CVS update: gnupg/g10

Werner Koch wkoch@guug.de
Fri, 14 Jul 2000 19:34:51 +0200


Date:	Friday July 14, 2000 @ 19:34
Author:	wkoch

Update of /home/koch/cvs/gnupg/g10
In directory sigtrap:/tmp/cvs-serv22575/g10

Modified Files:
	ChangeLog Makefile.am armor.c build-packet.c cipher.c 
	comment.c compress.c dearmor.c decrypt.c delkey.c encode.c 
	encr-data.c export.c filter.h free-packet.c getkey.c gpg.c 
	gpgd.c helptext.c hkp.c hkp.h import.c kbnode.c kbxblob.c 
	kbxfile.c keydb.h keyedit.c keygen.c keyid.c keylist.c 
	ks-proto.h main.h mainproc.c mdfilter.c misc.c openfile.c 
	options.h packet.h parse-packet.c passphrase.c pkclist.c 
	plaintext.c pubkey-enc.c revoke.c ringedit.c seckey-cert.c 
	seskey.c sig-check.c sign.c signal.c skclist.c status.c 
	status.h tdbdump.c tdbio.c tdbio.h textfilter.c trustdb.c 
	trustdb.h verify.c 
Log Message:
Fri Jul 14 19:38:23 CEST 2000  Werner Koch  <wk@>

  Replaced everything with the code from the STABLE-BRANCH-1-0 and
  started to backport the changes from the 1.1 development branch
  which are dated according to the ChangeLog of the 1.1 from
  Sat Sep 18 12:16:08 CEST 1999  to  Thu May 25 18:39:11 CEST 2000.
  Here are those changes, some of them are duplicates because they
  have been done on both branch simultaneously.

  * gpg.c (print_mds): Add arg keys as a kludge to print hmacs
  (main): New option --print-hmac.

  * trustdb.c (verify_own_keys): Do not print warning about unprotected
  key when in quiet mode.

  * build-paket.c (do_user_id): Save offset where name has been stored.

  * ringedit.c : Add new access method KBXF

  * kbxfile.c: New.

  * kbx.h: New.
  * kbxblob.c: Started to work on the keybox stuff.

  * keygen.c (gen_dsa): Modified to work with gcry_pk_genkey.

  * Removed dummy-cipher.h from all files.

  * keygen.c (gen_elg): Modified to work with gcry_pk_genkey.
  (key_from_sexp): New.
  (factors_from_sexp): New.

  * g10.c : Renamed to ...
  * gpg.c : ... this
  * Makefile.am: And fixed it here.

  * Changed all "g10_"/"GPG_" prefixes to "gpg_"/"GPG_".

  * misc.c (mpi_read_opaque): Fixed double counting.

  * seckey-cert.c (do_check): Removed buffer and the unmotivated free
  on it.

  * pubkey-enc.c (pk_decrypt): New wrapper for the gcry_ function.
  * seckey-cert.c (pk_check_secret_key): Likewise.
  * encode.c (pk_encrypt): Likewise.

  * parse-packet.c (parse_key): Fixed case of unencrypted secret keys.

  * misc.c (mpi_print): Use gcry_mpi_aprint.
  (pubkey_nbits): Kludge to use the gcry_pk_ API.

  * seskey.c (encode_session_key): Replaced mpi_set_buffer by *_scan.
  (do_encode_md): Ditto.
  (encode_md_value): Ditto.
  * seckey-cert.c (protect_secret_key): Ditto.
  * comment.c (make_mpi_comment_node): Replaced mpi_get_buffer by _print.
  * pubkey-enc.c (get_it): Ditto.
  * sig-check.c (do_signature_check): Ditto.

  * keyid.c (do_fingerprint_md): Replaced mpi_get_buffer by gcry_mpi_print.
  (v3_keyid): New.
  (keyid_from_sk): And use it here.
  (keyid_from_pk): Ditto.
  (fingerprint_from_sk): Ditto.
  (fingerprint_from_pk): Ditto.

  * misc.c (mpi_print): New.

  * misc.c (checksum_mpi): Now uses gcry_mpi_print to get the data.

  * seckey-cert.c (do_check): Replaced mpi_read_from_buffer.

  * armor.c (armor_filter): Made the "Comment:" header translatable.

  * seckey-cert.c: Removed obsolete mpi_*_protect_flag.
  * parse-packet.c: Ditto.

  * misc.c (mpi_read): Removed the secure argumet becuase it is
  never used.  Changed all Callers.
  (mpi_read_opaque): New.
  (mpi_write_opaque): New.
  * parse-packet.c (parse_key): Use the opaque method also for
  v3 keys.
  * build-packet.c (do_secret_key): Likewise.

  * g10.c (main): Check libgcrypt version.

  * packet.h: replaced inclusion of mpi.h by a plain typeedef of the
  gcry_mpi structure and removed all inclusions of "mpi.h" in all
  sources.

  * g10.c: Add --delete-secret-key to the help page.

  * g10.c (main): Changed the default homedir to "~/.gnupg-test" so
  that we don't mess up with the stable version.

  * misc.c (mpi_write): New.
  (mpi_write): New.

  * misc.c (checksum_u16_nobug): Removed.
  (checksum_mpi_counted_nbits): Renamed to ...
  (checksum_mpi): ... this to superseed the old one. Changed all
  callers. This is because we do not emulate the old gpg bug anymore.
  * g10.c (oEmuChecksumBug): Removed.

  * g10.c (register_extension): New...
  (main): Use it here instead of register_cipher_extesnion.
  (strusage): s/strusage/my_strusage/ . Made static.
  (main): Use set_strusage().

  * tdbdump.c (HEXTOBIN): Changed the name of the argument, so that
  traditional cpp don't mess up the macros. Suggested by Jos Backus.

  * armor.c (parse_header_line): Stop parsing on a only WS line too.
  Suggested by Aric Cyr.

  * misc.c (pull_in_libs): Removed.

  * mainproc.c (list_node): Print the PK algo in the --with-colon mode.
  * keylist.c (list_keyblock): Ditto.

  * misc.c (pull_in_libs): Removed pull in of g10c.

  * misc.c (map_gcry_rc): Removed here and chnaged all users.

  * getkey.c: Replaced check_pubkey_algo by openpgp_pk_test_algo.
  * import.c (delete_inv_parts): Ditto.
  * pkclist.c: Ditto.
  * skclist.c: Ditto.
  * pubkey-enc.c: Ditto.

  * g10.c (main): Replaced the function to diable PK algos.

  * g10.c (main): Replaced get_random_bits by gcry_random_bytes.
  * seskey.c (encode_session_key): Likewise.
  (make_session_key): Renamed randomize_buffer to gcry_randomize
  and use the GCRY_xxx_RANDOM constants.
  * cipher.c (write_header): Ditto.
  * passphrase.c (hash_passphrase): Ditto.
  * seckey-cert.c (protect_secret_key): Ditto.

  * getkey.c (find_by_name): Replaced rmd160_hash_buffer
  by gcry_md_hash_buffer.
  * keyedit.c (show_prefs): Ditto.
  * keylist.c (list_keyblock): Ditto.
  * trustdb.c (print_uid_from_keyblock): Ditto.
  (make_uid_records): Ditto.

  * skclist.c (build_sk_list): Removed the test on faked RNGs.
  (is_insecure): Removed.
  * g10.c (--quick-random): Removed this option.

  * Replaced all PUBKEY_ALGO_xxx by GCRY_PK_xxxx.

  * misc.c (pubkey_algo_npkey): New as a wrapper around the gcry fucntion.
  (pubkey_algo_nskey): Ditto.
  (pubkey_algo_nsig): Ditto.
  (pubkey_algo_nenc): Ditto.

  * Makefile.am (basicdefs.h): Added.
  (install-data-local): Removed the handling for historic gpgm.

  * misc.c (openpgp_cipher_test_algo): New.
  (openpgp_pk_test_algo): New.
  (openpgp_md_test_algo): New.

  * g10.c (build_list): Changed to use the new functions from libgcrypt.

  * ringedit.c (enum_keyblocks): Set .rt to 0 on open.

  * encode.c (encode_simple): Use new CTB when we don't have the
  length of the file.  This is somewhat strange as the comment above
  indicates that this part is actually fixed for PGP 5 - maybe I simply
  lost the source line, tsss.

  * sign.c (clearsign_file): Avoid duplicated Entries in the "Hash:"
  line.  Those headers are now only _not_ printed when there are
  only old-style keys _and_ all hashs are MD5.

  (clearsign_file): Use gcry_md_test_algo() and gcry_md_algo_name().

  * openfile.c (make_outfile_name): Use case-insenstive compare for
  DOS systems.	Add ".pgp" to the list of know extensions.
  (open_outfile): For DOS systems try to replace the suffix instead of
  appending it.

  * encr-data.c (decrypt_data): Reset error on a weak key.

  * cipher.c: Replaced the cipher and digest functions by the gcry_ ones.
  * seckey-cert.c: Ditto.
  * seskey.c: Ditto.
  * g10.c (print_mds): Replaced digst functions with the new gcry_ ones.
  * keyid.c: Ditto.
  * mainproc.c: Ditto.
  * passphrase.c: Ditto.
  * sig-check.c: Ditto.
  * sign.c: Ditto.

  * pkclist.c (do_edit_ownertrust): Made the answer string const.

  * basicdefs.h: New.  Move some defs and decl to this header.

  * openfile.c (open_outfile): Fixed the 8dot3 handling.

  * passphrase.c (passphrase_to_dek): Print uid using utf8 func.
  * delkey.c (delete_key): Ditto.
  * pkclist.c (show_paths,do_edit_ownertrust,do_we_trust): Ditto
  (do_we_trust_pre): Ditto.
  * trustdb.c (print_user_id,check_uidsigs): Ditto.
  * revoke.c (gen_revoke,ask_revoke_sig): Ditto.

  * filter.h: Changed cipher handle types to the the GCRY_xxx ones.
  replaces include cipher by system header include gcrypt.h.
  * cipher.c: replaced the cipher functions by the gcry_ ones.
  Ditto for the md functions.

  * misc.c (map_gcry_rc): New.


