Add files via upload

This commit is contained in:
Imre Kristoffer Eilertsen
2020-08-27 05:08:49 +02:00
committed by GitHub
parent 3415bd1a46
commit 109f38629b
2 changed files with 14 additions and 15 deletions
@@ -354,17 +354,16 @@
{ "action": "deny", "process": "any", "remote-addresses": "195.88.54.21" },
{ "action": "deny", "process": "any", "remote-addresses": "195.88.55.21" },
{ "action": "deny", "process": "any", "remote-addresses": "196.196.230.76" },
{ "action": "deny", "process": "any", "remote-domains": "2001:67c:21e0::ad" }
]}
{ "action": "deny", "process": "any", "remote-addresses": "2001:67c:21e0::ad" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"5d404.v.fwmrm.net" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"elkjop.no.edgekey.net" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"dnb.no.edgekey.net" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"skatteetaten.no.cdn.cloudflare.net" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"norwegian.com.cdn.cloudflare.net" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"ad.dep.no" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"ad.hem.no" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"ads.mst.dk" },
{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"annonser.gess.no" },
{ "action": "allow", "process": "any", "remote-domains": "5d404.v.fwmrm.net" },
{ "action": "allow", "process": "any", "remote-domains": "elkjop.no.edgekey.net" },
{ "action": "allow", "process": "any", "remote-domains": "dnb.no.edgekey.net" },
{ "action": "allow", "process": "any", "remote-domains": "skatteetaten.no.cdn.cloudflare.net" },
{ "action": "allow", "process": "any", "remote-domains": "norwegian.com.cdn.cloudflare.net" },
{ "action": "allow", "process": "any", "remote-domains": "ad.dep.no" },
{ "action": "allow", "process": "any", "remote-domains": "ad.hem.no" },
{ "action": "allow", "process": "any", "remote-domains": "ads.mst.dk" },
{ "action": "allow", "process": "any", "remote-domains": "annonser.gess.no" },
@@ -2395,19 +2395,19 @@ def prepare_ls(lines) -> str:
)
line = re.sub(
r"remote-domains(\": \"[0-9a-f:]{4,39}\")",
r"remote-addresses\1",
r"remote-domains(\": \"[0-9a-f:]{4,39})$",
r'remote-addresses\1" },',
line
)
line = re.sub(
r"{ \"action\": \"deny\", \"process\": \"any\", \"remote-domains\": \"!",
r"{ \"action\": \"allow\", \"process\": \"any\", \"remote-domains\": \"",
r'{ "action": "allow", "process": "any", "remote-domains": "',
line
)
line = re.sub(
r"(\"2001:67c:21e0::ad$)",
r"(\"annonser\.gess\.no$)",
r'\1" }\n]}',
line
)