OD-Database is a web-crawling project that aims to index a very large number of file links and their basic metadata from open directories (misconfigured Apache/Nginx/FTP servers, or more often, mirrors of various public services).
Each crawler instance fetches tasks from the central server and pushes the result once completed. A single instance can crawl hundreds of websites at the same time (Both FTP and HTTP(S)) and the central server is capable of ingesting thousands of new documents per second.
The data is indexed into elasticsearch and made available via the web frontend (Currently hosted at https://od-db.the-eye.eu/). There is currently ~1.93 billion files indexed (total of about 300Gb of raw data). The raw data is made available as a CSV file here.
Suggestions/concerns/PRs are welcome
Assuming you have Python 3 and git installed:
sudo apt install libssl-dev libcurl4-openssl-dev
git clone https://github.com/simon987/od-database
cd od-database
git submodule update --init --recursive
sudo pip3 install -r requirements.txt
Create /config.py
and fill out the parameters. Sample
config:
# Leave default values for no CAPTCHAs
= False
CAPTCHA_LOGIN = False
CAPTCHA_SUBMIT = False
CAPTCHA_SEARCH = 10
CAPTCHA_EVERY
# Flask secret key for sessions
= ""
FLASK_SECRET = (25, 50, 100, 250, 500, 1000)
RESULTS_PER_PAGE # Allow ftp websites in /submit
= False
SUBMIT_FTP # Allow http(s) websites in /submit
= True
SUBMIT_HTTP
= "http://localhost/api"
SERVER_URL = "5817926d-f2f9-4422-a411-a98f1bfe4b6c" API_TOKEN
The python crawler that was a part of this project is discontinued, the go implementation is currently in use.
cd od-database
python3 app.py
sudo apt install build-essential python-dev
sudo pip install uwsgi
od-database.ini
/etc/nginx/sites-enabled/default
):server {
...
include uwsgi_params;
location / {
uwsgi_pass 127.0.0.1:3031;
}
...
}
PUT _template/default
{
"index_patterns": ["*"],
"order": -1,
"settings": {
"number_of_shards": "50",
"number_of_replicas": "0",
"codec" : "best_compression",
"routing_partition_size" : 5
}
}
uwsgi od-database.ini