mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-11-01 07:53:56 +08:00
💐 Sync 2026-09-10 14:49:21
This commit is contained in:
1 parent
0e9e9c2496
commit
7b0b16dcd4
181 files changed
+23375
-22143
No files matched your search
+11
-3
@@ -9,11 +9,19 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=miniupnpd
|
||||
PKG_VERSION:=2.3.11
|
||||
PKG_RELEASE:=8
|
||||
PKG_RELEASE:=9
|
||||
|
||||
PKG_SOURCE_URL:=https://github.com/miniupnp/miniupnp/releases/download/miniupnpd_$(subst .,_,$(PKG_VERSION))
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
#PKG_SOURCE_URL:=https://github.com/miniupnp/miniupnp/releases/download/miniupnpd_$(subst .,_,$(PKG_VERSION))
|
||||
#PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
#PKG_HASH:=66cb3c3d697ab2bb3a61d3c48628166d6ba328d7c2dbeb95898fdf2a3202af7b
|
||||
# Build from GitHub tag archives, as release archive differ in code comments to the public repository
|
||||
PKG_SOURCE_VERSION:=63ac33eaa49332cde15fd509b539a260b531da05
|
||||
PKG_SOURCE_URL:=https://codeload.github.com/miniupnp/miniupnp/tar.gz/$(PKG_SOURCE_VERSION)?
|
||||
PKG_SOURCE:=miniupnp-$(PKG_SOURCE_VERSION).tar.gz
|
||||
PKG_HASH:=skip
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)/miniupnpd
|
||||
TAR_OPTIONS+= --strip-components 1
|
||||
TAR_CMD=$(HOST_TAR) -C $(1)/.. $(TAR_OPTIONS)
|
||||
|
||||
PKG_MAINTAINER:=Alexandru Ardelean <ardeleanalex@gmail.com>
|
||||
PKG_LICENSE:=BSD-3-Clause
|
||||
|
||||
@@ -115,7 +115,7 @@ upnpd_generate_config() {
|
||||
network_find_wan6 external_iface6 && network_get_device ifname6 "$external_iface6"
|
||||
fi
|
||||
if [ "$ifname" = "" ]; then
|
||||
log "No external network interface found, not starting" daemon.err
|
||||
log "No external network interface detected yet, not starting" daemon.err
|
||||
return 1
|
||||
fi
|
||||
# Workaround for daemon bug with UPnP IGDv2 if IPv6 is not ready at start
|
||||
@@ -136,7 +136,7 @@ upnpd_generate_config() {
|
||||
10.* | 100.6[4-9].* | 100.[7-9][0-9].* | 100.1[0-1][0-9].* | 100.12[0-7].* | 172.1[6-9].* | \
|
||||
172.2[0-9].* | 172.3[0-1].* | 192.0.0.[1-6] | 192.168.* | 198.1[89].*) extipv4private=1 ;;
|
||||
esac
|
||||
[ "$extipv4private" = "1" ] && log "Private/CGNAT-reserved external IPv4 detected ($extipv4)"
|
||||
[ "$extipv4private" = "1" ] && log "Private/CGNAT-reserved external IPv4 detected"
|
||||
|
||||
{
|
||||
echo "# Daemon"
|
||||
@@ -197,7 +197,8 @@ upnpd_generate_config() {
|
||||
[ "$ipv6_disable" = "0" ] && echo "ipv6_disable=no" || echo "ipv6_disable=yes"
|
||||
local rejectport
|
||||
for rejectport in $reject_ports; do
|
||||
is_port_or_range "$rejectport" allowport0 && echo "deny 1-65535 0.0.0.0/0 $rejectport # Reject port $rejectport" &&
|
||||
[ "$rejectport" = "0" ] && continue
|
||||
is_port_or_range "$rejectport" allowport0 && echo "deny 1-65535 0.0.0.0/0 $rejectport # Reject internal port $rejectport" &&
|
||||
echo "deny $rejectport 0.0.0.0/0 1-65535 # Reject external port $rejectport" ||
|
||||
log "Invalid port or port range ($rejectport) in reject_ports ignored" daemon.warn
|
||||
done
|
||||
|
||||
@@ -53,7 +53,7 @@ if uci -q get upnpd.config.stun_host | grep -q -E "stun[0-9]?.l.google.com|stun.
|
||||
uci delete upnpd.config.stun_host
|
||||
uci -q delete upnpd.config.stun_port
|
||||
# To keep behaviour with daemon <2.3.10 as previously, a false-negative filter result was returned for unsupported servers
|
||||
uci set upnpd.config.allow_cgnat="allow-filtered"
|
||||
[ "$(uci -q get upnpd.config.allow_cgnat)" = "1" ] && uci set upnpd.config.allow_cgnat="allow-filtered"
|
||||
elif uci -q get upnpd.config.stun_port >/dev/null; then
|
||||
uci -q get upnpd.config.stun_host >/dev/null && [ "$(uci -q get upnpd.config.stun_port)" != "3478" ] &&
|
||||
log "stun_port: Include stun_port in stun_host, and remove option" &&
|
||||
|
||||
@@ -20,7 +20,7 @@ Link: https://github.com/Self-Hosting-Group/wiki/wiki/Port-Mapping-Protocols-Ove
|
||||
|
||||
--- a/upnphttp.c
|
||||
+++ b/upnphttp.c
|
||||
@@ -307,9 +307,22 @@ ParseHttpHeaders(struct upnphttp * h)
|
||||
@@ -319,9 +319,22 @@ ParseHttpHeaders(struct upnphttp * h)
|
||||
}
|
||||
else if(strncasecmp(line, "user-agent:", 11) == 0)
|
||||
{
|
||||
|
||||
File diff suppressed because it is too large.
Load diff
Reference in new issue
Block a user