diff options
author | adamw <adamw@FreeBSD.org> | 2014-08-01 00:26:58 +0800 |
---|---|---|
committer | adamw <adamw@FreeBSD.org> | 2014-08-01 00:26:58 +0800 |
commit | ffca3bd8ba655c9d3fb462cdb573a157d82bc3b9 (patch) | |
tree | e0f6b8c0407732a3932276ad579d1cafae2d8355 | |
parent | 34ef8d12c8e5be2db51b1a755da49cc3db0d1b4d (diff) | |
download | freebsd-ports-gnome-ffca3bd8ba655c9d3fb462cdb573a157d82bc3b9.tar.gz freebsd-ports-gnome-ffca3bd8ba655c9d3fb462cdb573a157d82bc3b9.tar.zst freebsd-ports-gnome-ffca3bd8ba655c9d3fb462cdb573a157d82bc3b9.zip |
Stage and unbreak by adding missing headers and removing the MD2 code.
-rw-r--r-- | security/rainbowcrack/Makefile | 9 | ||||
-rw-r--r-- | security/rainbowcrack/files/patch-HashAlgorithm.cpp | 16 | ||||
-rw-r--r-- | security/rainbowcrack/files/patch-HashAlgorithm.h | 7 | ||||
-rw-r--r-- | security/rainbowcrack/files/patch-HashRoutine.cpp | 7 | ||||
-rw-r--r-- | security/rainbowcrack/files/patch-Public.h | 11 | ||||
-rw-r--r-- | security/rainbowcrack/files/patch-RainbowTableDump.cpp | 10 | ||||
-rw-r--r-- | security/rainbowcrack/files/patch-RainbowTableGenerate.cpp | 10 | ||||
-rw-r--r-- | security/rainbowcrack/files/patch-RainbowTableSort.cpp | 10 | ||||
-rw-r--r-- | security/rainbowcrack/pkg-plist | 4 |
9 files changed, 58 insertions, 26 deletions
diff --git a/security/rainbowcrack/Makefile b/security/rainbowcrack/Makefile index e2d754c71c9e..d1ded4a2620b 100644 --- a/security/rainbowcrack/Makefile +++ b/security/rainbowcrack/Makefile @@ -6,12 +6,11 @@ PORTVERSION= 1.2 CATEGORIES= security MASTER_SITES= http://www.semprixd.com/shares/ports/ -MAINTAINER= ports@FreeBSD.org +MAINTAINER= ports@FreeBSD.org COMMENT= Hash cracker that precomputes plaintext - ciphertext pairs in advance USES= dos2unix -NO_STAGE= yes .include <bsd.port.pre.mk> .if ${ARCH} == "ia64" || ${ARCH} == "powerpc" || ${ARCH} == "sparc64" @@ -24,9 +23,9 @@ post-patch: do-install: .for f in rcrack rtgen rtdump rtsort - ${INSTALL_PROGRAM} ${WRKSRC}/${f} ${PREFIX}/bin + ${INSTALL_PROGRAM} ${WRKSRC}/${f} ${STAGEDIR}${PREFIX}/bin .endfor - ${MKDIR} ${EXAMPLESDIR} - ${INSTALL_DATA} ${WRKSRC}/charset.txt ${EXAMPLESDIR} + ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} + ${INSTALL_DATA} ${WRKSRC}/charset.txt ${STAGEDIR}${EXAMPLESDIR} .include <bsd.port.post.mk> diff --git a/security/rainbowcrack/files/patch-HashAlgorithm.cpp b/security/rainbowcrack/files/patch-HashAlgorithm.cpp index 31c061fe9aa6..bdc9c9805772 100644 --- a/security/rainbowcrack/files/patch-HashAlgorithm.cpp +++ b/security/rainbowcrack/files/patch-HashAlgorithm.cpp @@ -1,13 +1,12 @@ ---- ./HashAlgorithm.cpp.orig 2008-07-22 20:31:14.000000000 -0400 -+++ ./HashAlgorithm.cpp 2008-07-22 20:35:25.000000000 -0400 -@@ -6,9 +6,14 @@ +--- HashAlgorithm.cpp.orig 2014-07-31 12:12:45.000000000 -0400 ++++ HashAlgorithm.cpp 2014-07-31 12:21:30.000000000 -0400 +@@ -6,9 +6,13 @@ #include "HashAlgorithm.h" +#include "Public.h" + #include <openssl/des.h> -+#include <openssl/md2.h> +#include <openssl/md4.h> #include <openssl/md5.h> #include <openssl/sha.h> @@ -15,7 +14,7 @@ #ifdef _WIN32 #pragma comment(lib, "libeay32.lib") #endif -@@ -48,6 +53,30 @@ +@@ -48,6 +52,25 @@ des_ecb_encrypt((des_cblock*)magic, (des_cblock*)pHash, ks, DES_ENCRYPT); } @@ -33,11 +32,6 @@ + MD4(UnicodePlain, nPlainLen * 2, pHash); +} + -+void HashMD2(unsigned char* pPlain, int nPlainLen, unsigned char* pHash) -+{ -+ MD2(pPlain, nPlainLen, pHash); -+} -+ +void HashMD4(unsigned char* pPlain, int nPlainLen, unsigned char* pHash) +{ + MD4(pPlain, nPlainLen, pHash); @@ -46,7 +40,7 @@ void HashMD5(unsigned char* pPlain, int nPlainLen, unsigned char* pHash) { MD5(pPlain, nPlainLen, pHash); -@@ -57,3 +86,9 @@ +@@ -57,3 +80,9 @@ { SHA1(pPlain, nPlainLen, pHash); } diff --git a/security/rainbowcrack/files/patch-HashAlgorithm.h b/security/rainbowcrack/files/patch-HashAlgorithm.h index bcf5e2b7923e..600086b3a78d 100644 --- a/security/rainbowcrack/files/patch-HashAlgorithm.h +++ b/security/rainbowcrack/files/patch-HashAlgorithm.h @@ -1,12 +1,11 @@ ---- ./HashAlgorithm.h.orig 2008-07-22 20:30:34.000000000 -0400 -+++ ./HashAlgorithm.h 2008-07-22 20:31:07.000000000 -0400 -@@ -8,7 +8,13 @@ +--- HashAlgorithm.h.orig 2014-07-31 12:12:45.000000000 -0400 ++++ HashAlgorithm.h 2014-07-31 12:21:55.000000000 -0400 +@@ -8,7 +8,12 @@ #define _HASHALGORITHM_H void HashLM(unsigned char* pPlain, int nPlainLen, unsigned char* pHash); +void HashNTLM(unsigned char* pPlain, int nPlainLen, unsigned char* pHash); + -+void HashMD2(unsigned char* pPlain, int nPlainLen, unsigned char* pHash); +void HashMD4(unsigned char* pPlain, int nPlainLen, unsigned char* pHash); void HashMD5(unsigned char* pPlain, int nPlainLen, unsigned char* pHash); + diff --git a/security/rainbowcrack/files/patch-HashRoutine.cpp b/security/rainbowcrack/files/patch-HashRoutine.cpp index e94c5bc6bc20..3269d077752d 100644 --- a/security/rainbowcrack/files/patch-HashRoutine.cpp +++ b/security/rainbowcrack/files/patch-HashRoutine.cpp @@ -1,11 +1,10 @@ ---- ./HashRoutine.cpp.orig 2008-07-22 20:27:54.000000000 -0400 -+++ ./HashRoutine.cpp 2008-07-22 20:28:34.000000000 -0400 -@@ -18,8 +18,12 @@ +--- HashRoutine.cpp.orig 2014-07-31 12:12:45.000000000 -0400 ++++ HashRoutine.cpp 2014-07-31 12:20:45.000000000 -0400 +@@ -18,8 +18,11 @@ // Notice: MIN_HASH_LEN <= nHashLen <= MAX_HASH_LEN AddHashRoutine("lm", HashLM, 8); + AddHashRoutine("ntlm", HashNTLM, 16); -+ AddHashRoutine("md2", HashMD2, 16); + AddHashRoutine("md4", HashMD4, 16); AddHashRoutine("md5", HashMD5, 16); AddHashRoutine("sha1", HashSHA1, 20); diff --git a/security/rainbowcrack/files/patch-Public.h b/security/rainbowcrack/files/patch-Public.h new file mode 100644 index 000000000000..29d4aff64ae7 --- /dev/null +++ b/security/rainbowcrack/files/patch-Public.h @@ -0,0 +1,11 @@ +--- Public.h.orig 2014-07-31 12:15:30.000000000 -0400 ++++ Public.h 2014-07-31 12:15:56.000000000 -0400 +@@ -12,6 +12,8 @@ + #include <string> + #include <vector> + #include <list> ++#include <sys/types.h> ++ + using namespace std; + + #ifdef _WIN32 diff --git a/security/rainbowcrack/files/patch-RainbowTableDump.cpp b/security/rainbowcrack/files/patch-RainbowTableDump.cpp new file mode 100644 index 000000000000..9f934830563f --- /dev/null +++ b/security/rainbowcrack/files/patch-RainbowTableDump.cpp @@ -0,0 +1,10 @@ +--- RainbowTableDump.cpp.orig 2014-07-31 12:22:38.000000000 -0400 ++++ RainbowTableDump.cpp 2014-07-31 12:22:51.000000000 -0400 +@@ -5,6 +5,7 @@ + */ + + #include "ChainWalkContext.h" ++#include <stdlib.h> + + int main(int argc, char* argv[]) + { diff --git a/security/rainbowcrack/files/patch-RainbowTableGenerate.cpp b/security/rainbowcrack/files/patch-RainbowTableGenerate.cpp new file mode 100644 index 000000000000..5364a0249b9d --- /dev/null +++ b/security/rainbowcrack/files/patch-RainbowTableGenerate.cpp @@ -0,0 +1,10 @@ +--- RainbowTableGenerate.cpp.orig 2014-07-31 12:14:05.000000000 -0400 ++++ RainbowTableGenerate.cpp 2014-07-31 12:14:24.000000000 -0400 +@@ -14,6 +14,7 @@ + #include <unistd.h> + #endif + #include <time.h> ++#include <stdlib.h> + + #include "ChainWalkContext.h" + diff --git a/security/rainbowcrack/files/patch-RainbowTableSort.cpp b/security/rainbowcrack/files/patch-RainbowTableSort.cpp new file mode 100644 index 000000000000..fdbb0f157a9b --- /dev/null +++ b/security/rainbowcrack/files/patch-RainbowTableSort.cpp @@ -0,0 +1,10 @@ +--- RainbowTableSort.cpp.orig 2014-07-31 12:23:47.000000000 -0400 ++++ RainbowTableSort.cpp 2014-07-31 12:23:58.000000000 -0400 +@@ -5,6 +5,7 @@ + */ + + #include "Public.h" ++#include <stdlib.h> + + #define ASSUMED_MIN_MEMORY 32 * 1024 * 1024 + diff --git a/security/rainbowcrack/pkg-plist b/security/rainbowcrack/pkg-plist index 7301f80ee5d9..646875107a9f 100644 --- a/security/rainbowcrack/pkg-plist +++ b/security/rainbowcrack/pkg-plist @@ -2,5 +2,5 @@ bin/rcrack bin/rtgen bin/rtdump bin/rtsort -%%EXAMPLESDIR%%/charset.txt -@dirrm %%EXAMPLESDIR%% +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/charset.txt +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%% |