Skip to content

Commit 180dc3c

Browse files
committed
build: miniupnpc 2.2.2
Creating the dll subdir is no-longer required. We can also drop our wingen patch.
1 parent c46f1ce commit 180dc3c

File tree

4 files changed

+37
-33
lines changed

4 files changed

+37
-33
lines changed

depends/packages/miniupnpc.mk

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
package=miniupnpc
2-
$(package)_version=2.0.20180203
2+
$(package)_version=2.2.2
33
$(package)_download_path=https://miniupnp.tuxfamily.org/files/
44
$(package)_file_name=$(package)-$($(package)_version).tar.gz
5-
$(package)_sha256_hash=90dda8c7563ca6cd4a83e23b3c66dbbea89603a1675bfdb852897c2c9cc220b7
6-
$(package)_patches=dont_use_wingen.patch
5+
$(package)_sha256_hash=888fb0976ba61518276fe1eda988589c700a3f2a69d71089260d75562afd3687
6+
$(package)_patches=dont_leak_info.patch
77

88
define $(package)_set_vars
99
$(package)_build_opts=CC="$($(package)_cc)"
@@ -13,9 +13,7 @@ $(package)_build_env+=CFLAGS="$($(package)_cflags) $($(package)_cppflags)" AR="$
1313
endef
1414

1515
define $(package)_preprocess_cmds
16-
mkdir dll && \
17-
sed -e 's|MINIUPNPC_VERSION_STRING \"version\"|MINIUPNPC_VERSION_STRING \"$($(package)_version)\"|' -e 's|OS/version|$(host)|' miniupnpcstrings.h.in > miniupnpcstrings.h && \
18-
patch -p1 < $($(package)_patch_dir)/dont_use_wingen.patch
16+
patch -p1 < $($(package)_patch_dir)/dont_leak_info.patch
1917
endef
2018

2119
define $(package)_build_cmds
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
commit 8815452257437ba36607d0e2381c01142d1c7bb0
2+
Author: fanquake <[email protected]>
3+
Date: Thu Nov 19 10:51:19 2020 +0800
4+
5+
Don't leak OS and miniupnpc version info in User-Agent
6+
7+
diff --git a//minisoap.c b/minisoap.c
8+
index 7860667..775580b 100644
9+
--- a/minisoap.c
10+
+++ b/minisoap.c
11+
@@ -90,7 +90,7 @@ int soapPostSubmit(SOCKET fd,
12+
headerssize = snprintf(headerbuf, sizeof(headerbuf),
13+
"POST %s HTTP/%s\r\n"
14+
"Host: %s%s\r\n"
15+
- "User-Agent: " OS_STRING ", " UPNP_VERSION_STRING ", MiniUPnPc/" MINIUPNPC_VERSION_STRING "\r\n"
16+
+ "User-Agent: " UPNP_VERSION_STRING "\r\n"
17+
"Content-Length: %d\r\n"
18+
"Content-Type: text/xml\r\n"
19+
"SOAPAction: \"%s\"\r\n"
20+
diff --git a/miniwget.c b/miniwget.c
21+
index d5b7970..05aeb9c 100644
22+
--- a/miniwget.c
23+
+++ b/miniwget.c
24+
@@ -444,7 +444,7 @@ miniwget3(const char * host,
25+
"GET %s HTTP/%s\r\n"
26+
"Host: %s:%d\r\n"
27+
"Connection: Close\r\n"
28+
- "User-Agent: " OS_STRING ", " UPNP_VERSION_STRING ", MiniUPnPc/" MINIUPNPC_VERSION_STRING "\r\n"
29+
+ "User-Agent: " UPNP_VERSION_STRING "\r\n"
30+
31+
"\r\n",
32+
path, httpversion, host, port);

depends/patches/miniupnpc/dont_use_wingen.patch

Lines changed: 0 additions & 26 deletions
This file was deleted.

doc/dependencies.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ These are the dependencies currently used by Bitcoin Core. You can find instruct
1717
| libnatpmp | git commit [4536032...](https://github.com/miniupnp/libnatpmp/tree/4536032ae32268a45c073a4d5e91bbab4534773a) | | No | | |
1818
| libpng | | | | | [Yes](https://github.com/bitcoin/bitcoin/blob/master/depends/packages/qt.mk) |
1919
| librsvg | | | | | |
20-
| MiniUPnPc | [2.0.20180203](https://miniupnp.tuxfamily.org/files) | | No | | |
20+
| MiniUPnPc | [2.2.2](https://miniupnp.tuxfamily.org/files) | | No | | |
2121
| PCRE | | | | | [Yes](https://github.com/bitcoin/bitcoin/blob/master/depends/packages/qt.mk) |
2222
| Python (tests) | | [3.6](https://www.python.org/downloads) | | | |
2323
| qrencode | [3.4.4](https://fukuchi.org/works/qrencode) | | No | | |

0 commit comments

Comments
 (0)