mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-24 04:34:08 +08:00
5311f248b7
As discussed previously, this patch moves the basic CTR functionality into a chainable algorithm called ctr. The IPsec-specific variant of it is now placed on top with the name rfc3686. So ctr(aes) gives a chainable cipher with IV size 16 while the IPsec variant will be called rfc3686(ctr(aes)). This patch also adjusts gcm accordingly. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
21 lines
524 B
C
21 lines
524 B
C
/*
|
|
* CTR: Counter mode
|
|
*
|
|
* Copyright (c) 2007 Herbert Xu <herbert@gondor.apana.org.au>
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify it
|
|
* under the terms of the GNU General Public License as published by the Free
|
|
* Software Foundation; either version 2 of the License, or (at your option)
|
|
* any later version.
|
|
*
|
|
*/
|
|
|
|
#ifndef _CRYPTO_CTR_H
|
|
#define _CRYPTO_CTR_H
|
|
|
|
#define CTR_RFC3686_NONCE_SIZE 4
|
|
#define CTR_RFC3686_IV_SIZE 8
|
|
#define CTR_RFC3686_BLOCK_SIZE 16
|
|
|
|
#endif /* _CRYPTO_CTR_H */
|