aboutsummaryrefslogtreecommitdiffstats
path: root/g10/encr-data.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2000-01-27 16:50:45 +0000
committerWerner Koch <[email protected]>2000-01-27 16:50:45 +0000
commitbaa30ad117e12c5182a78ede84c5103bea23616b (patch)
treef1d174362ee1855c5af77dcb917451e026c0a8d5 /g10/encr-data.c
parentSee ChangeLog: Mon Jan 24 22:24:38 CET 2000 Werner Koch (diff)
downloadgnupg-baa30ad117e12c5182a78ede84c5103bea23616b.tar.gz
gnupg-baa30ad117e12c5182a78ede84c5103bea23616b.zip
See ChangeLog: Thu Jan 27 18:00:44 CET 2000 Werner Koch
Diffstat (limited to 'g10/encr-data.c')
-rw-r--r--g10/encr-data.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/g10/encr-data.c b/g10/encr-data.c
index 286475003..0f741b9ec 100644
--- a/g10/encr-data.c
+++ b/g10/encr-data.c
@@ -62,7 +62,7 @@ decrypt_data( void *procctx, PKT_encrypted *ed, DEK *dek )
if( gcry_cipher_test_algo( dek->algo ) ) {
if( opt.verbose )
log_info(_("encrypted with unknown algorithm %d\n"), dek->algo );
- rc = G10ERR_CIPHER_ALGO;
+ rc = GPGERR_CIPHER_ALGO;
goto leave;
}
if( opt.verbose )
@@ -129,7 +129,7 @@ decrypt_data( void *procctx, PKT_encrypted *ed, DEK *dek )
p = temp;
/* log_hexdump( "prefix", temp, nprefix+2 ); */
if( p[nprefix-2] != p[nprefix] || p[nprefix-1] != p[nprefix+1] ) {
- rc = G10ERR_BAD_KEY;
+ rc = GPGERR_BAD_KEY;
goto leave;
}
if( ed->mdc_method )
@@ -139,12 +139,12 @@ decrypt_data( void *procctx, PKT_encrypted *ed, DEK *dek )
proc_packets( procctx, ed->buf);
ed->buf = NULL;
if( ed->mdc_method && dfx.eof_seen == 2 )
- rc = G10ERR_INVALID_PACKET;
+ rc = GPGERR_INVALID_PACKET;
else if( ed->mdc_method ) { /* check the mdc */
int datalen = gcry_md_get_algo_dlen( ed->mdc_method );
if( datalen != 20
|| memcmp(gcry_md_read( dfx.mdc_hash, 0 ), dfx.defer, datalen) )
- rc = G10ERR_BAD_SIGN;
+ rc = GPGERR_BAD_SIGN;
log_hexdump("MDC calculated:", gcry_md_read( dfx.mdc_hash, 0), datalen);
log_hexdump("MDC message :", dfx.defer, 20);
}