Created
January 15, 2021 17:12
-
-
Save daveio/73bdc21ff61ac2dabc9eeb513e62a025 to your computer and use it in GitHub Desktop.
dante sending socks requests out alternate interface
This file contains 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
# get dante to use uid 'proxy' for priv and unpriv | |
# echo "201 fastlane" >> /etc/iproute2/rt_tables | |
ip rule add fwmark 0x1 table fastlane | |
ip route add default via 10.0.104.1 dev fastlane table fastlane | |
iptables -A OUTPUT -t mangle ! -d 10.0.101.0/24 -m owner --uid-owner proxy -j MARK --set-mark 1 | |
iptables -t nat -A OUTPUT -m owner --uid-owner proxy -p udp --dport 53 -j DNAT --to 10.0.104.1:53 | |
iptables -t nat -A OUTPUT -m owner --uid-owner proxy -p tcp --dport 53 -j DNAT --to 10.0.104.1:53 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment