1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-03-09 15:40:03 +00:00

v2ray plugin support

This commit is contained in:
Ycarus 2019-01-26 13:51:53 +01:00
parent df7a7ffd2b
commit 58b4ff3198
8 changed files with 186 additions and 40 deletions

View file

@ -131,10 +131,22 @@ end
function options_obfs(s, tab)
local o
local v2ray_installed = nixio.fs.access("/usr/bin/v2ray-plugin")
local obfs_installed = nixio.fs.access("/usr/bin/obfs-local")
s:taboption(tab, Flag, "obfs", translate("Enable"))
o = s:taboption(tab, ListValue, "obfs_plugin", translate("Plugin"))
if v2ray_installed then
o:value("v2ray")
o.default = "v2ray"
else
o.default = "obfs-simple"
end
if obfs_installed then
o:value("obfs-simple")
end
o = s:taboption(tab, ListValue, "obfs_type", translate("Type"))
o:value("http")
o:value("tls")
--o:value("tls")
o.default = "http"
end