1 /**
2  * Author......: See docs/credits.txt
3  * License.....: MIT
4  */
5 
6 #include "common.h"
7 #include "types.h"
8 #include "modules.h"
9 #include "bitops.h"
10 #include "convert.h"
11 #include "shared.h"
12 #include "memory.h"
13 #include "emu_inc_ecc_secp256k1.h"
14 
15 static const u32   ATTACK_EXEC    = ATTACK_EXEC_OUTSIDE_KERNEL;
16 static const u32   DGST_POS0      = 0;
17 static const u32   DGST_POS1      = 1;
18 static const u32   DGST_POS2      = 2;
19 static const u32   DGST_POS3      = 3;
20 static const u32   DGST_SIZE      = DGST_SIZE_4_8;
21 static const u32   HASH_CATEGORY  = HASH_CATEGORY_CRYPTOCURRENCY_WALLET;
22 static const char *HASH_NAME      = "Electrum Wallet (Salt-Type 5)";
23 static const u64   KERN_TYPE      = 21800;
24 static const u32   OPTI_TYPE      = OPTI_TYPE_ZERO_BYTE
25                                   | OPTI_TYPE_USES_BITS_64
26                                   | OPTI_TYPE_SLOW_HASH_SIMD_LOOP;
27 static const u64   OPTS_TYPE      = OPTS_TYPE_PT_GENERATE_LE
28                                   | OPTS_TYPE_NATIVE_THREADS;
29 static const u32   SALT_TYPE      = SALT_TYPE_EMBEDDED;
30 static const char *ST_PASS        = "hashcat";
31 static const char *ST_HASH        = "$electrum$5*02170fee7c35f1ef3b229edc90fbd0793b688a0d6f41137a97aab2343d315cce16*94cf72d8f5d774932b414a3344984859e43721268d2eb35fa531de5a2fc7024b463c730a54f4f46229dd9fede5034b19ac415c2916e9c16b02094f845795df0c397ff76d597886b1f9e014ad1a8f64a3f617d9900aa645b3ba86f16ce542251fc22c41d93fa6bc118be96d9582917e19d2a299743331804cfc7ce2c035367b4cbcfb70adfb1e10a0f2795769f2165d8fd13daa8b45eeac495b5b63e91a87f63b42e483f84a881e49adecacf6519cb564694b42dd9fe80fcbc6cdb63cf5ae33f35255266f5c2524dd93d3cc15eba0f2ccdc3c109cc2d7e8f711b8b440f168caf8b005e8bcdfe694148e94a04d2a738f09349a96600bd8e8edae793b26ebae231022f24e96cb158db141ac40400a9e9ef099e673cfe017281537c57f82fb45c62bdb64462235a6eefb594961d5eb2c46537958e4d04250804c6e9f343ab7a0db07af6b8a9d1a6c5cfcd311b8fb8383ac9ed9d98d427d526c2f517fc97473bd87cb59899bd0e8fb8c57fa0f7e0d53daa57c972cf92764af4b1725a5fb8f504b663ec519731929b3caaa793d8ee74293eee27d0e208a60e26290bc546e6fa9ed865076e13febfea249729218c1b5752e912055fbf993fbac5df2cca2b37c5e0f9c30789858ceeb3c482a8db123966775aeed2eee2fc34efb160d164929f51589bff748ca773f38978bff3508d5a7591fb2d2795df983504a788071f469d78c88fd7899cabbc5804f458653d0206b82771a59522e1fa794d7de1536c51a437f5d6df5efd6654678e5794ca429b5752e1103340ed80786f1e9da7f5b39af628b2212e4d88cd36b8a7136d50a6b6e275ab406ba7c57cc70d77d01c4c16e9363901164fa92dc9e9b99219d5376f24862e775968605001e71b000e2c7123b4b43f3ca40db17efd729388782e46e64d43ccb947db4eb1473ff1a3836b74fe312cd1a33b73b8b8d80c087088932277773c329f2f66a01d6b3fc1e651c56959ebbed7b14a21b977f3acdedf1a0d98d519a74b50c39b3052d840106da4145345d86ec0461cddafacc2a4f0dd646457ad05bf04dcbcc80516a5c5ed14d2d639a70e77b686f19cbfb63f546d81ae19cc8ba35cce3f3b5b9602df25b678e14411fecec87b8347f5047513df415c6b1a3d39871a6bcb0f67d9cf8311596deae45fd1d84a04fd58f1fd55c5156b7309af09094c99a53674809cb87a45f95a2d69f9997a38085519cb4e056f9efd56672a2c1fe927d5ea8eec25b8aff6e56f9a2310f1a481daf407b8adf16201da267c59973920fd21bb087b88123ef98709839d6a3ee34efb8ccd5c15ed0e46cff3172682769531164b66c8689c35a26299dd26d09233d1f64f9667474141cf9c6a6de7f2bc52c3bb44cfe679ff4b912c06df406283836b3581773cb76d375304f46239da5996594a8d03b14c02f1b35a432dc44a96331242ae31174*33a7ee59d6d17ed1ee99dc0a71771227e6f3734b17ba36eb589bdced56244135";
32 
module_attack_exec(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)33 u32         module_attack_exec    (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return ATTACK_EXEC;     }
module_dgst_pos0(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)34 u32         module_dgst_pos0      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return DGST_POS0;       }
module_dgst_pos1(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)35 u32         module_dgst_pos1      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return DGST_POS1;       }
module_dgst_pos2(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)36 u32         module_dgst_pos2      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return DGST_POS2;       }
module_dgst_pos3(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)37 u32         module_dgst_pos3      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return DGST_POS3;       }
module_dgst_size(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)38 u32         module_dgst_size      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return DGST_SIZE;       }
module_hash_category(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)39 u32         module_hash_category  (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return HASH_CATEGORY;   }
module_hash_name(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)40 const char *module_hash_name      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return HASH_NAME;       }
module_kern_type(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)41 u64         module_kern_type      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return KERN_TYPE;       }
module_opti_type(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)42 u32         module_opti_type      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return OPTI_TYPE;       }
module_opts_type(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)43 u64         module_opts_type      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return OPTS_TYPE;       }
module_salt_type(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)44 u32         module_salt_type      (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return SALT_TYPE;       }
module_st_hash(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)45 const char *module_st_hash        (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return ST_HASH;         }
module_st_pass(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)46 const char *module_st_pass        (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra) { return ST_PASS;         }
47 
48 typedef struct electrum
49 {
50   secp256k1_t coords;
51 
52   u32 data_buf[256];
53 
54 } electrum_t;
55 
56 typedef struct electrum_tmp
57 {
58   u64  ipad[8];
59   u64  opad[8];
60 
61   u64  dgst[8];
62   u64  out[8];
63 
64 } electrum_tmp_t;
65 
66 static const char *SIGNATURE_ELECTRUM = "$electrum$5*";
67 
module_esalt_size(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)68 u64 module_esalt_size (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra)
69 {
70   const u64 esalt_size = (const u64) sizeof (electrum_t);
71 
72   return esalt_size;
73 }
74 
module_tmp_size(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)75 u64 module_tmp_size (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra)
76 {
77   const u64 tmp_size = (const u64) sizeof (electrum_tmp_t);
78 
79   return tmp_size;
80 }
81 
module_pw_max(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra)82 u32 module_pw_max (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra)
83 {
84   const u32 pw_max = PW_MAX;
85 
86   return pw_max;
87 }
88 
module_unstable_warning(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const user_options_t * user_options,MAYBE_UNUSED const user_options_extra_t * user_options_extra,MAYBE_UNUSED const hc_device_param_t * device_param)89 bool module_unstable_warning (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const user_options_t *user_options, MAYBE_UNUSED const user_options_extra_t *user_options_extra, MAYBE_UNUSED const hc_device_param_t *device_param)
90 {
91   if (device_param->opencl_platform_vendor_id == VENDOR_ID_APPLE)
92   {
93     // self-test failed
94     if ((device_param->opencl_device_vendor_id == VENDOR_ID_INTEL_SDK) && (device_param->opencl_device_type & CL_DEVICE_TYPE_GPU))
95     {
96       return true;
97     }
98   }
99 
100   // amdgpu-pro-20.50-1234664-ubuntu-20.04 (legacy)
101   // test_1619943729/test_report.log:! unhandled return code 255, cmdline : cat test_1619943729/21800_passwords.txt | ./hashcat --quiet --potfile-disable --runtime 400 --hwmon-disable -O -D 2 --backend-vector-width 1 -a 0 -m 21800 test_1619943729/21800_hashes.txt
102   // test_1619955152/test_report.log:! unhandled return code 255, cmdline : cat test_1619955152/21800_passwords.txt | ./hashcat --quiet --potfile-disable --runtime 400 --hwmon-disable -D 2 --backend-vector-width 4 -a 0 -m 21800 test_1619955152/21800_hashes.txt
103   if ((device_param->opencl_device_vendor_id == VENDOR_ID_AMD) && (device_param->has_vperm == false))
104   {
105     return true;
106   }
107 
108   return false;
109 }
110 
module_hash_decode(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED void * digest_buf,MAYBE_UNUSED salt_t * salt,MAYBE_UNUSED void * esalt_buf,MAYBE_UNUSED void * hook_salt_buf,MAYBE_UNUSED hashinfo_t * hash_info,const char * line_buf,MAYBE_UNUSED const int line_len)111 int module_hash_decode (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED void *digest_buf, MAYBE_UNUSED salt_t *salt, MAYBE_UNUSED void *esalt_buf, MAYBE_UNUSED void *hook_salt_buf, MAYBE_UNUSED hashinfo_t *hash_info, const char *line_buf, MAYBE_UNUSED const int line_len)
112 {
113   u32 *digest = (u32 *) digest_buf;
114 
115   electrum_t *esalt = (electrum_t *) esalt_buf;
116 
117   token_t token;
118 
119   token.token_cnt  = 4;
120 
121   token.signatures_cnt    = 1;
122   token.signatures_buf[0] = SIGNATURE_ELECTRUM;
123 
124   token.len[0]     = 12;
125   token.attr[0]    = TOKEN_ATTR_FIXED_LENGTH
126                    | TOKEN_ATTR_VERIFY_SIGNATURE;
127 
128   token.sep[1]     = '*';
129   token.len_min[1] = 66;
130   token.len_max[1] = 66;
131   token.attr[1]    = TOKEN_ATTR_VERIFY_LENGTH
132                    | TOKEN_ATTR_VERIFY_HEX;
133 
134   token.sep[2]     = '*';
135   token.len_min[2] = 2048;
136   token.len_max[2] = 2048;
137   token.attr[2]    = TOKEN_ATTR_VERIFY_LENGTH
138                    | TOKEN_ATTR_VERIFY_HEX;
139 
140   token.sep[3]     = '*';
141   token.len_min[3] = 64;
142   token.len_max[3] = 64;
143   token.attr[3]    = TOKEN_ATTR_VERIFY_LENGTH
144                    | TOKEN_ATTR_VERIFY_HEX;
145 
146   const int rc_tokenizer = input_tokenizer ((const u8 *) line_buf, line_len, &token);
147 
148   if (rc_tokenizer != PARSER_OK) return (rc_tokenizer);
149 
150   const u8 *ephemeral_pos = token.buf[1];
151   const u8 *data_buf_pos  = token.buf[2];
152   const u8 *mac_pos       = token.buf[3];
153 
154   /**
155    * store data
156    */
157 
158   // ephemeral pubkey:
159 
160   u32 ephemeral_pubkey[9] = { 0 };
161 
162   u8 *ephemeral_pubkey_ptr = (u8 *) ephemeral_pubkey;
163 
164   for (u32 i = 0, j = 0; j < 66; i += 1, j += 2)
165   {
166     ephemeral_pubkey_ptr[i] = hex_to_u8 (ephemeral_pos + j);
167   }
168 
169   secp256k1_t *coords = &esalt->coords;
170 
171   u32 parse_success = parse_public (coords, ephemeral_pubkey);
172 
173   if (parse_success != 0) return (PARSER_SALT_VALUE);
174 
175   // data buf:
176 
177   u8* data_buf_ptr = (u8 *) esalt->data_buf;
178 
179   for (u32 i = 0, j = 0; j < 2048; i += 1, j += 2)
180   {
181     data_buf_ptr[i] = hex_to_u8 (data_buf_pos + j);
182   }
183 
184   // digest / mac:
185 
186   for (u32 i = 0, j = 0; j < 64; i += 1, j += 8)
187   {
188     digest[i] = hex_to_u32 (mac_pos + j);
189 
190     digest[i] = byte_swap_32 (digest[i]);
191   }
192 
193   // fake salt
194 
195   salt->salt_buf[0] = esalt->data_buf[0];
196   salt->salt_buf[1] = esalt->data_buf[1];
197   salt->salt_buf[2] = esalt->data_buf[2];
198   salt->salt_buf[3] = esalt->data_buf[3];
199 
200   salt->salt_len = 16;
201 
202   salt->salt_iter = 1024 - 1;
203 
204   return (PARSER_OK);
205 }
206 
module_hash_encode(MAYBE_UNUSED const hashconfig_t * hashconfig,MAYBE_UNUSED const void * digest_buf,MAYBE_UNUSED const salt_t * salt,MAYBE_UNUSED const void * esalt_buf,MAYBE_UNUSED const void * hook_salt_buf,MAYBE_UNUSED const hashinfo_t * hash_info,char * line_buf,MAYBE_UNUSED const int line_size)207 int module_hash_encode (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSED const void *digest_buf, MAYBE_UNUSED const salt_t *salt, MAYBE_UNUSED const void *esalt_buf, MAYBE_UNUSED const void *hook_salt_buf, MAYBE_UNUSED const hashinfo_t *hash_info, char *line_buf, MAYBE_UNUSED const int line_size)
208 {
209   u32 *digest = (u32 *) digest_buf;
210 
211   electrum_t *esalt = (electrum_t *) esalt_buf;
212 
213   // ephemeral pubkey:
214 
215   char ephemeral[66 + 1];
216 
217   memset (ephemeral, 0, sizeof (ephemeral));
218 
219   u8 type = 0x02 | (esalt->coords.xy[8] & 1); // odd or even y coordinate
220 
221   snprintf (ephemeral, 66 + 1, "%02x", type);
222 
223   for (int i = 31, j = 2; i >= 0; i -= 1, j += 2)
224   {
225     const u8 *ptr = (const u8 *) esalt->coords.xy;
226 
227     snprintf (ephemeral + j, 66 + 1 - j, "%02x", ptr[i]);
228   }
229 
230   // data buf:
231 
232   char data_buf[2048 + 1];
233 
234   memset (data_buf, 0, sizeof (data_buf));
235 
236   for (u32 i = 0, j = 0; i < 1024; i += 1, j += 2)
237   {
238     const u8 *ptr = (const u8 *) esalt->data_buf;
239 
240     snprintf (data_buf + j, 2048 + 1 - j, "%02x", ptr[i]);
241   }
242 
243   // mac:
244 
245   char mac[64 + 1];
246 
247   memset (mac, 0, sizeof (mac));
248 
249   for (u32 i = 0, j = 0; i < 8; i += 1, j += 8)
250   {
251     snprintf (mac + j, 64 + 1 - j, "%08x", digest[i]);
252   }
253 
254   int bytes_written = snprintf (line_buf, line_size, "%s%s*%s*%s",
255     SIGNATURE_ELECTRUM,
256     ephemeral,
257     data_buf,
258     mac);
259 
260   return bytes_written;
261 }
262 
module_init(module_ctx_t * module_ctx)263 void module_init (module_ctx_t *module_ctx)
264 {
265   module_ctx->module_context_size             = MODULE_CONTEXT_SIZE_CURRENT;
266   module_ctx->module_interface_version        = MODULE_INTERFACE_VERSION_CURRENT;
267 
268   module_ctx->module_attack_exec              = module_attack_exec;
269   module_ctx->module_benchmark_esalt          = MODULE_DEFAULT;
270   module_ctx->module_benchmark_hook_salt      = MODULE_DEFAULT;
271   module_ctx->module_benchmark_mask           = MODULE_DEFAULT;
272   module_ctx->module_benchmark_salt           = MODULE_DEFAULT;
273   module_ctx->module_build_plain_postprocess  = MODULE_DEFAULT;
274   module_ctx->module_deep_comp_kernel         = MODULE_DEFAULT;
275   module_ctx->module_deprecated_notice        = MODULE_DEFAULT;
276   module_ctx->module_dgst_pos0                = module_dgst_pos0;
277   module_ctx->module_dgst_pos1                = module_dgst_pos1;
278   module_ctx->module_dgst_pos2                = module_dgst_pos2;
279   module_ctx->module_dgst_pos3                = module_dgst_pos3;
280   module_ctx->module_dgst_size                = module_dgst_size;
281   module_ctx->module_dictstat_disable         = MODULE_DEFAULT;
282   module_ctx->module_esalt_size               = module_esalt_size;
283   module_ctx->module_extra_buffer_size        = MODULE_DEFAULT;
284   module_ctx->module_extra_tmp_size           = MODULE_DEFAULT;
285   module_ctx->module_extra_tuningdb_block     = MODULE_DEFAULT;
286   module_ctx->module_forced_outfile_format    = MODULE_DEFAULT;
287   module_ctx->module_hash_binary_count        = MODULE_DEFAULT;
288   module_ctx->module_hash_binary_parse        = MODULE_DEFAULT;
289   module_ctx->module_hash_binary_save         = MODULE_DEFAULT;
290   module_ctx->module_hash_decode_potfile      = MODULE_DEFAULT;
291   module_ctx->module_hash_decode_zero_hash    = MODULE_DEFAULT;
292   module_ctx->module_hash_decode              = module_hash_decode;
293   module_ctx->module_hash_encode_status       = MODULE_DEFAULT;
294   module_ctx->module_hash_encode_potfile      = MODULE_DEFAULT;
295   module_ctx->module_hash_encode              = module_hash_encode;
296   module_ctx->module_hash_init_selftest       = MODULE_DEFAULT;
297   module_ctx->module_hash_mode                = MODULE_DEFAULT;
298   module_ctx->module_hash_category            = module_hash_category;
299   module_ctx->module_hash_name                = module_hash_name;
300   module_ctx->module_hashes_count_min         = MODULE_DEFAULT;
301   module_ctx->module_hashes_count_max         = MODULE_DEFAULT;
302   module_ctx->module_hlfmt_disable            = MODULE_DEFAULT;
303   module_ctx->module_hook_extra_param_size    = MODULE_DEFAULT;
304   module_ctx->module_hook_extra_param_init    = MODULE_DEFAULT;
305   module_ctx->module_hook_extra_param_term    = MODULE_DEFAULT;
306   module_ctx->module_hook12                   = MODULE_DEFAULT;
307   module_ctx->module_hook23                   = MODULE_DEFAULT;
308   module_ctx->module_hook_salt_size           = MODULE_DEFAULT;
309   module_ctx->module_hook_size                = MODULE_DEFAULT;
310   module_ctx->module_jit_build_options        = MODULE_DEFAULT;
311   module_ctx->module_jit_cache_disable        = MODULE_DEFAULT;
312   module_ctx->module_kernel_accel_max         = MODULE_DEFAULT;
313   module_ctx->module_kernel_accel_min         = MODULE_DEFAULT;
314   module_ctx->module_kernel_loops_max         = MODULE_DEFAULT;
315   module_ctx->module_kernel_loops_min         = MODULE_DEFAULT;
316   module_ctx->module_kernel_threads_max       = MODULE_DEFAULT;
317   module_ctx->module_kernel_threads_min       = MODULE_DEFAULT;
318   module_ctx->module_kern_type                = module_kern_type;
319   module_ctx->module_kern_type_dynamic        = MODULE_DEFAULT;
320   module_ctx->module_opti_type                = module_opti_type;
321   module_ctx->module_opts_type                = module_opts_type;
322   module_ctx->module_outfile_check_disable    = MODULE_DEFAULT;
323   module_ctx->module_outfile_check_nocomp     = MODULE_DEFAULT;
324   module_ctx->module_potfile_custom_check     = MODULE_DEFAULT;
325   module_ctx->module_potfile_disable          = MODULE_DEFAULT;
326   module_ctx->module_potfile_keep_all_hashes  = MODULE_DEFAULT;
327   module_ctx->module_pwdump_column            = MODULE_DEFAULT;
328   module_ctx->module_pw_max                   = module_pw_max;
329   module_ctx->module_pw_min                   = MODULE_DEFAULT;
330   module_ctx->module_salt_max                 = MODULE_DEFAULT;
331   module_ctx->module_salt_min                 = MODULE_DEFAULT;
332   module_ctx->module_salt_type                = module_salt_type;
333   module_ctx->module_separator                = MODULE_DEFAULT;
334   module_ctx->module_st_hash                  = module_st_hash;
335   module_ctx->module_st_pass                  = module_st_pass;
336   module_ctx->module_tmp_size                 = module_tmp_size;
337   module_ctx->module_unstable_warning         = module_unstable_warning;
338   module_ctx->module_warmup_disable           = MODULE_DEFAULT;
339 }
340