1
mirror of https://github.com/hashcat/hashcat synced 2024-11-20 23:27:31 +01:00

Add support for hash modules to usage.c

This commit is contained in:
jsteube 2019-01-06 13:23:45 +01:00
parent aec6a3bc99
commit 0186f025d3
10 changed files with 478 additions and 311 deletions

View File

@ -272,6 +272,7 @@ typedef enum kernel_workload
* output functions
*/
const char *strhashcategory (const u32 hash_category);
const char *stroptitype (const u32 opti_type);
int ascii_digest (const hashconfig_t *hashconfig, const hashes_t *hashes, const module_ctx_t *module_ctx, char *out_buf, const int out_size, const u32 salt_pos, const u32 digest_pos);

View File

@ -2469,8 +2469,25 @@ typedef enum hash_type
typedef enum hash_category
{
HASH_CATEGORY_UNDEFINED = 0,
HASH_CATEGORY_RAW_HASH = 1,
HASH_CATEGORY_UNDEFINED = 0,
HASH_CATEGORY_RAW_HASH = 1,
HASH_CATEGORY_RAW_HASH_SALTED = 2,
HASH_CATEGORY_RAW_HASH_AUTHENTICATED = 3,
HASH_CATEGORY_RAW_CIPHER_KPA = 4,
HASH_CATEGORY_GENERIC_KDF = 5,
HASH_CATEGORY_NETWORK_PROTOCOL = 6,
HASH_CATEGORY_FORUM_SOFTWARE = 7,
HASH_CATEGORY_DATABASE_SERVER = 8,
HASH_CATEGORY_NETWORK_SERVER = 9,
HASH_CATEGORY_RAW_CHECKSUM = 10,
HASH_CATEGORY_OS = 11,
HASH_CATEGORY_EAS = 12,
HASH_CATEGORY_ARCHIVE = 13,
HASH_CATEGORY_BACKUP = 14,
HASH_CATEGORY_FDE = 15,
HASH_CATEGORY_DOCUMENTS = 16,
HASH_CATEGORY_PASSWORD_MANAGER = 17,
HASH_CATEGORY_OTP = 18,
HASH_CATEGORY_PLAIN = 19,
} hash_category_t;

View File

@ -10,6 +10,6 @@
#include <string.h>
void usage_mini_print (const char *progname);
void usage_big_print (const char *progname);
void usage_big_print (hashcat_ctx_t *hashcat_ctx);
#endif // _USAGE_H

View File

