services.opengfw.rules
Rules passed to OpenGFW. Example rules
- Type
list of (submodule)- Default
[ ]- Example
[ { action = "block"; expr = "string(http?.req?.headers?.host) endsWith \"v2ex.com\""; name = "block v2ex http"; } { action = "block"; expr = "string(socks?.req?.addr) endsWith \"google.com\" && socks?.req?.port == 80"; name = "block google socks"; } { action = "modify"; expr = "dns != nil && dns.qr && any(dns.questions, {.name endsWith \"v2ex.com\"})"; modifier = { args = { a = "0.0.0.0"; aaaa = "::"; }; name = "dns"; }; name = "v2ex dns poisoning"; } ]- Declared
- <nixpkgs/nixos/modules/services/networking/opengfw.nix>