aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Release 1.4.19.gnupg-1.4.19Werner Koch2015-02-275-17/+39
|
* po: Auto-updateWerner Koch2015-02-2729-200/+543
| | | | --
* po: Update German translationWerner Koch2015-02-271-6/+19
|
* po: Update French translationDavid Prévot2015-02-261-72/+70
|
* po: Update Czech translationRoman Pavlik2015-02-261-1488/+1463
|
* po: Update Dutch translationFrans Spiesschaert2015-02-261-1388/+1488
|
* po: Update Spanish translationManuel \"Venturi\" Porras Peralta2015-02-261-1226/+1248
|
* po: Update Polish translationJakub Bogusz2015-02-261-1164/+1140
|
* po: Update Russian translationIneiev2015-02-261-948/+935
|
* po: Update Ukrainian translationYuri Chornoivan2015-02-261-10/+15
|
* po: Update Italian translation.Milo Casagrande2015-02-261-2579/+1699
|
* Update Chinese (traditional) translationJedi Lin2015-02-261-31/+12
|
* Fix for building without DNS support.Werner Koch2015-02-261-2/+2
| | | | * util/cert.c (get_cert) [!USE_DNS_CERT]: Add want_ipgp.
* po,intl: Update to 0.19.3.Werner Koch2015-02-2699-1926/+2720
|
* Switch to a hash and CERT record based PKA system.Werner Koch2015-02-267-224/+226
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * util/pka.c: Rewrite. (get_pka_info): Add arg fprbuflen. Change callers to pass this. * util/strgutil.c (ascii_strlwr): New. * configure.ac: Remove option --disable-dns-pka. (USE_DNS_PKA): Remove ac_define. * g10/getkey.c (parse_auto_key_locate): Always include PKA. -- Note that although PKA is now always build, it will only work if support for looking up via DNS has not been disabled. The new PKA only works with the IPGP DNS certtype and shall be used only to retrieve the fingerprint and optional the key for the first time. Due to the security problems with DNSSEC the former assumption to validate the key using DNSSEC is not anymore justified. Instead an additional layer (e.g. Trust-On-First-Use) needs to be implemented to track change to the key. Having a solid way of getting a key matching a mail address is however a must have. More work needs to go into a redefinition of the --verify-options pka-lookups and pka-trust-increase. The auto-key-locate mechanism should also be able to continue key fetching with another method once the fingerprint has been retrieved with PKA. Signed-off-by: Werner Koch <[email protected]> This is a backport from master. (backported from commit 2fc27c8696f5cf2ddf3212397ea49bff115d617b)
* Move two functions from g10/ to util/.Werner Koch2015-02-263-50/+50
| | | | | | | * g10/misc.c (has_invalid_email_chars, is_valid_mailbox): Move to ... * util/strgutil.c: here. Signed-off-by: Werner Koch <[email protected]>
* Add new function strconcat.Werner Koch2015-02-262-27/+90
| | | | | | | * include/util.h (GNUPG_GCC_A_SENTINEL): New. * util/strgutil.c (do_strconcat, strconcat): New. Signed-off-by: Werner Koch <[email protected]>
* Add convenience function to hash a buffer.Werner Koch2015-02-262-1/+19
| | | | | | * cipher/sha1.c (sha1_hash_buffer): New. Signed-off-by: Werner Koch <[email protected]>
* Allow requesting only an IPGP certtype with dns_cert().Werner Koch2015-02-263-7/+9
| | | | | | * util/cert.c (get_cert): Add arg want_ipgp. Change callers. Signed-off-by: Werner Koch <[email protected]>
* doc: Fix name of keep-ownertrust.Werner Koch2015-02-261-1/+1
| | | | | | -- Reported-by: Guilhem Moulin <[email protected]>
* mpi: Avoid data-dependent timing variations in mpi_powm.NIIBE Yutaka2015-02-263-40/+82
| | | | | | | | | | | | * include/mpi.h, mpi/mpiutils.c (mpi_set_cond): New. * mpi/mpi-pow.c (SIZE_PRECOMP): Rename from SIZE_B_2I3. (mpi_powm): Access all data in the table and use mpi_set_cond. -- Access to the precomputed table was indexed by a portion of EXPO, which could be mounted by a side channel attack. This change fixes this particular data-dependent access pattern.
* doc: Add warning note about not acting as an oracle to --batch.Werner Koch2015-02-231-6/+17
| | | | --
* Protect against NULL return of mpi_get_opaque.Werner Koch2015-02-231-5/+12
| | | | | | | | | | | * g10/seckey-cert.c (do_check): Call BUG for NULL return of get_opaque. -- This is the suggested addition from commit 6f03218. We better run into an fatal error than into a segv. Signed-off-by: Werner Koch <[email protected]>
* gpg: Fix segv due to NULL value stored as opaque MPIDaniel Kahn Gillmor2015-02-232-4/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * g10/build-packet.c (do_secret_key): Check for NULL return from gcry_mpi_get_opaque. * g10/keyid.c (hash_public_key): Ditto. -- This is a backport of 76c8122adfed0f0f443cce7bda702ba2b39661b3 from master to the STABLE-BRANCH-1-4 On the STABLE-BRANCH-1-4, we may also want to patch g10/seckey-cert.c, but that has not been done in this patch. This fix extends commmit 0835d2f44ef62eab51fce6a927908f544e01cf8f. gpg2 --export --no-default-keyring --keyring TESTDATA With TESTDATA being below after unpacking. -----BEGIN PGP ARMORED FILE----- mBMEhdkMmS8BcX8F//8F5voEhQAQmBMEnAAAZwAAo4D/f/8EhQAAAIAEnP8EhQAQ iBMEnP8AAAAABf8jIID///8EhQYQmBMEnIUAEIgTBKT/AAAAAAUAACCA/f//BIUA EJgTBJx/AP8ABPPzBJx/AP8ABPPz =2yE0 -----END PGP ARMORED FILE----- Reported-by: Jodie Cunningham [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Remove an unused variable.Werner Koch2015-02-231-1/+0
| | | | | | | * g10/import.c (import): Remove need_armor. [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* curl-shim: clean up varargsDaniel Kahn Gillmor2015-02-231-0/+2
| | | | | | | | | | | | | | | | | | * keyserver/curl-shim.c (curl_easy_setopt) : ensure that va_end is called. -- stdarg(3) says: Each invocation of va_start() must be matched by a corresponding invocation of va_end() in the same function. Observed by Joshua Rogers <[email protected]> Debian-Bug-Id: #773475 [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Print better diagnostics for keyserver operations.Werner Koch2015-02-235-22/+125
| | | | | | | | | | | | | | | | | | | | | | | | | | * g10/armor.c (parse_key_failed_line): New. (check_input): Watch out for gpgkeys_ error lines. * g10/filter.h (armor_filter_context_t): Add field key_failed_code. * g10/import.c (import): Add arg r_gpgkeys_err. (import_keys_internal): Ditto. (import_keys_stream): Ditto. * g10/keyserver.c (keyserver_errstr): New. (keyserver_spawn): Detect "KEY " lines while sending. Get gpgkeys_err while receiving keys. (keyserver_work): Add kludge for better error messages. -- GnuPG-bug-id: 1832 Note that these changes can be backported to 1.4 but they don't make sense for 2.1 due to the removal of the keyserver helpers. The error reporting could be improved even more but given that this is an old GnuPG branch it is not justified to put too much effort into it. Signed-off-by: Werner Koch <[email protected]> [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* Use inline functions to convert buffer data to scalars.Werner Koch2015-02-2312-106/+148
| | | | | | | | | | | | | | | | | | | * include/host2net.h (buf16_to_ulong, buf16_to_uint): New. (buf16_to_ushort, buf16_to_u16): New. (buf32_to_size_t, buf32_to_ulong, buf32_to_uint, buf32_to_u32): New. -- This fixes sign extension on shift problems. Hanno Böck found a case with an invalid read due to this problem. To fix that almost all uses of "<< 24" and "<< 8" are changed by this patch to use an inline function from host2net.h. (back ported from commit 2183683bd633818dd031b090b5530951de76f392) Signed-off-by: Werner Koch <[email protected]> [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* doc: Change remaining http links to gnupg.org to httpsWerner Koch2015-02-233-4/+4
| | | | | | | | -- GnuPG-bug-id: 1830 [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Prevent an invalid memory read using a garbled keyring.Werner Koch2015-02-231-3/+21
| | | | | | | | | | | | | | | | | | | | | | | * g10/keyring.c (keyring_get_keyblock): Whitelist allowed packet types. -- The keyring DB code did not reject packets which don't belong into a keyring. If for example the keyblock contains a literal data packet it is expected that the processing code stops at the data packet and reads from the input stream which is referenced from the data packets. Obviously the keyring processing code does not and cannot do that. However, when exporting this messes up the IOBUF and leads to an invalid read of sizeof (int). We now skip all packets which are not allowed in a keyring. Reported-by: Hanno Böck <[email protected]> (back ported from commit f0f71a721ccd7ab9e40b8b6b028b59632c0cc648) [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Fix a NULL-deref in export due to invalid packet lengths.Werner Koch2015-02-231-1/+2
| | | | | | | | | | | | | * g10/build-packet.c (write_fake_data): Take care of a NULL stored as opaque MPI. -- Reported-by: Hanno Böck <[email protected]> (back ported from commit 0835d2f44ef62eab51fce6a927908f544e01cf8f) [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Fix a NULL-deref due to empty ring trust packets.Werner Koch2015-02-231-3/+7
| | | | | | | | | | | | | * g10/parse-packet.c (parse_trust): Always allocate a packet. -- Reported-by: Hanno Böck <[email protected]> Signed-off-by: Werner Koch <[email protected]> (back ported from commit 39978487863066e59bb657f5fe4e8baab510da7e) [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Limit the size of key packets to a sensible value.Werner Koch2015-02-231-2/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * g10/parse-packet.c (MAX_KEY_PACKET_LENGTH): New. (MAX_UID_PACKET_LENGTH): New. (MAX_COMMENT_PACKET_LENGTH): New. (MAX_ATTR_PACKET_LENGTH): New. (parse_key): Limit the size of a key packet to 256k. (parse_user_id): Use macro for the packet size limit. (parse_attribute): Ditto. (parse_comment): Ditto. -- Without that it is possible to force gpg to allocate large amounts of memory by using a bad encoded MPI. This would be an too easy DoS. Another way to mitigate would be to change the MPI read function to allocate memory dynamically while reading the MPI. However, that complicates and possibly slows down the code. A too large key packet is in any case a sign for broken data and thus gpg should not use it. Reported-by: Hanno Böck GnuPG-bug-id: 1823 Signed-off-by: Werner Koch <[email protected]> (back ported from commit 382ba4b137b42d5f25a7e256bb7c053ee5ac7b64) [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Allow predefined names as answer to the keygen.algo prompt.Werner Koch2015-02-232-11/+43
| | | | | | | | | | | * g10/keygen.c (ask_algo): Add list of strings. -- Signed-off-by: Werner Koch <[email protected]> (backported from commit b1d5ed6ac842469afcb84868d0f6641dc286a6c7) [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* gpg: Print a warning if the subkey expiration may not be what you want.Werner Koch2015-02-231-0/+58
| | | | | | | | | | | | | | | * g10/keyedit.c (subkey_expire_warning): New. keyedit_menu): Call it when needed. -- GnuPG-bug-id: 1715 The heuristic to detect a problem is not very advanced but it should catch the most common cases. (backported from commit ae3d1bbb65b65cf3c57bb14886be120f5e31635d) [dkg: rebased to STABLE-BRANCH-1-4] Signed-off-by: Daniel Kahn Gillmor <[email protected]>
* Use ciphertext blinding for Elgamal decryption.Werner Koch2015-02-111-14/+49
| | | | | | | | | | | | | | | | | | | * cipher/elgamal.c (USE_BLINDING): New. (decrypt): Rewrite to use ciphertext blinding. -- CVE-id: CVE-2014-3591 As a countermeasure to a new side-channel attacks on sliding windows exponentiation we blind the ciphertext for Elgamal decryption. This is similar to what we are doing with RSA. Unfortunately, the performance impact of Elgamal blinding is quite noticeable: For a 3072 bit Elgamal key the decryption used to take 13ms; with the blinding it takes 24ms. This has been measured using time(1), calling gpg with a 100 byte message, and having gpg modified to run the pubkey_decrypt function 100 times and finally scale the result (using an i5-2410M CPU @ 2.30GHz TP 220).
* Update automake helper files.Werner Koch2015-01-1910-1128/+1565
| | | | --
* Modernize to automake 1.14.Werner Koch2015-01-198-37/+37
| | | | | | | | | | | | * Makefile.am (AUTOMAKE_OPTIONS): Move to ... * configure.ac (AM_INIT_AUTOMAKE): here and add serial-tests. * keyserver/Makefile.am: Replace INCLUDES by AM_CPPFLAGS. * mpi/Makefile.am: Ditto. * util/Makefile.am: Ditto. * keyserver/Makefile.am: Ditto. Adjusted other things. * m4/intl.m4, m4/po.m4: Use autoconf's AC_PROG_MKDIR_P.
* Fix a problem with select and high fds.Werner Koch2015-01-192-15/+22
| | | | | | | | | | | | | | | | | | | | | * cipher/rndlinux.c (rndlinux_gather_random): Check fd before using FD_SET. -- If on systems where the maximum number of fds may be dynamically configured to a value of FD_MAXSIZE or higher and the RNG is first used after more than FD_SETSIZE-1 descriptors are in use, we disable the progress messages from the RNG. A better solution would be too use poll but that requires more tests. The same problem exists in rndunix.c - however this rng is only used on old Unices and I assume that they don't feature dynamically configured maximum fd sizes. (from Libgcrypt commit 9487099071af4478d2882e633a0ade805801d6fa) This may fix GnuPG-bug-id: 1818
* doc: Formatting fixes.Werner Koch2015-01-131-9/+16
| | | | | | | | | | | * doc/gpl.texi: Fix enumerate and re-indent examples. -- Cherry-pick a part of ff6115227a1ced14e2fb3d160a12181b9dfbc502. Reported-by: Ian Abbott Signed-off-by: Werner Koch <[email protected]>
* avoid future chance of using uninitialized memoryDaniel Kahn Gillmor2015-01-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | * util/iobuf.c: (iobuf_open): initialize len -- Cherry-pick 367b073ab5f439ccf0750461d10c69f36998bd62. In iobuf_open, IOBUFCTRL_DESC and IOBUFCTRL_INIT commands are invoked (via file_filter()) on fcx, passing in a pointer to an uninitialized len. With these two commands, file_filter doesn't actually do anything with the value of len, so there's no actual risk of use of uninitialized memory in the code as it stands. However, some static analysis tools might flag this situation with a warning, and initializing the value doesn't hurt anything, so i think this trivial cleanup is warranted. Debian-Bug-Id: 773469
* doc: Fix memory leak in yat2m.Werner Koch2015-01-131-0/+1
| | | | | | | * doc/yat2m.c (write_th): Free NAME. -- Reported-by: Joshua Rogers <[email protected]>
* gpg: Fix possible read of unallocated memoryWerner Koch2015-01-131-4/+7
| | | | | | | | | | | | | | | | | * g10/parse-packet.c (can_handle_critical): Check content length before calling can_handle_critical_notation. -- The problem was found by Jan Bee and gniibe proposed the used fix. Thanks. This bug can't be exploited: Only if the announced length of the notation is 21 or 32 a memcmp against fixed strings using that length would be done. The compared data is followed by the actual signature and thus it is highly likely that not even read of unallocated memory will happen. Nevertheless such a bug needs to be fixed. Signed-off-by: Werner Koch <[email protected]>
* scd: Fix possibly inhibited checkpin of the admin pin.Werner Koch2015-01-091-1/+1
| | | | | | | * scd/app-openpgp.c (do_check_pin): Do not check a byte of a released buffer. Signed-off-by: Werner Koch <[email protected]>
* scd: fix get_public_key for OpenPGPcard v1.0.Joshua Rogers2015-01-081-1/+1
| | | | | | | | | | | * scd/app-openpgp.c (get_public_key): correctly close 'fp' upon use. -- Inside the get_public_key function, 'fp' was opened using popen, but incorrectly closed using fclose. Debian-Bug-Id: 773474
* gpg: release DEK soon after its use.NIIBE Yutaka2014-12-121-1/+1
| | | | | | | | | | | | | * g10/keygen.c (generate_subkeypair): Release DEK soon. -- This fixes the out_of_core error in the test case of adding RSA-4096 subkey to RSA-4096 primary key with configuration: s2k-cipher-algo S10 Debian-bug-id: 772780
* doc: Do not install gnupg.7Werner Koch2014-11-241-1/+4
| | | | | -- GnuPG-bug-id: 1770
* gpg: Fix use of uninit.value in listing sig subpkts.Werner Koch2014-11-241-2/+7
| | | | | | | | | | | | | | | * g10/parse-packet.c (dump_sig_subpkt): Print regex subpacket sanitized. -- We may not use "%s" to print an arbitrary buffer. At least "%.*s" should have been used. However, it is in general preferable to escape control characters while printf user data. Reported-by: Hanno Böck Signed-off-by: Werner Koch <[email protected]> (backported from commit 596ae9f5433ca3b0e01f7acbe06fd2e424c42ae8)
* gpg: Fix off-by-one read in the attribute subpacket parser.Werner Koch2014-11-241-0/+8
| | | | | | | | | | | * g10/parse-packet.c (parse_attribute_subpkts): Check that the attribute packet is large enough for the subpacket type. -- Reported-by: Hanno Böck Signed-off-by: Werner Koch <[email protected]> (backported from commit 0988764397f99db4efef1eabcdb8072d6159af76)
* gpg: Fix a NULL-deref for invalid input data.Werner Koch2014-11-241-2/+8
| | | | | | | | | | | * g10/mainproc.c (proc_encrypted): Take care of canceled passpharse entry. -- GnuPG-bug-id: 1761 Signed-off-by: Werner Koch <[email protected]> (backported from commit 32e85668b82f6fbcb824eea9548970804fb41d9e)