当前位置:网站首页>Deploy L2TP in VPN (Part 2)

Deploy L2TP in VPN (Part 2)

2022-06-24 07:31:00 Chen Bucheng I

If some options are not found , Write it directly to the end of the file . After preservation , perform : sysctl -p

2.iptables Rule settings need iptables To forward external requests .sysctl The solution is , A user through ppp After connecting to the server , How does his request map inside the server , therefore , No, iptables, The user configures through the above , You can log in and connect to L2TP VPN 了 , But it's very likely that you can't access the Internet on the connection , Because the external request has not been forwarded , Configure the following to forward . iptables -I INPUT -p udp -m multiport --dports 500,4500,1701 -j ACCEPTiptables -I FORWARD -m state --state RELATED,ESTABLISHED -j ACCEPTiptables -I FORWARD -s 192.168.2.0/23 -j ACCEPTiptables -t nat -A POSTROUTING -s 192.168.2.0/23 -j SNAT --to-source xxx.xx.xx.xxiptables save

among 192.168.2.0/23 Is the assigned client address range customizable ,xxx.xx.xx.xx Is the mapped Internet address systemctl restart iptables

3、 ... and . Client connection

1. Meet these conditions

  • Make sure that the local router does not vpn The intranet segment of the server In a segment , Otherwise conflict
  • windows A pure system must be used
  • Make sure you are not currently using the agent software , No wall climbing VPN

2.. Open the network sharing center –> Set up a connection or network – Connect to the workspace

3. Click to use my internet Connect – Enter the address information

4. Enter the username and password – establish

5. Click change adapter settings – Right click VPN, Select Properties

6. Click Security Settings vpn type

6. Click Advanced settings to set the shared secret key

7. Click OK to connect

原网站

版权声明
本文为[Chen Bucheng I]所创,转载请带上原文链接,感谢
https://yzsam.com/2021/06/20210630195006474q.html

随机推荐