aboutsummaryrefslogtreecommitdiffstats
path: root/g10/pkclist.c (unfollow)
Commit message (Collapse)AuthorFilesLines
2015-01-22gpg: Replace remaining old error code macros by GPG_ERR_.Werner Koch1-8/+8
* g10/gpg.h (g10_errstr): Remove macro and change all occurrences by gpg_strerror. (G10ERR_): Remove all macros and change all occurrences by their GPG_ERR_ counterparts. Signed-off-by: Werner Koch <[email protected]>
2014-08-14gpg: Remove options --pgp2 and --rfc1991.Werner Koch1-12/+4
* g10/gpg.c (oRFC1991, oPGP2): Remove (opts): Remove --pgp2 and --rfc1991. * g10/options.h (CO_PGP2, CO_RFC1991): Remove. Remove all users. (RFC2440, PGP2): Remove. Remove all code only enabled by these conditions. * tests/openpgp/clearsig.test: Remove --rfc1991 test. -- The use of PGP 2.c is considered insecure for quite some time now (e.g. due to the use of MD5). Thus we remove all support for _creating_ PGP 2 compatible messages.
2014-06-10gpg: Use more specific reason codes for INV_RECP.Werner Koch1-7/+15
* g10/pkclist.c (find_and_check_key, build_pk_list): Use more specific reasons codes for INV_RECP. -- GnuPG-bug-id: 1650
2014-03-27Change some keyedit functions to allow printing to arbitrary streams.Werner Koch1-9/+9
* common/ttyio.c (tty_print_string): Add optional arg FP. Change all callers. (tty_print_utf8_string2): Ditto. * g10/keyedit.c (show_prefs): Ditto. (show_key_with_all_names_colon): Ditto. (show_names): Ditto. * g10/keylist.c (print_revokers): Ditto. (print_fingerprint): Ditto.
2014-02-10gpg: Allow building without any trust model support.Werner Koch1-1/+6
* configure.ac: Add option --disable-trust-models (NO_TRUST_MODELS): New ac_define and am_conditional. * g10/Makefile.am (trust_source): New. (gpg2_SOURCES): Factor some files out to above. Add trust.c. * g10/gpg.c [NO_TRUST_MODELS]: Disable options --export-ownertrust, --import-ownertrust, --update-trustdb, --check-trustdb, --fix-trustdb, --list-trustdb, --trustdb-name, --auto-check-trustdb, --no-auto-check-trustdb, and --force-ownertrust. (parse_trust_model) [NO_TRUST_MODELS]: Do not build. (main) [NO_TRUST_MODELS]: Set trust_model to always and exclude all trustdb related option code. * g10/keyedit.c (cmds) [NO_TRUST_MODELS]: Remove menu items "trust", "enable", and "disable". * g10/keylist.c (public_key_list) [NO_TRUST_MODELS]: Do not print "tru" record. * g10/trust.c: New. * g10/trustdb.c (struct key_item): Move to trustdb.h. (register_trusted_keyid): Rename to tdb_register_trusted_keyid. (register_trusted_key): Rename to tdb_register_trusted_key. (trust_letter, uid_trust_string_fixed, trust_value_to_string) (string_to_trust_value, get_ownertrust_with_min, get_ownertrust_info) (get_ownertrust_string, get_validity_info, get_validity_string) (clean_sigs_from_uid, clean_uid_from_key, clean_key): Move to trust.c. (mark_usable_uid_certs): Move to trust.c and make global. (is_in_klist): Move as inline to trustdb.h. (trustdb_check_or_update): Rename to tdb_check_or_update (revalidation_mark): Rename to tdb_revalidation_mark. (get_ownertrust): Rename to tdb_get_ownertrust. (get_min_ownertrust): Rename to tdb_get_min_ownertrust. (update_ownertrust): Rename to tdb_update_ownertrust. (clear_ownertrusts): Rename to tdb_clear_ownertrusts. (cache_disabled_value): Rename to tdb_cache_disabled_value. (check_trustdb_stale): Rename to tdb_check_trustdb_stale. (get_validity): Rename to tdb_get_validity_core, add arg MAIN_PK and factor some code out to ... * trust.c (get_validity): ...new. (check_or_update_trustdb): New wrapper. (revalidation_mark): New wrapper. (get_ownertrust): New wrapper. (get_ownertrust_with_min): New wrapper. (update_ownertrust): New wrapper. (clear_ownertrusts): New wrapper. (cache_disabled_value): New wrapper. (check_trustdb_stale): New wrapper. * tests/openpgp/defs.inc (opt_always): New. Use in all tests instead of --always-trust.
2014-02-05gpg: Change format for the key size in --list-key and --edit-key.Werner Koch1-7/+9
* g10/gpg.c (oLegacyListMode, opts, main): Add --legacy-list-mode. * g10/options.h (struct opt): Add field legacy_list_mode. * g10/keydb.h (PUBKEY_STRING_SIZE): New. * g10/keyid.c (pubkey_string): New. * g10/import.c (import_one, import_secret_one): Use pubkey_string. * g10/keylist.c (print_seckey_info): Ditto. (print_pubkey_info, print_card_key_info): Ditto. (list_keyblock_print): Ditto. * g10/mainproc.c (list_node): Ditto. * g10/pkclist.c (do_edit_ownertrust, build_pk_list): Ditto. * g10/keyedit.c (show_key_with_all_names): Ditto. Also change the format. (show_basic_key_info): Ditto. * common/openpgp-oid.c (openpgp_curve_to_oid): Also allow "ed25519". (openpgp_oid_to_curve): Downcase "ed25519" -- For ECC it seems to be better to show the name of the curve and not just the size of the prime field. The curve name does not anymore fit into the "<size><letter>" descriptor (e.g. "2048R") and a fixed length format does not work either. Thus the new format uses "rsa2048" - RSA with 2048 bit "elg1024" - Elgamal with 1024 bit "ed25519" - ECC using the curve Ed25519. "E_1.2.3.4" - ECC using the unsupported curve with OID "1.2.3.4". unless --legacy-list-mode is given. In does not anymore line up nicely in columns thus I expect further changes to this new format. Signed-off-by: Werner Koch <[email protected]>
2012-12-19gpg: Suppress "public key already present" in quiet mode.Werner Koch1-3/+5
* g10/pkclist.c (find_and_check_key, build_pk_list): Print a diagnostic only in non-quiet mode.
2012-08-24Actually show translators comments in PO filesDavid Prévot1-1/+1
--
2012-06-05Change all quotes in strings and comments to the new GNU standard.Werner Koch1-3/+3
The asymmetric quotes used by GNU in the past (`...') don't render nicely on modern systems. We now use two \x27 characters ('...'). The proper solution would be to use the correct Unicode symmetric quotes here. However this has the disadvantage that the system requires Unicode support. We don't want that today. If Unicode is available a generated po file can be used to output proper quotes. A simple sed script like the one used for en@quote is sufficient to change them. The changes have been done by applying sed -i "s/\`\([^'\`]*\)'/'\1'/g" to most files and fixing obvious problems by hand. The msgid strings in the po files were fixed with a similar command.
2011-09-20Allow NULL for free_public_key.Werner Koch1-4/+5
2011-02-04Nuked almost all trailing white space.post-nuke-of-trailing-wsWerner Koch1-66/+66
We better do this once and for all instead of cluttering all future commits with diffs of trailing white spaces. In the majority of cases blank or single lines are affected and thus this change won't disturb a git blame too much. For future commits the pre-commit scripts checks that this won't happen again.
2010-10-29* pkclist.c (select_algo_from_prefs): Make sure the scores can'tDavid Shaw1-17/+31
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). * pkclist.c (select_algo_from_prefs): Slightly improve the handling of 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.
2010-10-20Make public key data structure easier to read.Werner Koch1-4/+4
Check vor v1 card while signing.
2010-10-01Exporting secret keys via gpg-agent is now basically supported.Werner Koch1-7/+9
A couple of forward ported changes. Doc updates.
2010-04-23Decryption and signi via agent is now implemented.Werner Koch1-12/+12
2010-04-21More changes on the way to remove secring.gpg.Werner Koch1-6/+6
2010-03-15Finished the bulk of changes to use estream in most places instead ofWerner Koch1-6/+5
stdio.
2009-12-08Unification of the search descriptor usage.Werner Koch1-1/+1
2009-09-30Some changes to suport g13.Werner Koch1-92/+119
2008-10-03* main.h, mainproc.c (check_sig_and_print), keylist.cDavid Shaw1-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.
2008-09-23* pkclist.c (select_algo_from_prefs): Redo function to rank prefs andDavid Shaw1-143/+153
pick a consensus winner across all keys.
2008-05-07--locate-key now returns several keys if they all match.Werner Koch1-4/+4
2008-04-08Enhanced --auto-key-locate.Werner Koch1-6/+7
2008-04-07Minor cleanups.Werner Koch1-1/+0
Implemented key helper kdns
2007-11-19Started to implement the audit log feature.Werner Koch1-1/+1
Pass PINENTRY_USER_DATA and XAUTHORITY to Pinentry. Improved support for the quality bar. Minor internal restructuring. Translation fixes.
2007-07-04Changed to GPLv3.Werner Koch1-4/+2
Removed intl/.
2007-01-30Added LIBINTL to more Makefile targets.Werner Koch1-0/+12
doc/ * com-certs.pem: Added the current root certifcates of D-Trust and S-Trust. g10/ * status.c (write_status_begin_signing): New. * sign.c (sign_file, sign_symencrypt_file): Call it. * textfilter.c (copy_clearsig_text): Call it. * call-agent.c (agent_scd_pksign): Pass --hash-rmd160 to SCD if required. * gpg.c (main): Let --no-use-agent and --gpg-agent-info print a warning. * misc.c (obsolete_option): New.
2006-11-05Collected fixes.Werner Koch1-16/+64
2006-10-02Fix for bug 537Werner Koch1-8/+8
2006-07-27Preparing a new releasegnupg-1.9.22Werner Koch1-10/+11
2006-07-26Fixed memory allocation bug and typos.Werner Koch1-1/+1
2006-06-30A couple of fixes. gpg2's key generation does now work.Werner Koch1-4/+4
2006-06-28* keydb.h, pkclist.c (select_algo_from_prefs, algo_available): Pass aDavid Shaw1-6/+7
union for preference hints rather than doing void * games. * sign.c (sign_file): Use it here.
2006-06-28* pkclist.c (algo_available): Automatically enable DSA2 mode when handlingDavid Shaw1-5/+5
a key that clearly isn't DSA1 (i.e. q!=160).
2006-05-23g10/ does build again.Werner Koch1-4/+4
2006-04-28Merged recent changes from 1.4Werner Koch1-4/+16
2006-04-20* options.h, gpg.c (main): Add --enable-dsa2 and --disable-dsa2. DefaultsDavid Shaw1-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.
2006-04-19Continued with merging.Werner Koch1-1/+1
Still does not build.
2006-04-19Merged with gpg 1.4.3 code. Werner Koch1-557/+620
The gpg part does not yet build.
2006-03-07* options.h, gpg.c (main, parse_trust_model), pkclist.cDavid Shaw1-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.
2005-12-20Finished PKA featureWerner Koch1-3/+7
2005-12-08Made strings translatable. Minor fixes.Werner Koch1-1/+1
2005-11-10* packet.h: Move some flags to a bitfield. Change all callers.David Shaw1-1/+1
2005-08-05auto retrieve keys from PKA. Thsi allows to specify an email addressWerner Koch1-304/+401
so that gpg can get the key from DNS. This helps with opportunistic encryption. No integration with the trust modell yet.
2005-08-05* pkclist.c (do_edit_ownertrust): Don't allow ownertrust level 0.David Shaw1-1/+1
Noted by Michael Schierl.
2005-08-04Fixes pertaining to revocation creation with subkey-only exported card keysWerner Koch1-3/+10
2005-07-28Implemented PKA trust modelWerner Koch1-0/+42
2005-07-27Converted all m_free to xfree etc.Werner Koch1-22/+22
2005-05-31Updated FSF street address and preparations for a release candidate.Werner Koch1-1/+2
2004-10-28* skclist.c (build_sk_list): Don't need to warn about PGP-generatedDavid Shaw1-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.