pam_pkcs11  0.6.9
Macros | Functions
pam-pkcs11-ossl-compat.h File Reference
#include <openssl/opensslv.h>
#include <openssl/opensslconf.h>
#include <openssl/bn.h>
#include <openssl/rsa.h>
#include <openssl/dsa.h>

Go to the source code of this file.

Macros

#define EVP_CIPHER_CTX_new()
 
#define EVP_CIPHER_CTX_free(x)
 
#define EVP_PKEY_base_id(x)   (x->type)
 
#define RSA_PKCS1_OpenSSL   RSA_PKCS1_SSLeay
 
#define OPENSSL_malloc_init   CRYPTO_malloc_init
 
#define EVP_PKEY_get0_RSA(x)   (x->pkey.rsa)
 
#define EVP_PKEY_get0_DSA(x)   (x->pkey.dsa)
 
#define X509_get_extension_flags(x)   (x->ex_flags)
 
#define X509_get_key_usage(x)   (x->ex_kusage)
 
#define X509_get_extended_key_usage(x)   (x->ex_xkusage)
 
#define EVP_MD_CTX_new   EVP_MD_CTX_create
 
#define EVP_MD_CTX_free   EVP_MD_CTX_destroy
 
#define EVP_PKEY_up_ref(user_key)   CRYPTO_add(&user_key->references, 1, CRYPTO_LOCK_EVP_PKEY)
 
#define X509_up_ref(cert)   CRYPTO_add(&cert->references, 1, CRYPTO_LOCK_X509)
 
#define X509_get0_tbs_sigalg(x)   (x->cert_info->key->algor)
 
#define X509_OBJECT_get0_X509(x)   (x->data.x509)
 
#define X509_OBJECT_get0_X509_CRL(x)   (x->data.crl)
 
#define X509_OBJECT_free(x)
 
#define pam_pkcs11_ossl_inline
 
#define RSA_bits(R)   (BN_num_bits(R->n))
 

Functions

static pam_pkcs11_ossl_inline int RSA_set0_key (RSA *r, BIGNUM *n, BIGNUM *e, BIGNUM *d)
 
static pam_pkcs11_ossl_inline int RSA_set0_factors (RSA *r, BIGNUM *p, BIGNUM *q)
 
static pam_pkcs11_ossl_inline int RSA_set0_crt_params (RSA *r, BIGNUM *dmp1, BIGNUM *dmq1, BIGNUM *iqmp)
 
static pam_pkcs11_ossl_inline void RSA_get0_key (const RSA *r, const BIGNUM **n, const BIGNUM **e, const BIGNUM **d)
 
static pam_pkcs11_ossl_inline void RSA_get0_factors (const RSA *r, const BIGNUM **p, const BIGNUM **q)
 
static pam_pkcs11_ossl_inline void RSA_get0_crt_params (const RSA *r, const BIGNUM **dmp1, const BIGNUM **dmq1, const BIGNUM **iqmp)
 
static pam_pkcs11_ossl_inline void DSA_get0_pqg (const DSA *d, const BIGNUM **p, const BIGNUM **q, const BIGNUM **g)
 
static pam_pkcs11_ossl_inline void DSA_get0_key (const DSA *d, const BIGNUM **pub_key, const BIGNUM **priv_key)
 

Macro Definition Documentation

#define EVP_CIPHER_CTX_free (   x)
Value:
({ \
if (x) { \
EVP_CIPHER_CTX_cleanup(x); \
OPENSSL_free(x); \
} \
})

Definition at line 63 of file pam-pkcs11-ossl-compat.h.

#define EVP_CIPHER_CTX_new ( )
Value:
({ \
EVP_CIPHER_CTX * tmp = NULL; \
tmp = OPENSSL_malloc(sizeof(struct evp_cipher_ctx_st)); \
if (tmp) { \
EVP_CIPHER_CTX_init(tmp); \
} \
tmp; \
})

Definition at line 54 of file pam-pkcs11-ossl-compat.h.

#define EVP_MD_CTX_free   EVP_MD_CTX_destroy

Definition at line 93 of file pam-pkcs11-ossl-compat.h.

#define EVP_MD_CTX_new   EVP_MD_CTX_create

Definition at line 92 of file pam-pkcs11-ossl-compat.h.

#define EVP_PKEY_base_id (   x)    (x->type)

Definition at line 80 of file pam-pkcs11-ossl-compat.h.

#define EVP_PKEY_get0_DSA (   x)    (x->pkey.dsa)

