74aa5e8063bbcec0a8dfc70894a3b4b436c437fb
[hashcat.git] / OpenCL / m03710_a0.cl
1 /**
2  * Authors.....: Jens Steube <jens.steube@gmail.com>
3  *               magnum <john.magnum@hushmail.com>
4  *
5  * License.....: MIT
6  */
7
8 #define _MD5_
9
10 #define NEW_SIMD_CODE
11
12 #include "inc_hash_constants.h"
13 #include "inc_vendor.cl"
14
15 #define DGST_R0 0
16 #define DGST_R1 3
17 #define DGST_R2 2
18 #define DGST_R3 1
19
20 #include "inc_hash_functions.cl"
21 #include "inc_types.cl"
22 #include "inc_common.cl"
23 #include "inc_rp.h"
24 #include "inc_rp.cl"
25 #include "inc_simd.cl"
26
27 #if   VECT_SIZE == 1
28 #define uint_to_hex_lower8(i) (u32x) (l_bin2asc[(i)])
29 #elif VECT_SIZE == 2
30 #define uint_to_hex_lower8(i) (u32x) (l_bin2asc[(i).s0], l_bin2asc[(i).s1])
31 #elif VECT_SIZE == 4
32 #define uint_to_hex_lower8(i) (u32x) (l_bin2asc[(i).s0], l_bin2asc[(i).s1], l_bin2asc[(i).s2], l_bin2asc[(i).s3])
33 #elif VECT_SIZE == 8
34 #define uint_to_hex_lower8(i) (u32x) (l_bin2asc[(i).s0], l_bin2asc[(i).s1], l_bin2asc[(i).s2], l_bin2asc[(i).s3], l_bin2asc[(i).s4], l_bin2asc[(i).s5], l_bin2asc[(i).s6], l_bin2asc[(i).s7])
35 #elif VECT_SIZE == 16
36 #define uint_to_hex_lower8(i) (u32x) (l_bin2asc[(i).s0], l_bin2asc[(i).s1], l_bin2asc[(i).s2], l_bin2asc[(i).s3], l_bin2asc[(i).s4], l_bin2asc[(i).s5], l_bin2asc[(i).s6], l_bin2asc[(i).s7], l_bin2asc[(i).s8], l_bin2asc[(i).s9], l_bin2asc[(i).sa], l_bin2asc[(i).sb], l_bin2asc[(i).sc], l_bin2asc[(i).sd], l_bin2asc[(i).se], l_bin2asc[(i).sf])
37 #endif
38
39 __kernel void m03710_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 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
40 {
41   /**
42    * modifier
43    */
44
45   const u32 gid = get_global_id (0);
46   const u32 lid = get_local_id (0);
47   const u32 lsz = get_local_size (0);
48
49   /**
50    * bin2asc table
51    */
52
53   __local u32 l_bin2asc[256];
54
55   for (u32 i = lid; i < 256; i += lsz)
56   {
57     const u32 i0 = (i >> 0) & 15;
58     const u32 i1 = (i >> 4) & 15;
59
60     l_bin2asc[i] = ((i0 < 10) ? '0' + i0 : 'a' - 10 + i0) << 8
61                  | ((i1 < 10) ? '0' + i1 : 'a' - 10 + i1) << 0;
62   }
63
64   barrier (CLK_LOCAL_MEM_FENCE);
65
66   if (gid >= gid_max) return;
67
68   /**
69    * base
70    */
71
72   u32 pw_buf0[4];
73   u32 pw_buf1[4];
74
75   pw_buf0[0] = pws[gid].i[0];
76   pw_buf0[1] = pws[gid].i[1];
77   pw_buf0[2] = pws[gid].i[2];
78   pw_buf0[3] = pws[gid].i[3];
79   pw_buf1[0] = pws[gid].i[4];
80   pw_buf1[1] = pws[gid].i[5];
81   pw_buf1[2] = pws[gid].i[6];
82   pw_buf1[3] = pws[gid].i[7];
83
84   const u32 pw_len = pws[gid].pw_len;
85
86   /**
87    * salt
88    */
89
90   u32 salt_buf0[4];
91   u32 salt_buf1[4];
92   u32 salt_buf2[4];
93   u32 salt_buf3[4];
94
95   salt_buf0[0] = salt_bufs[salt_pos].salt_buf[ 0];
96   salt_buf0[1] = salt_bufs[salt_pos].salt_buf[ 1];
97   salt_buf0[2] = salt_bufs[salt_pos].salt_buf[ 2];
98   salt_buf0[3] = salt_bufs[salt_pos].salt_buf[ 3];
99   salt_buf1[0] = salt_bufs[salt_pos].salt_buf[ 4];
100   salt_buf1[1] = salt_bufs[salt_pos].salt_buf[ 5];
101   salt_buf1[2] = salt_bufs[salt_pos].salt_buf[ 6];
102   salt_buf1[3] = salt_bufs[salt_pos].salt_buf[ 7];
103   salt_buf2[0] = salt_bufs[salt_pos].salt_buf[ 8];
104   salt_buf2[1] = salt_bufs[salt_pos].salt_buf[ 9];
105   salt_buf2[2] = salt_bufs[salt_pos].salt_buf[10];
106   salt_buf2[3] = salt_bufs[salt_pos].salt_buf[11];
107   salt_buf3[0] = salt_bufs[salt_pos].salt_buf[12];
108   salt_buf3[1] = salt_bufs[salt_pos].salt_buf[13];
109   salt_buf3[2] = salt_bufs[salt_pos].salt_buf[14];
110   salt_buf3[3] = salt_bufs[salt_pos].salt_buf[15];
111
112   const u32 salt_len = salt_bufs[salt_pos].salt_len;
113
114   const u32 pw_salt_len = 32 + salt_len;
115
116   /**
117    * loop
118    */
119
120   for (u32 il_pos = 0; il_pos < il_cnt; il_pos += VECT_SIZE)
121   {
122     u32x w0[4] = { 0 };
123     u32x w1[4] = { 0 };
124     u32x w2[4] = { 0 };
125     u32x w3[4] = { 0 };
126
127     const u32x out_len = apply_rules_vect (pw_buf0, pw_buf1, pw_len, rules_buf, il_pos, w0, w1);
128
129     append_0x80_2x4_VV (w0, w1, out_len);
130
131     w3[2] = out_len * 8;
132     w3[3] = 0;
133
134     u32x a = MD5M_A;
135     u32x b = MD5M_B;
136     u32x c = MD5M_C;
137     u32x d = MD5M_D;
138
139     MD5_STEP (MD5_Fo, a, b, c, d, w0[0], MD5C00, MD5S00);
140     MD5_STEP (MD5_Fo, d, a, b, c, w0[1], MD5C01, MD5S01);
141     MD5_STEP (MD5_Fo, c, d, a, b, w0[2], MD5C02, MD5S02);
142     MD5_STEP (MD5_Fo, b, c, d, a, w0[3], MD5C03, MD5S03);
143     MD5_STEP (MD5_Fo, a, b, c, d, w1[0], MD5C04, MD5S00);
144     MD5_STEP (MD5_Fo, d, a, b, c, w1[1], MD5C05, MD5S01);
145     MD5_STEP (MD5_Fo, c, d, a, b, w1[2], MD5C06, MD5S02);
146     MD5_STEP (MD5_Fo, b, c, d, a, w1[3], MD5C07, MD5S03);
147     MD5_STEP (MD5_Fo, a, b, c, d, w2[0], MD5C08, MD5S00);
148     MD5_STEP (MD5_Fo, d, a, b, c, w2[1], MD5C09, MD5S01);
149     MD5_STEP (MD5_Fo, c, d, a, b, w2[2], MD5C0a, MD5S02);
150     MD5_STEP (MD5_Fo, b, c, d, a, w2[3], MD5C0b, MD5S03);
151     MD5_STEP (MD5_Fo, a, b, c, d, w3[0], MD5C0c, MD5S00);
152     MD5_STEP (MD5_Fo, d, a, b, c, w3[1], MD5C0d, MD5S01);
153     MD5_STEP (MD5_Fo, c, d, a, b, w3[2], MD5C0e, MD5S02);
154     MD5_STEP (MD5_Fo, b, c, d, a, w3[3], MD5C0f, MD5S03);
155
156     MD5_STEP (MD5_Go, a, b, c, d, w0[1], MD5C10, MD5S10);
157     MD5_STEP (MD5_Go, d, a, b, c, w1[2], MD5C11, MD5S11);
158     MD5_STEP (MD5_Go, c, d, a, b, w2[3], MD5C12, MD5S12);
159     MD5_STEP (MD5_Go, b, c, d, a, w0[0], MD5C13, MD5S13);
160     MD5_STEP (MD5_Go, a, b, c, d, w1[1], MD5C14, MD5S10);
161     MD5_STEP (MD5_Go, d, a, b, c, w2[2], MD5C15, MD5S11);
162     MD5_STEP (MD5_Go, c, d, a, b, w3[3], MD5C16, MD5S12);
163     MD5_STEP (MD5_Go, b, c, d, a, w1[0], MD5C17, MD5S13);
164     MD5_STEP (MD5_Go, a, b, c, d, w2[1], MD5C18, MD5S10);
165     MD5_STEP (MD5_Go, d, a, b, c, w3[2], MD5C19, MD5S11);
166     MD5_STEP (MD5_Go, c, d, a, b, w0[3], MD5C1a, MD5S12);
167     MD5_STEP (MD5_Go, b, c, d, a, w2[0], MD5C1b, MD5S13);
168     MD5_STEP (MD5_Go, a, b, c, d, w3[1], MD5C1c, MD5S10);
169     MD5_STEP (MD5_Go, d, a, b, c, w0[2], MD5C1d, MD5S11);
170     MD5_STEP (MD5_Go, c, d, a, b, w1[3], MD5C1e, MD5S12);
171     MD5_STEP (MD5_Go, b, c, d, a, w3[0], MD5C1f, MD5S13);
172
173     MD5_STEP (MD5_H , a, b, c, d, w1[1], MD5C20, MD5S20);
174     MD5_STEP (MD5_H , d, a, b, c, w2[0], MD5C21, MD5S21);
175     MD5_STEP (MD5_H , c, d, a, b, w2[3], MD5C22, MD5S22);
176     MD5_STEP (MD5_H , b, c, d, a, w3[2], MD5C23, MD5S23);
177     MD5_STEP (MD5_H , a, b, c, d, w0[1], MD5C24, MD5S20);
178     MD5_STEP (MD5_H , d, a, b, c, w1[0], MD5C25, MD5S21);
179     MD5_STEP (MD5_H , c, d, a, b, w1[3], MD5C26, MD5S22);
180     MD5_STEP (MD5_H , b, c, d, a, w2[2], MD5C27, MD5S23);
181     MD5_STEP (MD5_H , a, b, c, d, w3[1], MD5C28, MD5S20);
182     MD5_STEP (MD5_H , d, a, b, c, w0[0], MD5C29, MD5S21);
183     MD5_STEP (MD5_H , c, d, a, b, w0[3], MD5C2a, MD5S22);
184     MD5_STEP (MD5_H , b, c, d, a, w1[2], MD5C2b, MD5S23);
185     MD5_STEP (MD5_H , a, b, c, d, w2[1], MD5C2c, MD5S20);
186     MD5_STEP (MD5_H , d, a, b, c, w3[0], MD5C2d, MD5S21);
187     MD5_STEP (MD5_H , c, d, a, b, w3[3], MD5C2e, MD5S22);
188     MD5_STEP (MD5_H , b, c, d, a, w0[2], MD5C2f, MD5S23);
189
190     MD5_STEP (MD5_I , a, b, c, d, w0[0], MD5C30, MD5S30);
191     MD5_STEP (MD5_I , d, a, b, c, w1[3], MD5C31, MD5S31);
192     MD5_STEP (MD5_I , c, d, a, b, w3[2], MD5C32, MD5S32);
193     MD5_STEP (MD5_I , b, c, d, a, w1[1], MD5C33, MD5S33);
194     MD5_STEP (MD5_I , a, b, c, d, w3[0], MD5C34, MD5S30);
195     MD5_STEP (MD5_I , d, a, b, c, w0[3], MD5C35, MD5S31);
196     MD5_STEP (MD5_I , c, d, a, b, w2[2], MD5C36, MD5S32);
197     MD5_STEP (MD5_I , b, c, d, a, w0[1], MD5C37, MD5S33);
198     MD5_STEP (MD5_I , a, b, c, d, w2[0], MD5C38, MD5S30);
199     MD5_STEP (MD5_I , d, a, b, c, w3[3], MD5C39, MD5S31);
200     MD5_STEP (MD5_I , c, d, a, b, w1[2], MD5C3a, MD5S32);
201     MD5_STEP (MD5_I , b, c, d, a, w3[1], MD5C3b, MD5S33);
202     MD5_STEP (MD5_I , a, b, c, d, w1[0], MD5C3c, MD5S30);
203     MD5_STEP (MD5_I , d, a, b, c, w2[3], MD5C3d, MD5S31);
204     MD5_STEP (MD5_I , c, d, a, b, w0[2], MD5C3e, MD5S32);
205     MD5_STEP (MD5_I , b, c, d, a, w2[1], MD5C3f, MD5S33);
206
207     a += MD5M_A;
208     b += MD5M_B;
209     c += MD5M_C;
210     d += MD5M_D;
211
212     w0[0] = uint_to_hex_lower8 ((a >>  0) & 255) <<  0
213           | uint_to_hex_lower8 ((a >>  8) & 255) << 16;
214     w0[1] = uint_to_hex_lower8 ((a >> 16) & 255) <<  0
215           | uint_to_hex_lower8 ((a >> 24) & 255) << 16;
216     w0[2] = uint_to_hex_lower8 ((b >>  0) & 255) <<  0
217           | uint_to_hex_lower8 ((b >>  8) & 255) << 16;
218     w0[3] = uint_to_hex_lower8 ((b >> 16) & 255) <<  0
219           | uint_to_hex_lower8 ((b >> 24) & 255) << 16;
220     w1[0] = uint_to_hex_lower8 ((c >>  0) & 255) <<  0
221           | uint_to_hex_lower8 ((c >>  8) & 255) << 16;
222     w1[1] = uint_to_hex_lower8 ((c >> 16) & 255) <<  0
223           | uint_to_hex_lower8 ((c >> 24) & 255) << 16;
224     w1[2] = uint_to_hex_lower8 ((d >>  0) & 255) <<  0
225           | uint_to_hex_lower8 ((d >>  8) & 255) << 16;
226     w1[3] = uint_to_hex_lower8 ((d >> 16) & 255) <<  0
227           | uint_to_hex_lower8 ((d >> 24) & 255) << 16;
228     w2[0] = 0x80;
229     w2[1] = 0;
230     w2[2] = 0;
231     w2[3] = 0;
232     w3[0] = 0;
233     w3[1] = 0;
234     w3[2] = 0;
235     w3[3] = 0;
236
237     /**
238      * prepend salt
239      */
240
241     switch_buffer_by_offset_le (w0, w1, w2, w3, salt_len);
242
243     w3[2] = pw_salt_len * 8;
244     w3[3] = 0;
245
246     w0[0] |= salt_buf0[0];
247     w0[1] |= salt_buf0[1];
248     w0[2] |= salt_buf0[2];
249     w0[3] |= salt_buf0[3];
250     w1[0] |= salt_buf1[0];
251     w1[1] |= salt_buf1[1];
252     w1[2] |= salt_buf1[2];
253     w1[3] |= salt_buf1[3];
254     w2[0] |= salt_buf2[0];
255     w2[1] |= salt_buf2[1];
256     w2[2] |= salt_buf2[2];
257     w2[3] |= salt_buf2[3];
258     w3[0] |= salt_buf3[0];
259     w3[1] |= salt_buf3[1];
260     w3[2] |= salt_buf3[2];
261     w3[3] |= salt_buf3[3];
262
263     /**
264      * md5
265      */
266
267     a = MD5M_A;
268     b = MD5M_B;
269     c = MD5M_C;
270     d = MD5M_D;
271
272     MD5_STEP (MD5_Fo, a, b, c, d, w0[0], MD5C00, MD5S00);
273     MD5_STEP (MD5_Fo, d, a, b, c, w0[1], MD5C01, MD5S01);
274     MD5_STEP (MD5_Fo, c, d, a, b, w0[2], MD5C02, MD5S02);
275     MD5_STEP (MD5_Fo, b, c, d, a, w0[3], MD5C03, MD5S03);
276     MD5_STEP (MD5_Fo, a, b, c, d, w1[0], MD5C04, MD5S00);
277     MD5_STEP (MD5_Fo, d, a, b, c, w1[1], MD5C05, MD5S01);
278     MD5_STEP (MD5_Fo, c, d, a, b, w1[2], MD5C06, MD5S02);
279     MD5_STEP (MD5_Fo, b, c, d, a, w1[3], MD5C07, MD5S03);
280     MD5_STEP (MD5_Fo, a, b, c, d, w2[0], MD5C08, MD5S00);
281     MD5_STEP (MD5_Fo, d, a, b, c, w2[1], MD5C09, MD5S01);
282     MD5_STEP (MD5_Fo, c, d, a, b, w2[2], MD5C0a, MD5S02);
283     MD5_STEP (MD5_Fo, b, c, d, a, w2[3], MD5C0b, MD5S03);
284     MD5_STEP (MD5_Fo, a, b, c, d, w3[0], MD5C0c, MD5S00);
285     MD5_STEP (MD5_Fo, d, a, b, c, w3[1], MD5C0d, MD5S01);
286     MD5_STEP (MD5_Fo, c, d, a, b, w3[2], MD5C0e, MD5S02);
287     MD5_STEP (MD5_Fo, b, c, d, a, w3[3], MD5C0f, MD5S03);
288
289     MD5_STEP (MD5_Go, a, b, c, d, w0[1], MD5C10, MD5S10);
290     MD5_STEP (MD5_Go, d, a, b, c, w1[2], MD5C11, MD5S11);
291     MD5_STEP (MD5_Go, c, d, a, b, w2[3], MD5C12, MD5S12);
292     MD5_STEP (MD5_Go, b, c, d, a, w0[0], MD5C13, MD5S13);
293     MD5_STEP (MD5_Go, a, b, c, d, w1[1], MD5C14, MD5S10);
294     MD5_STEP (MD5_Go, d, a, b, c, w2[2], MD5C15, MD5S11);
295     MD5_STEP (MD5_Go, c, d, a, b, w3[3], MD5C16, MD5S12);
296     MD5_STEP (MD5_Go, b, c, d, a, w1[0], MD5C17, MD5S13);
297     MD5_STEP (MD5_Go, a, b, c, d, w2[1], MD5C18, MD5S10);
298     MD5_STEP (MD5_Go, d, a, b, c, w3[2], MD5C19, MD5S11);
299     MD5_STEP (MD5_Go, c, d, a, b, w0[3], MD5C1a, MD5S12);
300     MD5_STEP (MD5_Go, b, c, d, a, w2[0], MD5C1b, MD5S13);
301     MD5_STEP (MD5_Go, a, b, c, d, w3[1], MD5C1c, MD5S10);
302     MD5_STEP (MD5_Go, d, a, b, c, w0[2], MD5C1d, MD5S11);
303     MD5_STEP (MD5_Go, c, d, a, b, w1[3], MD5C1e, MD5S12);
304     MD5_STEP (MD5_Go, b, c, d, a, w3[0], MD5C1f, MD5S13);
305
306     MD5_STEP (MD5_H , a, b, c, d, w1[1], MD5C20, MD5S20);
307     MD5_STEP (MD5_H , d, a, b, c, w2[0], MD5C21, MD5S21);
308     MD5_STEP (MD5_H , c, d, a, b, w2[3], MD5C22, MD5S22);
309     MD5_STEP (MD5_H , b, c, d, a, w3[2], MD5C23, MD5S23);
310     MD5_STEP (MD5_H , a, b, c, d, w0[1], MD5C24, MD5S20);
311     MD5_STEP (MD5_H , d, a, b, c, w1[0], MD5C25, MD5S21);
312     MD5_STEP (MD5_H , c, d, a, b, w1[3], MD5C26, MD5S22);
313     MD5_STEP (MD5_H , b, c, d, a, w2[2], MD5C27, MD5S23);
314     MD5_STEP (MD5_H , a, b, c, d, w3[1], MD5C28, MD5S20);
315     MD5_STEP (MD5_H , d, a, b, c, w0[0], MD5C29, MD5S21);
316     MD5_STEP (MD5_H , c, d, a, b, w0[3], MD5C2a, MD5S22);
317     MD5_STEP (MD5_H , b, c, d, a, w1[2], MD5C2b, MD5S23);
318     MD5_STEP (MD5_H , a, b, c, d, w2[1], MD5C2c, MD5S20);
319     MD5_STEP (MD5_H , d, a, b, c, w3[0], MD5C2d, MD5S21);
320     MD5_STEP (MD5_H , c, d, a, b, w3[3], MD5C2e, MD5S22);
321     MD5_STEP (MD5_H , b, c, d, a, w0[2], MD5C2f, MD5S23);
322
323     MD5_STEP (MD5_I , a, b, c, d, w0[0], MD5C30, MD5S30);
324     MD5_STEP (MD5_I , d, a, b, c, w1[3], MD5C31, MD5S31);
325     MD5_STEP (MD5_I , c, d, a, b, w3[2], MD5C32, MD5S32);
326     MD5_STEP (MD5_I , b, c, d, a, w1[1], MD5C33, MD5S33);
327     MD5_STEP (MD5_I , a, b, c, d, w3[0], MD5C34, MD5S30);
328     MD5_STEP (MD5_I , d, a, b, c, w0[3], MD5C35, MD5S31);
329     MD5_STEP (MD5_I , c, d, a, b, w2[2], MD5C36, MD5S32);
330     MD5_STEP (MD5_I , b, c, d, a, w0[1], MD5C37, MD5S33);
331     MD5_STEP (MD5_I , a, b, c, d, w2[0], MD5C38, MD5S30);
332     MD5_STEP (MD5_I , d, a, b, c, w3[3], MD5C39, MD5S31);
333     MD5_STEP (MD5_I , c, d, a, b, w1[2], MD5C3a, MD5S32);
334     MD5_STEP (MD5_I , b, c, d, a, w3[1], MD5C3b, MD5S33);
335     MD5_STEP (MD5_I , a, b, c, d, w1[0], MD5C3c, MD5S30);
336     MD5_STEP (MD5_I , d, a, b, c, w2[3], MD5C3d, MD5S31);
337     MD5_STEP (MD5_I , c, d, a, b, w0[2], MD5C3e, MD5S32);
338     MD5_STEP (MD5_I , b, c, d, a, w2[1], MD5C3f, MD5S33);
339
340     COMPARE_M_SIMD (a, d, c, b);
341   }
342 }
343
344 __kernel void m03710_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 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
345 {
346 }
347
348 __kernel void m03710_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 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
349 {
350 }
351
352 __kernel void m03710_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 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
353 {
354   /**
355    * modifier
356    */
357
358   const u32 gid = get_global_id (0);
359   const u32 lid = get_local_id (0);
360   const u32 lsz = get_local_size (0);
361
362   /**
363    * bin2asc table
364    */
365
366   __local u32 l_bin2asc[256];
367
368   for (u32 i = lid; i < 256; i += lsz)
369   {
370     const u32 i0 = (i >> 0) & 15;
371     const u32 i1 = (i >> 4) & 15;
372
373     l_bin2asc[i] = ((i0 < 10) ? '0' + i0 : 'a' - 10 + i0) << 8
374                  | ((i1 < 10) ? '0' + i1 : 'a' - 10 + i1) << 0;
375   }
376
377   barrier (CLK_LOCAL_MEM_FENCE);
378
379   if (gid >= gid_max) return;
380
381   /**
382    * base
383    */
384
385   u32 pw_buf0[4];
386   u32 pw_buf1[4];
387
388   pw_buf0[0] = pws[gid].i[0];
389   pw_buf0[1] = pws[gid].i[1];
390   pw_buf0[2] = pws[gid].i[2];
391   pw_buf0[3] = pws[gid].i[3];
392   pw_buf1[0] = pws[gid].i[4];
393   pw_buf1[1] = pws[gid].i[5];
394   pw_buf1[2] = pws[gid].i[6];
395   pw_buf1[3] = pws[gid].i[7];
396
397   const u32 pw_len = pws[gid].pw_len;
398
399   /**
400    * salt
401    */
402
403   u32 salt_buf0[4];
404   u32 salt_buf1[4];
405   u32 salt_buf2[4];
406   u32 salt_buf3[4];
407
408   salt_buf0[0] = salt_bufs[salt_pos].salt_buf[ 0];
409   salt_buf0[1] = salt_bufs[salt_pos].salt_buf[ 1];
410   salt_buf0[2] = salt_bufs[salt_pos].salt_buf[ 2];
411   salt_buf0[3] = salt_bufs[salt_pos].salt_buf[ 3];
412   salt_buf1[0] = salt_bufs[salt_pos].salt_buf[ 4];
413   salt_buf1[1] = salt_bufs[salt_pos].salt_buf[ 5];
414   salt_buf1[2] = salt_bufs[salt_pos].salt_buf[ 6];
415   salt_buf1[3] = salt_bufs[salt_pos].salt_buf[ 7];
416   salt_buf2[0] = salt_bufs[salt_pos].salt_buf[ 8];
417   salt_buf2[1] = salt_bufs[salt_pos].salt_buf[ 9];
418   salt_buf2[2] = salt_bufs[salt_pos].salt_buf[10];
419   salt_buf2[3] = salt_bufs[salt_pos].salt_buf[11];
420   salt_buf3[0] = salt_bufs[salt_pos].salt_buf[12];
421   salt_buf3[1] = salt_bufs[salt_pos].salt_buf[13];
422   salt_buf3[2] = salt_bufs[salt_pos].salt_buf[14];
423   salt_buf3[3] = salt_bufs[salt_pos].salt_buf[15];
424
425   const u32 salt_len = salt_bufs[salt_pos].salt_len;
426
427   const u32 pw_salt_len = 32 + salt_len;
428
429   /**
430    * digest
431    */
432
433   const u32 search[4] =
434   {
435     digests_buf[digests_offset].digest_buf[DGST_R0],
436     digests_buf[digests_offset].digest_buf[DGST_R1],
437     digests_buf[digests_offset].digest_buf[DGST_R2],
438     digests_buf[digests_offset].digest_buf[DGST_R3]
439   };
440
441   /**
442    * loop
443    */
444
445   for (u32 il_pos = 0; il_pos < il_cnt; il_pos += VECT_SIZE)
446   {
447     u32x w0[4] = { 0 };
448     u32x w1[4] = { 0 };
449     u32x w2[4] = { 0 };
450     u32x w3[4] = { 0 };
451
452     const u32x out_len = apply_rules_vect (pw_buf0, pw_buf1, pw_len, rules_buf, il_pos, w0, w1);
453
454     append_0x80_2x4_VV (w0, w1, out_len);
455
456     w3[2] = out_len * 8;
457     w3[3] = 0;
458
459     u32x a = MD5M_A;
460     u32x b = MD5M_B;
461     u32x c = MD5M_C;
462     u32x d = MD5M_D;
463
464     MD5_STEP (MD5_Fo, a, b, c, d, w0[0], MD5C00, MD5S00);
465     MD5_STEP (MD5_Fo, d, a, b, c, w0[1], MD5C01, MD5S01);
466     MD5_STEP (MD5_Fo, c, d, a, b, w0[2], MD5C02, MD5S02);
467     MD5_STEP (MD5_Fo, b, c, d, a, w0[3], MD5C03, MD5S03);
468     MD5_STEP (MD5_Fo, a, b, c, d, w1[0], MD5C04, MD5S00);
469     MD5_STEP (MD5_Fo, d, a, b, c, w1[1], MD5C05, MD5S01);
470     MD5_STEP (MD5_Fo, c, d, a, b, w1[2], MD5C06, MD5S02);
471     MD5_STEP (MD5_Fo, b, c, d, a, w1[3], MD5C07, MD5S03);
472     MD5_STEP (MD5_Fo, a, b, c, d, w2[0], MD5C08, MD5S00);
473     MD5_STEP (MD5_Fo, d, a, b, c, w2[1], MD5C09, MD5S01);
474     MD5_STEP (MD5_Fo, c, d, a, b, w2[2], MD5C0a, MD5S02);
475     MD5_STEP (MD5_Fo, b, c, d, a, w2[3], MD5C0b, MD5S03);
476     MD5_STEP (MD5_Fo, a, b, c, d, w3[0], MD5C0c, MD5S00);
477     MD5_STEP (MD5_Fo, d, a, b, c, w3[1], MD5C0d, MD5S01);
478     MD5_STEP (MD5_Fo, c, d, a, b, w3[2], MD5C0e, MD5S02);
479     MD5_STEP (MD5_Fo, b, c, d, a, w3[3], MD5C0f, MD5S03);
480
481     MD5_STEP (MD5_Go, a, b, c, d, w0[1], MD5C10, MD5S10);
482     MD5_STEP (MD5_Go, d, a, b, c, w1[2], MD5C11, MD5S11);
483     MD5_STEP (MD5_Go, c, d, a, b, w2[3], MD5C12, MD5S12);
484     MD5_STEP (MD5_Go, b, c, d, a, w0[0], MD5C13, MD5S13);
485     MD5_STEP (MD5_Go, a, b, c, d, w1[1], MD5C14, MD5S10);
486     MD5_STEP (MD5_Go, d, a, b, c, w2[2], MD5C15, MD5S11);
487     MD5_STEP (MD5_Go, c, d, a, b, w3[3], MD5C16, MD5S12);
488     MD5_STEP (MD5_Go, b, c, d, a, w1[0], MD5C17, MD5S13);
489     MD5_STEP (MD5_Go, a, b, c, d, w2[1], MD5C18, MD5S10);
490     MD5_STEP (MD5_Go, d, a, b, c, w3[2], MD5C19, MD5S11);
491     MD5_STEP (MD5_Go, c, d, a, b, w0[3], MD5C1a, MD5S12);
492     MD5_STEP (MD5_Go, b, c, d, a, w2[0], MD5C1b, MD5S13);
493     MD5_STEP (MD5_Go, a, b, c, d, w3[1], MD5C1c, MD5S10);
494     MD5_STEP (MD5_Go, d, a, b, c, w0[2], MD5C1d, MD5S11);
495     MD5_STEP (MD5_Go, c, d, a, b, w1[3], MD5C1e, MD5S12);
496     MD5_STEP (MD5_Go, b, c, d, a, w3[0], MD5C1f, MD5S13);
497
498     MD5_STEP (MD5_H , a, b, c, d, w1[1], MD5C20, MD5S20);
499     MD5_STEP (MD5_H , d, a, b, c, w2[0], MD5C21, MD5S21);
500     MD5_STEP (MD5_H , c, d, a, b, w2[3], MD5C22, MD5S22);
501     MD5_STEP (MD5_H , b, c, d, a, w3[2], MD5C23, MD5S23);
502     MD5_STEP (MD5_H , a, b, c, d, w0[1], MD5C24, MD5S20);
503     MD5_STEP (MD5_H , d, a, b, c, w1[0], MD5C25, MD5S21);
504     MD5_STEP (MD5_H , c, d, a, b, w1[3], MD5C26, MD5S22);
505     MD5_STEP (MD5_H , b, c, d, a, w2[2], MD5C27, MD5S23);
506     MD5_STEP (MD5_H , a, b, c, d, w3[1], MD5C28, MD5S20);
507     MD5_STEP (MD5_H , d, a, b, c, w0[0], MD5C29, MD5S21);
508     MD5_STEP (MD5_H , c, d, a, b, w0[3], MD5C2a, MD5S22);
509     MD5_STEP (MD5_H , b, c, d, a, w1[2], MD5C2b, MD5S23);
510     MD5_STEP (MD5_H , a, b, c, d, w2[1], MD5C2c, MD5S20);
511     MD5_STEP (MD5_H , d, a, b, c, w3[0], MD5C2d, MD5S21);
512     MD5_STEP (MD5_H , c, d, a, b, w3[3], MD5C2e, MD5S22);
513     MD5_STEP (MD5_H , b, c, d, a, w0[2], MD5C2f, MD5S23);
514
515     MD5_STEP (MD5_I , a, b, c, d, w0[0], MD5C30, MD5S30);
516     MD5_STEP (MD5_I , d, a, b, c, w1[3], MD5C31, MD5S31);
517     MD5_STEP (MD5_I , c, d, a, b, w3[2], MD5C32, MD5S32);
518     MD5_STEP (MD5_I , b, c, d, a, w1[1], MD5C33, MD5S33);
519     MD5_STEP (MD5_I , a, b, c, d, w3[0], MD5C34, MD5S30);
520     MD5_STEP (MD5_I , d, a, b, c, w0[3], MD5C35, MD5S31);
521     MD5_STEP (MD5_I , c, d, a, b, w2[2], MD5C36, MD5S32);
522     MD5_STEP (MD5_I , b, c, d, a, w0[1], MD5C37, MD5S33);
523     MD5_STEP (MD5_I , a, b, c, d, w2[0], MD5C38, MD5S30);
524     MD5_STEP (MD5_I , d, a, b, c, w3[3], MD5C39, MD5S31);
525     MD5_STEP (MD5_I , c, d, a, b, w1[2], MD5C3a, MD5S32);
526     MD5_STEP (MD5_I , b, c, d, a, w3[1], MD5C3b, MD5S33);
527     MD5_STEP (MD5_I , a, b, c, d, w1[0], MD5C3c, MD5S30);
528     MD5_STEP (MD5_I , d, a, b, c, w2[3], MD5C3d, MD5S31);
529     MD5_STEP (MD5_I , c, d, a, b, w0[2], MD5C3e, MD5S32);
530     MD5_STEP (MD5_I , b, c, d, a, w2[1], MD5C3f, MD5S33);
531
532     a += MD5M_A;
533     b += MD5M_B;
534     c += MD5M_C;
535     d += MD5M_D;
536
537     w0[0] = uint_to_hex_lower8 ((a >>  0) & 255) <<  0
538           | uint_to_hex_lower8 ((a >>  8) & 255) << 16;
539     w0[1] = uint_to_hex_lower8 ((a >> 16) & 255) <<  0
540           | uint_to_hex_lower8 ((a >> 24) & 255) << 16;
541     w0[2] = uint_to_hex_lower8 ((b >>  0) & 255) <<  0
542           | uint_to_hex_lower8 ((b >>  8) & 255) << 16;
543     w0[3] = uint_to_hex_lower8 ((b >> 16) & 255) <<  0
544           | uint_to_hex_lower8 ((b >> 24) & 255) << 16;
545     w1[0] = uint_to_hex_lower8 ((c >>  0) & 255) <<  0
546           | uint_to_hex_lower8 ((c >>  8) & 255) << 16;
547     w1[1] = uint_to_hex_lower8 ((c >> 16) & 255) <<  0
548           | uint_to_hex_lower8 ((c >> 24) & 255) << 16;
549     w1[2] = uint_to_hex_lower8 ((d >>  0) & 255) <<  0
550           | uint_to_hex_lower8 ((d >>  8) & 255) << 16;
551     w1[3] = uint_to_hex_lower8 ((d >> 16) & 255) <<  0
552           | uint_to_hex_lower8 ((d >> 24) & 255) << 16;
553     w2[0] = 0x80;
554     w2[1] = 0;
555     w2[2] = 0;
556     w2[3] = 0;
557     w3[0] = 0;
558     w3[1] = 0;
559     w3[2] = 0;
560     w3[3] = 0;
561
562     /**
563      * prepend salt
564      */
565
566     switch_buffer_by_offset_le (w0, w1, w2, w3, salt_len);
567
568     w3[2] = pw_salt_len * 8;
569     w3[3] = 0;
570
571     w0[0] |= salt_buf0[0];
572     w0[1] |= salt_buf0[1];
573     w0[2] |= salt_buf0[2];
574     w0[3] |= salt_buf0[3];
575     w1[0] |= salt_buf1[0];
576     w1[1] |= salt_buf1[1];
577     w1[2] |= salt_buf1[2];
578     w1[3] |= salt_buf1[3];
579     w2[0] |= salt_buf2[0];
580     w2[1] |= salt_buf2[1];
581     w2[2] |= salt_buf2[2];
582     w2[3] |= salt_buf2[3];
583     w3[0] |= salt_buf3[0];
584     w3[1] |= salt_buf3[1];
585     w3[2] |= salt_buf3[2];
586     w3[3] |= salt_buf3[3];
587
588     /**
589      * md5
590      */
591
592     a = MD5M_A;
593     b = MD5M_B;
594     c = MD5M_C;
595     d = MD5M_D;
596
597     MD5_STEP (MD5_Fo, a, b, c, d, w0[0], MD5C00, MD5S00);
598     MD5_STEP (MD5_Fo, d, a, b, c, w0[1], MD5C01, MD5S01);
599     MD5_STEP (MD5_Fo, c, d, a, b, w0[2], MD5C02, MD5S02);
600     MD5_STEP (MD5_Fo, b, c, d, a, w0[3], MD5C03, MD5S03);
601     MD5_STEP (MD5_Fo, a, b, c, d, w1[0], MD5C04, MD5S00);
602     MD5_STEP (MD5_Fo, d, a, b, c, w1[1], MD5C05, MD5S01);
603     MD5_STEP (MD5_Fo, c, d, a, b, w1[2], MD5C06, MD5S02);
604     MD5_STEP (MD5_Fo, b, c, d, a, w1[3], MD5C07, MD5S03);
605     MD5_STEP (MD5_Fo, a, b, c, d, w2[0], MD5C08, MD5S00);
606     MD5_STEP (MD5_Fo, d, a, b, c, w2[1], MD5C09, MD5S01);
607     MD5_STEP (MD5_Fo, c, d, a, b, w2[2], MD5C0a, MD5S02);
608     MD5_STEP (MD5_Fo, b, c, d, a, w2[3], MD5C0b, MD5S03);
609     MD5_STEP (MD5_Fo, a, b, c, d, w3[0], MD5C0c, MD5S00);
610     MD5_STEP (MD5_Fo, d, a, b, c, w3[1], MD5C0d, MD5S01);
611     MD5_STEP (MD5_Fo, c, d, a, b, w3[2], MD5C0e, MD5S02);
612     MD5_STEP (MD5_Fo, b, c, d, a, w3[3], MD5C0f, MD5S03);
613
614     MD5_STEP (MD5_Go, a, b, c, d, w0[1], MD5C10, MD5S10);
615     MD5_STEP (MD5_Go, d, a, b, c, w1[2], MD5C11, MD5S11);
616     MD5_STEP (MD5_Go, c, d, a, b, w2[3], MD5C12, MD5S12);
617     MD5_STEP (MD5_Go, b, c, d, a, w0[0], MD5C13, MD5S13);
618     MD5_STEP (MD5_Go, a, b, c, d, w1[1], MD5C14, MD5S10);
619     MD5_STEP (MD5_Go, d, a, b, c, w2[2], MD5C15, MD5S11);
620     MD5_STEP (MD5_Go, c, d, a, b, w3[3], MD5C16, MD5S12);
621     MD5_STEP (MD5_Go, b, c, d, a, w1[0], MD5C17, MD5S13);
622     MD5_STEP (MD5_Go, a, b, c, d, w2[1], MD5C18, MD5S10);
623     MD5_STEP (MD5_Go, d, a, b, c, w3[2], MD5C19, MD5S11);
624     MD5_STEP (MD5_Go, c, d, a, b, w0[3], MD5C1a, MD5S12);
625     MD5_STEP (MD5_Go, b, c, d, a, w2[0], MD5C1b, MD5S13);
626     MD5_STEP (MD5_Go, a, b, c, d, w3[1], MD5C1c, MD5S10);
627     MD5_STEP (MD5_Go, d, a, b, c, w0[2], MD5C1d, MD5S11);
628     MD5_STEP (MD5_Go, c, d, a, b, w1[3], MD5C1e, MD5S12);
629     MD5_STEP (MD5_Go, b, c, d, a, w3[0], MD5C1f, MD5S13);
630
631     MD5_STEP (MD5_H , a, b, c, d, w1[1], MD5C20, MD5S20);
632     MD5_STEP (MD5_H , d, a, b, c, w2[0], MD5C21, MD5S21);
633     MD5_STEP (MD5_H , c, d, a, b, w2[3], MD5C22, MD5S22);
634     MD5_STEP (MD5_H , b, c, d, a, w3[2], MD5C23, MD5S23);
635     MD5_STEP (MD5_H , a, b, c, d, w0[1], MD5C24, MD5S20);
636     MD5_STEP (MD5_H , d, a, b, c, w1[0], MD5C25, MD5S21);
637     MD5_STEP (MD5_H , c, d, a, b, w1[3], MD5C26, MD5S22);
638     MD5_STEP (MD5_H , b, c, d, a, w2[2], MD5C27, MD5S23);
639     MD5_STEP (MD5_H , a, b, c, d, w3[1], MD5C28, MD5S20);
640     MD5_STEP (MD5_H , d, a, b, c, w0[0], MD5C29, MD5S21);
641     MD5_STEP (MD5_H , c, d, a, b, w0[3], MD5C2a, MD5S22);
642     MD5_STEP (MD5_H , b, c, d, a, w1[2], MD5C2b, MD5S23);
643     MD5_STEP (MD5_H , a, b, c, d, w2[1], MD5C2c, MD5S20);
644     MD5_STEP (MD5_H , d, a, b, c, w3[0], MD5C2d, MD5S21);
645     MD5_STEP (MD5_H , c, d, a, b, w3[3], MD5C2e, MD5S22);
646     MD5_STEP (MD5_H , b, c, d, a, w0[2], MD5C2f, MD5S23);
647
648     MD5_STEP (MD5_I , a, b, c, d, w0[0], MD5C30, MD5S30);
649     MD5_STEP (MD5_I , d, a, b, c, w1[3], MD5C31, MD5S31);
650     MD5_STEP (MD5_I , c, d, a, b, w3[2], MD5C32, MD5S32);
651     MD5_STEP (MD5_I , b, c, d, a, w1[1], MD5C33, MD5S33);
652     MD5_STEP (MD5_I , a, b, c, d, w3[0], MD5C34, MD5S30);
653     MD5_STEP (MD5_I , d, a, b, c, w0[3], MD5C35, MD5S31);
654     MD5_STEP (MD5_I , c, d, a, b, w2[2], MD5C36, MD5S32);
655     MD5_STEP (MD5_I , b, c, d, a, w0[1], MD5C37, MD5S33);
656     MD5_STEP (MD5_I , a, b, c, d, w2[0], MD5C38, MD5S30);
657     MD5_STEP (MD5_I , d, a, b, c, w3[3], MD5C39, MD5S31);
658     MD5_STEP (MD5_I , c, d, a, b, w1[2], MD5C3a, MD5S32);
659     MD5_STEP (MD5_I , b, c, d, a, w3[1], MD5C3b, MD5S33);
660     MD5_STEP (MD5_I , a, b, c, d, w1[0], MD5C3c, MD5S30);
661
662     if (MATCHES_NONE_VS (a, search[0])) continue;
663
664     MD5_STEP (MD5_I , d, a, b, c, w2[3], MD5C3d, MD5S31);
665     MD5_STEP (MD5_I , c, d, a, b, w0[2], MD5C3e, MD5S32);
666     MD5_STEP (MD5_I , b, c, d, a, w2[1], MD5C3f, MD5S33);
667
668     COMPARE_S_SIMD (a, d, c, b);
669   }
670 }
671
672 __kernel void m03710_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 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
673 {
674 }
675
676 __kernel void m03710_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 il_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
677 {
678 }