Skip to content

Commit

Permalink
Make error msg less technical
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Ortmann committed Apr 30, 2024
1 parent 7a2f8e2 commit d64692b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/mod/pbkdf2.mod/pbkdf2.c
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ static char *pbkdf2_hash(const char *pass, const char *digest_name,
digestlen, buf)) {
explicit_bzero(buf, digestlen);
explicit_bzero(out, outlen);
putlog(LOG_MISC, "*", "PBKDF2 error: PKCS5_PBKDF2_HMAC(): %s.",
putlog(LOG_MISC, "*", "PBKDF2 key derivation error: %s.",
ERR_error_string(ERR_get_error(), NULL));
nfree(buf);
return NULL;
Expand Down Expand Up @@ -246,7 +246,7 @@ static int tcl_pbkdf2 STDVAR
}
digestlen = EVP_MD_size(digest);
if (!PKCS5_PBKDF2_HMAC(argv[1], strlen(argv[1]), (const unsigned char *) argv[2], strlen(argv[2]), rounds, digest, digestlen, buf)) {
Tcl_AppendResult(irp, "PBKDF2 error: PKCS5_PBKDF2_HMAC(): ", ERR_error_string(ERR_get_error(), NULL), ".", NULL);
Tcl_AppendResult(irp, "PBKDF2 key derivation error: ", ERR_error_string(ERR_get_error(), NULL), ".", NULL);
return TCL_ERROR;
}
buf[digestlen] = 0;
Expand Down

0 comments on commit d64692b

Please sign in to comment.