This script fetches blocklist .json
from urls (such as
shavar-prod-lists) and
generates safebrowsing-compatible digest list files to be served by
shavar.
- python 2.x
- (optional) virtualenv and/or virtualenvwrapper
-
(optional) Make a virtualenv for the project and activate it:
virtualenv shavar-list-creation source shavar-list-creation/bin/activate
-
Install required libraries:
pip install -r requirements.txt
-
Copy the
sample_shavar_list_creation.ini
file toshavar_list_creation.ini
:cp sample_shavar_list_creation.ini shavar_list_creation.ini
-
Run the
lists2safebrowsing.py
script:./lists2safebrowsing.py
This is run by a Jenkins deployment job every 30 minutes that:
- Checks out this repository
- Checks out the shavar-list-creation-config repository
- Copies
stage.ini
orprod.ini
toshavar_list_creation.ini
- Runs
python lists2safebrowsing.py
, which uploads updated safebrowsing list files to S3 for shavar.