File: ChangeLog        	Status: Up-to-date
File: Makefile.am      	Status: Up-to-date
File: armor.c          	Status: Up-to-date
File: build-packet.c   	Status: Up-to-date
File: cipher.c         	Status: Up-to-date
File: comment.c        	Status: Up-to-date
File: compress.c       	Status: Up-to-date
File: dearmor.c        	Status: Up-to-date
File: decrypt.c        	Status: Up-to-date
File: delkey.c         	Status: Up-to-date
File: encode.c         	Status: Up-to-date
File: encr-data.c      	Status: Up-to-date
File: export.c         	Status: Up-to-date
File: filter.h         	Status: Up-to-date
File: free-packet.c    	Status: Up-to-date
File: getkey.c         	Status: Up-to-date
File: gpg.c            	Status: Up-to-date
File: gpgd.c           	Status: Up-to-date
File: helptext.c       	Status: Up-to-date
File: hkp.c            	Status: Up-to-date
File: hkp.h            	Status: Up-to-date
File: import.c         	Status: Up-to-date
File: kbnode.c         	Status: Up-to-date
File: kbxblob.c        	Status: Up-to-date
File: kbxfile.c        	Status: Up-to-date
File: keydb.h          	Status: Up-to-date
File: keyedit.c        	Status: Up-to-date
File: keygen.c         	Status: Up-to-date
File: keyid.c          	Status: Up-to-date
File: keylist.c        	Status: Up-to-date
File: ks-proto.h       	Status: Up-to-date
File: main.h           	Status: Up-to-date
File: mainproc.c       	Status: Up-to-date
File: mdfilter.c       	Status: Up-to-date
File: misc.c           	Status: Up-to-date
File: openfile.c       	Status: Up-to-date
File: options.h        	Status: Up-to-date
File: packet.h         	Status: Up-to-date
File: parse-packet.c   	Status: Up-to-date
File: passphrase.c     	Status: Up-to-date
File: pkclist.c        	Status: Up-to-date
File: plaintext.c      	Status: Up-to-date
File: pubkey-enc.c     	Status: Up-to-date
File: revoke.c         	Status: Up-to-date
File: ringedit.c       	Status: Up-to-date
File: seckey-cert.c    	Status: Up-to-date
File: seskey.c         	Status: Up-to-date
File: sig-check.c      	Status: Up-to-date
File: sign.c           	Status: Up-to-date
File: signal.c         	Status: Up-to-date
File: skclist.c        	Status: Up-to-date
File: status.c         	Status: Up-to-date
File: status.h         	Status: Up-to-date
File: tdbdump.c        	Status: Up-to-date
File: tdbio.c          	Status: Up-to-date
File: tdbio.h          	Status: Up-to-date
File: textfilter.c     	Status: Up-to-date
File: trustdb.c        	Status: Up-to-date
File: trustdb.h        	Status: Up-to-date
File: verify.c         	Status: Up-to-date