aboutsummaryrefslogtreecommitdiffstats
path: root/g10/pkclist.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Fix spelling: "occured" should be "occurred"Daniel Kahn Gillmor2016-08-041-1/+1
| | | | | | | | * checks/armor.test, cipher/des.c, g10/ccid-driver.c, g10/pkclist.c, util/regcomp.c, util/regex_internal.c: correct the spelling of "occured" to "occurred" Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Use more specific reason codes for INV_RECP.Werner Koch2014-06-231-5/+13
| | | | | | | | | | * g10/pkclist.c (build_pk_list): Use more specific reasons codes for INV_RECP. -- GnuPG-bug-id: 1650 Note that this patch is a bit more limited than the one in 2.1.
* gpg: Suppress "public key already present" in quiet mode.Werner Koch2012-12-201-4/+6
| | | | | | | | * g10/pkclist.c (build_pk_list): Print two diagnostics only in non-quiet mode. -- (back-ported from commit 8325d616593187ff227853de0295e3269b96edcb)
* Support the not anymore patented IDEA cipher algorithm.Werner Koch2012-11-081-56/+55
| | | | | | | | | | | | | | | | | | | | | | | | * 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.
* Actually show translators comments in PO filesDavid Prévot2012-08-241-1/+1
| | | | | | | -- Note that strings marked for gettext need to immediately follow a TRANSLATOR comment block.
* * pkclist.c (select_algo_from_prefs): Slightly improve the handling ofDavid Shaw2010-10-291-13/+21
| | | | | | | MD5 in preference lists. Instead of replacing MD5 with SHA-1, just remove MD5 from the list altogether, and let the next-highest ranked algorithm be chosen.
* * pkclist.c (select_algo_from_prefs): Make sure the scores can'tDavid Shaw2010-10-291-4/+10
| | | | | | | overflow when picking an algorithm (not a security issue since we can't pick something not present in all preference lists, but we might pick something that isn't scored first choice).
* * main.h, mainproc.c (check_sig_and_print), keylist.cDavid Shaw2008-10-031-1/+2
| | | | | | | | | (list_keyblock_print), pkclist.c (do_edit_ownertrust), keyedit.c (menu_showphoto), photoid.c (generate_photo_id, show_photos), misc.c (pct_expando): Add %v and %V expandos so that displaying photo IDs can show the attribute validity tag (%v) and string (%V). Originally by Daniel Gillmor.
* * pkclist.c (select_algo_from_prefs): Redo function to rank prefs andDavid Shaw2008-09-231-139/+150
| | | | | pick a consensus winner across all keys.
* Switched to GPLv3.Werner Koch2007-10-231-4/+2
| | | | | Updated gettext.
* * 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.
* Fixed memory allocation bug and typos.Werner Koch2006-07-261-1/+1
|
* * keydb.h, pkclist.c (select_algo_from_prefs, algo_available): Pass aDavid Shaw2006-06-281-6/+7
| | | | | | | union for preference hints rather than doing void * games. * sign.c (sign_file): Use it here.
* * pkclist.c (algo_available): Automatically enable DSA2 mode when handlingDavid Shaw2006-06-281-5/+5
| | | | | a key that clearly isn't DSA1 (i.e. q!=160).
* * options.h, gpg.c (main): Add --enable-dsa2 and --disable-dsa2. DefaultsDavid Shaw2006-04-201-4/+16
| | | | | | | | | | | | | | | | 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.
* * options.h, gpg.c (main, parse_trust_model), pkclist.cDavid Shaw2006-03-071-1/+1
| | | | | | | (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.
* Finished PKA featureWerner Koch2005-12-201-3/+7
|
* Made strings translatable. Minor fixes.Werner Koch2005-12-081-1/+1
|
* * packet.h: Move some flags to a bitfield. Change all callers.David Shaw2005-11-101-1/+1
|
* auto retrieve keys from PKA. Thsi allows to specify an email addressWerner Koch2005-08-051-304/+401
| | | | | | so that gpg can get the key from DNS. This helps with opportunistic encryption. No integration with the trust modell yet.
* * pkclist.c (do_edit_ownertrust): Don't allow ownertrust level 0.David Shaw2005-08-051-1/+1
| | | | | Noted by Michael Schierl.
* Fixes pertaining to revocation creation with subkey-only exported card keysWerner Koch2005-08-041-3/+10
|
* Implemented PKA trust modelWerner Koch2005-07-281-0/+42
|
* Converted all m_free to xfree etc.Werner Koch2005-07-271-22/+22
|
* Updated FSF street address and preparations for a release candidate.Werner Koch2005-05-311-1/+2
|
* * skclist.c (build_sk_list): Don't need to warn about PGP-generatedDavid Shaw2004-10-281-1/+1
| | | | | | | | | | | | | | | | | Elgamal signing keys since we no longer support any Elgamal signing keys. * sign.c (sign_file, clearsign_file): Use "writing to" instead of "writing to file" to match other strings. * pkclist.c (check_signatures_trust): Fix typo. Noted by Moray Allan. This is Debian bug #278708. * passphrase.c (ask_passphrase, passphrase_to_dek): "password" -> "passphrase". * keyedit.c (show_key_with_all_names): Show designated revoker as part of translatable string.
* * delkey.c, export.c, keyedit.c, pkclist.c, revoke.c, skclist.c: Fix a fewDavid Shaw2004-10-281-1/+1
| | | | | missed possible \"username\" quotes.
* * pkclist.c (do_edit_ownertrust): Add a note to translators.Werner Koch2004-10-151-1/+12
| | | | | | | * keygen.c (ask_user_id): Ditto. * helptext.c: Typo fix.
* * pkclist.c (do_edit_ownertrust): Different prompt when we're using directDavid Shaw2004-10-131-14/+26
| | | | | | | | | | | | | | trust since the meaning is different. * keyedit.c (trustsig_prompt): Change the strings to match the ones in pkclist.c:do_edit_ownertrust to make translation easier. * trustdb.c (trust_model_string, get_validity): Add direct trust model which applies to the key as a whole and not per-uid. * options.h, g10.c (parse_trust_model): New. (main): Call it from here to do string-to-trust-model.
* * pkclist.c (do_edit_ownertrust): Use the same translated string forDavid Shaw2004-10-111-2/+2
| | | | | | | | | | | | | | showing the user ID as mainproc.c:print_pkenc_list. * mainproc.c (print_pkenc_list): Allow translating the quotes around the user ID. * card-util.c, g10.c, photoid.c, trustdb.c: The last of the \"%s\" -> `%s' quoting for things that aren't user IDs. * keyserver.c (keyserver_spawn): If there is no keyserver host, print the whole URI since it is self-contained.
* * card-util.c, keyedit.c, openfile.c, pkclist.c, delkey.c, keygen.c,David Shaw2004-10-101-2/+2
| | | | | | photoid.c, revoke.c: Some yes-or-no prompts end in "(y/n)". Some don't. Consistently use y/n everywhere.
* * pkclist.c (build_pk_list): Keystrify.David Shaw2004-10-071-11/+8
| | | | | | * mainproc.c (check_sig_and_print), pkclist.c (do_edit_ownertrust): Improve translatability of user ID prompts.
* * helptext.c, pkclist.c (do_we_trust): It is not possible to get here withDavid Shaw2004-10-061-123/+60
| | | | | | | | | | | | | a revoked or expired key, so BUG() that case. Remove question about overriding revoked/expired. Also --keyid-format-ify. (do_we_trust_pre): Use print_pubkey_info() instead of printing the info ourselves. * passphrase.c (passphrase_to_dek): Improve translatability of user ID prompts. * keylist.c (print_pubkey_info): Use the user ID the pk was selected by, if any.
* * plaintext.c (handle_plaintext): Bigger buffer for extra safety.David Shaw2004-08-081-9/+13
| | | | | | | | | | | | | | | | | * g10.c (main): New alias --throw-keyid for --throw-keyids, so that it continues to work in old configuration files. Noted by Jens Adam. * pkclist.c (algo_available): --pgp8 now allows blowfish, zlib, and bzip2. * status.c (do_get_from_fd): Flush stdout if status isn't flushing it for us. This guarantees that any menus that were displayed before the prompt don't get stuck in a buffer. Noted by Peter Palfrader. This is Debian bug #254072. * sign.c (update_keysig_packet): Revert change of 2004-05-18. It is not appropriate to strip policy and notations when remaking a sig. That should only happen when specifically requested by the user.
* * verify.c (verify_signatures): Verify multiple files in the same order inDavid Shaw2004-05-231-20/+21
| | | | | | | | which we hashed them when issuing the signature. Noted by Nicholas Cole. * pkclist.c (do_edit_ownertrust): Fix a kbnode leak and do another keyid-format conversion.
* * keyserver.c (keyserver_work): Allow --refresh-keys with a preferredDavid Shaw2004-05-201-70/+1
| | | | | | | | | | | keyserver to happen even if there is no global keyserver set. * sig-check.c (do_check_messages): No need to check for Elgamal signatures any longer. (do_check_messages, do_check, check_key_signature2): --keyid-format conversion. * pkclist.c (show_paths, edit_ownertrust): Remove some unused code.
* * packet.h, getkey.c (merge_selfsigs, merge_selfsigs_main), pkclist.cDavid Shaw2004-01-221-3/+7
| | | | | | (check_signatures_trust): Indicate who has revoked a key (the owner or a designated revoker). If a key was revoked by both, prefer the owner.
* * misc.c (pull_in_libs): Dead code. Removed.David Shaw2003-12-301-0/+4
| | | | | | | | | | | | | | | | | | | | | | | * sig-check.c (check_revocation_keys): Comments. * getkey.c (merge_selfsigs_main): Don't bother to check designated revoker sigs if the key is already revoked. * packet.h, getkey.c (merge_selfsigs_main): New "maybe_revoked" flag on PKs. It is set when there is a revocation signature from a valid revocation key, but the revocation key is not present to verify the signature. * pkclist.c (check_signatures_trust): Use it here to give a warning when showing key trust. * compress-bz2.c: Include stdio.h. Solaris 9 has a very old bzip2 library and we can at least guarantee that it won't fail because of the lack of stdio.h. * tdbio.c: Fixed format string bugs related to the use of DB_NAME. Reported by Florian Weimer.
* * pkclist.c (build_pk_list): Do not allow an empty PK list in interactiveDavid Shaw2003-11-271-1/+2
| | | | | | | | mode. * getkey.c (get_seckey_byname2): Disallow use of sign+encrypt Elgamal keys.
* * pkclist.c (build_pk_list): When adding recipients interactively, allowDavid Shaw2003-11-101-0/+1
| | | | | the user to stop at any point.
* * trustdb.h, trustdb.c (register_trusted_keyid): New. Adds a keyid to theDavid Shaw2003-11-011-22/+31
| | | | | | | | | | | | | | | | | | | | list of ultimately trusted keys. * keygen.c (do_generate_keypair): Use it here so that the ultimate ownertrust happens before the trustdb (might be) rebuilt. Also fix an error where the newly generated pk is thought to be a subkey by the trustdb. * g10.c (main): Fix --export-all do actually do something different than --export. * pkclist.c (build_pk_list): Show all recipients rather than showing each recipient as they are added. * mainproc.c (proc_symkey_enc, proc_encrypted): Keep a count of the number of passphrases that can decrypt a symmetric or mixed symmetric/pk message and include it in the list of keys shown to the user.
* * sign.c (mk_notation_policy_etc): Capitalize "URL".David Shaw2003-09-241-1/+1
| | | | | | | | | | * trustdb.c (validate_keys): Give a little more information while rebuilding trustdb. * pkclist.c (do_edit_ownertrust): Clarify "don't know". * g10.c (main): Default to --no-mangle-dos-filenames.
* * armor.c (parse_hash_header, armor_filter), g10.c (print_hex, print_mds),David Shaw2003-09-041-4/+0
| | | | | pkclist.c (algo_available): Drop TIGER/192 support.
* * mainproc.c (check_sig_and_print), main.h, keylist.c (show_policy,David Shaw2003-05-311-1/+2
| | | | | | | | | | | | | | | | | show_notation): Collapse the old print_notation_data into show_policy() and show_notation() so there is only one function to print notations and policy URLs. * options.h, main.h, g10.c (main), keyedit.c (print_and_check_one_sig), keylist.c (list_one, list_keyblock_print), pkclist.c (do_edit_ownertrust), sign.c (mk_notation_and_policy): New "list-options" and "verify-options" commands. These replace the existing --show-photos/--no-show-photos, --show-notation/--no-show-notation, --show-policy-url/--no-show-policy-url, and --show-keyring options. The new method is more flexible since a user can specify (for example) showing photos during sig verification, but not in key listings. The old options are emulated.
* * armor.c, g10.c, kbnode.c, misc.c, pkclist.c, sign.c, build-packet.c,David Shaw2003-05-241-6/+6
| | | | | | | | | getkey.c, keydb.c, openfile.c, plaintext.c, status.c, gpgv.c, keygen.c, options.h, sig-check.c, tdbio.h, encode.c, mainproc.c, parse-packet.c, signal.c, textfilter.c: Edit all preprocessor instructions to remove whitespace before the '#'. This is not required by C89, but there are some compilers out there that don't like it.
* * packet.h, build-packet.c (build_sig_subpkt), export.cDavid Shaw2003-05-031-43/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (do_export_stream), import.c (remove_bad_stuff, import), parse-packet.c (dump_sig_subpkt, parse_one_sig_subpkt): Remove vestigal code for the old sig cache subpacket. This wasn't completely harmless as it caused subpacket 101 to disappear on import and export. * options.h, armor.c, cipher.c, g10.c, keyedit.c, pkclist.c, sign.c, encode.c, getkey.c, revoke.c: The current flags for different levels of PGP-ness are massively complex. This is step one in simplifying them. No functional change yet, just use a macro to check for compliance level. * sign.c (sign_file): Fix bug that causes spurious compression preference warning. * sign.c (clearsign_file): Fix bug that prevents proper warning message from appearing when clearsigning in --pgp2 mode with a non-v3 RSA key. * main.h, misc.c (compliance_option_string, compliance_string, compliance_failure), pkclist.c (build_pk_list), sign.c (sign_file, clearsign_file), encode.c (encode_crypt, write_pubkey_enc_from_list): New functions to put the "this message may not be usable...." warning in one place. * options.h, g10.c (main): Part two of the simplification. Use a single enum to indicate what we are compliant to (1991, 2440, PGPx, etc.) * g10.c (main): Show errors for failure in export, send-keys, recv-keys, and refresh-keys. * options.h, g10.c (main): Give algorithm warnings for algorithms chosen against the --pgpX and --openpgp rules. * keydb.h, pkclist.c (algo_available): Make TIGER192 invalid in --openpgp mode. * sign.c (sign_file), pkclist.c (algo_available): Allow passing a hint of 0.
* * tdbio.c (create_version_record): Only create new trustdbs withDavid Shaw2003-05-011-1/+1
| | | | | | | | | | | | | | | | | | | | TM_CLASSIC or TM_PGP. * trustdb.h, trustdb.c (trust_string, get_ownertrust_string, get_validity_string, ask_ownertrust, validate_keys), pkclist.c (do_edit_ownertrust): Rename trust_string to trust_value_to_string for naming consistency. * trustdb.h, trustdb.c (string_to_trust_value): New function to translate a string to a trust value. * g10.c (main): Use string_to_trust_value here for --force-ownertrust. * options.h, g10.c (main), trustdb.c (trust_model_string, init_trustdb, check_trustdb, update_trustdb, get_validity, validate_one_keyblock): An "OpenPGP" trust model is misleading since there is no official OpenPGP trust model. Use "PGP" instead.
* * build-packet.c (build_sig_subpkt): Comments.David Shaw2003-04-301-13/+24
| | | | | | | | | | | | | | | | | | | | | | | | | * exec.c (exec_write): Cast NULL to void* to properly terminate varargs list. * keyedit.c (show_key_with_all_names): Just for safety, catch an invalid pk algorithm. * sign.c (make_keysig_packet): Crucial that the call to mksubpkt comes LAST before the calls to finalize the sig as that makes it possible for the mksubpkt function to get a reliable pointer to the subpacket area. * pkclist.c (do_we_trust_pre): If an untrusted key was chosen by a particular user ID, use that ID as the one to ask about when prompting whether to use the key anyway. (build_pk_list): Similar change here when adding keys to the recipient list. * trustdb.c (update_validity): Fix bug that prevented more than one validity record per trust record. (get_validity): When retrieving validity for a (user) supplied user ID, return the validity for that user ID only, and do not fall back to the general key validity. (validate_one_keyblock): Some commentary on whether non-self-signed user IDs belong in the web of trust (arguably, they do).
* * import.c (import_revoke_cert): Remove ultimate trust when revoking anDavid Shaw2003-04-231-10/+10
| | | | | | | | | | | | | | | | | | ultimately trusted key. * keyedit.c (sign_uids): Allow replacing expired signatures. Allow duplicate signatures with --expert. * pkclist.c (check_signatures_trust): Don't display a null fingerprint when checking a signature with --always-trust enabled. * filter.h (progress_filter_context_t), progress.c (handle_progress), plaintext.c (ask_for_detached_datafile, hash_datafiles): Fix compiler warnings. Make "what" constant. * build-packet.c (do_plaintext): Do not create invalid literal packets with >255-byte names.
* * pkclist.c (algo_available): PGP 8 can use the SHA-256 hash.David Shaw2003-04-041-14/+16
| | | | | | * sign.c (sign_file, clearsign_file, sign_symencrypt_file): Remove unused code.