libssh  0.8.5
The SSH library
libcrypto-compat.h
1#ifndef LIBCRYPTO_COMPAT_H
2#define LIBCRYPTO_COMPAT_H
3
4#include <openssl/opensslv.h>
5#if OPENSSL_VERSION_NUMBER < 0x10100000L
6
7#include <openssl/rsa.h>
8#include <openssl/dsa.h>
9#include <openssl/ecdsa.h>
10#include <openssl/dh.h>
11#include <openssl/evp.h>
12#include <openssl/hmac.h>
13
14int RSA_set0_key(RSA *r, BIGNUM *n, BIGNUM *e, BIGNUM *d);
15int RSA_set0_factors(RSA *r, BIGNUM *p, BIGNUM *q);
16int RSA_set0_crt_params(RSA *r, BIGNUM *dmp1, BIGNUM *dmq1, BIGNUM *iqmp);
17void RSA_get0_key(const RSA *r, const BIGNUM **n, const BIGNUM **e, const BIGNUM **d);
18void RSA_get0_factors(const RSA *r, const BIGNUM **p, const BIGNUM **q);
19void RSA_get0_crt_params(const RSA *r, const BIGNUM **dmp1, const BIGNUM **dmq1, const BIGNUM **iqmp);
20
21void DSA_get0_pqg(const DSA *d, const BIGNUM **p, const BIGNUM **q, const BIGNUM **g);
22int DSA_set0_pqg(DSA *d, BIGNUM *p, BIGNUM *q, BIGNUM *g);
23void DSA_get0_key(const DSA *d, const BIGNUM **pub_key, const BIGNUM **priv_key);
24int DSA_set0_key(DSA *d, BIGNUM *pub_key, BIGNUM *priv_key);
25
26void DSA_SIG_get0(const DSA_SIG *sig, const BIGNUM **pr, const BIGNUM **ps);
27int DSA_SIG_set0(DSA_SIG *sig, BIGNUM *r, BIGNUM *s);
28
29void ECDSA_SIG_get0(const ECDSA_SIG *sig, const BIGNUM **pr, const BIGNUM **ps);
30int ECDSA_SIG_set0(ECDSA_SIG *sig, BIGNUM *r, BIGNUM *s);
31
32int EVP_MD_CTX_reset(EVP_MD_CTX *ctx);
33EVP_MD_CTX *EVP_MD_CTX_new(void);
34void EVP_MD_CTX_free(EVP_MD_CTX *ctx);
35
36HMAC_CTX *HMAC_CTX_new(void);
37int HMAC_CTX_reset(HMAC_CTX *ctx);
38void HMAC_CTX_free(HMAC_CTX *ctx);
39
40#endif /* OPENSSL_VERSION_NUMBER */
41
42#endif /* LIBCRYPTO_COMPAT_H */