mirror of
https://github.com/trailofbits/algo.git
synced 2025-06-07 07:33:52 +02:00
Modified script to handle more types of blocklists (#1771)
Added/modified script to better handle multiple types of blocklists available to drop in to the BLOCKLIST_URLS.
This commit is contained in:
parent
02fe2f7dd5
commit
e29615bc05
1 changed files with 1 additions and 1 deletions
|
@ -14,7 +14,7 @@ rm -f $BLOCKHOSTS
|
||||||
echo 'Downloading hosts lists...'
|
echo 'Downloading hosts lists...'
|
||||||
#Download and process the files needed to make the lists (enable/add more, if you want)
|
#Download and process the files needed to make the lists (enable/add more, if you want)
|
||||||
for url in $BLOCKLIST_URLS; do
|
for url in $BLOCKLIST_URLS; do
|
||||||
wget --timeout=2 --tries=3 -qO- "$url" | grep -Ev "(localhost)" | grep -Ew "(0.0.0.0|127.0.0.1)" | awk '{sub(/\r$/,"");print $2}' >> "$TEMP"
|
wget --timeout=2 --tries=3 -qO- "$url" | grep -Ev "(localhost)" | grep -Ev "#" | sed -E "s/(0.0.0.0 |127.0.0.1 |255.255.255.255 )//" >> "$TEMP"
|
||||||
done
|
done
|
||||||
|
|
||||||
#Add black list, if non-empty
|
#Add black list, if non-empty
|
||||||
|
|
Loading…
Add table
Reference in a new issue