aboutsummaryrefslogtreecommitdiffstats
path: root/g10/gpg.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Release 1.4.19.gnupg-1.4.19Werner Koch2015-02-271-3/+2
|
* gpg: Add build and runtime support for larger RSA keysDaniel Kahn Gillmor2014-10-031-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | * configure.ac: Added --enable-large-secmem option. * g10/options.h: Add opt.flags.large_rsa. * g10/gpg.c: Contingent on configure option: adjust secmem size, add gpg --enable-large-rsa, bound to opt.flags.large_rsa. * g10/keygen.c: Adjust max RSA size based on opt.flags.large_rsa * doc/gpg.texi: Document --enable-large-rsa. -- Some older implementations built and used RSA keys up to 16Kib, but the larger secret keys now fail when used by more recent GnuPG, due to secure memory limitations. Building with ./configure --enable-large-secmem will make gpg capable of working with those secret keys, as well as permitting the use of a new gpg option --enable-large-rsa, which let gpg generate RSA keys up to 8Kib when used with --batch --gen-key. Debian-bug-id: 739424 Minor edits by wk. GnuPG-bug-id: 1732
* Allow use of --debug-level=LEVEL without '='.Werner Koch2014-09-291-1/+1
| | | | * g10/gpg.c (opts): Fix "debug-level".
* Update config.{guess,sub} and some copyright notices.Werner Koch2013-12-101-0/+1
| | | | | | | * scripts/config.guess, scripts/config.sub: Update to version 2013-11-29. Signed-off-by: Werner Koch <[email protected]>
* gpg: Change armor Version header to emit only the major version.Werner Koch2013-11-271-2/+3
| | | | | | | | | | | | | | | | | | * g10/options.h (opt): Rename field no_version to emit_version. * g10/gpg.c (main): Init opt.emit_vesion to 1. Change --emit-version to bump up opt.emit_version. * g10/armor.c (armor_filter): Implement different --emit-version values. -- GnuPG-bug-id: 1572 Signed-off-by: Werner Koch <[email protected]> (cherry picked from commit e951782e937ce290be0d89d83e84b3daea997587) Resolved conflicts: NEWS g10/armor.c g10/gpg.c
* gpg: Do not require a trustdb with --always-trust.Werner Koch2013-10-111-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * g10/tdbio.c (tdbio_set_dbname): Add arg R_NOFILE. * g10/trustdb.c (trustdb_args): Add field no_trustdb. (init_trustdb): Set that field. (revalidation_mark): Take care of a nonexistent trustdb file. (read_trust_options): Ditto. (get_ownertrust): Ditto. (get_min_ownertrust): Ditto. (update_ownertrust): Ditto. (update_min_ownertrust): Ditto. (clear_ownertrusts): Ditto. (cache_disabled_value): Ditto. (check_trustdb_stale): Ditto. (get_validity): Ditto. * g10/gpg.c (main): Do not create a trustdb with most commands for trust-model always. -- This slightly changes the semantics of most commands in that they won't create a trustdb if --trust-model=always is used. It just does not make sense to create a trustdb if there is no need for it. Signed-off-by: Werner Koch <[email protected]> (cherry picked from commit 1a0eeaacd1bf09fe5125dbc3f56016bc20f3512e) Resolved conflicts: g10/gpg.c g10/tdbio.h g10/trustdb.c (indentation fixes)
* gpg: No need to create a trustdb when encrypting with --always-trust.Werner Koch2013-08-021-0/+6
| | | | | | | | | * g10/gpg.c (main): Special case setup_trustdb for --encrypt. -- (back ported from commit 498b9a95dc65c43240835d64cc92d8fb43014d53) Signed-off-by: Werner Koch <[email protected]>
* Fix potential heap corruption in "gpg -v --version"Werner Koch2012-12-151-43/+39
| | | | | | | | | | | | | | | | | * g10/gpg.c (build_list): Rewrite to cope with buffer overflow in certain locales. * util/membuf.c (put_membuf_str): New. (get_membuf): Make LEN optional. -- This fixes an obvious bug in locales where the translated string is longer than the original. The bug could be exhibited by using LANG=ru_RU.utf8 gpg -v --version. En passant we also removed the trailing white space on continued lines. Reported-by: Dmitry V. Levin" <ldv at altlinux.org>
* Support the not anymore patented IDEA cipher algorithm.Werner Koch2012-11-081-50/+8
| | | | | | | | | | | | | | | | | | | | | | | | * cipher/idea.c: New. Take from Libgcrypt master and adjust for direct use in GnuPG. * cipher/idea-stub.c: Remove. * cipher/Makefile.am: Add idea.c and remove idea-stub.c rules. * configure.ac: Remove idea-stub code. * g10/gpg.c (check_permissions): Remove code path for ITEM==2. (main): Make --load-extension a dummy option. * g10/keygen.c (keygen_set_std_prefs): Include IDEA only in PGP2 compatibility mode. * g10/misc.c (idea_cipher_warn): Remove. Also remove all callers. * g10/seckey-cert.c (do_check): Remove emitting of STATUS_RSA_OR_IDEA. * g10/status.c (get_status_string): Remove STATUS_RSA_OR_IDEA. * g10/status.h (STATUS_RSA_OR_IDEA): Remove. -- To keep the number of actually used algorithms low, we support IDEA only in a basically read-only way (unless --pgp2 is used during key generation). It does not make sense to suggest the use of this old 64 bit blocksize algorithm. However, there is old data available where it might be helpful to have IDEA available.
* Fix typos spotted during translationsWerner Koch2012-08-241-2/+2
| | | | | * g10/gpg.c: uppercase after Syntax * util/secmem.c (print_warn): Update URL.
* Replace file locking by the new portable dotlock code.Werner Koch2012-01-101-2/+2
| | | | | | | | | | | | | * include/dotlock.h: New. From current gnupg master. * util/dotlock.c: Ditto. Include util.h. The major changes done in master are: Factor Unix and W32 specific code out into specific functions. Define HAVE_POSIX_SYSTEM. Rearrange some functions. (disable_dotlock): Rename to dotlock_disable. (create_dotlock): Rename to dotlock_create and add a dummy arg. (destroy_dotlock): Rename to dotlock_destroy. (make_dotlock): Rename to dotlock_take. (release_dotlock): Rename to dotlock_release. (remove_lockfiles): Rename to dotlock_remove_lockfiles.
* Update copyright years.Werner Koch2012-01-101-1/+1
| | | | * util/argparse.c (default_strusage): Update printed copyright year.
* On VMS use --batch by default if in batch mode.Werner Koch2011-09-121-0/+12
| | | | | | This problem was identified and solved by Steven M. Schweda. Note that the vms specific code is not part of this repository. See http://antinode.info/dec/sw/gnupg.html for the VMS port.
* Add pubkey letters e and E for ECC.Werner Koch2011-07-011-39/+41
| | | | | | | This does not mean we have any kind of ECC support now. It is merely to avoid printing a question mark for the algorithm. Trailing white space changes as usual.
* * gpg.c (main): Do not provide a default forDavid Shaw2010-10-291-6/+1
| | | | | | --personal-digest-preferences. This allows the usual digest selection algorithm to pick a digest based on recipient keys.
* Ignore some GnuPG-2 only options.Werner Koch2010-06-011-1/+8
|
* * gpg.c (main): --pgp6 includes --disable-mdc.David Shaw2009-07-311-0/+1
|
* Parse EXTCAP lines from the card.Werner Koch2009-07-231-4/+2
| | | | | Change messages for a corrupt trustdb.
* First set of changes to backport the new card code from 2.0.Werner Koch2009-07-211-0/+1
| | | | | | | | For compatibility reasons a few new files had to be added. Also added estream-printf as this is now used in app-openpgp.c and provides a better and generic asprintf implementation than the hack we used for the W32 code in ttyio.c. Card code is not yet finished.
* Remove Camellia restriction.David Shaw2009-06-051-9/+1
|
* Fix bug#1044.Werner Koch2009-05-201-6/+14
|
* * gpg.c (main): Properly handle UTF8 usernames with --sign-key and --lsign-key.David Shaw2008-12-211-1/+1
|
* Revert that last stupid setuid detection fix.Werner Koch2008-07-171-1/+1
|
* 2008-02-09 Marcus Brinkmann <[email protected]>Marcus Brinkmann2008-02-091-44/+66
| | | | | | | | * gpg.c (main): New variable default_configname. Use it if save_configname is NULL (can happen if default configfile does not exist). Move default configname determination to ... (get_default_configname): ... this new function.
* Fixed a regression in gpg_dermor.gnupg-1.4.8rc2Werner Koch2007-12-141-0/+3
|
* * gpg.c (print_algo_names): New. (list_config): Use it here for theDavid Shaw2007-11-281-1/+35
| | | | | | "ciphername" and "digestname" config items so we can get a script-parseable list of the names.
* Switched to GPLv3.Werner Koch2007-10-231-4/+2
| | | | | Updated gettext.
* * gpg.c (main): Add --require-cross-certification toDavid Shaw2007-10-231-2/+3
| | | | | --openpgp/--rfc4880 mode.
* * gpg.c (main): Disable --rfc2440-text and --force-v3-sigs by default.David Shaw2007-10-231-9/+9
| | | | | | | Enable --require-cross-certification by default. --openpgp (--rfc4880) is the same as --rfc2440 except with "--enable-dsa2 --no-rfc2440-text --escape-from-lines".
* * options.h, gpg.c (main), misc.c (compliance_option_string): AddDavid Shaw2007-10-171-1/+24
| | | | | | | | | --rfc4880, and make --openpgp an alias to it. --rfc2440 now stands alone. For now, use the old 2440 defaults for 4880. * keyedit.c (keyedit_menu): Use compliance_option_string() instead of printing the compliance modes here.
* * gpg.c (main): Fix typo. Noted by John Clizbe.David Shaw2007-07-191-1/+1
|
* Add an extra warning for Camellia.Werner Koch2007-07-091-0/+8
| | | | | | Minor W32 fix Address change.
* * gpg.c, pkclist.c: #include <strings.h> for strcasecmp if it isDavid Shaw2007-04-161-2/+5
| | | | | | present. Note that autoconf protects us against a strings.h that cannot be used together with string.h.
* Preparing 1.4.7gnupg-1.4.7Werner Koch2007-03-051-4/+15
|
* * main.h, keygen.c (ask_expire_interval, parse_expire_string): Pass inDavid Shaw2007-02-011-2/+2
| | | | | | the time to use to calculate the expiration offset, rather than querying it internally. Change all callers.
* Removed references to removed g10defs.h file.Werner Koch2006-12-131-1/+0
|
* Removed the use of g10defs.h.Werner Koch2006-12-111-1/+1
| | | | | | This required some code cleanups and the introduction of a few accessor ducntions in mpi.
* * options.h, gpg.c (main), passphrase.c (passphrase_to_dek): AddDavid Shaw2006-12-031-0/+4
| | | | | | | --passphrase-repeat option to control how many times gpg will re-prompt for a passphrase to ensure the user has typed it correctly. Defaults to 1.
* New command --gpgconf-test.Werner Koch2006-10-231-0/+6
|
* * parse-packet.c (parse_symkeyenc): Show the unpacked as well as theDavid Shaw2006-10-131-0/+32
| | | | | | | | | packed s2k iteration count. * main.h, options.h, gpg.c (encode_s2k_iterations, main), passphrase.c (hash_passphrase): Add --s2k-count option to specify the number of s2k hash iterations.
* do no use reopen_std under W32.Werner Koch2006-06-271-2/+2
|
* * options.h, gpg.c (main), keygen.c (keygen_upd_std_prefs,David Shaw2006-06-221-0/+15
| | | | | | | keygen_add_std_prefs, proc_parameter_file): Add --default-keyserver-url to specify a keyserver URL at key generation time, and "Keyserver:" keyword for doing the same through a batch file.
* * gpg.c (reopen_std): New function to reopen fd 0, 1, or 2 if we areDavid Shaw2006-05-231-0/+62
| | | | | | | | called with them closed. This is to protect our keyring/trustdb files from corruption if they get attached to one of the standard fds. Print a warning if possible that this has happened, and fail completely if we cannot reopen (should never happen). (main): Call it here.
* * options.h, gpg.c (main): Add --enable-dsa2 and --disable-dsa2. DefaultsDavid Shaw2006-04-201-0/+7
| | | | | | | | | | | | | | | | to disable. * pkclist.c (algo_available): If --enable-dsa2 is set, we're allowed to truncate hashes to fit DSA keys. * sign.c (match_dsa_hash): New. Return the best match hash for a given q size. (do_sign, hash_for, sign_file): When signing with a DSA key, if it has q==160, assume it is an old DSA key and don't allow truncation unless --enable-dsa2 is also set. q!=160 always allows truncation since they must be DSA2 keys. (make_keysig_packet): If the user doesn't specify a --cert-digest-algo, use match_dsa_hash to pick the best hash for key signatures.
* * gpg.c (print_mds), armor.c (armor_filter, parse_hash_header): AddDavid Shaw2006-04-201-3/+18
| | | | | | | | | | | | | | SHA-224. * sign.c (write_plaintext_packet), encode.c (encode_simple): Factor common literal packet setup code from here, to... * main.h, plaintext.c (setup_plaintext_name): Here. New. Make sure the literal packet filename field is UTF-8 encoded. * options.h, gpg.c (main): Make sure --set-filename is UTF-8 encoded and note when filenames are already UTF-8.
* * getkey.c (parse_auto_key_locate): Fix dupe-removal code.David Shaw2006-04-091-3/+8
| | | | | | | | | | | | | * keyedit.c (menu_backsign): Allow backsigning even if the secret subkey doesn't have a binding signature. * armor.c (radix64_read): Don't report EOF when reading only a pad (=) character. The EOF actually starts after the pad. * gpg.c (main): Make --export, --send-keys, --recv-keys, --refresh-keys, and --fetch-keys follow their arguments from left to right. Suggested by Peter Palfrader.
* About to release 1.4.3gnupg-1.4.3Werner Koch2006-04-031-0/+2
|
* * options.h, sign.c (mk_notation_policy_etc), gpg.c (add_notation_data):David Shaw2006-03-081-60/+13
| | | | | | | | | | Use it here for the various notation commands. * packet.h, main.h, keygen.c (keygen_add_notations), build-packet.c (string_to_notation, sig_to_notation) (free_notation): New "one stop shopping" functions to handle notations and start removing some code duplication.
* * options.h, mainproc.c (check_sig_and_print), gpg.c (main):David Shaw2006-03-081-7/+9
| | | | | | | | | pka-lookups, not pka-lookup. * options.h, gpg.c (main), keyedit.c [cmds], sig-check.c (signature_check2): Rename "backsign" to "cross-certify" as a more accurate name.
* * options.h, gpg.c (main, parse_trust_model), pkclist.cDavid Shaw2006-03-071-39/+9
| | | | | | | (check_signatures_trust), mainproc.c (check_sig_and_print, pka_uri_from_sig), trustdb.c (init_trustdb): Some tweaks to PKA so that it is a verify-option now.