2 * Author......: Jens Steube <jens.steube@gmail.com>
10 #include "include/constants.h"
11 #include "include/kernel_vendor.h"
18 #include "include/kernel_functions.c"
19 #include "OpenCL/types_ocl.c"
20 #include "OpenCL/common.c"
21 #include "OpenCL/simd.c"
23 __constant u32 k_sha256[64] =
25 SHA256C00, SHA256C01, SHA256C02, SHA256C03,
26 SHA256C04, SHA256C05, SHA256C06, SHA256C07,
27 SHA256C08, SHA256C09, SHA256C0a, SHA256C0b,
28 SHA256C0c, SHA256C0d, SHA256C0e, SHA256C0f,
29 SHA256C10, SHA256C11, SHA256C12, SHA256C13,
30 SHA256C14, SHA256C15, SHA256C16, SHA256C17,
31 SHA256C18, SHA256C19, SHA256C1a, SHA256C1b,
32 SHA256C1c, SHA256C1d, SHA256C1e, SHA256C1f,
33 SHA256C20, SHA256C21, SHA256C22, SHA256C23,
34 SHA256C24, SHA256C25, SHA256C26, SHA256C27,
35 SHA256C28, SHA256C29, SHA256C2a, SHA256C2b,
36 SHA256C2c, SHA256C2d, SHA256C2e, SHA256C2f,
37 SHA256C30, SHA256C31, SHA256C32, SHA256C33,
38 SHA256C34, SHA256C35, SHA256C36, SHA256C37,
39 SHA256C38, SHA256C39, SHA256C3a, SHA256C3b,
40 SHA256C3c, SHA256C3d, SHA256C3e, SHA256C3f,
43 static void sha256_transform (const u32 w0[4], const u32 w1[4], const u32 w2[4], const u32 w3[4], u32 digest[8])
71 #define ROUND_EXPAND() \
73 w0_t = SHA256_EXPAND (we_t, w9_t, w1_t, w0_t); \
74 w1_t = SHA256_EXPAND (wf_t, wa_t, w2_t, w1_t); \
75 w2_t = SHA256_EXPAND (w0_t, wb_t, w3_t, w2_t); \
76 w3_t = SHA256_EXPAND (w1_t, wc_t, w4_t, w3_t); \
77 w4_t = SHA256_EXPAND (w2_t, wd_t, w5_t, w4_t); \
78 w5_t = SHA256_EXPAND (w3_t, we_t, w6_t, w5_t); \
79 w6_t = SHA256_EXPAND (w4_t, wf_t, w7_t, w6_t); \
80 w7_t = SHA256_EXPAND (w5_t, w0_t, w8_t, w7_t); \
81 w8_t = SHA256_EXPAND (w6_t, w1_t, w9_t, w8_t); \
82 w9_t = SHA256_EXPAND (w7_t, w2_t, wa_t, w9_t); \
83 wa_t = SHA256_EXPAND (w8_t, w3_t, wb_t, wa_t); \
84 wb_t = SHA256_EXPAND (w9_t, w4_t, wc_t, wb_t); \
85 wc_t = SHA256_EXPAND (wa_t, w5_t, wd_t, wc_t); \
86 wd_t = SHA256_EXPAND (wb_t, w6_t, we_t, wd_t); \
87 we_t = SHA256_EXPAND (wc_t, w7_t, wf_t, we_t); \
88 wf_t = SHA256_EXPAND (wd_t, w8_t, w0_t, wf_t); \
91 #define ROUND_STEP(i) \
93 SHA256_STEP (SHA256_F0o, SHA256_F1o, a, b, c, d, e, f, g, h, w0_t, k_sha256[i + 0]); \
94 SHA256_STEP (SHA256_F0o, SHA256_F1o, h, a, b, c, d, e, f, g, w1_t, k_sha256[i + 1]); \
95 SHA256_STEP (SHA256_F0o, SHA256_F1o, g, h, a, b, c, d, e, f, w2_t, k_sha256[i + 2]); \
96 SHA256_STEP (SHA256_F0o, SHA256_F1o, f, g, h, a, b, c, d, e, w3_t, k_sha256[i + 3]); \
97 SHA256_STEP (SHA256_F0o, SHA256_F1o, e, f, g, h, a, b, c, d, w4_t, k_sha256[i + 4]); \
98 SHA256_STEP (SHA256_F0o, SHA256_F1o, d, e, f, g, h, a, b, c, w5_t, k_sha256[i + 5]); \
99 SHA256_STEP (SHA256_F0o, SHA256_F1o, c, d, e, f, g, h, a, b, w6_t, k_sha256[i + 6]); \
100 SHA256_STEP (SHA256_F0o, SHA256_F1o, b, c, d, e, f, g, h, a, w7_t, k_sha256[i + 7]); \
101 SHA256_STEP (SHA256_F0o, SHA256_F1o, a, b, c, d, e, f, g, h, w8_t, k_sha256[i + 8]); \
102 SHA256_STEP (SHA256_F0o, SHA256_F1o, h, a, b, c, d, e, f, g, w9_t, k_sha256[i + 9]); \
103 SHA256_STEP (SHA256_F0o, SHA256_F1o, g, h, a, b, c, d, e, f, wa_t, k_sha256[i + 10]); \
104 SHA256_STEP (SHA256_F0o, SHA256_F1o, f, g, h, a, b, c, d, e, wb_t, k_sha256[i + 11]); \
105 SHA256_STEP (SHA256_F0o, SHA256_F1o, e, f, g, h, a, b, c, d, wc_t, k_sha256[i + 12]); \
106 SHA256_STEP (SHA256_F0o, SHA256_F1o, d, e, f, g, h, a, b, c, wd_t, k_sha256[i + 13]); \
107 SHA256_STEP (SHA256_F0o, SHA256_F1o, c, d, e, f, g, h, a, b, we_t, k_sha256[i + 14]); \
108 SHA256_STEP (SHA256_F0o, SHA256_F1o, b, c, d, e, f, g, h, a, wf_t, k_sha256[i + 15]); \
114 for (int i = 16; i < 64; i += 16)
116 ROUND_EXPAND (); ROUND_STEP (i);
129 static void hmac_sha256_pad (u32 w0[4], u32 w1[4], u32 w2[4], u32 w3[4], u32 ipad[8], u32 opad[8])
131 w0[0] = w0[0] ^ 0x36363636;
132 w0[1] = w0[1] ^ 0x36363636;
133 w0[2] = w0[2] ^ 0x36363636;
134 w0[3] = w0[3] ^ 0x36363636;
135 w1[0] = w1[0] ^ 0x36363636;
136 w1[1] = w1[1] ^ 0x36363636;
137 w1[2] = w1[2] ^ 0x36363636;
138 w1[3] = w1[3] ^ 0x36363636;
139 w2[0] = w2[0] ^ 0x36363636;
140 w2[1] = w2[1] ^ 0x36363636;
141 w2[2] = w2[2] ^ 0x36363636;
142 w2[3] = w2[3] ^ 0x36363636;
143 w3[0] = w3[0] ^ 0x36363636;
144 w3[1] = w3[1] ^ 0x36363636;
145 w3[2] = w3[2] ^ 0x36363636;
146 w3[3] = w3[3] ^ 0x36363636;
157 sha256_transform (w0, w1, w2, w3, ipad);
159 w0[0] = w0[0] ^ 0x6a6a6a6a;
160 w0[1] = w0[1] ^ 0x6a6a6a6a;
161 w0[2] = w0[2] ^ 0x6a6a6a6a;
162 w0[3] = w0[3] ^ 0x6a6a6a6a;
163 w1[0] = w1[0] ^ 0x6a6a6a6a;
164 w1[1] = w1[1] ^ 0x6a6a6a6a;
165 w1[2] = w1[2] ^ 0x6a6a6a6a;
166 w1[3] = w1[3] ^ 0x6a6a6a6a;
167 w2[0] = w2[0] ^ 0x6a6a6a6a;
168 w2[1] = w2[1] ^ 0x6a6a6a6a;
169 w2[2] = w2[2] ^ 0x6a6a6a6a;
170 w2[3] = w2[3] ^ 0x6a6a6a6a;
171 w3[0] = w3[0] ^ 0x6a6a6a6a;
172 w3[1] = w3[1] ^ 0x6a6a6a6a;
173 w3[2] = w3[2] ^ 0x6a6a6a6a;
174 w3[3] = w3[3] ^ 0x6a6a6a6a;
185 sha256_transform (w0, w1, w2, w3, opad);
188 static void hmac_sha256_run (u32 w0[4], u32 w1[4], u32 w2[4], u32 w3[4], u32 ipad[8], u32 opad[8], u32 digest[8])
199 sha256_transform (w0, w1, w2, w3, digest);
216 w3[3] = (64 + 32) * 8;
227 sha256_transform (w0, w1, w2, w3, digest);
230 __kernel void m01450_m04 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __global bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV_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 combs_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
236 const u32 lid = get_local_id (0);
242 const u32 gid = get_global_id (0);
244 if (gid >= gid_max) return;
249 pws0[0] = pws[gid].i[0];
250 pws0[1] = pws[gid].i[1];
251 pws0[2] = pws[gid].i[2];
252 pws0[3] = pws[gid].i[3];
253 pws1[0] = pws[gid].i[4];
254 pws1[1] = pws[gid].i[5];
255 pws1[2] = pws[gid].i[6];
256 pws1[3] = pws[gid].i[7];
258 const u32 pw_l_len = pws[gid].pw_len;
266 salt_buf0[0] = salt_bufs[salt_pos].salt_buf[ 0];
267 salt_buf0[1] = salt_bufs[salt_pos].salt_buf[ 1];
268 salt_buf0[2] = salt_bufs[salt_pos].salt_buf[ 2];
269 salt_buf0[3] = salt_bufs[salt_pos].salt_buf[ 3];
273 salt_buf1[0] = salt_bufs[salt_pos].salt_buf[ 4];
274 salt_buf1[1] = salt_bufs[salt_pos].salt_buf[ 5];
275 salt_buf1[2] = salt_bufs[salt_pos].salt_buf[ 6];
276 salt_buf1[3] = salt_bufs[salt_pos].salt_buf[ 7];
278 const u32 salt_len = salt_bufs[salt_pos].salt_len;
284 for (u32 il_pos = 0; il_pos < combs_cnt; il_pos += VECT_SIZE)
286 const u32x pw_r_len = pwlenx_create_combt (combs_buf, il_pos);
288 const u32x pw_len = pw_l_len + pw_r_len;
290 u32x wordr0[4] = { 0 };
291 u32x wordr1[4] = { 0 };
292 u32x wordr2[4] = { 0 };
293 u32x wordr3[4] = { 0 };
295 wordr0[0] = ix_create_combt (combs_buf, il_pos, 0);
296 wordr0[1] = ix_create_combt (combs_buf, il_pos, 1);
297 wordr0[2] = ix_create_combt (combs_buf, il_pos, 2);
298 wordr0[3] = ix_create_combt (combs_buf, il_pos, 3);
299 wordr1[0] = ix_create_combt (combs_buf, il_pos, 4);
300 wordr1[1] = ix_create_combt (combs_buf, il_pos, 5);
301 wordr1[2] = ix_create_combt (combs_buf, il_pos, 6);
302 wordr1[3] = ix_create_combt (combs_buf, il_pos, 7);
304 if (combs_mode == COMBINATOR_MODE_BASE_LEFT)
306 switch_buffer_by_offset_le (wordr0, wordr1, wordr2, wordr3, pw_l_len);
311 w0[0] = wordl0[0] | wordr0[0];
312 w0[1] = wordl0[1] | wordr0[1];
313 w0[2] = wordl0[2] | wordr0[2];
314 w0[3] = wordl0[3] | wordr0[3];
318 w1[0] = wordl1[0] | wordr1[0];
319 w1[1] = wordl1[1] | wordr1[1];
320 w1[2] = wordl1[2] | wordr1[2];
321 w1[3] = wordl1[3] | wordr1[3];
325 w2[0] = wordl2[0] | wordr2[0];
326 w2[1] = wordl2[1] | wordr2[1];
327 w2[2] = wordl2[2] | wordr2[2];
328 w2[3] = wordl2[3] | wordr2[3];
332 w3[0] = wordl3[0] | wordr3[0];
333 w3[1] = wordl3[1] | wordr3[1];
334 w3[2] = wordl3[2] | wordr3[2];
335 w3[3] = wordl3[3] | wordr3[3];
343 w0_t[0] = swap32 (w0[0]);
344 w0_t[1] = swap32 (w0[1]);
345 w0_t[2] = swap32 (w0[2]);
346 w0_t[3] = swap32 (w0[3]);
350 w1_t[0] = swap32 (w1[0]);
351 w1_t[1] = swap32 (w1[1]);
352 w1_t[2] = swap32 (w1[2]);
353 w1_t[3] = swap32 (w1[3]);
372 hmac_sha256_pad (w0_t, w1_t, w2_t, w3_t, ipad, opad);
374 w0_t[0] = swap32 (salt_buf0[0]);
375 w0_t[1] = swap32 (salt_buf0[1]);
376 w0_t[2] = swap32 (salt_buf0[2]);
377 w0_t[3] = swap32 (salt_buf0[3]);
378 w1_t[0] = swap32 (salt_buf1[0]);
379 w1_t[1] = swap32 (salt_buf1[1]);
380 w1_t[2] = swap32 (salt_buf1[2]);
381 w1_t[3] = swap32 (salt_buf1[3]);
389 w3_t[3] = (64 + salt_len) * 8;
393 hmac_sha256_run (w0_t, w1_t, w2_t, w3_t, ipad, opad, digest);
395 COMPARE_M_SIMD (digest[3], digest[7], digest[2], digest[6]);
399 __kernel void m01450_m08 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __global bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV_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 combs_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
403 __kernel void m01450_m16 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __global bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV_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 combs_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
407 __kernel void m01450_s04 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __global bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV_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 combs_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
413 const u32 lid = get_local_id (0);
419 const u32 gid = get_global_id (0);
421 if (gid >= gid_max) return;
426 pws0[0] = pws[gid].i[0];
427 pws0[1] = pws[gid].i[1];
428 pws0[2] = pws[gid].i[2];
429 pws0[3] = pws[gid].i[3];
430 pws1[0] = pws[gid].i[4];
431 pws1[1] = pws[gid].i[5];
432 pws1[2] = pws[gid].i[6];
433 pws1[3] = pws[gid].i[7];
435 const u32 pw_l_len = pws[gid].pw_len;
443 salt_buf0[0] = salt_bufs[salt_pos].salt_buf[ 0];
444 salt_buf0[1] = salt_bufs[salt_pos].salt_buf[ 1];
445 salt_buf0[2] = salt_bufs[salt_pos].salt_buf[ 2];
446 salt_buf0[3] = salt_bufs[salt_pos].salt_buf[ 3];
450 salt_buf1[0] = salt_bufs[salt_pos].salt_buf[ 4];
451 salt_buf1[1] = salt_bufs[salt_pos].salt_buf[ 5];
452 salt_buf1[2] = salt_bufs[salt_pos].salt_buf[ 6];
453 salt_buf1[3] = salt_bufs[salt_pos].salt_buf[ 7];
455 const u32 salt_len = salt_bufs[salt_pos].salt_len;
461 const u32 search[4] =
463 digests_buf[digests_offset].digest_buf[DGST_R0],
464 digests_buf[digests_offset].digest_buf[DGST_R1],
465 digests_buf[digests_offset].digest_buf[DGST_R2],
466 digests_buf[digests_offset].digest_buf[DGST_R3]
473 for (u32 il_pos = 0; il_pos < combs_cnt; il_pos += VECT_SIZE)
475 const u32x pw_r_len = pwlenx_create_combt (combs_buf, il_pos);
477 const u32x pw_len = pw_l_len + pw_r_len;
479 u32x wordr0[4] = { 0 };
480 u32x wordr1[4] = { 0 };
481 u32x wordr2[4] = { 0 };
482 u32x wordr3[4] = { 0 };
484 wordr0[0] = ix_create_combt (combs_buf, il_pos, 0);
485 wordr0[1] = ix_create_combt (combs_buf, il_pos, 1);
486 wordr0[2] = ix_create_combt (combs_buf, il_pos, 2);
487 wordr0[3] = ix_create_combt (combs_buf, il_pos, 3);
488 wordr1[0] = ix_create_combt (combs_buf, il_pos, 4);
489 wordr1[1] = ix_create_combt (combs_buf, il_pos, 5);
490 wordr1[2] = ix_create_combt (combs_buf, il_pos, 6);
491 wordr1[3] = ix_create_combt (combs_buf, il_pos, 7);
493 if (combs_mode == COMBINATOR_MODE_BASE_LEFT)
495 switch_buffer_by_offset_le (wordr0, wordr1, wordr2, wordr3, pw_l_len);
500 w0[0] = wordl0[0] | wordr0[0];
501 w0[1] = wordl0[1] | wordr0[1];
502 w0[2] = wordl0[2] | wordr0[2];
503 w0[3] = wordl0[3] | wordr0[3];
507 w1[0] = wordl1[0] | wordr1[0];
508 w1[1] = wordl1[1] | wordr1[1];
509 w1[2] = wordl1[2] | wordr1[2];
510 w1[3] = wordl1[3] | wordr1[3];
514 w2[0] = wordl2[0] | wordr2[0];
515 w2[1] = wordl2[1] | wordr2[1];
516 w2[2] = wordl2[2] | wordr2[2];
517 w2[3] = wordl2[3] | wordr2[3];
521 w3[0] = wordl3[0] | wordr3[0];
522 w3[1] = wordl3[1] | wordr3[1];
523 w3[2] = wordl3[2] | wordr3[2];
524 w3[3] = wordl3[3] | wordr3[3];
532 w0_t[0] = swap32 (w0[0]);
533 w0_t[1] = swap32 (w0[1]);
534 w0_t[2] = swap32 (w0[2]);
535 w0_t[3] = swap32 (w0[3]);
539 w1_t[0] = swap32 (w1[0]);
540 w1_t[1] = swap32 (w1[1]);
541 w1_t[2] = swap32 (w1[2]);
542 w1_t[3] = swap32 (w1[3]);
561 hmac_sha256_pad (w0_t, w1_t, w2_t, w3_t, ipad, opad);
563 w0_t[0] = swap32 (salt_buf0[0]);
564 w0_t[1] = swap32 (salt_buf0[1]);
565 w0_t[2] = swap32 (salt_buf0[2]);
566 w0_t[3] = swap32 (salt_buf0[3]);
567 w1_t[0] = swap32 (salt_buf1[0]);
568 w1_t[1] = swap32 (salt_buf1[1]);
569 w1_t[2] = swap32 (salt_buf1[2]);
570 w1_t[3] = swap32 (salt_buf1[3]);
578 w3_t[3] = (64 + salt_len) * 8;
582 hmac_sha256_run (w0_t, w1_t, w2_t, w3_t, ipad, opad, digest);
584 COMPARE_S_SIMD (digest[3], digest[7], digest[2], digest[6]);
588 __kernel void m01450_s08 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __global bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV_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 combs_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
592 __kernel void m01450_s16 (__global pw_t *pws, __global kernel_rule_t *rules_buf, __global comb_t *combs_buf, __global bf_t *bfs_buf, __global void *tmps, __global void *hooks, __global u32 *bitmaps_buf_s1_a, __global u32 *bitmaps_buf_s1_b, __global u32 *bitmaps_buf_s1_c, __global u32 *bitmaps_buf_s1_d, __global u32 *bitmaps_buf_s2_a, __global u32 *bitmaps_buf_s2_b, __global u32 *bitmaps_buf_s2_c, __global u32 *bitmaps_buf_s2_d, __global plain_t *plains_buf, __global digest_t *digests_buf, __global u32 *hashes_shown, __global salt_t *salt_bufs, __global void *esalt_bufs, __global u32 *d_return_buf, __global u32 *d_scryptV_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 combs_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)