mirror of
https://bitbucket.org/anticensority/antizapret-pac-generator-light.git
synced 2024-11-22 05:06:04 +03:00
Handle special DNS zones only by their full blocked domain, not by third level domain
This commit is contained in:
parent
ae9e96ece8
commit
91b2584845
@ -66,7 +66,7 @@ echo " if (domains.length < 10) return \"DIRECT\"; // list is broken
|
||||
|
||||
var shost;
|
||||
if (/\.(ru|co|cu|com|info|net|org|gov|edu|int|mil|biz|pp|ne|msk|spb|nnov|od|in|ho|cc|dn|i|tut|v|dp|sl|ddns|dyndns|livejournal|herokuapp|azurewebsites|cloudfront|ucoz|3dn|nov|linode|amazonaws|sl-reverse|kiev|beget|kirov|akadns|scaleway|fastly)\.[^.]+$/.test(host))
|
||||
shost = host.replace(/(.+)\.([^.]+\.[^.]+\.[^.]+$)/, \"\$2\");
|
||||
shost = host;
|
||||
else
|
||||
shost = host.replace(/(.+)\.([^.]+\.[^.]+$)/, \"\$2\");
|
||||
|
||||
|
@ -17,9 +17,7 @@
|
||||
{sub(/\.$/, "", $1)}
|
||||
|
||||
{
|
||||
if (/\.(ru|co|cu|com|info|net|org|gov|edu|int|mil|biz|pp|ne|msk|spb|nnov|od|in|ho|cc|dn|i|tut|v|dp|sl|ddns|dyndns|livejournal|herokuapp|azurewebsites|cloudfront|ucoz|3dn|nov|linode|amazonaws|sl-reverse|kiev|beget|kirov|akadns|scaleway|fastly)\.[^.]+$/)
|
||||
{$1 = gensub(/(.+)\.([^.]+\.[^.]+\.[^.]+$)/, "\\2", 1)}
|
||||
else
|
||||
if (!(/\.(ru|co|cu|com|info|net|org|gov|edu|int|mil|biz|pp|ne|msk|spb|nnov|od|in|ho|cc|dn|i|tut|v|dp|sl|ddns|dyndns|livejournal|herokuapp|azurewebsites|cloudfront|ucoz|3dn|nov|linode|amazonaws|sl-reverse|kiev|beget|kirov|akadns|scaleway|fastly|hldns|appspot|my1|hwcdn)\.[^.]+$/))
|
||||
{$1 = gensub(/(.+)\.([^.]+\.[^.]+$)/, "\\2", 1)}
|
||||
}
|
||||
|
||||
@ -35,4 +33,4 @@ function printarray(arrname, arr) {
|
||||
# Final function
|
||||
END {
|
||||
printarray("d_other", d_other)
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user