diff options
Diffstat (limited to 'src/crypto/cipher.c')
| -rw-r--r-- | src/crypto/cipher.c | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/src/crypto/cipher.c b/src/crypto/cipher.c deleted file mode 100644 index f83a6d0ff..000000000 --- a/src/crypto/cipher.c +++ /dev/null @@ -1,24 +0,0 @@ -#include <stdint.h> -#include <errno.h> -#include <gpxe/crypto.h> - -int cipher_encrypt ( struct cipher_algorithm *cipher, - void *ctx, const void *src, void *dst, - size_t len ) { - if ( ( len & ( cipher->blocksize - 1 ) ) ) { - return -EINVAL; - } - cipher->encrypt ( ctx, src, dst, len ); - return 0; -} - -int cipher_decrypt ( struct cipher_algorithm *cipher, - void *ctx, const void *src, void *dst, - size_t len ) { - if ( ( len & ( cipher->blocksize - 1 ) ) ) { - return -EINVAL; - } - cipher->decrypt ( ctx, src, dst, len ); - return 0; -} - |
