List Info

Thread: OpenSSL: openssl/apps/ dgst.c




OpenSSL: openssl/apps/ dgst.c
country flaguser name
Germany
2007-05-17 07:35:32
  OpenSSL CVS Repository
  http://cvs.openssl.org/
 
____________________________________________________________
________________

  Server: cvs.openssl.org                  Name:   Dr.
Stephen Henson
  Root:   /v/openssl/cvs                   Email:  steveopenssl.org
  Module: openssl                          Date:  
17-May-2007 14:35:32
  Branch: HEAD                             Handle:
2007051713353200

  Modified files:
    openssl/apps            dgst.c

  Log:
    Use EVP_DigestVerify() in dgst.c if verifying.

  Summary:
    Revision    Changes     Path
    1.44        +6  -1      openssl/apps/dgst.c
 
____________________________________________________________
________________

  patch -p0 <<' .'
  Index: openssl/apps/dgst.c
 
============================================================
================
  $ cvs diff -u -r1.43 -r1.44 dgst.c
  --- openssl/apps/dgst.c	30 Apr 2007 15:20:10 -0000	1.43
  +++ openssl/apps/dgst.c	17 May 2007 12:35:32 -0000	1.44
   -412,13 +412,18 
   		{
   		EVP_MD_CTX *mctx = NULL;
   		EVP_PKEY_CTX *pctx = NULL;
  +		int r;
   		if (!BIO_get_md_ctx(bmd, &mctx))
   			{
   			BIO_printf(bio_err, "Error getting
contextn");
   			ERR_print_errors(bio_err);
   			goto end;
   			}
  -		if (!EVP_DigestSignInit(mctx, &pctx, md, e,
sigkey))
  +		if (do_verify)
  +			r = EVP_DigestVerifyInit(mctx, &pctx, md, e,
sigkey);
  +		else
  +			r = EVP_DigestSignInit(mctx, &pctx, md, e,
sigkey);
  +		if (!r)
   			{
   			BIO_printf(bio_err, "Error setting
contextn");
   			ERR_print_errors(bio_err);
   .
____________________________________________________________
__________
OpenSSL Project                                 http://www.openssl.org
CVS Repository Commit List                    
openssl-cvsopenssl.org
Automated List Manager                          
majordomoopenssl.org

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )