diff options
| author | Xiyue Deng | 2013-01-30 12:34:22 -0800 |
|---|---|---|
| committer | Adam Vandenberg | 2013-01-30 12:46:02 -0800 |
| commit | 4f08d34d7c927d90c7fbc63d1f0b374d1f39e266 (patch) | |
| tree | 5efe39f867837d227e501ed2136fb2571698447c /Library/Formula/ettercap.rb | |
| parent | bf19835a291cdf79292d10b2b76c88f248894923 (diff) | |
| download | homebrew-4f08d34d7c927d90c7fbc63d1f0b374d1f39e266.tar.bz2 | |
Ettercap 0.7.5.2
* Also drop merged upstream patches.
Closes #17445.
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library/Formula/ettercap.rb')
| -rw-r--r-- | Library/Formula/ettercap.rb | 107 |
1 files changed, 2 insertions, 105 deletions
diff --git a/Library/Formula/ettercap.rb b/Library/Formula/ettercap.rb index 88c9addad..202d82a2b 100644 --- a/Library/Formula/ettercap.rb +++ b/Library/Formula/ettercap.rb @@ -2,8 +2,8 @@ require 'formula' class Ettercap < Formula homepage 'http://ettercap.sourceforge.net' - url 'http://downloads.sourceforge.net/project/ettercap/ettercap/0.7.5-Assimilation/ettercap-0.7.5.1.tar.gz' - sha1 '912394ce37479099402281030b472bc92a5d6db6' + url 'http://downloads.sourceforge.net/project/ettercap/ettercap/0.7.5-Assimilation/ettercap-0.7.5.2.tar.gz' + sha1 'c0b7798c6ff95b04402042956e62e2e984ba48d5' depends_on 'cmake' => :build depends_on 'ghostscript' => :build @@ -11,12 +11,6 @@ class Ettercap < Formula depends_on 'libnet' depends_on 'curl' # require libcurl >= 7.26.0 - # Solve incompatible return types. - # Patch forwarded upstream: https://github.com/Ettercap/ettercap/pull/66 - # Merge upstream fix for CVE-2012-0722: https://github.com/Ettercap/ettercap/pull/68 - # Both patch already merged upstream. Drop on next major version. - def patches; DATA; end - def install libnet = Formula.factory 'libnet' @@ -32,100 +26,3 @@ class Ettercap < Formula end end end - -__END__ -diff --git a/src/dissectors/ec_mongodb.c b/src/dissectors/ec_mongodb.c -index 86ebbdd..297e8d7 100644 ---- a/src/dissectors/ec_mongodb.c -+++ b/src/dissectors/ec_mongodb.c -@@ -99,7 +99,7 @@ FUNC_DECODER(dissector_mongodb) - if (session_get(&s, ident, DISSECT_IDENT_LEN) == ESUCCESS) { - conn_status = (struct mongodb_status *) s->data; - if (PACKET->DATA.len < 16) -- return; -+ return NULL; - unsigned char *res = memmem(ptr, PACKET->DATA.len, "fails", 5); - unsigned char *gres = memmem(ptr, PACKET->DATA.len, "readOnly", 8); - if (conn_status->status == WAIT_RESULT && res) { -@@ -118,7 +118,7 @@ FUNC_DECODER(dissector_mongodb) - if (session_get(&s, ident, DISSECT_IDENT_LEN) == ESUCCESS) { - conn_status = (struct mongodb_status *) s->data; - if (PACKET->DATA.len < 16) -- return; -+ return NULL; - - unsigned char *noncep = memmem(ptr, PACKET->DATA.len, "nonce", 5); - unsigned char *keyp = memmem(ptr, PACKET->DATA.len, "key\x00", 4); -diff --git a/include/ec.h b/include/ec.h -index 463e36f..069e3f1 100644 ---- a/include/ec.h -+++ b/include/ec.h -@@ -81,6 +81,11 @@ - - #define SAFE_FREE(x) do{ if(x) { free(x); x = NULL; } }while(0) - -+ -+/* convert to string */ -+#define EC_STRINGIFY(in) #in -+#define EC_TOSTRING(in) EC_STRINGIFY(in) -+ - #ifdef OS_LINUX - #define __init __attribute__((constructor(101))) - #define __init_last __attribute__((constructor(200)) -diff --git a/include/ec_inet.h b/include/ec_inet.h -index 43b0ca5..379192d 100644 ---- a/include/ec_inet.h -+++ b/include/ec_inet.h -@@ -24,24 +24,22 @@ - #endif - #endif - --enum { -- NS_IN6ADDRSZ = 16, -- NS_INT16SZ = 2, -- -- ETH_ADDR_LEN = 6, -- TR_ADDR_LEN = 6, -- FDDI_ADDR_LEN = 6, -- MEDIA_ADDR_LEN = 6, -+#define NS_IN6ADDRSZ 16 -+#define NS_INT16SZ = 2 -+ -+#define ETH_ADDR_LEN 6 -+#define TR_ADDR_LEN 6 -+#define FDDI_ADDR_LEN 6 -+#define MEDIA_ADDR_LEN 6 - -- IP_ADDR_LEN = 4, -- IP6_ADDR_LEN = 16, -- MAX_IP_ADDR_LEN = IP6_ADDR_LEN, -- -- ETH_ASCII_ADDR_LEN = sizeof("ff:ff:ff:ff:ff:ff")+1, -- IP_ASCII_ADDR_LEN = sizeof("255.255.255.255")+1, -- IP6_ASCII_ADDR_LEN = sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255")+1, -- MAX_ASCII_ADDR_LEN = IP6_ASCII_ADDR_LEN, --}; -+#define IP_ADDR_LEN 4 -+#define IP6_ADDR_LEN 16 -+#define MAX_IP_ADDR_LEN IP6_ADDR_LEN -+ -+#define ETH_ASCII_ADDR_LEN 19 // sizeof("ff:ff:ff:ff:ff:ff")+1 -+#define IP_ASCII_ADDR_LEN 17 // sizeof("255.255.255.255")+1 -+#define IP6_ASCII_ADDR_LEN 47 // sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255")+1 -+#define MAX_ASCII_ADDR_LEN IP6_ASCII_ADDR_LEN - - /* - * Some predefined addresses here -diff --git a/src/ec_scan.c b/src/ec_scan.c -index cce3672..9455c3e 100644 ---- a/src/ec_scan.c -+++ b/src/ec_scan.c -@@ -630,7 +630,7 @@ int scan_load_hosts(char *filename) - for (nhosts = 0; !feof(hf); nhosts++) { - int proto; - -- if (fscanf(hf, "%s %s %s\n", ip, mac, name) != 3 || -+ if (fscanf(hf, "%"EC_TOSTRING(MAX_ASCII_ADDR_LEN)"s %"EC_TOSTRING(ETH_ASCII_ADDR_LEN)"s %"EC_TOSTRING(MAX_HOSTNAME_LEN)"s\n", ip, mac, name) != 3 || - *ip == '#' || *mac == '#' || *name == '#') - continue; - |
