Skip to content

Instantly share code, notes, and snippets.

@wuhx
Created October 26, 2012 03:11
Show Gist options
  • Save wuhx/3956654 to your computer and use it in GitHub Desktop.
Save wuhx/3956654 to your computer and use it in GitHub Desktop.
openswan
#add for openswan
net.ipv4.ip_forward = 1
net.ipv4.conf.all.send_redirects = 0
net.ipv4.conf.default.send_redirects = 0
net.ipv4.conf.eth0.send_redirects = 0
#net.ipv4.conf.eth1.send_redirects = 0
net.ipv4.conf.lo.send_redirects = 0
net.ipv4.conf.all.accept_redirects = 0
net.ipv4.conf.default.accept_redirects = 0
net.ipv4.conf.eth0.accept_redirects = 0
#net.ipv4.conf.eth1.accept_redirects = 0
net.ipv4.conf.lo.accept_redirects = 0
sysctl -p
service ipsec start
///
# for f in /proc/sys/net/ipv4/conf/*/accept_redirects; do echo 0 > $f; done
# for f in /proc/sys/net/ipv4/conf/*/send_redirects; do echo 0 > $f; done
# echo 1 > /proc/sys/net/ipv4/ip_forward
///
ipsec verify
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment