|
|
@ -1,3 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* Author......: See docs/credits.txt
|
|
|
|
* Author......: See docs/credits.txt
|
|
|
|
* License.....: MIT
|
|
|
|
* License.....: MIT
|
|
|
@ -89,6 +90,16 @@ int module_hash_decode (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSE
|
|
|
|
|
|
|
|
|
|
|
|
hc_token_t token;
|
|
|
|
hc_token_t token;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (line_len < 46) return (PARSER_SALT_LENGTH);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
|
|
|
* Checking the signature for performance optimization
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (strncmp(line_buf, SIGNATURE_KRB5PA, strlen (SIGNATURE_KRB5PA))) {
|
|
|
|
|
|
|
|
return (PARSER_SIGNATURE_UNMATCHED);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
memset (&token, 0, sizeof (hc_token_t));
|
|
|
|
memset (&token, 0, sizeof (hc_token_t));
|
|
|
|
|
|
|
|
|
|
|
|
token.signatures_cnt = 1;
|
|
|
|
token.signatures_cnt = 1;
|
|
|
@ -102,9 +113,6 @@ int module_hash_decode (MAYBE_UNUSED const hashconfig_t *hashconfig, MAYBE_UNUSE
|
|
|
|
* $krb5pa$17$*user*realm*$enc_timestamp+checksum
|
|
|
|
* $krb5pa$17$*user*realm*$enc_timestamp+checksum
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
// assume no signature found
|
|
|
|
|
|
|
|
if (line_len < 11) return (PARSER_SALT_LENGTH);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// assume $krb5pa$17$user$realm$enc_timestamp+checksum
|
|
|
|
// assume $krb5pa$17$user$realm$enc_timestamp+checksum
|
|
|
|
token.token_cnt = 4;
|
|
|
|
token.token_cnt = 4;
|
|
|
|
|
|
|
|
|
|
|
|