-
-
Save jaybosamiya/3c42e7e26701c2e2531b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Index: libpcap/NMAP_MODIFICATIONS/0002-Add-the-disable-packet-ring-configure-option.patch | |
=================================================================== | |
--- libpcap/NMAP_MODIFICATIONS/0002-Add-the-disable-packet-ring-configure-option.patch (revision 32728) | |
+++ libpcap/NMAP_MODIFICATIONS/0002-Add-the-disable-packet-ring-configure-option.patch (working copy) | |
@@ -40,28 +40,34 @@ | |
AC_CONFIG_HEADER(config.h) | |
diff --git pcap-linux.c pcap-linux.c | |
-index d4f50b7..213558b 100644 | |
+index 17bd0f5..bd2457d 100644 | |
--- pcap-linux.c | |
+++ pcap-linux.c | |
-@@ -219,14 +219,16 @@ static const char rcsid[] _U_ = | |
+@@ -196,17 +196,19 @@ static const char rcsid[] _U_ = | |
/* check for memory mapped access avaibility. We assume every needed | |
* struct is defined if the macro TPACKET_HDRLEN is defined, because it | |
* uses many ring related structs and macros */ | |
-# ifdef TPACKET_HDRLEN | |
-# define HAVE_PACKET_RING | |
+-# ifdef TPACKET3_HDRLEN | |
+-# define HAVE_TPACKET3 | |
+-# endif /* TPACKET3_HDRLEN */ | |
-# ifdef TPACKET2_HDRLEN | |
-# define HAVE_TPACKET2 | |
--# else | |
--# define TPACKET_V1 0 | |
+-# else /* TPACKET2_HDRLEN */ | |
+-# define TPACKET_V1 0 /* Old kernel with only V1, so no TPACKET_Vn defined */ | |
-# endif /* TPACKET2_HDRLEN */ | |
-# endif /* TPACKET_HDRLEN */ | |
+# ifdef PCAP_SUPPORT_PACKET_RING | |
+# ifdef TPACKET_HDRLEN | |
+# define HAVE_PACKET_RING | |
++# ifdef TPACKET3_HDRLEN | |
++# define HAVE_TPACKET3 | |
++# endif /* TPACKET3_HDRLEN */ | |
+# ifdef TPACKET2_HDRLEN | |
+# define HAVE_TPACKET2 | |
-+# else | |
-+# define TPACKET_V1 0 | |
++# else /* TPACKET2_HDRLEN */ | |
++# define TPACKET_V1 0 /* Old kernel with only V1, so no TPACKET_Vn defined */ | |
+# endif /* TPACKET2_HDRLEN */ | |
+# endif /* TPACKET_HDRLEN */ | |
+# endif /* PCAP_SUPPORT_PACKET_RING */ | |
Index: libpcap/NMAP_MODIFICATIONS/0004-Include-netpacket-packet.h-before-pcap-bpf.h.patch | |
=================================================================== | |
--- libpcap/NMAP_MODIFICATIONS/0004-Include-netpacket-packet.h-before-pcap-bpf.h.patch (revision 32728) | |
+++ libpcap/NMAP_MODIFICATIONS/0004-Include-netpacket-packet.h-before-pcap-bpf.h.patch (working copy) | |
@@ -22,9 +22,8 @@ | |
--- | |
fad-getad.c | 12 ++++++------ | |
1 file changed, 6 insertions(+), 6 deletions(-) | |
- | |
diff --git fad-getad.c fad-getad.c | |
-index 742ae1f..519893a 100644 | |
+index af371d4..2b483f6 100644 | |
--- fad-getad.c | |
+++ fad-getad.c | |
@@ -54,12 +54,6 @@ static const char rcsid[] _U_ = | |
@@ -37,12 +36,12 @@ | |
-#include "os-proto.h" | |
-#endif | |
- | |
- #ifdef AF_PACKET | |
- # ifdef HAVE_NETPACKET_PACKET_H | |
- /* Solaris 11 and later, Linux distributions with newer glibc */ | |
-@@ -77,6 +71,12 @@ static const char rcsid[] _U_ = | |
+ /* | |
+ * We don't do this on Solaris 11 and later, as it appears there aren't | |
+ * any AF_PACKET addresses on interfaces, so we don't need this, and | |
+@@ -83,6 +77,12 @@ static const char rcsid[] _U_ = | |
# endif /* HAVE_NETPACKET_PACKET_H */ | |
- #endif /* AF_PACKET */ | |
+ #endif /* (defined(linux) || defined(__Lynx__)) && defined(AF_PACKET) */ | |
+#include "pcap-int.h" | |
+ | |
Index: libpcap/NMAP_MODIFICATIONS/HOWTO-UPGRADE | |
=================================================================== | |
--- libpcap/NMAP_MODIFICATIONS/HOWTO-UPGRADE (revision 32728) | |
+++ libpcap/NMAP_MODIFICATIONS/HOWTO-UPGRADE (working copy) | |
@@ -3,7 +3,7 @@ | |
cd | |
# Make a copy of this directory. | |
-cp -r ~/nmap/NMAP_MODIFICATIONS . | |
+cp -r ~/nmap/libpcap/NMAP_MODIFICATIONS . | |
tar xzvf libpcap-X.Y.tar.gz | |
cd nmap | |
rsync -rv --delete ~/libpcap-X.Y/ ~/nmap/libpcap/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment