aboutsummaryrefslogtreecommitdiffstats
path: root/g10
diff options
context:
space:
mode:
Diffstat (limited to 'g10')
-rw-r--r--g10/ChangeLog9
-rw-r--r--g10/encode.c9
-rw-r--r--g10/keygen.c2
-rw-r--r--g10/misc.c11
-rw-r--r--g10/pubkey-enc.c3
-rw-r--r--g10/sig-check.c3
-rw-r--r--g10/sign.c4
7 files changed, 26 insertions, 15 deletions
diff --git a/g10/ChangeLog b/g10/ChangeLog
index 1569113e8..5acfd4f0f 100644
--- a/g10/ChangeLog
+++ b/g10/ChangeLog
@@ -1,3 +1,12 @@
+Wed Sep 6 17:55:47 CEST 2000 Werner Koch <[email protected]>
+
+ * misc.c (print_pubkey_algo_note): Do not print the RSA notice.
+ * sig-check.c (do_signature_check): Do not emit the RSA status message.
+ * pubkey-enc.c (get_session_key): Ditto.
+
+ * encode.c (encode_simple, encode_crypt): Fix for large files.
+ * sign.c (sign_file): Ditto.
+
Wed Sep 6 14:59:09 CEST 2000 Werner Koch <[email protected]>
* passphrase.c (hash_passphrase): Removed funny assert. Reported by
diff --git a/g10/encode.c b/g10/encode.c
index d1c02bbed..e70901387 100644
--- a/g10/encode.c
+++ b/g10/encode.c
@@ -169,6 +169,11 @@ encode_simple( const char *filename, int mode )
if( filename && !opt.textmode && !mode ) {
if( !(filesize = iobuf_get_filelength(inp)) )
log_info(_("%s: WARNING: empty file\n"), filename );
+ /* we can't yet encode the length of very large files,
+ * so we switch to partial lengthn encoding in this case */
+ if ( filesize >= IOBUF_FILELENGTH_LIMIT )
+ filesize = 0;
+
}
else
filesize = opt.set_filesize ? opt.set_filesize : 0; /* stdin */
@@ -317,6 +322,10 @@ encode_crypt( const char *filename, STRLIST remusr )
if( filename && !opt.textmode ) {
if( !(filesize = iobuf_get_filelength(inp)) )
log_info(_("%s: WARNING: empty file\n"), filename );
+ /* we can't yet encode the length of very large files,
+ * so we switch to partial lengthn encoding in this case */
+ if ( filesize >= IOBUF_FILELENGTH_LIMIT )
+ filesize = 0;
}
else
filesize = opt.set_filesize ? opt.set_filesize : 0; /* stdin */
diff --git a/g10/keygen.c b/g10/keygen.c
index a98ec53f2..2f68e0d41 100644
--- a/g10/keygen.c
+++ b/g10/keygen.c
@@ -415,6 +415,8 @@ gen_dsa(unsigned int nbits, KBNODE pub_root, KBNODE sec_root, DEK *dek,
}
#if 0
+/* we can't enable generation right now, becuase we first need to implement
+ * the keyflags */
static int
gen_rsa(int algo, unsigned nbits, KBNODE pub_root, KBNODE sec_root, DEK *dek,
STRING2KEY *s2k, PKT_secret_key **ret_sk, u32 expireval )
diff --git a/g10/misc.c b/g10/misc.c
index 8706430e7..1e4f4916d 100644
--- a/g10/misc.c
+++ b/g10/misc.c
@@ -211,15 +211,6 @@ print_pubkey_algo_note( int algo )
{
if( algo >= 100 && algo <= 110 )
no_exp_algo();
- else if( is_RSA( algo ) ) {
- static int did_note = 0;
-
- if( !did_note ) {
- did_note = 1;
- log_info(_("RSA keys are deprecated; please consider "
- "creating a new key and use this key in the future\n"));
- }
- }
}
void
@@ -253,3 +244,5 @@ print_digest_algo_note( int algo )
+
+
diff --git a/g10/pubkey-enc.c b/g10/pubkey-enc.c
index 97c73bbc7..1babe460d 100644
--- a/g10/pubkey-enc.c
+++ b/g10/pubkey-enc.c
@@ -47,9 +47,6 @@ get_session_key( PKT_pubkey_enc *k, DEK *dek )
PKT_secret_key *sk = NULL;
int rc;
- if( is_RSA(k->pubkey_algo) ) /* warn about that */
- write_status(STATUS_RSA_OR_IDEA);
-
rc = check_pubkey_algo( k->pubkey_algo );
if( rc )
goto leave;
diff --git a/g10/sig-check.c b/g10/sig-check.c
index 15ba3ab81..67efad019 100644
--- a/g10/sig-check.c
+++ b/g10/sig-check.c
@@ -66,9 +66,6 @@ do_signature_check( PKT_signature *sig, MD_HANDLE digest,
PKT_public_key *pk = m_alloc_clear( sizeof *pk );
int rc=0;
- if( is_RSA(sig->pubkey_algo) )
- write_status(STATUS_RSA_OR_IDEA);
-
*r_expiredate = 0;
if( get_pubkey( pk, sig->keyid ) )
rc = G10ERR_NO_PUBKEY;
diff --git a/g10/sign.c b/g10/sign.c
index e5df3e482..5d87dad84 100644
--- a/g10/sign.c
+++ b/g10/sign.c
@@ -429,6 +429,10 @@ sign_file( STRLIST filenames, int detached, STRLIST locusr,
if( fname ) {
if( !(filesize = iobuf_get_filelength(inp)) )
log_info(_("WARNING: `%s' is an empty file\n"), fname );
+ /* we can't yet encode the length of very large files,
+ * so we switch to partial lengthn encoding in this case */
+ if ( filesize >= IOBUF_FILELENGTH_LIMIT )
+ filesize = 0;
/* because the text_filter modifies the length of the
* data, it is not possible to know the used length