Definition at line 88 of file pam-pkcs11-ossl-compat.h.

#define EVP_PKEY_get0_RSA (   x)    (x->pkey.rsa)

Definition at line 87 of file pam-pkcs11-ossl-compat.h.

#define EVP_PKEY_up_ref (   user_key)    CRYPTO_add(&user_key->references, 1, CRYPTO_LOCK_EVP_PKEY)

Definition at line 94 of file pam-pkcs11-ossl-compat.h.

#define OPENSSL_malloc_init   CRYPTO_malloc_init

Definition at line 85 of file pam-pkcs11-ossl-compat.h.

#define pam_pkcs11_ossl_inline

Definition at line 128 of file pam-pkcs11-ossl-compat.h.

#define RSA_bits (   R)    (BN_num_bits(R->n))

Definition at line 137 of file pam-pkcs11-ossl-compat.h.

#define RSA_PKCS1_OpenSSL   RSA_PKCS1_SSLeay

Definition at line 84 of file pam-pkcs11-ossl-compat.h.

#define X509_get0_tbs_sigalg (   x)    (x->cert_info->key->algor)

Definition at line 96 of file pam-pkcs11-ossl-compat.h.

#define X509_get_extended_key_usage (   x)    (x->ex_xkusage)

Definition at line 91 of file pam-pkcs11-ossl-compat.h.

#define X509_get_extension_flags (   x)    (x->ex_flags)

Definition at line 89 of file pam-pkcs11-ossl-compat.h.

#define X509_get_key_usage (   x)    (x->ex_kusage)

Definition at line 90 of file pam-pkcs11-ossl-compat.h.

#define X509_OBJECT_free (   x)
Value:
({ \
if (x) { \
X509_OBJECT_free_contents(x); \
OPENSSL_free(x); \
} \
})

Definition at line 100 of file pam-pkcs11-ossl-compat.h.

#define X509_OBJECT_get0_X509 (   x)    (x->data.x509)

Definition at line 97 of file pam-pkcs11-ossl-compat.h.

#define X509_OBJECT_get0_X509_CRL (   x)    (x->data.crl)

Definition at line 98 of file pam-pkcs11-ossl-compat.h.

#define X509_up_ref (   cert)    CRYPTO_add(&cert->references, 1, CRYPTO_LOCK_X509)

Definition at line 95 of file pam-pkcs11-ossl-compat.h.

Function Documentation

static pam_pkcs11_ossl_inline void DSA_get0_key ( const DSA *  d,
const BIGNUM **  pub_key,
const BIGNUM **  priv_key 
)
static

Definition at line 235 of file pam-pkcs11-ossl-compat.h.

static pam_pkcs11_ossl_inline void DSA_get0_pqg ( const DSA *  d,
const BIGNUM **  p,
const BIGNUM **  q,
const BIGNUM **  g 
)
static

Definition at line 225 of file pam-pkcs11-ossl-compat.h.

static pam_pkcs11_ossl_inline void RSA_get0_crt_params ( const RSA *  r,
const BIGNUM **  dmp1,
const BIGNUM **  dmq1,
const BIGNUM **  iqmp 
)
static

Definition at line 211 of file pam-pkcs11-ossl-compat.h.

static pam_pkcs11_ossl_inline void RSA_get0_factors ( const RSA *  r,
const BIGNUM **  p,
const BIGNUM **  q 
)
static

Definition at line 203 of file pam-pkcs11-ossl-compat.h.

static pam_pkcs11_ossl_inline void RSA_get0_key ( const RSA *  r,
const BIGNUM **  n,
const BIGNUM **  e,
const BIGNUM **  d 
)
static

Definition at line 193 of file pam-pkcs11-ossl-compat.h.

static pam_pkcs11_ossl_inline int RSA_set0_crt_params ( RSA *  r,
BIGNUM *  dmp1,
BIGNUM *  dmq1,
BIGNUM *  iqmp 
)
static

Definition at line 178 of file pam-pkcs11-ossl-compat.h.

static pam_pkcs11_ossl_inline int RSA_set0_factors ( RSA *  r,
BIGNUM *  p,
BIGNUM *  q 
)
static

Definition at line 165 of file pam-pkcs11-ossl-compat.h.

static pam_pkcs11_ossl_inline int RSA_set0_key ( RSA *  r,
BIGNUM *  n,
BIGNUM *  e,
BIGNUM *  d 
)
static

Definition at line 149 of file pam-pkcs11-ossl-compat.h.