Commit 072dd6ef authored by Niels Möller's avatar Niels Möller

* des.c (des_encrypt, des_decrypt): Assert that the key setup was

successful.

Rev: src/nettle/des.c:1.2
parent e62872fa
......@@ -209,7 +209,8 @@ des_encrypt(struct des_ctx *ctx,
const uint8_t *src)
{
assert(!(length % DES_BLOCK_SIZE));
assert(ctx->status == DES_OK);
while (length)
{
DesSmallFipsEncrypt(dst, ctx->key, src);
......@@ -225,6 +226,7 @@ des_decrypt(struct des_ctx *ctx,
const uint8_t *src)
{
assert(!(length % DES_BLOCK_SIZE));
assert(ctx->status == DES_OK);
while (length)
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment