nixos/home: Filter out Disney+ IPv6 DNS queries
All checks were successful
CI / Check, build and cache Nix flake (push) Successful in 36m4s

This commit is contained in:
Jack O'Sullivan 2024-05-16 21:05:48 +01:00
parent 746e0b9dc4
commit a5e51ddd6b

View File

@ -61,6 +61,19 @@ in
webserver = true;
webserver-address = "::";
webserver-allow-from = [ "127.0.0.1" "::1" ];
lua-dns-script = pkgs.writeText "pdns-script.lua" ''
-- Disney+ doesn't like our IP space...
function preresolve(dq)
local name = dq.qname:toString()
if dq.qtype == pdns.AAAA and (string.find(name, "disneyplus") or string.find(name, "disney-plus")) then
dq.rcode = 0
return true
end
return false
end
'';
};
};
};