Add constant time crypt_bytes_to_hex helper and use it in libdevmapper.

Fixes: #736
This commit is contained in:
Milan Broz
2022-04-25 18:35:36 +02:00
parent ff14c17de7
commit e161cd1859
3 changed files with 60 additions and 46 deletions

View File

@@ -37,6 +37,7 @@ int crypt_parse_integrity_mode(const char *s, char *integrity,
int crypt_parse_pbkdf(const char *s, const char **pbkdf);
ssize_t crypt_hex_to_bytes(const char *hex, char **result, int safe_alloc);
char *crypt_bytes_to_hex(size_t size, const char *bytes);
bool crypt_is_cipher_null(const char *cipher_spec);