@ -61,7 +61,7 @@ int benchmark_next (hashcat_ctx_t *hashcat_ctx)
{
char *modulefile = (char *) hcmalloc (HCBUFSIZ_TINY);
for (int i = cur; i < 99999; i++)
for (int i = cur; i < 100000; i++)
{
#if defined (_WIN)
snprintf (modulefile, HCBUFSIZ_TINY, "%s/modules/module_%05d.dll", folder_config->shared_dir, i);

View File

@ -47,6 +47,27 @@ static const char *OPTI_STR_USES_BITS_16 = "Uses-16-Bit";
static const char *OPTI_STR_USES_BITS_32 = "Uses-32-Bit";
static const char *OPTI_STR_USES_BITS_64 = "Uses-64-Bit";
static const char *HASH_CATEGORY_UNDEFINED_STR = "Undefined";
static const char *HASH_CATEGORY_RAW_HASH_STR = "Raw Hash";
static const char *HASH_CATEGORY_RAW_HASH_SALTED_STR = "Raw Hash, Salted and/or Iterated";
static const char *HASH_CATEGORY_RAW_HASH_AUTHENTICATED_STR = "Raw Hash, Authenticated";
static const char *HASH_CATEGORY_RAW_CIPHER_KPA_STR = "Raw Cipher, Known-Plaintext attack";
static const char *HASH_CATEGORY_GENERIC_KDF_STR = "Generic KDF";
static const char *HASH_CATEGORY_NETWORK_PROTOCOL_STR = "Network Protocols";
static const char *HASH_CATEGORY_FORUM_SOFTWARE_STR = "Forums, CMS, E-Commerce, Frameworks";
static const char *HASH_CATEGORY_DATABASE_SERVER_STR = "Database Server";
static const char *HASH_CATEGORY_NETWORK_SERVER_STR = "FTP, HTTP, SMTP, LDAP Server";
static const char *HASH_CATEGORY_RAW_CHECKSUM_STR = "Raw Checksum";
static const char *HASH_CATEGORY_OS_STR = "Operating System";
static const char *HASH_CATEGORY_EAS_STR = "Enterprise Application Software (EAS)";
static const char *HASH_CATEGORY_ARCHIVE_STR = "Archives";
static const char *HASH_CATEGORY_BACKUP_STR = "Backup";
static const char *HASH_CATEGORY_FDE_STR = "Full-Disk Encryption (FDE)";
static const char *HASH_CATEGORY_DOCUMENTS_STR = "Documents";
static const char *HASH_CATEGORY_PASSWORD_MANAGER_STR = "Password Managers";
static const char *HASH_CATEGORY_OTP_STR = "One-Time Passwords";
static const char *HASH_CATEGORY_PLAIN_STR = "Plaintext";
/**
* parser
*/
@ -260,6 +281,35 @@ static bool parse_and_store_generic_salt (u8 *out_buf, int *out_len, const u8 *i
* output
*/
const char *strhashcategory (const u32 hash_category)
{
switch (hash_category)
{
case HASH_CATEGORY_UNDEFINED: return HASH_CATEGORY_UNDEFINED_STR;
case HASH_CATEGORY_RAW_HASH: return HASH_CATEGORY_RAW_HASH_STR;
case HASH_CATEGORY_RAW_HASH_SALTED: return HASH_CATEGORY_RAW_HASH_SALTED_STR;
case HASH_CATEGORY_RAW_HASH_AUTHENTICATED: return HASH_CATEGORY_RAW_HASH_AUTHENTICATED_STR;
case HASH_CATEGORY_RAW_CIPHER_KPA: return HASH_CATEGORY_RAW_CIPHER_KPA_STR;
case HASH_CATEGORY_GENERIC_KDF: return HASH_CATEGORY_GENERIC_KDF_STR;
case HASH_CATEGORY_NETWORK_PROTOCOL: return HASH_CATEGORY_NETWORK_PROTOCOL_STR;
case HASH_CATEGORY_FORUM_SOFTWARE: return HASH_CATEGORY_FORUM_SOFTWARE_STR;
case HASH_CATEGORY_DATABASE_SERVER: return HASH_CATEGORY_DATABASE_SERVER_STR;
case HASH_CATEGORY_NETWORK_SERVER: return HASH_CATEGORY_NETWORK_SERVER_STR;
case HASH_CATEGORY_RAW_CHECKSUM: return HASH_CATEGORY_RAW_CHECKSUM_STR;
case HASH_CATEGORY_OS: return HASH_CATEGORY_OS_STR;
case HASH_CATEGORY_EAS: return HASH_CATEGORY_EAS_STR;
case HASH_CATEGORY_ARCHIVE: return HASH_CATEGORY_ARCHIVE_STR;
case HASH_CATEGORY_BACKUP: return HASH_CATEGORY_BACKUP_STR;
case HASH_CATEGORY_FDE: return HASH_CATEGORY_FDE_STR;
case HASH_CATEGORY_DOCUMENTS: return HASH_CATEGORY_DOCUMENTS_STR;
case HASH_CATEGORY_PASSWORD_MANAGER: return HASH_CATEGORY_PASSWORD_MANAGER_STR;
case HASH_CATEGORY_OTP: return HASH_CATEGORY_OTP_STR;
case HASH_CATEGORY_PLAIN: return HASH_CATEGORY_PLAIN_STR;
}
return NULL;
}
const char *stroptitype (const u32 opti_type)
{
switch (opti_type)
@ -625,10 +675,8 @@ static bool module_load (hashcat_ctx_t *hashcat_ctx, module_ctx_t *module_ctx, c
if (module_ctx->module_handle == NULL)
{
event_log_error (hashcat_ctx, "Cannot load module %s", module_file);
#if defined (_WIN)
event_log_error (hashcat_ctx, "Cannot load module %s", module_file); // todo: maybe there's a dlerror () equivalent
#else
event_log_error (hashcat_ctx, "%s", dlerror ());
#endif
@ -652,7 +700,10 @@ static bool module_load (hashcat_ctx_t *hashcat_ctx, module_ctx_t *module_ctx, c
static void module_unload (module_ctx_t *module_ctx)
{
hc_dlclose (module_ctx->module_handle);
if (module_ctx->module_handle)
{
hc_dlclose (module_ctx->module_handle);
}
}
int hashconfig_init (hashcat_ctx_t *hashcat_ctx)

View File

@ -1,4 +1,286 @@
" 900 | MD4 | Raw Hash",
" 0 | MD5 | Raw Hash",
" 5100 | Half MD5 | Raw Hash",
" 100 | SHA1 | Raw Hash",
" 1300 | SHA2-224 | Raw Hash",
" 1400 | SHA2-256 | Raw Hash",
" 10800 | SHA2-384 | Raw Hash",
" 1700 | SHA2-512 | Raw Hash",
" 17300 | SHA3-224 | Raw Hash",
" 17400 | SHA3-256 | Raw Hash",
" 17500 | SHA3-384 | Raw Hash",
" 17600 | SHA3-512 | Raw Hash",
" 17700 | Keccak-224 | Raw Hash",
" 17800 | Keccak-256 | Raw Hash",
" 17900 | Keccak-384 | Raw Hash",
" 18000 | Keccak-512 | Raw Hash",
" 600 | BLAKE2b-512 | Raw Hash",
" 10100 | SipHash | Raw Hash",
" 6000 | RIPEMD-160 | Raw Hash",
" 6100 | Whirlpool | Raw Hash",
" 6900 | GOST R 34.11-94 | Raw Hash",
" 11700 | GOST R 34.11-2012 (Streebog) 256-bit, big-endian | Raw Hash",
" 11800 | GOST R 34.11-2012 (Streebog) 512-bit, big-endian | Raw Hash",
" 10 | md5($pass.$salt) | Raw Hash, Salted and/or Iterated",
" 20 | md5($salt.$pass) | Raw Hash, Salted and/or Iterated",
" 30 | md5(utf16le($pass).$salt) | Raw Hash, Salted and/or Iterated",
" 40 | md5($salt.utf16le($pass)) | Raw Hash, Salted and/or Iterated",
" 3800 | md5($salt.$pass.$salt) | Raw Hash, Salted and/or Iterated",
" 3710 | md5($salt.md5($pass)) | Raw Hash, Salted and/or Iterated",
" 4010 | md5($salt.md5($salt.$pass)) | Raw Hash, Salted and/or Iterated",
" 4110 | md5($salt.md5($pass.$salt)) | Raw Hash, Salted and/or Iterated",
" 2600 | md5(md5($pass)) | Raw Hash, Salted and/or Iterated",
" 3910 | md5(md5($pass).md5($salt)) | Raw Hash, Salted and/or Iterated",
" 4300 | md5(strtoupper(md5($pass))) | Raw Hash, Salted and/or Iterated",
" 4400 | md5(sha1($pass)) | Raw Hash, Salted and/or Iterated",
" 110 | sha1($pass.$salt) | Raw Hash, Salted and/or Iterated",
" 120 | sha1($salt.$pass) | Raw Hash, Salted and/or Iterated",
" 130 | sha1(utf16le($pass).$salt) | Raw Hash, Salted and/or Iterated",
" 140 | sha1($salt.utf16le($pass)) | Raw Hash, Salted and/or Iterated",
" 4500 | sha1(sha1($pass)) | Raw Hash, Salted and/or Iterated",
" 4520 | sha1($salt.sha1($pass)) | Raw Hash, Salted and/or Iterated",
" 4700 | sha1(md5($pass)) | Raw Hash, Salted and/or Iterated",
" 18500 | sha1(md5(md5($pass))) | Raw Hash, Salted and/or Iterated",
" 4900 | sha1($salt.$pass.$salt) | Raw Hash, Salted and/or Iterated",
" 14400 | sha1(CX) | Raw Hash, Salted and/or Iterated",
" 1410 | sha256($pass.$salt) | Raw Hash, Salted and/or Iterated",
" 1420 | sha256($salt.$pass) | Raw Hash, Salted and/or Iterated",
" 1430 | sha256(utf16le($pass).$salt) | Raw Hash, Salted and/or Iterated",
" 1440 | sha256($salt.utf16le($pass)) | Raw Hash, Salted and/or Iterated",
" 1710 | sha512($pass.$salt) | Raw Hash, Salted and/or Iterated",
" 1720 | sha512($salt.$pass) | Raw Hash, Salted and/or Iterated",
" 1730 | sha512(utf16le($pass).$salt) | Raw Hash, Salted and/or Iterated",
" 1740 | sha512($salt.utf16le($pass)) | Raw Hash, Salted and/or Iterated",
" 50 | HMAC-MD5 (key = $pass) | Raw Hash, Authenticated",
" 60 | HMAC-MD5 (key = $salt) | Raw Hash, Authenticated",
" 150 | HMAC-SHA1 (key = $pass) | Raw Hash, Authenticated",
" 160 | HMAC-SHA1 (key = $salt) | Raw Hash, Authenticated",
" 1450 | HMAC-SHA256 (key = $pass) | Raw Hash, Authenticated",
" 1460 | HMAC-SHA256 (key = $salt) | Raw Hash, Authenticated",
" 1750 | HMAC-SHA512 (key = $pass) | Raw Hash, Authenticated",
" 1760 | HMAC-SHA512 (key = $salt) | Raw Hash, Authenticated",
" 11750 | HMAC-Streebog-256 (key = $pass), big-endian | Raw Hash, Authenticated",
" 11760 | HMAC-Streebog-256 (key = $salt), big-endian | Raw Hash, Authenticated",
" 11850 | HMAC-Streebog-512 (key = $pass), big-endian | Raw Hash, Authenticated",
" 11860 | HMAC-Streebog-512 (key = $salt), big-endian | Raw Hash, Authenticated",
" 14000 | DES (PT = $salt, key = $pass) | Raw Cipher, Known-Plaintext attack",
" 14100 | 3DES (PT = $salt, key = $pass) | Raw Cipher, Known-Plaintext attack",
" 14900 | Skip32 (PT = $salt, key = $pass) | Raw Cipher, Known-Plaintext attack",
" 15400 | ChaCha20 | Raw Cipher, Known-Plaintext attack",
" 400 | phpass | Generic KDF",
" 8900 | scrypt | Generic KDF",
" 11900 | PBKDF2-HMAC-MD5 | Generic KDF",
" 12000 | PBKDF2-HMAC-SHA1 | Generic KDF",
" 10900 | PBKDF2-HMAC-SHA256 | Generic KDF",
" 12100 | PBKDF2-HMAC-SHA512 | Generic KDF",
" 23 | Skype | Network Protocols",
" 2500 | WPA-EAPOL-PBKDF2 | Network Protocols",
" 2501 | WPA-EAPOL-PMK | Network Protocols",
" 16800 | WPA-PMKID-PBKDF2 | Network Protocols",
" 16801 | WPA-PMKID-PMK | Network Protocols",
" 4800 | iSCSI CHAP authentication, MD5(CHAP) | Network Protocols",
" 5300 | IKE-PSK MD5 | Network Protocols",
" 5400 | IKE-PSK SHA1 | Network Protocols",
" 5500 | NetNTLMv1 | Network Protocols",
" 5500 | NetNTLMv1+ESS | Network Protocols",
" 5600 | NetNTLMv2 | Network Protocols",
" 7300 | IPMI2 RAKP HMAC-SHA1 | Network Protocols",
" 7500 | Kerberos 5 AS-REQ Pre-Auth etype 23 | Network Protocols",
" 8300 | DNSSEC (NSEC3) | Network Protocols",
" 10200 | CRAM-MD5 | Network Protocols",
" 11100 | PostgreSQL CRAM (MD5) | Network Protocols",
" 11200 | MySQL CRAM (SHA1) | Network Protocols",
" 11400 | SIP digest authentication (MD5) | Network Protocols",
" 13100 | Kerberos 5 TGS-REP etype 23 | Network Protocols",
" 16100 | TACACS+ | Network Protocols",
" 16500 | JWT (JSON Web Token) | Network Protocols",
" 18200 | Kerberos 5 AS-REP etype 23 | Network Protocols",
" 121 | SMF (Simple Machines Forum) > v1.1 | Forums, CMS, E-Commerce, Frameworks",
" 400 | phpBB3 (MD5) | Forums, CMS, E-Commerce, Frameworks",
" 2611 | vBulletin < v3.8.5 | Forums, CMS, E-Commerce, Frameworks",
" 2711 | vBulletin >= v3.8.5 | Forums, CMS, E-Commerce, Frameworks",
" 2811 | MyBB 1.2+ | Forums, CMS, E-Commerce, Frameworks",
" 2811 | IPB2+ (Invision Power Board) | Forums, CMS, E-Commerce, Frameworks",
" 8400 | WBB3 (Woltlab Burning Board) | Forums, CMS, E-Commerce, Frameworks",
" 11 | Joomla < 2.5.18 | Forums, CMS, E-Commerce, Frameworks",
" 400 | Joomla >= 2.5.18 (MD5) | Forums, CMS, E-Commerce, Frameworks",
" 400 | WordPress (MD5) | Forums, CMS, E-Commerce, Frameworks",
" 2612 | PHPS | Forums, CMS, E-Commerce, Frameworks",
" 7900 | Drupal7 | Forums, CMS, E-Commerce, Frameworks",
" 21 | osCommerce | Forums, CMS, E-Commerce, Frameworks",
" 21 | xt:Commerce | Forums, CMS, E-Commerce, Frameworks",
" 11000 | PrestaShop | Forums, CMS, E-Commerce, Frameworks",
" 124 | Django (SHA-1) | Forums, CMS, E-Commerce, Frameworks",
" 10000 | Django (PBKDF2-SHA256) | Forums, CMS, E-Commerce, Frameworks",
" 16000 | Tripcode | Forums, CMS, E-Commerce, Frameworks",
" 3711 | MediaWiki B type | Forums, CMS, E-Commerce, Frameworks",
" 13900 | OpenCart | Forums, CMS, E-Commerce, Frameworks",
" 4521 | Redmine | Forums, CMS, E-Commerce, Frameworks",
" 4522 | PunBB | Forums, CMS, E-Commerce, Frameworks",
" 12001 | Atlassian (PBKDF2-HMAC-SHA1) | Forums, CMS, E-Commerce, Frameworks",
" 12 | PostgreSQL | Database Server",
" 131 | MSSQL (2000) | Database Server",
" 132 | MSSQL (2005) | Database Server",
" 1731 | MSSQL (2012, 2014) | Database Server",
" 200 | MySQL323 | Database Server",
" 300 | MySQL4.1/MySQL5 | Database Server",
" 3100 | Oracle H: Type (Oracle 7+) | Database Server",
" 112 | Oracle S: Type (Oracle 11+) | Database Server",
" 12300 | Oracle T: Type (Oracle 12+) | Database Server",
" 8000 | Sybase ASE | Database Server",
" 141 | Episerver 6.x < .NET 4 | HTTP, SMTP, LDAP Server",
" 1441 | Episerver 6.x >= .NET 4 | HTTP, SMTP, LDAP Server",
" 1600 | Apache $apr1$ MD5, md5apr1, MD5 (APR) | HTTP, SMTP, LDAP Server",
" 12600 | ColdFusion 10+ | HTTP, SMTP, LDAP Server",
" 1421 | hMailServer | HTTP, SMTP, LDAP Server",
" 101 | nsldap, SHA-1(Base64), Netscape LDAP SHA | HTTP, SMTP, LDAP Server",
" 111 | nsldaps, SSHA-1(Base64), Netscape LDAP SSHA | HTTP, SMTP, LDAP Server",
" 1411 | SSHA-256(Base64), LDAP {SSHA256} | HTTP, SMTP, LDAP Server",
" 1711 | SSHA-512(Base64), LDAP {SSHA512} | HTTP, SMTP, LDAP Server",
" 16400 | CRAM-MD5 Dovecot | HTTP, SMTP, LDAP Server",
" 15000 | FileZilla Server >= 0.9.55 | FTP Server",
" 11500 | CRC32 | Checksums",
" 3000 | LM | Operating Systems",
" 1000 | NTLM | Operating Systems",
" 1100 | Domain Cached Credentials (DCC), MS Cache | Operating Systems",
" 2100 | Domain Cached Credentials 2 (DCC2), MS Cache 2 | Operating Systems",
" 15300 | DPAPI masterkey file v1 | Operating Systems",
" 15900 | DPAPI masterkey file v2 | Operating Systems",
" 12800 | MS-AzureSync PBKDF2-HMAC-SHA256 | Operating Systems",
" 1500 | descrypt, DES (Unix), Traditional DES | Operating Systems",
" 12400 | BSDi Crypt, Extended DES | Operating Systems",
" 500 | md5crypt, MD5 (Unix), Cisco-IOS $1$ (MD5) | Operating Systems",
" 3200 | bcrypt $2*$, Blowfish (Unix) | Operating Systems",
" 7400 | sha256crypt $5$, SHA256 (Unix) | Operating Systems",
" 1800 | sha512crypt $6$, SHA512 (Unix) | Operating Systems",
" 122 | macOS v10.4, MacOS v10.5, MacOS v10.6 | Operating Systems",
" 1722 | macOS v10.7 | Operating Systems",
" 7100 | macOS v10.8+ (PBKDF2-SHA512) | Operating Systems",
" 6300 | AIX {smd5} | Operating Systems",
" 6700 | AIX {ssha1} | Operating Systems",
" 6400 | AIX {ssha256} | Operating Systems",
" 6500 | AIX {ssha512} | Operating Systems",
" 2400 | Cisco-PIX MD5 | Operating Systems",
" 2410 | Cisco-ASA MD5 | Operating Systems",
" 500 | Cisco-IOS $1$ (MD5) | Operating Systems",
" 5700 | Cisco-IOS type 4 (SHA256) | Operating Systems",
" 9200 | Cisco-IOS $8$ (PBKDF2-SHA256) | Operating Systems",
" 9300 | Cisco-IOS $9$ (scrypt) | Operating Systems",
" 22 | Juniper NetScreen/SSG (ScreenOS) | Operating Systems",
" 501 | Juniper IVE | Operating Systems",
" 15100 | Juniper/NetBSD sha1crypt | Operating Systems",
" 7000 | FortiGate (FortiOS) | Operating Systems",
" 5800 | Samsung Android Password/PIN | Operating Systems",
" 13800 | Windows Phone 8+ PIN/password | Operating Systems",
" 8100 | Citrix NetScaler | Operating Systems",
" 8500 | RACF | Operating Systems",
" 7200 | GRUB 2 | Operating Systems",
" 9900 | Radmin2 | Operating Systems",
" 125 | ArubaOS | Operating Systems",
" 7700 | SAP CODVN B (BCODE) | Enterprise Application Software (EAS)",
" 7701 | SAP CODVN B (BCODE) via RFC_READ_TABLE | Enterprise Application Software (EAS)",
" 7800 | SAP CODVN F/G (PASSCODE) | Enterprise Application Software (EAS)",
" 7801 | SAP CODVN F/G (PASSCODE) via RFC_READ_TABLE | Enterprise Application Software (EAS)",
" 10300 | SAP CODVN H (PWDSALTEDHASH) iSSHA-1 | Enterprise Application Software (EAS)",
" 8600 | Lotus Notes/Domino 5 | Enterprise Application Software (EAS)",
" 8700 | Lotus Notes/Domino 6 | Enterprise Application Software (EAS)",
" 9100 | Lotus Notes/Domino 8 | Enterprise Application Software (EAS)",
" 133 | PeopleSoft | Enterprise Application Software (EAS)",
" 13500 | PeopleSoft PS_TOKEN | Enterprise Application Software (EAS)",
" 11600 | 7-Zip | Archives",
" 12500 | RAR3-hp | Archives",
" 13000 | RAR5 | Archives",
" 13200 | AxCrypt | Archives",
" 13300 | AxCrypt in-memory SHA1 | Archives",
" 13600 | WinZip | Archives",
" 14700 | iTunes backup < 10.0 | Backup",
" 14800 | iTunes backup >= 10.0 | Backup",
" 62XY | TrueCrypt | Full-Disk Encryption (FDE)",
" X | 1 = PBKDF2-HMAC-RIPEMD160 | Full-Disk Encryption (FDE)",
" X | 2 = PBKDF2-HMAC-SHA512 | Full-Disk Encryption (FDE)",
" X | 3 = PBKDF2-HMAC-Whirlpool | Full-Disk Encryption (FDE)",
" X | 4 = PBKDF2-HMAC-RIPEMD160 + boot-mode | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure AES | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Serpent | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Serpent | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded AES-Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Serpent-AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Twofish-Serpent | Full-Disk Encryption (FDE)",
" Y | 3 = XTS 1536 bit all | Full-Disk Encryption (FDE)",
" 8800 | Android FDE <= 4.3 | Full-Disk Encryption (FDE)",
" 12900 | Android FDE (Samsung DEK) | Full-Disk Encryption (FDE)",
" 12200 | eCryptfs | Full-Disk Encryption (FDE)",
" 137XY | VeraCrypt | Full-Disk Encryption (FDE)",
" X | 1 = PBKDF2-HMAC-RIPEMD160 | Full-Disk Encryption (FDE)",
" X | 2 = PBKDF2-HMAC-SHA512 | Full-Disk Encryption (FDE)",
" X | 3 = PBKDF2-HMAC-Whirlpool | Full-Disk Encryption (FDE)",
" X | 4 = PBKDF2-HMAC-RIPEMD160 + boot-mode | Full-Disk Encryption (FDE)",
" X | 5 = PBKDF2-HMAC-SHA256 | Full-Disk Encryption (FDE)",
" X | 6 = PBKDF2-HMAC-SHA256 + boot-mode | Full-Disk Encryption (FDE)",
" X | 7 = PBKDF2-HMAC-Streebog-512 | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure AES | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Serpent | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Twofish | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Camellia | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Kuznyechik | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Serpent | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Camellia | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Kuznyechik | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded AES-Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Camellia-Kuznyechik | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Camellia-Serpent | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Kuznyechik-AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Kuznyechik-Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Serpent-AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Twofish-Serpent | Full-Disk Encryption (FDE)",
" Y | 3 = XTS 1536 bit all | Full-Disk Encryption (FDE)",
" 14600 | LUKS | Full-Disk Encryption (FDE)",
" 16700 | FileVault 2 | Full-Disk Encryption (FDE)",
" 18300 | Apple File System (APFS) | Full-Disk Encryption (FDE)",
" 9700 | MS Office <= 2003 $0/$1, MD5 + RC4 | Documents",
" 9710 | MS Office <= 2003 $0/$1, MD5 + RC4, collider #1 | Documents",
" 9720 | MS Office <= 2003 $0/$1, MD5 + RC4, collider #2 | Documents",
" 9800 | MS Office <= 2003 $3/$4, SHA1 + RC4 | Documents",
" 9810 | MS Office <= 2003 $3, SHA1 + RC4, collider #1 | Documents",
" 9820 | MS Office <= 2003 $3, SHA1 + RC4, collider #2 | Documents",
" 9400 | MS Office 2007 | Documents",
" 9500 | MS Office 2010 | Documents",
" 9600 | MS Office 2013 | Documents",
" 10400 | PDF 1.1 - 1.3 (Acrobat 2 - 4) | Documents",
" 10410 | PDF 1.1 - 1.3 (Acrobat 2 - 4), collider #1 | Documents",
" 10420 | PDF 1.1 - 1.3 (Acrobat 2 - 4), collider #2 | Documents",
" 10500 | PDF 1.4 - 1.6 (Acrobat 5 - 8) | Documents",
" 10600 | PDF 1.7 Level 3 (Acrobat 9) | Documents",
" 10700 | PDF 1.7 Level 8 (Acrobat 10 - 11) | Documents",
" 16200 | Apple Secure Notes | Documents",
" 18600 | Open Document Format (ODF) 1.1 (SHA-1, Blowfish) | Documents",
" 18400 | Open Document Format (ODF) 1.2 (SHA-256, AES) | Documents",
" 9000 | Password Safe v2 | Password Managers",
" 5200 | Password Safe v3 | Password Managers",
" 6800 | LastPass + LastPass sniffed | Password Managers",
" 6600 | 1Password, agilekeychain | Password Managers",
" 8200 | 1Password, cloudkeychain | Password Managers",
" 11300 | Bitcoin/Litecoin wallet.dat | Password Managers",
" 12700 | Blockchain, My Wallet | Password Managers",
" 15200 | Blockchain, My Wallet, V2 | Password Managers",
" 16600 | Electrum Wallet (Salt-Type 1-2) | Password Managers",
" 13400 | KeePass 1 (AES/Twofish) and KeePass 2 (AES) | Password Managers",
" 15500 | JKS Java Key Store Private Keys (SHA1) | Password Managers",
" 15600 | Ethereum Wallet, PBKDF2-HMAC-SHA256 | Password Managers",
" 15700 | Ethereum Wallet, SCRYPT | Password Managers",
" 16300 | Ethereum Pre-Sale Wallet, PBKDF2-HMAC-SHA256 | Password Managers",
" 16900 | Ansible Vault | Password Managers",
" 18100 | TOTP (HMAC-SHA1) | One-Time Passwords",
" 99999 | Plaintext | Plaintext",
static const char *ST_PASS_HEX_02501 = "7f620a599c445155935a35634638fa67b4aafecb92e0bd8625388757a63c2dda";
static const char *ST_PASS_BIN_09710 = "\x91\xb2\xe0\x62\xb9";
static const char *ST_PASS_BIN_09810 = "\xb8\xf6\x36\x19\xca";

View File

@ -1098,20 +1098,6 @@ int main (int argc, char **argv)
return 0;
}
if (user_options->usage == true)
{
usage_big_print (PROGNAME);
return 0;
}
if (user_options->example_hashes == true)
{
example_hashes (hashcat_ctx);
return 0;
}
// init a hashcat session; this initializes opencl devices, hwmon, etc
welcome_screen (hashcat_ctx, VERSION_TAG);
@ -1122,7 +1108,19 @@ int main (int argc, char **argv)
if (rc_session_init == 0)
{
if (user_options->opencl_info == true)
if (user_options->usage == true)
{
usage_big_print (hashcat_ctx);
rc_final = 0;
}
else if (user_options->example_hashes == true)
{
example_hashes (hashcat_ctx);
rc_final = 0;
}
else if (user_options->opencl_info == true)
{
// if this is just opencl_info, no need to execute some real cracking session

View File

@ -537,6 +537,8 @@ void example_hashes (hashcat_ctx_t *hashcat_ctx)
{
user_options_t *user_options = hashcat_ctx->user_options;
fclose (stderr); // a bit harsh
if (user_options->hash_mode_chgd == true)
{
const int rc = hashconfig_init (hashcat_ctx);

View File

@ -6,6 +6,8 @@
#include "common.h"
#include "types.h"
#include "shared.h"
#include "interface.h"
#include "memory.h"
#include "usage.h"
static const char *const USAGE_MINI[] =
@ -16,10 +18,8 @@ static const char *const USAGE_MINI[] =
NULL
};
static const char *const USAGE_BIG[] =
static const char *const USAGE_BIG_PRE_HASHMODES[] =
{
"%s - advanced password recovery",
"",
"Usage: %s [options]... hash|hashfile|hccapxfile [dictionary|mask|directory]...",
"",
"- [ Options ] -",
@ -134,286 +134,11 @@ static const char *const USAGE_BIG[] =
"",
" # | Name | Category",
" ======+==================================================+======================================",
" 900 | MD4 | Raw Hash",
" 0 | MD5 | Raw Hash",
" 5100 | Half MD5 | Raw Hash",
" 100 | SHA1 | Raw Hash",
" 1300 | SHA2-224 | Raw Hash",
" 1400 | SHA2-256 | Raw Hash",
" 10800 | SHA2-384 | Raw Hash",
" 1700 | SHA2-512 | Raw Hash",
" 17300 | SHA3-224 | Raw Hash",
" 17400 | SHA3-256 | Raw Hash",
" 17500 | SHA3-384 | Raw Hash",
" 17600 | SHA3-512 | Raw Hash",
" 17700 | Keccak-224 | Raw Hash",
" 17800 | Keccak-256 | Raw Hash",
" 17900 | Keccak-384 | Raw Hash",
" 18000 | Keccak-512 | Raw Hash",
" 600 | BLAKE2b-512 | Raw Hash",
" 10100 | SipHash | Raw Hash",
" 6000 | RIPEMD-160 | Raw Hash",
" 6100 | Whirlpool | Raw Hash",
" 6900 | GOST R 34.11-94 | Raw Hash",
" 11700 | GOST R 34.11-2012 (Streebog) 256-bit, big-endian | Raw Hash",
" 11800 | GOST R 34.11-2012 (Streebog) 512-bit, big-endian | Raw Hash",
" 10 | md5($pass.$salt) | Raw Hash, Salted and/or Iterated",
" 20 | md5($salt.$pass) | Raw Hash, Salted and/or Iterated",
" 30 | md5(utf16le($pass).$salt) | Raw Hash, Salted and/or Iterated",
" 40 | md5($salt.utf16le($pass)) | Raw Hash, Salted and/or Iterated",
" 3800 | md5($salt.$pass.$salt) | Raw Hash, Salted and/or Iterated",
" 3710 | md5($salt.md5($pass)) | Raw Hash, Salted and/or Iterated",
" 4010 | md5($salt.md5($salt.$pass)) | Raw Hash, Salted and/or Iterated",
" 4110 | md5($salt.md5($pass.$salt)) | Raw Hash, Salted and/or Iterated",
" 2600 | md5(md5($pass)) | Raw Hash, Salted and/or Iterated",
" 3910 | md5(md5($pass).md5($salt)) | Raw Hash, Salted and/or Iterated",
" 4300 | md5(strtoupper(md5($pass))) | Raw Hash, Salted and/or Iterated",
" 4400 | md5(sha1($pass)) | Raw Hash, Salted and/or Iterated",
" 110 | sha1($pass.$salt) | Raw Hash, Salted and/or Iterated",
" 120 | sha1($salt.$pass) | Raw Hash, Salted and/or Iterated",
" 130 | sha1(utf16le($pass).$salt) | Raw Hash, Salted and/or Iterated",
" 140 | sha1($salt.utf16le($pass)) | Raw Hash, Salted and/or Iterated",
" 4500 | sha1(sha1($pass)) | Raw Hash, Salted and/or Iterated",
" 4520 | sha1($salt.sha1($pass)) | Raw Hash, Salted and/or Iterated",
" 4700 | sha1(md5($pass)) | Raw Hash, Salted and/or Iterated",
" 18500 | sha1(md5(md5($pass))) | Raw Hash, Salted and/or Iterated",
" 4900 | sha1($salt.$pass.$salt) | Raw Hash, Salted and/or Iterated",
" 14400 | sha1(CX) | Raw Hash, Salted and/or Iterated",
" 1410 | sha256($pass.$salt) | Raw Hash, Salted and/or Iterated",
" 1420 | sha256($salt.$pass) | Raw Hash, Salted and/or Iterated",
" 1430 | sha256(utf16le($pass).$salt) | Raw Hash, Salted and/or Iterated",
" 1440 | sha256($salt.utf16le($pass)) | Raw Hash, Salted and/or Iterated",
" 1710 | sha512($pass.$salt) | Raw Hash, Salted and/or Iterated",
" 1720 | sha512($salt.$pass) | Raw Hash, Salted and/or Iterated",
" 1730 | sha512(utf16le($pass).$salt) | Raw Hash, Salted and/or Iterated",
" 1740 | sha512($salt.utf16le($pass)) | Raw Hash, Salted and/or Iterated",
" 50 | HMAC-MD5 (key = $pass) | Raw Hash, Authenticated",
" 60 | HMAC-MD5 (key = $salt) | Raw Hash, Authenticated",
" 150 | HMAC-SHA1 (key = $pass) | Raw Hash, Authenticated",
" 160 | HMAC-SHA1 (key = $salt) | Raw Hash, Authenticated",
" 1450 | HMAC-SHA256 (key = $pass) | Raw Hash, Authenticated",
" 1460 | HMAC-SHA256 (key = $salt) | Raw Hash, Authenticated",
" 1750 | HMAC-SHA512 (key = $pass) | Raw Hash, Authenticated",
" 1760 | HMAC-SHA512 (key = $salt) | Raw Hash, Authenticated",
" 11750 | HMAC-Streebog-256 (key = $pass), big-endian | Raw Hash, Authenticated",
" 11760 | HMAC-Streebog-256 (key = $salt), big-endian | Raw Hash, Authenticated",
" 11850 | HMAC-Streebog-512 (key = $pass), big-endian | Raw Hash, Authenticated",
" 11860 | HMAC-Streebog-512 (key = $salt), big-endian | Raw Hash, Authenticated",
" 14000 | DES (PT = $salt, key = $pass) | Raw Cipher, Known-Plaintext attack",
" 14100 | 3DES (PT = $salt, key = $pass) | Raw Cipher, Known-Plaintext attack",
" 14900 | Skip32 (PT = $salt, key = $pass) | Raw Cipher, Known-Plaintext attack",
" 15400 | ChaCha20 | Raw Cipher, Known-Plaintext attack",
" 400 | phpass | Generic KDF",
" 8900 | scrypt | Generic KDF",
" 11900 | PBKDF2-HMAC-MD5 | Generic KDF",
" 12000 | PBKDF2-HMAC-SHA1 | Generic KDF",
" 10900 | PBKDF2-HMAC-SHA256 | Generic KDF",
" 12100 | PBKDF2-HMAC-SHA512 | Generic KDF",
" 23 | Skype | Network Protocols",
" 2500 | WPA-EAPOL-PBKDF2 | Network Protocols",
" 2501 | WPA-EAPOL-PMK | Network Protocols",
" 16800 | WPA-PMKID-PBKDF2 | Network Protocols",
" 16801 | WPA-PMKID-PMK | Network Protocols",
" 4800 | iSCSI CHAP authentication, MD5(CHAP) | Network Protocols",
" 5300 | IKE-PSK MD5 | Network Protocols",
" 5400 | IKE-PSK SHA1 | Network Protocols",
" 5500 | NetNTLMv1 | Network Protocols",
" 5500 | NetNTLMv1+ESS | Network Protocols",
" 5600 | NetNTLMv2 | Network Protocols",
" 7300 | IPMI2 RAKP HMAC-SHA1 | Network Protocols",
" 7500 | Kerberos 5 AS-REQ Pre-Auth etype 23 | Network Protocols",
" 8300 | DNSSEC (NSEC3) | Network Protocols",
" 10200 | CRAM-MD5 | Network Protocols",
" 11100 | PostgreSQL CRAM (MD5) | Network Protocols",
" 11200 | MySQL CRAM (SHA1) | Network Protocols",
" 11400 | SIP digest authentication (MD5) | Network Protocols",
" 13100 | Kerberos 5 TGS-REP etype 23 | Network Protocols",
" 16100 | TACACS+ | Network Protocols",
" 16500 | JWT (JSON Web Token) | Network Protocols",
" 18200 | Kerberos 5 AS-REP etype 23 | Network Protocols",
" 121 | SMF (Simple Machines Forum) > v1.1 | Forums, CMS, E-Commerce, Frameworks",
" 400 | phpBB3 (MD5) | Forums, CMS, E-Commerce, Frameworks",
" 2611 | vBulletin < v3.8.5 | Forums, CMS, E-Commerce, Frameworks",
" 2711 | vBulletin >= v3.8.5 | Forums, CMS, E-Commerce, Frameworks",
" 2811 | MyBB 1.2+ | Forums, CMS, E-Commerce, Frameworks",
" 2811 | IPB2+ (Invision Power Board) | Forums, CMS, E-Commerce, Frameworks",
" 8400 | WBB3 (Woltlab Burning Board) | Forums, CMS, E-Commerce, Frameworks",
" 11 | Joomla < 2.5.18 | Forums, CMS, E-Commerce, Frameworks",
" 400 | Joomla >= 2.5.18 (MD5) | Forums, CMS, E-Commerce, Frameworks",
" 400 | WordPress (MD5) | Forums, CMS, E-Commerce, Frameworks",
" 2612 | PHPS | Forums, CMS, E-Commerce, Frameworks",
" 7900 | Drupal7 | Forums, CMS, E-Commerce, Frameworks",
" 21 | osCommerce | Forums, CMS, E-Commerce, Frameworks",
" 21 | xt:Commerce | Forums, CMS, E-Commerce, Frameworks",
" 11000 | PrestaShop | Forums, CMS, E-Commerce, Frameworks",
" 124 | Django (SHA-1) | Forums, CMS, E-Commerce, Frameworks",
" 10000 | Django (PBKDF2-SHA256) | Forums, CMS, E-Commerce, Frameworks",
" 16000 | Tripcode | Forums, CMS, E-Commerce, Frameworks",
" 3711 | MediaWiki B type | Forums, CMS, E-Commerce, Frameworks",
" 13900 | OpenCart | Forums, CMS, E-Commerce, Frameworks",
" 4521 | Redmine | Forums, CMS, E-Commerce, Frameworks",
" 4522 | PunBB | Forums, CMS, E-Commerce, Frameworks",
" 12001 | Atlassian (PBKDF2-HMAC-SHA1) | Forums, CMS, E-Commerce, Frameworks",
" 12 | PostgreSQL | Database Server",
" 131 | MSSQL (2000) | Database Server",
" 132 | MSSQL (2005) | Database Server",
" 1731 | MSSQL (2012, 2014) | Database Server",
" 200 | MySQL323 | Database Server",
" 300 | MySQL4.1/MySQL5 | Database Server",
" 3100 | Oracle H: Type (Oracle 7+) | Database Server",
" 112 | Oracle S: Type (Oracle 11+) | Database Server",
" 12300 | Oracle T: Type (Oracle 12+) | Database Server",
" 8000 | Sybase ASE | Database Server",
" 141 | Episerver 6.x < .NET 4 | HTTP, SMTP, LDAP Server",
" 1441 | Episerver 6.x >= .NET 4 | HTTP, SMTP, LDAP Server",
" 1600 | Apache $apr1$ MD5, md5apr1, MD5 (APR) | HTTP, SMTP, LDAP Server",
" 12600 | ColdFusion 10+ | HTTP, SMTP, LDAP Server",
" 1421 | hMailServer | HTTP, SMTP, LDAP Server",
" 101 | nsldap, SHA-1(Base64), Netscape LDAP SHA | HTTP, SMTP, LDAP Server",
" 111 | nsldaps, SSHA-1(Base64), Netscape LDAP SSHA | HTTP, SMTP, LDAP Server",
" 1411 | SSHA-256(Base64), LDAP {SSHA256} | HTTP, SMTP, LDAP Server",
" 1711 | SSHA-512(Base64), LDAP {SSHA512} | HTTP, SMTP, LDAP Server",
" 16400 | CRAM-MD5 Dovecot | HTTP, SMTP, LDAP Server",
" 15000 | FileZilla Server >= 0.9.55 | FTP Server",
" 11500 | CRC32 | Checksums",
" 3000 | LM | Operating Systems",
" 1000 | NTLM | Operating Systems",
" 1100 | Domain Cached Credentials (DCC), MS Cache | Operating Systems",
" 2100 | Domain Cached Credentials 2 (DCC2), MS Cache 2 | Operating Systems",
" 15300 | DPAPI masterkey file v1 | Operating Systems",
" 15900 | DPAPI masterkey file v2 | Operating Systems",
" 12800 | MS-AzureSync PBKDF2-HMAC-SHA256 | Operating Systems",
" 1500 | descrypt, DES (Unix), Traditional DES | Operating Systems",
" 12400 | BSDi Crypt, Extended DES | Operating Systems",
" 500 | md5crypt, MD5 (Unix), Cisco-IOS $1$ (MD5) | Operating Systems",
" 3200 | bcrypt $2*$, Blowfish (Unix) | Operating Systems",
" 7400 | sha256crypt $5$, SHA256 (Unix) | Operating Systems",
" 1800 | sha512crypt $6$, SHA512 (Unix) | Operating Systems",
" 122 | macOS v10.4, MacOS v10.5, MacOS v10.6 | Operating Systems",
" 1722 | macOS v10.7 | Operating Systems",
" 7100 | macOS v10.8+ (PBKDF2-SHA512) | Operating Systems",
" 6300 | AIX {smd5} | Operating Systems",
" 6700 | AIX {ssha1} | Operating Systems",
" 6400 | AIX {ssha256} | Operating Systems",
" 6500 | AIX {ssha512} | Operating Systems",
" 2400 | Cisco-PIX MD5 | Operating Systems",
" 2410 | Cisco-ASA MD5 | Operating Systems",
" 500 | Cisco-IOS $1$ (MD5) | Operating Systems",
" 5700 | Cisco-IOS type 4 (SHA256) | Operating Systems",
" 9200 | Cisco-IOS $8$ (PBKDF2-SHA256) | Operating Systems",
" 9300 | Cisco-IOS $9$ (scrypt) | Operating Systems",
" 22 | Juniper NetScreen/SSG (ScreenOS) | Operating Systems",
" 501 | Juniper IVE | Operating Systems",
" 15100 | Juniper/NetBSD sha1crypt | Operating Systems",
" 7000 | FortiGate (FortiOS) | Operating Systems",
" 5800 | Samsung Android Password/PIN | Operating Systems",
" 13800 | Windows Phone 8+ PIN/password | Operating Systems",
" 8100 | Citrix NetScaler | Operating Systems",
" 8500 | RACF | Operating Systems",
" 7200 | GRUB 2 | Operating Systems",
" 9900 | Radmin2 | Operating Systems",
" 125 | ArubaOS | Operating Systems",
" 7700 | SAP CODVN B (BCODE) | Enterprise Application Software (EAS)",
" 7701 | SAP CODVN B (BCODE) via RFC_READ_TABLE | Enterprise Application Software (EAS)",
" 7800 | SAP CODVN F/G (PASSCODE) | Enterprise Application Software (EAS)",
" 7801 | SAP CODVN F/G (PASSCODE) via RFC_READ_TABLE | Enterprise Application Software (EAS)",
" 10300 | SAP CODVN H (PWDSALTEDHASH) iSSHA-1 | Enterprise Application Software (EAS)",
" 8600 | Lotus Notes/Domino 5 | Enterprise Application Software (EAS)",
" 8700 | Lotus Notes/Domino 6 | Enterprise Application Software (EAS)",
" 9100 | Lotus Notes/Domino 8 | Enterprise Application Software (EAS)",
" 133 | PeopleSoft | Enterprise Application Software (EAS)",
" 13500 | PeopleSoft PS_TOKEN | Enterprise Application Software (EAS)",
" 11600 | 7-Zip | Archives",
" 12500 | RAR3-hp | Archives",
" 13000 | RAR5 | Archives",
" 13200 | AxCrypt | Archives",
" 13300 | AxCrypt in-memory SHA1 | Archives",
" 13600 | WinZip | Archives",
" 14700 | iTunes backup < 10.0 | Backup",
" 14800 | iTunes backup >= 10.0 | Backup",
" 62XY | TrueCrypt | Full-Disk Encryption (FDE)",
" X | 1 = PBKDF2-HMAC-RIPEMD160 | Full-Disk Encryption (FDE)",
" X | 2 = PBKDF2-HMAC-SHA512 | Full-Disk Encryption (FDE)",
" X | 3 = PBKDF2-HMAC-Whirlpool | Full-Disk Encryption (FDE)",
" X | 4 = PBKDF2-HMAC-RIPEMD160 + boot-mode | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure AES | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Serpent | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Serpent | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded AES-Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Serpent-AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Twofish-Serpent | Full-Disk Encryption (FDE)",
" Y | 3 = XTS 1536 bit all | Full-Disk Encryption (FDE)",
" 8800 | Android FDE <= 4.3 | Full-Disk Encryption (FDE)",
" 12900 | Android FDE (Samsung DEK) | Full-Disk Encryption (FDE)",
" 12200 | eCryptfs | Full-Disk Encryption (FDE)",
" 137XY | VeraCrypt | Full-Disk Encryption (FDE)",
" X | 1 = PBKDF2-HMAC-RIPEMD160 | Full-Disk Encryption (FDE)",
" X | 2 = PBKDF2-HMAC-SHA512 | Full-Disk Encryption (FDE)",
" X | 3 = PBKDF2-HMAC-Whirlpool | Full-Disk Encryption (FDE)",
" X | 4 = PBKDF2-HMAC-RIPEMD160 + boot-mode | Full-Disk Encryption (FDE)",
" X | 5 = PBKDF2-HMAC-SHA256 | Full-Disk Encryption (FDE)",
" X | 6 = PBKDF2-HMAC-SHA256 + boot-mode | Full-Disk Encryption (FDE)",
" X | 7 = PBKDF2-HMAC-Streebog-512 | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure AES | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Serpent | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Twofish | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Camellia | Full-Disk Encryption (FDE)",
" Y | 1 = XTS 512 bit pure Kuznyechik | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Serpent | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Camellia | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit pure Kuznyechik | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded AES-Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Camellia-Kuznyechik | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Camellia-Serpent | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Kuznyechik-AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Kuznyechik-Twofish | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Serpent-AES | Full-Disk Encryption (FDE)",
" Y | 2 = XTS 1024 bit cascaded Twofish-Serpent | Full-Disk Encryption (FDE)",
" Y | 3 = XTS 1536 bit all | Full-Disk Encryption (FDE)",
" 14600 | LUKS | Full-Disk Encryption (FDE)",
" 16700 | FileVault 2 | Full-Disk Encryption (FDE)",
" 18300 | Apple File System (APFS) | Full-Disk Encryption (FDE)",
" 9700 | MS Office <= 2003 $0/$1, MD5 + RC4 | Documents",
" 9710 | MS Office <= 2003 $0/$1, MD5 + RC4, collider #1 | Documents",
" 9720 | MS Office <= 2003 $0/$1, MD5 + RC4, collider #2 | Documents",
" 9800 | MS Office <= 2003 $3/$4, SHA1 + RC4 | Documents",
" 9810 | MS Office <= 2003 $3, SHA1 + RC4, collider #1 | Documents",
" 9820 | MS Office <= 2003 $3, SHA1 + RC4, collider #2 | Documents",
" 9400 | MS Office 2007 | Documents",
" 9500 | MS Office 2010 | Documents",
" 9600 | MS Office 2013 | Documents",
" 10400 | PDF 1.1 - 1.3 (Acrobat 2 - 4) | Documents",
" 10410 | PDF 1.1 - 1.3 (Acrobat 2 - 4), collider #1 | Documents",
" 10420 | PDF 1.1 - 1.3 (Acrobat 2 - 4), collider #2 | Documents",
" 10500 | PDF 1.4 - 1.6 (Acrobat 5 - 8) | Documents",
" 10600 | PDF 1.7 Level 3 (Acrobat 9) | Documents",
" 10700 | PDF 1.7 Level 8 (Acrobat 10 - 11) | Documents",
" 16200 | Apple Secure Notes | Documents",
" 18600 | Open Document Format (ODF) 1.1 (SHA-1, Blowfish) | Documents",
" 18400 | Open Document Format (ODF) 1.2 (SHA-256, AES) | Documents",
" 9000 | Password Safe v2 | Password Managers",
" 5200 | Password Safe v3 | Password Managers",
" 6800 | LastPass + LastPass sniffed | Password Managers",
" 6600 | 1Password, agilekeychain | Password Managers",
" 8200 | 1Password, cloudkeychain | Password Managers",
" 11300 | Bitcoin/Litecoin wallet.dat | Password Managers",
" 12700 | Blockchain, My Wallet | Password Managers",
" 15200 | Blockchain, My Wallet, V2 | Password Managers",
" 16600 | Electrum Wallet (Salt-Type 1-2) | Password Managers",
" 13400 | KeePass 1 (AES/Twofish) and KeePass 2 (AES) | Password Managers",
" 15500 | JKS Java Key Store Private Keys (SHA1) | Password Managers",
" 15600 | Ethereum Wallet, PBKDF2-HMAC-SHA256 | Password Managers",
" 15700 | Ethereum Wallet, SCRYPT | Password Managers",
" 16300 | Ethereum Pre-Sale Wallet, PBKDF2-HMAC-SHA256 | Password Managers",
" 16900 | Ansible Vault | Password Managers",
" 18100 | TOTP (HMAC-SHA1) | One-Time Passwords",
" 99999 | Plaintext | Plaintext",
"",
NULL
};
static const char *const USAGE_BIG_POST_HASHMODES[] =
{
#ifdef WITH_BRAIN
"- [ Brain Client Features ] -",
"",
@ -510,6 +235,28 @@ static const char *const USAGE_BIG[] =
NULL
};
typedef struct usage_sort
{
u32 hash_mode;
char *hash_name;
u32 hash_category;
} usage_sort_t;
static int sort_by_usage (const void *p1, const void *p2)
{
const usage_sort_t *u1 = (const usage_sort_t *) p1;
const usage_sort_t *u2 = (const usage_sort_t *) p2;
if (u1->hash_category > u2->hash_category) return 1;
if (u1->hash_category < u2->hash_category) return -1;
if (u1->hash_mode > u2->hash_mode) return 1;
if (u1->hash_mode < u2->hash_mode) return -1;
return 0;
}
void usage_mini_print (const char *progname)
{
for (int i = 0; USAGE_MINI[i] != NULL; i++)
@ -520,12 +267,70 @@ void usage_mini_print (const char *progname)
}
}
void usage_big_print (const char *progname)
void usage_big_print (hashcat_ctx_t *hashcat_ctx)
{
for (int i = 0; USAGE_BIG[i] != NULL; i++)
hashconfig_t *hashconfig = hashcat_ctx->hashconfig;
user_options_t *user_options = hashcat_ctx->user_options;
fclose (stderr); // a bit harsh
for (int i = 0; USAGE_BIG_PRE_HASHMODES[i] != NULL; i++)
{
printf (USAGE_BIG[i], progname);
printf ("%s", USAGE_BIG_PRE_HASHMODES[i]);
hc_fwrite (EOL, strlen (EOL), 1, stdout);
}
//hc_fwrite (EOL, strlen (EOL), 1, stdout);
#define MAX_HASH_MODES 100000
usage_sort_t *usage_sort_buf = (usage_sort_t *) hccalloc (MAX_HASH_MODES, sizeof (usage_sort_t));
int usage_sort_cnt = 0;
for (int i = 0; i < 100000; i++)
{
user_options->hash_mode = i;
const int rc = hashconfig_init (hashcat_ctx);
if (rc == 0)
{
usage_sort_buf[usage_sort_cnt].hash_mode = i;
usage_sort_buf[usage_sort_cnt].hash_name = hcstrdup (hashconfig->hash_name);
usage_sort_buf[usage_sort_cnt].hash_category = hashconfig->hash_category;
usage_sort_cnt++;
}
hashconfig_destroy (hashcat_ctx);
}
qsort (usage_sort_buf, usage_sort_cnt, sizeof (usage_sort_t), sort_by_usage);
for (int i = 0; i < usage_sort_cnt; i++)
{
printf ("%7d | %-48s | %s", usage_sort_buf[i].hash_mode, usage_sort_buf[i].hash_name, strhashcategory (usage_sort_buf[i].hash_category));
hc_fwrite (EOL, strlen (EOL), 1, stdout);
}
for (int i = 0; i < usage_sort_cnt; i++)
{
hcfree (usage_sort_buf[i].hash_name);
}
hcfree (usage_sort_buf);
hc_fwrite (EOL, strlen (EOL), 1, stdout);
for (int i = 0; USAGE_BIG_POST_HASHMODES[i] != NULL; i++)
{
printf ("%s", USAGE_BIG_POST_HASHMODES[i]);
hc_fwrite (EOL, strlen (EOL), 1, stdout);
}
hc_fwrite (EOL, strlen (EOL), 1, stdout);
}

View File

@ -1370,6 +1370,11 @@ void user_options_session_auto (hashcat_ctx_t *hashcat_ctx)
user_options->session = "example_hashes";
}
if (user_options->usage == true)
{
user_options->session = "usage";
}
if (user_options->speed_only == true)
{
user_options->session = "speed_only";
@ -1442,7 +1447,8 @@ void user_options_preprocess (hashcat_ctx_t *hashcat_ctx)
|| user_options->opencl_info == true
|| user_options->keyspace == true
|| user_options->speed_only == true
|| user_options->progress_only == true)
|| user_options->progress_only == true
|| user_options->usage == true)
{
user_options->hwmon_disable = true;
user_options->left = false;
@ -1498,6 +1504,11 @@ void user_options_preprocess (hashcat_ctx_t *hashcat_ctx)
user_options->quiet = true;
}
if (user_options->usage == true)
{
user_options->quiet = true;
}
if (user_options->progress_only == true)
{
user_options->speed_only = true;