mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-18 23:45:52 +08:00
test
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
<div class="bt-w-menu">
|
||||
<p class="bgw" onclick="pluginService('l2tp');">服务</p>
|
||||
<p onclick="pluginConfig('l2tp',null, 'conf');">用户配置</p>
|
||||
<p onclick="pluginConfig('l2tp',null, 'conf_psk');">PSK配置</p>
|
||||
<p onclick="userList();">用户列表</p>
|
||||
</div>
|
||||
<div class="bt-w-con pd15">
|
||||
|
||||
@@ -92,6 +92,12 @@ def getPathFile():
|
||||
return '/etc/ppp/chap-secrets'
|
||||
|
||||
|
||||
def getPathFilePsk():
|
||||
if public.isAppleSystem():
|
||||
return getServerDir() + '/ipsec.secrets'
|
||||
return '/etc/ipsec.secrets'
|
||||
|
||||
|
||||
def getUserList():
|
||||
import re
|
||||
path = getPathFile()
|
||||
@@ -183,6 +189,8 @@ if __name__ == "__main__":
|
||||
print reload()
|
||||
elif func == 'conf':
|
||||
print getPathFile()
|
||||
elif func == 'conf_psk':
|
||||
print getPathFilePsk()
|
||||
elif func == 'user_list':
|
||||
print getUserList()
|
||||
elif func == 'add_user':
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
%any %any : PSK "midoks"
|
||||
Reference in New Issue
Block a user