1
0
mirror of https://github.com/hashcat/hashcat.git synced 2024-11-27 02:18:21 +00:00

Refactor kernel declarations for Skip32 to enable OSX using it

This commit is contained in:
jsteube 2017-02-23 15:18:41 +01:00
parent f381b107a3
commit ba5fb80a38
3 changed files with 8 additions and 8 deletions

View File

@ -51,7 +51,7 @@ __constant u8 c_ftable[256] =
0xbd, 0xa8, 0x3a, 0x01, 0x05, 0x59, 0x2a, 0x46
};
void g (__local u8 s_ftable[256], const u32 *key, const int k, const u32 *wx, u32 *out)
void g (__local u8 *s_ftable, const u32 *key, const int k, const u32 *wx, u32 *out)
{
const u32 g1 = wx[1];
const u32 g2 = wx[0];
@ -64,7 +64,7 @@ void g (__local u8 s_ftable[256], const u32 *key, const int k, const u32 *wx, u3
out[1] = g5;
}
u32 skip32 (__local u8 s_ftable[256], const u32 KP, const u32 *key)
u32 skip32 (__local u8 *s_ftable, const u32 KP, const u32 *key)
{
u32 wl[2];
u32 wr[2];

View File

@ -49,7 +49,7 @@ __constant u8 c_ftable[256] =
0xbd, 0xa8, 0x3a, 0x01, 0x05, 0x59, 0x2a, 0x46
};
void g (__local u8 s_ftable[256], const u32 *key, const int k, const u32 *wx, u32 *out)
void g (__local u8 *s_ftable, const u32 *key, const int k, const u32 *wx, u32 *out)
{
const u32 g1 = wx[1];
const u32 g2 = wx[0];
@ -62,7 +62,7 @@ void g (__local u8 s_ftable[256], const u32 *key, const int k, const u32 *wx, u3
out[1] = g5;
}
u32 skip32 (__local u8 s_ftable[256], const u32 KP, const u32 *key)
u32 skip32 (__local u8 *s_ftable, const u32 KP, const u32 *key)
{
u32 wl[2];
u32 wr[2];

View File

@ -49,7 +49,7 @@ __constant u8 c_ftable[256] =
0xbd, 0xa8, 0x3a, 0x01, 0x05, 0x59, 0x2a, 0x46
};
void g (__local u8 s_ftable[256], const u32 *key, const int k, const u32 *wx, u32 *out)
void g (__local u8 *s_ftable, const u32 *key, const int k, const u32 *wx, u32 *out)
{
const u32 g1 = wx[1];
const u32 g2 = wx[0];
@ -62,7 +62,7 @@ void g (__local u8 s_ftable[256], const u32 *key, const int k, const u32 *wx, u3
out[1] = g5;
}
u32 skip32 (__local u8 s_ftable[256], const u32 KP, const u32 *key)
u32 skip32 (__local u8 *s_ftable, const u32 KP, const u32 *key)
{
u32 wl[2];
u32 wr[2];
@ -102,7 +102,7 @@ u32 skip32 (__local u8 s_ftable[256], const u32 KP, const u32 *key)
return r;
}
void m14900m (__local u8 s_ftable[256], u32 w0[4], u32 w1[4], u32 w2[4], u32 w3[4], const u32 pw_len, __global pw_t *pws, __global const kernel_rule_t *rules_buf, __global const comb_t *combs_buf, __global const bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global const u32 *bitmaps_buf_s1_a, __global const u32 *bitmaps_buf_s1_b, __global const u32 *bitmaps_buf_s1_c, __global const u32 *bitmaps_buf_s1_d, __global const u32 *bitmaps_buf_s2_a, __global const u32 *bitmaps_buf_s2_b, __global const u32 *bitmaps_buf_s2_c, __global const u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global const digest_t *digests_buf, __global u32 *hashes_shown, __global const salt_t *salt_bufs, __global oldoffice01_t *oldoffice01_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset)
void m14900m (__local u8 *s_ftable, u32 w0[4], u32 w1[4], u32 w2[4], u32 w3[4], const u32 pw_len, __global pw_t *pws, __global const kernel_rule_t *rules_buf, __global const comb_t *combs_buf, __global const bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global const u32 *bitmaps_buf_s1_a, __global const u32 *bitmaps_buf_s1_b, __global const u32 *bitmaps_buf_s1_c, __global const u32 *bitmaps_buf_s1_d, __global const u32 *bitmaps_buf_s2_a, __global const u32 *bitmaps_buf_s2_b, __global const u32 *bitmaps_buf_s2_c, __global const u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global const digest_t *digests_buf, __global u32 *hashes_shown, __global const salt_t *salt_bufs, __global oldoffice01_t *oldoffice01_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset)
{
/**
* modifier
@ -150,7 +150,7 @@ void m14900m (__local u8 s_ftable[256], u32 w0[4], u32 w1[4], u32 w2[4], u32 w3[
}
}
void m14900s (__local u8 s_ftable[256], u32 w0[4], u32 w1[4], u32 w2[4], u32 w3[4], const u32 pw_len, __global pw_t *pws, __global const kernel_rule_t *rules_buf, __global const comb_t *combs_buf, __global const bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global const u32 *bitmaps_buf_s1_a, __global const u32 *bitmaps_buf_s1_b, __global const u32 *bitmaps_buf_s1_c, __global const u32 *bitmaps_buf_s1_d, __global const u32 *bitmaps_buf_s2_a, __global const u32 *bitmaps_buf_s2_b, __global const u32 *bitmaps_buf_s2_c, __global const u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global const digest_t *digests_buf, __global u32 *hashes_shown, __global const salt_t *salt_bufs, __global oldoffice01_t *oldoffice01_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset)
void m14900s (__local u8 *s_ftable, u32 w0[4], u32 w1[4], u32 w2[4], u32 w3[4], const u32 pw_len, __global pw_t *pws, __global const kernel_rule_t *rules_buf, __global const comb_t *combs_buf, __global const bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global const u32 *bitmaps_buf_s1_a, __global const u32 *bitmaps_buf_s1_b, __global const u32 *bitmaps_buf_s1_c, __global const u32 *bitmaps_buf_s1_d, __global const u32 *bitmaps_buf_s2_a, __global const u32 *bitmaps_buf_s2_b, __global const u32 *bitmaps_buf_s2_c, __global const u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global const digest_t *digests_buf, __global u32 *hashes_shown, __global const salt_t *salt_bufs, __global oldoffice01_t *oldoffice01_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV0_buf, __global u32 *d_scryptV1_buf, __global u32 *d_scryptV2_buf, __global u32 *d_scryptV3_buf, const u32 bitmap_mask, const u32 bitmap_shift1, const u32 bitmap_shift2, const u32 salt_pos, const u32 loop_pos, const u32 loop_cnt, const u32 il_cnt, const u32 digests_cnt, const u32 digests_offset)
{
/**
* modifier