Eneboo - Documentación para desarrolladores
'defines' | 'typedefs' | Funciones
Referencia del Archivo src/libdigidoc/openssl/crypto/bn/bn_nist.c
#include "bn_lcl.h"
#include "cryptlib.h"

'defines'

#define BN_NIST_192_TOP   (192+BN_BITS2-1)/BN_BITS2
#define BN_NIST_224_TOP   (224+BN_BITS2-1)/BN_BITS2
#define BN_NIST_256_TOP   (256+BN_BITS2-1)/BN_BITS2
#define BN_NIST_384_TOP   (384+BN_BITS2-1)/BN_BITS2
#define BN_NIST_521_TOP   (521+BN_BITS2-1)/BN_BITS2
#define bn_cp_64(to, n, from, m)
#define bn_64_set_0(to, n)
#define nist_set_192(to, from, a1, a2, a3)
#define nist_set_224(to, from, a1, a2, a3, a4, a5, a6, a7)
#define nist_set_256(to, from, a1, a2, a3, a4, a5, a6, a7, a8)
#define nist_set_384(to, from, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12)
#define BN_NIST_521_RSHIFT   (521%BN_BITS2)
#define BN_NIST_521_LSHIFT   (BN_BITS2-BN_NIST_521_RSHIFT)
#define BN_NIST_521_TOP_MASK   ((BN_ULONG)BN_MASK2>>BN_NIST_521_LSHIFT)

'typedefs'

typedef BN_ULONG(* bn_addsub_f )(BN_ULONG *, const BN_ULONG *, const BN_ULONG *, int)

Funciones

const BIGNUMBN_get0_nist_prime_192 (void)
const BIGNUMBN_get0_nist_prime_224 (void)
const BIGNUMBN_get0_nist_prime_256 (void)
const BIGNUMBN_get0_nist_prime_384 (void)
const BIGNUMBN_get0_nist_prime_521 (void)
int BN_nist_mod_192 (BIGNUM *r, const BIGNUM *a, const BIGNUM *field, BN_CTX *ctx)
int BN_nist_mod_224 (BIGNUM *r, const BIGNUM *a, const BIGNUM *field, BN_CTX *ctx)
int BN_nist_mod_256 (BIGNUM *r, const BIGNUM *a, const BIGNUM *field, BN_CTX *ctx)
int BN_nist_mod_384 (BIGNUM *r, const BIGNUM *a, const BIGNUM *field, BN_CTX *ctx)
int BN_nist_mod_521 (BIGNUM *r, const BIGNUM *a, const BIGNUM *field, BN_CTX *ctx)

Documentación de los 'defines'

#define bn_64_set_0 (   to,
 
)
Valor:
{ \
        bn_32_set_0(to, (n)*2); \
        bn_32_set_0(to, (n)*2+1); \
        }
#define bn_cp_64 (   to,
  n,
  from,
 
)
Valor:
{ \
        bn_cp_32(to, (n)*2, from, (m)*2); \
        bn_cp_32(to, (n)*2+1, from, (m)*2+1); \
        }
#define BN_NIST_192_TOP   (192+BN_BITS2-1)/BN_BITS2
#define BN_NIST_224_TOP   (224+BN_BITS2-1)/BN_BITS2
#define BN_NIST_256_TOP   (256+BN_BITS2-1)/BN_BITS2
#define BN_NIST_384_TOP   (384+BN_BITS2-1)/BN_BITS2
#define BN_NIST_521_LSHIFT   (BN_BITS2-BN_NIST_521_RSHIFT)
#define BN_NIST_521_RSHIFT   (521%BN_BITS2)
#define BN_NIST_521_TOP   (521+BN_BITS2-1)/BN_BITS2
#define BN_NIST_521_TOP_MASK   ((BN_ULONG)BN_MASK2>>BN_NIST_521_LSHIFT)
#define nist_set_192 (   to,
  from,
  a1,
  a2,
  a3 
)
Valor:
{ \
        bn_cp_64(to, 0, from, (a3) - 3) \
        bn_cp_64(to, 1, from, (a2) - 3) \
        bn_cp_64(to, 2, from, (a1) - 3) \
        }
