luci-app-ssr-plus: Add WireGuard kernelMode reserved keepalive allowedips argument

whether to use the virtual NIC TUN of the Linux kernel!Virtual NIC TUN of Linux kernel can be used only when system supports and have root permission.
Some routes cannot be connected if they are used.
This commit is contained in:
zxlhhyccc 2024-04-05 22:45:12 +08:00 committed by sbwml
parent 636ac623e7
commit bc711b591d

View File

@ -831,11 +831,22 @@ o:depends("transport", "kcp")
o.rmempty = true o.rmempty = true
-- [[ WireGuard 部分 ]]-- -- [[ WireGuard 部分 ]]--
o = s:option(Flag, "kernelmode", translate("Enabled Kernel virtual NIC TUN(optional)"))
o.description = translate("Virtual NIC TUN of Linux kernel can be used only when system supports and have root permission. If used, IPv6 routing table 1023 is occupied.")
o:depends({type = "v2ray", v2ray_protocol = "wireguard"})
o.default = "0"
o.rmempty = true
o = s:option(DynamicList, "local_addresses", translate("Local addresses")) o = s:option(DynamicList, "local_addresses", translate("Local addresses"))
o.datatype = "cidr" o.datatype = "cidr"
o:depends({type = "v2ray", v2ray_protocol = "wireguard"}) o:depends({type = "v2ray", v2ray_protocol = "wireguard"})
o.rmempty = true o.rmempty = true
o = s:option(DynamicList, "reserved", translate("Reserved bytes(optional)"))
o.description = translate("Wireguard reserved bytes.")
o:depends({type = "v2ray", v2ray_protocol = "wireguard"})
o.rmempty = true
o = s:option(Value, "private_key", translate("Private key")) o = s:option(Value, "private_key", translate("Private key"))
o:depends({type = "v2ray", v2ray_protocol = "wireguard"}) o:depends({type = "v2ray", v2ray_protocol = "wireguard"})
o.password = true o.password = true
@ -850,6 +861,19 @@ o:depends({type = "v2ray", v2ray_protocol = "wireguard"})
o.password = true o.password = true
o.rmempty = true o.rmempty = true
o = s:option(Value, "keepalive", translate("Heartbeat interval(second)"))
o.description = translate("Default value 0 indicatesno heartbeat.")
o:depends({type = "v2ray", v2ray_protocol = "wireguard"})
o.default = "0"
o.rmempty = true
o = s:option(DynamicList, "allowedips", translate("allowedIPs(optional)"))
o.description = translate("Wireguard allows only traffic from specific source IP.")
o.datatype = "cidr"
o:depends({type = "v2ray", v2ray_protocol = "wireguard"})
o.default = "0.0.0.0/0"
o.rmempty = true
-- [[ TLS ]]-- -- [[ TLS ]]--
o = s:option(Flag, "tls", translate("TLS")) o = s:option(Flag, "tls", translate("TLS"))
o.rmempty = true o.rmempty = true