diff --git a/SOURCES/nmap-ipv6_literal_proxy.patch b/SOURCES/nmap-ipv6_literal_proxy.patch new file mode 100644 index 0000000..8d730fc --- /dev/null +++ b/SOURCES/nmap-ipv6_literal_proxy.patch @@ -0,0 +1,13 @@ +diff --git a/ncat/ncat_connect.c b/ncat/ncat_connect.c +index 0968601..447aeb1 100644 +--- a/ncat/ncat_connect.c ++++ b/ncat/ncat_connect.c +@@ -353,7 +353,7 @@ static const char *sock_to_url(char *host_str, unsigned short port) + Snprintf(buf, sizeof(buf), "%s:%hu", host_str, port); + break; + case 2: +- Snprintf(buf, sizeof(buf), "[%s]:%hu]", host_str, port); ++ Snprintf(buf, sizeof(buf), "[%s]:%hu", host_str, port); + } + + return buf; diff --git a/SOURCES/nmap_resolve_config.patch b/SOURCES/nmap_resolve_config.patch new file mode 100644 index 0000000..b843921 --- /dev/null +++ b/SOURCES/nmap_resolve_config.patch @@ -0,0 +1,12 @@ +diff --git a/ncat/ncat_core.c b/ncat/ncat_core.c +index 21eca9e..c45a04e 100644 +--- a/ncat/ncat_core.c ++++ b/ncat/ncat_core.c +@@ -287,6 +287,7 @@ int resolve(const char *hostname, unsigned short port, + int result; + + flags = 0; ++ flags |= AI_ADDRCONFIG; + if (o.nodns) + flags |= AI_NUMERICHOST; + diff --git a/SPECS/nmap.spec b/SPECS/nmap.spec index 10b531d..1c3386a 100644 --- a/SPECS/nmap.spec +++ b/SPECS/nmap.spec @@ -13,7 +13,7 @@ Name: nmap Epoch: 2 Version: 7.70 #global prerelease TEST5 -Release: 6%{?dist} +Release: 8%{?dist} # Uses combination of licenses based on GPL license, but with extra modification # so it got its own license tag rhbz#1055861 License: Nmap @@ -37,6 +37,11 @@ Patch5: ncat_reg_stdin.diff Patch6: nmap-6.25-displayerror.patch Patch7: nmap-safe_fd_functions.patch +# https://github.com/nmap/nmap/pull/2247 +Patch8: nmap_resolve_config.patch + +# https://bugzilla.redhat.com/show_bug.cgi?id=2120294 +Patch9: nmap-ipv6_literal_proxy.patch URL: http://nmap.org/ BuildRequires: gcc-c++ @@ -270,6 +275,12 @@ fi %endif %changelog +* Tue Aug 23 2022 Martin Osvald - 2:7.70-8 +- Resolves: #2120294 - wrong connect format + +* Wed May 04 2022 Martin Osvald - 2:7.70-7 +- Do not listen on ipv6 if it's disabled (#1899824) + * Wed Jul 21 2021 Pavel Zhukov - 2:7.70-6 - Use safe variants of FD_ functions (#1914733)