#define nist_set_224 (   to,
  from,
  a1,
  a2,
  a3,
  a4,
  a5,
  a6,
  a7 
)
Valor:
{ \
        bn_cp_32(to, 0, from, (a7) - 7) \
        bn_cp_32(to, 1, from, (a6) - 7) \
        bn_cp_32(to, 2, from, (a5) - 7) \
        bn_cp_32(to, 3, from, (a4) - 7) \
        bn_cp_32(to, 4, from, (a3) - 7) \
        bn_cp_32(to, 5, from, (a2) - 7) \
        bn_cp_32(to, 6, from, (a1) - 7) \
        }
#define nist_set_256 (   to,
  from,
  a1,
  a2,
  a3,
  a4,
  a5,
  a6,
  a7,
  a8 
)
Valor:
{ \
        bn_cp_32(to, 0, from, (a8) - 8) \
        bn_cp_32(to, 1, from, (a7) - 8) \
        bn_cp_32(to, 2, from, (a6) - 8) \
        bn_cp_32(to, 3, from, (a5) - 8) \
        bn_cp_32(to, 4, from, (a4) - 8) \
        bn_cp_32(to, 5, from, (a3) - 8) \
        bn_cp_32(to, 6, from, (a2) - 8) \
        bn_cp_32(to, 7, from, (a1) - 8) \
        }
#define nist_set_384 (   to,
  from,
  a1,
  a2,
  a3,
  a4,
  a5,
  a6,
  a7,
  a8,
  a9,
  a10,
  a11,
  a12 
)
Valor:
{ \
        bn_cp_32(to, 0, from,  (a12) - 12) \
        bn_cp_32(to, 1, from,  (a11) - 12) \
        bn_cp_32(to, 2, from,  (a10) - 12) \
        bn_cp_32(to, 3, from,  (a9) - 12)  \
        bn_cp_32(to, 4, from,  (a8) - 12)  \
        bn_cp_32(to, 5, from,  (a7) - 12)  \
        bn_cp_32(to, 6, from,  (a6) - 12)  \
        bn_cp_32(to, 7, from,  (a5) - 12)  \
        bn_cp_32(to, 8, from,  (a4) - 12)  \
        bn_cp_32(to, 9, from,  (a3) - 12)  \
        bn_cp_32(to, 10, from, (a2) - 12)  \
        bn_cp_32(to, 11, from, (a1) - 12)  \
        }

Documentación de los 'typedefs'

typedef BN_ULONG(* bn_addsub_f)(BN_ULONG *, const BN_ULONG *, const BN_ULONG *, int)

Documentación de las funciones

const BIGNUM* BN_get0_nist_prime_192 ( void  )
const BIGNUM* BN_get0_nist_prime_224 ( void  )
const BIGNUM* BN_get0_nist_prime_256 ( void  )
const BIGNUM* BN_get0_nist_prime_384 ( void  )
const BIGNUM* BN_get0_nist_prime_521 ( void  )
int BN_nist_mod_192 ( BIGNUM r,
const BIGNUM a,
const BIGNUM field,
BN_CTX ctx 
)
int BN_nist_mod_224 ( BIGNUM r,
const BIGNUM a,
const BIGNUM field,
BN_CTX ctx 
)
int BN_nist_mod_256 ( BIGNUM r,
const BIGNUM a,
const BIGNUM field,
BN_CTX ctx 
)
int BN_nist_mod_384 ( BIGNUM r,
const BIGNUM a,
const BIGNUM field,
BN_CTX ctx 
)
int BN_nist_mod_521 ( BIGNUM r,
const BIGNUM a,
const BIGNUM field,
BN_CTX ctx 
)
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'