*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> DSA_get_default_openssl_method (3)              



NAME    [Toc]    [Back]

       DSA_set_method,            DSA_set_default_openssl_method,
       DSA_get_default_openssl_method,            DSA_new_method,
       DSA_OpenSSL - Select DSA method

SYNOPSIS    [Toc]    [Back]

       #include <openssl/dsa.h> #include <openssl/engine.h>

       void DSA_set_default_openssl_method(
               DSA_METHOD        *meth        );       DSA_METHOD
               void ); int DSA_set_method(
               DSA *dsa, ENGINE *engine ); DSA *DSA_new_method(
               ENGINE *engine ); DSA_METHOD *DSA_OpenSSL(
               void );

DESCRIPTION    [Toc]    [Back]

       A DSA_METHOD specifies the functions that OpenSSL uses for
       DSA  operations.  By  modifying  the  method,  alternative
       implementations such as hardware accelerators can be used.

       Initially, the default is the OpenSSL internal implementation.
 The DSA_OpenSSL() function returns a pointer to that

       The  DSA_set_default_openssl_method()  function makes meth
       the default method for all DSA structures  created  later.
       This  is true only while the default engine for DSA operations
 remains as openssl.  ENGINEs provide  an  encapsulation
  for  implementations  of one or more algorithms at a
       time, and all the DSA  functions  mentioned  here  operate
       within the scope of the default openssl engine.

       The  DSA_get_default_openssl_method()  function  returns a
       pointer to the current  default  method  for  the  openssl

       The  DSA_set_method()  selects  engine  for all operations
       using the structure dsa.

       The DSA_new_method() function allocates and initializes  a
       DSA  structure  so  that  engine  will be used for the DSA
       operations. If engine is NULL, the default engine for  DSA
       operations is used.


       struct    {        /*   name   of  the  implementation  */
       const char *name;
            /*   sign   */        DSA_SIG   *(*dsa_do_sign)(const
       unsigned char *dgst, int dlen,
                                        DSA *dsa);

            /*    pre-compute    k^-1    and    r   */        int
       (*dsa_sign_setup)(DSA   *dsa,   BN_CTX   *ctx_in,   BIGNUM
                                        BIGNUM **rp);

            /* verify */      int (*dsa_do_verify)(const unsigned
       char *dgst, int dgst_len,
                                        DSA_SIG *sig, DSA *dsa);

            /* compute rr = a1^p1 * a2^p2 mod m (May be NULL  for
       */      int (*dsa_mod_exp)(DSA *dsa,  BIGNUM  *rr,  BIGNUM
       *a1, BIGNUM *p1,
                                        BIGNUM  *a2,  BIGNUM *p2,
       BIGNUM *m,
                                        BN_CTX *ctx,  BN_MONT_CTX

            /*  compute  r  =  a  ^ p mod m (May be NULL for some
       implementations) */
               int (*bn_mod_exp)(DSA *dsa, BIGNUM *r, BIGNUM *a,
                                        const  BIGNUM  *p,  const
       BIGNUM *m,
                                        BN_CTX  *ctx, BN_MONT_CTX

            /* called at DSA_new */
               int (*init)(DSA *DSA);

            /* called at DSA_free */
               int (*finish)(DSA *DSA);

               int flags;

               char *app_data; /* ?? */

        } DSA_METHOD;

RETURN VALUES    [Toc]    [Back]

       The  DSA_OpenSSL()  and   DSA_get_default_openssl_method()
       functions return pointers to the respective DSA_METHODs.

       The  DSA_set_default_openssl_method()  function returns no

       The DSA_set_method()  function  returns  non-zero  if  the
       ENGINE  associated  with  dsa  was successfully changed to

       The DSA_new_method() function returns  NULL  and  sets  an
       error  code  that  can be obtained from ERR_get_error() if
       the allocation fails. Otherwise it returns  a  pointer  to
       the newly allocated structure.

HISTORY    [Toc]    [Back]

       The   DSA_set_default_method(),  DSA_get_default_method(),
       DSA_set_method(),  DSA_new_method(),   and   DSA_OpenSSL()
       functions were added in OpenSSL 0.9.4.

       The          DSA_set_default_openssl_method()          and
       DSA_get_default_openssl_method()  functions  replaced  the
       DSA_set_default_method()    and   DSA_get_default_method()
       functions  respectively,  and  the  DSA_set_method()   and
       DSA_new_method()  functions  were  altered  to use ENGINEs
       rather than  DSA_METHODs  during  development  of  OpenSSL

SEE ALSO    [Toc]    [Back]

       Functions: dsa(3), DSA_new(3)

[ Back ]
 Similar pages
Name OS Title
RSA_set_method OpenBSD select RSA method
DH_OpenSSL OpenBSD select DH method
DH_OpenSSL Tru64 Select DH method
DH_get_default_openssl_method Tru64 Select DH method
DH_set_method Tru64 Select DH method
DH_set_default_openssl_method Tru64 Select DH method
DH_new_method Tru64 Select DH method
RSA_PKCS1_RSAref Tru64 Select RSA method
RSA_PKCS1_SSLeay Tru64 Select RSA method
RSA_flags Tru64 Select RSA method
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service