Initial commit
[hashcat.git] / nv / m00030_a0.cu
1 /**
2  * Author......: Jens Steube <jens.steube@gmail.com>
3  * License.....: MIT
4  */
5
6 #define _MD5_
7
8 #include "include/constants.h"
9 #include "include/kernel_vendor.h"
10
11 #ifdef  VLIW1
12 #define VECT_SIZE1
13 #endif
14
15 #ifdef  VLIW2
16 #define VECT_SIZE1
17 #endif
18
19 #define DGST_R0 0
20 #define DGST_R1 3
21 #define DGST_R2 2
22 #define DGST_R3 1
23
24 #include "include/kernel_functions.c"
25 #include "types_nv.c"
26 #include "common_nv.c"
27 #include "include/rp_gpu.h"
28 #include "rp_nv.c"
29
30 #ifdef  VECT_SIZE1
31 #define VECT_COMPARE_S "check_single_vect1_comp4.c"
32 #define VECT_COMPARE_M "check_multi_vect1_comp4.c"
33 #endif
34
35 #ifdef  VECT_SIZE2
36 #define VECT_COMPARE_S "check_single_vect2_comp4.c"
37 #define VECT_COMPARE_M "check_multi_vect2_comp4.c"
38 #endif
39
40 #ifdef  VECT_SIZE4
41 #define VECT_COMPARE_S "check_single_vect4_comp4.c"
42 #define VECT_COMPARE_M "check_multi_vect4_comp4.c"
43 #endif
44
45 __device__ __constant__ gpu_rule_t c_rules[1024];
46
47 extern "C" __global__ void __launch_bounds__ (256, 1) m00030_m04 (const pw_t *pws, const gpu_rule_t *rules_buf, const comb_t *combs_buf, const bf_t *bfs_buf, const void *tmps, void *hooks, const u32 *bitmaps_buf_s1_a, const u32 *bitmaps_buf_s1_b, const u32 *bitmaps_buf_s1_c, const u32 *bitmaps_buf_s1_d, const u32 *bitmaps_buf_s2_a, const u32 *bitmaps_buf_s2_b, const u32 *bitmaps_buf_s2_c, const u32 *bitmaps_buf_s2_d, plain_t *plains_buf, const digest_t *digests_buf, u32 *hashes_shown, const salt_t *salt_bufs, const void *esalt_bufs, u32 *d_return_buf, 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 rules_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
48 {
49   /**
50    * modifier
51    */
52
53   const u32 lid = threadIdx.x;
54
55   /**
56    * base
57    */
58
59   const u32 gid = (blockIdx.x * blockDim.x) + threadIdx.x;
60
61   if (gid >= gid_max) return;
62
63   u32x pw_buf0[4];
64
65   pw_buf0[0] = pws[gid].i[ 0];
66   pw_buf0[1] = pws[gid].i[ 1];
67   pw_buf0[2] = pws[gid].i[ 2];
68   pw_buf0[3] = pws[gid].i[ 3];
69
70   u32x pw_buf1[4];
71
72   pw_buf1[0] = pws[gid].i[ 4];
73   pw_buf1[1] = pws[gid].i[ 5];
74   pw_buf1[2] = pws[gid].i[ 6];
75   pw_buf1[3] = pws[gid].i[ 7];
76
77   const u32 pw_len = pws[gid].pw_len;
78
79   /**
80    * salt
81    */
82
83   u32 salt_buf0[4];
84
85   salt_buf0[0] = salt_bufs[salt_pos].salt_buf[0];
86   salt_buf0[1] = salt_bufs[salt_pos].salt_buf[1];
87   salt_buf0[2] = salt_bufs[salt_pos].salt_buf[2];
88   salt_buf0[3] = salt_bufs[salt_pos].salt_buf[3];
89
90   u32 salt_buf1[4];
91
92   salt_buf1[0] = salt_bufs[salt_pos].salt_buf[4];
93   salt_buf1[1] = salt_bufs[salt_pos].salt_buf[5];
94   salt_buf1[2] = salt_bufs[salt_pos].salt_buf[6];
95   salt_buf1[3] = salt_bufs[salt_pos].salt_buf[7];
96
97   const u32 salt_len = salt_bufs[salt_pos].salt_len;
98
99   /**
100    * loop
101    */
102
103   for (u32 il_pos = 0; il_pos < rules_cnt; il_pos++)
104   {
105     u32x w0[4];
106
107     w0[0] = pw_buf0[0];
108     w0[1] = pw_buf0[1];
109     w0[2] = pw_buf0[2];
110     w0[3] = pw_buf0[3];
111
112     u32x w1[4];
113
114     w1[0] = pw_buf1[0];
115     w1[1] = pw_buf1[1];
116     w1[2] = pw_buf1[2];
117     w1[3] = pw_buf1[3];
118
119     u32x w2[4];
120
121     w2[0] = 0;
122     w2[1] = 0;
123     w2[2] = 0;
124     w2[3] = 0;
125
126     u32x w3[4];
127
128     w3[0] = 0;
129     w3[1] = 0;
130     w3[2] = 0;
131     w3[3] = 0;
132
133     const u32 out_len = apply_rules (c_rules[il_pos].cmds, w0, w1, pw_len);
134
135     /**
136      * append salt
137      */
138
139     u32 s0[4];
140
141     s0[0] = salt_buf0[0];
142     s0[1] = salt_buf0[1];
143     s0[2] = salt_buf0[2];
144     s0[3] = salt_buf0[3];
145
146     u32 s1[4];
147
148     s1[0] = salt_buf1[0];
149     s1[1] = salt_buf1[1];
150     s1[2] = salt_buf1[2];
151     s1[3] = salt_buf1[3];
152
153     u32 s2[4];
154
155     s2[0] = 0;
156     s2[1] = 0;
157     s2[2] = 0;
158     s2[3] = 0;
159
160     u32 s3[4];
161
162     s3[0] = 0;
163     s3[1] = 0;
164     s3[2] = 0;
165     s3[3] = 0;
166
167     switch_buffer_by_offset (s0, s1, s2, s3, (out_len * 2));
168
169     const u32 out_salt_len = (out_len * 2) + salt_len;
170
171     u32x w0_t[4];
172     u32x w1_t[4];
173     u32x w2_t[4];
174     u32x w3_t[4];
175
176     make_unicode (w0, w0_t, w1_t);
177     make_unicode (w1, w2_t, w3_t);
178
179     w0_t[0] |= s0[0];
180     w0_t[1] |= s0[1];
181     w0_t[2] |= s0[2];
182     w0_t[3] |= s0[3];
183     w1_t[0] |= s1[0];
184     w1_t[1] |= s1[1];
185     w1_t[2] |= s1[2];
186     w1_t[3] |= s1[3];
187     w2_t[0] |= s2[0];
188     w2_t[1] |= s2[1];
189     w2_t[2] |= s2[2];
190     w2_t[3] |= s2[3];
191     w3_t[0] |= s3[0];
192     w3_t[1] |= s3[1];
193     w3_t[2] |= s3[2];
194     w3_t[3] |= s3[3];
195
196     append_0x80_4 (w0_t, w1_t, w2_t, w3_t, out_salt_len);
197
198     w3_t[2] = out_salt_len * 8;
199
200     /**
201      * md5
202      */
203
204     u32x a = MD5M_A;
205     u32x b = MD5M_B;
206     u32x c = MD5M_C;
207     u32x d = MD5M_D;
208
209     MD5_STEP (MD5_Fo, a, b, c, d, w0_t[0], MD5C00, MD5S00);
210     MD5_STEP (MD5_Fo, d, a, b, c, w0_t[1], MD5C01, MD5S01);
211     MD5_STEP (MD5_Fo, c, d, a, b, w0_t[2], MD5C02, MD5S02);
212     MD5_STEP (MD5_Fo, b, c, d, a, w0_t[3], MD5C03, MD5S03);
213     MD5_STEP (MD5_Fo, a, b, c, d, w1_t[0], MD5C04, MD5S00);
214     MD5_STEP (MD5_Fo, d, a, b, c, w1_t[1], MD5C05, MD5S01);
215     MD5_STEP (MD5_Fo, c, d, a, b, w1_t[2], MD5C06, MD5S02);
216     MD5_STEP (MD5_Fo, b, c, d, a, w1_t[3], MD5C07, MD5S03);
217     MD5_STEP (MD5_Fo, a, b, c, d, w2_t[0], MD5C08, MD5S00);
218     MD5_STEP (MD5_Fo, d, a, b, c, w2_t[1], MD5C09, MD5S01);
219     MD5_STEP (MD5_Fo, c, d, a, b, w2_t[2], MD5C0a, MD5S02);
220     MD5_STEP (MD5_Fo, b, c, d, a, w2_t[3], MD5C0b, MD5S03);
221     MD5_STEP (MD5_Fo, a, b, c, d, w3_t[0], MD5C0c, MD5S00);
222     MD5_STEP (MD5_Fo, d, a, b, c, w3_t[1], MD5C0d, MD5S01);
223     MD5_STEP (MD5_Fo, c, d, a, b, w3_t[2], MD5C0e, MD5S02);
224     MD5_STEP (MD5_Fo, b, c, d, a, w3_t[3], MD5C0f, MD5S03);
225
226     MD5_STEP (MD5_Go, a, b, c, d, w0_t[1], MD5C10, MD5S10);
227     MD5_STEP (MD5_Go, d, a, b, c, w1_t[2], MD5C11, MD5S11);
228     MD5_STEP (MD5_Go, c, d, a, b, w2_t[3], MD5C12, MD5S12);
229     MD5_STEP (MD5_Go, b, c, d, a, w0_t[0], MD5C13, MD5S13);
230     MD5_STEP (MD5_Go, a, b, c, d, w1_t[1], MD5C14, MD5S10);
231     MD5_STEP (MD5_Go, d, a, b, c, w2_t[2], MD5C15, MD5S11);
232     MD5_STEP (MD5_Go, c, d, a, b, w3_t[3], MD5C16, MD5S12);
233     MD5_STEP (MD5_Go, b, c, d, a, w1_t[0], MD5C17, MD5S13);
234     MD5_STEP (MD5_Go, a, b, c, d, w2_t[1], MD5C18, MD5S10);
235     MD5_STEP (MD5_Go, d, a, b, c, w3_t[2], MD5C19, MD5S11);
236     MD5_STEP (MD5_Go, c, d, a, b, w0_t[3], MD5C1a, MD5S12);
237     MD5_STEP (MD5_Go, b, c, d, a, w2_t[0], MD5C1b, MD5S13);
238     MD5_STEP (MD5_Go, a, b, c, d, w3_t[1], MD5C1c, MD5S10);
239     MD5_STEP (MD5_Go, d, a, b, c, w0_t[2], MD5C1d, MD5S11);
240     MD5_STEP (MD5_Go, c, d, a, b, w1_t[3], MD5C1e, MD5S12);
241     MD5_STEP (MD5_Go, b, c, d, a, w3_t[0], MD5C1f, MD5S13);
242
243     MD5_STEP (MD5_H , a, b, c, d, w1_t[1], MD5C20, MD5S20);
244     MD5_STEP (MD5_H , d, a, b, c, w2_t[0], MD5C21, MD5S21);
245     MD5_STEP (MD5_H , c, d, a, b, w2_t[3], MD5C22, MD5S22);
246     MD5_STEP (MD5_H , b, c, d, a, w3_t[2], MD5C23, MD5S23);
247     MD5_STEP (MD5_H , a, b, c, d, w0_t[1], MD5C24, MD5S20);
248     MD5_STEP (MD5_H , d, a, b, c, w1_t[0], MD5C25, MD5S21);
249     MD5_STEP (MD5_H , c, d, a, b, w1_t[3], MD5C26, MD5S22);
250     MD5_STEP (MD5_H , b, c, d, a, w2_t[2], MD5C27, MD5S23);
251     MD5_STEP (MD5_H , a, b, c, d, w3_t[1], MD5C28, MD5S20);
252     MD5_STEP (MD5_H , d, a, b, c, w0_t[0], MD5C29, MD5S21);
253     MD5_STEP (MD5_H , c, d, a, b, w0_t[3], MD5C2a, MD5S22);
254     MD5_STEP (MD5_H , b, c, d, a, w1_t[2], MD5C2b, MD5S23);
255     MD5_STEP (MD5_H , a, b, c, d, w2_t[1], MD5C2c, MD5S20);
256     MD5_STEP (MD5_H , d, a, b, c, w3_t[0], MD5C2d, MD5S21);
257     MD5_STEP (MD5_H , c, d, a, b, w3_t[3], MD5C2e, MD5S22);
258     MD5_STEP (MD5_H , b, c, d, a, w0_t[2], MD5C2f, MD5S23);
259
260     MD5_STEP (MD5_I , a, b, c, d, w0_t[0], MD5C30, MD5S30);
261     MD5_STEP (MD5_I , d, a, b, c, w1_t[3], MD5C31, MD5S31);
262     MD5_STEP (MD5_I , c, d, a, b, w3_t[2], MD5C32, MD5S32);
263     MD5_STEP (MD5_I , b, c, d, a, w1_t[1], MD5C33, MD5S33);
264     MD5_STEP (MD5_I , a, b, c, d, w3_t[0], MD5C34, MD5S30);
265     MD5_STEP (MD5_I , d, a, b, c, w0_t[3], MD5C35, MD5S31);
266     MD5_STEP (MD5_I , c, d, a, b, w2_t[2], MD5C36, MD5S32);
267     MD5_STEP (MD5_I , b, c, d, a, w0_t[1], MD5C37, MD5S33);
268     MD5_STEP (MD5_I , a, b, c, d, w2_t[0], MD5C38, MD5S30);
269     MD5_STEP (MD5_I , d, a, b, c, w3_t[3], MD5C39, MD5S31);
270     MD5_STEP (MD5_I , c, d, a, b, w1_t[2], MD5C3a, MD5S32);
271     MD5_STEP (MD5_I , b, c, d, a, w3_t[1], MD5C3b, MD5S33);
272     MD5_STEP (MD5_I , a, b, c, d, w1_t[0], MD5C3c, MD5S30);
273     MD5_STEP (MD5_I , d, a, b, c, w2_t[3], MD5C3d, MD5S31);
274     MD5_STEP (MD5_I , c, d, a, b, w0_t[2], MD5C3e, MD5S32);
275     MD5_STEP (MD5_I , b, c, d, a, w2_t[1], MD5C3f, MD5S33);
276
277
278     const u32x r0 = a;
279     const u32x r1 = d;
280     const u32x r2 = c;
281     const u32x r3 = b;
282
283     #include VECT_COMPARE_M
284   }
285 }
286
287 extern "C" __global__ void __launch_bounds__ (256, 1) m00030_m08 (const pw_t *pws, const gpu_rule_t *rules_buf, const comb_t *combs_buf, const bf_t *bfs_buf, const void *tmps, void *hooks, const u32 *bitmaps_buf_s1_a, const u32 *bitmaps_buf_s1_b, const u32 *bitmaps_buf_s1_c, const u32 *bitmaps_buf_s1_d, const u32 *bitmaps_buf_s2_a, const u32 *bitmaps_buf_s2_b, const u32 *bitmaps_buf_s2_c, const u32 *bitmaps_buf_s2_d, plain_t *plains_buf, const digest_t *digests_buf, u32 *hashes_shown, const salt_t *salt_bufs, const void *esalt_bufs, u32 *d_return_buf, 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 rules_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
288 {
289 }
290
291 extern "C" __global__ void __launch_bounds__ (256, 1) m00030_m16 (const pw_t *pws, const gpu_rule_t *rules_buf, const comb_t *combs_buf, const bf_t *bfs_buf, const void *tmps, void *hooks, const u32 *bitmaps_buf_s1_a, const u32 *bitmaps_buf_s1_b, const u32 *bitmaps_buf_s1_c, const u32 *bitmaps_buf_s1_d, const u32 *bitmaps_buf_s2_a, const u32 *bitmaps_buf_s2_b, const u32 *bitmaps_buf_s2_c, const u32 *bitmaps_buf_s2_d, plain_t *plains_buf, const digest_t *digests_buf, u32 *hashes_shown, const salt_t *salt_bufs, const void *esalt_bufs, u32 *d_return_buf, 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 rules_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
292 {
293 }
294
295 extern "C" __global__ void __launch_bounds__ (256, 1) m00030_s04 (const pw_t *pws, const gpu_rule_t *rules_buf, const comb_t *combs_buf, const bf_t *bfs_buf, const void *tmps, void *hooks, const u32 *bitmaps_buf_s1_a, const u32 *bitmaps_buf_s1_b, const u32 *bitmaps_buf_s1_c, const u32 *bitmaps_buf_s1_d, const u32 *bitmaps_buf_s2_a, const u32 *bitmaps_buf_s2_b, const u32 *bitmaps_buf_s2_c, const u32 *bitmaps_buf_s2_d, plain_t *plains_buf, const digest_t *digests_buf, u32 *hashes_shown, const salt_t *salt_bufs, const void *esalt_bufs, u32 *d_return_buf, 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 rules_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
296 {
297   /**
298    * modifier
299    */
300
301   const u32 lid = threadIdx.x;
302
303   /**
304    * base
305    */
306
307   const u32 gid = (blockIdx.x * blockDim.x) + threadIdx.x;
308
309   if (gid >= gid_max) return;
310
311   u32x pw_buf0[4];
312
313   pw_buf0[0] = pws[gid].i[ 0];
314   pw_buf0[1] = pws[gid].i[ 1];
315   pw_buf0[2] = pws[gid].i[ 2];
316   pw_buf0[3] = pws[gid].i[ 3];
317
318   u32x pw_buf1[4];
319
320   pw_buf1[0] = pws[gid].i[ 4];
321   pw_buf1[1] = pws[gid].i[ 5];
322   pw_buf1[2] = pws[gid].i[ 6];
323   pw_buf1[3] = pws[gid].i[ 7];
324
325   const u32 pw_len = pws[gid].pw_len;
326
327   /**
328    * salt
329    */
330
331   u32 salt_buf0[4];
332
333   salt_buf0[0] = salt_bufs[salt_pos].salt_buf[0];
334   salt_buf0[1] = salt_bufs[salt_pos].salt_buf[1];
335   salt_buf0[2] = salt_bufs[salt_pos].salt_buf[2];
336   salt_buf0[3] = salt_bufs[salt_pos].salt_buf[3];
337
338   u32 salt_buf1[4];
339
340   salt_buf1[0] = salt_bufs[salt_pos].salt_buf[4];
341   salt_buf1[1] = salt_bufs[salt_pos].salt_buf[5];
342   salt_buf1[2] = salt_bufs[salt_pos].salt_buf[6];
343   salt_buf1[3] = salt_bufs[salt_pos].salt_buf[7];
344
345   const u32 salt_len = salt_bufs[salt_pos].salt_len;
346
347   /**
348    * digest
349    */
350
351   const u32 search[4] =
352   {
353     digests_buf[digests_offset].digest_buf[DGST_R0],
354     digests_buf[digests_offset].digest_buf[DGST_R1],
355     digests_buf[digests_offset].digest_buf[DGST_R2],
356     digests_buf[digests_offset].digest_buf[DGST_R3]
357   };
358
359   /**
360    * loop
361    */
362
363   for (u32 il_pos = 0; il_pos < rules_cnt; il_pos++)
364   {
365     u32x w0[4];
366
367     w0[0] = pw_buf0[0];
368     w0[1] = pw_buf0[1];
369     w0[2] = pw_buf0[2];
370     w0[3] = pw_buf0[3];
371
372     u32x w1[4];
373
374     w1[0] = pw_buf1[0];
375     w1[1] = pw_buf1[1];
376     w1[2] = pw_buf1[2];
377     w1[3] = pw_buf1[3];
378
379     u32x w2[4];
380
381     w2[0] = 0;
382     w2[1] = 0;
383     w2[2] = 0;
384     w2[3] = 0;
385
386     u32x w3[4];
387
388     w3[0] = 0;
389     w3[1] = 0;
390     w3[2] = 0;
391     w3[3] = 0;
392
393     const u32 out_len = apply_rules (c_rules[il_pos].cmds, w0, w1, pw_len);
394
395     /**
396      * append salt
397      */
398
399     u32 s0[4];
400
401     s0[0] = salt_buf0[0];
402     s0[1] = salt_buf0[1];
403     s0[2] = salt_buf0[2];
404     s0[3] = salt_buf0[3];
405
406     u32 s1[4];
407
408     s1[0] = salt_buf1[0];
409     s1[1] = salt_buf1[1];
410     s1[2] = salt_buf1[2];
411     s1[3] = salt_buf1[3];
412
413     u32 s2[4];
414
415     s2[0] = 0;
416     s2[1] = 0;
417     s2[2] = 0;
418     s2[3] = 0;
419
420     u32 s3[4];
421
422     s3[0] = 0;
423     s3[1] = 0;
424     s3[2] = 0;
425     s3[3] = 0;
426
427     switch_buffer_by_offset (s0, s1, s2, s3, (out_len * 2));
428
429     const u32 out_salt_len = (out_len * 2) + salt_len;
430
431     u32x w0_t[4];
432     u32x w1_t[4];
433     u32x w2_t[4];
434     u32x w3_t[4];
435
436     make_unicode (w0, w0_t, w1_t);
437     make_unicode (w1, w2_t, w3_t);
438
439     w0_t[0] |= s0[0];
440     w0_t[1] |= s0[1];
441     w0_t[2] |= s0[2];
442     w0_t[3] |= s0[3];
443     w1_t[0] |= s1[0];
444     w1_t[1] |= s1[1];
445     w1_t[2] |= s1[2];
446     w1_t[3] |= s1[3];
447     w2_t[0] |= s2[0];
448     w2_t[1] |= s2[1];
449     w2_t[2] |= s2[2];
450     w2_t[3] |= s2[3];
451     w3_t[0] |= s3[0];
452     w3_t[1] |= s3[1];
453     w3_t[2] |= s3[2];
454     w3_t[3] |= s3[3];
455
456     append_0x80_4 (w0_t, w1_t, w2_t, w3_t, out_salt_len);
457
458     w3_t[2] = out_salt_len * 8;
459
460     /**
461      * md5
462      */
463
464     u32x a = MD5M_A;
465     u32x b = MD5M_B;
466     u32x c = MD5M_C;
467     u32x d = MD5M_D;
468
469     MD5_STEP (MD5_Fo, a, b, c, d, w0_t[0], MD5C00, MD5S00);
470     MD5_STEP (MD5_Fo, d, a, b, c, w0_t[1], MD5C01, MD5S01);
471     MD5_STEP (MD5_Fo, c, d, a, b, w0_t[2], MD5C02, MD5S02);
472     MD5_STEP (MD5_Fo, b, c, d, a, w0_t[3], MD5C03, MD5S03);
473     MD5_STEP (MD5_Fo, a, b, c, d, w1_t[0], MD5C04, MD5S00);
474     MD5_STEP (MD5_Fo, d, a, b, c, w1_t[1], MD5C05, MD5S01);
475     MD5_STEP (MD5_Fo, c, d, a, b, w1_t[2], MD5C06, MD5S02);
476     MD5_STEP (MD5_Fo, b, c, d, a, w1_t[3], MD5C07, MD5S03);
477     MD5_STEP (MD5_Fo, a, b, c, d, w2_t[0], MD5C08, MD5S00);
478     MD5_STEP (MD5_Fo, d, a, b, c, w2_t[1], MD5C09, MD5S01);
479     MD5_STEP (MD5_Fo, c, d, a, b, w2_t[2], MD5C0a, MD5S02);
480     MD5_STEP (MD5_Fo, b, c, d, a, w2_t[3], MD5C0b, MD5S03);
481     MD5_STEP (MD5_Fo, a, b, c, d, w3_t[0], MD5C0c, MD5S00);
482     MD5_STEP (MD5_Fo, d, a, b, c, w3_t[1], MD5C0d, MD5S01);
483     MD5_STEP (MD5_Fo, c, d, a, b, w3_t[2], MD5C0e, MD5S02);
484     MD5_STEP (MD5_Fo, b, c, d, a, w3_t[3], MD5C0f, MD5S03);
485
486     MD5_STEP (MD5_Go, a, b, c, d, w0_t[1], MD5C10, MD5S10);
487     MD5_STEP (MD5_Go, d, a, b, c, w1_t[2], MD5C11, MD5S11);
488     MD5_STEP (MD5_Go, c, d, a, b, w2_t[3], MD5C12, MD5S12);
489     MD5_STEP (MD5_Go, b, c, d, a, w0_t[0], MD5C13, MD5S13);
490     MD5_STEP (MD5_Go, a, b, c, d, w1_t[1], MD5C14, MD5S10);
491     MD5_STEP (MD5_Go, d, a, b, c, w2_t[2], MD5C15, MD5S11);
492     MD5_STEP (MD5_Go, c, d, a, b, w3_t[3], MD5C16, MD5S12);
493     MD5_STEP (MD5_Go, b, c, d, a, w1_t[0], MD5C17, MD5S13);
494     MD5_STEP (MD5_Go, a, b, c, d, w2_t[1], MD5C18, MD5S10);
495     MD5_STEP (MD5_Go, d, a, b, c, w3_t[2], MD5C19, MD5S11);
496     MD5_STEP (MD5_Go, c, d, a, b, w0_t[3], MD5C1a, MD5S12);
497     MD5_STEP (MD5_Go, b, c, d, a, w2_t[0], MD5C1b, MD5S13);
498     MD5_STEP (MD5_Go, a, b, c, d, w3_t[1], MD5C1c, MD5S10);
499     MD5_STEP (MD5_Go, d, a, b, c, w0_t[2], MD5C1d, MD5S11);
500     MD5_STEP (MD5_Go, c, d, a, b, w1_t[3], MD5C1e, MD5S12);
501     MD5_STEP (MD5_Go, b, c, d, a, w3_t[0], MD5C1f, MD5S13);
502
503     MD5_STEP (MD5_H , a, b, c, d, w1_t[1], MD5C20, MD5S20);
504     MD5_STEP (MD5_H , d, a, b, c, w2_t[0], MD5C21, MD5S21);
505     MD5_STEP (MD5_H , c, d, a, b, w2_t[3], MD5C22, MD5S22);
506     MD5_STEP (MD5_H , b, c, d, a, w3_t[2], MD5C23, MD5S23);
507     MD5_STEP (MD5_H , a, b, c, d, w0_t[1], MD5C24, MD5S20);
508     MD5_STEP (MD5_H , d, a, b, c, w1_t[0], MD5C25, MD5S21);
509     MD5_STEP (MD5_H , c, d, a, b, w1_t[3], MD5C26, MD5S22);
510     MD5_STEP (MD5_H , b, c, d, a, w2_t[2], MD5C27, MD5S23);
511     MD5_STEP (MD5_H , a, b, c, d, w3_t[1], MD5C28, MD5S20);
512     MD5_STEP (MD5_H , d, a, b, c, w0_t[0], MD5C29, MD5S21);
513     MD5_STEP (MD5_H , c, d, a, b, w0_t[3], MD5C2a, MD5S22);
514     MD5_STEP (MD5_H , b, c, d, a, w1_t[2], MD5C2b, MD5S23);
515     MD5_STEP (MD5_H , a, b, c, d, w2_t[1], MD5C2c, MD5S20);
516     MD5_STEP (MD5_H , d, a, b, c, w3_t[0], MD5C2d, MD5S21);
517     MD5_STEP (MD5_H , c, d, a, b, w3_t[3], MD5C2e, MD5S22);
518     MD5_STEP (MD5_H , b, c, d, a, w0_t[2], MD5C2f, MD5S23);
519
520     MD5_STEP (MD5_I , a, b, c, d, w0_t[0], MD5C30, MD5S30);
521     MD5_STEP (MD5_I , d, a, b, c, w1_t[3], MD5C31, MD5S31);
522     MD5_STEP (MD5_I , c, d, a, b, w3_t[2], MD5C32, MD5S32);
523     MD5_STEP (MD5_I , b, c, d, a, w1_t[1], MD5C33, MD5S33);
524     MD5_STEP (MD5_I , a, b, c, d, w3_t[0], MD5C34, MD5S30);
525     MD5_STEP (MD5_I , d, a, b, c, w0_t[3], MD5C35, MD5S31);
526     MD5_STEP (MD5_I , c, d, a, b, w2_t[2], MD5C36, MD5S32);
527     MD5_STEP (MD5_I , b, c, d, a, w0_t[1], MD5C37, MD5S33);
528     MD5_STEP (MD5_I , a, b, c, d, w2_t[0], MD5C38, MD5S30);
529     MD5_STEP (MD5_I , d, a, b, c, w3_t[3], MD5C39, MD5S31);
530     MD5_STEP (MD5_I , c, d, a, b, w1_t[2], MD5C3a, MD5S32);
531     MD5_STEP (MD5_I , b, c, d, a, w3_t[1], MD5C3b, MD5S33);
532     MD5_STEP (MD5_I , a, b, c, d, w1_t[0], MD5C3c, MD5S30);
533
534     bool q_cond = (search[0] != a);
535
536     if (q_cond) continue;
537
538     MD5_STEP (MD5_I , d, a, b, c, w2_t[3], MD5C3d, MD5S31);
539     MD5_STEP (MD5_I , c, d, a, b, w0_t[2], MD5C3e, MD5S32);
540     MD5_STEP (MD5_I , b, c, d, a, w2_t[1], MD5C3f, MD5S33);
541
542
543     const u32x r0 = a;
544     const u32x r1 = d;
545     const u32x r2 = c;
546     const u32x r3 = b;
547
548     #include VECT_COMPARE_S
549   }
550 }
551
552 extern "C" __global__ void __launch_bounds__ (256, 1) m00030_s08 (const pw_t *pws, const gpu_rule_t *rules_buf, const comb_t *combs_buf, const bf_t *bfs_buf, const void *tmps, void *hooks, const u32 *bitmaps_buf_s1_a, const u32 *bitmaps_buf_s1_b, const u32 *bitmaps_buf_s1_c, const u32 *bitmaps_buf_s1_d, const u32 *bitmaps_buf_s2_a, const u32 *bitmaps_buf_s2_b, const u32 *bitmaps_buf_s2_c, const u32 *bitmaps_buf_s2_d, plain_t *plains_buf, const digest_t *digests_buf, u32 *hashes_shown, const salt_t *salt_bufs, const void *esalt_bufs, u32 *d_return_buf, 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 rules_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
553 {
554 }
555
556 extern "C" __global__ void __launch_bounds__ (256, 1) m00030_s16 (const pw_t *pws, const gpu_rule_t *rules_buf, const comb_t *combs_buf, const bf_t *bfs_buf, const void *tmps, void *hooks, const u32 *bitmaps_buf_s1_a, const u32 *bitmaps_buf_s1_b, const u32 *bitmaps_buf_s1_c, const u32 *bitmaps_buf_s1_d, const u32 *bitmaps_buf_s2_a, const u32 *bitmaps_buf_s2_b, const u32 *bitmaps_buf_s2_c, const u32 *bitmaps_buf_s2_d, plain_t *plains_buf, const digest_t *digests_buf, u32 *hashes_shown, const salt_t *salt_bufs, const void *esalt_bufs, u32 *d_return_buf, 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 rules_cnt, const u32 digests_cnt, const u32 digests_offset, const u32 combs_mode, const u32 gid_max)
557 {
558 }