aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* scd: Silence compiler warning.NIIBE Yutaka2020-10-061-3/+3
| | | | | | | | | | | | * scd/app-openpgp.c (build_ecc_privkey_template): Fix allocation size. -- Cherry-picked from master commit of: 2a34a2afea5fcb5f4ed206afa110650db3dd7ef0 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Report any error for LEARN command.NIIBE Yutaka2020-10-061-28/+63
| | | | | | | | | | | | * scd/app-openpgp.c (do_learn_status): Report any error. -- Backport master commit of: 862d9c6face9b4ad61f6e59bf1ba9b5f5d05c58c Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Internal CCID driver: More fix for SPR532.NIIBE Yutaka2020-10-061-4/+4
| | | | | | | | | | | | | * scd/ccid-driver.c (bulk_in): Handle the case of missing intr_cb. -- Backport master commit of: 920f258eb6018ecec1d63bad6a0fb0772f72affa GnuPG-bug-id: 5065 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Internal CCID driver fix.NIIBE Yutaka2020-10-061-2/+5
| | | | | | | | | | | | | * scd/ccid-driver.c (intr_cb): More useful debug output. (ccid_slot_status): Remove redundant condition. -- Backport master commit of: 1444203ca32ccfa4bd5097d2d49565c4055c620b Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Internal CCID driver: Call libusb_clear_halt at ccid_setup_intr.NIIBE Yutaka2020-10-061-3/+1
| | | | | | | | | | | | | * scd/ccid-driver.c (ccid_setup_intr): Reset the endpoint. (ccid_vendor_specific_init): Don't call libusb_clear_halt. -- Backport master commit of: 6af978713e4c69d7814f47e709f1dfb3fe9076d1 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Internal CCID driver: Fix a failure path.NIIBE Yutaka2020-10-061-0/+1
| | | | | | | | | | | | | * scd/ccid-driver.c (ccid_open_usb_reader): On error, call libusb_release_interface. -- Backport master commit of: d561c936a217627bc29aac628a8d01f7003dcd28 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Internal CCID: Handle LIBUSB_ERROR_TIMEOUT at ccid_get_atr.NIIBE Yutaka2020-10-061-1/+2
| | | | | | | | | | | | | | | * scd/ccid-driver.c (ccid_slot_status): Handle LIBUSB_ERROR_TIMEOUT. -- Backport master commit of: b1e8072320c19246962beb6d67dc5784b5a72364 With SPR532, at the first connection, it fails by LIBUSB_ERROR_TIMEOUT, but no retry. Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Change handling of SPR532 card reader.NIIBE Yutaka2020-10-061-4/+17
| | | | | | | | | | | | | | | | * scd/ccid-driver.c (ccid_vendor_specific_init): Put some workaround for SPR532 initialization. (ccid_slot_status): Send ESCape command after GetSlotStatus. -- Backport master commit of: 684a52dffa8b7f79b26fe53b3ab10d7748a8fb37 GnuPG-bug-id: 5065 Fixes-commit: 4fae55f8ee11b3f710524e5e8b8a91b159949f2d Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: For SPR532, submit the ESCape command at initialization.NIIBE Yutaka2020-10-061-14/+13
| | | | | | | | | | | | | | * scd/ccid-driver.c (ccid_vendor_specific_init): Submit the ESC command for VENDOR_SCM. (ccid_transceive_secure): Don't submit the ESC command every time. -- Backport master commit of: 4fae55f8ee11b3f710524e5e8b8a91b159949f2d Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Fix CCID internal driver for interrupt transfer.NIIBE Yutaka2020-10-061-3/+36
| | | | | | | | | | | | | | | | | | * scd/ccid-driver.c (intr_cb): Handle the case of multiple messages. -- Backport master commit of: 7cbb513a2dc150a90a30c53316970df2a439d494 SPR532 USB Smart Card Reader (also know as SPR332) may send two messages at once for a single interrupt transfer. An example transfer observed was like: 50 03 50 02, which is considered valid, according to the CCID specification. GnuPG-bug-id: 5065 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Better handling of timeout and time extension.NIIBE Yutaka2020-10-061-7/+4
| | | | | | | | | | | | | | | * scd/ccid-driver.c (CCID_CMD_TIMEOUT_LONGER): Remove. (ccid_transceive): Don't use x4 blindly for bBWI, but use dynamically determined value. Use value from variable wait_more for bulk_in. Set wait_more by the value of time extension request. -- Backport master commit of: f1cf799a37f320d33cae445c74f3fc1936dd9995 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Fix internal CCID driver, so that -DTEST works.NIIBE Yutaka2020-10-061-41/+54
| | | | | | | | | | | | * scd/ccid-driver.c: Support a test program by ccid-driver. -- Backport from master commit: b31060425226b45deb21915bf5cd8b6ba62bd098 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: ccid-driver: Initial getting ATR more robustly.NIIBE Yutaka2020-10-061-18/+39
| | | | | | | | | | | | | | | * scd/ccid-driver.c (send_power_off): New. (do_close_reader): Use send_power_off. (ccid_get_atr): Add error recovery. -- Backport from master commit of: c51a5685554a06e00ae1e99070b44613b2f8d417 GnuPG-bug-id: 4616 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Clean up the structure for future fix of PC/SC.NIIBE Yutaka2020-10-063-18/+23
| | | | | | | | | | | | | | | | | | * scd/apdu.c (struct dev_list): Rename from ccid_table, with void*. (open_ccid_reader): Follow the change. (apdu_dev_list_start, apdu_dev_list_finish): Likewise. (apdu_open_reader): Likewise. * scd/ccid-driver.c (ccid_dev_scan): Use void *. (ccid_dev_scan_finish, ccid_get_BAI, ccid_open_usb_reader): Likewise. * scd/ccid-driver.h: Change the APIs. -- Backport from master commit of: f44aa290c1368a3119b2323664c0f356195c4206 Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Map some error codes from libusb to ccid-driver error codes.Werner Koch2020-10-065-12/+57
| | | | | | | | | | | | | | | | | | | * scd/ccid-driver.h (CCID_DRIVER_ERR_USB_*): New error codes. * scd/apdu.h: New SW_HOST error codes. * scd/apdu.c (host_sw_string): Print them * scd/ccid-driver.c (map_libusb_error): New. (ccid_open_usb_reader, bulk_in, abort_cmd): Map libusb error codes. * scd/iso7816.c (map_sw): Map new codes to gpg-error. -- Backport from master commit: 9a8d7e41bba1926158a21ebdda542241493ef983 This change will help to get low level error conditions from hipher application code. Signed-off-by: Werner Koch <[email protected]>
* scd: internal driver: Submit SET_INTERFACE control transfer.NIIBE Yutaka2020-10-061-8/+6
| | | | | | | | | | | | | | | | | | | | | | * scd/ccid-driver.c (ccid_open_usb_reader): Alway submit SET_INTERFACE control transfer. -- Backport from master commit: 611faf1579a56925994d53eb08e1290a4b3958cf This handling is not mondatory, but it's better to do so, because there are card reader with pinpad and token with ack button, which support user interaction. User interaction status should be reset at open time. The status should be reset when the session is closed/stopped. In practice, since cleanup routine in a driver may not be called properly, it's good to submit SET_INTERFACE at open time. Signed-off-by: NIIBE Yutaka <[email protected]>
* scd: Internal CCID driver: Spelling cleanup.NIIBE Yutaka2020-10-061-2/+2
| | | | | | | | | -- Signed-off-by: Daniel Kahn Gillmor <[email protected]> Backport master commit of: 0904b8ef348a52335c378bee6dc90a978885d66f
* scd: Internal CCID driver: Clean up backport from master.NIIBE Yutaka2020-10-061-1/+1
| | | | | | | | | | | | | * scd/ccid-driver.c (print_error) [TEST]: Add missing break. Note that this is anyway an impossible case. -- Backport master commit of: 8fb14d3b3f9c5c27ff8b9f0e7e7207ec388687ff Signed-off-by: Werner Koch <[email protected]>
* dirmngr: Minor cleanup for better readability.Werner Koch2020-10-053-29/+29
| | | | | | | | | | * dirmngr/ldap.c (start_default_fetch_ldap): Rename to start_cacert_fetch_ldap and remove arg attr. Instead use "cACertificate" directly. * dirmngr/crlfetch.c (ca_cert_fetch): Change the only caller. (start_cert_fetch_ldap): Rename arg for clarity. Signed-off-by: Werner Koch <[email protected]>
* build: Fix SENDMAIL define for a PATH with spaces.Werner Koch2020-10-041-1/+1
| | | | * configure.ac: Fix use of $PATH
* w32: Add manifest files to most binariesWerner Koch2020-10-0226-31/+512
| | | | | | -- Signed-off-by: Werner Koch <[email protected]>
* common,w32: Change copyright holder notice.Werner Koch2020-10-021-0/+14
| | | | --
* gpgconf,w32: Add manifest so we get the correct windows version.Werner Koch2020-10-026-10/+86
| | | | | | | | | | | | | | * common/w32info-rc.h.in: Update copyright info. * tools/gpg-connect-agent-w32info.rc: Tweak file info. * tools/gpgconf-w32info.rc: New. * tools/gpgconf.w32-manifest.in: New. * configure.ac: Add new .in file. * tools/Makefile.am (EXTRA_DIST): Add them. (gpg_connect_agent_robjs, gpgconf_robjs): New. (gpgconf_LDADD): Add resource file. (gpg_connect_agent_LDADD): Change name of resource macro. Signed-off-by: Werner Koch <[email protected]>
* gpgconf: New option --show-versions.Werner Koch2020-10-022-1/+236
| | | | | | | | | | | | | | | | | | | | * tools/gpgconf.c: Include exechelp.h. New option --show-versions. (get_revision_from_blurb): New. (show_version_gnupg): New. (show_version_libgcrypt): New. (show_version_gpgrt): New. (show_versions_via_dirmngr): New. (show_versions): New. * dirmngr/dirmngr.c (main): New internal option --gpgconf-versions. (get_revision_from_blurb): New. (gpgconf_versions): New. -- This option should be helpful to gather information for debugging. Signed-off-by: Werner Koch <[email protected]> Backported-from-master: 357ad9ae29677c1676b56d2b81282e2f78ec8040
* doc: Typo fixesWerner Koch2020-10-022-2/+2
| | | | --
* doc: Remove enable-extended-key-format in vsnfdAndre Heinecke2020-10-011-1/+0
| | | | | | | | * doc/examples/vsnfd.prf: Remove enable-extended-key-format -- This is no longer a valid option for gpg-agent because it is now the default.
* kbx: Add bounds check to detect corrupt keyboxes.Werner Koch2020-09-221-13/+118
| | | | | | | | | | | | | | | | | | | * kbx/keybox-dump.c (_keybox_dump_blob): Fix the fixmes. Add support for 32 byte fingerprints. -- kbxutil is a debug tool but nevertheless it should behave well and not read beyond allocated buffers and in turn crash. Vincent Ulitzsch and Dominik Maier were kind enough to report these crashes along with a couple of test keyboxes and crash analysis. Signed-off-by: Werner Koch <[email protected]> Backported from master and while doing that adding also the support for OpenPGP v5 keys. Signed-off-by: Werner Koch <[email protected]>
* scd: Fix the use case of verify_chv2 by CHECKPIN.NIIBE Yutaka2020-09-161-16/+20
| | | | | | | | | | | | | * scd/app-openpgp.c (verify_chv2): Call verify_a_chv with chvno=1 when needed. -- Backport of master commit of: 6e51f2044aebb885ea81dae259db1b7f477b1c44 Fixes-commit: d2f1a0a791db3eb03c003365cbcd010bd8066edb Signed-off-by: NIIBE Yutaka <[email protected]>
* gpg-connect-agent: Catch signals so that SIGPIPE is ignored.Werner Koch2020-09-102-1/+2
| | | | | | | | | | | | | * dirmngr/server.c (cmd_killdirmngr): Return 0. * tools/gpg-connect-agent.c (main): Catch signals. -- And we also print nicer diagnostics. The reason we need this is that for example "gpgconf --kill dirmngr" uses gpg-connect-agent to send a command to dirmngr. This may results in a SIGPIPE which in turn leads to an annoying error message from gpgconf. Signed-off-by: Werner Koch <[email protected]>
* dirmngr: Fix the pool keyserver case for a single host in the pool.Werner Koch2020-09-101-1/+20
| | | | | * dirmngr/ks-engine-hkp.c (map_host): Set R_HOSTNAME also for localhost and if there is no pool.
* dirmngr: Align the gnutls use of CAs with the ntbtls code.Werner Koch2020-09-103-10/+18
| | | | | | | | | | | | | | * dirmngr/http.c (http_session_new) <gnutls>: Use only the special pool certificate for the default keyserver. -- The gnutls version uses a different strategy than the ntbtls version on when to use the special SKS pool certificate. This patch aligns it so that we don't need to wonder about different kind of bug reports. In short the special cert is now the only cert use with the default keyserver. Signed-off-by: Werner Koch <[email protected]>
* agent: Keep some permissions of private-keys-v1.d.Werner Koch2020-09-102-27/+55
| | | | | | | | | * common/sysutils.c (modestr_to_mode): Re-implement. (gnupg_chmod): Support keeping of permissions. -- GnuPG-bug-id: 2312 Signed-off-by: Werner Koch <[email protected]>
* build: Fix recent commit for SOURCE_DATE_EPOCH.Werner Koch2020-09-091-2/+2
| | | | | | | | | | | -- Fixes-commit: 5ade2b68db231c78d8ecca0eb21db2153da958d2 which was recently pushed to make use of $SOURCE_DATE_EPOCH as fallback. (cherry picked from commit 61bb75d045a3709d1cba0084c95e991dfd52c8ee) Signed-off-by: Werner Koch <[email protected]>
* tests: New test run envvar to run gpg under valgrind.Werner Koch2020-09-042-1/+14
| | | | | | | | | -- Take care: Running under valgrind takes loooong and in some case you may run into an valgrind internal error. Signed-off-by: Werner Koch <[email protected]>
* gpg: Initialize a parameter to silence valgrind.Werner Koch2020-09-042-2/+3
| | | | | | | | | | | | | * g10/keygen.c (read_parameter_file): Initialize nline. * g10/textfilter.c (copy_clearsig_text): Initialize bufsize. -- In iobuf_read_line the parameter to pass and return the current buffer length is controlled by the buffer parameter. Thus there should be no problem because the assert call check s buffer first. For yet unknown reasons when using the standard GNU libc assert valgrind complains about an uninitialized variable. That does not happen with our log_assert. Tested with gcc 8.3.0 and valgrind 3.14.0.
* Post release updatesWerner Koch2020-09-032-1/+8
| | | | --
* Release 2.2.23gnupg-2.2.23Werner Koch2020-09-031-1/+17
|
* gpg: Fix AEAD preference list overflowWerner Koch2020-09-031-1/+1
| | | | | | | | | | | | | * g10/getkey.c (fixup_uidnode): Increase size of prefs array. -- GnuPG-bug-id: 5050 Fixes-commit: ab7a0b07024c432233e691b5e4be7e32baf8d80f which introduced a feature to show the AEAD preferences of keys created with rfc4880bis capable software (e.g. GnuPG 2.3-beta). The same code in 2.3 is correct, though. Signed-off-by: Werner Koch <[email protected]>
* po: auto updateWerner Koch2020-09-0326-1288/+1513
| | | | --
* po: Update Ukrainian translationYuri Chornoivan2020-09-031-76/+64
| | | | | | | | -- The provided patch did not cleany apply (3 of 31 hunks failed). Signed-off-by: Werner Koch <[email protected]>
* po: Update Polish translationJakub Bogusz2020-09-031-67/+29
| | | | --
* po: Add key-check.c to the list of translatable sources.Werner Koch2020-09-031-0/+1
| | | | --
* po: Update Czech translation.Petr Pisar2020-09-031-63/+41
| | | | | | -- Signed-off-by: Werner Koch <[email protected]>
* gpg: Fix segv importing certain keys.Werner Koch2020-09-021-2/+5
| | | | | | | | | | * g10/key-check.c (key_check_all_keysigs): Initialize issuer. -- Fixes-commit: 404fa8211b6188a0abe83ef43a4b44d528c0b035 from 2017 Signed-off-by: Werner Koch <[email protected]>
* scd: Fix a regression for OpenPGP card.NIIBE Yutaka2020-09-011-0/+5
| | | | | | | | | | | * scd/app-openpgp.c (verify_chv2): Make sure loading keys. -- Fixes-commit: d2f1a0a791db3eb03c003365cbcd010bd8066edb Reported-by: Michał Górny GnuPG-bug-id: 5039 Signed-off-by: NIIBE Yutaka <[email protected]>
* po: Minor update to the Hungarian translation.Nagy Ferenc László2020-08-281-51/+39
| | | | --
* sm: Fix a bug in the rfc2253 parserWerner Koch2020-08-281-1/+1
| | | | | | | | | | | | | * sm/certdump.c (parse_dn_part): Fix parser flaw. -- This could in theory result in reading bytes after a after Nul in a string and thus possible segv on unallocated memory or reading other parts of the memory. However, it is harmless because the rfc2253 strings have been constructed by libksba. GnuPG-bug-id: 5037 Signed-off-by: Werner Koch <[email protected]>
* Post release updatesWerner Koch2020-08-272-1/+4
| | | | --
* Release 2.2.22gnupg-2.2.22Werner Koch2020-08-271-3/+47
|
* doc: Fix typosGavin L. Rebeiro2020-08-272-2/+2
| | | | --