Created
March 18, 2025 14:08
-
-
Save will/d42cdaaefcf80ccffbc64f2f02e5b85c to your computer and use it in GitHub Desktop.
nftables mitmproxy nixos
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
block_global: false | |
ssl_insecure: true | |
connection_strategy: lazy | |
keep_alive: false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# assume uid 1000 runs mitmproxy, all other user's (eg root) traffic will be routed through mitmproxy | |
{ | |
# found in ~/.mitmproxy/ after running it once | |
security.pki.certificateFiles = [ ./mitmproxy-ca-cert.pem ]; | |
# networking.nftables.ruleset = '' | |
# table ip filter { | |
# chain mitmproxy { | |
# type nat hook output priority -100; policy accept; | |
# ip protocol tcp meta skuid 1000 return | |
# ip protocol tcp tcp dport 443 redirect to 8080 | |
# } | |
# } | |
# | |
# table ip6 filter { | |
# chain mitmproxy { | |
# type nat hook output priority -100; policy accept; | |
# ip6 nexthdr tcp meta skuid 1000 return | |
# ip6 nexthdr tcp tcp dport 443 redirect to 8080 | |
# } | |
# } | |
# ''; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment