summaryrefslogtreecommitdiffstats
path: root/crypto.h
diff options
context:
space:
mode:
authorAdriaan de Jong <dejong@fox-it.com>2011-06-23 17:31:19 +0200
committerDavid Sommerseth <davids@redhat.com>2011-10-19 22:13:25 +0200
commit670f9dd91aed7ac435b79c0e28e49fa7c256642c (patch)
tree303257a54b2e5e6fa4ea2e46528b142910a556e5 /crypto.h
parente8c950f12dfd6187f084fb06b6fe6e57c030bdad (diff)
downloadopenvpn-670f9dd91aed7ac435b79c0e28e49fa7c256642c.tar.gz
openvpn-670f9dd91aed7ac435b79c0e28e49fa7c256642c.tar.xz
openvpn-670f9dd91aed7ac435b79c0e28e49fa7c256642c.zip
Refactored cipher key types
Signed-off-by: Adriaan de Jong <dejong@fox-it.com> Acked-by: David Sommerseth <davids@redhat.com> Acked-by: James Yonan <james@openvpn.net> Signed-off-by: David Sommerseth <davids@redhat.com>
Diffstat (limited to 'crypto.h')
-rw-r--r--crypto.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/crypto.h b/crypto.h
index f300e3c..425c090 100644
--- a/crypto.h
+++ b/crypto.h
@@ -164,9 +164,9 @@ cipher_ok (const char* name)
*/
struct key_type
{
- uint8_t cipher_length;
+ uint8_t cipher_length; /**< Cipher length, in bytes */
uint8_t hmac_length; /**< HMAC length, in bytes */
- const EVP_CIPHER *cipher;
+ const cipher_kt_t *cipher; /**< Cipher static parameters */
const md_kt_t *digest; /**< Message digest static parameters */
};
@@ -309,8 +309,6 @@ int read_key (struct key *key, const struct key_type *kt, struct buffer *buf);
bool cfb_ofb_mode (const struct key_type* kt);
-const char *kt_cipher_name (const struct key_type *kt);
-int kt_key_size (const struct key_type *kt);
void init_key_type (struct key_type *kt, const char *ciphername,
bool ciphername_defined, const char *authname, bool authname_defined,
int keysize, bool cfb_ofb_allowed, bool warn);