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

Try to fix uPnP (#547)

This commit is contained in:
suyuan 2024-09-24 18:23:28 +08:00 committed by GitHub
commit 3c0ec8ae81
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 12 additions and 0 deletions

View file

@ -0,0 +1,3 @@
#!/bin/sh
/etc/init.d/miniupnpd restart >/dev/null 2>&1

View file

@ -158,6 +158,15 @@ if [ "$(uci -q get firewall.ttl)" = "" ]; then
commit firewall
EOF
fi
if [ "$(uci -q get firewall.upnp)" = "" ]; then
uci -q batch <<-EOF >/dev/null
set firewall.upnp=include
set firewall.upnp.path='/etc/firewall.ttl'
set firewall.upnp.type='script'
set firewall.upnp.fw4_compatible='1'
commit firewall
EOF
fi
if [ "$(uci -q get firewall.fwlantovpn)" = "" ]; then
uci -q batch <<-EOF >/dev/null
set firewall.zone_lan.auto_helper='0'