Brain: Add brain_ctx_t to hashcat_ctx_t to enable runtime check if hashcat was compiled with brain support
This commit is contained in:
@@ -249,4 +249,7 @@ void brain_server_db_attack_init (brain_server_db_attack_t *brain_server_
|
||||
bool brain_server_db_attack_realloc (brain_server_db_attack_t *brain_server_db_attack, const i64 new_long_cnt, const i64 new_short_cnt);
|
||||
void brain_server_db_attack_free (brain_server_db_attack_t *brain_server_db_attack);
|
||||
|
||||
int brain_ctx_init (hashcat_ctx_t *hashcat_ctx);
|
||||
void brain_ctx_destroy (hashcat_ctx_t *hashcat_ctx);
|
||||
|
||||
#endif // _BRAIN_H
|
||||
|
||||
@@ -2120,6 +2120,13 @@ typedef struct user_options_extra
|
||||
|
||||
} user_options_extra_t;
|
||||
|
||||
typedef struct brain_ctx
|
||||
{
|
||||
bool support; // general brain support compiled in (server or client)
|
||||
bool enabled; // brain support required by user request on command line
|
||||
|
||||
} brain_ctx_t;
|
||||
|
||||
typedef struct bitmap_ctx
|
||||
{
|
||||
bool enabled;
|
||||
@@ -2585,6 +2592,7 @@ typedef struct module_ctx
|
||||
|
||||
typedef struct hashcat_ctx
|
||||
{
|
||||
brain_ctx_t *brain_ctx;
|
||||
bitmap_ctx_t *bitmap_ctx;
|
||||
combinator_ctx_t *combinator_ctx;
|
||||
cpt_ctx_t *cpt_ctx;
|
||||
|
||||
Reference in New Issue
Block a user