1
0
mirror of synced 2024-11-25 14:26:09 +03:00

Add notes on multiple VPN users

This commit is contained in:
hwdsl2 2016-05-11 02:30:40 -05:00
parent 4f7050d9d0
commit aaccabd55a
3 changed files with 23 additions and 2 deletions

View File

@ -75,7 +75,7 @@ sudo sh vpnsetup_centos.sh
**iPhone/iPad 用户**: 在 iOS 的设置菜单请选择 `L2TP` (而不是 `IPSec`) 作为 VPN 类型。
如果要创建具有不同凭据的多个 VPN 用户,只需要<a href="https://gist.github.com/hwdsl2/123b886f29f4c689f531" target="_blank">修改这几行的脚本</a>
如果要创建具有不同凭据的多个 VPN 用户,只需要<a href="docs/enable-multiple-users.txt" target="_blank">修改这几行的脚本</a>
在 VPN 已连接时,客户端配置为使用 <a href="https://developers.google.com/speed/public-dns/" target="_blank">Google Public DNS</a>。此设置可在 `options.xl2tpd` 文件的 `ms-dns` 项更改。

View File

@ -74,7 +74,7 @@ For **Windows users**, a <a href="https://documentation.meraki.com/MX-Z/Client_V
**iPhone/iPad users**: In iOS settings, choose `L2TP` (instead of `IPSec`) as the VPN type.
To enable multiple VPN users with different credentials, just <a href="https://gist.github.com/hwdsl2/123b886f29f4c689f531" target="_blank">edit a few lines</a> in the scripts.
To enable multiple VPN users with different credentials, just <a href="docs/enable-multiple-users.txt" target="_blank">edit a few lines</a> in the scripts.
Clients are configured to use <a href="https://developers.google.com/speed/public-dns/" target="_blank">Google Public DNS</a> when the VPN is active. To change, set `ms-dns` in `options.xl2tpd`.

View File

@ -0,0 +1,21 @@
To enable multiple VPN users with different credentials, find and replace these lines in the script:
cat > /etc/ppp/chap-secrets <<EOF
# Secrets for authentication using CHAP
# client server secret IP addresses
"$VPN_USER" l2tpd "$VPN_PASSWORD" *
EOF
with the following:
cat > /etc/ppp/chap-secrets <<EOF
"user1" l2tpd "password1" *
"user2" l2tpd "password2" *
EOF
-----------------
IMPORTANT NOTES
-----------------
1. Make sure there is NO SPACE after both EOF above!
2. This example shows user1 with password1, and user2 with password2. You can add more users, use one line for each user.
3. The characters \ and " within your username/password MUST be escaped as \\ and \", respectively.