DSA_do_sign 3 2003-07-24 0.9.9-dev OpenSSL
NAME
DSA_do_sign, DSA_do_verify - raw DSA signature operations
LIBRARY
libcrypto, -lcrypto
SYNOPSIS
#include
DSA_SIG *DSA_do_sign(const unsigned char *dgst, int dlen, DSA *dsa);
int DSA_do_verify(const unsigned char *dgst, int dgst_len,
DSA_SIG *sig, DSA *dsa);
DESCRIPTION
_D_S_A___d_o___s_i_g_n_(_) computes a digital signature on the lleenn byte message
digest ddggsstt using the private key ddssaa and returns it in a
newly allocated DDSSAA__SSIIGG structure.
_D_S_A___s_i_g_n___s_e_t_u_p(3) may be used to precompute part
of the signing operation in case signature generation is
time-critical.
_D_S_A___d_o___v_e_r_i_f_y_(_) verifies that the signature ssiigg matches a given
message digest ddggsstt of size lleenn. ddssaa is the signer's public
key.
RETURN VALUES
_D_S_A___d_o___s_i_g_n_(_) returns the signature, NULL on error. _D_S_A___d_o___v_e_r_i_f_y_(_)
returns 1 for a valid signature, 0 for an incorrect signature and -1
on error. The error codes can be obtained by
_E_R_R___g_e_t___e_r_r_o_r(3).
SEE ALSO
_o_p_e_n_s_s_l___d_s_a(3), _E_R_R___g_e_t___e_r_r_o_r(3), _o_p_e_n_s_s_l___r_a_n_d(3),
_D_S_A___S_I_G___n_e_w(3),
_D_S_A___s_i_g_n(3)
HISTORY
_D_S_A___d_o___s_i_g_n_(_) and _D_S_A___d_o___v_e_r_i_f_y_(_) were added in OpenSSL 0.9.3.