aboutsummaryrefslogtreecommitdiffstats
path: root/g10/pubkey-enc.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>1999-12-08 21:03:03 +0000
committerWerner Koch <[email protected]>1999-12-08 21:03:03 +0000
commit4555c0be941cef55486b7a1644d9b70f4ea50c77 (patch)
tree1a10627bf31163f9aef5040724c53f75e8daf3e6 /g10/pubkey-enc.c
parentSee ChangeLog: Fri Nov 19 17:15:20 CET 1999 Werner Koch (diff)
downloadgnupg-4555c0be941cef55486b7a1644d9b70f4ea50c77.tar.gz
gnupg-4555c0be941cef55486b7a1644d9b70f4ea50c77.zip
See ChangeLog: Wed Dec 8 21:58:32 CET 1999 Werner Koch
Diffstat (limited to 'g10/pubkey-enc.c')
-rw-r--r--g10/pubkey-enc.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/g10/pubkey-enc.c b/g10/pubkey-enc.c
index f11e6f12a..94fe2777b 100644
--- a/g10/pubkey-enc.c
+++ b/g10/pubkey-enc.c
@@ -27,10 +27,9 @@
#include "memory.h"
#include "packet.h"
#include "main.h"
-#include "mpi.h"
#include "keydb.h"
#include "trustdb.h"
-#include "cipher.h"
+#include "dummy-cipher.h"
#include "status.h"
#include "options.h"
#include "i18n.h"
@@ -110,7 +109,7 @@ get_it( PKT_pubkey_enc *k, DEK *dek, PKT_secret_key *sk, u32 *keyid )
if( rc )
goto leave;
frame = mpi_get_buffer( plain_dek, &nframe, NULL );
- mpi_free( plain_dek ); plain_dek = NULL;
+ mpi_release( plain_dek ); plain_dek = NULL;
/* Now get the DEK (data encryption key) from the frame
*
@@ -129,7 +128,7 @@ get_it( PKT_pubkey_enc *k, DEK *dek, PKT_secret_key *sk, u32 *keyid )
* DEK is the encryption key (session key) with length k
* CSUM
*/
- if( DBG_CIPHER )
+ if( (opt.debug & DBG_CIPHER_VALUE) )
log_hexdump("DEK frame:", frame, nframe );
n=0;
if( n + 7 > nframe )
@@ -171,7 +170,7 @@ get_it( PKT_pubkey_enc *k, DEK *dek, PKT_secret_key *sk, u32 *keyid )
rc = G10ERR_WRONG_SECKEY;
goto leave;
}
- if( DBG_CIPHER )
+ if( (opt.debug & DBG_CIPHER_VALUE) )
log_hexdump("DEK is:", dek->key, dek->keylen );
/* check that the algo is in the preferences */
{
@@ -197,7 +196,7 @@ get_it( PKT_pubkey_enc *k, DEK *dek, PKT_secret_key *sk, u32 *keyid )
}
leave:
- mpi_free(plain_dek);
+ mpi_release(plain_dek);
m_free(frame);
return rc;
}