diff options
author | Andreas Schneider <asn@cryptomilk.org> | 2013-10-18 23:21:52 +0200 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2013-10-18 23:50:06 +0200 |
commit | 5b7f07b484c47497b371b97578c0581b4e96fce4 (patch) | |
tree | a839238b241c914778af64788ba9fcfe511ec187 /include | |
parent | ec5278e34dd8271c696fe5f54ebc114dc132fe8c (diff) | |
download | libssh-5b7f07b484c47497b371b97578c0581b4e96fce4.tar.gz libssh-5b7f07b484c47497b371b97578c0581b4e96fce4.tar.xz libssh-5b7f07b484c47497b371b97578c0581b4e96fce4.zip |
wrapper: Add more evp functions.
Diffstat (limited to 'include')
-rw-r--r-- | include/libssh/libcrypto.h | 3 | ||||
-rw-r--r-- | include/libssh/wrapper.h | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/include/libssh/libcrypto.h b/include/libssh/libcrypto.h index 54c78b16..c8b157b0 100644 --- a/include/libssh/libcrypto.h +++ b/include/libssh/libcrypto.h @@ -38,6 +38,9 @@ typedef SHA_CTX* SHACTX; typedef SHA256_CTX* SHA256CTX; typedef MD5_CTX* MD5CTX; typedef HMAC_CTX* HMACCTX; +#ifdef HAVE_ECC +typedef EVP_MD_CTX *EVPCTX; +#endif #define SHA_DIGEST_LEN SHA_DIGEST_LENGTH #ifdef MD5_DIGEST_LEN diff --git a/include/libssh/wrapper.h b/include/libssh/wrapper.h index 90c268d9..7374a88a 100644 --- a/include/libssh/wrapper.h +++ b/include/libssh/wrapper.h @@ -53,6 +53,9 @@ void sha1(unsigned char *digest,int len,unsigned char *hash); void sha256(unsigned char *digest, int len, unsigned char *hash); void evp(int nid, unsigned char *digest, int len, unsigned char *hash, unsigned int *hlen); +EVPCTX evp_init(int nid); +void evp_update(EVPCTX ctx, const void *data, unsigned long len); +void evp_final(EVPCTX ctx, unsigned char *md, unsigned int *mdlen); ssh_mac_ctx ssh_mac_ctx_init(enum ssh_mac_e type); void ssh_mac_update(ssh_mac_ctx ctx, const void *data, unsigned long len); |