diff --git a/ChangeLog b/ChangeLog index 5ea79f136..3d8ba00e4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2013-11-12 Vladimir Serbinenko + + * include/grub/crypto.h: Add maximums on hash size and cipher block + size. + 2013-11-12 Vladimir Serbinenko * grub-core/commands/xnu_uuid.c: Remove variable length arrays. diff --git a/include/grub/crypto.h b/include/grub/crypto.h index 0e8820ed6..d7ba697c6 100644 --- a/include/grub/crypto.h +++ b/include/grub/crypto.h @@ -85,6 +85,10 @@ enum gcry_cipher_modes }; #endif +/* Don't rely on this. Check! */ +#define GRUB_CRYPTO_MAX_MDLEN 64 +#define GRUB_CRYPTO_MAX_CIPHER_BLOCKSIZE 16 + /* Type for the cipher_setkey function. */ typedef gcry_err_code_t (*gcry_cipher_setkey_t) (void *c, const unsigned char *key,