mirror of
https://github.com/hashcat/hashcat.git
synced 2025-01-03 12:21:07 +00:00
Fix WinZip multihash
This commit is contained in:
parent
a5ec5d68b8
commit
0891989404
@ -3,7 +3,7 @@
|
||||
* License.....: MIT
|
||||
*/
|
||||
|
||||
#define _PBKDF2_SHA1_
|
||||
#define _ZIP2_
|
||||
|
||||
#include "include/constants.h"
|
||||
#include "include/kernel_vendor.h"
|
||||
@ -598,12 +598,12 @@ __kernel void m13600_comp (__global pw_t *pws, __global kernel_rule_t *rules_buf
|
||||
|
||||
hmac_sha1_run (w0, w1, w2, w3, ipad, opad, digest);
|
||||
|
||||
#define il_pos 0
|
||||
|
||||
const u32 r0 = swap32 (digest[0] & 0xffffffff);
|
||||
const u32 r1 = swap32 (digest[1] & 0xffffffff);
|
||||
const u32 r2 = swap32 (digest[2] & 0xffff0000);
|
||||
const u32 r3 = swap32 (digest[3] & 0x00000000);
|
||||
|
||||
#define il_pos 0
|
||||
|
||||
#include COMPARE_M
|
||||
}
|
||||
|
@ -664,6 +664,8 @@ typedef struct
|
||||
u32 digest_buf[4];
|
||||
#elif defined _KEEPASS_
|
||||
u32 digest_buf[4];
|
||||
#elif defined _ZIP2_
|
||||
u32 digest_buf[4];
|
||||
#endif
|
||||
|
||||
} digest_t;
|
||||
@ -905,7 +907,7 @@ typedef struct
|
||||
u32 data_len;
|
||||
u32 data_buf[2048];
|
||||
u32 auth_len;
|
||||
u32 auth_buf[5];
|
||||
u32 auth_buf[4];
|
||||
|
||||
} zip2_t;
|
||||
|
||||
|
@ -28,6 +28,7 @@
|
||||
#define _PBKDF2_SHA256_
|
||||
#define _PBKDF2_SHA512_
|
||||
#define _RAR3_
|
||||
#define _ZIP2_
|
||||
#endif
|
||||
|
||||
#ifdef _SIPHASH_
|
||||
@ -54,7 +55,7 @@
|
||||
#define BCRYPTM_5 0x6F756274u
|
||||
#endif
|
||||
|
||||
#if defined _SHA1_ || defined _SAPG_ || defined _OFFICE2007_ || defined _OFFICE2010_ || defined _OLDOFFICE34_ || defined _ANDROIDFDE_ || defined _DCC2_ || defined _WPA_ || defined _MD5_SHA1_ || defined _SHA1_MD5_ || defined _PSAFE2_ || defined _LOTUS8_ || defined _PBKDF2_SHA1_ || defined _RAR3_ || defined _SHA256_SHA1_
|
||||
#if defined _SHA1_ || defined _SAPG_ || defined _OFFICE2007_ || defined _OFFICE2010_ || defined _OLDOFFICE34_ || defined _ANDROIDFDE_ || defined _DCC2_ || defined _WPA_ || defined _MD5_SHA1_ || defined _SHA1_MD5_ || defined _PSAFE2_ || defined _LOTUS8_ || defined _PBKDF2_SHA1_ || defined _RAR3_ || defined _SHA256_SHA1_ || defined _ZIP2_
|
||||
/**
|
||||
* SHA1 Constants
|
||||
*/
|
||||
|
@ -111,7 +111,7 @@
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined _SHA1_ || defined _SAPG_ || defined _OFFICE2007_ || defined _OFFICE2010_ || defined _OLDOFFICE34_ || defined _ANDROIDFDE_ || defined _DCC2_ || defined _WPA_ || defined _MD5_SHA1_ || defined _SHA1_MD5_ || defined _PSAFE2_ || defined _LOTUS8_ || defined _PBKDF2_SHA1_ || defined _RAR3_ || defined _SHA256_SHA1_
|
||||
#if defined _SHA1_ || defined _SAPG_ || defined _OFFICE2007_ || defined _OFFICE2010_ || defined _OLDOFFICE34_ || defined _ANDROIDFDE_ || defined _DCC2_ || defined _WPA_ || defined _MD5_SHA1_ || defined _SHA1_MD5_ || defined _PSAFE2_ || defined _LOTUS8_ || defined _PBKDF2_SHA1_ || defined _RAR3_ || defined _SHA256_SHA1_ || defined _ZIP2_
|
||||
|
||||
#ifdef IS_NV
|
||||
#define SHA1_F0(x,y,z) ((z) ^ ((x) & ((y) ^ (z))))
|
||||
|
@ -278,7 +278,7 @@ typedef struct
|
||||
u32 data_len;
|
||||
u32 data_buf[2048];
|
||||
u32 auth_len;
|
||||
u32 auth_buf[5];
|
||||
u32 auth_buf[4];
|
||||
|
||||
} zip2_t;
|
||||
|
||||
|
@ -10224,9 +10224,9 @@ int main (int argc, char **argv)
|
||||
attack_exec = ATTACK_EXEC_OUTSIDE_KERNEL;
|
||||
opts_type = OPTS_TYPE_PT_GENERATE_LE;
|
||||
kern_type = KERN_TYPE_ZIP2;
|
||||
dgst_size = DGST_SIZE_4_5;
|
||||
dgst_size = DGST_SIZE_4_4;
|
||||
parse_func = zip2_parse_hash;
|
||||
sort_by_digest = sort_by_digest_4_5;
|
||||
sort_by_digest = sort_by_digest_4_4;
|
||||
opti_type = OPTI_TYPE_ZERO_BYTE;
|
||||
dgst_pos0 = 0;
|
||||
dgst_pos1 = 1;
|
||||
|
@ -20136,7 +20136,6 @@ int zip2_parse_hash (char *input_buf, uint input_len, hash_t *hash_buf)
|
||||
digest[1] = zip2->auth_buf[1];
|
||||
digest[2] = zip2->auth_buf[2];
|
||||
digest[3] = zip2->auth_buf[3];
|
||||
digest[4] = zip2->auth_buf[4];
|
||||
|
||||
return (PARSER_OK);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user