Imported Upstream version 2.2.31
[platform/upstream/gpg2.git] / ChangeLog
1 2021-09-15  Werner Koch  <wk@gnupg.org>
2
3         Release 2.2.31.
4         + commit ecf4c2f611238799a3af6369a64e418a77ab9dd6
5
6
7 2021-09-14  Werner Koch  <wk@gnupg.org>
8
9         scd: Remove context reference counting from pc/sc.
10         + commit 67e1834ad402e86906429ba0e2bf7ebd72de2450
11         * scd/apdu.c (pcsc): Add flag context_valid, remove count.
12         (close_pcsc_reader): Use new flag instead of looking at magic context
13         value.
14         (pcsc_init): Set new flag.
15         (open_pcsc_reader): Use new flag.
16         (apdu_init): Clear new flag.
17
18         * scd/apdu.c: Remove assert.h.  Replace all assert by log_assert.
19
20 2021-09-13  Werner Koch  <wk@gnupg.org>
21
22         common: New envvar GNUPG_EXEC_DEBUG_FLAGS.
23         + commit 117afec018911a3b0187f15c8559f811a72ddb79
24         * common/exechelp-w32.c (gnupg_spawn_process_detached): Silence
25         breakaway messages and turn them again into debug messages.
26
27 2021-09-08  Werner Koch  <wk@gnupg.org>
28
29         scd: Support PC/SC for "getinfo reader_list".
30         + commit f32994b0bf07d62bf596cc8bb6ec3c3a5f133ac4
31         * scd/apdu.c: Include membuf.h.
32         (pcsc): Add reader_list field.
33         (open_pcsc_reader): Fill that field.
34         (apdu_get_reader_list): New.
35         * scd/command.c: Remove header ccid-driver.h.
36         (pretty_assuan_send_data): New.
37         (cmd_getinfo): Print all reader names.
38
39 2021-09-07  Werner Koch  <wk@gnupg.org>
40
41         scd: Fix possible assertion in close_pcsc_reader.
42         + commit 192113552faa98f40cc91fe014ec55861474626c
43         * scd/apdu.c (close_pcsc_reader): Don't ref-count if the context is
44         invalid.
45         (open_pcsc_reader): Compare the context against -1 which is our
46         indicator for an invalid context.
47
48         agent: Fix segv in GET_PASSPHRASE (regression)
49         + commit 4b2cfec2dc2fd524a4fed6c17bb11e6a7baf15f2
50         * agent/command.c (cmd_get_passphrase): Do not deref PI.  PI is always
51         NULL.
52
53 2021-08-27  NIIBE Yutaka  <gniibe@fsij.org>
54
55         common: Fix put_membuf.
56         + commit 7e431e009e479e63f0996a612e12fb9d8b209ab9
57         * common/membuf.c (put_membuf): Allow NULL for the second arg.
58
59         build: Fix removal of AC_TYPE_SIGNAL.
60         + commit 0ca84cbdf0a5a956f4de80f874f8a3b495cfab20
61         * configure.ac: AC_TYPE_SIGNAL is still needed.
62
63         common: Fix get_signal_name for GNU/Linux.
64         + commit d5f9481186eaf2ff28d7ab04fd36f0bbd1c9714d
65         * common/signal.c (get_signal_name): Use sigdescr_np if available.
66         * configure.ac: Check the function.
67
68 2021-08-26  Werner Koch  <wk@gnupg.org>
69
70         Release 2.2.30.
71         + commit d583e750a668f82bdaa1d0f7c4ffc68c35ed4ca6
72
73
74 2021-08-20  Werner Koch  <wk@gnupg.org>
75
76         wkd: Properly unescape the user-id from a key listing.
77         + commit 2b65f4e953806977490b11cb4739c22ab94e0030
78         * tools/wks-util.c (append_to_uidinfo_list): Unescape UID.
79
80         common: New function decode_c_string.
81         + commit 17e2ec488f662059df0fd2d3b777aa51eab5c0cc
82         * common/miscellaneous.c (decode_c_string): New.
83
84         agent: Use the sysconfdir for a pattern file.
85         + commit 5ed8e598faaffa9aec43fc70199ed7f57560c2ba
86         * agent/genkey.c (do_check_passphrase_pattern): Use make_filename.
87
88         agent: Ignore passphrase constraints for a generated passphrase.
89         + commit db5dc7a91af3774cfbce0bc533e0f0b5498402fe
90         * agent/agent.h (PINENTRY_STATUS_PASSWORD_GENERATED): New.
91         (MAX_GENPIN_TRIES): Remove.
92         * agent/call-pinentry.c (struct entry_parm_s):
93         (struct inq_cb_parm_s): Add genpinhash and genpinhas_valid.
94         (is_generated_pin): New.
95         (inq_cb): Suppress constraints checking for a generated passphrase.
96         No more need for several tries to generate the passphrase.
97         (do_getpin): Store a generated passphrase/pin in the status field.
98         (agent_askpin): Suppress constraints checking for a generated
99         passphrase.
100         (agent_get_passphrase): Ditto.
101         * agent/command.c (cmd_get_passphrase): Ditto.
102
103         wkd: Fix client issue with leading or trailing spaces in user-ids.
104         + commit 576e429d41a144ff4f0c00e8722da2f92ae17d9a
105         * common/recsel.c (recsel_parse_expr): Add flag -t.
106         * common/stringhelp.c (strtokenize): Factor code out to
107         do_strtokenize.
108         (strtokenize_nt): New.
109         (do_strtokenize): Add arg trim to support the strtokenize_nt.
110         * common/t-stringhelp.c (test_strtokenize_nt): New test cases.
111
112         * tools/wks-util.c (wks_list_key): Use strtokenize_nt and the recsel
113         flag -t.
114
115         gpg: Return SUCCESS/FAILURE status also for --card-edit/name.
116         + commit 6685696adafba104072303507dedbbd45731d326
117         * g10/card-util.c (change_name): Call write_sc_op_status.
118
119 2021-08-18  Werner Koch  <wk@gnupg.org>
120
121         agent: Improve the GENPIN callback.
122         + commit 2e69ce878f893de0830317f94c51fdce70e1e540
123         * agent/call-pinentry.c (DEFAULT_GENPIN_BYTES): Replace by  ...
124         (DEFAULT_GENPIN_BITS): this and increase to 150.
125         (generate_pin): Make sure that we use at least 128 bits.
126
127         agent: Fix for zero length help string in pinentry hints.
128         + commit 4855888c0a56a50be6085476f5767d0c62722f2d
129         * agent/call-pinentry.c: Remove unused assert.h.
130         (inq_cb): Fix use use of assuan_end_confidential in case of nested
131         use.
132         (do_getpin): Ditto.
133         (setup_formatted_passphrase): Escape the help string.
134         (setup_enforced_constraints): Ignore empty help strings.
135
136         common,w32: Replace log_debug by log_info for InProcessJobs.
137         + commit ec2f1b38980a1b60624a35707ccebb05c5524d2f
138         * common/exechelp-w32.c (gnupg_spawn_process_detached): Use log_info.
139
140 2021-08-17  Werner Koch  <wk@gnupg.org>
141
142         w32: Move socketdir to LOCAL_APPDATA.
143         + commit 4dfa951a0a631d5e0e44ff5fb8fb74adb651190c
144         * common/homedir.c (is_gnupg_default_homedir): Use standard_homedir
145         instead of the constant which makes a difference on Windows.
146         (_gnupg_socketdir_internal) [W32]: Move the directory to LOCAL_APPDATA.
147         (gnupg_cachedir): Remove unsued function.
148
149         * common/sysutils.c (gnupg_rmdir): New.
150         * tools/gpgconf.c (main): s/rmdir/gnupg_rmdir/.
151
152         gpgconf,w32: Print more registry diagnostics with --list-dirs.
153         + commit 013f2e4672b1565002700e307d3bb95d9352c4d5
154         * tools/gpgconf.c (list_dirs): Figure out classes with the key.
155
156         agent: Make QT_QPA_PLATFORMTHEME=qt5ct work for the pient.
157         + commit 455ba49071dea7588c9de11785b3092e45e4560b
158         * agent/call-pinentry.c (atfork_core): Pass DISPLAY.
159
160         agent: New option --check-sym-passphrase-pattern.
161         + commit c6a4a660fdb977713a1e6c0dd4dae97ddffbe376
162         * agent/gpg-agent.c (oCheckSymPassphrasePattern): New.
163         (opts): Add --check-sym-passphrase-pattern.
164         (parse_rereadable_options): Set option.
165         (main): Return option info.
166         * tools/gpgconf-comp.c: Add new option.
167         * agent/agent.h (opt): Add var check_sym_passphrase_pattern.
168         (struct pin_entry_info_s): Add var constraints_flags.
169         (CHECK_CONSTRAINTS_NOT_EMPTY): New to replace a hardwired 1.
170         (CHECK_CONSTRAINTS_NEW_SYMKEY): New.
171         * agent/genkey.c (check_passphrase_pattern): Rename to ...
172         (do_check_passphrase_pattern): this to make code reading
173         easier. Handle the --check-sym-passphrase-pattern option.
174         (check_passphrase_constraints): Replace arg no_empty by a generic
175         flags arg.  Also handle --check-sym-passphrase-pattern here.
176         * agent/command.c (cmd_get_passphrase): In --newsymkey mode pass
177         CHECK_CONSTRAINTS_NEW_SYMKEY flag.
178         * agent/call-pinentry.c (struct entry_parm_s): Add constraints_flags.
179         (struct inq_cb_parm_s): New.
180         (inq_cb): Use new struct for parameter passing.  Pass flags to teh
181         constraints checking.
182         (do_getpin): Pass constraints flag down.
183         (agent_askpin): Take constraints flag from the supplied pinentry
184         struct.
185
186 2021-08-17  Ingo Klöcker  <dev@ingo-kloecker.de>
187
188         agent: Add checkpin inquiry for pinentry.
189         + commit 9832566e4512ab7cb90aa0b7f769792f5c123ed4
190         * agent/call-pinentry.c: Include zb32.
191         (MAX_GENPIN_TRIES): New.
192         (DEFAULT_GENPIN_BYTES): New.
193         (generate_pin): New.
194         (setup_genpin): New.
195         (inq_quality): Rename to ...
196         (inq_cb): this.  Handle checkpin inquiry.
197         (setup_enforced_constraints): New.
198         (agent_get_passphrase): Call sertup_genpin.  Call
199         setup_enforced_constraints if new passphrase is requested.
200
201 2021-08-16  Ingo Klöcker  <dev@ingo-kloecker.de>
202
203         agent: New option --pinentry-formatted-passphrase.
204         + commit 32fbdddf8b4729d9a54a7751c0b5e406a470657f
205         * agent/agent.h (opt): Add field pinentry_formatted_passphrase.
206         * agent/call-pinentry.c (setup_formatted_passphrase): New.
207         (agent_get_passphrase): Pass option to pinentry.
208         * agent/gpg-agent.c (oPinentryFormattedPassphrase): New.
209         (opts): Add option.
210         (parse_rereadable_options): Set option.
211
212         common: Pass XDG_SESSION_TYPE and QT_QPA_PLATFORM envvars to pinentry.
213         + commit 8fff61de9433e9293712a1dd21dfbe12f951eff9
214         * common/session-env.c (stdenvnames): Add XDG_SESSION_TYPE and
215         QT_QPA_PLATFORM.
216
217 2021-08-16  Werner Koch  <wk@gnupg.org>
218
219         tools: Extend gpg-check-pattern.
220         + commit 5ca15e58b241901cc46fd9fad4db3bbb9e321988
221         * tools/gpg-check-pattern.c: Major rewrite.
222
223 2021-07-04  Werner Koch  <wk@gnupg.org>
224
225         Release 2.2.29.
226         + commit 695a879af81e895741109874b9ac0712e1afc994
227
228
229 2021-06-25  Werner Koch  <wk@gnupg.org>
230
231         dirmngr: Change the default keyserver.
232         + commit 47c4e3e00a7ef55f954c14b3c237496e54a853c1
233         * configure.ac (DIRMNGR_DEFAULT_KEYSERVER): Change to
234         keyserver.ubuntu.com.
235
236         * dirmngr/certcache.c (cert_cache_init): Disable default pool cert.
237         * dirmngr/http-ntbtls.c (gnupg_http_tls_verify_cb): Ditto.
238         * dirmngr/http.c (http_session_new): Ditto.
239
240         * dirmngr/server.c (make_keyserver_item): Use a different mapping for
241         the gnupg.net names.
242
243         gpg: Let --fetch-key return an exit code on failure.
244         + commit 5fe4b978875271fb55f1f674ab545bed2b97a7a8
245         * g10/keyserver.c (keyserver_fetch): Return an error code.
246         * g10/gpg.c (main) <aFetchKeys>: Return 1 in case of no data.
247
248 2021-06-23  NIIBE Yutaka  <gniibe@fsij.org>
249
250         scd:ccid: Handle LIBUSB_TRANSFER_OVERFLOW interrupt transfer.
251         + commit b90c55fa66db254da98958de10e1287c39a4322a
252         * scd/ccid-driver.c (intr_cb): Ignore LIBUSB_TRANSFER_OVERFLOW.
253
254         scd:ccid:spr532: Extend abort_cmd for initialization time.
255         + commit 8e941e19b08785e5e709943765548d4f9f9f57a3
256         * scd/ccid-driver.c (abort_cmd): Add INIT argument to support
257         synchronize until success, even ignoring timeout.
258         (bulk_in): Normal use case of abort_cmd.
259         (ccid_vendor_specific_init): Initial use case of abort_cmd.
260
261 2021-06-22  Werner Koch  <wk@gnupg.org>
262
263         tests: Cope with broken Libgcrypt versions.
264         + commit af2fd9f0af25e1f95d9484f7d2125cd9888aa308
265         * common/t-sexputil.c (test_ecc_uncompress): Ignore unknwon curve
266         errors.
267
268         w32: Add fallback in case the Windows console can't cope with Unicode.
269         + commit e94dfa21d2c17b590122d55468f68e8ab72e4193
270         * common/ttyio.c (w32_write_console): Fallback to WriteConsoleA on
271         error.
272
273 2021-06-21  Werner Koch  <wk@gnupg.org>
274
275         dirmngr: Fix regression in KS_GET for mail address pattern.
276         + commit adf7bfba5ddce9faadff959369ba2271cdd36825
277         * dirmngr/ks-engine-hkp.c (ks_hkp_search): Munge mail address pattern.
278         (ks_hkp_get): Allow for mail addresses.
279         -
280
281         Before the keyserver changes in 2.2.28 gpg passed dirmngr a pail
282         address as an exact pattern (e.g. "=foo@example.org").  Since 2.2.28
283         the mail address is detected gpg gpg and we see for example
284         "<foo@example.org>".  This patch fixes this to turn a mail address
285         into an exact match again.
286
287 2021-06-14  NIIBE Yutaka  <gniibe@fsij.org>
288
289         scd: Error code map fix for older Yubikey.
290         + commit 01a413d5235f1bbd00f83fb86d0e183d8f0b1a57
291         * scd/iso7816.c (map_sw): Recognize 6A86.
292
293 2021-06-11  NIIBE Yutaka  <gniibe@fsij.org>
294
295         dirmngir: Fix build with --disable-ldap.
296         + commit c8b2162c0e7eb42b74811b7ed225fa0f56be4083
297         * dirmngr/dirmngr.c (parse_rereadable_options) [USE_LDAP]:
298         Conditionalize.
299
300         dirmngr: Remove use of USE_LDAPWRAPPER.
301         + commit 8ee4c8d1e0d7677d4f8b9538c12b32bb6393c2c5
302         * configure.ac (USE_LDAPWRAPPER): Remove.
303         * dirmngr/Makefile.am: Use USE_LDAP instead of USE_LDAPWRAPPER.
304         * dirmngr/ldap-wrapper-ce.c: Remove.
305         * dirmngr/ldap-wrapper.h, dirmngr/ldap-wrapper.c: Remove
306         USE_LDAPWRAPPER things.
307
308 2021-06-10  Werner Koch  <wk@gnupg.org>
309
310         Release 2.2.28.
311         + commit 9f6076868ecd313e832c112ea79cfcffed3dc342
312
313
314         gpg: Partial fix for Unicode problem in output files.
315         + commit 845711d1420cc01289c15ba49deb03200a5cd102
316         * g10/openfile.c (overwrite_filep): Use gnupg_access.
317
318         scd: Fix serial number detection for Yubikey 5.
319         + commit c2f02797cdefdce5afd8b29bb8e51d4515a70a96
320         * scd/app.c (app_new_register): Handle serial number correctly.
321
322 2021-06-09  Werner Koch  <wk@gnupg.org>
323
324         gpgtar,w32: Fix file size computation.
325         + commit 198b240b195596974e8b61e2b79fb6e8dc78f89a
326         * tools/gpgtar-create.c (fillup_entry_w32): Move parentheses.
327
328         sm: New option --ldapserver as an alias for --keyserver.
329         + commit d6df1bf84969bf5f5781e33bc1c2f6cb2aee0093
330         * sm/gpgsm.c (opts): Add option --ldapserver and make --keyserver an
331         alias.
332
333         dirmngr: Allow to pass no filter args to dirmngr_ldap.
334         + commit f6e45671aa26f3e7abb968a876de7bbdb4fca3f1
335         * dirmngr/dirmngr_ldap.c (main): Handle no args case.
336
337 2021-06-08  Werner Koch  <wk@gnupg.org>
338
339         w32: Change spawn functions to use Unicode version of CreateProcess.
340         + commit 7a98e45e74ec2883c24689964d6119796da0969f
341         * common/exechelp-w32.c (gnupg_spawn_process): Change to use
342         CreateProcessW.
343         (gnupg_spawn_process_fd): Ditto.
344         (gnupg_spawn_process_detached): Ditto.
345         * g10/exec.c (w32_system): Ditto.
346
347 2021-06-08  Andre Heinecke  <aheinecke@gnupg.org>
348
349         common,w32: Breakaway detached childs when in job.
350         + commit f20e9a464487443552b6cbdf918c6448d3cb643f
351         * common/exechelp-w32.c (gnupg_spawn_process_detached): Add
352         CREATE_BREAKAWAY_FROM_JOB creation flag if required.
353
354 2021-06-08  Werner Koch  <wk@gnupg.org>
355
356         w32: Always use Unicode for console input and output.
357         + commit b912f07cdf00043b97fca54e4113fab277726e03
358         * common/init.c (_init_common_subsystems) [W32]: Set the codepage to
359         UTF-8 for input and putput.  Switch gettext to UTF-8.
360         * g10/gpg.c (utf8_strings) [W32]: Make sure this is always set.
361
362         w32: Free memory allocated by new function w32_write_console.
363         + commit ebdb62a98a6e917bafb795b5f50483a95790e739
364         * common/ttyio.c (w32_write_console): Free buffer.
365
366         common,w32: Allow Unicode input and output with the console.
367         + commit 90aadf69f730ff1bd053abcd6cc8bc67518ecf4b
368         * common/ttyio.c (do_get) [W32]: Use ReadConsoleW.
369         (w32_write_console): New.
370         (tty_printf, tty_fprintf) [W32]: Use new function.
371
372         common: Re-indent ttyio.c and remove EMX, RISCOS, and CE support.
373         + commit 521e176a605e6b6229825761906005b05608daf5
374         * common/ttyio.c: Remove cruft like EMX and RISCOS support.  Translate
375         a few strings.  Re-indent.
376
377         common: Rename w32-misc.c to w32-cmdline.c.
378         + commit d7d9a5ba3cbf9cf7e22a8871474032b525825eed
379         * common/w32-misc.c: Rename to ....
380         * common/w32-cmdline.c: this.
381         * common/Makefile.am: Adjust.
382
383         common,w32: Implement globing of command line args.
384         + commit 09f49b4c9aae46c40a189b1270e215bc978dbc3c
385         * common/w32-misc.c [W32]: Include windows.h
386         (struct add_arg_s): New.
387         (add_arg): New.
388         (glob_arg): New.
389         (parse_cmdstring): Add arg argvflags and set it.
390         (w32_parse_commandline): Add arg r_itemsalloced.  Add globing.
391
392         * common/init.c (prepare_w32_commandline): Mark glob created items as
393         leaked.
394
395         * common/t-w32-cmdline.c : Include windows.h
396         (test_all): Add simple glob test for Unix.
397         (main): Add manual test mode for Windows.
398
399         * common/xasprintf.c (xtryreallocarray): New.
400
401         common,w32: Refine the command line parsing for \ in quotes.
402         + commit 4d6807b215e7541fd52caf7e4adc40d77670f99f
403         * common/t-w32-cmdline.c (test_all): Add new test cases.
404         * common/w32-misc.c (strip_one_arg): Add arg endquote.
405         (parse_cmdstring): Take care of backslashes in quotes.
406
407         common: First take on handling Unicode command line args.
408         + commit 90ddd1cf13cd6bb88d5bb8c1846d7297ca8ac81c
409         * common/w32-misc.c: New.
410         * common/t-w32-cmdline.c: New.
411         * common/init.c: Include w32help.h.
412         (prepare_w32_commandline): New.
413         (_init_common_subsystems) [W32]: Call prepare_w32_commandline.
414
415         * common/Makefile.am (common_sources) [W32]: Add w32-misc.c
416         (module_tests): Add t-w32-cmdline
417         (t_w32_cmdline_LDADD): New.
418
419         gpg: Prepare for globing with UTF-8.
420         + commit 1f59c4c8e2cfa2b111f0798212546864668383f9
421         * g10/gpg.c (_dowildcard): Remove.
422         (my_strusage): Enable wildcards using our new system.
423
424         dirmngr: Rewrite the LDAP wrapper tool.
425         + commit 39815c023f0371dea01f7c51469b19c06ad18718
426         * dirmngr/ldap-misc.c: New.
427         * dirmngr/ldap-misc.h: New.
428         * dirmngr/ks-engine-ldap.c: Include ldap-misc.h.
429         (ldap_err_to_gpg_err, ldap_to_gpg_err): Move to ldap-misc.c.
430         * dirmngr/ldap-wrapper.c (ldap_wrapper): Print list of args in debug
431         mode.
432         * dirmngr/server.c (lookup_cert_by_pattern): Handle GPG_ERR_NOT_FOUND
433         the saqme as GPG_ERR_NO_DATA.
434         * dirmngr/ldap.c (run_ldap_wrapper): Add args tls_mode and ntds.
435         Remove arg url.  Adjust for changes in dirmngr_ldap.
436         (url_fetch_ldap): Remove args host and port.  Parse the URL and use
437         these values to call run_ldap_wrapper.
438         (attr_fetch_ldap): Pass tls flags to run_ldap_wrapper.
439         (rfc2254_need_escape, rfc2254_escape): New.
440         (extfilt_need_escape, extfilt_escape): New.
441         (parse_one_pattern): Rename to ...
442         (make_one_filter): this.  Change for new dirmngr_ldap calling
443         convention.  Make issuer DN searching partly work.
444         (escape4url, make_url): Remove.
445         (start_cert_fetch_ldap): Change for new dirmngr_ldap calling
446         convention.
447         * dirmngr/dirmngr_ldap.c: Major rewrite.
448
449         * dirmngr/t-ldap-misc.c: New.
450         * dirmngr/t-support.h (DIM, DIMof): New.
451         * dirmngr/Makefile.am (dirmngr_ldap_SOURCES): Add ldap-misc.c
452         (module_tests) [USE_LDAP]: Add t-ldap-misc.
453         (t_ldap_parse_uri_SOURCES): Ditto.
454         (t_ldap_misc_SOURCES): New.
455
456 2021-06-08  NIIBE Yutaka  <gniibe@fsij.org>
457
458         agent: Appropriate error code for importing key with no passwd.
459         + commit 2f98d8a0f92dc991bff406e159690a111202fcb4
460         * agent/cvt-openpgp.c (convert_from_openpgp_main): Return
461         GPG_ERR_BAD_SECKEY.
462
463 2021-06-04  Werner Koch  <wk@gnupg.org>
464
465         dirmngr: Remove useless code.
466         + commit 8bd5172539e1399b407aa2a9d56fa51b8e040ae3
467         * dirmngr/ks-engine-ldap.c (my_ldap_connect): Remove the
468         password_param thing because we set the password directly without an
469         intermediate var.
470
471 2021-06-02  Werner Koch  <wk@gnupg.org>
472
473         sm: Support AES-GCM decryption.
474         + commit b722fd755c77cbba12478f6de8913c73213d78ee
475         * sm/gpgsm.c (main): Use gpgrt_fcancel on decryption error if gpgrt
476         supports this.
477         * sm/decrypt.c (decrypt_gcm_filter): New.
478         (gpgsm_decrypt): Use this filter if requested.  Check authtag.
479         * common/compliance.c (gnupg_cipher_is_allowed): Allow GCM for gpgsm
480         in consumer (decrypt) de-vs mode.
481
482 2021-05-28  Werner Koch  <wk@gnupg.org>
483
484         gpgconf: Make runtime changes with different homedir work.
485         + commit c8f0b02936c73b6ef3c99a1bea9ae63f74da0768
486         * tools/gpgconf-comp.c (dirmngr_runtime_change): Pass --homedir
487         first.  Remove unused variable.
488
489         dirmngr: Fix default port for our redefinition of ldaps.
490         + commit 8de9d54ac83fa20cb52b847b643311841be4d6dc
491         * dirmngr/server.c (make_keyserver_item): Fix default port for ldaps.
492         Move a tmpstr out of the blocks.
493         * dirmngr/ks-engine-ldap.c (my_ldap_connect): Improve diagnostics.
494
495 2021-05-27  NIIBE Yutaka  <gniibe@fsij.org>
496
497         build: _DARWIN_C_SOURCE should be 1.
498         + commit 40b2890b4349781ddb0330193aed0286b1d23dad
499         * configure.ac (*-apple-darwin*): Set _DARWIN_C_SOURCE 1.
500
501 2021-05-26  Werner Koch  <wk@gnupg.org>
502
503         dirmngr: Use --ldaptimeout for OpenPGP LDAP keyservers.
504         + commit 317d5947b84ae2707e46b89fb0d8318c07174e13
505         * dirmngr/ks-engine-ldap.c (my_ldap_connect): Use LDAP_OPT_TIMEOUT.
506
507         * dirmngr/dirmngr.c (main): Move --ldaptimeout setting to ...
508         (parse_rereadable_options): here.
509
510         dirmngr: New option --ldapserver.
511         + commit ff17aee5d10c8c5ab902253fb4332001c3fc3701
512         * dirmngr/dirmngr.c (opts): Add option --ldapserver.
513         (ldapserver_list_needs_reset): New var.
514         (parse_rereadable_options): Implement option.
515         (main): Ignore dirmngr_ldapservers.conf if no --ldapserver is used.
516
517         * dirmngr/server.c (cmd_ldapserver): Add option --clear and list
518         configured servers if none are given.
519
520         dirmngr: Allow for non-URL specified ldap keyservers.
521         + commit 2b4cddf9086faaf5b35f64a7db97a5ce8804c05b
522         * dirmngr/server.c (cmd_ldapserver): Strip an optional prefix.
523         (make_keyserver_item): Handle non-URL ldap specs.
524         * dirmngr/dirmngr.h (struct ldap_server_s): Add fields starttls,
525         ldap_over_tls, and ntds.
526
527         * dirmngr/ldapserver.c (ldapserver_parse_one): Add for an empty host
528         string.  Improve error messages for the non-file case.  Support flags.
529         * dirmngr/ks-action.c (ks_action_help): Handle non-URL ldap specs.
530         (ks_action_search, ks_action_get, ks_action_put): Ditto.
531         * dirmngr/ks-engine-ldap.c: Include ldapserver.h.
532         (ks_ldap_help): Handle non-URL ldap specs.
533         (my_ldap_connect): Add args r_host and r_use_tls.  Rewrite to support
534         URLs and non-URL specified keyservers.
535         (ks_ldap_get): Adjust for changes in my_ldap_connect.
536         (ks_ldap_search): Ditto.
537         (ks_ldap_put): Ditto.
538
539         gpg,sm: Simplify keyserver spec parsing.
540         + commit 9f586700ec4ceac97fd47cd799878a8847342ffa
541         * common/keyserver.h: Remove.
542         * sm/gpgsm.h (struct keyserver_spec): Remove.
543         (opt): Change keyserver to a strlist_t.
544         * sm/gpgsm.c (keyserver_list_free): Remove.
545         (parse_keyserver_line): Remove.
546         (main): Store keyserver in an strlist.
547         * sm/call-dirmngr.c (prepare_dirmngr): Adjust for the strlist.  Avoid
548         an ambiguity in dirmngr by adding a prefix if needed.
549
550         * g10/options.h (struct keyserver_spec): Move definition from
551         keyserver.h to here.  Remove most fields.
552         * g10/keyserver.c (free_keyserver_spec): Adjust.
553         (cmp_keyserver_spec): Adjust.
554         (parse_keyserver_uri): Simplify.
555         (keyidlist): Remove fakev3 arg which does not make any sense because
556         we don't even support v3 keys.
557
558         dirmngr: Support pseudo URI scheme "opaque".
559         + commit 72124fadafde153f8ac89a70202006d831829d06
560         * dirmngr/http.h (HTTP_PARSE_NO_SCHEME_CHECK): New.
561         * dirmngr/http.c (http_parse_uri): Use this flag.  Change all callers
562         to use the new macro for better readability.
563         (do_parse_uri): Add pseudo scheme "opaque".
564         (uri_query_value): New.
565
566 2021-05-21  NIIBE Yutaka  <gniibe@fsij.org>
567
568         scd: Release memory for RDRNAME.
569         + commit 5be0d075b1ad03a46a6169bf16cd3ee6102e1358
570         * scd/apdu.c (apdu_close_reader): Free RDRNAME field.
571
572 2021-05-20  Jakub Jelen  <jjelen@redhat.com>
573
574         scd: avoid memory leaks.
575         + commit 678e1b20d3531e642fa8871ea56c6c7d5c208fbe
576         * scd/app-p15.c (send_certinfo): free labelbuf
577           (do_sign): goto leave instead of return
578         * scd/command.c (cmd_genkey): goto leave instead of return
579
580         common: Avoid double-free.
581         + commit 4dc4b025d6dd194a96b11ccfd64d763d2c902a91
582         * common/name-value.c (do_nvc_parse): reset to null after ownership
583         change
584
585 2021-05-19  Ineiev  <ineiev@gnu.org>
586
587         po: Update Russian translation.
588         + commit 17b7048732e265450323cc3e01a48c9d492edf0c
589
590
591 2021-05-19  Werner Koch  <wk@gnupg.org>
592
593         dirmngr: For KS_SEARCH return the fingerprint also with LDAP.
594         + commit f0e538619d5079fcd87c31e853e6deb28564a321
595         * dirmngr/ks-engine-ldap.c (extract_keys): Return the fingerprint if
596         available.
597         (ks_ldap_search): Ditto.
598         (extract_keys): Make sure to free the ldap values also in corner
599         cases.
600         (my_ldap_value_free): New.
601         (ks_ldap_get): Ditto.
602         (ks_ldap_search): Ditto.
603         (my_ldap_connect): Ditto.
604
605 2021-05-18  Werner Koch  <wk@gnupg.org>
606
607         gpg: Fix sending an OpenPGP key with umlaut to an LDAP keyserver.
608         + commit 7bf8530e75d05a712d00a333d59b0a8cf663b9cb
609         * g10/call-dirmngr.c (record_output): Rewrite.
610
611 2021-05-18  Ingo Klöcker  <dev@ingo-kloecker.de>
612
613         scd:p15: Fix logic for appending product name to MANUFACTURER.
614         + commit aa6288140481bccc366e87fcdc6781dc82d0af31
615         * scd/app-p15.c (do_getattr): Append product name to MANUFACTURER if
616         manufacturer_id does not already contain a bracket and if we have a
617         product name.
618
619 2021-05-17  Werner Koch  <wk@gnupg.org>
620
621         gpg: Use a more descriptive prompt for symmetric decryption.
622         + commit 03f83bcda5d1f8d8246bcc1afc603b7f74d0626b
623         * g10/keydb.h (GETPASSWORD_FLAG_SYMDECRYPT): New.
624         (passphrase_to_dek_ext): Remove this obsolete prototype.
625         * g10/passphrase.c (passphrase_get): Add arg flags.  Use new flag
626         value.
627         (passphrase_to_dek): Add arg flags and pass it on.
628         * g10/mainproc.c (proc_symkey_enc): Use new flag.
629
630         sm: Ask for the password for password based decryption (pwri)
631         + commit 50ea1b67e8260aaebbeba0c4cd73e21443a74636
632         * sm/decrypt.c (pwri_decrypt): Add arg ctrl.  Ask for passphrase.
633
634         * sm/export.c (export_p12): Mark string as translatable.
635         * sm/import.c (parse_p12): Ditto.
636
637         sm: Support decryption of password based encryption (pwri)
638         + commit 6f31acac767f2ec67729c0491f29061b26fe14b9
639         * sm/decrypt.c (string_from_gcry_buffer): New.
640         (pwri_parse_pbkdf2): New.
641         (pwri_decrypt): New.
642         (prepare_decryption): Support pwri.
643         (gpgsm_decrypt): Test for PWRI.  Move IS_DE_VS flag to DFPARM.
644
645         * common/sexputil.c (cipher_mode_to_string): New.
646
647         dirmngr: LDAP search by a mailbox now ignores revoked keys.
648         + commit b6f8cd7eef4b00a2c6ccaac743382f1dd83bde6a
649         * dirmngr/ks-engine-ldap.c (keyspec_to_ldap_filter): Ignore revoked
650         and disable keys in mail mode.
651
652 2021-05-07  NIIBE Yutaka  <gniibe@fsij.org>
653
654         scd,pcsc: Use a single context.
655         + commit 987b8168602286d06debbbc8d4deebd35f454e29
656         * scd/apdu.c (pcsc): New variable.
657         (struct reader_table_s): Remove pcsc.context from member.
658         (pcsc_get_status, connect_pcsc_card): Use pcsc.context.
659         (close_pcsc_reader): Release pcsc.context here with reference count.
660         (apdu_open_one_reader): Move API loading to ...
661         (pcsc_init): new.
662         (apdu_open_one_reader): Remove.
663         (apdu_open_reader): Call open_pcsc_reader instead of
664         apdu_open_one_reader.
665         (open_pcsc_reader): Call pcsc_init if needed.  Call close_pcsc_reader
666         instead of pcsc_release_context.  Make reader parsing more robust.
667         (apdu_init): Initialize pcsc.count and pcsc.context.
668
669 2021-05-04  Werner Koch  <wk@gnupg.org>
670
671         gpg: Allow ECDH with a smartcard returning just the x-coordinate.
672         + commit b203325ce112c223a5164081cecd14744a01ff69
673         * g10/ecdh.c (pk_ecdh_encrypt_with_shared_point): Factor extraction
674         part out to  ...
675         (extract_secret_x): new.  Allow for x-only coordinate.
676         (pk_ecdh_encrypt_with_shared_point): Change arg shared_mpi
677         to (shared,nshared).  Move param check to the top.  Add extra safety
678         check.
679         (pk_ecdh_decrypt): Adjust for change.
680         * g10/pkglue.c (get_data_from_sexp): New.
681         (pk_encrypt): Use it for "s" and adjusted for changed
682         pk_ecdh_encrypt_with_shared_point.
683         * g10/pubkey-enc.c (get_it): Remove conversion to an MPI and call
684         pk_ecdh_decrypt with the frame buffer.
685
686         scd: Fix possible PC/SC removed card problem.
687         + commit 9d83bfb639680d3bc756fcfe2b7f83b18bed8dff
688         * scd/apdu.c (pcsc_cancel): New.
689         (pcsc_init): Load new function.
690         (connect_pcsc_card): Use it after a removed card error.
691
692         scd: Add string for another PC/SC error code.
693         + commit a475bb725be7e275a06e0625b0088f607f36634c
694         * scd/apdu.c (PCSC_E_NO_READERS_AVAILABLE): New.
695         (pcsc_error_string): Add a description for this.
696         * scd/scdaemon.c (scd_kick_the_loop): Fix diagnostic.
697
698 2021-05-04  Kirill Elagin  <kirelagin@gmail.com>
699
700         scd: Fix unblock PIN by a Reset Code with KDF.
701         + commit 6c4216094ef4771d1d5011b7aee35f241e3bcc4d
702         * scd/app-openpgp.c (do_change_pin): Use correct CHVNO=1 for
703         pin2hash_if_kdf, for user's PIN.
704
705 2021-05-04  Werner Koch  <wk@gnupg.org>
706
707         gpg: Fix mailbox based search via AKL keyserver method.
708         + commit 22fe23f46d3179cb0a68f58bf6f722b89c0c4d9c
709         * g10/keyserver.c (keyserver_import_name): Rename to ...
710         (keyserver_import_mbox): this.  And use mail search mode.
711         * g10/getkey.c (get_pubkey_byname): Change the two callers.
712
713         gpg: Auto import keys specified with --trusted-keys.
714         + commit e7251be84c797ddbc3f0a5212886761666e3aa33
715         * g10/getkey.c (get_pubkey_with_ldap_fallback): New.
716         * g10/trustdb.c (verify_own_keys): Use it.
717
718         (cherry picked from commit 100037ac0f558e8959fc065d4703c85c2962489e)
719
720         gpg: Allow decryption w/o public key but with correct card inserted.
721         + commit e53f6037283e1a4f18b1c5d66d2678888c701cea
722         * agent/command.c (cmd_readkey): Add option --no-data and special
723         handling for $SIGNKEYID and $AUTHKEYID.
724         * g10/call-agent.c (agent_scd_getattr): Create shadow keys for KEY-FPR
725         output.
726         * g10/skclist.c (enum_secret_keys): Automagically get a missing public
727         key for the current card.
728
729         agent: Silence error messages for READKEY --card.
730         + commit aa612d752ebb1851f23184df084aed5314b72e3a
731         * agent/command.c (cmd_readkey): Test for shadow key before creating
732         it.
733
734         (cherry picked from commit 8f2c9cb73538baab7da8107f2cceb2f6fc49642a)
735
736 2021-05-03  Werner Koch  <wk@gnupg.org>
737
738         gpg: Allow fingerprint based lookup with --locate-external-key.
739         + commit 2af217ecd7e4242be2b35bc0085eccaf13cc2027
740         * g10/keyserver.c (keyserver_import_fprint_ntds): New.
741         * g10/getkey.c (get_pubkey_byname): Detect an attempt to search by
742         fingerprint in no_local mode.
743
744         gpg: Lookup a missing public key of the current card via LDAP.
745         + commit b59af0e2a05a3714b0bcbe7e775c6ffacfbc7119
746         * g10/getkey.c (get_seckey_default_or_card): Lookup a missing public
747         key from the current card via LDAP.
748         * g10/call-dirmngr.c: Include keyserver-intetnal.h.
749         (gpg_dirmngr_ks_get): Rename arg quick into flags.  Take care of the
750         new LDAP flag.
751         * g10/keyserver-internal.h (KEYSERVER_IMPORT_FLAG_QUICK): New.
752         Replace the use of the value 1 for the former quick arg.
753         (KEYSERVER_IMPORT_FLAG_LDAP): New.
754         * g10/keyserver.c (keyserver_get_chunk): Increase the reserved line
755         length.
756         * dirmngr/ks-action.c (ks_action_get): Add arg ldap_only.
757         * dirmngr/server.c (cmd_ks_get): Add option --ldap.
758
759         scd: Add option --info to emit KEYPAIRINFO by readkey command.
760         + commit b8df8321e1ef38147f42af1166d2c60805f88b9c
761         * scd/command.c (do_readkey): Implement this.
762         * scd/app-help.c (app_help_get_keygrip_string_pk): Make HEXKEYGRIP
763         parm optional.  Add arg R_ALGOSTR.
764
765 2021-05-03  NIIBE Yutaka  <gniibe@fsij.org>
766
767         common: Fix gnupg_wait_processes, by skipping invalid PID.
768         + commit c2ba6bea4ce81a066765c285c4b7c1dc6d39f144
769         * common/exechelp-posix.c (gnupg_wait_processes): Skip invalid PID.
770
771 2021-05-03  Werner Koch  <wk@gnupg.org>
772
773         agent: Skip unknown unknown ssh curves seen on cards.
774         + commit bbf4bd3bfcb51e9d91e08ceefba3ff016bae50ff
775         * agent/command-ssh.c (ssh_handler_request_identities): Skip unknown
776         curves.
777
778 2021-04-29  Werner Koch  <wk@gnupg.org>
779
780         gpgconf: Do not i18n an empty string to the PO files meta data.
781         + commit a456303ae306fbfda0cf89ff41678d50c24bf6fc
782         * tools/gpgconf-comp.c (my_dgettext): Ignore empty strings.
783
784         scd: New option --pcsc-shared.
785         + commit 5eec40f3d82777b4fb807a9bf1b71422a8caa2f9
786         * scd/scdaemon.h (opt): Add field opcsc_shared.
787         * scd/scdaemon.c (opcscShared): New.
788         (opts): Add "--pcsc-shared".
789         (main): Set flag.
790         * scd/apdu.c (connect_pcsc_card): Use it.
791         (pcsc_get_status): Take flag in account.
792         * scd/app-openpgp.c (verify_chv2): Do not auto verify chv1 in shared
793         mode.
794
795         scd: Rewrite READKEY to allow for compressed points.
796         + commit 96577e2e46e4c5b66a2685cb605e07be0a6a09a5
797         * scd/app-help.c (app_help_pubkey_from_cert): New.  Taken from 2.3.
798         * scd/command.c (cmd_readkey): Rewrite using new helper.
799
800         common: Extend the openpgp_curve_to_oid function.
801         + commit 5b8593135fa6e88ecc459444ec19b9a824f12a15
802         * common/openpgp-oid.c (openpgp_curve_to_oid): Add optional arg R_NBITS.
803         Change all callers.
804
805         common: New module to compute openpgp fingerprints.
806         + commit f3c98b8cb5adcac17043fa6066b73bd08c8ef41a
807         * common/openpgp-fpr.c: New.
808         * common/Makefile.am (common_sources): Add it.
809
810         common: New function to uncompress an ECC public key.
811         + commit c825117c5fa562fced0d3cafc22fd878cf615b42
812         * common/sexputil.c (ec2os): New.
813         (uncompress_ecc_q_in_canon_sexp): New.
814
815         * common/t-sexputil.c (fail2): new.
816         (test_ecc_uncompress): New.
817         (main): Run new test.
818
819         common: New function cmp_canon_sexp.
820         + commit 473e649ea1a69e82b7f99a17fbff4d641936c61c
821         * common/sexputil.c (cmp_canon_sexp): New.
822         (cmp_canon_sexp_def_tcmp): New.
823         * common/t-sexputil.c (test_cmp_canon_sexp): Add a simple test.
824
825         scd: New function send_keyinfo to assist in backporting.
826         + commit 0eed0ced9bcd3c14621076d26cf4d9f809e1873c
827         * scd/command.c (send_keyinfo): New.
828
829         scd: Minor changes to assist in backporting from 2.3.
830         + commit 3db99b8861a7544efee13be45d14bbac63c0c868
831         * scd/command.c (send_status_direct): Return an error code.
832         * scd/app-common.h (APP_LEARN_FLAG_REREAD): New.
833
834         scd: Extend an internal function to also return the algo.
835         + commit 72a7d45a230bf28e2ba7e8a57b702c98998ea0a3
836         * scd/app-help.c (app_help_get_keygrip_string_pk): Add optional arg
837         r_algo.  Change all callers.
838         (app_help_get_keygrip_string): Ditto.
839
840         scd: New function for iso7816 PSO_CSV.
841         + commit 91dd74f3d7e3630bb7f298fe4d392f8a6cef9acb
842         * scd/iso7816.c (iso7816_pso_csv): New.
843
844         scd: Extend iso7816_select_path.
845         + commit 855d14d390e8dd8464f2f38187dbccb19a13e815
846         * scd/iso7816.c (iso7816_select_path): Add arg top_fd.
847         * scd/app-nks.c (do_readkey): Adjust for this change
848         (select_ef_by_path: Ditto.
849
850         * common/tlv.h: Include membuf.h.
851
852         scd: Add new status codes.
853         + commit 3ce69d8387925d444d529ce0bb5beed9e880aad7
854         * scd/apdu.h (SW_SM_NOT_SUP, SW_CC_NOT_SUP, SW_FILE_STRUCT)
855         (SW_NO_CURRENT_EF): New.
856         * scd/apdu.c (apdu_strerror): Map them to strings.
857         * scd/iso7816.c (map_sw): ... and to gpg-error.
858
859         scd: Extend ISO binary and record reading functions.
860         + commit ec9e8e0d6a1fe47dbf42652c4246e1c34fdf0288
861         * scd/iso7816.c (iso7816_read_binary_ext): Add optional arg r_sw and
862         change callers.
863         (iso7816_read_record): Factor all code out to ...
864         (iso7816_read_record_ext): New.
865
866 2021-04-13  Werner Koch  <wk@gnupg.org>
867
868         gpg: Do not use self-sigs-only for LDAP keyserver imports.
869         + commit 1303b0ed84da57b48d88343ab43f83546e508aba
870         * dirmngr/ks-engine-ldap.c (ks_ldap_get): Print a SOURCE status.
871         * g10/options.h (opts): New field expl_import_self_sigs_only.
872         * g10/import.c (parse_import_options): Set it.
873         * g10/keyserver.c (keyserver_get_chunk): Add special options for LDAP.
874
875 2021-04-08  NIIBE Yutaka  <gniibe@fsij.org>
876
877         scd: Fix CCID driver for SCM SPR332/SPR532.
878         + commit f8ae51977ce4079d638d1ae2f3dd1da41c02a6d7
879         * scd/ccid-driver.c (ccid_vendor_specific_pinpad_setup): New.
880         (ccid_vendor_specific_setup): Only send CLEAR_HALT.
881         (ccid_transceive_secure): Each time, use send_escape_cmd.
882
883 2021-04-06  Werner Koch  <wk@gnupg.org>
884
885         gpg: Fix new pseudo option compliance_de_vs.
886         + commit 18551c6dc2c33f856d05053b27a1210c4c607cef
887         * g10/gpg.c (gpgconf_list): Take opt.compliance also in account.
888
889 2021-04-01  Werner Koch  <wk@gnupg.org>
890
891         common: Make the compliance check more robust.
892         + commit 8ef0f53cb0014026d0d58b8de2133310d96bc1e3
893         * common/compliance.c (get_compliance_cache): New.
894         (gnupg_rng_is_compliant): Use per mode cache.
895         (gnupg_gcrypt_is_compliant): Ditto.
896
897         gpgconf: Return a new pseudo option compliance_de_vs.
898         + commit 9feffc03f36499162342609897484b4b32fd53a7
899         * tools/gpgconf-comp.c (gc_options_gpg): Add "compliance_de_vs".
900         * g10/gpg.c (gpgconf_list): Return that pseudo option.
901
902 2021-03-26  Werner Koch  <wk@gnupg.org>
903             cbiedl@gnupg.com
904
905         gpgconf: Fix argv overflow if --homedir is used.
906         + commit a50093893cd100c74a32cbacc749aab582154625
907         * tools/gpgconf-comp.c (gc_component_launch): Fix crash due to too
908         small array.
909
910 2021-03-11  Werner Koch  <wk@gnupg.org>
911
912         gpg: New option --force-sign-key.
913         + commit 87d7b7e07565bdba9e9e8b8698f7094046d4f762
914         * g10/gpg.c (oForceSignKey,opts): New option "--force-sign-key".
915         (main): Set it.
916         * g10/options.h (opt): New flag flags.force_sign_key.
917         * g10/keyedit.c (sign_uids): Use new flag.
918
919 2021-03-02  Werner Koch  <wk@gnupg.org>
920
921         sm: Do away with the locked flag in keydb.c.
922         + commit f3e68e39da7609f594572833528a0f2b9c20bf2d
923         * sm/keydb.c (struct keydb_handle): Remove field locked.
924         (keydb_lock): Remove use of locked flag.
925         (lock_all): Ditto.
926         (unlock_all): Ditto.
927         (keydb_set_flags): Use dotlock_is_locked instead of the locked flag.
928         (keydb_insert_cert): Ditto.
929         (keydb_delete): Ditto.
930         (keydb_search): s/keydb_lock/lock_all/.
931         (keydb_set_cert_flags): Ditto.
932         (keydb_clear_some_cert_flags): Ditto.
933
934         * sm/keydb.c (maybe_create_keybox): s/access/gnupg_access/.
935
936         common: New function dotlock_is_locked.
937         + commit 67b82a9c607e1488972a85a30015f48c68245af0
938         * common/dotlock.c (dotlock_is_locked): New.
939         (dotlock_take): Set locked flag also in disabled mode.  No more
940         warning if the lock has already been taken.
941         (dotlock_release): Clear locked flag also in disabled mode.  No more
942         warning if the lock has not been taken.
943
944         sm: Lock kbx files also before a search.
945         + commit 677245ba0e7d6c0bc85ac998f47e3f220b736840
946         * sm/keydb.c (keydb_search): Lock files.
947
948         sm: On Windows close the kbx files at several places.
949         + commit 2b9ae79ad81a0d3eff011fabe6629e371cd7c5b4
950         * kbx/keybox-search.c (keybox_search_reset) [W32]: Always close.
951
952         * kbx/keybox-init.c (keybox_close_all_files): New.
953         * sm/keydb.c (keydb_close_all_files): New.
954         * sm/call-dirmngr.c (gpgsm_dirmngr_isvalid): Call new function.
955         (gpgsm_dirmngr_lookup): Ditto.
956         (gpgsm_dirmngr_run_command): Ditto.
957
958         sm: Remove unused function.
959         + commit c99f3599d80d351dda1400314b43ea8ccdcc7b7d
960         * sm/keydb.c (keydb_insert_cert): Remove.
961         * kbx/keybox-update.c (keybox_update_cert): Remove stub.
962
963 2021-03-01  Nicolas Fella via Gnupg-devel  <gnupg-devel@gnupg.org>
964
965         gpg: Keep temp files when opening images via xdg-open.
966         + commit 0441ed6e1c1d7eac81bfbec6ce51f319d9d20eb7
967         * g10/photoid.c (get_default_photo_command): Change parameter for
968         xdg-open.
969
970 2021-03-01  Werner Koch  <wk@gnupg.org>
971
972         sm: Silence some other pkcs#12 import prattle.
973         + commit e5af401fc4c3294de9a4f10630b200185329230b
974         * sm/minip12.c (parse_bag_data): Print a regular log_info only in
975         verbose mode.
976
977 2021-02-24  Werner Koch  <wk@gnupg.org>
978
979         sm: Silence some output on --quiet.
980         + commit bcdbf0fcf3c1c210504cbed53f524704747deaaa
981         * sm/encrypt.c (gpgsm_encrypt): Take care of --quiet.
982         * sm/gpgsm.c: Include minip12.h.
983         (set_debug): Call p12_set_verbosity.
984         * sm/import.c (parse_p12): Dump keygrip only in debug mode.
985         * sm/minip12.c (opt_verbose, p12_set_verbosity): New.
986         (parse_bag_encrypted_data): Print info messages only in verbose mode.
987
988 2021-02-19  Werner Koch  <wk@gnupg.org>
989
990         scd: Change parameters of readkey fucntion pointer.
991         + commit 41979ed7308ef3ab1c877d3f110ce9b61eb17bec
992         * scd/app-common.h (APP_READKEY_FLAG_ADVANCED): New.
993         (struct app_ctx_s): Replace param advanced by flags in readkey.
994         Change all users.
995
996         scd: Pass ctrl parameter to more app functions.
997         + commit 669786cf646d8636de85a3cb8b3aa83ba709d207
998         * scd/app-common.h (struct app_ctx_s): Add parameter ctrl to function
999         pointers for readkey, setattr, sign, auth, decipher, and check_pin.
1000
1001         scd: Detect Yubikey and provide nicer display-s/n.
1002         + commit f8588369bcb0e66118725793b53e871ce2acb10d
1003         * scd/app-common.h (struct app_ctx_s): Rename unused field
1004         card_version to cardversion.
1005         * scd/app.c (app_new_register): Add code rom 2.3 to detect the Yubikey
1006         and set cardversion.
1007         (app_get_dispserialno): New.
1008         * scd/app-openpgp.c (do_getattr): Use app_get_dispserialno.
1009
1010         scd: Change the apptype from a string to an enum.
1011         + commit 43b3ec5aee40172890c077485e438d2d4994d81d
1012         * scd/app-common.h (cardtype_t): New.
1013         (apptype_t): New.
1014         (struct app_ctx_s): Change type of field apptype.  Add fields
1015         appversion and cardtype.  Adjust all app-*.c for the new type.
1016         * scd/app.c (supported_app_list): New.
1017         (strapptype): New.
1018         (apptype_from_name): New.
1019         (app_dump_state): Use strapptype.
1020         (app_write_learn_status): Ditto.
1021         (app_getattr): Ditto.
1022         (check_conflict): Use apptype_from_name and integer comparison.
1023         * scd/app-openpgp.c: Replace app->card_version by app->appversion.
1024
1025         scd: Add some compatibility code for easier backporting.
1026         + commit 6380126b31aacb2e8ad3aae4866d4d384186bf97
1027         * scd/app-common.h (APP_WRITEKEY_FLAG_FORCE): New.
1028         (APP_READKEY_FLAG_INFO): New.
1029         (APP_LEARN_FLAG_KEYPAIRINFO): New.
1030         (APP_LEARN_FLAG_MULTI): New.
1031         (struct app_ctx_s): New forward declaration.
1032         (struct app_ctx_s): Add members prep_reselect, reselect, and
1033         with_keygrip.
1034         (KEYGRIP_ACTION_SEND_DATA): New.
1035         (KEYGRIP_ACTION_WRITE_STATUS): New.
1036         (KEYGRIP_ACTION_LOOKUP): New.
1037         (APP_CARD): New macro.
1038         * scd/scdaemon.h: Include app-common.h and remove from all other
1039         files.
1040         (app_t): Move typedef to ...
1041         * scd/app-common.h: here.
1042
1043 2021-02-17  Werner Koch  <wk@gnupg.org>
1044
1045         dirmngr: Support new gpgNtds parameter in LDAP keyserver URLs.
1046         + commit 55f46b33df08e8e0ea520ade5f73b321bc01d705
1047         * dirmngr/ldap-parse-uri.c (ldap_parse_uri): Support a new gpgNtds
1048         extension.
1049         * dirmngr/ks-engine-ldap.c (my_ldap_connect): Do ldap_init always with
1050         hostname - which is NULL and thus the same if not given.  Fix minor
1051         error in error code handling.
1052
1053         dirmngr: Rewrite a weird function by straighter code.
1054         + commit cdc828f6902667196eb3870f9287045afe7144d5
1055         * dirmngr/ldap-parse-uri.c (ldap_uri_p): Use ascii-memcasecmp.
1056
1057 2021-01-28  Werner Koch  <wk@gnupg.org>
1058
1059         Include the library version in the compliance checks.
1060         + commit 6e258babe7ccc52a7fb621339c2e2fc5f0f23bc9
1061         * common/compliance.c (gnupg_gcrypt_is_compliant): New.
1062         (gnupg_rng_is_compliant): Also check library version.
1063         * g10/mainproc.c (proc_encrypted): Use new function.
1064         (check_sig_and_print): Ditto.
1065         * sm/decrypt.c (gpgsm_decrypt): Ditto.
1066         * sm/encrypt.c (gpgsm_encrypt): Ditto.
1067         * sm/verify.c (gpgsm_verify): Ditto
1068
1069 2021-01-27  Werner Koch  <wk@gnupg.org>
1070
1071         gpg: Fix ugly error message for an unknown symkey algorithm.
1072         + commit 9037be5f40da409a7734a2672e64345472f294fc
1073         * g10/mainproc.c (proc_symkey_enc): Do not continue with an unknown
1074         algorithm.
1075
1076 2021-01-11  Werner Koch  <wk@gnupg.org>
1077
1078         Release 2.2.27.
1079         + commit 0c103cde00098bdf1cec8f27e764300d192210e4
1080
1081
1082         gpg,w32: Fix gnupg_remove.
1083         + commit 3901c1a8c59a436ea4509d5aaebbecc5a0268391
1084         * common/sysutils.c (map_w32_to_errno): New.
1085         (gnupg_w32_set_errno): New.
1086         (gnupg_remove) [w32]: Set ERRNO
1087
1088 2021-01-08  Werner Koch  <wk@gnupg.org>
1089
1090         gpg: Fix --gpgconf-list case with no conf files at all.
1091         + commit 9f37d3e6f307a9460c0a356afa1f8b991c527d6c
1092         * g10/gpg.c (get_default_configname): Remove unused function.
1093         (main): Provide a proper filename to gpgconf_list.
1094
1095 2021-01-07  Werner Koch  <wk@gnupg.org>
1096
1097         gpgconf: Fix description of two new options.
1098         + commit ff30fcd3dc78c00ed87ce6bd3414b828bdf51e84
1099         * tools/gpgconf-comp.c: Fix auto-key-import and include-key-block.
1100
1101 2020-12-30  Werner Koch  <wk@gnupg.org>
1102
1103         wkd: Minor permission fix for created files.
1104         + commit fdc54850263b2b888398f95be7816134b45a60d3
1105         * tools/wks-util.c (wks_cmd_install_key): Don't set u+x on the file.
1106         (ensure_policy_file): No need to make the policy file group writable.
1107
1108 2020-12-23  Werner Koch  <wk@gnupg.org>
1109
1110         gpg: Initialize a variable even in a never used code path.
1111         + commit 83e875a2d1e7560b9626266373c89e6e6eb7cb50
1112         * g10/sign.c (write_signature_packets): Init ERR.
1113
1114 2020-12-21  Werner Koch  <wk@gnupg.org>
1115
1116         Release 2.2.26.
1117         + commit c77bb1a750f0e2d6538d23fdc0af0e3ff3d56781
1118
1119
1120         common: Remove superfluous debug output from dotlock.c.
1121         + commit 323a69ef65e0d48fb9d038ecca01a70688ad3325
1122         * common/dotlock.c (dotlock_create_unix): Remove debug output.
1123
1124         doc: Explain LDAP keyserver parameters.
1125         + commit 261fb98c6f034f3f96abee79ea73febd115420ae
1126
1127
1128         common: Fix the "ignore" meta command in argparse.c.
1129         + commit 09dc59f6d43f5e81781429913b8f377581825be0
1130         * src/argparse.c (gnupg_argparse): Factor some code out to ...
1131         (prepare_arg_return): new.
1132         (gnupg_argparse): No missing arg error in ignore sections.
1133         * common/sysutils.c: Include pwd.h.
1134         (gnupg_getusername): New.
1135
1136 2020-12-18  Werner Koch  <wk@gnupg.org>
1137
1138         gpg: Fix --trusted-key with fingerprint arg.
1139         + commit 8a2e5025eb0f9537a4e776cf2886771a507121f1
1140         * g10/trustdb.c (tdb_register_trusted_key): Take care of that
1141         other constant.
1142
1143         dirmngr: Do not block threads in LDAP keyserver calls.
1144         + commit 15bfd189c07ef0f1bb94db0aee9ad26441ddc494
1145         * dirmngr/ks-engine-ldap.c: Wrap some ldap calls.
1146
1147         dirmngr: Fix backport of the new option parser from 2.3.
1148         + commit 9b886adba4f83ca462f8015060bcea8a7ceb6bb0
1149         * dirmngr/dirmngr.c (main) <aGPGConfList>: Re-introduce
1150         gpgconf-dirmngr.conf.
1151
1152 2020-12-17  Werner Koch  <wk@gnupg.org>
1153
1154         gpg: New AKL method "ntds"
1155         + commit 559efd23e936536435a42646b62fe8c4f8585d38
1156         * dirmngr/ks-engine-ldap.c (keyspec_to_ldap_filter): Change the new
1157         support for KEYDB_SEARCH_MODE_MAIL.
1158         (ks_ldap_get): Add a debug.
1159         * g10/options.h (AKL_NTDS): New.
1160         * g10/keyserver.c (keyserver_import_ntds): New.
1161         (keyserver_get_chunk): Allow KEYDB_SEARCH_MODE_MAIL.
1162         * g10/getkey.c (parse_auto_key_locate): Support "ntds".
1163         (get_pubkey_byname): Ditto.
1164
1165         dirmngr: Support "ldap:///" for the current AD user.
1166         + commit 776bef74c778c6740a6aac8a05801a958868346d
1167         * dirmngr/http.h (struct parsed_uri_s): Add field ad_current.
1168         * dirmngr/ldap-parse-uri.c (ldap_parse_uri): Set it.
1169         * dirmngr/ks-engine-ldap.c (my_ldap_connect): Take care of ad_current.
1170
1171         dirmngr: Allow LDAP searches via fingerprint.
1172         + commit c75fd75532905a2922288e0e8ac01fcd0226fc52
1173         * dirmngr/ks-engine-ldap.c (keyspec_to_ldap_filter): Add arg
1174         serverinfo and allow searching by fingerprint.
1175         (ks_ldap_get, ks_ldap_search): First connect then create teh filter.
1176
1177         dirmngr: Store all version 2 schema attributes.
1178         + commit c28cb5282b149f1e34df6f923e88e1998a60cc4a
1179         * g10/call-dirmngr.c (ks_put_inq_cb): Emit "fpr" records.
1180         * dirmngr/ks-engine-ldap.c (extract_attributes): Add args
1181         extract-state and schemav2.  Add data for the new schema version.
1182         remove the legacy code to handle UIDs in the "pub" line.
1183         (ks_ldap_put): Set new attributes for NTDS use the fingerprint as CN.
1184
1185
1186         This is a backport from 2.3
1187
1188         dirmngr: Support the new Active Directory schema.
1189         + commit ac8ece92662d83b79b03a369df07362d320fd118
1190         * dirmngr/ks-engine-ldap.c (SERVERINFO_): New constants.
1191         (my_ldap_connect): Relace args pgpkeyattrp and real_ldapp by a new
1192         serverinfo arg.  Set the new info flags.
1193         (ks_ldap_get): Adjust for change.
1194         (ks_ldap_search): Ditto.
1195         (ks_ldap_put): Ditto.  Replace xmalloc by xtrymalloc.  Change the DN
1196         for use with NTDS (aka Active Directory).
1197
1198         dirmngr: Do not store the useless pgpSignerID in the LDAP.
1199         + commit 0e88c73bc94fbca224f06d95bb024030bb3a73bb
1200         * dirmngr/ks-engine-ldap.c (extract_attributes): Do not store the
1201         pgpSignerID.
1202         * g10/call-dirmngr.c (ks_put_inq_cb): Do not emit sig records.
1203
1204         dirmngr: Fix adding keys to an LDAP server.
1205         + commit e47de853820000ddf383e7b790fbc435e3378d66
1206         * dirmngr/ks-engine-ldap.c (ks_ldap_put): Extract attribites into
1207         addlist.
1208
1209 2020-12-16  NIIBE Yutaka  <gniibe@fsij.org>
1210
1211         scd:ccid: Call libusb_clear_halt in ccid_vendor_specific_setup.
1212         + commit 3c55e15cee4bfed6ef96fbc97a0d2f00afceebe3
1213         * scd/ccid-driver.c (ccid_vendor_specific_setup): Only for SPR532,
1214         call libusb_clear_halt.
1215
1216         scd:ccid: Revert the addition of libusb_clear_halt for EP_INTR.
1217         + commit 585cfca0a60bd910012a8a2218f74889840b2546
1218         * scd/ccid-driver.c (ccid_setup_intr): Don't call libusb_clear_halt.
1219
1220 2020-12-07  NIIBE Yutaka  <gniibe@fsij.org>
1221
1222         scd:openpgp: Fix writing ECC key to card.
1223         + commit 5a03bf61304d0c2c8b4df53a1a7680cd0eb91cb1
1224         * scd/app-openpgp.c (build_privkey_template): Adding another argument
1225         of ecc_d_fixed_len to handle variable-size MPI.
1226
1227 2020-12-04  Werner Koch  <wk@gnupg.org>
1228
1229         Backport of the new option parser from 2.3.
1230         + commit a028f24136a062f55408a5fec84c6d31201b2143
1231         * configure.ac (GPGRT_ENABLE_ARGPARSE_MACROS): Define.
1232         * common/argparse.c, common/argparse.h: Rewrite.
1233         * tests/gpgscm/main.c: Switch to the new option parser.
1234
1235         * g10/gpg.c: Switch to the new option parser and enable a global conf
1236         file.
1237         * g10/gpgv.c: Ditto.
1238         * agent/gpg-agent.c: Ditto.
1239         * agent/preset-passphrase.c: Ditto.
1240         * agent/protect-tool.c: Ditto.
1241         * scd/scdaemon.c: Ditto.
1242         * dirmngr/dirmngr.c: Ditto.
1243         * dirmngr/dirmngr_ldap.c: Ditto
1244         * dirmngr/dirmngr-client.c: Ditto.
1245         * kbx/kbxutil.c: Ditto.
1246         * tools/gpg-card.c: Ditto.
1247         * tools/gpg-check-pattern.c: Ditto.
1248         * tools/gpg-connect-agent.c: Ditto.
1249         * tools/gpg-pair-tool.c: Ditto.
1250         * tools/gpg-wks-client.c: Ditto.
1251         * tools/gpg-wks-server.c: Ditto.
1252         * tools/gpgconf.c: Ditto.
1253         * tools/gpgsplit.c: Ditto.
1254         * tools/gpgtar.c: Ditto.
1255         * g13/g13.c: Ditto.
1256         * g13/g13-syshelp.c: Ditto.  Do not force verbose mode.
1257         * sm/gpgsm.c: Ditto. Add option --no-options.
1258
1259 2020-12-02  Werner Koch  <wk@gnupg.org>
1260
1261         kbx: Better error message in case of a crippled Libgcrypt.
1262         + commit acafa695e1e7998b892a6a621ef06d57bbc82722
1263         * kbx/keybox-openpgp.c (keygrip_from_keyparm): Detect missing curve.
1264
1265 2020-12-01  Jens Meißner  <meissner@b1-systems.de>
1266
1267         doc: Add parameters for batch generation of ECC keys.
1268         + commit a3f95a29b97d603c606936620e4638cc6db10ec9
1269         * doc/gpg.texi: Add parameters for batch generation of ECC keys.
1270
1271 2020-11-27  NIIBE Yutaka  <gniibe@fsij.org>
1272
1273         common: Fix fallback handling to utf-8.
1274         + commit 7d7a50ba7231bd4432b1254c7067a7f287890632
1275         * common/utf8conv.c (handle_iconv_error): Set NO_TRANSLATION.
1276
1277 2020-11-23  Werner Koch  <wk@gnupg.org>
1278
1279         Release 2.2.25.
1280         + commit 40f75823d25548abbc52dd6121963a55d99b1230
1281
1282
1283 2020-11-19  Werner Koch  <wk@gnupg.org>
1284
1285         gpgconf: Also print revision of libksba.
1286         + commit 6594dc31f58916b6f8b31de070e85d56221e3b94
1287         * dirmngr/dirmngr.c (get_revision_from_blurb): Fix detection of empty
1288         string.
1289         (gpgconf_versions): Print ksba revision.
1290
1291 2020-11-19  Jakub Bogusz  <qboosh@pld-linux.org>
1292
1293         po: Update Polish translation.
1294         + commit f7cbf68fdd1e42cdbabec7e06f2149f6b3f1d1dc
1295
1296
1297 2020-11-19  NIIBE Yutaka  <gniibe@fsij.org>
1298
1299         scd:openpgp: Public keys should be available for check_keyidstr.
1300         + commit 84020385be19556800b22cc5b0ce098acd424298
1301         * scd/app-openpgp.c (check_keyidstr): Call get_public_key.
1302
1303 2020-11-17  Werner Koch  <wk@gnupg.org>
1304
1305         Release 2.2.24.
1306         + commit 5751c48035764d938ae0459fcecd37194133bfb7
1307
1308
1309 2020-11-16  Werner Koch  <wk@gnupg.org>
1310             NIIBE Yutaka  <gniibe@fsij.org>
1311
1312         scd:openpgp: Allow keygrip to be used to reference a key.
1313         + commit 1049f06c6d2e1a833af4c73ea67a05417bbd0967
1314         * scd/app-openpgp.c (struct app_local_s): Add keygrip_str.
1315         (store_keygrip): New.
1316         (read_public_key): Store the keygrip.
1317         (get_public_key): Sitto.
1318         (send_keypair_info): USe the stored keygrip.
1319         (check_keyidstr): New.  Factored out from other functions and
1320         extended.
1321         (do_sign): Use check_keyidstr.
1322         (do_auth): Ditto.
1323         (do_decipher): Ditto.
1324         (do_check_pin): Ditto.
1325
1326 2020-11-13  Werner Koch  <wk@gnupg.org>
1327
1328         gpg: Provide better diagnostic for replaced card keys.
1329         + commit 5d98f95aa90c290a88ce97525d9f98f0aaf9e5aa
1330         * agent/divert-scd.c (divert_pksign): Add arg 'grip'.  Replace OPENPGP
1331         key reference to keygrips.
1332         (divert_pkdecrypt): Ditto.
1333         * agent/protect.c (parse_shadow_info): Trim spaces.
1334         * agent/pkdecrypt.c (agent_pkdecrypt): Pass the keygrip.
1335         * agent/pksign.c (agent_pksign_do): Ditto.
1336
1337         * g10/mainproc.c (print_pkenc_list): Print extra info for an invalid
1338         id error.
1339         * g10/sign.c (do_sign): Ditto.
1340
1341         gpg: Fix the encrypt+sign hash algo preference selection for ECDSA.
1342         + commit aeed0b93ff660fe271d8f98f8d5ce60aa5bf3ebe
1343         * g10/keydb.h (pref_hint): Change from union to struct and add field
1344         'exact'.  Adjust callers.
1345         * g10/pkclist.c (algo_available): Take care of the exact hint.
1346         * g10/sign.c (sign_file): Fix indentation.  Rework the hash from
1347         recipient prefs.
1348
1349 2020-11-12  Werner Koch  <wk@gnupg.org>
1350
1351         gpgconf: Yet another fix for --apply-profile.
1352         + commit f400ff4e7dfb424fbfcf7dfc5f80d89757ece5ab
1353         * tools/gpgconf.c (main): Use gnupg_homedir instead of
1354         default_homedir.  Check for existance of the directory.
1355
1356         scd: Skip unknown options in command SERIALNO.
1357         + commit 7076f6cafbac0cfbb3ab11e0f27c5d04ca956e8f
1358         * scd/command.c (cmd_serialno): Skip options.
1359
1360 2020-11-11  Werner Koch  <wk@gnupg.org>
1361
1362         gpg: Support brainpool keygen with "key from card".
1363         + commit 966fe1e9d98a0345da9b506ce9be0ad398f12d43
1364         * g10/keygen.c (ask_algo): Add brainpool hack in the same as for Nist
1365         curves.
1366
1367 2020-11-10  Werner Koch  <wk@gnupg.org>
1368
1369         w32: Support Unicode also for config files etc.
1370         + commit 163e4ff1959788781403ddf85f808054de414fd6
1371         * common/sysutils.c (gnupg_fopen) [W32]: Use _wfopen if needed.   Use
1372         new function in most places where fopen is used.
1373
1374         w32: Support utf8 for getcwd even if build with gpgrt < 1.40.
1375         + commit 9188a3c6b7eb871f711a0979620ca72f99522d53
1376         * common/sysutils.c (gnupg_getcwd) [W32]: Use Unicode version.
1377
1378 2020-11-09  NIIBE Yutaka  <gniibe@fsij.org>
1379
1380         scd: Internal CCID driver: Fix a race condition on close.
1381         + commit 8e206c1721564c91dd05ea46b5262670011155ab
1382         * scd/ccid-driver.c (ccid_require_get_status): For VENDOR_SCM reader,
1383         return 0 only at the initial call.
1384         (bulk_in): Don't detect an error for VENDOR_SCM reader, just kicking
1385         the loop, to invoke scd_update_reader_status_file, which calls
1386         ccid_slot_status again.
1387         (ccid_slot_status): Move the call of ccid_vendor_specific_setup to...
1388         (ccid_get_atr): ... here.
1389
1390 2020-11-09  Werner Koch  <wk@gnupg.org>
1391
1392         card: Run factory-reset in locked stated.
1393         + commit 7f765a98fd662f345baf30d93392103e5f85ace1
1394         * scd/command.c (reset_notify): Add option --keep-lock.
1395         (do_reset): Add arg keep_lock.
1396         (cmd_lock): Send progress status.
1397         * g10/call-agent.c (agent_scd_apdu): Add more pseudo APDUs.
1398         * g10/card-util.c (send_apdu): Ditto.
1399         (factory_reset): Use lock commands.
1400
1401         gpg: Fix recent commit for weak digest algos and smartcards.
1402         + commit 21d5323f5d029758fd55eae1dfdfb88b718ceada
1403         * g10/sign.c (sign_file): Fix condition.
1404
1405         Require libksba 1.3.5.
1406         + commit 549dc8cfe9a44fe7eb8a6a90662d4cbb1958a556
1407         * configure.ac (NEED_KSBA_VERSION): Set to 1.3.5.
1408
1409         Require Libgpg-error 1.27.
1410         + commit fc01ae50718b4030fbfdf3ca65ddb3e3107eacda
1411         * configure.ac (NEED_GPG_ERROR_VERSION): Require 1.27
1412         * common/util.h: Remove compatibility macros.
1413
1414         Require Libgcrypt 1.8.
1415         + commit 99ab3aed15c8a84347e39fbe49bd5748aeefe31a
1416         * configure.ac (NEED_LIBGCRYPT_VERSION): Require 1.8.
1417         * tools/gpgconf.c (show_version_libgcrypt): Remove conditional case
1418         for Libgcrypt < 1.8.
1419         * common/compliance.c (gnupg_rng_is_compliant): Ditto.
1420         * agent/pksign.c: Ditto.
1421         * agent/gpg-agent.c (thread_init_once): Ditto.
1422         (agent_libgcrypt_progress_cb): Ditto.
1423         * agent/command.c (cmd_getinfo): Ditto.
1424
1425 2020-11-09  Ben Kibbey  <bjk@luxsci.net>
1426
1427         gpg: Add canceled status message.
1428         + commit f05d1772c47b71cf77f79519b8edbc682002d303
1429         * common/status.h (STATUS_CANCELED_BY_USER): New.
1430         * g10/passphrase.c (passphrase_to_dek): Send STATUS_CANCELED_BY_USER
1431         instead of STATUS_MISSING_PASSPHRASE when canceled is set.
1432
1433 2020-11-09  Werner Koch  <wk@gnupg.org>
1434
1435         gpg: Do not print rejected digest algo notes with --quiet.
1436         + commit c373735e79a1b6240e9eca972c2bbb0c9f3247c4
1437         * g10/misc.c (print_digest_rejected_note): Do not print in quiet mode.
1438         (print_sha1_keysig_rejected_note): Ditto.
1439
1440 2020-11-04  Werner Koch  <wk@gnupg.org>
1441
1442         speedo,w32: Install gpg-check-pattern and example profiles.
1443         + commit a4fa4b5d4ba38e51436914505af1a8f3483ed945
1444         * doc/examples/vsnfd.prf: Rename to VS-NfD.prf.
1445         * doc/examples/Automatic.prf: New.
1446         * doc/Makefile.am (examples): Adjust.
1447         * build-aux/speedo/w32/inst.nsi: Install gpg-check-pattern.exe and 3
1448         example files.
1449         * build-aux/speedo/w32/wixlib.wxs: Add new files.
1450
1451         g13: Include a now missing header file.
1452         + commit d4089b04a5f15c1cc1a4809cb8f0d59fc1cdf564
1453         * g13/create.c: Include sysutuls.h
1454         * g13/sh-dmcrypt.c: Ditto.
1455
1456         gpgconf: Make sure the homedir exists for --apply-profile.
1457         + commit 1fbf085bc8b4a92772d1da8bfea507f4f97434b1
1458         * tools/gpgconf.c (main) <aApplyDefaults, aApplyProfile>: Create the
1459         standard home directory.
1460
1461         common: Fix duplicate implementation of try_make_homedir.
1462         + commit 6fe5c8c06e8cd162913ee5b0eb741eb4beebf44a
1463         * g10/openfile.c (try_make_homedir): Move core of the code to ...
1464         * common/homedir.c (gnupg_maybe_make_homedir): new.
1465         * sm/keydb.c (try_make_homedir): Implement using new function.
1466
1467         * common/homedir.c: Include i18n.h.
1468         * po/POTFILES.in: Add common/homedir.c.
1469
1470 2020-11-04  Andre Heinecke  <aheinecke@gnupg.org>
1471
1472         w32: Add another pinentry search path.
1473         + commit b4cb91d5fbe2b8917d76d12eb72aaac0d97ed596
1474         * common/homedir.c (get_default_pinentry_name): Try ../bin/pinentry.exe
1475
1476         w32: Add windows subsystem variant of gpgconf.
1477         + commit c366e04958481382c3f7b50f169120053186069b
1478         * tools/Makefile.am (gpgconf-w32): New target. Builds gpgconf with
1479         subsystem windows.
1480         * build-aux/speedo/w32/wixlib.wxs: Package it.
1481
1482 2020-11-03  Werner Koch  <wk@gnupg.org>
1483
1484         w32: Fix strftime problem on Windows.
1485         + commit d633e92233f4a4afc82d3d9282220f303974525b
1486         * common/gettime.c: Include locale.h.
1487         (asctimestamp): Increase buffer.  On Windows use setlocale.
1488
1489         gpg: Switch to AES256 for symmetric encryption in de-vs mode.
1490         + commit 166e779634ea5fe2a7beeb186807e3a81128c717
1491         * g10/gpg.c (set_compliance_option): For AES256 and SHA256 in de-vs
1492         mode.
1493         * g10/encrypt.c (setup_symkey): Add extra compliance check.
1494         (encrypt_simple): Avoid printing a second error oncplinace failure.
1495
1496 2020-11-03  Andre Heinecke  <aheinecke@gnupg.org>
1497
1498         po: Major update of italian translation.
1499         + commit ccecdc1f34a973dcd8d00b6ee9c830e0ddc8d08b
1500         * po/it.po: Update to a recent 2.2 version.
1501
1502 2020-11-02  Werner Koch  <wk@gnupg.org>
1503
1504         gpg: Allow setting notations with the empty string as value.
1505         + commit f007d79533e638e395e1a3cf99233fd900cc805c
1506         * g10/misc.c (pct_expando): Catch special case of the empty string.
1507         Also map a NULL to the empty string.
1508         * g10/photoid.c (show_photos): Make an empty string used as command
1509         fail.
1510
1511         gpg: Do not use weak digest algos if selected by recipient prefs.
1512         + commit 4c181d51a6f1fd05b7f190a18769ba5e9f892f6a
1513         * g10/misc.c (is_weak_digest): New.
1514         (print_digest_algo_note): Use it here.
1515         * g10/sig-check.c (check_signature_end_simple): Use it.
1516         * g10/sign.c (hash_for): Do not use recipient_digest_algo if it is in
1517         the least of weak digest algorithm.
1518
1519 2020-10-30  Ingo Klöcker  <dev@ingo-kloecker.de>
1520
1521         gpg: Fix iteration over signatures.
1522         + commit 8a941428086bc173a65d4e8687308ca923394738
1523         * g10/keyedit.c (keyedit_quick_revsig): Take signature of correct node
1524
1525 2020-10-30  NIIBE Yutaka  <gniibe@fsij.org>
1526
1527         agent: Fix secret key import for Ed25519.
1528         + commit ba321b60bc3bfc29dfc6fa325dcabad4fac29f9c
1529         * agent/cvt-openpgp.c (convert_secret_key): Avoid adding 0x00 at the
1530         beginning of MPI.
1531
1532 2020-10-28  Werner Koch  <wk@gnupg.org>
1533
1534         gpg: New command --quick-revoke-sig.
1535         + commit 7ec56b033647a1b14d56f771d51c563dbd25f1b7
1536         * g10/gpg.c (enum cmd_and_opt_values): Add aQuickRevSig.
1537         (opts): Add --quick-revoke-sig.
1538         (main): Implement.
1539         * g10/keyedit.c (quick_find_keyblock): Add arg 'want_secret' and
1540         adjust all callers.
1541         (keyedit_quick_revsig): new.
1542         * g10/revoke.c (get_default_sig_revocation_reason): New.
1543         * g10/keylist.c (cmp_signodes): New.
1544
1545 2020-10-26  NIIBE Yutaka  <gniibe@fsij.org>
1546
1547         scd: Internal CCID driver thing only for SPR532.
1548         + commit 38040ffee81e3c7a6972c9eae42af44eaaeb6ce6
1549         * scd/ccid-driver.c (ccid_vendor_specific_setup): New.  Limit
1550         only for SPR532, excluding other readers by SCM.
1551         (ccid_slot_status): Use ccid_vendor_specific_setup.
1552
1553         scd: Internal CCID driver limiting only for SPR532.
1554         + commit d1c9cc3ca03d2134a0feecab6db3c4af308c7fa7
1555         * scd/ccid-driver.c (ccid_vendor_specific_init): Only do that for
1556         SPR532.
1557
1558 2020-10-23  Werner Koch  <wk@gnupg.org>
1559
1560         common: New functions gnupg_opendir et al.
1561         + commit 5f8123df7856b724a062177026fe669ae49be263
1562         * common/sysutils.h (struct gnupg_dirent_s): New.
1563         * common/sysutils.c: Include dirent.h.
1564         (struct gnupg_dir_s): New.
1565         (gnupg_opendir, gnupg_readdir, gnupg_closedir): New.  Change all
1566         callers of opendir, readdir, and closedir to use these functions.
1567
1568         w32: Make gnupg_remove and gnupg_rename_file Unicode aware.
1569         + commit 4252cd7b18b41a0d91076e46df9ba857e743406b
1570         * common/sysutils.c (w32_rename): New.
1571         (gnupg_rename_file) [W32]: Support Unicode.
1572         (gnupg_remove) [W32]: Support Unicode.  Drop Windows-CE support.
1573
1574         Replace all calls to stat by gnupg_stat.
1575         + commit 157030271f2d88d0756788a60c43e455870ec124
1576         * common/sysutils.c (gnupg_stat): New.
1577         * common/sysutils.h: Include sys/stat.h.
1578
1579         Replace most calls to open by a new wrapper.
1580         + commit 86e52e3c33843f67a7972181ccbf33b48a40e557
1581         * common/sysutils.c (any8bitchar) [W32]: New.
1582         (gnupg_open): New.  Replace most calls to open by this.
1583         * common/iobuf.c (any8bitchar) [W32]: New.
1584         (direct_open) [W32]: Use CreateFileW if needed.
1585
1586 2020-10-21  Werner Koch  <wk@gnupg.org>
1587
1588         w32: Allow Unicode filenames for dotlock.
1589         + commit d65ea29683eeecfcf12e74744a490e8acfc1a5cf
1590         * common/dotlock.c (any8bitchar) [W32]: New.
1591         (dotlock_create_w32): Use strconcat and CreateFileW.
1592
1593         * common/t-dotlock.c: Source include dotlock.c and modify to allow
1594         manual testing on Windows.
1595
1596         Replace all calls to access by gnupg_access.
1597         + commit dd5fd4a760b8cf6ae05ff878bcf36cf2465e744c
1598         * common/sysutils.c (gnupg_access): New.  Replace all calls to access
1599         by this wrapper.
1600         * common/homedir.c (w32_shgetfolderpath): Change to return UTF-8
1601         directory name.
1602         (standard_homedir): Adjust for change.
1603         (w32_commondir, gnupg_cachedir): Ditto.
1604
1605 2020-10-06  NIIBE Yutaka  <gniibe@fsij.org>
1606
1607         scd: Add a workaround for Yubikey.
1608         + commit 25bec16d0bdcb9829a7b35c403cbb778b3b0c097
1609         * scd/app-openpgp.c (get_public_key): Handle wrong code for Yubikey.
1610
1611         scd: Silence compiler warning.
1612         + commit 0f4c956a76614bebf0f86bef79eba0e850e23df4
1613         * scd/app-openpgp.c (build_ecc_privkey_template): Fix allocation size.
1614
1615         scd: Report any error for LEARN command.
1616         + commit 7c8823bf82daade7417aeaebc34fefe3aa7c1856
1617         * scd/app-openpgp.c (do_learn_status): Report any error.
1618
1619         scd: Internal CCID driver: More fix for SPR532.
1620         + commit 1f1b68eef72bed9bb7ac1eb8102f6f51d587dbc0
1621         * scd/ccid-driver.c (bulk_in): Handle the case of missing intr_cb.
1622
1623         scd: Internal CCID driver fix.
1624         + commit 33a2d4bd7ffc6ad10d7ddb0f29fe4e21609806f7
1625         * scd/ccid-driver.c (intr_cb): More useful debug output.
1626         (ccid_slot_status): Remove redundant condition.
1627
1628         scd: Internal CCID driver: Call libusb_clear_halt at ccid_setup_intr.
1629         + commit 48565e7a08d64e3628da8baa80541841af0a6166
1630         * scd/ccid-driver.c (ccid_setup_intr): Reset the endpoint.
1631         (ccid_vendor_specific_init): Don't call libusb_clear_halt.
1632
1633         scd: Internal CCID driver: Fix a failure path.
1634         + commit 30693dfb6fe970dba195bf00a77d854e6fbc1ed0
1635         * scd/ccid-driver.c (ccid_open_usb_reader): On error, call
1636         libusb_release_interface.
1637
1638         scd: Internal CCID: Handle LIBUSB_ERROR_TIMEOUT at ccid_get_atr.
1639         + commit 498cd38019b8122824d69fd194675ab532501423
1640         * scd/ccid-driver.c (ccid_slot_status): Handle LIBUSB_ERROR_TIMEOUT.
1641
1642         scd: Change handling of SPR532 card reader.
1643         + commit 7db836c0e9223a4d5f30636e35e18156a97e6b91
1644         * scd/ccid-driver.c (ccid_vendor_specific_init): Put some workaround
1645         for SPR532 initialization.
1646         (ccid_slot_status): Send ESCape command after GetSlotStatus.
1647
1648         scd: For SPR532, submit the ESCape command at initialization.
1649         + commit 11d8d1e0505645f7d14bcc1c01d17a566e033705
1650         * scd/ccid-driver.c (ccid_vendor_specific_init): Submit the ESC
1651         command for VENDOR_SCM.
1652         (ccid_transceive_secure): Don't submit the ESC command every time.
1653
1654         scd: Fix CCID internal driver for interrupt transfer.
1655         + commit dd7cc24d5f9274579f0966de3be7ae8b0c19bacd
1656         * scd/ccid-driver.c (intr_cb): Handle the case of multiple messages.
1657
1658         scd: Better handling of timeout and time extension.
1659         + commit 186d11896ca2751eac8a7f54845ec71cc7f6fcc3
1660         * scd/ccid-driver.c (CCID_CMD_TIMEOUT_LONGER): Remove.
1661         (ccid_transceive): Don't use x4 blindly for bBWI, but use dynamically
1662         determined value.  Use value from variable wait_more for bulk_in.
1663         Set wait_more by the value of time extension request.
1664
1665         scd: Fix internal CCID driver, so that -DTEST works.
1666         + commit 60af035c22b9fbdc10c8c0a69399c46908801c66
1667         * scd/ccid-driver.c: Support a test program by ccid-driver.
1668
1669         scd: ccid-driver: Initial getting ATR more robustly.
1670         + commit 165312dca90a198ebc0be4ed6b0791297c90b085
1671         * scd/ccid-driver.c (send_power_off): New.
1672         (do_close_reader): Use send_power_off.
1673         (ccid_get_atr): Add error recovery.
1674
1675         scd: Clean up the structure for future fix of PC/SC.
1676         + commit 1efc01ff987dde4adf6777d4df44b5a00f6f0d8d
1677         * scd/apdu.c (struct dev_list): Rename from ccid_table, with void*.
1678         (open_ccid_reader): Follow the change.
1679         (apdu_dev_list_start, apdu_dev_list_finish): Likewise.
1680         (apdu_open_reader): Likewise.
1681         * scd/ccid-driver.c (ccid_dev_scan): Use void *.
1682         (ccid_dev_scan_finish, ccid_get_BAI, ccid_open_usb_reader): Likewise.
1683         * scd/ccid-driver.h: Change the APIs.
1684
1685 2020-10-06  Werner Koch  <wk@gnupg.org>
1686
1687         scd: Map some error codes from libusb to ccid-driver error codes.
1688         + commit 5b985b026418213a4c75291cb041ca8aa798cec3
1689         * scd/ccid-driver.h (CCID_DRIVER_ERR_USB_*): New error codes.
1690         * scd/apdu.h: New SW_HOST error codes.
1691         * scd/apdu.c (host_sw_string): Print them
1692         * scd/ccid-driver.c (map_libusb_error): New.
1693         (ccid_open_usb_reader, bulk_in, abort_cmd): Map libusb error codes.
1694         * scd/iso7816.c (map_sw): Map new codes to gpg-error.
1695
1696 2020-10-06  NIIBE Yutaka  <gniibe@fsij.org>
1697
1698         scd: internal driver: Submit SET_INTERFACE control transfer.
1699         + commit cccdca61a841228475da573aab8b57c659a9631a
1700         * scd/ccid-driver.c (ccid_open_usb_reader): Alway submit SET_INTERFACE
1701         control transfer.
1702
1703         scd: Internal CCID driver: Clean up backport from master.
1704         + commit 7b531fe5801b0ad47414c4a6ed961665ba5a2541
1705             * scd/ccid-driver.c (print_error) [TEST]: Add missing break.  Note
1706             that this is anyway an impossible case.
1707
1708 2020-10-05  Werner Koch  <wk@gnupg.org>
1709
1710         dirmngr: Minor cleanup for better readability.
1711         + commit ffbef54d36d4c2c150b63a57c79872d2e1f2a68e
1712         * dirmngr/ldap.c (start_default_fetch_ldap): Rename to
1713         start_cacert_fetch_ldap and remove arg attr.  Instead use
1714         "cACertificate" directly.
1715         * dirmngr/crlfetch.c (ca_cert_fetch): Change the only caller.
1716         (start_cert_fetch_ldap): Rename arg for clarity.
1717
1718 2020-10-04  Werner Koch  <wk@gnupg.org>
1719
1720         build: Fix SENDMAIL define for a PATH with spaces.
1721         + commit 77e416741abb0a871733bd46cbc81329859de96e
1722         * configure.ac: Fix use of $PATH
1723
1724 2020-10-02  Werner Koch  <wk@gnupg.org>
1725
1726         gpgconf,w32: Add manifest so we get the correct windows version.
1727         + commit 239e60a37f63d3880d1107b6981a964f437761ae
1728         * common/w32info-rc.h.in: Update copyright info.
1729         * tools/gpg-connect-agent-w32info.rc: Tweak file info.
1730         * tools/gpgconf-w32info.rc: New.
1731         * tools/gpgconf.w32-manifest.in: New.
1732         * configure.ac: Add new .in file.
1733         * tools/Makefile.am (EXTRA_DIST): Add them.
1734         (gpg_connect_agent_robjs, gpgconf_robjs): New.
1735         (gpgconf_LDADD): Add resource file.
1736         (gpg_connect_agent_LDADD): Change name of resource macro.
1737
1738         gpgconf: New option --show-versions.
1739         + commit a298ba02ee76a9291ef5cec1a3564d8e254b9ca7
1740         * tools/gpgconf.c: Include exechelp.h.  New option --show-versions.
1741         (get_revision_from_blurb): New.
1742         (show_version_gnupg): New.
1743         (show_version_libgcrypt): New.
1744         (show_version_gpgrt): New.
1745         (show_versions_via_dirmngr): New.
1746         (show_versions): New.
1747         * dirmngr/dirmngr.c (main): New internal option --gpgconf-versions.
1748         (get_revision_from_blurb): New.
1749         (gpgconf_versions): New.
1750
1751 2020-10-01  Andre Heinecke  <aheinecke@gnupg.org>
1752
1753         doc: Remove enable-extended-key-format in vsnfd.
1754         + commit d833030f8cf646b5de83d01fc3e412ad77ec4b1c
1755         * doc/examples/vsnfd.prf: Remove enable-extended-key-format
1756
1757 2020-09-22  Werner Koch  <wk@gnupg.org>
1758
1759         kbx: Add bounds check to detect corrupt keyboxes.
1760         + commit be8b30f8ebf637a7e476ff8902349a56924bf20f
1761         * kbx/keybox-dump.c (_keybox_dump_blob): Fix the fixmes.  Add support
1762         for 32 byte fingerprints.
1763
1764 2020-09-16  NIIBE Yutaka  <gniibe@fsij.org>
1765
1766         scd: Fix the use case of verify_chv2 by CHECKPIN.
1767         + commit 61aea64b3c1717a7e304c82cda92e08ce5a6c533
1768         * scd/app-openpgp.c (verify_chv2): Call verify_a_chv with chvno=1
1769         when needed.
1770
1771 2020-09-10  Werner Koch  <wk@gnupg.org>
1772
1773         gpg-connect-agent: Catch signals so that SIGPIPE is ignored.
1774         + commit a084924d07be16dbbbf4b34d463c67c8d4c117be
1775         * dirmngr/server.c (cmd_killdirmngr): Return 0.
1776         * tools/gpg-connect-agent.c (main): Catch signals.
1777
1778         dirmngr: Fix the pool keyserver case for a single host in the pool.
1779         + commit 72e04b03b1a7aee5521156c6d549ca10a81ac529
1780         * dirmngr/ks-engine-hkp.c (map_host): Set R_HOSTNAME also for
1781         localhost and if there is no pool.
1782
1783         dirmngr: Align the gnutls use of CAs with the ntbtls code.
1784         + commit e4f3b74c91063d83395ba0bc37f67cb22d47ca8f
1785         * dirmngr/http.c (http_session_new) <gnutls>: Use only the special
1786         pool certificate for the default keyserver.
1787
1788         agent: Keep some permissions of private-keys-v1.d.
1789         + commit 7de9ed521e516879a72ec6ff6400aed4bdce5920
1790         * common/sysutils.c (modestr_to_mode): Re-implement.
1791         (gnupg_chmod): Support keeping of permissions.
1792
1793 2020-09-04  Werner Koch  <wk@gnupg.org>
1794
1795         gpg: Initialize a parameter to silence valgrind.
1796         + commit 6ce8fdc4b2a05bb2c1cf2aa9faa76f1c7a4fdb28
1797         * g10/keygen.c (read_parameter_file): Initialize nline.
1798         * g10/textfilter.c (copy_clearsig_text): Initialize bufsize.
1799
1800 2020-09-03  Werner Koch  <wk@gnupg.org>
1801
1802         Release 2.2.23.
1803         + commit e234d04c3c91cd4e84cb5790a131bf6a8b6733c4
1804
1805
1806         gpg: Fix AEAD preference list overflow.
1807         + commit aeb8272ca8aad403a4baac33b8d5673719cfd8f0
1808         * g10/getkey.c (fixup_uidnode): Increase size of prefs array.
1809
1810 2020-09-02  Werner Koch  <wk@gnupg.org>
1811
1812         gpg: Fix segv importing certain keys.
1813         + commit 896c528ba0555443cca81b3f091f761e70c698cd
1814         * g10/key-check.c (key_check_all_keysigs): Initialize issuer.
1815
1816 2020-09-01  NIIBE Yutaka  <gniibe@fsij.org>
1817
1818         scd: Fix a regression for OpenPGP card.
1819         + commit 0a9665187a7cbf68933b7162fb5f974177684a50
1820         * scd/app-openpgp.c (verify_chv2): Make sure loading keys.
1821
1822 2020-08-28  Werner Koch  <wk@gnupg.org>
1823
1824         sm: Fix a bug in the rfc2253 parser.
1825         + commit d2fe2ffd753706d07b26fbe22b17a561a2e535fc
1826         * sm/certdump.c (parse_dn_part): Fix parser flaw.
1827
1828 2020-08-27  Werner Koch  <wk@gnupg.org>
1829
1830         Release 2.2.22.
1831         + commit f9c120a29986e82d1179b38167ef2696dd0cc10a
1832
1833
1834         dirmngr: Print the last alert message returned by NTBTLS.
1835         + commit 45499b2ca3e8f3466e725dbc381757c89a7c39bf
1836         * dirmngr/http.c (send_request): Print the last TLS alert.
1837
1838 2020-08-27  NIIBE Yutaka  <gniibe@fsij.org>
1839
1840         scd: Add condition for VERIFY with 0x82.
1841         + commit d2f1a0a791db3eb03c003365cbcd010bd8066edb
1842         * scd/app-openpgp.c (verify_chv2): Check availability of keys in
1843         question.
1844
1845 2020-08-26  Werner Koch  <wk@gnupg.org>
1846
1847         build: Silence gcc warning -Wformat-zero-length.
1848         + commit 0be5decc097286e3502b6a12e019d40b8caf27b4
1849         * configure.ac: Avoid useless gcc warning.  We use an empty string
1850         quite often, for example in log_printhex.
1851
1852 2020-08-26  NIIBE Yutaka  <gniibe@fsij.org>
1853
1854         agent: Allow TERM="".
1855         + commit 4c8d5eb0bdd380c412c5f5fbc2b92fe6bcea825d
1856         * agent/call-pinentry.c (start_pinentry): When TERM is none,
1857         don't send OPTION ttytype to pinentry.
1858
1859 2020-08-25  Ineiev  <ineiev@gnu.org>
1860
1861         po: Update Russian translation.
1862         + commit 00ac538e928076e1879366cdce0e57be41f6c8fb
1863
1864
1865 2020-08-25  Werner Koch  <wk@gnupg.org>
1866
1867         gpg: Set default keysize to rsa3072.
1868         + commit 60f08969e13b2bb7f194eff80c3a275d444dc6b7
1869         * g10/keygen.c (DEFAULT_STD_KEY_PARAM): Change.
1870         (gen_rsa): Set fallback to 3072.
1871         (get_keysize_range): Set default to 3072.
1872         * doc/examples/vsnfd.prf: No more need for default-new-key-algo.
1873
1874         sm: Do not require a default keyring for --gpgconf-list.
1875         + commit 0847133e4cafa214c8129c245194d97c1e192cd5
1876         * sm/gpgsm.c (main): No default keyring for gpgconf mode.
1877
1878         agent: Allow using --gogconf-list even if HOME does not exist.
1879         + commit adea5ba7e75261705ba6e9c2456207e9455677f3
1880         * agent/gpg-agent.c (main): Do not create directories in gpgconf mode.
1881
1882 2020-08-23  Werner Koch  <wk@gnupg.org>
1883
1884         gpg,gpgsm: Record the creation time of a private key.
1885         + commit 5ac0cf1b8198dcaac7e7abaf05c28dd413f38cad
1886         * sm/call-agent.c (gpgsm_agent_genkey): Pass --timestamp option.
1887         (gpgsm_agent_import_key): Ditto.
1888         * g10/call-agent.c (agent_genkey): Add arg timestamp and pass it on.
1889         (agent_import_key): Ditto.
1890         * g10/import.c (transfer_secret_keys): Pass the creation date to the
1891         agent.
1892         * g10/keygen.c (common_gen): Ditto.
1893
1894         agent: Allow to pass a timestamp to genkey and import.
1895         + commit 051830d7b4862b6eca6c18c9fd53b51fa1158c34
1896         * agent/command.c (cmd_genkey): Add option --timestamp.
1897         (cmd_import_key): Ditto.
1898         * agent/genkey.c (store_key): Add arg timestamp and change callers.
1899         (agent_genkey): Ditto.
1900         * agent/findkey.c (write_extended_private_key): Add args timestamp and
1901         newkey to write a Created line.
1902         (agent_write_private_key): Add arg timestamp.
1903         (agent_write_shadow_key): Ditto.
1904         * agent/protect-tool.c (agent_write_private_key): Ditto as dummy arg.
1905
1906 2020-08-22  Werner Koch  <wk@gnupg.org>
1907
1908         agent: Default to extended key format.
1909         + commit 5b927b7b27bddc8ee70176414690d8ca8d879b54
1910         * agent/gpg-agent.c (oDisableExtendedKeyFormat, oNoop): New.
1911         (opts): Make --enable-extended-key-format a dummy option.  Add
1912         disable-extended-key-format.
1913         (parse_rereadable_options): Implement oDisableExtendedKeyFormat.
1914         * agent/protect.c (agent_protect): Be safe and set use_ocb either to
1915         to 1 or 0.
1916
1917         gpgtar,w32: Handle Unicode file names.
1918         + commit 843890663b6c68b4361ccfbeb11a50b02d5cc13f
1919         * tools/gpgtar.c (oUtf8Strings): New.
1920         (opts): Add option --utf8-strings.
1921         (parse_arguments): Set option.
1922         * tools/gpgtar.h (opt): Add field utf8strings.
1923         * tools/gpgtar-create.c (name_to_utf8): New.
1924         (fillup_entry_w32): Use that.
1925         (scan_directory): Ditto.
1926         (scan_directory) [W32]: Convert file name to utf8.
1927         (gpgtar_create): Convert pattern.
1928
1929         common: Use gpgrt functions for mkdir and chdir if available.
1930         + commit 364cef997c0ac5632152acfb7ab2330c4f289a9a
1931         * common/sysutils.c (gnupg_mkdir): Divert to gpgrt_mkdir.
1932         (gnupg_chdir): Divert to gpgrt_chdir
1933
1934         common,w32: Do not assume the ANSI codepage during string conversion.
1935         + commit bef68efd8da92115142005d22e9336ff798dcf4b
1936         * common/utf8conv.c (get_w32_codepage): New.
1937         (wchar_to_native): Use instead oc CP_ACP.
1938         (native_to_wchar): Ditto.
1939
1940         common: Strip trailing CR,LF from w32_strerror.
1941         + commit 73b0fdabdb108880034b7730d04614d8a7cf943a
1942         * common/stringhelp.c (w32_strerror): Strip trailing CR,LF.
1943         * common/iobuf.c (iobuf_get_filelength): Use -1 and not 0 for the
1944         arg to w32_strerror.
1945
1946 2020-08-20  Werner Koch  <wk@gnupg.org>
1947
1948         gpgtar: Make --files-from and --null work as described.
1949         + commit 1efe99f3d9e3c6d5733cf512b7e494284a445bfa
1950         * tools/gpgtar-create.c (gpgtar_create): Add args files_from and
1951         null_names.  Improve reading from a file.
1952         * tools/gpgtar.c: Make global vars static.
1953         (main): Remove tests for --files-from and --null option combinations.
1954         Pass option variables to gpgtar_create.
1955
1956         build: New configure option --disable-tests.
1957         + commit 829bc3bc60da134841705f7d701b0870e1629b38
1958         * configure.ac: Add option --disable-tests.  Print warnings in the
1959         summary.
1960         (DISABLE_TESTS): New am_conditional.
1961
1962         gpg: Fix regression for non-default --passphrase-repeat option.
1963         + commit a4d73b1c8e2a312e78831843aa04364d7d3c8e6f
1964         * agent/command.c (cmd_get_passphrase): Take care of --repeat with
1965         --newsymkey.
1966
1967 2020-08-13  Werner Koch  <wk@gnupg.org>
1968
1969         gpg: Ignore personal_digest_prefs for ECDSA keys.
1970         + commit f0f8b124f0d2332e1c0b496df5e5f9c4b3db6bc3
1971         * g10/sign.c (hash_for): Simplify hash algo selection for ECDSA.
1972
1973 2020-08-12  Werner Koch  <wk@gnupg.org>
1974
1975         common: Pass the WAYLAND_DISPLAY envvar along.
1976         + commit 3cf920a1e353ceec7a3d854d5b509be417e4c801
1977         * common/session-env.c (stdenvnames): Add WAYLAND_DISPLAY.
1978
1979 2020-08-04  Werner Koch  <wk@gnupg.org>
1980
1981         sm: Also show the SHA-256 fingerprint.
1982         + commit 9c57de75cf36cfcf408eda1b59a0362a061517ce
1983         * sm/keylist.c (list_cert_colon): Emit a new "fp2" record.
1984         (list_cert_raw): Print the SHA2 fingerprint.
1985         (list_cert_std): Ditto.
1986
1987 2020-07-30  NIIBE Yutaka  <gniibe@fsij.org>
1988
1989         w32: More adding NETLIBS.
1990         + commit 8d9ce32c30db2bba5736fff5f56b7c145aaec42c
1991         * common/Makefile.am (t_common_ldadd): Add $(NETLIBS).
1992
1993         w32: Add link to $(NETLIB) for -lws2_32.
1994         + commit f95d923090e119a7a05eef13bbbc108ed98e513a
1995         * dirmngr/Makefile.am (dirmngr_LDADD): Add $(NETLIBS).
1996         * sm/Makefile.am (gpgsm_LDADD): Ditto.
1997         * tools/Makefile.am (gpg_wks_client_LDADD): Ditto.
1998
1999 2020-07-16  Werner Koch  <wk@gnupg.org>
2000
2001         gpg: Do not close stdout after --export-ssh-key.
2002         + commit 970e43130506186c82d528d0a4fe34725e3c8e6b
2003         * g10/export.c (export_ssh_key): Do not close stdout.
2004
2005 2020-07-15  NIIBE Yutaka  <gniibe@fsij.org>
2006
2007         tools: Use internal regexp routines.
2008         + commit b4cbb5f58a00fa5ac9f1282664c0adb7ecfa9e57
2009         * tools/gpg-check-pattern.c: Use jimregexp.h.
2010
2011         regexp: Import change from JimTcl.
2012         + commit 1d1f2aa94370dcb715f6ae02ea5e14eb7ec5fa98
2013         * regexp/jimregexp.h, regexp/jimregexp.c: Fix from JimTcl.
2014
2015         regexp: Fix generation of _unicode_mapping.c.
2016         + commit 8904b18822fc2203ed667844cc3885dc459dbfef
2017         * configure.ac (AWK_HEX_NUMBER_OPTION): Detect GNU Awk.
2018         * regexp/Makefile.am: Use AWK_HEX_NUMBER_OPTION.
2019         * regexp/parse-unidata.awk: Don't use strtonum.
2020
2021         gpg: Add regular expression support.
2022         + commit 199309190a0b9966445bc386747c433949d3b81e
2023         * AUTHORS, COPYING.other: Update.
2024         * Makefile.am (SUBDIRS): Add regexp sub directory.
2025         * configure.ac (DISABLE_REGEX): Remove.
2026         * g10/Makefile.am (needed_libs): Add libregexp.a.
2027         * g10/trustdb.c: Remove DISABLE_REGEX support.
2028         * regexp/LICENSE, regexp/jimregexp.c, regexp/jimregexp.h,
2029           regexp/utf8.c, regexp/utf8.h: New from Jim Tcl.
2030         * regexp/UnicodeData.txt: New from Unicode.
2031         * regexp/Makefile.am, regexp/parse-unidata.awk: New.
2032         * tests/openpgp/Makefile.am: Remove DISABLE_REGEX support.
2033         * tools/Makefile.am: Remove DISABLE_REGEX support.
2034
2035 2020-07-13  Werner Koch  <wk@gnupg.org>
2036
2037         agent: Fix regression with --newsymkey in loopback mode.
2038         + commit d9ea47f702840c87431df984b9b3f7e60c9ea815
2039         * agent/command.c (cmd_get_passphrase): Never repeat in loopback mode;
2040         same as with !OPT_NEWSYMKEY.
2041
2042 2020-07-13  NIIBE Yutaka  <gniibe@fsij.org>
2043
2044         dirmngr: Handle EAFNOSUPPORT at connect_server.
2045         + commit ce793fc2f838a97cb1e92b3060337b8052f3dc3a
2046         * dirmngr/http.c (connect_server): Skip server with EAFNOSUPPORT.
2047
2048 2020-07-09  Werner Koch  <wk@gnupg.org>
2049
2050         Release 2.2.21.
2051         + commit be6fc39ed9b4ffd56d960e20499599c851c17b44
2052
2053
2054 2020-07-08  Werner Koch  <wk@gnupg.org>
2055
2056         Do not use the pinentry's qualitybar.
2057         + commit b451c4f5ea672c9915e28d8dde30abc675060f06
2058         * agent/genkey.c (agent_ask_new_passphrase): No qualitybar.
2059         * g10/call-agent.c (agent_get_passphrase): Ditto.
2060         * sm/call-agent.c (gpgsm_agent_ask_passphrase): Ditto.
2061
2062         gpg: Use integrated passphrase repeat entry also for -c.
2063         + commit ae8b88c635424ef36f024d0016949d11187dc21e
2064         * g10/call-agent.c (agent_get_passphrase): Add arg newsymkey.
2065         * g10/passphrase.c (passphrase_get): Add arg newsymkey.
2066         (passphrase_to_dek): Pass it on.
2067
2068         agent: New option --newsymkey for GET_PASSPHRASE.
2069         + commit d9e2dfa4c585de7c261fde13c18bd0f82415d6c3
2070         * agent/call-pinentry.c (do_getpin): New.
2071         (agent_askpin): Use do_getpin.
2072         (agent_get_passphrase): Add arg pininfo.  Use do_getpin.
2073         * agent/genkey.c (check_passphrase_constraints): New arg no_empty.
2074         * agent/command.c (reenter_passphrase_cmp_cb): New.
2075         (cmd_get_passphrase): Add option --newsymkey.
2076
2077 2020-07-07  Werner Koch  <wk@gnupg.org>
2078
2079         gpg: Fix flaw in symmetric algorithm selection in mixed mode.
2080         + commit 7b6071a45fbf14219b6aca4fff8fa0eaf6c6dd8e
2081         * g10/encrypt.c (setup_symkey): Use default_cipher_algo function
2082         instead of the fallback s2k_cipher_algo.  Fix error code.
2083         (encrypt_simple): Use setup_symkey.
2084
2085 2020-07-03  Werner Koch  <wk@gnupg.org>
2086
2087         sm: Exclude rsaPSS from de-vs compliance mode.
2088         + commit 4a36adaa64311a42eb78d9e52390df489454cafb
2089         * common/compliance.h (PK_ALGO_FLAG_RSAPSS): New.
2090         * common/compliance.c (gnupg_pk_is_compliant): Add arg alog_flags and
2091         test rsaPSS.  Adjust all callers.
2092         * common/util.c (pubkey_algo_to_string): New.
2093         (gnupg_pk_is_allowed): Ditto.
2094         * sm/misc.c (gpgsm_ksba_cms_get_sig_val): New wrapper function.
2095         (gpgsm_get_hash_algo_from_sigval): New.
2096         * sm/certcheck.c (gpgsm_check_cms_signature): Change type of sigval
2097         arg.  Add arg pkalgoflags.  Use the PK_ALGO_FLAG_RSAPSS.
2098         * sm/verify.c (gpgsm_verify): Use the new wrapper and new fucntion to
2099         also get the algo flags.  Pass algo flags along.  Change some of the
2100         info output to be more like current master.
2101
2102 2020-07-02  Werner Koch  <wk@gnupg.org>
2103
2104         dirmngr: Silence annoying warning for missing default ldap server file.
2105         + commit daca1a011b0e4ae888fd6b11253993cb3537990f
2106         * dirmngr/dirmngr.c (parse_ldapserver_file): Add arg ignore_enoent.
2107         (main): Use that arg for the default file.
2108
2109         dirmngr: Fix case handling of "ldapi" scheme.
2110         + commit 0795ab1c8f95831c15d4ae36d197805a26f8c899
2111         * dirmngr/ldap-parse-uri.c (ldap_uri_p): s/'i'/'I'.
2112
2113 2020-06-26  Werner Koch  <wk@gnupg.org>
2114
2115         sm: Print the serial number of a cert also in decimal.
2116         + commit ad6bf5d67f58dcdd76b621e77b81efa7b41ca885
2117         * sm/certdump.c: Include membuf.h.
2118         (gpgsm_print_serial_decimal): New.
2119         * sm/keylist.c (list_cert_raw): Print s/n also in decimal
2120         (list_cert_std): Ditto.
2121
2122 2020-06-03  Werner Koch  <wk@gnupg.org>
2123
2124         doc: Minor enhancement for reproducibility.
2125         + commit 5ade2b68db231c78d8ecca0eb21db2153da958d2
2126         * doc/Makefile.am (defsincdate): In no repo mode and with
2127         SOURCE_DATE_EPOCH set, use that instead of blanking the date.
2128
2129         common: Add missing error code GPG_ERR_WRONG_NAME.
2130         + commit 381c54179c2adefd558035f573a2029de2e1a2f7
2131         * configure.ac: Require libgpg-error 1.25.
2132         * common/util.h: Define some extra error codes.
2133
2134 2020-05-29  NIIBE Yutaka  <gniibe@fsij.org>
2135
2136         scd: Fix condition for C5 data object for newer Yubikey.
2137         + commit e285b1197b93e5114679b2ece9f10743abc715ef
2138         * scd/app-openpgp.c (compare_fingerprint): Relax the condition.
2139
2140 2020-05-21  NIIBE Yutaka  <gniibe@fsij.org>
2141
2142         dirmngr: dns: Fix allocation of string buffer in stack.
2143         + commit ab724d3206c8d3500ab2d982c98bad93ee550e42
2144         * dirmngr/dns.h (dns_strsection, dns_strclass)
2145         (dns_strtype): Change APIs.
2146         * dirmngr/dns.c (dns_p_lines): Use __dst for dns_strsection.
2147         (dns_rr_print): Use __dst for dns_strclass and dns_strtype.
2148         (dns_trace_dump): Likewise.
2149         (dns_ai_print): Use __dst for dns_strtype.
2150         (dns_strsection): Add an argument __dst for storage.
2151         (dns_strclass, dns_strtype): Likewise.
2152         (parse_packet): Use __dst for dns_strsection.
2153         (send_query): Use __dst for dns_strtype.
2154         (isection): Use __dst for dns_strsection.
2155         (iclass): Use __dst for dns_strclass.
2156         (itype): Use __dst for dns_strtype.
2157
2158 2020-05-12  Werner Koch  <wk@gnupg.org>
2159
2160         common: Change argument order of log_printhex.
2161         + commit c6324ee07a9ff2a626d6dfcc094a67b62628d42e
2162         * common/logging.c (log_printhex): Chnage order of args.  Make it
2163         printf alike.  Change all callers.
2164         * configure.ac: Add -Wno-format-zero-length
2165
2166 2020-04-16  Werner Koch  <wk@gnupg.org>
2167
2168         sm: Always allow authorityInfoAccess lookup if CRLs are also enabled.
2169         + commit aec7d136e4bdfd53709dc04e3e92f4c50135d368
2170         * sm/certchain.c (find_up): Disable external lookups in offline mode.
2171         Always allow AKI lookup if CRLs are also enabled.
2172
2173         sm: Lookup missing issuers first using authorityInfoAccess.
2174         + commit d57209553da7da85a369cd362aabeaef07e0bc26
2175         * sm/call-dirmngr.c (gpgsm_dirmngr_lookup): Add optional arg URL and
2176         adjust all callers.
2177         * sm/certchain.c (oidstr_caIssuers): New.
2178         (struct find_up_store_certs_s): Add additional fields.
2179         (find_up_store_certs_cb): Store the fingerprint.
2180         (find_up_via_auth_info_access): New.
2181         (find_up): Try the AIA URI first.
2182
2183         dirmngr: Allow http URLs with "LOOKUP --url"
2184         + commit 3b27c26241ee25cf75555e11d9bb463faac8237d
2185         * dirmngr/crlfetch.c (read_cert_via_http): New.
2186         (fetch_cert_by_url): Implement http scheme.
2187
2188         gpg: Add missing options --no-include-key-block.
2189         + commit 7dbfd92b3e231cfe111c8832ff1048305c8d2d92
2190         * g10/gpg.c (opts): Add it.
2191
2192         gpg: Make AEAD modes subject to compliance checks.
2193         + commit 37b116db20080f6e1c6ca1dec79014fecf2c3248
2194         * g10/decrypt-data.c (decrypt_data): Move aead algo detection up.
2195
2196         gpg: Show AEAD preferences.
2197         + commit ab7a0b07024c432233e691b5e4be7e32baf8d80f
2198         * g10/packet.h (preftype_t): Add PREFTYPE_AEAD.
2199         * g10/keyedit.c (show_prefs): Print AEAD preferences.
2200         * g10/getkey.c (fixup_uidnode): Set AEAD flags.
2201         (merge_selfsigs): Ditto.
2202
2203         gpg: Support decryption of the new AEAD packet.
2204         + commit 1dfe71c62b184c84723c5f926f2596f46ee967cf
2205         * common/openpgpdefs.h (aead_algo_t): New.
2206         (pkttype_t): Add PKT_ENCRYPTED_AEAD.
2207         * g10/decrypt-data.c (struct decode_filter_context_s): Add fields for
2208         AEAD.
2209         (aead_set_nonce_and_ad): New.
2210         (aead_checktag): New.
2211         (decrypt_data): Support AEAD.
2212         (aead_underflow): New.
2213         (aead_decode_filter): New.
2214         * g10/dek.h (DEK): Add field use_aead.  Turn use_mdc,
2215         algo_info_printed, and symmetric into bit flags.
2216         * g10/mainproc.c (struct mainproc_context): Add field
2217         seen_pkt_encrypted_aead.
2218         (release_list): Clear it.
2219         (have_seen_pkt_encrypted_aead): New.
2220         (symkey_decrypt_seskey): Support AEAD.
2221         (proc_symkey_enc): Ditto.
2222         (proc_encrypted): Ditto.
2223         (proc_plaintext): Ditto.
2224         * g10/misc.c (MY_GCRY_CIPHER_MODE_EAX): New.
2225         (openpgp_aead_test_algo): New.
2226         (openpgp_aead_algo_name): New.
2227         (openpgp_aead_algo_info): New.
2228         * g10/packet.h (PKT_symkey_enc): Add field use_aead.
2229         (PKT_user_id): Add field flags.aead
2230         (PKT_public_key): Ditto.
2231         (PKT_encrypted): Add fields for AEAD.
2232         * g10/parse-packet.c (parse): Handle PKT_ENCRYPTED_AEAD.
2233         (parse_symkeyenc): Support AEAD.
2234         (parse_encrypted): Ditto.
2235         (dump_sig_subpkt): Dump AEAD preference packet.
2236         (parse_encrypted_aead): New.
2237
2238 2020-04-15  Werner Koch  <wk@gnupg.org>
2239
2240         gpg: Improve symmetric decryption speed by about 25%
2241         + commit 144b95cc9d0f03a2fe5d91120f6b4b30f4bb8f71
2242         * g10/decrypt-data.c (mdc_decode_filter, decode_filter): Fatcor buffer
2243         filling code out to ...
2244         (fill_buffer): new.
2245
2246         gpg: Reformat parts of decrypt-data.c.
2247         + commit 2f39e00b6b7d2aa57cd268c579127947042a0fcf
2248         * g10/decrypt-data.c (struct decode_filter_context_s): Rename 'defer'
2249         to 'holdback' and 'defer_filled' to 'holdbacklen'.  Increase size of
2250         holdback to allow for future AEAD decryption.  Turn 'partial' and
2251         'eof_seen' into bit fields.
2252         (decrypt_data): Replace write_status_text by write_Status_printf.
2253         Indent parts of the code.
2254
2255         sm,dirmngr: Restrict allowed parameters used with rsaPSS.
2256         + commit ddc74f50d42370421b4802dc13df88f0ca2fcee5
2257         * sm/certcheck.c (extract_pss_params): Check the used PSS params.
2258         * dirmngr/crlcache.c (finish_sig_check): Ditto.
2259         * dirmngr/validate.c (check_cert_sig): Ditto.
2260
2261         sm: Support rsaPSS verification also for CMS signatures.
2262         + commit 24d563749f50f51841b3fd00eb615a871e45bb28
2263         * sm/certcheck.c (gpgsm_check_cert_sig): Factor PSS parsing out to ...
2264         (extract_pss_params): new.
2265         (gpgsm_check_cms_signature): Implement PSS.
2266
2267         dirmngr: Support rsaPSS also in the general validate module.
2268         + commit 8bf17eb94d0d85f34477ec0c2c0514000b6aa045
2269         * dirmngr/validate.c (hash_algo_from_buffer): New.
2270         (uint_from_buffer): New.
2271         (check_cert_sig): Support rsaPSS.
2272         * sm/certcheck.c (gpgsm_check_cert_sig): Fix small memory leak on
2273         error.
2274
2275         sm,dirmngr: Support rsaPSS signature verification.
2276         + commit 0626cc8fed340deb36f0c10e7a68afc287d0f626
2277         * sm/certcheck.c (hash_algo_from_buffer): New.
2278         (uint_from_buffer): New.
2279         (gpgsm_check_cert_sig): Handle PSS.
2280         * dirmngr/crlcache.c (hash_algo_from_buffer): New.
2281         (uint_from_buffer): New.
2282         (start_sig_check): Detect PSS and extract hash algo.  New arg to
2283         return a PSS flag.
2284         (finish_sig_check): New arg use_pss.  Extract PSS args and use them.
2285         (crl_parse_insert): Pass use_pss flag along.
2286
2287         common: New function to map hash algo names.
2288         + commit 4d37cc72b83f601118c2c6c79d9d96c85e250f7e
2289         * common/sexputil.c (hash_algo_to_string): New.
2290
2291         scd:p15: Return a display S/N via Assuan.
2292         + commit 39e2260d7e05ef2fd6ff94a1bc538cf0d640193c
2293         * scd/app-p15.c (make_pin_prompt): Factor some code out to ...
2294         (get_dispserialno): this.
2295         (do_getattr): Use new fucntion for a $DISPSERIALNO.
2296
2297         scd:p15: Show a pretty PIN prompt.
2298         + commit beaa2cbb7f039c6ebfcfff483cfe6002a858993d
2299         * scd/app-p15.c (struct prkdf_object_s): New fields common_name and
2300         serial_number.
2301         (release_prkdflist): Free them.
2302         (keygrip_from_prkdf): Parse cert and set them.
2303         (any_control_or_space): New.
2304         (make_pin_prompt): New.
2305         (verify_pin): Construct a pretty PIN prompt.
2306         (do_sign): Remove debug output.
2307
2308         scd: Return GPG_ERR_BAD_PIN on 0x63Cn status word.
2309         + commit 9e6a3290dad1b19144a2b413902e9918094a2cea
2310         * scd/iso7816.c (map_sw): Detect 0x63Cn status code.
2311
2312         scd: Factor common PIN status check out.
2313         + commit 9497d25c567d4fb8b6be603b102a149060e7aa56
2314         * scd/iso7816.h (ISO7816_VERIFY_ERROR): New.
2315         (ISO7816_VERIFY_NO_PIN): New.
2316         (ISO7816_VERIFY_BLOCKED): New.
2317         (ISO7816_VERIFY_NULLPIN): New.
2318         (ISO7816_VERIFY_NOT_NEEDED): New.
2319         * scd/iso7816.c (iso7816_verify_status): New.
2320         * scd/app-nks.c (get_chv_status): Use new function.
2321
2322         scd:p15: Fix decrypt followed by sign problem for D-Trust cards.
2323         + commit 471b06e91b6ae47e1f71cd7a698763cd9d32ff12
2324         * scd/iso7816.c (iso7816_select_mf): New.
2325         * scd/app-p15.c (card_product_t): New.
2326         (struct app_local_s): Add field 'card_product'.
2327         (read_ef_tokeninfo): Detect D-Trust card.
2328         (prepare_verify_pin): Switch to D-Trust AID.
2329         (do_decipher): Restore a SE for D-TRust cards.  Change the padding
2330         indicator to 0x81.
2331
2332         * common/percent.c (percent_data_escape): new.  Taken from master.
2333
2334         scd:p15: Emit MANUFACTURER, $ENCRKEYID, $SIGNKEYID.
2335         + commit 4148976841d154c94e6d1d4dcc1720908582086b
2336         * scd/app-p15.c (read_ef_tokeninfo): Store manufacturer_id.
2337         (do_getattr): Implement MANUFACTURER, $ENCRKEYID and $SIGNKEYID.
2338         (send_keypairinfo): Also print usage flags.
2339
2340         gpg: Use the new MANUFACTURER attribute.
2341         + commit 88b456bdf4e4763e8f1b718f5597d4d075d989cd
2342         * g10/call-agent.h (struct agent_card_info_s): Add manufacturer fields.
2343         * g10/call-agent.c (agent_release_card_info): Release them.
2344         (learn_status_cb): Parse MANUFACTURER attribute.
2345         * g10/card-util.c (get_manufacturer): Remove.
2346         (current_card_status): Use new attribute.
2347
2348         scd:openpgp: New attribute "MANUFACTURER".
2349         + commit 431b3e68e071d2bdc22b2c845ca929182830ddbd
2350         * scd/app-openpgp.c (get_manufacturer): New..
2351         (do_getattr): Add new attribute "MANUFACTURER".
2352         (do_learn_status): Always print it.
2353
2354         scd:p15: Rename some variables and functions for clarity.
2355         + commit b0cb2c2ab8c71738167785564698c43b50c15fee
2356         * scd/app-p15.c: Rename keyinfo to prkdf.
2357
2358
2359         Backported from master.  Removed the do_with_keygrip related parts
2360         because that function is not available.
2361
2362         scd:p15: Cache the PIN.
2363         + commit 133b6ff8cd0c938abbf55ba6dc50299240d247f6
2364         * scd/app-p15.c (struct prkdf_object_s): Add flag pin_verified.
2365         (verify_pin): Make use of it.
2366
2367 2020-04-08  NIIBE Yutaka  <gniibe@fsij.org>
2368
2369         gpg: ECDH: Accept longer padding.
2370         + commit 2f08a4f25df7d1cbf037bdf0d7f5c1ef5859fa1e
2371         * g10/pubkey-enc.c (get_it): Remove check which mandates shorter
2372         padding.
2373
2374 2020-04-01  Werner Koch  <wk@gnupg.org>
2375
2376         scd:p15: Add missing keygrip retrieval for decryption.
2377         + commit b95a0bfbba75025761aa163eca74c7653d76981a
2378         * scd/app-p15.c (do_decipher): Get the keygrip.
2379
2380         scd:p15: Support decryption with CardOS 5 cards.
2381         + commit 4af38ea5e450b3eb79af98b9876b2b968110a459
2382         * scd/app-p15.c (do_decipher): New.
2383
2384         scd:p15: Factor PIN verification out to a new function.
2385         + commit ce9406ca370b482c05c859d963949ae75c99cb6f
2386         * scd/app-p15.c (do_sign): Factor code out to ...
2387         (prepare_verify_pin, verify_pin): new functions.
2388
2389         scd:p15: Support signing with CardOS 5 cards.
2390         + commit e730444e7b7502b935bbe343935f68f764b95b96
2391         * scd/app-help.c (app_help_get_keygrip_string_pk): Add optional arg
2392         r_pkey and change all callers.
2393         (app_help_get_keygrip_string): Ditto.
2394         * scd/app-p15.c (struct cdf_object_s): Use bit flags
2395         (struct aodf_object_s): Ditto.  Add field 'fid'.
2396         (struct prkdf_object_s): Ditto.  Add fields keygrip, keyalgo, and
2397         keynbits.
2398         (parse_certid): Allow a keygrip instead of a certid aka keyref.
2399         (read_ef_aodf): Store the FID.
2400         (keygripstr_from_prkdf): Rename to ...
2401         (keygrip_from_prkdf): this.  Remove arg r_gripstr and implement cache.
2402         Change callers to directly use the values from the object.  Also store
2403         the algo and length of the key ion the object.
2404         (keyref_from_keyinfo): New. Factored out code.
2405         (do_sign): Support SHA-256 and >2048 bit RSA keys.
2406         common/scd:p15: Support signing with CardOS 5 cards.
2407         * common/util.h (KEYGRIP_LEN): New.
2408
2409         scd:p15: Read certificates in extended mode.
2410         + commit 368f006a2840cd6b37caf7b4b98a16b818ac2289
2411         * scd/app-p15.c (readcert_by_cdf): Allow reading in extended mode.
2412         * scd/app-common.h (app_get_slot): New.
2413
2414         scd: Add function for binary read in extended mode.
2415         + commit 64142caafe5c89ad4db36b47c2dc917a9ac66a8e
2416         * scd/iso7816.c (iso7816_read_binary): Factor code out to ...
2417         (iso7816_read_binary_ext): new function.  Add arg extended_mode.
2418
2419         scd:p15: Detect CardOS 5 cards and print some basic infos.
2420         + commit 60b0aa7e57e787cbeca22adf77b330f753553d87
2421         * scd/app-p15.c (read_ef_odf): Detect the home_DF on the fly.  Silence
2422         the garbage warning for null bytes.
2423         (print_tokeninfo_tokenflags): New.
2424         (read_ef_tokeninfo): Print manufacturer, label, and flags.
2425         (app_select_p15): No need to use the app_get_slot macro.
2426         (CARD_TYPE_CARDOS_50): New const.
2427         (card_atr_list): Detect CardOS 5.0
2428
2429 2020-03-30  Werner Koch  <wk@gnupg.org>
2430
2431         wks: Take name of sendmail from configure.
2432         + commit 76d2a02dfe8f923c0d4d8ef86ca71a9ac47c243d
2433         * configure.ac (NAME_OF_SENDMAIL): New ac_define.
2434         * tools/send-mail.c (run_sendmail): Use it.
2435
2436         agent: Print an error if gpg-protect reads the extended key format.
2437         + commit 011a2f5fb77c7963f25550e423160507818f7a91
2438         * agent/protect-tool.c (read_key): Detect simple extended key format.
2439
2440         sm: Fix possible NULL deref in error messages of --gen-key.
2441         + commit 2b4b0b1223aab955aafa2a150fe2dbc04c210bcd
2442         * sm/certreqgen.c: Protect printing the line numbers in case of !R.
2443
2444 2020-03-27  Werner Koch  <wk@gnupg.org>
2445
2446         sm: Consider certificates w/o CRL DP as valid.
2447         + commit 1424c12e4c7164990797a0a1daa3db6f3329aed4
2448         * sm/certchain.c (is_cert_still_valid): Shortcut if tehre is no DP.
2449         * common/audit.c (proc_type_verify): Print "n/a" if a cert has no
2450         distribution point.
2451         * sm/gpgsm.h (opt): Add field enable_issuer_based_crl_check.
2452         * sm/gpgsm.c (oEnableIssuerBasedCRLCheck): New.
2453         (opts): Add option --enable-issuer-based-crl-check.
2454         (main): Set option.
2455
2456 2020-03-20  Werner Koch  <wk@gnupg.org>
2457
2458         Release 2.2.20.
2459         + commit 5094bb08edd48087a5aa89494fc361f0ce4f34aa
2460         * build-aux/speedo.mk (sign-installer): Fix syntax error.
2461
2462 2020-03-19  Werner Koch  <wk@gnupg.org>
2463
2464         gpgconf: Take care of --homedir when reading/updating options.
2465         + commit b92860a8b9d253661de0060623e920b3f58e4443
2466         * tools/gpgconf-comp.c (gc_component_check_options): Take care of
2467         --homedir.
2468         (retrieve_options_from_program): Ditto.
2469
2470 2020-03-18  NIIBE Yutaka  <gniibe@fsij.org>
2471
2472         scd: Fix pinpad handling when KDF enabled.
2473         + commit 133248b297a1d72897f280d8bd21081cd6ebd66c
2474         * scd/app-openpgp.c (do_getattr): Send the KDF DO information.
2475
2476         scd: Disable pinpad if it's impossible by KDF DO.
2477         + commit b27e20a95cb7af59dcaa6e59aacf52ed766be1f3
2478         * scd/app-openpgp.c (struct app_local_s): Add pinpad.disabled field.
2479         (do_getattr): Set pinpad.disabled field.
2480         (check_pinpad_request): Use the pinpad.disabled field.
2481         (do_setattr): Update pinpad.disabled field.
2482
2483 2020-03-18  Werner Koch  <wk@gnupg.org>
2484
2485         gpg: Print a hint for --batch mode and --delete-secret-key.
2486         + commit fbe318475236166b54e19d228bf9b24e442e0fa5
2487         * g10/delkey.c: Include shareddefs.h.
2488         (delete_keys): Print a hint.
2489
2490         dirmngr: Improve finding OCSP cert.
2491         + commit 25dc0e5b1eb02f79946a86c799c7720001a296bc
2492         * dirmngr/certcache.c (find_cert_bysubject): Add better debug output
2493         and try to locate by keyid.
2494
2495 2020-03-18  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
2496
2497         gpg: Update --trusted-key to accept fingerprint as well as long key id.
2498         + commit b6d89d1944c55f302fb797cce0e007f59aabaf54
2499         * g10/trustdb.c (tdb_register_trusted_key): accept fingerprint as well
2500         as long key ID.
2501         * doc/gpg.texi: document that --trusted-key can accept a fingerprint.
2502
2503 2020-03-18  Werner Koch  <wk@gnupg.org>
2504             gniibe@fsij.org
2505
2506         gpg: Fix key expiration and usage for keys created at the Epoch.
2507         + commit e77f332b01f13af606ae0158dabcd644c274e456
2508         * g10/getkey.c (merge_selfsigs_main): Take a zero key creation time in
2509         account.
2510
2511 2020-03-14  Werner Koch  <wk@gnupg.org>
2512
2513         gpg: New option --auto-key-import.
2514         + commit 95b42278cafe7520d87168fb993ba715699e6bb6
2515         * g10/gpg.c (opts): New options --auto-key-import,
2516         --no-auto-key-import, and --no-include-key-block.
2517         (gpgconf_list): Add them.
2518         * g10/options.h (opt): Add field flags.auto_key_import.
2519         * g10/mainproc.c (check_sig_and_print): Use flag to enable that
2520         feature.
2521         * tools/gpgconf-comp.c: Give the new options a Basic config level.
2522
2523         gpg: Make use of the included key block in a signature.
2524         + commit b42d9f540c7484e45cfc997f77e360d0f0ec4bb9
2525         * g10/import.c (read_key_from_file): Rename to ...
2526         (read_key_from_file_or_buffer): this and add new parameters.  Adjust
2527         callers.
2528         (import_included_key_block): New.
2529         * g10/packet.h (PKT_signature): Add field flags.key_block.
2530         * g10/parse-packet.c (parse_signature): Set that flags.
2531         * g10/sig-check.c (check_signature2): Add parm forced_pk and change
2532         all callers.
2533         * g10/mainproc.c (do_check_sig): Ditto.
2534         (check_sig_and_print): Try the included key block if no key is
2535         available.
2536
2537         gpg: New option --include-key-block.
2538         + commit d79ebee64ea582da3c3be69cc23e146e2db3738b
2539         * common/openpgpdefs.h (SIGSUBPKT_KEY_BLOCK): New.
2540         * g10/gpg.c (oIncludeKeyBlock): New.
2541         (opts): New option --include-key-block.
2542         (main): Implement.
2543         * g10/options.h (opt): New flag include_key_block.
2544         * g10/parse-packet.c (dump_sig_subpkt): Support SIGSUBPKT_KEY_BLOCK.
2545         (parse_one_sig_subpkt): Ditto.
2546         (can_handle_critical): Ditto.
2547         * g10/sign.c (mk_sig_subpkt_key_block): New.
2548         (write_signature_packets): Call it for data signatures.
2549
2550         gpg: Add property "fpr" for use by --export-filter.
2551         + commit 2baa00ea186359f758fea5cb61aff99b09fec821
2552         * g10/export.c (push_export_filters): New.
2553         (pop_export_filters): New.
2554         (export_pubkey_buffer): Add args prefix and prefixlen.  Adjust
2555         callers.
2556         * g10/import.c (impex_filter_getval): Add property "fpr".
2557         * g10/main.h (struct impex_filter_parm_s): Add field hexfpr.
2558
2559 2020-02-19  NIIBE Yutaka  <gniibe@fsij.org>
2560
2561         gpg: Fix default-key selection when card is available.
2562         + commit 1cdd9e57f701f0d99d118d32adffe5216a94b0b2
2563         * g10/getkey.c (get_seckey_default_or_card): Handle the case
2564         when card key is not suitable for requested usage.
2565
2566 2020-02-19  Nick Piper  <nick.piper@cgi.com>
2567
2568         doc: Correction of typo in documentation of KEY_CONSIDERED.
2569         + commit 60dbe082949b13635f3f31aa03d12aa9f671c941
2570         (cherry picked from commit 0e1cbabc0ad4fe2ca9644fffb5cf27b1a8a1509f)
2571
2572 2020-02-15  Werner Koch  <wk@gnupg.org>
2573
2574         gpgsm: Fix import of some CR,LF ternminated certificates.
2575         + commit 38f819bd6d77d068d8626bf7f5b968ff03c263af
2576         * common/ksba-io-support.c (base64_reader_cb): Detect the END tag and
2577         don't just rely on the padding chars.  This could happen only with
2578         CR+LF termnmated PEM files.  Also move the detection into the invalid
2579         character detection branch for a minor parser speedup.
2580
2581 2020-02-10  Werner Koch  <wk@gnupg.org>
2582
2583         doc: Improve the warning section of the gpg man page.
2584         + commit 146dacd3b13bf5d917978313092c022641305a27
2585         * doc/gpg.texi: Update return value and warning sections.
2586
2587         (cherry picked from commit 113a8288b85725f7726bb2952431deea745997d8)
2588
2589 2020-02-10  Werner Koch  <wk@gnupg.org>
2590             Tomáš Mráz
2591
2592         build: Always use EXTERN_UNLESS_MAIN_MODULE pattern.
2593         + commit 21d9bd8b87a9f793a106095e3838eb71825189d7
2594         * common/util.h (EXTERN_UNLESS_MAIN_MODULE): Add the definion only
2595         here but now without the Norcroft-C.  Change all other places where it
2596         gets defined.
2597         * common/iobuf.h (iobuf_debug_mode): Declare unconditionally as
2598         extern.
2599         * common/iobuf.c (iobuf_debug_mode): Define it here.
2600         * agent/gpg-agent.c (INCLUDED_BY_MAIN_MODULE): Define here and also in
2601         all main modules of all other programs.
2602
2603         * g10/main.h: Put util.h before the local header files.
2604
2605 2020-02-10  Werner Koch  <wk@gnupg.org>
2606
2607         gpg: Make really sure that --verify-files always returns an error.
2608         + commit 49151255f3b1decf2e394a58bc0ac412bda2b214
2609         * g10/verify.c (verify_files): Track the first error code.
2610
2611         common: Also protect log_inc_errorcount against counter overflow.
2612         + commit 47f514fde6e29137d660c19e6eea0b842d2b03f5
2613         * common/logging.c (log_inc_errorcount): Also protect against
2614         overflow.
2615         (log_error): Call log_inc_errorcount instead of directly bumping the
2616         counter.
2617
2618 2020-01-17  Werner Koch  <wk@gnupg.org>
2619
2620         gpgconf,w32: Print a warning for a suspicious homedir.
2621         + commit a265d3997a9120cb607c2d9b843bf9ee9e944378
2622         * tools/gpgconf.c (list_dirs): Check whether the homedir has been
2623         taken from the registry.
2624
2625 2020-01-16  NIIBE Yutaka  <gniibe@fsij.org>
2626
2627         gpg: default-key: Simply don't limit by capability.
2628         + commit a7840777e4277039482ce3ea3e6fc919526be2f1
2629         * g10/getkey.c (parse_def_secret_key): Remove the check.
2630
2631 2019-12-23  Werner Koch  <wk@gnupg.org>
2632
2633         gpg: Fix output of --with-secret if a pattern is given.
2634         + commit def1ceccf05baf187b9313e6e37171709ab44225
2635         * g10/keylist.c (list_one): Probe for a secret key in --with-secret
2636         mode.
2637
2638 2019-12-19  Andre Heinecke  <aheinecke@gnupg.org>
2639
2640         speedo: Make signing optional for w32-release.
2641         + commit a56c591f9063d895544d681e25bda2ffb22f7ca0
2642         * build-aux/speedo.mk (AUTHENTICODE_sign): Check if
2643         certificates are available.
2644
2645         speedo: Use multithreaded xz for w32 source.
2646         + commit 28403cb5fe4eea2ac1ad514fdfcfa282e795c69f
2647         * build-aux/speedo.mk (dist-source): Add -T0 parameter to xz.
2648
2649         speedo: Improve and document wixlib build.
2650         + commit 4d9b262584fb15e7965d579fad9a149e26849c18
2651         * Makefile.am (sign-release): Add handling for wixlib.
2652         * build-aux/speedo.mk: Add help-wixlib and improve handling.
2653
2654 2019-12-17  Andre Heinecke  <aheinecke@intevation.de>
2655
2656         speedo, w32: Add w32-wixlib target for MSI package.
2657         + commit c461de93f44efaa6a1d9669eb9d4033943368431
2658         * Makefile.am (EXTRA_DIST): Add wixlib.wxs
2659         * build-aux/speedo.mk (w32-wixlib): New target.
2660         (w32-release): Build wixlib if WIXPREFIX is set.
2661         (help): Add documentation.
2662         * build-aux/speedo/w32/wixlib.wxs
2663
2664 2019-12-07  Werner Koch  <wk@gnupg.org>
2665
2666         Release 2.2.19.
2667         + commit 1c841c8389fb9640762822395b988e0d1584c9ae
2668
2669
2670         po: Make g10/call-dirmngr.c translatable.
2671         + commit 03983711b3376a5dff518a99adf5fb3a5bd8be4a
2672         * po/POTFILES.in: Add g10/call-dirmngr.c
2673         * g10/call-dirmngr.c (create_context): Change an i18n sting for easier
2674         reuse.
2675
2676         dirmngr: Tell gpg about WKD lookups resulting from a cache.
2677         + commit 438a1ec2978c64ecfe6b5ddaa61f214c2dcae88f
2678         * dirmngr/server.c (proc_wkd_get): Print new NOTE status
2679         "wkd_cached_result".
2680         * g10/call-dirmngr.c (ks_status_cb): Detect this and print a not ein
2681         verbose mode.
2682
2683 2019-12-06  Werner Koch  <wk@gnupg.org>
2684
2685         sm: Add special case for expired intermediate certificates.
2686         + commit 8c167febc0abc00be281a9dc8c2544b8d048a002
2687         * sm/gpgsm.h (struct server_control_s): Add field 'current_time'.
2688         * sm/certchain.c (find_up_search_by_keyid): Detect a corner case.
2689         Also simplify by using ref-ed cert objects in place of an anyfound
2690         var.
2691
2692 2019-12-04  Werner Koch  <wk@gnupg.org>
2693
2694         gpg: Use AKL for angle bracketed mail address with -r.
2695         + commit 78bb81e9deeca264f6a516630496470341e78fa9
2696         * g10/getkey.c (get_pubkey_byname): Extend is_mbox checking.
2697         (get_best_pubkey_byname): Ditto.
2698
2699 2019-11-29  Werner Koch  <wk@gnupg.org>
2700
2701         gpg: Fix double free with anonymous recipients.
2702         + commit 9ac182f376abf910a7b737b0e1ebd447eaa582f1
2703         * g10/pubkey-enc.c (get_session_key): Do not release SK.
2704
2705 2019-11-25  Werner Koch  <wk@gnupg.org>
2706
2707         Release 2.2.18.
2708         + commit 82b9e1bdbdd756290b8873b3e244dcc8d1f840fb
2709
2710
2711         tests: Adjust for now invalid SHA-1 key signatures.
2712         + commit 8e49fc7f43ecfe44dac57d97c555e2cbc7eb8e9a
2713         * tests/openpgp/defs.scm (create-gpghome): Add
2714         allow-weak-key-signatures.
2715
2716         agent: Improve --debug-pinentry diagnostics.
2717         + commit 96c4943a5bd070772d8be7bb7db8548840af5f8f
2718         * agent/call-pinentry.c (atfork_cb): Factor code out to ...
2719         (atfork_core): new.
2720
2721 2019-11-23  Werner Koch  <wk@gnupg.org>
2722
2723         wkd: Let --install-key write a template policy file.
2724         + commit 6e893061b54ddd38e83531f5513e3168d0002e41
2725         * tools/wks-util.c (ensure_policy_file): New.
2726         (wks_cmd_install_key): Call it.
2727
2728 2019-11-18  Werner Koch  <wk@gnupg.org>
2729
2730         dirmngr,gpg: Better diagnostic in case of bad TLS certificates.
2731         + commit 3efc94f1eb17eb5c5950c2fab9f701518352ae19
2732         * doc/DETAILS: Specify new status code "NOTE".
2733         * dirmngr/ks-engine-http.c (ks_http_fetch): Print a NOTE status for a
2734         bad TLS certificate.
2735         * g10/call-dirmngr.c (ks_status_cb): Detect this status.
2736
2737         dirmngr: Forward http redirect warnings to gpg.
2738         + commit 4dd50991252409eb2023ab8ad11f36a050f421af
2739         * dirmngr/http.c: Include dirmngr-status.h
2740         (http_prepare_redirect): Emit WARNING status lines for redirection
2741         problems.
2742         * dirmngr/http.h: Include fwddecl.h.
2743         (struct http_redir_info_s): Add field ctrl.
2744         * dirmngr/ks-engine-hkp.c (send_request): Set it.
2745         * dirmngr/ks-engine-http.c (ks_http_fetch): Set it.
2746         * g10/call-dirmngr.c (ks_status_cb): Detect the two new warnings.
2747
2748         dirmngr: Factor some prototypes out to dirmngr-status.h.
2749         + commit 466bdf7c07f4ebfc69d503f85b9423f2f6440682
2750         * dirmngr/dirmngr-status.h: New.
2751         * dirmngr/dirmngr.h: Include dirmngr-status.h and move some prototypes
2752         to that file.
2753         * dirmngr/t-support.c: New.
2754         * dirmngr/Makefile.am (t_common_src): Add new file.
2755
2756 2019-11-15  NIIBE Yutaka  <gniibe@fsij.org>
2757
2758         scd,ccid: Add support of GEMPC_EZIO.
2759         + commit 9b41f58c8a549055fa6bf7e21e2931b86f4da776
2760         * scd/ccid-driver.h (GEMPC_EZIO): New.
2761         * scd/ccid-driver.c (ccid_transceive_secure): Support GEMPC_EZIO.
2762
2763 2019-11-12  Werner Koch  <wk@gnupg.org>
2764
2765         dirmngr: Use IPv4 or IPv6 interface only if available.
2766         + commit 392e068e9f143d41f6350345619543cbcd47380f
2767         * dirmngr/dns-stuff.c (cached_inet_support): New variable.
2768         (dns_stuff_housekeeping): New.
2769         (check_inet_support): New.
2770         * dirmngr/http.c (connect_server): Use only detected interfaces.
2771         * dirmngr/dirmngr.c (housekeeping_thread): Flush the new cache.
2772
2773 2019-11-11  Werner Koch  <wk@gnupg.org>
2774
2775         gpg: Forbid the creation of SHA-1 third-party key signatures.
2776         + commit 754a03f5a279964af62025d11d92391e650fddb7
2777         * g10/sign.c (SIGNHINT_KEYSIG, SIGNHINT_SELFSIG): New.
2778         (do_sign): Add arg signhints and inhibit SHA-1 signatures.  Change
2779         callers to pass 0.
2780         (complete_sig): Add arg signhints and pass on.
2781         (make_keysig_packet, update_keysig_packet): Set signhints.
2782
2783         gpg: Add option --allow-weak-key-signatures.
2784         + commit 3b1fcf65239d9c73cc54760ea52a5749e024fa76
2785         * g10/gpg.c (oAllowWeakKeySignatures): New.
2786         (opts): Add --allow-weak-key-signatures.
2787         (main): Set it.
2788         * g10/options.h (struct opt): Add flags.allow_weak_key_signatures.
2789         * g10/misc.c (print_sha1_keysig_rejected_note): New.
2790         * g10/sig-check.c (check_signature_over_key_or_uid): Print note and
2791         act on new option.
2792
2793 2019-11-07  Werner Koch  <wk@gnupg.org>
2794
2795         gpg: Fix a potential loss of key sigs during import with self-sigs-only.
2796         + commit 2975868ede40ce8b8a0d20e7f0e4cd687772f9d0
2797         * g10/import.c (import_one_real): Don't do the final clean in the
2798         merge case.
2799
2800 2019-10-15  Werner Koch  <wk@gnupg.org>
2801
2802         gpg: Also delete key-binding signature when deleting a subkey.
2803         + commit d8052db74a0d2e6a55cf104e0ecb1868936bd09c
2804         * g10/delkey.c (do_delete_key): Simplify and correct subkey deletion.
2805
2806 2019-10-15  NIIBE Yutaka  <gniibe@fsij.org>
2807
2808         Revert "gpg: The first key should be in candidates."
2809         + commit 2906636b929f08fdf342560834d920e8e8153458
2810         This reverts commit 66eb953f43800a91c4280ae8fd49f6dc8cf74578.
2811
2812 2019-10-15  Werner Koch  <wk@gnupg.org>
2813
2814         gpg: Extend --quick-gen-key for creating keys from a card.
2815         + commit 652ca4b2bf985546baa70754f66eab3840cf2820
2816         * g10/keygen.c (parse_key_parameter_part): Add arg R_KEYGRIP and
2817         support the special algo "card".
2818         (parse_key_parameter_string): Add args R_KEYGRIP and R_SUBKEYGRIP.
2819         Handle the "card" algo.  Adjust callers.
2820         (parse_algo_usage_expire): Add arg R_KEYGRIP.
2821         (quickgen_set_para): Add arg KEYGRIP and put it into the parameter
2822         list.
2823         (quick_generate_keypair): Handle algo "card".
2824         (generate_keypair): Also handle the keygrips as returned by
2825         parse_key_parameter_string.
2826         (ask_algo): Support ed25519 from a card.
2827
2828 2019-10-15  NIIBE Yutaka  <gniibe@fsij.org>
2829
2830         po: Update Japanese translation.
2831         + commit fe02709ffd3c41fe84b90cda96edd12e6b836741
2832
2833
2834         gpg: The first key should be in candidates.
2835         + commit 66eb953f43800a91c4280ae8fd49f6dc8cf74578
2836         * g10/getkey.c (get_best_pubkey_byname): Handle the first key
2837         as the initial candidate for the selection.
2838
2839         gpg: Fix a memory leak in get_best_pubkey_byname.
2840         + commit 2924ac374eb8cbf87ed6c9fbbb72c0b8d1d37fa3
2841         * g10/getkey.c (get_best_pubkey_byname): Free the public key parts.
2842
2843 2019-10-03  Werner Koch  <wk@gnupg.org>
2844
2845         gpg: Be prepared for chosen-prefix SHA-1 collisions in key signatures.
2846         + commit edc36f59fcfcb4b896a53530345d586f7e5df560
2847         * g10/sig-check.c (check_signature_over_key_or_uid): Reject cewrtain
2848         SHA-1 based signatures.
2849
2850 2019-09-06  Werner Koch  <wk@gnupg.org>
2851
2852         gpg: Make --quiet work on --send-keys.
2853         + commit de57b5bf91d64f8843a68d1950bd12aecc82f8c1
2854         * g10/keyserver.c (keyserver_put): Act upon --quiet.
2855
2856 2019-08-23  Werner Koch  <wk@gnupg.org>
2857
2858         gpg: Implement keybox compression run.
2859         + commit b5f7ac6c368a07b3d35191bf56fdf58145c4e44b
2860         * kbx/keybox-init.c (keybox_lock): Add arg TIMEOUT and change all
2861         callers to pass -1.
2862         * g10/keydb.c (keydb_add_resource): Call keybox_compress.
2863
2864         kbx: Include deleted records into the --stats output.
2865         + commit 34f55c5e348d4bf9894c24988e6856b411ba05de
2866         * kbx/keybox-dump.c (_keybox_dump_file): Take deleted records in
2867         account.
2868
2869         kbx: Allow "gpgsm --faked-system-time" to kick off a compression run.
2870         + commit e854580fa562c423f3d977318b515fb4d186f99a
2871         * kbx/keybox-update.c (keybox_compress): Use make_timestamp.
2872
2873         gpg: Allow --locate-external-key even with --no-auto-key-locate.
2874         + commit df6cff8233aa281d150861a26cd262a8a15c73e7
2875         * g10/getkey.c (akl_empty_or_only_local): New.
2876         * g10/gpg.c (DEFAULT_AKL_LIST): New.
2877         (main): Use it here.
2878         (main) <aLocateExtKeys>: Set default AKL if none is set.
2879
2880         gpg: Silence some warning messages during -Kv.
2881         + commit 589f1187137cb14da1d16be1fdaf8f1ac2c2d436
2882         * g10/options.h (glo_ctrl): Add flag silence_parse_warnings.
2883         * g10/keylist.c (list_all): Set that during secret key listsings.
2884         * g10/parse-packet.c (unknown_pubkey_warning): If new flag is set do
2885          not print info message normally emitted inh verbose mode.
2886         (can_handle_critical_notation, enum_sig_subpkt): Ditto.
2887         (parse_signature, parse_key, parse_attribute_subpkts): Ditto.
2888
2889         gpg: Do not show an informational diagnostics with quiet.
2890         + commit 215858aba342e6f2b9a7c93f579638279af3a561
2891         * g10/trustdb.c (verify_own_keys): Silence informational diagnostic.
2892
2893         gpgconf: Suggest the use of --gpgconf-test on --launch problems.
2894         + commit 7c386c5fb5aebbbb36daf61c25d20e6888123994
2895         * tools/gpgconf-comp.c (gc_component_launch): Change suggestion.
2896
2897 2019-08-21  Werner Koch  <wk@gnupg.org>
2898
2899         scd:nks: Extend keypairinfo with usage flags.
2900         + commit 0a9053eff0406c6799ee201013194200c0ed3487
2901         * scd/app-nks.c (do_learn_status_core): Return usage.
2902
2903         scd:openpgp: Extend keypairinfo with usage flags.
2904         + commit 6f67abcc0339b42a181285b3416959c39a2d7808
2905         * scd/app-openpgp.c (send_keypair_info): Return usage.
2906
2907         sm: Show the usage flags when generating a key from a card.
2908         + commit a8aacaf2042a72760e6eaf35e65bfd6d42e642f0
2909         * g10/call-agent.c (scd_keypairinfo_status_cb): Also store the usage
2910         flags.
2911         * sm/call-agent.c (scd_keypairinfo_status_cb): Ditto.
2912         * sm/certreqgen-ui.c (gpgsm_gencertreq_tty): Print the usage flags.
2913
2914         (cherry picked from commit 9ed1aa56c4bbf44e00b731d6807ada9e95c91bd7)
2915
2916         gpg: Allow decryption using non-OpenPGP cards.
2917         + commit 9a317557c58d2bdcc504b70c366b77f4cac71df7
2918         * g10/call-agent.c (struct getattr_one_parm_s): New.
2919         (getattr_one_status_cb): New.
2920         (agent_scd_getattr_one): New.
2921         * g10/pubkey-enc.c (get_it): Allow the standard leading zero byte from
2922         pkcs#1.
2923         * g10/getkey.c (enum_secret_keys): Move to...
2924         * g10/skclist.c (enum_secret_keys): here and handle non-OpenPGP cards.
2925
2926         scd: New standard attributes $ENCRKEYID and $SIGNKEYID.
2927         + commit 23784f8bf0ac6d6c52cb2de2f99f46017a92c11a
2928         * g10/call-agent.c (agent_scd_keypairinfo): Use --keypairinfo.
2929         * sm/call-agent.c (gpgsm_agent_scd_keypairinfo): Ditto.
2930         * scd/app-openpgp.c (do_getattr): Add attributes "$ENCRKEYID" and
2931         "$SIGNKEYID".
2932         * scd/app-nks.c (do_getattr): Add attributes too.
2933
2934         gpg: Allow direct key generation from card with --full-gen-key.
2935         + commit fbed618a3699bea131ce36949387af0fa3cf13f9
2936         * g10/call-agent.c (agent_scd_readkey): New.
2937         * g10/keygen.c (ask_key_flags): Factor code out to ..
2938         (ask_key_flags_with_mask): new.
2939         (ask_algo): New mode 14.
2940
2941         common: Extend function pubkey_algo_string.
2942         + commit 0353cb0a5edeef07330da1688b7801c073959185
2943         * common/sexputil.c (pubkey_algo_string): Add arg R_ALGOID.
2944         * sm/certreqgen-ui.c (gpgsm_gencertreq_tty): Adjust.
2945
2946         (cherry picked from commit f952226043824cbbeb8517126b5266926121c4e8)
2947
2948         Removed the changes in gpg-card which is not part of 2.2
2949
2950         gpg: New option --use-only-openpgp-card.
2951         + commit c185f6dfbd1bfd809369da789239a371e9d1610e
2952         * g10/gpg.c (opts): Add option.
2953         (main): Set flag.
2954         * g10/options.h: Add flags.use_only_openpgp_card.
2955         * g10/call-agent.c (start_agent): Implement option.
2956
2957         gpg: Prepare card code to allow other than OpenPGP cards.
2958         + commit fe5c8de862885c51d27c2dc9ea237846c5e57e8a
2959         * g10/call-agent.c (start_agent): Use card app auto selection.
2960         * g10/card-util.c (current_card_status): Print the Application type.
2961         (card_status): Put empty line between card listings.
2962
2963         (cherry picked from commit e47524c34a2a9f53c2507f67a0b41b460cee78b7)
2964
2965         gpg: New card function agent_scd_keypairinfo.
2966         + commit 768cb6402f2941781262b9cb0a2aeecc89941f0f
2967         * g10/call-agent.c (scd_keypairinfo_status_cb)
2968         (agent_scd_keypairinfo): New.  Taken from gpgsm.
2969
2970         (cherry picked from commit 0fad61de159acf39e38a04f28f162f0beb0e77d6)
2971
2972         gpg: Remove two unused card related functions.
2973         + commit c2f87a936afb7eba288d7e6558c24509cd6ab045
2974         * g10/call-agent.c (inq_writekey_parms): Remove.
2975         (agent_scd_writekey): Remove.
2976         (agent_clear_pin_cache): Remove this stub.
2977
2978         (cherry picked from commit 334b16b868e771b983263ed20c200869e7e51198)
2979
2980         gpg: Repurpose the ISO defined DO "sex" to "salutation".
2981         + commit d410b5f9309607599c9ff45061fd1f02638a9a88
2982         * g10/card-util.c (current_card_status): String changes.
2983         (change_sex): Description change.
2984         (cmds): Add "salutation"; keep "sex" as an alias.
2985
2986         gpg: Remove unused arg in a card related function.
2987         + commit c66a2cc8d306e7d9d0b4450311f230f182762f93
2988         * g10/call-agent.c (agent_scd_setattr): Remove unused arg serialno.
2989
2990         (cherry picked from commit 3a4534d82682f69788da3cf4a445e38fbaf6b98e)
2991
2992 2019-08-12  NIIBE Yutaka  <gniibe@fsij.org>
2993
2994         common: Fix line break handling, finding a space.
2995         + commit 6e6078c8d0d4a2947e2a34f1367e4472f6ae483b
2996         * common/name-value.c (assert_raw_value): Correctly find a space.
2997
2998         sm: Support AES-256 key.
2999         + commit a9816d5fb13edb30c5d12cf85ae3e1a114fcc2c1
3000         * sm/decrypt.c (prepare_decryption): Handle a case for AES-256.
3001
3002         sm: Fix error checking of decryption result.
3003         + commit ccf5cc8b0b6cee562f7d5598149abcde17440ed4
3004         * sm/call-agent.c (gpgsm_agent_pkdecrypt): Fix condition.
3005
3006 2019-08-12  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3007
3008         gpg,gpgsm: Handle pkdecrypt responses with/without NUL terminators.
3009         + commit 64500e7f6dd63c793734e52e270b1ea23cfd1928
3010         * g10/call-agent.c (agent_pkdecrypt): accept but do not require
3011         NUL-terminated data from the agent.
3012         * sm/call-agent.c (gpgsm_agent_pkdecrypt): accept but do not require
3013         NUL-terminated data from the agent.
3014
3015 2019-08-12  NIIBE Yutaka  <gniibe@fsij.org>
3016
3017         scd: Handle CCID bwi of time extension.
3018         + commit 879660bf4581d902cc1d1244091873c6c0225fa2
3019         * scd/ccid-driver.c (bulk_in): Increase timeout by the multiplier
3020         value as defined section 6.2.6 in CCID specification.
3021
3022         scd: Fix bBWI value.
3023         + commit f8961a576d3b5d69bb0e600a64553659ebef8ee7
3024         * scd/ccid-driver.c (ccid_transceive_apdu_level): Use bBWI=0 for APDU
3025         level transfer.
3026         (ccid_transceive): Use bBWI=0 or the value returend by WTX for TPDU
3027         level transfer.
3028
3029         card: Fix showing KDF object attribute.
3030         + commit 8e01676981206c209c0bfcb92633d9d2f06a2d90
3031         * g10/call-agent.c (learn_status_cb): Parse the KDF DO.
3032         * g10/card-util.c (current_card_status): Show it correctly.
3033
3034 2019-07-22  NIIBE Yutaka  <gniibe@fsij.org>
3035
3036         gpg: The option --passphrase= can be empty.
3037         + commit b21133ba80f21ce93d5a4afe48027172d9fc1999
3038         * g10/gpg.c (opts): Use ARGPARSE_o_s for oPassphrase to allow
3039         empty string.
3040
3041 2019-07-16  NIIBE Yutaka  <gniibe@fsij.org>
3042
3043         dirmngr: Don't add system CAs for SKS HKPS pool.
3044         + commit 58e234fbeb6cc5908b69a73e50428f02e584e504
3045         * dirmngr/http.c [HTTP_USE_GNUTLS] (http_session_new): Clear
3046         add_system_cas.
3047
3048         gpg: Improve import slowness.
3049         + commit eb00a14f6d2de7c53487f39494c5cb9c0598fc96
3050         * g10/import.c (read_block): Avoid O(N^2) append.
3051         (sec_to_pub_keyblock): Likewise.
3052
3053         gpg: Fix keyring retrieval.
3054         + commit b7df72d3074b72cf8b537ac87416b6b719c1b1b7
3055         * g10/keyring.c (keyring_get_keyblock): Avoid O(N^2) append.
3056
3057 2019-07-12  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3058
3059         doc: fix spelling.
3060         + commit d10bb027e481b518e4bf13ba72d14933d6cbb8cb
3061         * doc/tools.texi: fix a handful of minor spelling errors.
3062
3063 2019-07-09  Werner Koch  <wk@gnupg.org>
3064
3065         Release 2.2.17.
3066         + commit 591523ec94b6279b8b39a01501d78cf980de8722
3067
3068
3069 2019-07-09  Ineiev  <ineiev@gnu.org>
3070
3071         po: Update Russian translation.
3072         + commit ad0c61972a413987d2cc8ac8deb6a646b954ae05
3073
3074
3075 2019-07-09  Werner Koch  <wk@gnupg.org>
3076
3077         gpg: Do not try the import fallback if the options are already used.
3078         + commit 3c2cf5ea952015a441ee5701c41dadc63be60d87
3079         * g10/import.c (import_one): Check options.
3080
3081         gpg: Fix regression in option "self-sigs-only".
3082         + commit b6effaf4669b2c3707932e3c5f2f57df886d759e
3083         * g10/import.c (read_block): Make sure KEYID is availabale also on a
3084         pending packet.
3085
3086 2019-07-05  Werner Koch  <wk@gnupg.org>
3087
3088         gpg: With --auto-key-retrieve prefer WKD over keyservers.
3089         + commit 3242837d203a7b90b92952e63ee160a5a41764c0
3090         * g10/mainproc.c (check_sig_and_print): Print a hint on how to make
3091         use of the preferred keyserver.  Remove keyserver lookup just by the
3092         keyid.  Try a WKD lookup before a keyserver lookup.
3093
3094         wkd: Change client/server limit back to 64 KiB.
3095         + commit 6396f8d115f21ae15571b683e9ac9d1d7e3f44f4
3096         * tools/wks-receive.c (decrypt_data): Change limit.
3097
3098 2019-07-04  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3099
3100         dirmngr: fix handling of HTTPS redirections during HKP.
3101         + commit efb6e08ea2ca1cf2d39135d94195802cd69b9ea6
3102         * dirmngr/ks-engine-hkp.c (send_request): Reinitialize HTTP session when
3103         following a HTTP redirection.
3104
3105 2019-07-04  Werner Koch  <wk@gnupg.org>
3106
3107         gpg: Add "self-sigs-only" and "import-clean" to the keyserver options.
3108         + commit 2b7151b0a57f5fe7d67fd76dfa1ba7a8731642c6
3109         * g10/gpg.c (main): Change default.
3110
3111         gpg: Avoid printing false AKL error message.
3112         + commit 4cbd058a3da9aae74aadab7f260952b9ebb5becf
3113         * g10/getkey.c (get_pubkey_byname): Add special traeatment for default
3114         and skipped-local.
3115
3116         gpg: New command --locate-external-key.
3117         + commit 46f3283b345e1cabca4b0320cf98274ade8ec162
3118         * g10/gpg.c (aLocateExtKeys): New.
3119         (opts): Add --locate-external-keys.
3120         (main): Implement that.
3121         * g10/getkey.c (get_pubkey_byname): Implement GET_PUBKEY_NO_LOCAL.
3122         (get_best_pubkey_byname): Add arg 'mode' and pass on to
3123         get_pubkey_byname.  Change callers.
3124         * g10/keylist.c (public_key_list): Add arg 'no_local'.
3125         (locate_one): Ditto.  Pass on to get_best_pubkey_byname.
3126
3127         gpg: Make the get_pubkey_byname interface easier to understand.
3128         + commit 11871433436b5b9b9aca46579dd185a9a77674cd
3129         * g10/keydb.h (enum get_pubkey_modes): New.
3130         * g10/getkey.c (get_pubkey_byname): Repalce no_akl by a mode arg and
3131         change all callers.
3132
3133 2019-07-03  Werner Koch  <wk@gnupg.org>
3134
3135         dirmngr: Avoid endless loop in case of HTTP error 503.
3136         + commit d2e8d71251813e61b15a07637497fabe823b822c
3137         * dirmngr/ks-engine-hkp.c (SEND_REQUEST_EXTRA_RETRIES): New.
3138         (handle_send_request_error): Use it for 503 and 504.
3139         (ks_hkp_search, ks_hkp_get, ks_hkp_put): Pass a new var for
3140         extra_tries.
3141
3142         dirmngr: Do not rewrite the redirection for the "openpgpkey" subdomain.
3143         + commit c9b133a54e93b7f2365b5d6b1c39ec2cc6dac8f9
3144         * dirmngr/http.c (same_host_p): Consider certain subdomains to be the
3145         same.
3146
3147 2019-07-03  Peter Lebbing  <peter@digitalbrains.com>
3148
3149         Mention --sender in documentation.
3150         + commit 37b549dfe0acd362399debd7c93794eb75937402
3151
3152
3153 2019-07-03  Werner Koch  <wk@gnupg.org>
3154
3155         dirmngr: Support the new WKD draft with the openpgpkey subdomain.
3156         + commit 458973f502b9a43ecf29e804a2c0c86e78f5927a
3157         * dirmngr/server.c (proc_wkd_get): Implement new openpgpkey subdomain
3158         method.
3159
3160 2019-07-02  Werner Koch  <wk@gnupg.org>
3161
3162         gpg: Fallback to import with self-sigs-only on too large keyblocks.
3163         + commit a1f2f38dfb2ba5ed66d3aef66fc3be9b67f9b800
3164         * g10/import.c (import_one): Rename to ...
3165         (import_one_real): this.  Do not print and update stats on keyring
3166         write errors.
3167         (import_one): New.  Add fallback code.
3168
3169 2019-07-01  Werner Koch  <wk@gnupg.org>
3170
3171         gpg: New import and keyserver option "self-sigs-only"
3172         + commit adb120e663fc5e78f714976c6e42ae233c1990b0
3173         * g10/options.h (IMPORT_SELF_SIGS_ONLY): New.
3174         * g10/import.c (parse_import_options): Add option "self-sigs-only".
3175         (read_block): Handle that option.
3176
3177         gpg: Make read_block in import.c more flexible.
3178         + commit 15a425a1dfe60bd976b17671aa8e3d9aed12e1c0
3179         * g10/import.c: Change arg 'with_meta' to 'options'.  Change callers.
3180
3181 2019-07-01  NIIBE Yutaka  <gniibe@fsij.org>
3182
3183         tools: gpgconf: Killing order is children-first.
3184         + commit 526714806da4e50c8e683b25d76460916d58ff41
3185         * tools/gpgconf-comp.c (gc_component_kill): Reverse the order.
3186
3187 2019-06-24  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3188
3189         spelling: Fix "synchronize"
3190         + commit 520f5d70e4128b61c30da2a463f6c34ca24b628e
3191
3192
3193 2019-06-03  Werner Koch  <wk@gnupg.org>
3194
3195         Return better error code for some getinfo IPC commands.
3196         + commit f3251023750d6bd9023dbb8373c804d7d4540a56
3197         * agent/command.c (cmd_getinfo): Return GPG_ERR_FALSE as boolean False.
3198         * g13/server.c (cmd_getinfo): Ditto.
3199         * sm/server.c (cmd_getinfo): Ditto.
3200
3201 2019-05-29  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3202
3203         doc/wks.texi: fix typo.
3204         + commit 175d194b5d6063895ecfcfed6ed2154e4a0d1421
3205
3206
3207 2019-05-28  Werner Koch  <wk@gnupg.org>
3208
3209         Release GnuPG 2.2.16.
3210         + commit 3f2b7a53ddc43b3a349451d28691aaaa116786dc
3211
3212
3213         dirmngr: Allow for other hash algorithms than SHA-1 in OCSP.
3214         + commit 5281ecbe3ae8364407d9831243b81d664b040805
3215         * dirmngr/ocsp.c (do_ocsp_request): Remove arg md.  Add args r_sigval,
3216         r_produced_at, and r_md.  Get the hash algo from the signature and
3217         create the context here.
3218         (check_signature): Allow any hash algo.  Print a diagnostic if the
3219         signature does not verify.
3220
3221 2019-05-27  Werner Koch  <wk@gnupg.org>
3222
3223         sm: Avoid confusing diagnostic for the default key.
3224         + commit 32210e855c460ed60505bf9be9adea33d05c40eb
3225         * sm/certlist.c (cert_usage_p): Add arg 'silent' and change all
3226         callers.
3227         (gpgsm_cert_use_sign_p): Add arg 'silent' and pass to cert_usage_p.
3228         Change all callers.
3229         * sm/sign.c (gpgsm_get_default_cert): Set SILENT when calling
3230         gpgsm_cert_use_sign_p
3231
3232         gpg: Fixed i18n markup of some strings.
3233         + commit ab5d7142a79e92819f5551cfc424a8ceaf0885fa
3234         * g10/tofu.c: Removed some translation markups which either make no
3235         sense or are not possble.
3236
3237         gpg: Allow deletion of subkeys with --delete-[secret-]key.
3238         + commit d9b31d3a20b89a5ad7e9a2158b6da63a9a37fa8a
3239         * common/userids.c (classify_user_id): Do not set the EXACT flag in
3240         the default case.
3241         * g10/export.c (exact_subkey_match_p): Make static,
3242         * g10/delkey.c (do_delete_key): Implement subkey only deleting.
3243
3244 2019-05-27  NIIBE Yutaka  <gniibe@fsij.org>
3245
3246         agent: Stop scdaemon after reload when disable_scdaemon.
3247         + commit 9ccdd59e4e1e0b0e3b03b288f52f3c71e86a04dd
3248         * agent/call-scd.c (agent_card_killscd): New.
3249         * agent/gpg-agent.c (agent_sighup_action): Call agent_card_killscd.
3250
3251 2019-05-21  Werner Koch  <wk@gnupg.org>
3252
3253         gpg: Do not bail on an invalid packet in the local keyring.
3254         + commit 30f44957ccd1433846709911798af3da4e437900
3255         * g10/keydb.c (parse_keyblock_image): Treat invalid packet special.
3256
3257         gpg: Do not allow creation of user ids larger than our parser allows.
3258         + commit d32963eeb33fd3053d40a4e7071fb0e8b28a8651
3259         * g10/parse-packet.c: Move max packet lengths constants to ...
3260         * g10/packet.h: ... here.
3261         * g10/build-packet.c (do_user_id): Return an error if too data is too
3262         large.
3263         * g10/keygen.c (write_uid): Return an error for too large data.
3264
3265 2019-05-21  NIIBE Yutaka  <gniibe@fsij.org>
3266
3267         agent: For SSH key, don't put NUL-byte at the end.
3268         + commit 6e39541f4f488fe59eac399bad18c465f373a784
3269         * agent/command-ssh.c (ssh_key_to_protected_buffer): Update
3270         the length by the second call of gcry_sexp_sprint.
3271
3272 2019-05-20  Werner Koch  <wk@gnupg.org>
3273             Matheus Afonso Martins Moreira
3274
3275         gpg: Do not delete any keys if --dry-run is passed.
3276         + commit 5c46c5f74540ad753b925b74593332ca92de47fa
3277         * g10/delkey.c (do_delete_key): Don't delete the keyblock on dry runs.
3278         Do not clear the ownertrust.  Do not let the agent delete the key.
3279
3280 2019-05-17  Werner Koch  <wk@gnupg.org>
3281
3282         gpg: Fix using --decrypt along with --use-embedded-filename.
3283         + commit 1702179d91b7136661af084d7dab2e50a2857491
3284         * g10/options.h (opt): Add flags.dummy_outfile.
3285         * g10/decrypt.c (decrypt_message): Set this global flag instead of the
3286         fucntion local flag.
3287         * g10/plaintext.c (get_output_file): Ignore opt.output if that was
3288         used as a dummy option aslong with --use-embedded-filename.
3289
3290         gpg: Improve the photo image viewer selection.
3291         + commit cd5f040a5389944dd8a05bc9c938f888581dfc8a
3292         * g10/exec.c (w32_system): Add "!ShellExecute" special.
3293         * g10/photoid.c (get_default_photo_command): Use the new ShellExecute
3294         under Windows and fallbac to 'display' and 'xdg-open' in the Unix
3295         case.
3296         (show_photos): Flush stdout so that the output is shown before the
3297         image pops up.
3298
3299 2019-05-16  Werner Koch  <wk@gnupg.org>
3300
3301         kbx: Fix an endless loop under Windows due to an incomplete fix.
3302         + commit 0fff927889b075442ed7130f376118c31fda1f32
3303         * kbx/keybox-search.c (keybox_search):  We need to seek to the last
3304         position in all cases not just when doing a NEXT.
3305
3306         kbx: Fix deadlock in gpgsm on Windows due to a sharing violation.
3307         + commit 6f72aa821407e47ad3963e72e139f2ca2c69d9dd
3308         * kbx/keybox-init.c (keybox_lock) [W32]: Use _keybox_close_file
3309         instead of fclose so that a close is done if the file is opened by
3310         another handle.
3311         * kbx/keybox-search.c (keybox_search): Remember the last offset and
3312         use that in NEXT search mode if we had to re-open the file.
3313
3314         gpgconf: Before --launch check that the config file is fine.
3315         + commit 3a28706cfd960ff84dda9a22aa2f160b4c2efbb5
3316         * tools/gpgconf-comp.c (gc_component_launch): Check the conf file.
3317         * tools/gpgconf.c (gpgconf_failure): Call log_flush.
3318
3319 2019-05-15  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3320
3321         gpg: enable OpenPGP export of cleartext keys with comments.
3322         + commit 9c704d9d46338769a66bfc6c378efeda3c4bd9ec
3323         * g10/export.c (cleartext_secret_key_to_openpgp): ignore trailing
3324         sublists in private-key S-expression.
3325
3326 2019-05-15  Werner Koch  <wk@gnupg.org>
3327
3328         gpgconf: Support --homedir for --launch.
3329         + commit 31e26037bd727a6ee9c96ba168a55c4f9def43b6
3330         * tools/gpgconf-comp.c (gpg_agent_runtime_change): Simplify because
3331         gnupg_homedir already returns abd absolute name.
3332         (scdaemon_runtime_change): Ditto.
3333         (dirmngr_runtime_change): Ditto.
3334         (gc_component_launch): Support --homedir.
3335
3336 2019-05-14  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3337
3338         agent: correct length for uri and comment on 64-bit big-endian platforms
3339         + commit 110932925ba8e0169da18d7774440f8d1fd8a344
3340         * agent/findkey.c (agent_public_key_from_file): pass size_t as int to
3341         gcry_sexp_build_array's %b.
3342
3343 2019-05-14  Werner Koch  <wk@gnupg.org>
3344
3345         gpg: Do not print a hint to use the deprecated --keyserver option.
3346         + commit 8d645f1d1f2b0f4e2d3b72f2a585acac4bdd8846
3347         * g10/keyserver.c (keyserver_search): Remove a specialized error
3348         message.
3349
3350 2019-05-14  NIIBE Yutaka  <gniibe@fsij.org>
3351
3352         g10: Fix possible null dereference.
3353         + commit 5b22d2c400890fc366ccb7ca74ee886d9cef22a3
3354         * g10/armor.c (armor_filter): Access ->d in the internal loop.
3355
3356         build: Update m4/iconv.m4.
3357         + commit cf73c82e95f999bd35636b0cf4e80ed5c33fa7a8
3358         * m4/iconv.m4: Update from gettext 0.20.1.
3359
3360 2019-05-13  Werner Koch  <wk@gnupg.org>
3361
3362         gpg: Change update_keysig_packet to replace SHA-1 by SHA-256.
3363         + commit c1dc7a832921fdf5686d377f33db78707c0345e2
3364         * g10/sign.c (update_keysig_packet): Convert digest algo when needed.
3365
3366 2019-05-12  Werner Koch  <wk@gnupg.org>
3367
3368         sm: Fix a warning in an es_fopencooie function.
3369         + commit 8d0d61aca3d2713df8a33444af3658b859d72be8
3370         * sm/certdump.c (format_name_writer): Take care of a flush request.
3371
3372 2019-05-10  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3373
3374         doc: correct documentation for gpgconf --kill.
3375         + commit be116f871dbf14dd44d3a7909c2a052f8979c480
3376         * doc/tools.texi(gpgconf): Correct documentation for gpgconf --kill.
3377
3378         (cherry picked from commit 9662538be6afc8beee0f2654f9a8f234c5dac016)
3379
3380 2019-05-09  Werner Koch  <wk@gnupg.org>
3381
3382         build: Sign all Windows binaries.
3383         + commit e6901c2bc802996c24335bcb35012ccb74b4ced0
3384         * build-aux/speedo.mk (AUTHENTICODE_SIGNHOST): New.
3385         (AUTHENTICODE_TOOL): New.
3386         (AUTHENTICODE_FILES): New.
3387         (installer): Sign listed files.
3388         (AUTHENTICODE_SIGNHOST): New macro.
3389         (sign-installer): Use that macro instead of direct use of osslsigncode.
3390
3391 2019-05-03  Werner Koch  <wk@gnupg.org>
3392
3393         gpg: Use just the addrspec from the Signer's UID.
3394         + commit 05204b72497db093f5d2da4a2446c0264a946296
3395         * g10/parse-packet.c (parse_signature): Take only the addrspec from a
3396         Signer's UID subpacket.
3397
3398 2019-04-23  NIIBE Yutaka  <gniibe@fsij.org>
3399
3400         po: Update Japanese Translation.
3401         + commit caa61fb7da6b858f038dde948d36fce5c0a85ee5
3402
3403
3404 2019-04-18  Andre Heinecke  <aheinecke@intevation.de>
3405
3406         g10: Fix double free when locating by mbox.
3407         + commit 35899dc2903b118620e6f9f0fa6b21c8568abbf1
3408         * g10/getkey.c (get_best_pubkey_byname): Set new.uid always
3409         to NULL after use.
3410
3411 2019-04-16  NIIBE Yutaka  <gniibe@fsij.org>
3412
3413         common: Fix AWK portability.
3414         + commit ee766b2b5d646643d66d23eae478f71c0a01a343
3415         * common/Makefile.am: Use pkg_namespace.
3416         * common/mkstrtable.awk: Use pkg_namespace.  Regexp fix.
3417
3418 2019-04-11  Werner Koch  <wk@gnupg.org>
3419
3420         gpg: Accept also armored data from the WKD.
3421         + commit dc4c7f65e32a0cddc075d06fa0132e099bcb6455
3422         * g10/keyserver.c (keyserver_import_wkd): Clear NO_ARMOR.
3423
3424         gpg: Set a limit of 5 to the number of keys imported from the WKD.
3425         + commit e9fcb0361ab4ef1f6fb0ea235f1b15667932aba2
3426         * g10/import.c (import): Limit the number of considered keys to 5.
3427         (import_one): Return the first fingerprint in case of WKD.
3428
3429 2019-04-02  Werner Koch  <wk@gnupg.org>
3430
3431         scd: Add dummy option --application-priority.
3432         + commit cb2065967465939f82cc585254cae0244ed94eac
3433
3434
3435         dirmngr: Improve domaininfo cache update algorithm.
3436         + commit 48e7977709b6a56e8fd8e9f5abb9dba5ea617c33
3437         * dirmngr/domaininfo.c (struct domaininfo_s): Add field keepmark.
3438         (insert_or_update): Implement new update algorithm.
3439
3440         dirmngr: Better error code for http status 413.
3441         + commit 0a30ce036a615bc95382e0640d185b031f8c6a63
3442         * dirmngr/ks-engine-hkp.c (send_request): New case for 413.
3443         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
3444         * dirmngr/ocsp.c (do_ocsp_request): Ditto.
3445
3446 2019-04-01  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3447
3448         NEWS: correct typo in header.
3449         + commit 5b1b5be65f343d252c865d705d23b55982718f2d
3450
3451
3452 2019-03-27  NIIBE Yutaka  <gniibe@fsij.org>
3453
3454         g10: Fix symmetric cipher algo constant for ECDH.
3455         + commit 38c2a9a644e0bc1e2594ea437a5930982f7b8c4e
3456         * g10/ecdh.c (kek_params_table): Use CIPHER_ALGO_AES192 for
3457         ECC strength 384, according to RFC-6637.
3458
3459 2019-03-27  Trevor Bentley  <trevor@yubico.com>
3460
3461         gpg: Don't use EdDSA algo ID for ECDSA curves.
3462         + commit 2f455d18ab99a1d94029d3f607ae918bd5c9fecf
3463         * g10/keygen.c (ask_curve): Change algo ID to ECDSA if it changed from
3464         an EdDSA curve.
3465
3466 2019-03-26  Werner Koch  <wk@gnupg.org>
3467
3468         Release 2.2.15.
3469         + commit dc93e57226db32d5b90884dcf768d271baa6628a
3470
3471
3472         sm: Allow decryption even if expired other keys are configured.
3473         + commit 30972d21824264aef2088d30b4f2e5ce3aca889e
3474         * sm/gpgsm.c (main): Add special handling for bad keys in decrypt
3475         mode.
3476
3477         agent: Allow other ssh fingerprint algos in KEYINFO.
3478         + commit 1c2fa8b6d747aa171bfef35a50754893aa80a562
3479         * agent/command.c (cmd_keyinfo): Allow for --ssh-fpr=ALGO.  Default to
3480         the standard algo.
3481
3482 2019-03-25  Werner Koch  <wk@gnupg.org>
3483
3484         wkd: New command --print-wkd-url for gpg-wks-client.
3485         + commit 2f3eebf1865a85f8c09a1c052513260ed55acec6
3486         * tools/gpg-wks-client.c (aPrintWKDURL): New.
3487         (opts): Add option.
3488         (main): Implement.
3489         * tools/wks-util.c (wks_cmd_print_wkd_url): New.
3490
3491 2019-03-25  NIIBE Yutaka  <gniibe@fsij.org>
3492
3493         libdns: Don't use _[A-Z] which are reserved names.
3494         + commit a975fd127a5d58bbbb3c585e610a54daeb423af6
3495         * dirmngr/dns.c: Use the identifiers of "*_instance" instead of
3496         reserved "_[A-Z]".
3497
3498 2019-03-25  Werner Koch  <wk@gnupg.org>
3499
3500         wkd: New command --print-wkd-hash for gpg-wks-client.
3501         + commit 64621f1f40c31c7f453da98efb860ff8cf11edbc
3502         * tools/gpg-wks-client.c (aPrintWKDHash): New.
3503         (opts) : Add "--print-wkd-hash".
3504         (main): Implement that command.
3505         (proc_userid_from_stdin): New.
3506         * tools/wks-util.c (wks_fname_from_userid): Add option HASH_ONLY.
3507         (wks_cmd_print_wkd_hash): New.
3508
3509 2019-03-25  Andre Heinecke  <aheinecke@gnupg.org>
3510
3511         sm, w32: Translate logger and status fd to handles.
3512         + commit b9d2759da19cb70c1f6243498480bea1d7ecaa46
3513         * sm/gpgsm.c (main): Call translate_sys2libc_fd_int to
3514         convert the FDs.
3515
3516 2019-03-22  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3517
3518         doc: fix formatting error.
3519         + commit 93782de23fe45e7f7f86140fda6de39395c3a9d8
3520
3521
3522 2019-03-19  Werner Koch  <wk@gnupg.org>
3523
3524         Release 2.2.14.
3525         + commit 813de13e73b01409fabff9859f24c4f23b808796
3526
3527
3528 2019-03-18  Ineiev  <ineiev@gnu.org>
3529
3530         po: Update Russian translation.
3531         + commit dc00947b21dcd4417a35da711c884cef5cc9fc7d
3532
3533
3534 2019-03-18  Werner Koch  <wk@gnupg.org>
3535
3536         gpg: Do not bail out on v5 keys in the local keyring.
3537         + commit de70a2f377c1647417fb8a2b6476c3744a901296
3538         * g10/parse-packet.c (parse_key): Return GPG_ERR_UNKNOWN_VERSION
3539         instead of invalid packet.
3540         * g10/keydb.c (parse_keyblock_image): Do not map the unknown version
3541         error to invalid keyring.
3542         (keydb_search): Skip unknown version errors simlar to legacy keys.
3543         * g10/keyring.c (keyring_rebuild_cache): Skip keys with unknown
3544         versions.
3545         * g10/import.c (read_block): Handle unknown version.
3546
3547         gpg: Allow import of PGP desktop exported secret keys.
3548         + commit 0e73214dd208fca4df26ac796416c6f25b3ae50d
3549         * g10/import.c (NODE_TRANSFER_SECKEY): New.
3550         (import): Add attic kludge.
3551         (transfer_secret_keys): Add arg only_marked.
3552         (resync_sec_with_pub_keyblock): Return removed seckeys via new arg
3553         r_removedsecs.
3554         (import_secret_one): New arg r_secattic.  Change to take ownership of
3555         arg keyblock.  Implement extra secret key import logic.  Factor some
3556         code out to ...
3557         (do_transfer): New.
3558         (import_matching_seckeys): New.
3559
3560         gpg: Avoid importing secret keys if the keyblock is not valid.
3561         + commit 43b23aa82be7e02414398af506986b812e2b9349
3562         * g10/keydb.h (struct kbnode_struct): Replace unused field RECNO by
3563         new field TAG.
3564         * g10/kbnode.c (alloc_node): Change accordingly.
3565         * g10/import.c (import_one): Add arg r_valid.
3566         (sec_to_pub_keyblock): Set tags.
3567         (resync_sec_with_pub_keyblock): New.
3568         (import_secret_one): Change return code to gpg_error_t.   Return an
3569         error code if sec_to_pub_keyblock failed.  Resync secret keyblock.
3570
3571         gpg: During secret key import print "sec" instead of "pub".
3572         + commit db2d75f1ffede2ea77163b487a15e60249daffa0
3573         * g10/keyedit.c (show_basic_key_info): New arg 'print_sec'.  Remove
3574         useless code for "sub" and "ssb".
3575         * g10/import.c (import_one): Pass FROM_SK to show_basic_key_info.  Do
3576         not print the first  keyinfo in FROM_SK mode.
3577         printing.
3578
3579         gpg: Simplify an interactive import status line.
3580         + commit 184fbf014ae537554d6939a47f07977ef0b0fe9f
3581         * g10/cpr.c (write_status_printf): Escape CR and LF.
3582         * g10/import.c (print_import_check): Simplify by using
3583         write_status_printf and hexfingerprint.
3584
3585
3586         Fixed one conlict in a comment.
3587
3588 2019-03-07  NIIBE Yutaka  <gniibe@fsij.org>
3589
3590         libdns: Avoid using compound literals (8).
3591         + commit ee08a15e31284d32fb59774fc15e39107a727072
3592         * dirmngr/dns.h (dns_quietinit): Remove.
3593         (dns_hints_i_new): Remove.
3594
3595         libdns: Avoid using compound literals (7).
3596         + commit 4ab0fef5dc856d1f2747efab584182aa880f631c
3597         * dirmngr/dns.h (DNS_OPTS_INIT, dns_opts): Remove.
3598         * dirmngr/dns-stuff.c (libdns_res_open): Use zero-ed, and initialized
3599         automatic variable for opts.
3600         * dirmngr/dns.c (send_query, resolve_query, resolve_addrinfo):
3601         Likewise.
3602
3603         libdns: Avoid using compound literals (6).
3604         + commit f3af1707690b070b4cbf6d761a9e5dbddbf681e9
3605         * dirmngr/dns.h (dns_rr_i_new): Remove.
3606         (dns_rr_i_init): Remove unused second argument.
3607         * dirmngr/dns.c (dns_p_dump, dns_hints_query, print_packet)
3608         (parse_packet): Use automatic variable for struct dns_rr_i.
3609         (dns_d_cname): No need to call dns_rr_i_init after memset 0.
3610         (dns_rr_i_init): Remove unused second argument.  Return nothing.
3611         * dirmngr/dns-stuff.c (resolve_addr_libdns, get_dns_cert_libdns)
3612         (getsrv_libdns): Follow the change of dns_rr_i_init.
3613
3614         (cherry picked from commit 6501e59d3685bb58753c9caea729a4b0eca3942a)
3615
3616         libdns: Avoid using compound literals (5).
3617         + commit 500151e6daf5fc4d6ea382b83aab3cca72b27881
3618         * dirmngr/dns.h (dns_rr_foreach): Don't use dns_rr_i_new.
3619         Call dns_rr_grep with NULL.
3620         * dirmngr/dns.c (dns_rr_grep): Support NULL for error_.
3621
3622         libdns: Avoid using compound literals (4).
3623         + commit 229302aecf8deea0349e79ca0cc05f32665391b7
3624         * dirmngr/dns.h (dns_d_new*): Remove.
3625         * dirmngr/dns.c (parse_packet): Use dns_d_init with automatic
3626         variable.
3627         (parse_domain): Likewise.
3628
3629         (cherry picked from commit 7313a112f9c7ada61d24285313d2e2d069a672e8)
3630
3631         libdns: Avoid using compound literals (3).
3632         + commit f0de4fc990767ae5d120a523be51616b0f35f4f6
3633         * dirmngr/dns.h (dns_p_new): Remove.
3634         * dirmngr/dns.c (dns_hosts_query): Use dns_p_init with automatic
3635         variable.
3636         (dns_hints_query, dns_res_glue, parse_packet, query_hosts)
3637         (send_query, show_hints, echo_port): Likewise.
3638
3639         libdns: Avoid using compound literals (2).
3640         + commit ff7d01fc6d396fc3b8d37baa9bd4cdebc8853648
3641         * dirmngr/dns.h (dns_strsection1, dns_strsection3): Remove.
3642         (dns_strclass1, dns_strclass3): Remove.
3643         (dns_strtype1, dns_strtype3): Remove.
3644         (dns_strsection, dns_strclass, dns_strtype): Directly use the
3645         function.
3646         * dirmngr/dns.c (dns_strsection): Use automatic variable.
3647         (dns_strclass, dns_strtype): Likewise.
3648
3649         (cherry picked from commit 455ef62d29a112de05897139716265d07e4c6ae3)
3650
3651         libdns: Avoid using compound literals.
3652         + commit 1318d1e2d50989c66f496ede906a846859f0cf9f
3653         * dirmngr/dns.c (dns_inet_pton, dns_so_tcp_keep): Use automatic
3654         variables.
3655         (dns_poll, dns_send_nopipe): Likewise, adding const qualifier.
3656
3657 2019-03-07  Werner Koch  <wk@gnupg.org>
3658
3659         dirmngr: Add CSRF protection exception for protonmail.
3660         + commit 557c721e787e7e6d311ccb48d8aa677123061cf5
3661         * dirmngr/http.c (same_host_p): Add exception table.
3662
3663         gpgtar: Make option -C work for archive creation.
3664         + commit 5d73c231e4f2d5994eb3be48b36517e39d66be96
3665         * tools/gpgtar-create.c (gpgtar_create): Switch to the -C directory.
3666
3667         gpgtar: Improve error messages.
3668         + commit 2e4151a3412c3fc553fbb7ad070dfffc68a04b35
3669         * tools/gpgtar.h (struct tarinfo_s): New.
3670         * tools/gpgtar.c (cmd, skip_crypto, files_from, null_names): Move
3671         global vars more to the top.
3672         (set_cmd): Rename 'cmd' to 'c'.
3673         * tools/gpgtar-list.c (parse_header): Add arg 'info' and improve error
3674         messages.
3675         (read_header): Add arg 'info' and update counter.
3676         (skip_data): Ditto.
3677         (gpgtar_list): Pass info object to read functions.
3678         (gpgtar_read_header): Add arg 'info'.
3679         * tools/gpgtar-extract.c (gpgtar_extract): add arg 'info' and pass on.
3680         (extract_regular): Add arg 'info' and update counter.
3681
3682         gpg: Make invalid primary key algos obvious in key listings.
3683         + commit d2a7f9078a4673ec53733e4f69fd17a8f1ac962d
3684         * g10/keylist.c (print_key_line): Print a warning for invalid algos.
3685
3686         sm: Print Yubikey attestation extensions with --dump-cert.
3687         + commit b3c8ce9e4343f1b68b9ba94bdd71b7d8e13b139a
3688         * sm/keylist.c (oidtranstbl): Add Yubikey OIDs.
3689         (OID_FLAG_HEX): New.
3690         (print_hex_extn): New.
3691         (list_cert_raw): Make use of that flag.
3692
3693         (cherry picked from commit 86c241a8c9a952ea8007066b70b04f435e2e483e)
3694
3695 2019-03-07  NIIBE Yutaka  <gniibe@fsij.org>
3696
3697         tests: Add "disable-scdaemon" in gpg-agent.conf.
3698         + commit 150d5452318eafa6aa800ff3b87f8f8eb35ed203
3699         * tests/openpgp/defs.scm: Add "disable-scdaemon".  Remove
3700           "scdaemon-program".
3701         * tests/gpgme/gpgme-defs.scm, tests/gpgsm/gpgsm-defs.scm: Likewise.
3702         * tests/inittests, tests/pkits/inittests: Add "disable-scdaemon"
3703
3704 2019-03-07  Werner Koch  <wk@gnupg.org>
3705
3706         scd: Fix flushing of CA-FPR data objects.
3707         + commit e7eafe10197557ce874db2f049d683f90f26e0bc
3708         * scd/app-openpgp.c (do_setattr): Add new table item to flush a
3709         different tag.
3710
3711 2019-03-07  NIIBE Yutaka  <gniibe@fsij.org>
3712
3713         agent: Support --mode=ssh option for CLEAR_PASSPHRASE.
3714         + commit 77a285a0a94994ee9b42289897f9bf3075c7192d
3715         * agent/command.c (cmd_clear_passphrase): Add support for SSH.
3716
3717 2019-03-07  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3718
3719         gpgv: Improve documentation for keyring choices.
3720         + commit a7b2a87f940dba078867c44f1f50d46211d51719
3721         * doc/gpgv.texi: Improve documentation for keyring choices
3722
3723 2019-02-28  Werner Koch  <wk@gnupg.org>
3724
3725         sm: Don't mark a cert as de-vs compliant if it leads to SHA-1 sigs.
3726         + commit be69bf0cbd11cb8c0d452e07066669aacc6caafa
3727         * sm/keylist.c (print_compliance_flags): Also check the digest_algo.
3728         Add new arg 'cert'.
3729
3730 2019-02-28  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
3731
3732         gpgsm: default to 3072-bit keys.
3733         + commit 121286d9d1506dbaad9ba33bae2e459814fe5849
3734         * doc/gpgsm.texi, doc/howto-create-a-server-cert.texi: : update
3735         default to 3072 bits.
3736         * sm/certreqgen-ui.c (gpgsm_gencertreq_tty): update default to
3737         3072 bits.
3738         * sm/certreqgen.c (proc_parameters): update default to 3072 bits.
3739         * sm/gpgsm.c (main): print correct default_pubkey_algo.
3740
3741 2019-02-26  Werner Koch  <wk@gnupg.org>
3742
3743         conf: New option --show-socket.
3744         + commit 92e26ade5c0d52f2e50eaf338a0bb8006e75711c
3745         * tools/gpgconf-comp.c (gc_component_t): Move this enum to ...
3746         * tools/gpgconf.h: here.
3747         * tools/gpgconf.c (oShowSocket): New.
3748         (opts): Add new option.
3749         (main): Implement new option.
3750
3751 2019-02-25  Werner Koch  <wk@gnupg.org>
3752
3753         scd: Don't let the "undefined" app cause a conflict error.
3754         + commit 0eb8095626be71160dfa66284a7b0a6a57cb03e3
3755         * scd/app.c (check_conflict): Ignore "undefined".
3756
3757         (cherry picked from commit 5ecc7a02609dde65096ddb12e0ff8f6bce3b774a)
3758
3759         sm: Fix certificate creation with key on card.
3760         + commit 54c56230e305a38d6fd0c3bf1262172fd5fbcb87
3761         * sm/certreqgen.c (create_request): Fix for certmode.
3762
3763         agent: Fix for suggested Libgcrypt use.
3764         + commit 0a95b153811f36739d1b20f23920bad0bb07c68b
3765         * agent/divert-scd.c (divert_pkdecrypt): Skip a flags parameter.
3766
3767 2019-02-25  NIIBE Yutaka  <gniibe@fsij.org>
3768
3769         gpgscm: Build well even if NDEBUG defined.
3770         + commit 8161afb9dddaba839be92fbe9d85c05235eda825
3771         * gpgscm/scheme.c (gc_reservation_failure): Fix adding ";".
3772         [!NDEBUG] (scheme_init_custom_alloc): Don't init seserved_lineno.
3773
3774 2019-02-19  Neal H. Walfield  <neal@g10code.com>
3775
3776         gpg: Fix comparison.
3777         + commit 14e5435afb50dc9a9243ff3e0aed5030beba2914
3778         * g10/gpgcompose.c (literal_name): Complain if passed zero arguments,
3779         not one or fewer.
3780
3781 2019-02-19  NIIBE Yutaka  <gniibe@fsij.org>
3782
3783         agent: Fix cancellation handling for scdaemon.
3784         + commit 005e951714ff62087b8c8802e05d14b7998826f3
3785         * agent/call-scd.c (cancel_inquire): Remove.
3786         (agent_card_pksign, agent_card_pkdecrypt, agent_card_writekey)
3787         (agent_card_scd): Don't call cancel_inquire.
3788
3789         scd: Distinguish cancel by user and protocol error.
3790         + commit 90e5f49b6a2e002d3c67a041a076f07aeb7a7f54
3791         * scd/apdu.h (SW_HOST_CANCELLED): New.
3792         * scd/apdu.c (host_sw_string): Support SW_HOST_CANCELLED.
3793         (pcsc_error_to_sw): Return SW_HOST_CANCELLED for PCSC_E_CANCELLED.
3794         * scd/iso7816.c (map_sw): Return GPG_ERR_INV_RESPONSE for
3795         SW_HOST_ABORTED and GPG_ERR_CANCELED for SW_HOST_CANCELLED.
3796
3797         common: Fix gnupg_wait_processes.
3798         + commit 6e422b5135c71f8fa859a3f4de51bf89e3ff5ac6
3799         * common/exechelp-posix.c (gnupg_wait_processes): Loop for r_exitcodes
3800         even if we already see an error.
3801
3802 2019-02-14  Ingvar Hagelund  <ingvar@redpill-linpro.com>
3803
3804         po: Correct a simple typo in the Norwegian translation.
3805         + commit a09bba976d2f5694011a9291189a70a0f3c4caae
3806
3807
3808 2019-02-12  Werner Koch  <wk@gnupg.org>
3809
3810         Release 2.2.13.
3811         + commit 7922e2dd1c7eee48a8a2cf4799827942489ddd0f
3812
3813
3814 2019-02-11  Werner Koch  <wk@gnupg.org>
3815
3816         sm: In --gen-key with "key from card" show also the algorithm.
3817         + commit d1bee9d1efa28fa9d35b7eed1e616c6362fd044e
3818         * sm/certreqgen-ui.c (gpgsm_gencertreq_tty): Get and show algo.
3819
3820         common: Provide function to get public key algo names in our format.
3821         + commit d29d73264f607642281fb701a17015306c8fc4d7
3822         * common/sexputil.c (pubkey_algo_string): New.
3823
3824         common: New functions get_option_value and ascii_strupr.
3825         + commit ee8d1a9e6c09b3ecc4b46f47b79358f78d458916
3826         * common/server-help.c (get_option_value): New.
3827         * common/stringhelp.c (ascii_strupr): New.
3828
3829         scd: Make app_genkey and supporting ISO function more flexible.
3830         + commit 14816c798099925e47908e7ce415412d72fbe28e
3831         * scd/app.c (app_genkey): Add arg keytype.
3832         * scd/app-common.h (struct app_ctx_s): Fitto for the genkey member.
3833         * scd/command.c (cmd_genkey): Adjust for change.
3834         * scd/iso7816.c (do_generate_keypair): Replace arg read_only by new
3835         args p1 and p2.
3836         (iso7816_read_public_key): Adjust for this.
3837         (iso7816_generate_keypair): Add new args p1 and p2.
3838         * scd/app-openpgp.c (do_genkey): Adjust for changes.
3839
3840         scd: Fix parameter name of app_change_key.
3841         + commit c075274aac0ffd388df638548b75a7d90e7e929d
3842         * scd/app-common.h (APP_GENKEY_FLAG_FORCE): New.
3843         * scd/app.c (app_change_pin): Rename arg reset_mode to flags and
3844         change from int to unsigned int.
3845
3846         scd: Allow standard keyref scheme for app-openpgp.
3847         + commit 6651a0640d0f1b4dd161210dc55974d9b93b7253
3848         * scd/app-openpgp.c (do_change_pin): Allow prefixing the CHVNO with
3849         "OPENPGP."
3850
3851         gpg: Emit an ERROR status if no key was found with --list-keys.
3852         + commit 14ea581a1c040b53b0ad4c51136a7948363b1e4b
3853         * g10/keylist.c (list_one): Emit status line.
3854
3855 2019-02-06  NIIBE Yutaka  <gniibe@fsij.org>
3856
3857         po: Update Japanese translation.
3858         + commit c16685b2f5021105ef0560cb3db68ef43bcdb9c1
3859
3860
3861         agent: Clear bogus pinentry cache, when it causes an error.
3862         + commit 9109bb9919f84d5472b7e62e84b961414a79d3c2
3863         * agent/agent.h (PINENTRY_STATUS_*): Expose to public.
3864         (struct pin_entry_info_s): Add status.
3865         * agent/call-pinentry.c (agent_askpin): Clearing the ->status
3866         before the loop, let the assuan_transact set ->status.  When
3867         failure with PINENTRY_STATUS_PASSWORD_FROM_CACHE, it returns
3868         soon.
3869         * agent/findkey.c (unprotect): Clear the pinentry cache,
3870         when it causes an error.
3871
3872         dirmngr: Fix initialization of assuan's nPth hook.
3873         + commit 7f4c3eb0a039621c564b6095ab5f810524843157
3874         * dirmngr/dirmngr.c (main): Move assuan_set_system_hooks to...
3875         (thread_init): ... here.
3876
3877 2019-01-30  Werner Koch  <wk@gnupg.org>
3878
3879         gpg: Allow generating Ed25519 key from an existing key.
3880         + commit 31d2a1eecaee766919b18bc42b918d9168f601f8
3881         * g10/misc.c (map_pk_gcry_to_openpgp): Add EdDSA mapping.
3882
3883 2019-01-29  Werner Koch  <wk@gnupg.org>
3884
3885         gpg: Implement searching keys via keygrip.
3886         + commit 5e5f3ca0c2e08185a236b4d04b318f81004e3223
3887         * kbx/keybox-defs.h (struct _keybox_openpgp_key_info): Add field grip.
3888         * kbx/keybox-openpgp.c (struct keyparm_s): New.
3889         (keygrip_from_keyparm): New.
3890         (parse_key): Compute keygrip.
3891         * kbx/keybox-search.c (blob_openpgp_has_grip): New.
3892         (has_keygrip): Call it.
3893
3894         common: Provide some convenient OpenPGP related constants.
3895         + commit b78f293cf06f447d1d0a5c416ac129a4e1cf9f8c
3896         * common/openpgpdefs.h (OPENPGP_MAX_NPKEY): New.
3897         (OPENPGP_MAX_NSKEY): New.
3898         (OPENPGP_MAX_NSIG): New.
3899         (OPENPGP_MAX_NENC): New.
3900         * g10/packet.h: Define PUBKEY_MAX using the new consts.
3901
3902         (cherry picked from commit f382984966a31a4cbe572bce5370590c5490ed1e)
3903
3904         common: New helper functions for OpenPGP curve OIDs.
3905         + commit dddbb26155f292fde2909ecc84b62b693b6dea49
3906         * common/openpgp-oid.c (openpgp_oidbuf_to_str): Factor most code out
3907         to ...
3908         (openpgp_oidbuf_to_str): new.
3909         (openpgp_oidbuf_is_ed25519): New.
3910         (openpgp_oidbuf_is_cv25519): New.
3911
3912 2019-01-22  Werner Koch  <wk@gnupg.org>
3913
3914         scd: Add option --clear to PASSWD.
3915         + commit d4082ff430afe670510d2c1c7ea66ee9ddcbe505
3916         * scd/command.c (cmd_passwd): Add option --clear.
3917         (send_status_printf): New.
3918         * scd/app-common.h (APP_CHANGE_FLAG_CLEAR): New.
3919         * scd/app-nks.c (do_change_pin): Return an error if that option is
3920         used.
3921         * scd/app-openpgp.c (do_change_pin): Ditto.
3922
3923         scd: One new and one improved 7816 function.
3924         + commit 9309175de8c76de44021c25c7885355ff1a9b67b
3925         * scd/apdu.c (apdu_send_direct): New arg R_SW.
3926         * scd/command.c (cmd_apdu): Ditto.
3927         * scd/iso7816.c (iso7816_apdu_direct): New arg R_SW.
3928         (iso7816_general_authenticate): New.
3929         * scd/app-nks.c (get_chv_status, get_nks_version): Pass NULL for new
3930         arg.
3931
3932         ssh: Simplify the curve name lookup.
3933         + commit 11a65159f997ccd69ecb9d867c1f3d0c4d8837d6
3934         * agent/command-ssh.c (struct ssh_key_type_spec): Add field
3935         alt_curve_name.
3936         (ssh_key_types): Add some alternate curve names.
3937         (ssh_identifier_from_curve_name): Lookup also bey alternative names
3938         and return the canonical name.
3939         (ssh_key_to_blob): Simplify the ECDSA case by using gcry_pk_get_curve
3940         instead of the explicit mapping.
3941         (ssh_receive_key): Likewise.  Use ssh_identifier_from_curve_name to
3942         validate the curve name.  Remove the reverse mapping because since
3943         GnuPG-2.2 Libgcrypt 1.7 is required.
3944         (ssh_handler_request_identities): Log an error message.
3945
3946         gpg: Stop early when trying to create a primary Elgamal key.
3947         + commit f5d3b982e44c5cfc60e9936020102a598b635187
3948         * g10/misc.c (openpgp_pk_test_algo2): Add extra check.
3949
3950 2019-01-17  NIIBE Yutaka  <gniibe@fsij.org>
3951
3952         scd: Fix for USB INTERRUPT transfer.
3953         + commit 9dc76d599cd4c86d3c187d078daad1144a92564c
3954         * scd/ccid-driver.c (intr_cb): When LIBUSB_TRANSFER_NO_DEVICE,
3955         just handle this event as failure.
3956
3957 2018-12-19  NIIBE Yutaka  <gniibe@fsij.org>
3958
3959         agent: Fix message for ACK button.
3960         + commit 80a08b655f8f5e7a7d78b766f1770fd474081a48
3961         * agent/divert-scd.c (getpin_cb): Display correct message.
3962
3963 2018-12-18  Werner Koch  <wk@gnupg.org>
3964
3965         Silence compiler warnings new with gcc 8.
3966         + commit 21fc089148678f59edb02e0e16bed65b709fb972
3967         * dirmngr/dns.c: Include gpgrt.h.  Silence -Warray-bounds also gcc.
3968         * tests/gpgscm/scheme.c: Include gpgrt.h.
3969         (Eval_Cycle): Ignore -Wimplicit-fallthrough.
3970
3971         wks: Do not use compression for the encrypted data.
3972         + commit 16424d8a34c7f6af1071fd19dfc180cb7d17c052
3973         * tools/gpg-wks-client.c (encrypt_response): Add arg -z0.
3974         * tools/gpg-wks-server.c (encrypt_stream): Ditto.
3975
3976 2018-12-18  NIIBE Yutaka  <gniibe@fsij.org>
3977
3978         po: Update Japanese translation.
3979         + commit ae9159e0685098ee97d6f526666524423f4a0fff
3980
3981
3982         scd: Support "acknowledge button" feature.
3983         + commit ffe31f405f9b5e4929e95c3d66c613052cb7727e
3984         * scd/apdu.c (set_prompt_cb): New member function.
3985         (set_prompt_cb_ccid_reader): New function.
3986         (open_ccid_reader): Initialize with set_prompt_cb_ccid_reader.
3987         (apdu_set_prompt_cb): New.
3988         * scd/app.c (lock_app, unlock_app): Add call to apdu_set_prompt_cb.
3989         * ccid-driver.c (ccid_set_prompt_cb): New.
3990         (bulk_in): Call ->prompt_cb when timer extension.
3991         * scd/command.c (popup_prompt): New.
3992
3993         agent: Support --ack option for POPUPPINPADPROMPT.
3994         + commit e6be36ee8854dc343a5e0f914991da3da360b513
3995         * agent/divert-scd.c (getpin_cb): Support --ack option.
3996
3997 2018-12-14  Werner Koch  <wk@gnupg.org>
3998
3999         Release 2.2.12.
4000         + commit 7d8f4ee7cf56eda988acdc909160cbac71bff18a
4001
4002
4003 2018-12-11  Werner Koch  <wk@gnupg.org>
4004
4005         agent: Make the S2K calibration time runtime configurable.
4006         + commit de29a50e7c8a779ac0832a149bcf3eb2c4191dc9
4007         * agent/protect.c (s2k_calibration_time): New file global var.
4008         (calibrate_s2k_count): Use it here.
4009         (get_calibrated_s2k_count): Replace function static var by ...
4010         (s2k_calibrated_count): new file global var.
4011         (set_s2k_calibration_time): New function.
4012         * agent/gpg-agent.c (oS2KCalibration): New const.
4013         (opts): New option --s2k-calibration.
4014         (parse_rereadable_options): Parse that option.
4015
4016 2018-12-11  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
4017
4018         agent: compile-time configuration of s2k calibration.
4019         + commit 0cf0f3aaf835d29848f1485df357606254ba6fad
4020         * configure.ac: add --with-agent-s2k-calibration=MSEC, introduces
4021         AGENT_S2K_CALIBRATION (measured in milliseconds)
4022         * agent/protect.c (calibrate_s2k_count): Calibrate based on
4023         AGENT_S2K_CALIBRATION.
4024
4025         (cherry picked from commit 926d07c5fa05de05caef3a72b6fe156606ac0549)
4026
4027 2018-12-11  Werner Koch  <wk@gnupg.org>
4028
4029         dirmngr: Retry another server from the pool on 502, 503, 504.
4030         + commit e5abdb6da7fa7cd4d146c7285b160277511bc230
4031         * dirmngr/ks-engine-hkp.c (handle_send_request_error): Add arg
4032         http_status and handle it.
4033         (ks_hkp_search): Get http_status froms end_request and pass on to
4034         handle_send_request_error.
4035         (ks_hkp_get): Ditto.
4036         (ks_hkp_put): Ditto.
4037
4038         dirmngr: New function http_status2string.
4039         + commit b9d71ea64a694582739c18cfef9621b36d5371e9
4040         * dirmngr/http.c (http_status2string): New.
4041
4042         gpg: In search-keys return "Not found" instead of "No Data".
4043         + commit f7ff25edadd474f83fccba6fd3c410eb8358bb22
4044         * g10/keyserver.c (keyserver_search): Check for NO_DATA.
4045
4046 2018-12-11  Tomi Leppänen  <tomi.leppanen@jolla.com>
4047
4048         tools: Use POSIX compatible arguments for find.
4049         + commit dfcc5e6d3ec91f547feb78e442946e729b49878c
4050         * tools/addgnupghome (filelist): Remove bashism.
4051
4052 2018-12-06  NIIBE Yutaka  <gniibe@fsij.org>
4053
4054         scd: Make "learn" report about KDF data object.
4055         + commit d4bc8051525a33b28b1e33daf35d79c1d6cd9c41
4056         * scd/app-openpgp.c (do_learn_status): Report KDF attr.
4057         * g10/card-util.c (current_card_status): Output KDF for with_colons.
4058
4059         card: Display if KDF is enabled or not.
4060         + commit 751ff784e5316470f266750d299ae857ad7840d8
4061         * g10/call-agent.h (kdf_do_enabled): New field.
4062         * g10/call-agent.c (learn_status_cb): Set kdf_do_enabled if available.
4063         * g10/card-util.c (current_card_status): Inform the availability.
4064
4065         g10: Fix memory leak for --card-status.
4066         + commit 293001e2c6f0e228ff7f1b6a3e2606ae1370a5d5
4067         * g10/card-util.c (card_status): Release memory of serial number.
4068
4069 2018-12-05  NIIBE Yutaka  <gniibe@fsij.org>
4070
4071         g10: Fix print_pubkey_info new line output.
4072         + commit c5aba093b86e7d69b34ddcf55130f8f21e889b5c
4073         * g10/keylist.c (print_pubkey_info): Reverse the condition.
4074
4075 2018-12-05  Werner Koch  <wk@gnupg.org>
4076
4077         gpg: New list-option "show-only-fpr-mbox".
4078         + commit 9b538451682c704b4036c0ecdb7e6b0ef8570016
4079         * g10/gpg.c (parse_list_options): Add option "show-only-fpr-mbox".
4080         * g10/options.h (LIST_SHOW_ONLY_FPR_MBOX): New.
4081         * g10/keylist.c (list_keyblock_simple): New.
4082         (list_keyblock): Call it.
4083         (list_all): Do not print the keyring name in LIST_SHOW_ONLY_FPR_MBOX
4084         mode.
4085
4086         wks: Fix filter expression syntax flaw.
4087         + commit 80bf1f8901dcbbb2cb6cacc11cca98705ce8f59d
4088         * tools/wks-util.c (wks_get_key, wks_filter_uid): The filter
4089         expression needs a space before the value.
4090         (install_key_from_spec_file): Replace es_getline by es_read_line and
4091         remove debug output.
4092
4093         wks: Allow reading of --install-key arguments from stdin.
4094         + commit b6fd60dfa1709f162c25eb72cf8c45d0ab9bf34f
4095         * tools/wks-util.c (install_key_from_spec_file): New.
4096         (wks_cmd_install_key): Call it.
4097         * tools/gpg-wks-client.c (main): Allow --install-key w/o arguments.
4098         * tools/gpg-wks-server.c (main): Ditto.
4099
4100         (cherry picked from commit ba46a359b9d6549b74ec8401ea39bad434d87564)
4101
4102         wks: Create sub-directories.
4103         + commit bf29d7c822264a40f1469c7b5024d93b955a3a1e
4104         * tools/wks-util.c (wks_compute_hu_fname): Stat and create directory
4105         if needed.
4106
4107         (cherry picked from commit 73e5b0ec9b9ba5e04e55f8c42d81e23df7c3afe0)
4108
4109         wks: Add new commands --install-key and --remove-key to the client.
4110         + commit 5b4aa8c6d4abfa3135ec3ab23decf9bdd624df3e
4111         * tools/gpg-wks-client.c (aInstallKey, aRemoveKey, oDirectory): New.
4112         (opts): Add "--install-key", "--remove-key" and "-C".
4113         (parse_arguments): Parse them.
4114         (main): Check that the given directory exists.  Implement the new
4115         commands.
4116
4117         wks: Move a few server functions to wks-util.
4118         + commit 51b722c6f57b80a3b9caa417b7a74e7fab80043f
4119         * tools/gpg-wks-server.c (write_to_file): Move to ...
4120         * tools/wks-util.c: here.
4121         * tools/gpg-wks-server.c (compute_hu_fname): Move to ...
4122         * tools/wks-util.c (wks_compute_hu_fname): here.
4123         * tools/gpg-wks-server.c (fname_from_userid): Move to ...
4124         * tools/wks-util.c (wks_fname_from_userid): here.
4125         * tools/gpg-wks-server.c (command_install_key): Move to ...
4126         * tools/wks-util.c (wks_cmd_install_key): here and change caller.
4127         * tools/gpg-wks-server.c (command_remove_key): Move to ...
4128         * tools/wks-util.c (wks_cmd_remove_key): here and change callers.
4129
4130         (cherry picked from commit 99094c992c20dd22971beb3527cfda109cd1df89)
4131
4132 2018-12-05  Jussi Kivilinna  <jussi.kivilinna@iki.fi>
4133
4134         g10/mainproc: disable hash contexts when --skip-verify is used.
4135         + commit 6008410e512cb74a4a2ad3f6e3fce4669e4f7e2c
4136         * g10/mainproc.c (proc_plaintext): Do not enable hash contexts when
4137         opt.skip_verify is set.
4138
4139         common/iobuf: fix memory wiping in iobuf_copy.
4140         + commit ebd434a45eefd34bd9d9f875f22a74a47b88dd5f
4141         * common/iobuf.c (iobuf_copy): Wipe used area of buffer instead of
4142         first sizeof(char*) bytes.
4143
4144         common: Use platform memory zeroing function for wipememory.
4145         + commit 21fdef6963539680a16b68b7536378bdaa8dea85
4146         * common/mischelp.h (wipememory): Replace macro with function
4147         prototype.
4148         (wipememory2): Remove.
4149         * common/mischelp.c (wipememory): New.
4150         * configure.ac (AC_CHECK_FUNCS): Check for 'explicit_bzero' and
4151         remove duplicated checks.
4152
4153 2018-12-05  Werner Koch  <wk@gnupg.org>
4154
4155         gpg: Improve error message about failed keygrip computation.
4156         + commit edeebe0a6b9a49d2291d6351d52c5bc688d24cff
4157         * g10/keyid.c (keygrip_from_pk): Print the fingerprint on failure.
4158
4159         (cherry picked from commit cd64af003d4b6b46b69dbd575f73d53359ae0bcc)
4160
4161 2018-11-23  Werner Koch  <wk@gnupg.org>
4162
4163         dirmngr: Avoid possible CSRF attacks via http redirects.
4164         + commit 4a4bb874f63741026bd26264c43bb32b1099f060
4165         * dirmngr/http.h (parsed_uri_s): Add fields off_host and off_path.
4166         (http_redir_info_t): New.
4167         * dirmngr/http.c (do_parse_uri): Set new fields.
4168         (same_host_p): New.
4169         (http_prepare_redirect): New.
4170         * dirmngr/t-http-basic.c: New test.
4171         * dirmngr/ks-engine-hkp.c (send_request): Use http_prepare_redirect
4172         instead of the open code.
4173         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
4174
4175 2018-11-12  Andre Heinecke  <aheinecke@intevation.de>
4176
4177         dirmngr: Add FLUSHCRLs command.
4178         + commit 00321a025f90990a71b60b4689ede1f38fbde347
4179         Summary:
4180         * dirmngr/crlcache.c (crl_cache_flush): Also deinit the cache.
4181         * dirmngr/server.c (hlp_flushcrls, cmd_flushcrls): New.
4182         (register_commands): Add FLUSHCRLS.
4183
4184 2018-11-06  Werner Koch  <wk@gnupg.org>
4185
4186         Release 2.1.11.
4187         + commit cb46b787571ef149856be03b8c3481bb79871698
4188
4189
4190 2018-11-06  NIIBE Yutaka  <gniibe@fsij.org>
4191
4192         g10: Fix print_keygrip for smartcard.
4193         + commit 627839ea88da11a9e8d033e3c91bdf5a048b15c3
4194         * g10/card-util.c (print_keygrip): Use tty_fprintf.
4195
4196 2018-11-05  Werner Koch  <wk@gnupg.org>
4197
4198         wks: New option --with-colons for gpg-wks-client.
4199         + commit 66e0bd37ee3dd5ab534b2664493576ef6ad15a08
4200         * tools/gpg-wks.h (opt): Add field with_colons.
4201         * tools/gpg-wks-client.c (oWithColons): New const.
4202         (opts, parse_arguments): Add option --with-colons.
4203         (main): Change aSupported to take several domains in --with-colons
4204         mode.
4205         (command_send): Factor policy getting code out to ...
4206         (get_policy_and_sa): New function.
4207         (command_supported): Make use of new function.
4208
4209         speedo: Remove obsolete configure option of gpgme.
4210         + commit 593895a5e495c4647efa7db164356f3cae3d5759
4211         * build-aux/speedo.mk (speedo_pkg_gpgme_configure): Remove
4212         --disable-w32-qt option.
4213
4214         dirmngr: In verbose mode print the OCSP responder id.
4215         + commit 50756927ce6247abc2fadefbc76c58b75c8a7586
4216         * dirmngr/ocsp.c (ocsp_isvalid): Print the responder id.
4217
4218         (cherry picked from commit 0a7f446c189201ca6e527af08b44da756b343209)
4219
4220         tools: Replace duplicated code in mime-maker.
4221         + commit d5f540e7a9b3a723ba787e3a587fcd1b0948f105
4222         * tools/rfc822parse.c (HEADER_NAME_CHARS): New.  Taken from
4223         mime-maker.c.
4224         (rfc822_valid_header_name_p): New.  Based on code from mime-maker.c.
4225         (rfc822_capitalize_header_name): New.  Copied from mime-maker.c.
4226         (capitalize_header_name): Remove.  Replace calls by new func.
4227         (my_toupper, my_strcasecmp): New.
4228         * tools/mime-maker.c: Include rfc822parse.h.
4229         (HEADER_NAME_CHARS, capitalize_header_name): Remove.
4230         (add_header): Replace check and capitalization by new functions.
4231
4232         gpg: Don't take the a TOFU trust model from the trustdb,
4233         + commit 82cd7556fdce989aaacf91e0d369a62e4652f224
4234         * g10/tdbio.c (tdbio_update_version_record): Never store a TOFU model.
4235         (create_version_record): Don't init as TOFU.
4236         (tdbio_db_matches_options): Don't indicate a change in case TOFU is
4237         stored in an old trustdb file.
4238
4239         dirmngr: Emit SOURCE status also on NO_DATA.
4240         + commit ab7a907a184f37ddafaa0dc7200c76b735ba4853
4241         * dirmngr/ks-engine-hkp.c (ks_hkp_search): Send SOURCE status also on
4242         NO DATA error.
4243         (ks_hkp_get): Ditto.
4244         * g10/call-dirmngr.c (gpg_dirmngr_ks_search): Print "data source" info
4245         also on error.
4246         (gpg_dirmngr_ks_get): Ditto.
4247
4248         dirmngr: Fix LDAP port parsing.
4249         + commit 5ab58d3001b0342aecaf691b1af70b1f76426f55
4250         * dirmngr/misc.c (host_and_port_from_url): Fix bad port parsing and a
4251         segv for a missing slash after the host name.
4252
4253 2018-10-26  Werner Koch  <wk@gnupg.org>
4254
4255         build: By default build wks-tools on all Unix platforms.
4256         + commit 8a33d5c9c699d2145d39b362d580df67571c5f36
4257         (cherry picked from commit b83fed64f8051279a8f36e024c1f12f7f13c4716)
4258
4259         wkd: Add option --directory to the server.
4260         + commit 839426104a0c829f0182b22048fdc51cf295beb7
4261         * tools/gpg-wks-server.c (opts): Add '--directory',
4262         (main): Explain how to set correct permissions.
4263         (command_list_domains): Create an empty policy file and remove the
4264         warning for an empty policy file.
4265
4266 2018-10-25  Werner Koch  <wk@gnupg.org>
4267
4268         dirmngr: Fix out of scope use of a var in the keyserver LDAP code.
4269         + commit 26ebb15bec897a105b248680c1ddf1806592b1eb
4270         * dirmngr/ks-engine-ldap.c (extract_attributes): Don't use a variabale
4271         out of scope and cleanup the entire pgpKeySize block.
4272
4273 2018-10-24  Werner Koch  <wk@gnupg.org>
4274
4275         agent: Fix possible uninitalized use of CTX in simple_pwquery.
4276         + commit e53253485cd7ceb7012505a629d2cd997167ccab
4277         * common/simple-pwquery.c (agent_open): Clear CTX even on early error.
4278
4279         agent: Fix possible release of unitialize var in a genkey error case.
4280         + commit 62c75271173f83c5770576aae7b84f55a9ccbc16
4281         * agent/command.c (cmd_genkey): Initialize 'value'.
4282
4283         ssh: Fix possible infinite loop in case of an read error.
4284         + commit 147e59b7815daafb32b570a96f1d1925d0f37008
4285         * agent/command-ssh.c (ssh_handler_add_identity): Handle other errors
4286         than EOF.
4287
4288         tools: Fix FILE memory leak in gpg-connect-agent.
4289         + commit f1561e5196e54f11b18050eeaeda50e786d188c2
4290         * tools/gpg-connect-agent.c (do_open): dup the fileno and close the
4291         stream.
4292
4293         (cherry picked from commit 378719f25fe00d46393541f4a4f79e04484c3000)
4294
4295         sm: Use the correct string in an error message.
4296         + commit 1b9b0fc54b9bcd5eb1e63816bd3222d7ac7572a7
4297         * sm/gpgsm.c (main): Fix error message.
4298
4299 2018-10-24  Andre Heinecke  <aheinecke@intevation.de>
4300
4301         dirmngr: Only print info for no ldapserver file.
4302         + commit 01baee2b0ef4f81ac6ffa55480e91168dd27b430
4303         * dirmngr/dirmngr.c (parse_ldapserver_file): Only print info
4304         for ENOENT.
4305
4306 2018-10-23  Andre Heinecke  <aheinecke@intevation.de>
4307
4308         sm: Fix dirmngr loadcrl for intermediate certs.
4309         + commit 6b36c16f77722d17f4f317c788701cbc1e9552b2
4310         * sm/call-dirmngr.c (run_command_inq_cb): Support ISTRUSTED.
4311         (inq_certificate): Distinguish unsupported inquiry error.
4312
4313 2018-10-22  Werner Koch  <wk@gnupg.org>
4314
4315         dirmngr: Prepare for updated WKD specs with ?l= param.
4316         + commit a2bd4a64e5b057f291a60a9499f881dd47745e2f
4317         * dirmngr/server.c (proc_wkd_get): Tack the raw local address to the
4318         request.
4319
4320         gpg: Fix extra check for sign usage of a data signature.
4321         + commit b0d6e26bf3c8decaa568c9e4a5b2451d9af0b25b
4322         * g10/sig-check.c (check_signature_end_simple):
4323
4324 2018-10-15  NIIBE Yutaka  <gniibe@fsij.org>
4325
4326         scd: Fix signing authentication status.
4327         + commit 7e2b0488d13561be2b754e28801de654747a8dcc
4328         * scd/app-openpgp.c (do_sign): Clear DID_CHV1 after signing.
4329
4330 2018-10-02  NIIBE Yutaka  <gniibe@fsij.org>
4331
4332         common: Fix gnupg_reopen_std.
4333         + commit 8f844ae1cd16e27ad07d45784b1f0ff2917da2b8
4334         * common/sysutils.c (gnupg_reopen_std): Use fcntl instead of fstat.
4335
4336 2018-09-10  NIIBE Yutaka  <gniibe@fsij.org>
4337
4338         common: Use iobuf_get_noeof to avoid undefined behaviors.
4339         + commit 0383e7fed7b2a45c7f0ae4c11415c6a9a3a3ddb7
4340         * common/iobuf.c (block_filter): Use iobuf_get_noeof.
4341
4342         agent: Fix error code check from npth_mutex_init.
4343         + commit 213379debe5591dad6339aa95aa7282e0de620f9
4344         * agent/call-pinentry.c (initialize_module_call_pinentry): It's an
4345         error when npth_mutex_init returns non-zero.
4346
4347 2018-09-07  NIIBE Yutaka  <gniibe@fsij.org>
4348
4349         g10: Fix memory leak.
4350         + commit 91f8a9b33a1282cbf00cb4b71b177088f0d923d7
4351         * g10/import.c (read_block): Call free_packet to skip the packet.
4352
4353 2018-09-06  NIIBE Yutaka  <gniibe@fsij.org>
4354
4355         Fix use of strncpy, which is actually good to use memcpy.
4356         + commit f0fdee2e24a25f57a84e1684984ce3921d923e0a
4357         * common/ssh-utils.c (get_fingerprint): Use memcpy.
4358         * g10/build-packet.c (string_to_notation): Use memcpy.
4359
4360 2018-08-30  Werner Koch  <wk@gnupg.org>
4361
4362         Release 2.2.10.
4363         + commit 24697074f44c18eeeedbc1e09d35f56504c57a1f
4364
4365
4366 2018-08-30  Ineiev  <ineiev@gnu.org>
4367
4368         po: Update Russian translation.
4369         + commit 2f5ba3a6c19b7a514488be01b7683287d74545d3
4370
4371
4372 2018-08-29  Werner Koch  <wk@gnupg.org>
4373
4374         gpg: Explain error message in key generation with --batch.
4375         + commit a9931b3c052ee9025705a8ef1f0cdd5f20aeda70
4376         * g10/keygen.c (generate_keypair): Show more info.
4377
4378         gpg: Remove unused function get_pubkeys.
4379         + commit 719fc941b6eceb75c2326335d9d73011823ff3f9
4380         * g10/getkey.c (get_pubkeys): Remove.
4381         (pubkey_free): Remove and use code directly ...
4382         (pubkeys_free): ... here.
4383
4384         (cherry picked from commit ed8fe21e6612401846fc4af8631f0136dc633c67)
4385
4386         gpg: New option --known-notation.
4387         + commit a59a9962f48f828ea7d22362dfa6d82841551110
4388         * g10/gpg.c (oKnownNotation): New const.
4389         (opts): Add option --known-notation.
4390         (main): Set option.
4391         * g10/parse-packet.c (known_notations_list): New local var.
4392         (register_known_notation): New.
4393         (can_handle_critical_notation): Rewrite to handle the new feature.
4394         Also print the name of unknown notations in verbose mode.
4395
4396 2018-08-28  Ineiev  <ineiev@gnu.org>
4397
4398         po: Update Russian translation.
4399         + commit b02ad56a9041273df58ded4cc70cf5ffa9e58c16
4400
4401
4402 2018-08-28  Werner Koch  <wk@gnupg.org>
4403
4404         assuan: Fix exponential decay for first second.
4405         + commit 38eb7c360bc4867cbaf37e3c2c0865bc6452ba4a
4406         * common/asshelp.c (wait_for_sock): Round SECSLEFT.
4407         * dirmngr/dirmngr.c (main): Take care of --debug-wait also in dameon
4408         mode.
4409         * common/sysutils.c (gnupg_usleep) [HAVE_NANOSLEEP]: Fix nanosleep use.
4410
4411 2018-08-28  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
4412
4413         assuan: Use exponential decay for first 1s of spinlock.
4414         + commit 1189df2cd7d4b6896ba22aa204c159ff2a425ead
4415         * common/asshelp.c (wait_for_sock): instead of checking the socket
4416         every second, we check 10 times in the first second (with exponential
4417         decay).
4418
4419         assuan: Reorganize waiting for socket.
4420         + commit a22a55b994e06dd06157fbdabf5a402d8daf69c2
4421         * common/asshelp.c (wait_for_sock): New function, collecting
4422         codepaths from...
4423         (start_new_gpg_agent) here and...
4424         (start_new_dirmngr) here.
4425
4426 2018-08-28  Werner Koch  <wk@gnupg.org>
4427
4428         gpg: Refresh expired keys originating from the WKD.
4429         + commit 0709f358cd13abc82e0f97f055fcaa712f0fd44f
4430         * g10/getkey.c (getkey_ctx_s): New field found_via_akl.
4431         (get_pubkey_byname): Set it.
4432         (only_expired_enc_subkeys): New.
4433         (get_best_pubkey_byname): Add support to refresh expired keys from the
4434         WKD.
4435
4436         gpg: Remove unused arg from a function.
4437         + commit 11a9fe1c5820b97d7e0f4b3e91f016df9dc466a9
4438         * g10/getkey.c (get_best_pubkey_byname): Remove unused arg 'no_akl'.
4439         Change both callers.
4440
4441         (cherry picked from commit db67ccb759426c1173761574b14bdfe6a76394c2)
4442
4443 2018-08-10  NIIBE Yutaka  <gniibe@fsij.org>
4444
4445         g10: Fix undefined behavior when EOF in parsing packet for S2K.
4446         + commit 822c633845066756b6442ca67b93b4b5c4316ca0
4447         * g10/parse-packet.c (parse_symkeyenc): Use iobuf_get_noeof.
4448         (parse_key): Likewise.
4449
4450 2018-07-29  Werner Koch  <wk@gnupg.org>
4451
4452         gpg: Set a limit for a WKD import of 256 KiB.
4453         + commit f1c0d9bb6506eee6a3ad93ef432fe6aa5b72aabd
4454         * g10/call-dirmngr.c (MAX_WKD_RESULT_LENGTH): New.
4455         (gpg_dirmngr_wkd_get): Use it.
4456
4457         dirmngr: Validate SRV records in WKD queries.
4458         + commit 8a98aa25bb4bdbfe53afd4534f6624454ca01ab0
4459         * dirmngr/server.c (proc_wkd_get): Check the returned SRV record names
4460         to mitigate rogue DNS servers.
4461
4462         common: New function to validate domain names.
4463         + commit 4f59187a17f16d559e37a375501a0add1ca7eee8
4464         * common/mbox-util.c (is_valid_domain_name): New.
4465         * common/t-mbox-util.c (run_dns_test): New test.
4466
4467         (cherry picked from commit ddee9f9409fb5a089883eab0fadef7b9b7e61e72)
4468
4469 2018-07-29  Jiří Keresteš  <jiri.kerestes@trustica.cz>
4470
4471         scd: Add support for Trustica Cryptoucan.
4472         + commit d43248af9242d30e95f58285e4f2a2e927aae937
4473         (cherry picked from commit 967d3649d24aba623133808e8d01675dff389fbb)
4474
4475 2018-07-12  Werner Koch  <wk@gnupg.org>
4476
4477         Release 2.2.9.
4478         + commit 2b82db61ccfe57d077dff43e0d732b51c73e1a45
4479
4480
4481 2018-07-09  Werner Koch  <wk@gnupg.org>
4482
4483         gpg: Remove multiple subkey bindings during export-clean.
4484         + commit 61562fe00027a4263f53661ad279072bd0b0133e
4485         * g10/key-clean.c (clean_one_subkey_dupsigs): New.
4486         (clean_all_subkeys): Call it.
4487
4488         gpg: Let export-clean remove expired subkeys.
4489         + commit 8055f186a32e628028de897b7ee4705cd8e999b7
4490         * g10/key-clean.h (KEY_CLEAN_NONE, KEY_CLEAN_INVALID)
4491         (KEY_CLEAN_ENCR, KEY_CLEAN_AUTHENCR, KEY_CLEAN_ALL): New.
4492         * g10/key-clean.c (clean_one_subkey): New.
4493         (clean_all_subkeys): Add arg CLEAN_LEVEL.
4494         * g10/import.c (import_one): Call clean_all_subkeys with
4495         KEY_CLEAN_NONE.
4496         * g10/export.c (do_export_stream): Call clean_all_subkeys depedning on
4497         the export clean options.
4498
4499         gpg: Split key cleaning function for clarity.
4500         + commit 046276db3a04f1907ddcf77c3771832613918226
4501         * g10/key-clean.c (clean_key): Rename to clean_all_uids and split
4502         subkey cleaning into ...
4503         (clean_all_subkeys): new.  Call that always after the former clean_key
4504         invocations.
4505
4506         gpg: Move key cleaning functions to a separate file.
4507         + commit 40bf383f72b5629de739e30c9c35bbcb628273e8
4508         * g10/trust.c (mark_usable_uid_certs, clean_sigs_from_uid)
4509         (clean_uid_from_key, clean_one_uid, clean_key): Move to ...
4510         * g10/key-clean.c: new file.
4511         * g10/key-clean.h: New.
4512         * g10/Makefile.am (gpg_sources): Add new files.
4513         * g10/export.c, g10/import.c, g10/keyedit.c, g10/trustdb.c: Include
4514         new header.
4515         * g10/trustdb.h (struct key_item, is_in_klist): Move to ...
4516         * g10/keydb.h: here.
4517
4518 2018-07-06  Werner Koch  <wk@gnupg.org>
4519
4520         gpg: Allow decryption using several passphrases in may cases.
4521         + commit b4599a0449ead7dc5c0d922aa78b6168e625e15e
4522         * g10/mainproc.c (symkey_decrypt_seskey): Check for a valid algorithm.
4523         (proc_symkey_enc): Clear passpharse on error from above function.
4524
4525 2018-07-05  Werner Koch  <wk@gnupg.org>
4526
4527         po: Add flag options for xgettext.
4528         + commit 833738a316977ee774399bd658d535216dff22e9
4529         * po/Makevars (XGETTEXT_OPTIONS): Add --flag options.
4530
4531         gpg: Prepare for signatures with ISSUER_FPR but without ISSUER.
4532         + commit 221af19351addcdc28a1cd533c8628cfa3841671
4533         * g10/getkey.c (get_pubkey_for_sig): New.
4534         (get_pubkeyblock_for_sig): New.
4535         * g10/mainproc.c (issuer_fpr_raw): Give global scope.
4536         (check_sig_and_print): Use get_pubkeyblock_for_sig.
4537         * g10/pkclist.c (check_signatures_trust): Use get_pubkey_for_sig.
4538         * g10/sig-check.c (check_signature2): Ditto.
4539         (check_signature_over_key_or_uid): Ditto.
4540
4541 2018-07-04  Andre Heinecke  <aheinecke@intevation.de>
4542
4543         po: Fix bug in german translation.
4544         + commit 063cf45c142f33815bc0f31d0fb3e1b25ca57b8c
4545         * po/de.po (decryption forced to fail!): Fix translation.
4546
4547 2018-07-04  Werner Koch  <wk@gnupg.org>
4548
4549         gpg: Ignore too large user ids during import.
4550         + commit cb6b925f94b42c91fe8a7ed8bb22d98984538efc
4551         * g10/import.c (read_block): Add special treatment for bad user ids
4552         and comment packets.
4553
4554         gpg: Extra check for sign usage when verifying a data signature.
4555         + commit ef50fdf82a459894ed3da7b9be83f89658f1eaba
4556         * g10/sig-check.c (check_signature_end_simple): Check sign usage.
4557
4558 2018-07-03  Werner Koch  <wk@gnupg.org>
4559
4560         gpg: Print revocation reason for "rev" records.
4561         + commit 04fb76684d8b2c9cda2e5c35bad6edec521cffa5
4562         * g10/main.h: Add prototype.
4563         * g10/keylist.c (list_keyblock_print): Print revocation info.
4564         (list_keyblock_colon): Ditto.
4565
4566         * g10/test-stubs.c (get_revocation_reason): New stub.
4567         * g10/gpgv.c (get_revocation_reason): New stub.
4568
4569         gpg: Print revocation reason for "rvs" records.
4570         + commit a8e24addcc4e0fdff7d07acdd7e13bf6febf97d2
4571         * g10/import.c (get_revocation_reason): New.
4572         (list_standalone_revocation): Extend function.
4573
4574         gpg: Let --show-keys print revocation certificates.
4575         + commit 5c67ee160d4969b1ef94642ac602e1aed4d9a6d7
4576         * g10/import.c (list_standalone_revocation): New.
4577         (import_revoke_cert): Call new function.
4578
4579 2018-07-03  NIIBE Yutaka  <gniibe@fsij.org>
4580
4581         g10: Fix memory leak for PKT_signature.
4582         + commit 2809be1f97a447171a9e8b40079851740b15341a
4583         * g10/getkey.c (buf_to_sig): Free by free_seckey_enc.
4584         * g10/gpgcompose.c (signature): Likewise.
4585         * g10/sign.c (write_signature_packets): Likewise.
4586
4587 2018-07-02  NIIBE Yutaka  <gniibe@fsij.org>
4588
4589         libdns: For SOCKS connection, just fails.
4590         + commit cca92ca5348999a3564dd54d7b0a103cc9e7640c
4591         * dirmngr/dns.c (dns_res_exec): If it's DNS_SO_SOCKS_CONN, don't
4592         iterate to other server, but return the error immediately.
4593
4594 2018-06-20  NIIBE Yutaka  <gniibe@fsij.org>
4595
4596         libdns: Let kernel to decide the local port.
4597         + commit 72a35ffee022f1bf180d02250c5be6a4edb599e7
4598         * dirmngr/dns.c (LEAVE_SELECTION_OF_PORT_TO_KERNEL): New.
4599         (dns_socket): Don't select ephemeral port in user space.
4600
4601 2018-06-18  NIIBE Yutaka  <gniibe@fsij.org>
4602
4603         libdns: Fix for non-FQDN hostname.
4604         + commit 87d0ecf8a1b80139a6cab2a79f1ca6e287207999
4605         * dirmngr/dns.c (dns_resconf_open): Clear search[0] for non-FQDN
4606         hostname.
4607
4608         libdns: Fix connect and try next nameserver when ECONNREFUSED.
4609         + commit 699fe4b36f62b0f4d4e21a85ee7c9ae13377d6cb
4610         * dirmngr/dns.c (dns_so_check): When EINVAL, release the association
4611         by connect with AF_UNSPEC and try again.  Also try again for
4612         ECONNREFUSED.
4613         (dns_res_exec): Try next nameserver when ECONNREFUSED.
4614
4615         libdns: Clear struct sockaddr_storage by zero.
4616         + commit 0c05b08e8b5c1f120fe5f3ed5c061f034f7496a0
4617         * dirmngr/dns.c (dns_resconf_pton): Clear SS.
4618         (dns_resconf_setiface): Clear ->IFACE.
4619         (dns_hints_root, send_query): Clear SS.
4620
4621         libdns: Sync to upstream.
4622         + commit 20c289606f89803929948ddd18910acff2acc9eb
4623         * dirmngr/dns.c (dns_nssconf_loadfile): Handle exclamation mark.
4624
4625         dirmngr: Fix recursive resolver mode.
4626         + commit 13320db678675246f4bb5a3fb6ece143f37c34a4
4627         * dirmngr/dns-stuff.c (libdns_init): Initialize options.recurse.
4628
4629 2018-06-12  Werner Koch  <wk@gnupg.org>
4630
4631         gpg: Do not import revocations with --show-keys.
4632         + commit e8f439e0547463c24f3c10008fee73e6c4259f52
4633         * g10/import.c (import_revoke_cert): Add arg 'options'.  Take care of
4634         IMPORT_DRY_RUN.
4635
4636 2018-06-12  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
4637
4638         gpg: Add new usage option for drop-subkey filters.
4639         + commit 86b64876bef0d8c4be8e309fcf3e2ce21e65a947
4640         * g10/import.c (impex_filter_getval): Add new "usage" property for
4641         drop-subkey filter.
4642
4643 2018-06-11  Werner Koch  <wk@gnupg.org>
4644
4645         gpg: Set some list options with --show-keys.
4646         + commit cbb84b3361263504dcb958208bc20177cb97cebd
4647         * g10/gpg.c (main): Set some list options.
4648
4649 2018-06-08  Werner Koch  <wk@gnupg.org>
4650
4651         gpg: Allow building with older libgpg-error.
4652         + commit 18274db32b5dea7fe8db67043a787578c975de4d
4653         * g10/mainproc.c (proc_encrypted): Use constant from logging.h
4654
4655         Release 2.2.8.
4656         + commit cd9aaa7862955846f8adf819cd89d0db33e9c08c
4657
4658
4659 2018-06-08  Ineiev  <ineiev@gnu.org>
4660
4661         po: Update Russian translation.
4662         + commit 77ab99f80a5b0fbc60e05230185a54cd200d5e65
4663
4664
4665 2018-06-08  Werner Koch  <wk@gnupg.org>
4666
4667         gpg: Sanitize diagnostic with the original file name.
4668         + commit 210e402acd3e284b32db1901e43bf1470e659e49
4669         * g10/mainproc.c (proc_plaintext): Sanitize verbose output.
4670
4671 2018-06-07  Werner Koch  <wk@gnupg.org>
4672
4673         gpg: Improve import's repair-key duplicate signature detection.
4674         + commit 6a87a0bd2501d82f4a6263608e4856e841305caf
4675         * g10/key-check.c (key_check_all_keysigs): Factor some code out to ...
4676         (remove_duplicate_sigs): new.
4677         (key_check_all_keysigs): Call remove_duplicate_sigs again after
4678         reordering.
4679
4680         gpg: Fix import's repair-key duplicate signature detection.
4681         + commit cedd754fcb03f6dad6e462efc3d347bcef4ec83a
4682         * g10/packet.h (PKG_siganture): Add field 'help_counter'.
4683         * g10/key-check.c (sig_comparison): Take care of HELP_COUNTER.
4684         (key_check_all_keysigs): De-duplicate on a per-block base.
4685
4686         gpg: Improve verbose output during import.
4687         + commit 36cc730fa516b3a197f3bb1eb6f3881dd128fbb7
4688         * g10/import.c (chk_self_sigs): Print the subkeyid in addition to the
4689         keyid.
4690         (delete_inv_parts): Ditto.
4691
4692         (cherry picked from commit 1bc6b5174248ba4d83d648ef6d6f4550540d1f20)
4693
4694 2018-06-06  Werner Koch  <wk@gnupg.org>
4695
4696         agent: Add DBUS_SESSION_BUS_ADDRESS et al. to the startup list.
4697         + commit c5c8fb1ec7c8690495de6189ec2c3a322db4e881
4698         * agent/gpg-agent.c (agent_copy_startup_env): Replace explicit list
4699         with the standard list.
4700
4701         gpg: Also detect a plaintext packet before an encrypted packet.
4702         + commit 054a187f24b19313cec59414fa924640e1b8c79c
4703         * g10/mainproc.c (proc_encrypted): Print warning and later force an
4704         error.
4705
4706         gpg: New command --show-keys.
4707         + commit dc87a3341f28ddac1113e90a3861d062be2610e2
4708         * g10/gpg.c (aShowKeys): New const.
4709         (opts): New command --show-keys.
4710         (main): Implement command.
4711         * g10/import.c (import_keys_internal): Don't print stats in show-only
4712         mode.
4713         (import_one): Be silent in show-only mode.
4714
4715 2018-05-31  Werner Koch  <wk@gnupg.org>
4716
4717         gpg: Print a hint on how to decrypt a non-mdc message anyway.
4718         + commit 825909e9cd5f344ece6c0b0ea3a9475df1d643de
4719         * g10/mainproc.c (proc_encrypted): Print a hint for legacy ciphers w/o
4720         MDC.  Also print a dedicated status error code
4721
4722         (cherry picked from commit 874e391665405fc413a69f2ffacdb94bb08da7ff)
4723
4724         gpg: Detect multiple literal plaintext packets more reliable.
4725         + commit 2f2b1d1da949e8fce28d3c4a934b4097d6f24295
4726         * g10/mainproc.c (proc_encrypted): Bump LITERALS_SEEN.
4727
4728         gpg: Remove MDC options.
4729         + commit 866667765f38bf65b612191209d0f0a87fb16393
4730         * g10/gpg.c: Turn options --force-mdc, --no-force-mdc, --disable-mdc
4731         and --no-disable-mdc into NOPs.
4732         * g10/encrypt.c (use_mdc): Simplify.  MDC is now almost always used.
4733         * g10/cipher.c (write_header): Include extra hint and make
4734         translatable.
4735         * g10/options.h (struct opt): Remove fields force_mdc and disable_mdc.
4736
4737         gpg: Hard fail on a missing MDC even for legacy algorithms.
4738         + commit 3db1b48a2da42942cb5a57281441167901bdcdc8
4739         * g10/mainproc.c (proc_encrypted): Require an MDC or AEAD
4740         * tests/openpgp/defs.scm (create-gpghome): Use --ignore-mdc-error to
4741         allow testing with the current files.
4742
4743         gpg: Turn --no-mdc-warn into a NOP.
4744         + commit 26c0d3a3fc903c1a0de644ebcc99d3e665a80941
4745         * g10/gpg.c (oNoMDCWarn): Remove.
4746         (opts): Make --no-mdc-warn a NOP.
4747         (main): Don't set var.
4748         * g10/options.h (struct opt): Remove 'no_mdc_var'.
4749         * g10/cipher-cfb.c (write_header): Assume opt.no_mdc_warn is false.
4750         * g10/mainproc.c (proc_encrypted): Ditto.
4751
4752 2018-05-07  Ineiev  <ineiev@gnu.org>
4753
4754         doc: Update description of displayed trust values.
4755         + commit ed12a1dabaf928e8620fc26ca426c935e1a8a880
4756         * doc/trust-values.texi: New file.
4757         * doc/Makefile.am (EXTRA_DIST): Add trust-values.texi.
4758         * doc/gnupg.texi (Trust Values): New chapter.
4759         * doc/gpg.texi (OpenPGP Key Management): Update the description
4760         of how trust values are displayed, replace table with a reference
4761         to Trust Values.
4762         * doc/gpg.texi (GPG Examples): Add @mansect trust values.
4763
4764 2018-05-02  Werner Koch  <wk@gnupg.org>
4765
4766         Release 2.2.7.
4767         + commit d31d149196832ed6b8849017d8bcd0852c6ca96c
4768
4769
4770         gpg: Fix minor memory leak in the compress filter.
4771         + commit d26363e4f1933781c86cbe87077fbf1b9a2b64d8
4772         * g10/compress.c (push_compress_filter2): Return an error if no filter
4773         was pushed.
4774         (push_compress_filter): Ditto.
4775         (handle_compressed): Free CFX if no filter was pushed.
4776         * g10/import.c (read_block): Ditto.
4777
4778         gpg: Fix "Too many open files" when using --multifile.
4779         + commit f7f3043653abe699602f910ddd09c1405675c7f6
4780         * common/miscellaneous.c (is_file_compressed): Don't cache the file.
4781
4782         dirmngr: Implement timeout for dirmngr_ldap under Windows.
4783         + commit 007dde93cc3971cb51d08e8c082e172506ae7f80
4784         * dirmngr/dirmngr_ldap.c (alarm_thread) [W32]: New.
4785         (set_timeout): Implement for W32.
4786
4787         build: New configure option to help with nPth debugging.
4788         + commit ddfd39e91a532fd31cd0c20c5d4cf9643acc58bd
4789         * configure.ac: Add option --enable-npth-debug
4790
4791 2018-05-02  Andre Heinecke  <aheinecke@intevation.de>
4792
4793         common,w32: Hide spawned processes by default.
4794         + commit 3bd793256e2e4be52075d50ccf2df70c4a2e1a0f
4795         * common/exechelp-w32.c (gnupg_spawn_process): Use SW_HIDE
4796         instead of SW_MINIMIZE.
4797
4798 2018-04-30  Werner Koch  <wk@gnupg.org>
4799
4800         dirmngr: Sleep in the ldap wrapper thread.
4801         + commit a598bbeeafa30f7854230eed212b76d5c5c77f86
4802         * dirmngr/ldap-wrapper.c (wrapper_list): Rename to reaper_list.
4803         (ldap_reaper_thread): Protect all list modification with a mutex.  Use
4804         a condition var to wake up the reaper thread.
4805
4806 2018-04-27  Werner Koch  <wk@gnupg.org>
4807
4808         dirmngr: Use the LDAP wrapper process also for Windows.
4809         + commit f9fbfc64e402bd41815a68426f55565fa6d5c726
4810         * dirmngr/ldap-wrapper.c: Revamp module to make use of es_poll for
4811         portability.
4812         * configure.ac: Always use the ldap wrapper.
4813
4814         dirmngr: Silence log output from dirmngr_ldap.
4815         + commit d22506a343cec61b7d1a48c970b63a8458b267ab
4816         * dirmngr/dirmngr_ldap.c: Remove assert.h.
4817         (main): Replace assert by log_assert.
4818         * dirmngr/ldap.c (run_ldap_wrapper): Use debug options to pass
4819         verbose options to dirmngr_ldap.
4820         (start_cert_fetch_ldap): Ditto.
4821
4822 2018-04-26  Werner Koch  <wk@gnupg.org>
4823
4824         dirmngr: Lower the dead host resurrection time to 1.5h.
4825         + commit 5789afc840cf79ba2a8cebd9d772ef9c3868c5e9
4826         * dirmngr/ks-engine-hkp.c (RESURRECT_INTERVAL): Decrease.
4827         (INITIAL_HOSTTABLE_SIZE): Increase because the old values was likely
4828         for development.
4829
4830         dirmngr: Fix handling of CNAMEed keyserver pools.
4831         + commit cc66108253c58583d6bad3d1e2da2b004701d0f0
4832         * dirmngr/ks-engine-hkp.c (map_host): Don't use the cname for HTTPHOST.
4833         * dirmngr/server.c (make_keyserver_item): Map keys.gnupg.net.
4834
4835 2018-04-25  Werner Koch  <wk@gnupg.org>
4836
4837         dirmngr: Add the used TLS library to the debug output.
4838         + commit bb8894760fe87cf46a42599f11eab7e7c7a8eb71
4839         * dirmngr/http.c (send_request): Print the used TLS library in debug
4840         mode.
4841
4842         dirmngr: Allow redirection from https to http for CRLs.
4843         + commit 1de4462974113ac18cf98f903e97cd1127fa842f
4844         * dirmngr/ks-engine.h (KS_HTTP_FETCH_NOCACHE): New flag.
4845         (KS_HTTP_FETCH_TRUST_CFG): Ditto.
4846         (KS_HTTP_FETCH_NO_CRL): Ditto.
4847         (KS_HTTP_FETCH_ALLOW_DOWNGRADE): Ditto.
4848         * dirmngr/ks-engine-http.c (ks_http_fetch): Replace args send_no_cache
4849         and extra_http_trust_flags by a new flags arg.  Allow redirectiong
4850         from https to http it KS_HTTP_FETCH_ALLOW_DOWNGRADE is set.
4851         * dirmngr/loadswdb.c (fetch_file): Call with KS_HTTP_FETCH_NOCACHE.
4852         * dirmngr/ks-action.c (ks_action_get): Ditto.
4853         (ks_action_fetch): Ditto.
4854         * dirmngr/crlfetch.c (crl_fetch): Call with the appropriate flags.
4855
4856         dirmngr: Implement CRL fetching via https.
4857         + commit 705d8e9cf0d109005b3441766270c0e584f7847d
4858         * dirmngr/http.h (HTTP_FLAG_TRUST_CFG): New flag.
4859         * dirmngr/http.c (http_register_cfg_ca): New.
4860         (http_session_new) [HTTP_USE_GNUTLS]: Implement new trust flag.
4861         * dirmngr/certcache.c (load_certs_from_dir): Call new function.
4862         (cert_cache_deinit): Ditto.
4863         * dirmngr/http-ntbtls.c (gnupg_http_tls_verify_cb): Ditto.
4864         * dirmngr/ks-engine-http.c (ks_http_fetch): Add new args
4865         'send_no_cache' and 'extra_http_trust_flags'.  Change all callers to
4866         provide the default value.
4867         * dirmngr/crlfetch.c (crl_fetch): Rewrite to make use of
4868         ks_http_fetch.
4869
4870 2018-04-25  NIIBE Yutaka  <gniibe@fsij.org>
4871
4872         g10: Fix printing the keygrip with --card-status.
4873         + commit 71903eee89496e3f1d0a24536bced6ff16df6783
4874         * g10/card-util.c (current_card_status): Keygrip for Auth is 3.
4875
4876 2018-04-24  Werner Koch  <wk@gnupg.org>
4877
4878         dirmngr: Fallback to CRL if no default OCSP responder is configured.
4879         + commit 460e3812be711bd18195053d74aa736215f21eee
4880         * dirmngr/server.c (cmd_isvalid): Use option second arg to trigger
4881         OCSP checkibng.  Fallback to CRL if no default OCSP responder has been
4882         configured.
4883         * sm/call-dirmngr.c (gpgsm_dirmngr_isvalid): Adjust accordingly.
4884
4885 2018-04-20  Andre Heinecke  <aheinecke@intevation.de>
4886
4887         dirmngr: More binary I/O on Windows for CRLs.
4888         + commit 64c1fddb253061a9773c6c4ed2a9c5a54702d21b
4889         * dirmngr/crlcache.c (lock_db_file, crl_cache_insert): Open cache
4890         file in binary mode.
4891
4892         doc: Remove unneccesary empty flags in vsndf.prf.
4893         + commit a44ed3d9a1ad5bd96694f10ea5523c517982017e
4894         * doc/examples/vsnfd.prf (max-cache-ttl): Remove empty flags.
4895
4896 2018-04-16  emma peel  <emma.peel@aktivix.org>
4897
4898         po: more updates to Spanish translation.
4899         + commit acd6d5ff7436bb7fba171ced3294046a14fb777d
4900
4901
4902         po: correct attribution for Spanish translation.
4903         + commit 21b2e88a7e6c3d7313773c9ffb3e0d1fb2af45df
4904
4905
4906         po: correct label tags in Polish translation.
4907         + commit a5290dace7f85d66272af3e14f9f2bc43d2a4af8
4908
4909
4910         po: correct label tags in Finnish translation.
4911         + commit e12475429578add12a53fb2232cb45dc9e2aae1b
4912
4913
4914 2018-04-15  Werner Koch  <wk@gnupg.org>
4915
4916         build: New target "release" to automate the release process.
4917         + commit 3b1ee413a65bf566aa8e5f29a5a2cd5a94e66faa
4918         * Makefile.am (RELEASE_ARCHIVE_DIR): New.
4919         (RELEASE_SIGNING_KEY): New.
4920         (AM_DISTCHECK_CONFIGURE_FLAGS): Remove removed --enable-gpg2-is-gpg,
4921         (RELEASE_NAME, RELEASE_W32_STEM_NAME): New.
4922         (release, sign-release): New.
4923
4924 2018-04-13  NIIBE Yutaka  <gniibe@fsij.org>
4925
4926         g10: Fix memory leak in check_sig_and_print.
4927         + commit f747b8f0734338baa1e608b193b213aca2c577e8
4928         * g10/mainproc.c (check_sig_and_print): Free the public key.
4929
4930         g10: Push compress filter only if compressed.
4931         + commit c31abf84659dbda5503dd9f3aa3449520bcd1b84
4932         * g10/compress.c (handle_compressed): Fix memory leak.
4933
4934 2018-04-12  Werner Koch  <wk@gnupg.org>
4935
4936         gpg: Extend the "sig" record in --list-mode.
4937         + commit 69c3e7acb744e1e5606a4d946e3b948704cfbbae
4938         * g10/getkey.c (get_user_id_string): Add arg R_NOUID.  Change call
4939         callers.
4940         (get_user_id): Add arg R_NOUID.  Change call callers.
4941         * g10/mainproc.c (issuer_fpr_string): Make global.
4942         * g10/keylist.c (list_keyblock_colon): Print a '?' for a missing key
4943         also in --list-mode.  Print the "issuer fpr" field also if there is an
4944         issuer fingerprint subpacket.
4945
4946         gpg: Extend the ERRSIG status line with a fingerprint.
4947         + commit 23a714598c247d78cfda46a6dc338b17e17cc194
4948         * g10/mainproc.c (issuer_fpr_raw): New.
4949         (issuer_fpr_string): Re-implement using issuer_fpr_rtaw.
4950         (check_sig_and_print): Don't free ISSUER_FPR.  Use ISSUER_FPR_RAW.
4951         Use write_status_printf.  Extend ERRSIG status.
4952
4953         gpg: Relax printing of STATUS_FAILURE.
4954         + commit e2bd152a928d79ddfb95fd2f7911c80a1a8d5a21
4955         * g10/gpg.c (g10_exit): Print STATUS_FAILURE only based on passed
4956         return code and not on the presence of any call to log_error.
4957
4958         agent,dirmngr: Add "getenv" to the getinfo command.
4959         + commit bbb5bfacc0d1f179cfec94fd32fee01a09df0f1d
4960         * agent/command.c (cmd_getinfo): Add sub-command getenv.
4961         * dirmngr/server.c (cmd_getinfo): Ditto.
4962
4963 2018-04-12  Andre Heinecke  <aheinecke@intevation.de>
4964
4965         build: Update getswdb version check to 2.2.
4966         + commit 327fece0aed2c9974659c72304f9fd1f461d460c
4967         * build-aux/getswdb.sh: Check for gnupg22_ver gnupg21_ver no
4968         longer exists.
4969
4970 2018-04-11  Werner Koch  <wk@gnupg.org>
4971
4972         gpg: New option --no-symkey-cache.
4973         + commit 789d240cb40ab36406a7c57ad49897e0bafbb41e
4974         * g10/gpg.c (oNoSymkeyCache): New.
4975         (opts): Add that option.
4976         (main): Set var.
4977         * g10/options.h (struct opt): New field no_symkey_cache.
4978         * g10/passphrase.c (passphrase_to_dek): Implement that feature.
4979
4980 2018-04-10  Werner Koch  <wk@gnupg.org>
4981
4982         agent: Improve the unknown ssh flag detection.
4983         + commit 9f69dbeb902ac447adbc92937cd451c4e909f234
4984         * agent/command-ssh.c (ssh_handler_sign_request): Simplify detection
4985         of flags.
4986
4987 2018-04-10  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
4988
4989         agent: unknown flags on ssh signing requests cause an error.
4990         + commit 381c46818ffa4605d0ca39818fe317de445eb6de
4991         * agent/command-ssh.c (ssh_handler_sign_request): if a flag is passed
4992         during an signature request that we do not know how to apply, return
4993         GPG_ERR_UNKNOWN_OPTION.
4994
4995         agent: change documentation reference for ssh-agent protocol.
4996         + commit 55435cdd4fe4fbfbcba1098bb715ecd6171ba2d8
4997         * agent/command-ssh.c: repoint documentation reference.
4998
4999 2018-04-09  Werner Koch  <wk@gnupg.org>
5000
5001         Release 2.2.6.
5002         + commit 6fbe2ddbaf5123ae444c95fdf8da67840f794c76
5003
5004
5005         gpg,w32: Fix empty homedir when only a drive letter is used.
5006         + commit 6da7aa1e7c80d214bd9dccb21744919ae191f2c8
5007         * common/homedir.c (copy_dir_with_fixup): New.
5008         (default_homedir): Use here.
5009         (gnupg_set_homedir): And here .
5010
5011         doc: Document --key-edit:change-usage.
5012         + commit a4e26f2ee852003707857ab0635b783acb89a2f8
5013         * g10/keyedit.c (menu_changeusage): Make strings translatable.
5014
5015 2018-04-06  Werner Koch  <wk@gnupg.org>
5016
5017         gpg: Check that a key may do certifications.
5018         + commit 1a5d95e7319e7e6f0dd11064a26cbbc371b05214
5019         * g10/sig-check.c (check_signature_end_simple): Check key usage for
5020         certifications.
5021         (check_signature_over_key_or_uid): Request usage certification.
5022
5023         gpg: Emit FAILURE stati now in almost all cases.
5024         + commit 0336e5d1a7b9d46e06c838e6a98aecfcc9542882
5025         * g10/cpr.c (write_status_failure): Make it print only once.
5026         * g10/gpg.c (wrong_args): Bump error counter.
5027         (g10_exit): Print a FAILURE status if we ever did a log_error etc.
5028         (main): Use log_error instead of log_fatal at one place.  Print a
5029         FAILURE status for a bad option.  Ditto for certain exit points so
5030         that we can see different error locations.
5031
5032         gpg: Re-indent sig-check.c and use signature class macros.
5033         + commit 5ba74a134db431530884f03eea5410a68dbfe0f5
5034         * g10/keydb.h (IS_BACK_SIG): New.
5035         * g10/sig-check.c: Re-indent and use macros.
5036
5037 2018-04-06  NIIBE Yutaka  <gniibe@fsij.org>
5038
5039         agent: Support SSH signature flags.
5040         + commit 80b775bdbb852aa4a80292c9357e5b1876110c00
5041         * agent/command-ssh.c (SSH_AGENT_RSA_SHA2_256): New.
5042         (SSH_AGENT_RSA_SHA2_512): New.
5043         (ssh_handler_sign_request): Override SPEC when FLAGS
5044         is specified.
5045
5046 2018-04-05  NIIBE Yutaka  <gniibe@fsij.org>
5047
5048         g10: Let card-edit/key-attr show message when change.
5049         + commit 870527df0dd704c994928348c8c2910030776680
5050         * g10/card-util.c (ask_card_rsa_keysize): Don't show message here.
5051         (ask_card_keyattr): Show message when change, also for ECC.
5052
5053 2018-04-04  NIIBE Yutaka  <gniibe@fsij.org>
5054
5055         tests: Fix no gpg-agent upon removal of GNUPGHOME.
5056         + commit 83529e1bd14a6d39f2a8ecab9fb6aa4c1f344c73
5057         * tests/gpgscm/gnupg.scm (with-ephemeral-home-directory): Add
5058         teadown-fn.
5059         * tests/gpgsm/export.scm: Use -no-atexit version and stop-agent.
5060         * tests/openpgp/decrypt-session-key.scm: Likewise.
5061         * tests/openpgp/decrypt-unwrap-verify.scm: Likewise.
5062         * tests/openpgp/defs.scm (have-opt-always-trust): Likewise.
5063         (setup-environment-no-atexit): New.
5064         (start-agent): Support no use of atexit.
5065         * tests/gpgsm/gpgsm-defs.scm (setup-gpgsm-environment-no-atexit): New.
5066         * tests/migrations/common.scm (untar-armored): Follow the change
5067         of with-ephemeral-home-directory.
5068
5069 2018-04-03  NIIBE Yutaka  <gniibe@fsij.org>
5070
5071         scd: Writing KDF resets auth state.
5072         + commit cb1731c23cddfa524d3f51cfd82029bff853a073
5073         * scd/app-openpgp.c (do_setattr): Clear auth state.
5074
5075 2018-04-02  NIIBE Yutaka  <gniibe@fsij.org>
5076
5077         g10: Fix filtering by PK->REQ_USAGE.
5078         + commit a17d2d1f690ebe5d005b4589a5fe378b6487c657
5079         * g10/getkey.c (get_pubkey_byfprint): Filter by PK->REQ_USAGE.
5080
5081 2018-03-30  NIIBE Yutaka  <gniibe@fsij.org>
5082
5083         g10: Fix card-edit/kdf-setup for single salt.
5084         + commit 130ad98240c066383fa0a99bcf5e0ec72bc0dff9
5085         * g10/card-util.c (gen_kdf_data): Use SALT_USER.
5086
5087         g10,scd: Support single salt for KDF data object.
5088         + commit 0c097575a9cd923f648fb5bb695893d46400c3ad
5089         * g10/card-util.c (gen_kdf_data): Support single salt.
5090         (kdf_setup): Can have argument for single salt.
5091         * scd/app-openpgp.c (pin2hash_if_kdf): Support single salt.
5092
5093         g10: Add "key-attr" command for --card-edit.
5094         + commit 820380335a20391e0998fb1ba32ebfb9accedc5b
5095         * g10/card-util.c (key_attr): New explicit command.
5096         (generate_card_keys, card_generate_subkey): Don't ask key attr change.
5097         (card_edit): Add for cmdKEYATTR.
5098
5099         scd: Support changing key attribute back to RSA.
5100         + commit 29692718768c28c524be6306081ab1852e75fe07
5101         * scd/app-openpgp.c (change_rsa_keyattr): Try usual RSA.
5102
5103 2018-03-29  NIIBE Yutaka  <gniibe@fsij.org>
5104
5105         g10: Support key attribute change at --card-edit/generate.
5106         + commit a1515b3bbc10a210040dda3b482bcdb933fa8d7c
5107         * g10/card-util.c (ask_card_rsa_keysize): Drop support for magic
5108         number 25519 for ed25519/cv25519.  Rename from ask_card_keyattr.
5109         (ask_card_keyattr): Support ECC, as well as RSA.
5110         (do_change_keyattr): Support ECC dropping magical number 25519.
5111         * g10/keygen.c (ask_curve): Allow call from outside, adding last arg
5112         of CURRENT.
5113         (generate_keypair): Follow the change of ask_curve.
5114         (generate_subkeypair): Likewise.
5115
5116         g10: check_pin_for_key_operation should be just before genkey.
5117         + commit 02d7bb819ff44cc90212568dd6ce24ae1dc5d17f
5118         * g10/card-util.c (generate_card_keys): Check PIN later.
5119         (card_generate_subkey): Likewise.
5120
5121 2018-03-28  NIIBE Yutaka  <gniibe@fsij.org>
5122
5123         g10: Change ask_curve so that it can be used outside.
5124         + commit e610d51f0de11154050915b951bcc5c53c940f5e
5125         * g10/call-agent.h (struct key_attr): New.
5126         * g10/keygen.c (ask_curve): Return const char *.  No allocation.
5127         (quick_generate_keypair): Follow the change.
5128         (generate_keypair, generate_subkeypair): Likewise.
5129         (parse_algo_usage_expire): Return const char *.
5130
5131 2018-03-27  NIIBE Yutaka  <gniibe@fsij.org>
5132
5133         agent,scd: Use pointer to represent HANDLE.
5134         + commit 96918346beeca7a46de9f03f19502373994c21bc
5135         * agent/call-scd.c [HAVE_W32_SYSTEM] (start_scd): Format with %p.
5136         * scd/command.c [HAVE_W32_SYSTEM] (option_handler): Use void *.
5137
5138 2018-03-27  Werner Koch  <wk@gnupg.org>
5139
5140         agent: Make the request origin a part of the cache items.
5141         + commit 02dce8c0cc57deb2095a9b06aeb8f4dea34eef7e
5142         * agent/cache.c (agent_put_cache): Add arg 'ctrl' and change all
5143         callers to pass it.
5144         (agent_get_cache): Ditto.
5145
5146         * agent/cache.c (struct cache_items_s): Add field 'restricted'.
5147         (housekeeping): Adjust debug output.
5148         (agent_flush_cache): Ditto.
5149         (agent_put_cache): Ditto.  Take RESTRICTED into account.
5150         (agent_get_cache): Ditto.
5151
5152 2018-03-26  Werner Koch  <wk@gnupg.org>
5153
5154         gpg: Auto-fix a broken trustdb with just the version record.
5155         + commit eb68c2d3d1b03a18cd24406fa46d4c30cb13d9f7
5156         * g10/tdbio.c (get_trusthashrec): Create hashtable on error.
5157
5158         gpg: Pass CTRL arg to get_trusthashrec.
5159         + commit a750ebebf35a392f1c72d6aee5618df0d9f25ff7
5160         * g10/tdbio.c (get_trusthashrec): Add arg CTRL.
5161         (tdbio_search_trust_byfpr): Ditto.
5162         (tdbio_search_trust_bypk): Ditto.
5163
5164         gpg: Return better error codes in case of a too short trustdb.
5165         + commit 403aa70c52e56614d65490dea9344113f9cf3d29
5166         * g10/tdbio.c (tdbio_read_record): Return GPG_ERR_EOF.
5167         (tdbio_new_recnum): Never return on error.
5168         (lookup_hashtable): Print a more descriptive error in case of !TABLE.
5169
5170         gpg: Fix trustdb updates without lock held.
5171         + commit 456a3a8e93ea14f821e0e98fb515f284ece98685
5172         * g10/tdbio.c (is_locked): Turn into a counter.
5173         (take_write_lock, release_write_lock): Implement recursive locks.
5174
5175         gpg: Disable unused code parts in tdbio.c.
5176         + commit 5f00531463ebc0e606c502696962426007545bb7
5177         * g10/tdbio.c (in_transaction): Comment this var.
5178         (put_record_into_cache): Comment the transaction code.
5179         (tdbio_sync): Ditto
5180
5181 2018-03-23  Werner Koch  <wk@gnupg.org>
5182
5183         sm: Add OPTION request-origin.
5184         + commit 137644c9cb58deaaba6850f2763d9c5f9241cb0b
5185         * sm/server.c: Include shareddefs.h.
5186         (option_handler): Add option.
5187
5188         gpg,sm: New option --request-origin.
5189         + commit 2cd35df5db3c4dfe37616dcfb1fcc644959449ef
5190         * g10/gpg.c (oRequestOrigin): New const.
5191         (opts): New option --request-origin.
5192         (main): Parse that option.
5193         * g10/options.h (struct opt): Add field request_origin.
5194         * g10/call-agent.c (start_agent): Send option to the agent.
5195         * sm/gpgsm.c (oRequestOrigin): New const.
5196         (opts): New option --request-origin.
5197         (main): Parse that option.
5198         * sm/gpgsm.h (struct opt): Add field request_origin.
5199         * sm/call-agent.c (start_agent): Send option to the agent.
5200
5201         agent: New OPTION pretend-request-origin.
5202         + commit 05c55ee260edc07cd19da56dfd00347bfe3f529c
5203         * common/shareddefs.h (request_origin_t): New.
5204         * common/agent-opt.c (parse_request_origin): New.
5205         (str_request_origin): New.
5206         * agent/command.c (option_handler): Implement new option.
5207
5208 2018-03-23  NIIBE Yutaka  <gniibe@fsij.org>
5209
5210         build: Fix the manual source field.
5211         + commit 5400a5bb77bddcb14c94d9405312d6181322b090
5212
5213
5214 2018-03-22  Werner Koch  <wk@gnupg.org>
5215
5216         gpg: Implement --dry-run for --passwd.
5217         + commit 165bc38cefbc03515403b60b704cabf4dc0b71f4
5218         * g10/keyedit.c (change_passphrase): Take care of --dry-run.
5219
5220 2018-03-22  NIIBE Yutaka  <gniibe@fsij.org>
5221
5222         scd: Support KDF DO setup.
5223         + commit 0152ba7c987443d641ce1091c79f90ef2cc46498
5224         * g10/call-agent.c (learn_status_cb): Parse the capability for KDF.
5225         * g10/card-util.c (gen_kdf_data, kdf_setup): New.
5226         (card_edit): New admin command cmdKDFSETUP to call kdf_setup.
5227         * scd/app-openpgp.c (do_getattr): Emit KDF capability.
5228
5229 2018-03-21  Werner Koch  <wk@gnupg.org>
5230
5231         gpg: Fix out-of-bound read in subpacket enumeration.
5232         + commit 983f7b2acbd1e7580652bbeb0c3d64f9dd19d9e4
5233         * g10/parse-packet.c (enum_sig_subpkt): Check buflen before reading
5234         the type octet.  Print diagnostic.
5235
5236 2018-03-19  NIIBE Yutaka  <gniibe@fsij.org>
5237
5238         scd: signal mask should be set just after npth_init.
5239         + commit 11bbd99477ef5ba5b7db0c17607b10af03c68afb
5240         * scd/scdaemon.c (setup_signal_mask): New.
5241         (main): Call setup_signal_mask.
5242         (handle_connections): Remove signal mask setup.
5243
5244 2018-03-16  NIIBE Yutaka  <gniibe@fsij.org>
5245
5246         scd: Better user interaction for factory-reset.
5247         + commit 2c85e202bc30231b9555100dec0c490c60d7b88c
5248         * g10/card-util.c (factory_reset): Dummy PIN size is now 32-byte.
5249         Connect the card again at the last step.
5250
5251 2018-03-15  NIIBE Yutaka  <gniibe@fsij.org>
5252
5253         scd: Fix suspend/resume handling for CCID driver.
5254         + commit fd23a0524d8060ed12d87c679b7823686614aaee
5255         * scd/ccid-driver.c (intr_cb): Try submitting INTERRUPT urb
5256         to see if it's suspend/resume.
5257
5258 2018-03-13  NIIBE Yutaka  <gniibe@fsij.org>
5259
5260         scd: After fatal error, shutdown a reader.
5261         + commit c84bae69e9e02923f7180e09d161cb0b13257436
5262         * scd/apdu.c (pcsc_send_apdu): Notify main loop after
5263         fatal errors.
5264
5265         scd: Fix for GNU/Linux suspend/resume.
5266         + commit 71e5282c25ba812c7091e587edd721839bc4c2ac
5267         * configure.ac (require_pipe_to_unblock_pselect): Default is "yes".
5268         * scd/scdaemon.c (scd_kick_the_loop): Minor clean up.
5269
5270 2018-03-12  NIIBE Yutaka  <gniibe@fsij.org>
5271
5272         scd: Fix typo in previous commit.
5273         + commit 655f0b9ad0138e6f960bf4befaf0eea569256614
5274
5275
5276 2018-03-09  NIIBE Yutaka  <gniibe@fsij.org>
5277
5278         scd: More fix with PC/SC for Windows.
5279         + commit 1e27c0e04cd3280d498dc8b72d2e410f6287f656
5280         * scd/apdu.c (pcsc_get_status): Return status based on CURRENT_STATUS.
5281         Add debug log.
5282
5283 2018-03-08  NIIBE Yutaka  <gniibe@fsij.org>
5284
5285         scd: Fix status check when using PC/SC.
5286         + commit f8b8b6aac2ca1cb34d7a346aee1d874e7650557b
5287         * scd/apdu.c (struct reader_table_s): Add field of current_state.
5288         (new_reader_slot): Initialize current_state.
5289         (pcsc_get_status): Keep the status in READER_TABLE array.
5290         Return SW_HOST_NO_READER when PCSC_STATE_CHANGED.
5291         * scd/scdaemon.c (handle_connections): Silence a warning.
5292
5293 2018-03-06  Werner Koch  <wk@gnupg.org>
5294
5295         agent: Also evict cached items via a timer.
5296         + commit f060cb5c63923d6caec784f65f3bb0aadf52f795
5297         * agent/cache.c (agent_cache_housekeeping): New func.
5298         * agent/gpg-agent.c (handle_tick): Call it.
5299
5300 2018-03-01  Werner Koch  <wk@gnupg.org>
5301
5302         gpg: Print the keygrip with --card-status.
5303         + commit fd595c9d3642dba437fbe0f6e25d7aaaae095f94
5304         * g10/call-agent.h (agent_card_info_s): Add fields grp1, grp2 and
5305         grp3.
5306         * g10/call-agent.c (unhexify_fpr): Allow for space as delimiter.
5307         (learn_status_cb): Parse KEYPARIINFO int the grpX fields.
5308         * g10/card-util.c (print_keygrip): New.
5309         (current_card_status): Print "grp:" records or with --with-keygrip a
5310         human readable keygrip.
5311
5312 2018-02-28  Andre Heinecke  <aheinecke@intevation.de>
5313
5314         gpgconf, w32: Allow UNC paths.
5315         + commit e43844c3b0b9ec93b7f2a88752bcd6b6244aacfb
5316         * tools/gpgconf-comp.c (get_config_filename): Allow UNC paths.
5317
5318 2018-02-22  Michał Górny  <mgorny@gentoo.org>
5319
5320         dirmngr: Handle failures related to missing IPv6 gracefully.
5321         + commit ecfc4db3a2f8bc2652ba4ac4de5ca1cd13bfcbec
5322         * dirmngr/ks-engine-hkp.c (handle_send_request_error): Handle two more
5323         error codes.
5324
5325 2018-02-22  Werner Koch  <wk@gnupg.org>
5326
5327         Release 2.2.5.
5328         + commit 9581a65ccc10daededc05c55391a04022f794a4a
5329
5330
5331         gpg: Don't let gpg return failure on an invalid packet in a keyblock.
5332         + commit b375d50ee4ce52c9b0f0855ec155be027642fb05
5333         * g10/keydb.c (parse_keyblock_image): Use log_info instead of
5334         log_error for skipped packets.
5335         * g10/keyring.c (keyring_get_keyblock): Ditto.
5336
5337 2018-02-22  NIIBE Yutaka  <gniibe@fsij.org>
5338
5339         g10: Select a secret key by checking availability under gpg-agent.
5340         + commit 88e766d3915c2919e9968148ebb30463d4a673e4
5341         * g10/getkey.c (finish_lookup): Add WANT_SECRET argument to confirm
5342         by agent_probe_secret_key.
5343         (get_pubkey_fromfile, lookup): Supply WANT_SECRET argument.
5344
5345 2018-02-20  Werner Koch  <wk@gnupg.org>
5346
5347         wks: Add special mode to --install-key.
5348         + commit 685a5e1558b2252ac895637fb857f6f7bb85ea7b
5349         * tools/gpg-wks-client.c (get_key_status_parm_s)
5350         (get_key_status_cb, get_key): Move to ...
5351         * tools/wks-util.c: ...here.
5352         (get_key): Rename to wks_get_key.
5353         * tools/gpg-wks-server.c: Include userids.h.
5354         (command_install_key): Allow use of a fingerprint.
5355
5356         wks: Implement server command --install-key.
5357         + commit ee474856ec16ff11d922d8503fb3ede77129c4aa
5358         * tools/wks-util.c (wks_filter_uid): Add arg 'binary'.
5359         * tools/gpg-wks-server.c (main): Expect 2 args for --install-key.
5360         (write_to_file): New.
5361         (check_and_publish): Factor some code out to ...
5362         (compute_hu_fname): ... new.
5363         (command_install_key): Implement.
5364
5365         wks: Support alternative submission address.
5366         + commit 1877603761911ea5b1c15f4aef11a2cf86a8682c
5367         * tools/gpg-wks.h (policy_flags_s): Add field 'submission_address'.
5368         * tools/wks-util.c (wks_parse_policy): Parse that field.
5369         (wks_free_policy): New.
5370         * tools/gpg-wks-client.c (command_send): Also try to take the
5371         submission-address from the policy file.  Free POLICY.
5372         * tools/gpg-wks-server.c (process_new_key): Free POLICYBUF.
5373         (command_list_domains): Free POLICY.
5374
5375 2018-02-15  Werner Koch  <wk@gnupg.org>
5376
5377         kbx: Fix detection of corrupted keyblocks on 32 bit systems.
5378         + commit 5e3679ae395e7a7e44f218f07bbe487429f1b279
5379         * kbx/keybox-search.c (blob_cmp_fpr): Avoid overflow in OFF+LEN
5380         checking.
5381         (blob_cmp_fpr_part): Ditto.
5382         (blob_cmp_name): Ditto.
5383         (blob_cmp_mail): Ditto.
5384         (blob_x509_has_grip): Ditto.
5385         (keybox_get_keyblock): Check OFF and LEN using a 64 bit var.
5386         (keybox_get_cert): Ditto.
5387
5388 2018-02-15  NIIBE Yutaka  <gniibe@fsij.org>
5389
5390         gpg: Fix reversed messages for --only-sign-text-ids.
5391         + commit ca138d5bf36accde2fd755249b470a8dc8743c95
5392         * g10/keyedit.c (keyedit_menu): Fix messages.
5393
5394 2018-02-14  Katsuhiro Ueno  <uenobk@gmail.com>
5395
5396         agent: Avoid appending a '\0' byte to the response of READKEY.
5397         + commit df97fe24807826ddc2af0e45e416fb81c5666f88
5398         * agent/command.c (cmd_readkey): Set pkbuflen to the length of the output
5399         without an extra '\0' byte.
5400
5401 2018-02-14  Werner Koch  <wk@gnupg.org>
5402
5403         sm: Fix minor memory leak in --export-p12.
5404         + commit 80719612b7e92aff5887f2a68d550a24f350722c
5405         * sm/export.c (gpgsm_p12_export): Free KEYGRIP.
5406
5407 2018-02-14  Katsuhiro Ueno  <uenobk@gmail.com>
5408
5409         sm: Fix a wrong key parameter in an exported private key file.
5410         + commit 29aac7798085ee38da5107698618890ae7593c96
5411         * sm/export.c (sexp_to_kparms): Fix the computation of array[6],
5412         which must be 'd mod (q-1)' but was 'p mod (q-1)'.
5413
5414 2018-02-14  Werner Koch  <wk@gnupg.org>
5415
5416         common: Use new function to print status strings.
5417         + commit f19ff78f0fbfc2793d8a9ab0173486bf712871ac
5418         * common/asshelp2.c (vprint_assuan_status_strings): New.
5419         (print_assuan_status_strings): New.
5420         * agent/command.c (agent_write_status): Replace by call to new
5421         function.
5422         * dirmngr/server.c (dirmngr_status): Ditto.
5423         * g13/server.c (g13_status): Ditto.
5424         * g13/sh-cmd.c (g13_status): Ditto.
5425         * sm/server.c (gpgsm_status2): Ditto.
5426         * scd/command.c (send_status_info): Bump up N.
5427
5428 2018-02-13  Arnaud Fontaine  <arnaud.fontaine@ssi.gouv.fr>
5429
5430         scd: Improve KDF-DO support.
5431         + commit 25f3b69129015c54392636818c8846e236f5cb2c
5432         * scd/app-openpgp.c (pin2hash_if_kdf): Check the content of KDF DO.
5433
5434 2018-02-12  NIIBE Yutaka  <gniibe@fsij.org>
5435
5436         scd: Fix handling for Data Object with no data.
5437         + commit 0a3bec2c2525935362f87dce93d7df2c8d498498
5438         * scd/app-openpgp.c (get_cached_data): Return NULL for Data Object
5439         with no data.
5440
5441 2018-02-09  Andre Heinecke  <aheinecke@intevation.de>
5442
5443         doc: Add compliance de-vs to gpgsm in vsnfd.prf.
5444         + commit e0658b19d93b38ed9ebd07734c4678acdde1607d
5445         * doc/examples/vsnfd.prf: Set complaince mode for gpgsm.
5446
5447 2018-02-07  NIIBE Yutaka  <gniibe@fsij.org>
5448
5449         scd: Use pipe to kick the loop on NetBSD.
5450         + commit 015fe1c47b91da340e9df6bed908e0747ae8c60b
5451         * configure.ac (HAVE_PSELECT_NO_EINTR): New.
5452         * scd/scdaemon.c (scd_kick_the_loop): Write to pipe.
5453         (handle_connections): Use pipe.
5454
5455 2018-01-29  NIIBE Yutaka  <gniibe@fsij.org>
5456
5457         tests: Fix for NetBSD with __func__.
5458         + commit 64aa98c8a05513d9c00f53a2b880d80f9035333e
5459         * tests/asschk.c: Don't define __func__ if available.
5460
5461 2018-01-27  Werner Koch  <wk@gnupg.org>
5462
5463         dirmngr: Improve assuan error comment for cmd keyserver.
5464         + commit f8e868d9dfb6fc1390e421e7993a1d076309ed83
5465         * dirmngr/server.c: Add error comment in case --resolve fails in
5466         ensure_keyserver.
5467
5468 2018-01-26  NIIBE Yutaka  <gniibe@fsij.org>
5469
5470         agent: Fix last commit.
5471         + commit d7207b39b71d1b07c4cddac602f29ec583f6d1ad
5472         * configure.ac: Check ucred.h as well as sys/ucred.h.
5473         * agent/command-ssh.c: Add inclusion of ucred.h.
5474
5475         agent: More fix for get_client_pid for portability.
5476         + commit 08e686a6a6d5bcb5410228b388745d09686b260c
5477             * configure.ac: Check sys/ucred.h instead of ucred.h.
5478             * agent/command-ssh.c: Include sys/ucred.h.
5479
5480 2018-01-22  NIIBE Yutaka  <gniibe@fsij.org>
5481
5482         scd: Support KDF Data Object of OpenPGPcard V3.3.
5483         + commit 91303b7df9c3e810cfcd4920f78bac6f8b7df2b2
5484         * scd/app-openpgp.c (do_getattr, do_setattr): Add KDF support.
5485         (pin2hash_if_kdf): New.
5486         (verify_a_chv): Add PINLEN arg.  Use pin2hash_if_kdf.
5487         (verify_chv2, do_sign): Follow the change of verify_a_chv.
5488         (verify_chv3, do_change_pin): Use pin2hash_if_kdf.
5489
5490 2018-01-18  Werner Koch  <wk@gnupg.org>
5491
5492         gpg: Fix the use of future-default with --quick-add-key.
5493         + commit e1e35db510c9222e7a7dc208c2e49df556954170
5494         * g10/keygen.c (parse_key_parameter_part): Add arg clear_cert.
5495         (parse_key_parameter_string): Add arg suggested_use and implement
5496         fallback.  Change callers to pass 0 for new arg.
5497         (parse_algo_usage_expire): Pass the parsed USAGESTR to
5498         parse_key_parameter_string so that it can use it in case a subkey is
5499         to be created.
5500
5501 2018-01-09  Andre Heinecke  <aheinecke@intevation.de>
5502
5503         doc: Note pinentry-mode for passphrase opts.
5504         + commit 6fb5713f4a6976900cc70c140e61043b6ef688d1
5505         * doc/gpg.texi (--passphrase, --passphrase-file, --passphrase-fd):
5506         Note that pinentry-mode needs to be loopback.
5507
5508 2018-01-08  Werner Koch  <wk@gnupg.org>
5509
5510         gpg: Print all keys with --decrypt --list-only.
5511         + commit 339b3301ee8410fe3bbdebb66a6e83801d79d40d
5512         * g10/mainproc.c (proc_pubkey_enc): Use dedicated error code for
5513         list-only and put the key into PKENC_LIST.
5514         (print_pkenc_list): Take care of the new error code.
5515
5516 2018-01-01  Werner Koch  <wk@gnupg.org>
5517
5518         gpg: Allow "futuredefault" as alias for "future-default".
5519         + commit 4d3c500f4793eb263940ff5ef87ec4ead63c9b4b
5520         * g10/keygen.c (parse_key_parameter_string): Allow "futuredefault" and
5521         use case-insensitive matching
5522         (quick_generate_keypair): Ditto.
5523         (parse_algo_usage_expire): Ditto.
5524
5525 2017-12-29  Werner Koch  <wk@gnupg.org>
5526
5527         gpg: Allow the use of "cv25519" and "ed25519" in the keygen parms.
5528         + commit 412bb7a801f242d47a82712080cce6ddbb843166
5529         * g10/keygen.c (gen_ecc): Map curve names.
5530
5531 2017-12-27  NIIBE Yutaka  <gniibe@fsij.org>
5532
5533         scd: Fix for inactive card at start by internal CCID driver.
5534         + commit 4f88b0f56134af2ce56d434b7acd47fcf9b6f7cf
5535         * scd/ccid-driver.c (do_close_reader): Set NULL on close.
5536         (bulk_in): Move DEBUGOUT and check by EP_INTR.
5537         (ccid_get_atr): Clear powered_off flag after initial status check.
5538
5539 2017-12-22  Werner Koch  <wk@gnupg.org>
5540
5541         kbx: Simplify by removing custom memory functions.
5542         + commit f3ba66781a07af2e32f5887e6e15acdd4822a431
5543         * kbx/keybox-util.c (keybox_set_malloc_hooks): Remove.
5544         (_keybox_malloc, _keybox_calloc, keybox_realloc)
5545         (_keybox_free): Remove.
5546         (keybox_file_rename): Remove.  Was not used.
5547         * sm/gpgsm.c (main): Remove call to keybox_set_malloc_hooks.
5548         * kbx/kbxutil.c (main): Ditto.
5549         * kbx/keybox-defs.h: Remove all separate includes.  Include util.h.
5550         remove convenience macros.
5551         * common/logging.h (return_if_fail): New.  Originally from
5552         keybox-defs.h but now using log_debug.
5553         (return_null_if_fail): Ditto.
5554         (return_val_if_fail): Ditto.
5555         (never_reached): Ditto.
5556
5557 2017-12-20  Werner Koch  <wk@gnupg.org>
5558
5559         common: Use larger buffer for homedir in case of 64 bit UIDs.
5560         + commit 290348e349e8d56a856f187a08e913f2ed525b3c
5561         * common/homedir.c (_gnupg_socketdir_internal): Enlarge PREFIX by 6
5562         bytes for "/gnupg".
5563
5564         Release 2.2.4.
5565         + commit 558b17593ae97b8a07d06bf0d6af1a626b304501
5566
5567
5568 2017-12-19  Petr Pisar  <petr.pisar@atlas.cz>
5569
5570         po: Update Czech translation.
5571         + commit 43aaf60449036e870cc25b77fbb7312cf3fb534c
5572
5573
5574 2017-12-19  Ineiev  <ineiev@gnu.org>
5575
5576         po: Update Russian translation.
5577         + commit c7b8ec6c8e57797f0b77dbf7fca85fb600323328
5578
5579
5580 2017-12-19  Werner Koch  <wk@gnupg.org>
5581
5582         wks: New server options --check, --with-dir, with-file.
5583         + commit 7449063b1af2eef73d621a69cdb2fb713ab1ae6c
5584         * tools/gpg-wks-server.c (aCheck, oWithDir, oWithFile): New const.
5585         (opts): New options --check, --with-dir, and --with-file.
5586         (main): Call command_check_key.
5587         (command_list_domains): Implement option --with-dir.
5588         (fname_from_userid): New.
5589         (command_check_key): New.
5590         (command_remove_key): Implement existsing command.
5591         (command_revoke_key): Call command_remove_key as a simple
5592         implementation.
5593
5594 2017-12-18  Werner Koch  <wk@gnupg.org>
5595
5596         conf: New option --status-fd.
5597         + commit 482e000b8a7e336f342a7fac3b7379257e944b6e
5598         * tools/gpgconf.c (oStatusFD): New const.
5599         (opts): New option --status-fd.
5600         (statusfp): New var.
5601         (set_status_fd): New.
5602         (gpgconf_write_status): New.
5603         (gpgconf_failure): New.
5604         (main): Set status fd and replace exit by gpgconf_failure.
5605         * tools/gpgconf-comp.c: Repalce exit by gpgconf_failure.
5606         (gc_process_gpgconf_conf): Print a few warning status messages.
5607
5608         gpgconf: Show --compliance in expert mode.
5609         + commit d74c40cef0a97cd98aa05f13b1541a94eda502a6
5610         * tools/gpgconf-comp.c (gc_options_gpg): Set compliance to expert.
5611         (gc_options_gpgsm): Ditto.
5612
5613         sm: Allow explicit setting of the default --compliance=gnupg.
5614         + commit 8c878ae4c9dfa9fe26aa15f4f9db3e86833575e9
5615         * sm/gpgsm.c (main): Allow setting of the default compliance.
5616         * tools/gpgconf-comp.c (gc_options_gpgsm): Add "compliance".
5617
5618 2017-12-18  NIIBE Yutaka  <gniibe@fsij.org>
5619
5620         po: Update Japanese translation.
5621         + commit e3ddeff66e8c08a37ddf8b6510d69579c245e192
5622         * po/ja.po: Fix message with no "%s".
5623
5624 2017-12-13  Werner Koch  <wk@gnupg.org>
5625
5626         gpg: Print a warning for too much data encrypted with 3DES et al.
5627         + commit 416cf9e9be5d2daf0ef629208031989699b3653f
5628         * g10/filter.h (cipher_filter_context_t): Remove unused filed
5629         'create_mdc'.  Turn field 'header' into a bit field.  Add new fields
5630         'short_blklen_warn' and 'short_blklen_count'.
5631         * g10/cipher.c (write_header): Print a warning if MDC is not used.
5632         (cipher_filter): Print a warning for long messages encrypted with a
5633         short block length algorithm.
5634
5635         gpg: Simplify cipher:write_header.
5636         + commit b5333e13cbc9db354ed90762190bf70605a02d1f
5637         * g10/cipher.c (write_header): Use write_status_printf.
5638
5639         gpg: Simplify default_recipient().
5640         + commit 9f641430dcdecbd7ee205d407cb19bb4262aa95d
5641         * g10/pkclist.c (default_recipient): Use hexfingerprint.
5642
5643         gpg: Return an error from hexfingerprint on malloc error.
5644         + commit cd26c5482b10bee7658959ae913f2ddb83190587
5645         * g10/keyid.c (hexfingerprint): Return NULL on malloc failure.  Chnage
5646         all callers.
5647
5648         gpg: Remove some xmallocs.
5649         + commit 29119a6492eda5dd7920e45e7f2faa043d436591
5650         * g10/getkey.c (get_pubkeys): Do not use xmalloc.
5651
5652 2017-12-12  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
5653
5654         gpg: default-preference-list: prefer SHA512.
5655         + commit 8ede3ae29a39641a2f98ad9a4cf61ea99085a892
5656         * g10/keygen.c (keygen_set_std_prefs): when producing default internal
5657         personal-digest-preferences, keep the same order.  When publishing
5658         external preferences, state preference for SHA512 first.
5659
5660 2017-12-12  Werner Koch  <wk@gnupg.org>
5661
5662         Change backlog from 5 to 64 and provide option --listen-backlog.
5663         + commit c81a447190d2763ac4c64b2e74e22e824da8aba3
5664         * agent/gpg-agent.c (oListenBacklog): New const.
5665         (opts): New option --listen-backlog.
5666         (listen_backlog): New var.
5667         (main): Parse new options.
5668         (create_server_socket): Use var instead of 5.
5669         * dirmngr/dirmngr.c: Likewise.
5670         * scd/scdaemon.c: Likewise.
5671
5672         build: New configure option --enable-run-gnupg-user-socket.
5673         + commit 17efcd2a2acdc3b7f00711272aa51e5be2476921
5674         * configure.ac: (USE_RUN_GNUPG_USER_SOCKET): New ac_define.
5675         * common/homedir.c (_gnupg_socketdir_internal): Add extra directories.
5676
5677 2017-12-11  Werner Koch  <wk@gnupg.org>
5678
5679         dirmngr: Check for WKD support at session end.
5680         + commit 20b52be9ca29b0bc843fc68a279cb72728ede72f
5681         * dirmngr/domaininfo.c (insert_or_update): Copy the name.
5682         * dirmngr/misc.c (copy_stream): Allow arg OUT to be NULL.
5683         * dirmngr/server.c (set_error): Protect CTX.
5684         (dirmngr_status): Protect against missing ASSUAN_CTX.
5685         (dirmngr_status_help): Ditto.
5686         (dirmngr_status_printf): Ditto.
5687         (cmd_wkd_get): Factor code out to ...
5688         (proc_wkd_get): new func.  Support silent operation with no CTX.
5689         (task_check_wkd_support): New.
5690
5691         dirmngr: Add a background task framework.
5692         + commit f2997adee0455c8c0fa391a853ec1b0c9fc43342
5693         * dirmngr/workqueue.c: New.
5694         * dirmngr/Makefile.am (dirmngr_SOURCES): Add new file.
5695         * dirmngr/server.c (server_local_s): New field session_id.
5696         (cmd_wkd_get): Add a task.
5697         (task_check_wkd_support): New stub function.
5698         (cmd_getinfo): New sub-commands "session_id" and "workqueue".
5699         (start_command_handler): Add arg session_id and store it in
5700         SERVER_LOCAL.
5701         (dirmngr_status_helpf): New.
5702         * dirmngr/dirmngr.h (wqtask_t): New type.
5703         * dirmngr/dirmngr.c (main): Pass 0 as session_id to
5704         start_command_handler.
5705         (start_connection_thread): Introduce a session_id and pass it to
5706         start_command_handler.  Run post session tasks.
5707         (housekeeping_thread): Run global workqueue tasks.
5708
5709         dirmngr: Limit the number of cached domains for WKD.
5710         + commit 7a663c296e687f12ccd9a21d414de780feb4dfcf
5711         * dirmngr/domaininfo.c (MAX_DOMAINBUCKET_LEN): New.
5712         (insert_or_update): Limit the length of a bucket chain.
5713         (domaininfo_print_stats): Print just one summary line.
5714
5715         (cherry picked from commit 26f08343fbccdbaa177c3507a3c5e24a5cf94a2d)
5716
5717         dirmngr: Keep track of domains used for WKD queries.
5718         + commit 6c1dcd79cf0977844179d9a7b189c10af5e42a7e
5719         * dirmngr/domaininfo.c: New file.
5720         * dirmngr/Makefile.am (dirmngr_SOURCES): Add file.
5721         * dirmngr/server.c (cmd_wkd_get): Check whether the domain is already
5722         known and tell domaininfo about the results.
5723
5724 2017-12-08  NIIBE Yutaka  <gniibe@fsij.org>
5725
5726         agent: Fix description of shadow format.
5727         + commit 5c121d44443b0a96ec6ea82b90717e3dbafd2cc5
5728         * agent/keyformat.txt, agent/protect.c, agent/t-protect.c: Fix.
5729
5730 2017-12-07  Werner Koch  <wk@gnupg.org>
5731
5732         build: Do not define logging.h constants for libgpg-error dev versions.
5733         + commit 2fedf8583bcc493f587c90bc9632d25dfd10bd10
5734         * common/logging.h [GPGRT_LOG_WITH_PREFIX]: Do not define the log
5735         constants.
5736
5737 2017-12-07  NIIBE Yutaka  <gniibe@fsij.org>
5738
5739         agent: Change intialization of assuan socket system hooks.
5740         + commit b9677ba16f6b386896781a751e4b2fc839e3ec81
5741         * agent/gpg-agent.c (initialize_modules): Add hook again.
5742         (main): Remove setting of the system houk but add scoket system hook
5743         setting after assuan initialization.
5744
5745 2017-12-06  NIIBE Yutaka  <gniibe@fsij.org>
5746
5747         agent: Set assuan system hooks before call of assuan_sock_init.
5748         + commit 1524ba9656f0205d8c6ef504f773b832a7a12ab9
5749         * agent/gpg-agent.c (initialize_modules): Move assuan_set_system_hooks.
5750         (main): ... here, just before assuan_sock_init.
5751
5752 2017-12-04  NIIBE Yutaka  <gniibe@fsij.org>
5753             Damien Goutte-Gattat  <dgouttegattat@incenp.org>
5754
5755         g10: Fix regexp sanitization.
5756         + commit 0d0b9eb0d4f99e8d293a4ce4b90921a879905115
5757         * g10/trustdb.c (sanitize_regexp): Only escape operators.
5758
5759 2017-11-26  Werner Koch  <wk@gnupg.org>
5760
5761         gpg: Do not read from uninitialized memory with --list-packets.
5762         + commit 4cf3cc6e3d48c8400466ca29c3f1c22ed2da6c2c
5763         * g10/parse-packet.c (parse_plaintext): Fill up the allocated NAME.
5764
5765 2017-11-24  Werner Koch  <wk@gnupg.org>
5766
5767         agent: New option --auto-expand-secmem.
5768         + commit 18af15249de5f826c3fa8d1d40e876734adcd0cf
5769         * agent/gpg-agent.c (oAutoExpandSecmem): New enum value.
5770         (opts): New option --auto-expand-secmem.
5771         (main): Implement that option.
5772
5773 2017-11-22  Werner Koch  <wk@gnupg.org>
5774
5775         gpg: Fix memory leaking for long inputs via --command-fd.
5776         + commit ea28ea18f3ee6c9f5e69986f39848398b58e242e
5777         * g10/cpr.c (do_get_from_fd): Free the old buffer.
5778
5779 2017-11-21  NIIBE Yutaka  <gniibe@fsij.org>
5780
5781         scd: Enable card removal check after select_application.
5782         + commit 0bb7fd0cab2d53cd0d44b21301b23edfe817e66b
5783         * scd/apdu.c (open_ccid_reader): Fix error handling of ccid_get_atr.
5784         * scd/app.c (select_application): Always kick the loop if new APP.
5785         * scd/ccid-driver.c (ccid_open_usb_reader): Don't setup at open.
5786         (ccid_slot_status): Setup interrupt transfer when !ON_WIRE.
5787
5788 2017-11-20  Werner Koch  <wk@gnupg.org>
5789
5790         Release 2.2.3.
5791         + commit 97f4feaaca8da4dcf1ca09a2016693155016f06b
5792
5793
5794         build: Use -Werror only for the check.
5795         + commit 04d9833e71cc9d0c087faec091c29b0b6cf69488
5796         * configure.ac: Do not add -Werror to mycflags.
5797
5798         gpg-agent: Avoid getting stuck in shutdown pending state.
5799         + commit 7ffedfab8909a45a4b0347a5f7b52222e8439f1d
5800         * agent/gpg-agent.c (handle_connections): Always check inotify fds.
5801
5802 2017-11-20  NIIBE Yutaka  <gniibe@fsij.org>
5803
5804         agent: Use clock or clock_gettime for calibration.
5805         + commit 760aa8aadafb747f33a1461ab0c2570b5ae43716
5806         * agent/protect.c (calibrate_get_time): Use clock or clock_gettime.
5807
5808         build: Check -Wlogical-op flag availability with -Werror.
5809         + commit 3ecd1a41be7c880976987d13e88342c98f37e064
5810         * configure.ac: Use -Werror.
5811
5812         build: BSD make support for yat2m.
5813         + commit e1984969cac06a88c7e6f5e49e5c3104d10a847d
5814         * configure.ac (YAT2M): Only define when found.
5815         * doc/Makefile.am: Portability fix.
5816
5817 2017-11-17  Werner Koch  <wk@gnupg.org>
5818
5819         dirmngr: Fix double free of a hash context in the error case.
5820         + commit 2aa106d6a4e2b09c257e8d769895d93ebb7f7edf
5821         * dirmngr/crlcache.c: Clearly document that this fucntions takes
5822         ownership of MD.
5823         (abort_sig_check): Allow NULL for MD.
5824         (crl_parse_insert): Immediately set MD to NULL.  Remove check for md
5825         before a calling abort_sig_check.
5826
5827 2017-11-15  Andre Heinecke  <aheinecke@intevation.de>
5828
5829         w32: Fix default registry path.
5830         + commit 4f5afaf1fdb5cb13859aca390ccb5a1ba1dba00c
5831         * configure.ac (GNUPG_REGISTRY_DIR): Remove leading backslash.
5832
5833         gpgtar: Prefer --set-filename over implicit name.
5834         + commit 878b8bfdcc3a8becfc46b9287a2d14cd3c875f28
5835         * tools/gpgtar-extract.c: Prefer opt.filename over filename
5836         for the directory prefix.
5837
5838 2017-11-15  Werner Koch  <wk@gnupg.org>
5839
5840         gpg: Print AKL info only in verbose mode.
5841         + commit b062ea5bc25157c942047b3fe7f5182a06106340
5842         * g10/getkey.c (get_pubkey_byname): Print info only in verbose mode.
5843
5844 2017-11-14  Andre Heinecke  <aheinecke@intevation.de>
5845
5846         sm, w32: Fix initial keybox creation.
5847         + commit 5ecef193bc2144e6d51a6bd5727bfd08a0d28b66
5848         * sm/keydb.c (maybe_create_keybox): Open new keybox in bin mode.
5849
5850 2017-11-07  Werner Koch  <wk@gnupg.org>
5851
5852         Release 2.2.2.
5853         + commit 5bd515005032f9340bd73e4346bbd0aef8518074
5854
5855
5856         dirmngr: Reduce default LDAP timeout to 15 seconds.
5857         + commit 30f21f8b0fa6844a9bba3f24dc41b3ac32170109
5858         * dirmngr/dirmngr.c (DEFAULT_LDAP_TIMEOUT): Change to 15.
5859         * dirmngr/dirmngr_ldap.c (DEFAULT_LDAP_TIMEOUT): Ditto.
5860
5861         (cherry picked from commit ab7ac827041b5cd97bbca7a75b0930072dd6611f)
5862
5863         speedo: Include software versions in the W32 README.
5864         + commit 23bfac6d1a8bd2d0af5a6fac3ba3a6e986d6c9e8
5865         (cherry picked from commit f9f72ffbfa9fd7d1a7a1823697d116d76155b407)
5866
5867 2017-11-07  Ineiev  <ineiev@gnu.org>
5868
5869         po: Update Russian translation.
5870         + commit 1941287c9d2c9e666bad1bd330db169f0e3d6b6c
5871
5872
5873 2017-11-07  NIIBE Yutaka  <gniibe@fsij.org>
5874
5875         po: Update Japanese translation.
5876         + commit 96d441b315ec5c9f329596cfda28ac13a8bfa21a
5877
5878
5879 2017-11-06  Werner Koch  <wk@gnupg.org>
5880
5881         agent: New GETINFO sub-commands "s2k_count_cal" and "s2k_time".
5882         + commit 3607ab2cf382296cb398a92d5ec792239960bf7b
5883         * agent/command.c (cmd_getinfo): New sub-commands.
5884         * agent/protect.c (get_standard_s2k_count): Factor some code out to ...
5885         (get_calibrated_s2k_count): new.
5886         (get_standard_s2k_time): New.
5887
5888         (cherry picked from commit 52d41c8b0f4af6278d18d8935399ddad16a26856)
5889
5890         agent: New option --s2k-count.
5891         + commit 78a6d0ce88ae14d8324fbab3aee3286b17e49259
5892         * agent/agent.h (opt): New field 's2k_count'.
5893         * agent/gpg-agent.c (oS2KCount): New enum value.
5894         (opts): New option --s2k-count.
5895         (parse_rereadable_options): Set opt.s2k_count.
5896
5897 2017-11-06  NIIBE Yutaka  <gniibe@fsij.org>
5898
5899         g10: Unattended key generation "Key-Grip" and "Subkey-Grip".
5900         + commit 680161647ad56d1ca92988f80bcc4d6fcb20b1eb
5901         * g10/keygen.c (pSUBKEYGRIP): New.
5902         (read_parameter_file): Add "Key-Grip" and "Subkey-Grip".
5903         (do_generate_keypair): Support pSUBKEYGRIP.
5904
5905         g10: Simplify "factory-reset" procedure.
5906         + commit f183b9768b42a6792c55a6129488bd8fbf5e8e6d
5907         * g10/card-util.c (factory_reset): Simplify.
5908
5909 2017-11-02  Ineiev  <ineiev@gnu.org>
5910
5911         po: Update Russian translation.
5912         + commit 6070f5a61d4d17ff437c69e1b708d49d107c22dc
5913
5914
5915 2017-11-02  Werner Koch  <wk@gnupg.org>
5916
5917         gpg: Introduce magic value 25519 to switch a card to ECC.
5918         + commit acb300543422c660c87ac2f0211a42f792a65cc4
5919         * g10/card-util.c (ask_card_keyattr): Handle special value 25519.
5920         (do_change_keyattr): Allow changing to cv25519/ed25519.
5921         (generate_card_keys): Ditto.
5922         (card_generate_subkey): Ditto.
5923
5924         gpg: Rename two card related functions in card-util.
5925         + commit de3a740c2e1156e58d2f94faa85c051740c8988e
5926         * g10/card-util.c (ask_card_rsa_keysize): Rename to ask_card_keyattr.
5927         (do_change_rsa_keysize): Rename to do_change_keyattr.
5928
5929 2017-11-02  NIIBE Yutaka  <gniibe@fsij.org>
5930
5931         agent: Fix returning GPG_ERR_NOT_FOUND wrongly.
5932         + commit 3da47d19df89d302c0ea25921f4bd8ce55705afe
5933         * agent/learncard.c (agent_handle_learn): Find SERIALNO.
5934
5935 2017-11-01  NIIBE Yutaka  <gniibe@fsij.org>
5936
5937         common: Accept the Z-suffix for yymmddThhmmssZ format.
5938         + commit 0e5bd473a07f188615c4fce26b73bb452d689d68
5939         * common/gettime.c (isotime_p): Accept the Z suffix.
5940
5941 2017-10-27  NIIBE Yutaka  <gniibe@fsij.org>
5942
5943         agent: Clean up pinentry access locking.
5944         + commit 3924e1442c6625a2b57573a1a634a5ec56b09a29
5945         * agent/agent.h (struct server_control_s): Rename PINENTRY_ACTIVE.
5946         * agent/call-pinentry.c (entry_owner): Remove.
5947         (agent_reset_query): Use thread private object of PINENTRY_ACTIVE.
5948         (unlock_pinentry): Add CTRL to arguments to access thread private.
5949         Check and decrement PINENTRY_ACTIVE for recursive use.
5950         (start_pinentry): Check and increment PINENTRY_ACTIVE for recursion.
5951         (agent_askpin): Follow the change of unlock_pinentry API.
5952         (agent_get_passphrase, agent_get_confirmation): Likewise.
5953         (agent_show_message, agent_popup_message_start): Likewise.
5954         (agent_popup_message_stop, agent_clear_passphrase): Likewise.
5955
5956         agent: Allow recursive use of pinentry.
5957         + commit 4738256f2e0d22302377c9ec7b2ae3999338e6c6
5958         * agent/agent.h (struct server_control_s): Add pinentry_level.
5959         * agent/call-pinentry.c (agent_popup_message_stop): Not clear
5960         ENTRY_CTX here.
5961         (unlock_pinentry): Handle recursion.  Clear ENTRY_CTX here.
5962         (start_pinentry): Allow recursive use.
5963
5964 2017-10-26  NIIBE Yutaka  <gniibe@fsij.org>
5965
5966         agent, tests: Support --disable-scdaemon build case.
5967         + commit 05cb87276c21c3a47226c75026fa46a955553dd9
5968         * agent/command.c (cmd_scd): Support !BUILD_WITH_SCDAEMON.
5969         * tests/openpgp/defs.scm (create-gpghome): Likewise.
5970         * tests/gpgsm/gpgsm-defs.scm (create-gpgsmhome): Likewise.
5971
5972         Fix comment of configure.
5973         + commit b13972dfbf7224478652038725ab0d2cb41b7303
5974         * configure.ac (BUILD_WITH_DIRMNGR): Comment fix.
5975
5976 2017-10-24  Werner Koch  <wk@gnupg.org>
5977
5978         gpg: Avoid superfluous sig check info during import.
5979         + commit 84af859e391a757877c9a1d78e35face983e6d23
5980         * g10/key-check.c (print_info): New.
5981         (key_check_all_keysigs): Print sig checking results only in debug
5982         mode.  Prettify the stats info and suppress them in quiet mode.
5983
5984         build: New configure option --enable-werror.
5985         + commit 812fe29bff42cf7dbd07e0becc55b2ada340dd97
5986         * configure.ac: Implement that option.
5987
5988         build: Do not mess with CFLAGS in configure.
5989         + commit e417aaf69817fcb4a73c38077853dc940a2deabc
5990         * configure.ac: Do not mess with the user provided CFLAGS.
5991
5992 2017-10-24  Rainer Perske  <rainer.perske@uni-muenster.de>
5993
5994         sm: Do not expect X.509 keyids to be unique.
5995         + commit 1067403c8a7fb51decf30059e46901b5ee9f5b37
5996         * sm/certlist.c (gpgsm_find_cert): Add arg allow_ambiguous and use it.
5997         * sm/call-dirmngr.c (inq_certificate): Pass true to ALLOW_AMBIGUOUS
5998         (run_command_inq_cb): Ditto.
5999         * sm/gpgsm.c (main): Pass false.
6000         * sm/server.c (cmd_passwd): Pass false.
6001
6002 2017-10-24  Werner Koch  <wk@gnupg.org>
6003
6004         gpgconf: Ignore non-installed components with --apply-profile.
6005         + commit 6e808ae4700dc5e95bf4cc2d5c063df582c234d0
6006         * tools/gpgconf-comp.c (retrieve_options_from_program): Add arg
6007         only_installed.
6008         (gc_component_retrieve_options): Use this if we want to process all
6009         components.
6010
6011         gpg: Improve the "secret key available" notice in keyedit.c.
6012         + commit 560d85ecff4246133d185dc29395f07c918b5556
6013         * g10/keyedit.c (KEYEDIT_NEED_SUBSK): New.
6014         (cmds): Add this flag to keytocard, bkuptocard, expire, and passwd.
6015         (keyedit_menu): Check whether only subkeys are available and take care
6016         of that in the command check and in the HELP listing.  Also print a
6017         different notice if only subkeys are available.
6018
6019         gpg: Remove unused flags from keyedit.c.
6020         + commit 016538d82867c40a21bc7cbf44ec386f4699077f
6021         * g10/keyedit.c (KEYEDIT_NOT_SK, KEYEDIT_ONLY_SK): Remove.
6022         (cmds): Remove them.
6023
6024 2017-10-19  Werner Koch  <wk@gnupg.org>
6025
6026         gpg: Fix creating on-disk subkey with on-card primary key.
6027         + commit 44fb3fbc85b32552c91f32f099b6b246c12ce0cc
6028         * g10/keygen.c (generate_subkeypair): Ignore error code issued for
6029         trying to verify a card based key.
6030
6031         gpg: Print sec/sbb with --import-option import-show or show-only.
6032         + commit 2c7dccca9b617780a3ea760adf460bb3b77f90f3
6033         * g10/import.c (import_one): Pass FROM_SK to list_keyblock_direct.
6034
6035         gpg: Make --dry-run and show-only work for secret keys.
6036         + commit 68c8619114fd5f24cb6bfb9e0f25c428a8805323
6037         * g10/import.c (import_secret_one): Check for dry-run before
6038         transferring keys.
6039
6040 2017-10-19  Damien Goutte-Gattat  <dgouttegattat@incenp.org>
6041
6042         dirmngr: Do not follow https-to-http redirects.
6043         + commit 1ba308aa0356a57c21c4c8c2dac75b4d62b8aac3
6044         * dirmngr/ks-engine-http.c (ks_http_fetch): Forbid redirects from
6045         a https URI to a http URI.
6046
6047 2017-10-19  NIIBE Yutaka  <gniibe@fsij.org>
6048
6049         g10: Fix find_and_check_key for multiple keyrings.
6050         + commit d07de3862710d88bc80d6f6c5ca8da5cf38ff0eb
6051         * g10/pkclist.c (find_and_check_key): Call get_validity on a specific
6052         keyblock.
6053
6054 2017-10-19  Werner Koch  <wk@gnupg.org>
6055
6056         gpg: Keep a lock during the read-update/insert cycle in import.
6057         + commit 7c73db3d31c6457dfbdc82a8dc89951c023f0603
6058         * g10/keydb.c (keydb_handle): New field 'keep_lock'.
6059         (keydb_release): Clear that flag.
6060         (keydb_lock): New function.
6061         (unlock_all): Skip if KEEP_LOCK is set.
6062         * g10/getkey.c (get_keyblock_byfprint_fast): Call keep_lock if
6063         requested.
6064
6065         gpg: Improve keydb handling in the main import function.
6066         + commit 8448347b5bdee56e6f9938a93ea92fe4d3c8800c
6067         * g10/getkey.c (get_pubkey_byfprint_fast): Factor most code out to ...
6068         (get_keyblock_byfprint_fast): .. new function.
6069         * g10/import.c (revocation_present): s/int rc/gpg_error_t err/.
6070         (import_one): Use get_keyblock_byfprint_fast to get the keyblock and a
6071         handle.  Remove the now surplus keyblock fetch in the merge branch.
6072
6073         gpg: Simplify keydb handling of the main import function.
6074         + commit 752cae6dd2ee8982a34c796a3f168ae538f7938c
6075         * g10/import.c (import_keys_internal): Return gpg_error_t instead of
6076         int.  Change var names.
6077         (import_keys_es_stream): Ditto.
6078         (import_one): Ditto.  Use a single keydb_new and simplify the use of
6079         of keydb_release.
6080
6081         sm: Fix colon listing of fields > 12 in crt records.
6082         + commit 1bf5cbd3ef01b7f5fdcfa30c882047b924dcf3f0
6083         * sm/keylist.c (print_capabilities): Move colon printing ...
6084         (list_cert_colon): to here.
6085
6086 2017-09-28  Werner Koch  <wk@gnupg.org>
6087
6088         gpg: Workaround for junk after --trusted-key.
6089         + commit b509d81cab030cca6abf0d878e1fc884eda344e6
6090         * g10/trust.c (register_trusted_key): Cut off everthing starting as a
6091         hash sign.
6092
6093 2017-09-19  Werner Koch  <wk@gnupg.org>
6094
6095         Release 2.2.1.
6096         + commit 355ca9e9498740fb6294eec451507b4891ae01ec
6097
6098
6099 2017-09-18  Werner Koch  <wk@gnupg.org>
6100
6101         dirmngr: Use system certs if --hkp-cacert is not used.
6102         + commit df692a6167be5486f9a29da003a00292fd895176
6103         * dirmngr/certcache.c (any_cert_of_class): New var.
6104         (put_cert): Set it.
6105         (cert_cache_deinit): Clear it.
6106         (cert_cache_any_in_class): New func.
6107         * dirmngr/http-ntbtls.c (gnupg_http_tls_verify_cb): Add hack to
6108         override empty list of HKP certs.
6109
6110         wks: Create a new user id if provider wants mailbox-only.
6111         + commit 50c8b6c88f5d9f4b6c4e9c03aee31fe29afa94b8
6112         * tools/gpg-wks-client.c (get_key): Add arg 'exact'.
6113         (add_user_id): New.
6114         (command_send): Create new user id.
6115
6116         wks: Send only the newest UID to the server.
6117         + commit 7f7f5d06fa5aa3a3c5ab8d2e59ee76207bfdeaa0
6118         * tools/wks-util.c (list_key_status_cb): Rename to key_status_cb.
6119         (wks_filter_uid): New.
6120         (wks_list_key): Allow FPR to be NULL.  Return an error if no
6121         fingerprint was found.
6122         * tools/gpg-wks-server.c (process_new_key)
6123         (check_and_publish): Remove now useless extra check for FPR.
6124         * tools/gpg-wks-client.c (command_check): Ditto.
6125         (command_send): Filter out the newest uid.
6126
6127         wks: Print the UID creation time with gpg-wks-client --check.
6128         + commit a0035986a8615df056182bb9af775b8b7b22003d
6129         * tools/gpg-wks.h (uidinfo_list_s): Add field 'created'.
6130         * tools/wks-util.c (append_to_uidinfo_list): Add arf 'created'.
6131         (wks_list_key): Pass timestamp to append_to_uidinfo_list.
6132         * tools/gpg-wks-client.c (command_check): Print UID creation time.
6133
6134         wks: Use dedicated type to convey user ids.
6135         + commit 4e0696de897cac6a34d55a69d8889faf26f1a923
6136         * tools/gpg-wks.h (uidinfo_list_s, uidinfo_list_t): New.
6137         * tools/wks-util.c (append_to_uidinfo_list): New.
6138         (free_uidinfo_list): New.
6139         (wks_list_key): Change arg r_mboxes to uidinfo_list_t.  Use
6140         append_to_uidinfo_list.
6141         * tools/gpg-wks-server.c (sserver_ctx_s): Replace strlist_t by
6142         uidinfo_list_t.
6143         (process_new_key): Ditto.
6144         (check_and_publish): Ditto.
6145         (command_receive_cb): Replace free_strlist by free_uidinfo_list.
6146         * tools/gpg-wks-client.c (command_check): Replace strlist_t by
6147         uidinfo_list_t.  Also print user id in verbose mode.
6148
6149 2017-09-13  Werner Koch  <wk@gnupg.org>
6150
6151         gpgv: Initialize compliance checker.
6152         + commit 006ca124ed95845d43af8c14d7ab2bc085b47b4c
6153         * g10/gpgv.c (main): Call gnupg_initialize_compliance.
6154
6155 2017-09-12  Werner Koch  <wk@gnupg.org>
6156
6157         wks: Add hack for the broken posteo system.
6158         + commit a821b4f5567d02c3329c2b94a73dcbe12e6699a2
6159         * tools/gpg-wks-client.c (command_send): Additional hack for posteo.
6160         Check the protocol-version flag.
6161
6162         wks: Add new policy flag protocol-version.
6163         + commit 332c9eaa2a3c7cae90b389cdaa2c149c5595fb4d
6164         * tools/gpg-wks.h (policy_flags_s): Add field protocol_version.
6165         * tools/wks-util.c (wks_parse_policy): Add new policy flag.
6166
6167         gpg: Fix "Fix key generation with only an email part".
6168         + commit 8b5a2474f21dd4f1aa2a283e2f57d75e42742af5
6169         * g10/keygen.c (proc_parameter_file): Don't check the result of
6170         stpcpy.
6171
6172         wks: Use unencrypted draft-1 mode for posteo.de.
6173         + commit c65a7bba7331975d20910f90cf648b6ecc5410f0
6174         * tools/gpg-wks-client.c (command_send): Allow sending in draft-1
6175         mode.
6176
6177         tools: New function mime_maker_add_body_data.
6178         + commit 7d15ee88980f88ca62fc7de9492dd08e54d0f0f1
6179         * tools/mime-maker.c (mime_maker_add_body_data): New.
6180
6181 2017-09-11  NIIBE Yutaka  <gniibe@fsij.org>
6182
6183         tests: Fix a test which specifies expiration date.
6184         + commit a172759b5088ae086c0caa2e7d4d0ea346b28a90
6185         * tests/openpgp/quick-key-manipulation.scm: Fix expiration time
6186         comparison.
6187
6188         scd: Fix for large ECC keys.
6189         + commit 827abe01a72a50eab1cdcde78985b42a4a8480fb
6190         * scd/app-openpgp.c (do_decipher): Support larger length.
6191
6192 2017-09-11  Werner Koch  <wk@gnupg.org>
6193
6194         gpg: Fix key generation with only an email part.
6195         + commit 7089dcc54099a4909ce7d386c07ab87e1398e2eb
6196         * g10/keygen.c (proc_parameter_file): Special case the email only
6197         case.
6198
6199 2017-08-28  Werner Koch  <wk@gnupg.org>
6200
6201         Release 2.2.0.
6202         + commit 9d80fb8e000189e61c173c39f1e1ca417566a7fc
6203
6204
6205 2017-08-27  Werner Koch  <wk@gnupg.org>
6206             Arnaud Fontaine  <arnaud.fontaine@ssi.gouv.fr>
6207
6208         scd: Convey the correct length for Le.
6209         + commit 45d5f5800afe6613f338a26f361cb5e03e861129
6210         * scd/app-openpgp.c (determine_rsa_response): Round bits up.
6211
6212 2017-08-24  Werner Koch  <wk@gnupg.org>
6213
6214         gpg: Fix memory leak while running --check-trustdb.
6215         + commit 13821e15fb9bdddfce79d88731c0f151724b2371
6216         * g10/trustdb.c (update_min_ownertrust): Free PK.
6217
6218         gpg: Fix memory leak in sig-check.
6219         + commit b065a696344eac3007dbd5642143ecaaeebab43a
6220         * g10/sig-check.c (check_signature_over_key_or_uid): Remove useless
6221         condition.  Actually free when SIGNER was allocated by us.
6222
6223         build: Remove obsolete option from autogen.rc.
6224         + commit 02a5df614a369519ad7781f95dc977e24a0d4277
6225         * autogen.rc: Remove --enable-gpg2-is-gpg.
6226
6227 2017-08-23  Werner Koch  <wk@gnupg.org>
6228
6229         gpgconf: Swap "auto-key-retrieve" and "no-auto-key-retrieve".
6230         + commit 565e486b8028f9e3cc51ebc5202666b598042175
6231         * g10/gpg.c (gpgconf_list): Announce "auto-key-retrieve".
6232         (main): Simplify setting of KEYSERVER_AUTO_KEY_RETRIEVE.
6233         * tools/gpgconf-comp.c: Make "no-auto-key-retrieve" invisible.  Make
6234         "auto-key-retrieve" an expert option.
6235
6236         tests: Do not run trust-pgp-4.scm.
6237         + commit b917cb66b79597520788cd9264889942247a3377
6238         * tests/openpgp/Makefile.am (XTESTS): Remove test.
6239         (EXTRA_DIST): Add test file.
6240
6241         build: Change SWDB tag "gnupg21" to "gnupg22".
6242         + commit 008ae0bd868cb49ad4d67fc8c71707cd2a162137
6243         * configure.ac (GNUPG_SWDB_TAG): New ac_define.  Set it to "gnupg22".
6244         * tools/gpgconf.c (query_swdb): Use it.
6245         * build-aux/speedo.mk: Change tag "gnupg21" to "gnupg22".
6246         * Makefile.am (distcheck-hook): Ditto.
6247
6248 2017-08-23  Åka Sikrom  <a4@hush.com>
6249
6250         po: Update Norwegian translation.
6251         + commit fd0e5b60bed1cfc2aed7b2e13cc449f355eac051
6252
6253
6254 2017-08-23  Andre Heinecke  <aheinecke@intevation.de>
6255
6256         agent: Fix string translation for Windows.
6257         + commit 6158811304937b592601ef30c29c5a5cdbaa88ea
6258         * agent/agent.h (L_): Define agent_Lunderscore when simple
6259         gettext is used.
6260
6261 2017-08-22  NIIBE Yutaka  <gniibe@fsij.org>
6262
6263         po: Update Japanese translation.
6264         + commit e6fa6b0ce823effd721c807b2b292287af91c642
6265
6266
6267 2017-08-21  Damien Goutte-Gattat  <dgouttegattat@incenp.org>
6268
6269         tests: Add tests for the PGP trust model.
6270         + commit c23a69970ba38edae9d3b2603825d18fbb732423
6271         * tests/openpgp/trust-pgp-1.scm: New file.
6272         * tests/openpgp/trust-pgp-2.scm: New file.
6273         * tests/openpgp/trust-pgp-3.scm: New file.
6274         * tests/openpgp/trust-pgp-4.scm: New file.
6275         * tests/openpgp/trust-pgp/common.scm: New file.
6276         * tests/openpgp/trust-pgp/scenario1.asc: New file.
6277         * tests/openpgp/trust-pgp/scenario2.asc: New file.
6278         * tests/openpgp/trust-pgp/scenario3.asc: New file.
6279         * tests/openpgp/trust-pgp/scenario4.asc: New file.
6280         * tests/openpgp/trust-pgp/alice.sec.asc: New file.
6281         * tests/openpgp/trust-pgp/bobby.sec.asc: New file.
6282         * tests/openpgp/trust-pgp/carol.sec.asc: New file.
6283         * tests/openpgp/trust-pgp/david.sec.asc: New file.
6284         * tests/openpgp/trust-pgp/frank.sec.asc: New file.
6285         * tests/openpgp/trust-pgp/grace.sec.asc: New file.
6286         * tests/openpgp/trust-pgp/heidi.sec.asc: New file.
6287         * tests/openpgp/Makefile.am (XTESTS): Add new tests.
6288         (TEST_FILES): Add new files.
6289         (EXTRA_DIST): Add new common file.
6290
6291         tests: Move some functions into a common module.
6292         + commit cbe54b28bf3610204e12c50c0606df37337a1156
6293         * tests/openpgp/tofu.scm (gettrust): Moved to the common defs.scm
6294         module.
6295         (checktrust): Likewise.
6296         * tests/openpgp/defs.scm (gettrust): New function.
6297         (checktrust): Likewise.
6298
6299         gpgconf: Make WoT settings configurable by gpgconf.
6300         + commit 0161225457e0609509d0d5f4b80a60a1071b4b48
6301         * tools/gpgconf-comp.c (gc_options_gpg): Add max-cert-depth,
6302         completes-needed, and marginals-needed options.
6303         * g10/gpg.c (gpgconf_list): Likewise.
6304
6305 2017-08-21  Justus Winter  <justus@g10code.com>
6306
6307         gpgscm: Fix -Wimplicit-fallthrough warnings.
6308         + commit 6e596b2a745ae7a75a69038cf00ab4bbae1cebaa
6309         * tests/gpgscm/scheme.c (CASE): Rearrange so that the case statement
6310         is at the front.
6311         (Eval_Cycle): Improve fallthrough annotations.
6312
6313 2017-08-11  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
6314
6315         gpg: default to --no-auto-key-retrieve.
6316         + commit e6f84116abca2ed49bf14b2e28c3c811a3717227
6317         * g10/gpg.c (main): remove KEYSERVER_AUTO_KEY_RETRIEVE from the
6318         default keyserver options.
6319         * doc/gpg.texi: document this change.
6320
6321 2017-08-10  Justus Winter  <justus@g10code.com>
6322
6323         tests: Improve documentation.
6324         + commit 23107ba20f8b4eb5482b480ad6a8af6b39d2bfeb
6325         * tests/openpgp/README: Add quickstart instructions, how to use
6326         shell.scm, remove no longer used MKDATA.
6327
6328 2017-08-09  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6329
6330         g10: Write status error on error of --quick-revoke-uid.
6331         + commit 977fc5f0eb9fdee19e66bea8cd2eb5414789b485
6332         * g10/keyedit.c (keyedit_quick_revuid): Write status error on error.
6333
6334 2017-08-09  Werner Koch  <wk@gnupg.org>
6335
6336         Release 2.1.23.
6337         + commit e8ffa9a6ca5d76660b67207cd1157068e48483de
6338
6339
6340         po: Update German translation.
6341         + commit 2059dbf201963c6f229698ae80c6c774b1f686c8
6342
6343
6344 2017-08-08  Werner Koch  <wk@gnupg.org>
6345
6346         build: New configure option --enable-all-tests.
6347         + commit fb21aa8b50367e2afa13bad73fc21d6f01a97e18
6348         * configure.ac: New option --enable-all-tests.
6349         * tests/gpgscm/ffi.c (ffi_init): New gloabl var *run-all-tests*.
6350         * tests/openpgp/all-tests.scm (all-tests): Use that var instead
6351         of *maintainer-mode*.
6352         * Makefile.am (AM_DISTCHECK_CONFIGURE_FLAGS): Add --enable-all-tests.
6353
6354         gpgscm: Make the test summary stand out.
6355         + commit 0bd19dae1161a71053d794e4f75e66f70445f9f0
6356         * tests/gpgscm/tests.scm (test-pool): Add delimiter lines.
6357
6358         sm: Always print the keygrip in colon mode.
6359         + commit 0a8e20c4c639f0c491e2af5ac5fb97005196422b
6360         * sm/keylist.c (list_cert_colon): Always print the keygrip as
6361         described in the manual.
6362
6363 2017-08-08  Justus Winter  <justus@g10code.com>
6364
6365         gpg: Add option '--disable-dirmngr'.
6366         + commit c4506f624ed6854aa0ba1629aa2d1d43eb26900d
6367         * doc/gpg.texi: Document new option.
6368         * g10/call-dirmngr.c (create_context): Fail if option is given.
6369         * g10/gpg.c (cmd_and_opt_values): New value.
6370         (opts): New option.
6371         (gpgconf_list): Add new option.
6372         (main): Handle new option.
6373         * g10/options.h (struct opt): New field 'disable_dirmngr'.
6374         * tools/gpgconf-comp.c (gc_options_gpg): New option.
6375
6376 2017-08-07  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
6377
6378         systemd-user: Drop redundant After=*.socket.
6379         + commit 81074c3b0211854a2dc94600dc892224201536f5
6380         * doc/examples/systemd-user/*.service: Drop redundant After=*.socket
6381         directive.
6382
6383         systemd-user: Drop RefuseManualStart=true.
6384         + commit 407da18254dfebcacfaee16952ef0b617b1626ea
6385         * doc/examples/systemd-user/*.service: drop RefuseManualStart=true
6386
6387 2017-08-07  Justus Winter  <justus@g10code.com>
6388
6389         tests: Do not run all tests unless in maintainer mode.
6390         + commit b0112dbca91e720a4ff622ad0e88d99eba56203a
6391         * configure.ac: Leak the maintainer mode flag into 'config.h'.
6392         * tests/gpgscm/ffi.c: Pass it into the scheme environment.
6393         * tests/openpgp/all-tests.scm: Only run tests against non-default
6394         configurations (keyring, extended-key-format) in maintainer mode.
6395
6396 2017-08-07  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
6397
6398         Fix spelling.
6399         + commit a611cba142470c52f3303c512f77ae7d195cc41f
6400         * doc/gpg.texi: s/occured/occurred/
6401
6402         Simple typo fix.
6403         + commit f011d8763a009612c858a287cf7cc6a1f1a6d32a
6404         * agent/gpg-agent.c: Correct spelling in comment.
6405
6406 2017-08-05  Werner Koch  <wk@gnupg.org>
6407
6408         gpg: Install gpg by default under the name gpg.
6409         + commit a69464b0b6dac88b360a13d3faf19dd7f2a0e02b
6410         * configure.ac: Remove option --enable-gpg2-is-gpg.  Add option
6411         --enable-gpg-is-gpg2.
6412         * build-aux/speedo.mk (speedo_pkg_gnupg_configure): Remove
6413         --enable-gpg2-is-gpg.
6414
6415         gpg: gpgconf needs to support the now default --auto-key-retrieve.
6416         + commit 69e97d909d586160cc0631c9a6f4d3f24bb0c682
6417         * tools/gpgconf-comp.c (gc_options_gpg): Re-add "auto-key_retrieve".
6418
6419 2017-08-04  Werner Koch  <wk@gnupg.org>
6420
6421         gpg: Fix memory leak in parse_auto_key_locate.
6422         + commit b70e86fd1050fc6da07a177ed142ae9882b4dd0d
6423         * g10/getkey.c (parse_auto_key_locate): Fix freeing of OPTIONS.
6424
6425         tests: Adjust tests for changed --auto-key-locate default.
6426         + commit 0767eada1479c0fa9d4b75781a8c2afb67bdbf90
6427         * tests/openpgp/defs.scm (create-gpghome): Disable new defaults.
6428
6429         gpg: Make --no-auto-key-retrieve gpgconf-igurable.
6430         + commit 9bb13a0e819334681caca38c9074bd7bfc04e45e
6431         * g10/gpg.c (gpgconf_list): Print no-auto-key-retrieve instead of
6432         auto-key-retrieve.
6433         * tools/gpgconf-comp.c (gc_options_gpg): Replace auto-key-retrieve by
6434         no-auto-key-retrieve and chnage level from invisible to advanced.
6435
6436         gpg: Default to --auto-key-locate "local,wkd" and --auto-key-retrieve.
6437         + commit 7e1fe791d188b078398bf83c9af992cb1bd2a4b3
6438         * g10/gpg.c (main): Add KEYSERVER_AUTO_KEY_RETRIEVE to the default
6439         keyserver options.  Set the default for --auto-key-locate to
6440         "local,wkd".  Reset that default iff --auto-key-locate has been given
6441         in the option file or in the commandline.
6442         * g10/getkey.c (parse_auto_key_locate): Work on a copy of the arg.
6443
6444         agent: Make --no-grab the default.
6445         + commit 3d78ae4d3de08398fabae5821045a3a1da6dadbe
6446         * agent/gpg-agent.c (oGrab): New const.
6447         (opts): New option --grab.  Remove description for --no-grab.
6448         (parse_rereadable_options): Make --no-grab the default.
6449         (finalize_rereadable_options): Allow --grab to override --no-grab.
6450         (main) <gpgconflist>: Add "grab".
6451         * tools/gpgconf-comp.c (gc_options_gpg_agent): Add "grab".
6452
6453         gpg: Avoid double fingerprint printing with import-show.
6454         + commit b54d75fb1dcfa2cebb3a2497b81ffb49acac2056
6455         * g10/import.c (import_one) <IMPORT_SHOW>: Take care of fingerprint
6456         options.
6457
6458         gpg: New import option show-only.
6459         + commit d9fabcc1989d7235ea0294874803295a30f8711b
6460         * g10/options.h (IMPORT_DRY_RUN): New.
6461         * g10/import.c (parse_import_options): Add "show-only".
6462         (import_one): use that as alternative to opt.dry_run.
6463
6464 2017-08-03  Werner Koch  <wk@gnupg.org>
6465
6466         wks: Allow gpg-wks-client --supported with just the domain name.
6467         + commit 6cba56d436b56ea5e60042144a8a75a2e80007c8
6468         * tools/gpg-wks-client.c (command_supported): Hack for missing local
6469         part.
6470
6471 2017-08-02  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6472
6473         g10: Always save standard revocation certificate in file.
6474         + commit dcfb01959802b27869528dda1d9a4f5e79574bb5
6475         * g10/revoke.c (gen_standard_revocation): Set opt.outfile to NULL
6476         temporarily to create certificate in right place.
6477
6478 2017-08-01  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6479
6480         Revert "g10: Always save standard revocation certificate in file."
6481         + commit 624cd2d0bf6cc6dd1b79654295dc76f5b2d6d70b
6482         This reverts commit ebc65ff459e6c228fb7406e375819a9fe5637abe.
6483
6484         g10: Always save standard revocation certificate in file.
6485         + commit ebc65ff459e6c228fb7406e375819a9fe5637abe
6486         * g10/main.h (open_outfile): New parameter NO_OUTFILE.
6487         * g10/openfile.c (open_outfile): New parameter NO_OUTFILE.  If given,
6488         never use opt.outfile.
6489         * g10/revoke.c (create_revocation): If FILENAME is true, also set
6490         NO_OUTFILE to true (for standard revocation certificates).
6491         * g10/dearmor.c, g10/encrypt.c, g10/export.c, g10/revoke.c,
6492         g10/sign.c: Adjust all other callers.
6493
6494         artwork: Add icons.
6495         + commit a8d0b8d2333ddab703d1e346e06c106eeeedfd53
6496         * artwork/icons/index.css: New file.
6497         * artwork/icons/index.html: New file.
6498         * artwork/icons/lock-12.png: New file.
6499         * artwork/icons/lock-128.png: New file.
6500         * artwork/icons/lock-16.png: New file.
6501         * artwork/icons/lock-24.png: New file.
6502         * artwork/icons/lock-256.png: New file.
6503         * artwork/icons/lock-32.png: New file.
6504         * artwork/icons/lock-48.png: New file.
6505         * artwork/icons/lock-64.png: New file.
6506         * artwork/icons/lock-wing-12.png: New file.
6507         * artwork/icons/lock-wing-128.png: New file.
6508         * artwork/icons/lock-wing-16.png: New file.
6509         * artwork/icons/lock-wing-24.png: New file.
6510         * artwork/icons/lock-wing-256.png: New file.
6511         * artwork/icons/lock-wing-32.png: New file.
6512         * artwork/icons/lock-wing-48.png: New file.
6513         * artwork/icons/lock-wing-64.png: New file.
6514         * artwork/icons/lock-wing.svg: New file.
6515         * artwork/icons/lock.svg: New file.
6516         * artwork/icons/wing-12.png: New file.
6517         * artwork/icons/wing-128.png: New file.
6518         * artwork/icons/wing-16.png: New file.
6519         * artwork/icons/wing-24.png: New file.
6520         * artwork/icons/wing-256.png: New file.
6521         * artwork/icons/wing-32.png: New file.
6522         * artwork/icons/wing-48.png: New file.
6523         * artwork/icons/wing-64.png: New file.
6524         * artwork/icons/wing.svg: New file.
6525
6526 2017-08-01  Werner Koch  <wk@gnupg.org>
6527
6528         gpg,sm: Error out on compliance mismatch while decrypting.
6529         + commit 4e117f206beb38287ddcd3251fb7baabadfbddbb
6530         * g10/pubkey-enc.c (get_session_key): Bail out if the algo is not
6531         allowed in the current compliance mode.
6532         * sm/decrypt.c (gpgsm_decrypt): Ditto.
6533
6534 2017-08-01  NIIBE Yutaka  <gniibe@fsij.org>
6535
6536         Simple typo fix.
6537         + commit fde9a8cc6c849fb21f3e6782dbd5c6bc863357eb
6538         * tools/rfc822parse.c: Fix.
6539
6540         po: Update Japanese translation.
6541         + commit 02b571947b9442604faa7509478cd8577c2c0b9c
6542
6543
6544 2017-07-31  Werner Koch  <wk@gnupg.org>
6545
6546         dirmngr,w32: Fix http connection timeout problem.
6547         + commit 482fd5758c1b7e1b33c4cb50656e586a3ae16815
6548         * dirmngr/http.c (connect_with_timeout) [W32]: Take care of EAGAIN.
6549
6550         Explain the "server is older than xxx warning".
6551         + commit 4ad5bc1b6d72483123963c894ee1412b2ceb99b4
6552         * g10/call-agent.c (warn_version_mismatch): Print a note on how to
6553         restart the servers.
6554         * g10/call-dirmngr.c (warn_version_mismatch): Ditto.
6555         * sm/call-agent.c (warn_version_mismatch): Ditto.
6556         * sm/call-dirmngr.c (warn_version_mismatch): Ditto.
6557
6558 2017-07-28  Werner Koch  <wk@gnupg.org>
6559
6560         Release 2.1.22.
6561         + commit 7d335ff496b129ee6f33c4ca25bd7a6631a4b590
6562
6563
6564         po: Update German translation.
6565         + commit 339f672dad94b4e0000fd2d3a1f272a4861c91c3
6566
6567
6568         agent: Make --ssh-fingerprint-digest re-readable.
6569         + commit 6c9899bede6ecb2ccf7336d12724090f36a6aa3d
6570         * agent/gpg-agent.c (main): Move oSSHFingerprintDigest to ...
6571         (parse_rereadable_options): here.
6572         (opts): Change its description.
6573         (main) <aGPGConfList>: Include this option.
6574         * tools/gpgconf-comp.c (gc_options_gpg_agent): Add option at expert
6575         level.
6576
6577         gpg,sm: String changes for compliance diagnostics.
6578         + commit efe187e8a2b583defdcd9d4b96e3dc83f95bef0d
6579
6580
6581         agent: For OCB key files return Bad Passprase instead of Checksum Error.
6582         + commit 5cf95157c5db88dd599ac4d48f619782179b1438
6583         * agent/protect.c (do_decryption): Map error checksum to bad
6584         passpharse protection
6585
6586         * agent/call-pinentry.c (unlock_pinentry): Don't munge the error
6587         source for corrupted protection.
6588
6589         gpg: Minor rework for better readibility of get_best_pubkey_byname.
6590         + commit 1c35e29af95c46475f297d2bd70a5f3bd49d45b1
6591         * g10/getkey.c (get_best_pubkey_byname): Change return type to
6592         gpg_error_t.  Use var name err instead of rc.  Move a
6593         gpg_error_from_syserror closer to the call.
6594
6595         gpg: Fix segv in get_best_pubkey_byname.
6596         + commit 6496dc1f9d2aef3bf8cf950da2434c96f7a0145c
6597         * g10/getkey.c (get_best_pubkey_byname): Init NEW.
6598
6599         agent: Minor cleanup (mostly for documentation).
6600         + commit 5516ef47a22dfdf9cdf56107f34d2bda9e46deec
6601         * agent/command.c (cmd_pksign): Change var name 'rc' to 'err'.
6602         * agent/findkey.c (read_key_file): Ditto.  Change return type to
6603         gpg_error_t.  On es_fessk failure return a correct error code.
6604         (agent_key_from_file): Change var name 'rc' to 'err'.
6605         * agent/pksign.c (agent_pksign_do): Ditto.  Change return type to
6606         gpg_error_t.  Return a valid erro code on malloc failure.
6607         (agent_pksign): Ditto.  Change return type to gpg_error_t.  replace
6608         xmalloc by xtrymalloc.
6609         * agent/protect.c (calculate_mic): Change return type to gpg_error_t.
6610         (do_decryption): Ditto.  Do not init RC.
6611         (merge_lists): Change return type to gpg_error_t.
6612         (agent_unprotect): Ditto.
6613         (agent_get_shadow_info): Ditto.
6614
6615 2017-07-27  Werner Koch  <wk@gnupg.org>
6616
6617         gpg: Tweak compliance checking for verification.
6618         + commit 6502bb0d2af5784918ebb74242fff6f0a72844bf
6619         * common/compliance.c (gnupg_pk_is_allowed): Rework to always allow
6620         verification.
6621         * g10/mainproc.c (check_sig_and_print): Print a con-compliant warning.
6622         * g10/sig-check.c (check_signature2): Use log_error instead of
6623         log_info.
6624
6625         gpg,sm: Allow encryption (with warning) to any key in de-vs mode.
6626         + commit 1bd22a85b4f06324037b3500d2fa8af62733c926
6627         * g10/encrypt.c (encrypt_crypt): Do not abort for a non-compliant key.
6628         * sm/encrypt.c (gpgsm_encrypt): Ditto.
6629
6630         gpg,sm: Fix compliance checking for decryption.
6631         + commit a0d0cbee7654ad7582400efaa92d493cd8e669e9
6632         * common/compliance.c (gnupg_pk_is_compliant): Remove the Elgamal
6633         signing check.  We don't support Elgamal signing at all.
6634         (gnupg_pk_is_allowed) <de-vs>: Revert encryption/decryption for RSA.
6635         Check the curvenames for ECDH.
6636         * g10/pubkey-enc.c (get_session_key): Print only a warning if the key
6637         is not compliant.
6638         * sm/decrypt.c (gpgsm_decrypt): Ditto.  Use the same string as in gpg
6639         so that we have only one translation.
6640
6641         gpg: Avoid output to the tty during import.
6642         + commit fcb62fe20f45290bf95703ec3bf4d0b361fa4339
6643         * g10/key-check.c (key_check_all_keysigs): Add arg mode and change all
6644         output calls to use it.
6645         * g10/keyedit.c (keyedit_print_one_sig): Add arg fp and chnage all
6646         output calls to use it.
6647         (keyedit_menu): Adjust for changes.
6648         * g10/gpgcompose.c (keyedit_print_one_sig): Add dummy arg fp.
6649         * g10/import.c (import_one): Call key_check_all_keysigs with output to
6650         the log stream.
6651
6652 2017-07-26  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6653
6654         g10: Make sure exactly one fingerprint is output with --quick-gen-key.
6655         + commit 94eea0ed2c8b47cb0fe02b22cbe668705a5fe0d0
6656         * g10/keygen.c (do_generate_keypair): Only set fpr in
6657         list_keyblock_direct invocation if neither --fingerprint nor
6658         --with-fingerprints are given.
6659
6660 2017-07-26  Werner Koch  <wk@gnupg.org>
6661
6662         doc: Add man pages form gpg-wks-server and gpg-wks-client.
6663         + commit be636c3cfca178927b09ef4154c3e555d6f5b1c4
6664         * doc/wks.texi: New.
6665         * doc/gnupg.texi: Include wks.texi.
6666         * doc/Makefile.am (gnupg_TEXINFOS): Add wks.texi.
6667         (myman_pages): Add new man pages.
6668
6669         wks: Fix program names in the usage diagnostics.
6670         + commit c76398da5b15df2086f68bc26b7fde75219976c7
6671         * tools/gpg-wks-client.c (my_strusage): Add case 12.
6672         * tools/gpg-wks-server.c (my_strusage): Add case 12:
6673
6674 2017-07-26  Andre Heinecke  <aheinecke@intevation.de>
6675
6676         doc: Update vsnfd profile example.
6677         + commit 4f569c69075fddbaea588544a6625c28cb4cb8f4
6678         * doc/examples/vsnfd.prf: Use rsa3072
6679
6680 2017-07-26  Werner Koch  <wk@gnupg.org>
6681
6682         dirmngr: Do not use a blocking connect in Tor mode.
6683         + commit c5e5748480952e5bcedb16f6ce6ef7e435acb3c7
6684         * dirmngr/http.c (http_raw_connect): Disable the timeout in Tor mode.
6685         (send_request): Ditto.
6686
6687         dirmngr: Auto-enable Tor on startup or reload.
6688         + commit fd68bdb61ec4f8441da6d3023a8da4315df54cec
6689         * dirmngr/dirmngr.c (dirmngr_use_tor): Test for Tor availibility.
6690
6691         agent,dirmngr: Check for homedir removal also using stat(2).
6692         + commit d50c2eff8d6931586c527edb3dea98dbc6facdec
6693         * agent/gpg-agent.c (have_homedir_inotify): New var.
6694         (reliable_homedir_inotify): New var.
6695         (main):  Set reliable_homedir_inotify.
6696         (handle_tick): Call stat on the homedir.
6697         (handle_connections): Mark availibility of the inotify watch.
6698         * dirmngr/dirmngr.c (handle_tick): Call stat on the homedir.
6699         (TIMERTICK_INTERVAL_SHUTDOWN): New.
6700         (handle_connections): Depend tick interval on the shutdown state.
6701
6702         agent: Lengthen timertick interval on Unix to 4 seconds.
6703         + commit f4ec7697a9c2d7587794d3bd75efbb0b51d6562f
6704         * agent/gpg-agent.c (TIMERTICK_INTERVAL): Same value for Windows and
6705         Unix.
6706
6707 2017-07-25  Werner Koch  <wk@gnupg.org>
6708
6709         common: Strip trailing slashes from the homedir.
6710         + commit 24c7aa0d58e3768690dd8ebef0e8e01af7e80f83
6711         * common/homedir.c (default_homedir): Strip trailing slashes.
6712         (gnupg_set_homedir): Ditto.
6713
6714         w32: Also change the directory on daemon startup.
6715         + commit 0ef50340ef68b2541d9a1aafa71f5400aef4dc7e
6716         * agent/gpg-agent.c (main): Always to the chdir.
6717         * dirmngr/dirmngr.c (main): Ditto.
6718         * scd/scdaemon.c (main): Ditto.
6719
6720         common: New functions gnupg_daemon_rootdir and gnupg_chdir.
6721         + commit 226f143ca01cf335c7c4e3e94c96fb9d271eccc9
6722         * common/sysutils.c (gnupg_chdir): New.
6723         * common/homedir.c (gnupg_daemon_rootdir): New.
6724         * agent/gpg-agent.c (main): Use these functions instead chdir("/").
6725         * dirmngr/dirmngr.c (main): Ditto.
6726         * scd/scdaemon.c (main): Ditto.
6727
6728         gpg: Update key origin info during import merge.
6729         + commit 166d0d7a2439f30c0a250faadc16ce3453447d71
6730         * g10/import.c (update_key_origin): New.
6731         (merge_blocks): Add arg curtime.
6732         (import_one): Pass curtime to merge_blocks.  Call update_key_origin.
6733
6734         gpg: Store key origin for new userids during import merge.
6735         + commit 84c993d9325fc000acac7950b2dfeefa5976df3b
6736         * g10/import.c (apply_meta_data): Rename to ...
6737         (insert_key_origin): this.  Factor code out to ...
6738         (insert_key_origin_pk, insert_key_origin_uid): new funcs.
6739         (import_one): Move insert_key_origin behind clean_key.
6740         (merge_blocks): Add args options, origin, and url.
6741         (append_uid): Rename to ...
6742         (append_new_uid): this.  Add args options, curtime, origin, and url.
6743         Call insert_key_origin_uid for new UIDs.
6744
6745 2017-07-25  NIIBE Yutaka  <gniibe@fsij.org>
6746
6747         dirmngr: Add annotation for fallthrough.
6748         + commit d40b4a41a8d60292fd4b5b951a19883e31090179
6749         * dirmngr/dns.c: Add /* FALL THROUGH */ to clarify.
6750
6751 2017-07-24  Werner Koch  <wk@gnupg.org>
6752
6753         gpg: Extend --key-origin to take an optional URL arg.
6754         + commit 87b5421ca84bbea68217c9ed771ee8c0a98a4d0c
6755         * g10/getkey.c (parse_key_origin): Parse appended URL.
6756         * g10/options.h (struct opt): Add field 'key_origin_url'.
6757         * g10/gpg.c (main) <aImport>: Pass that option to import_keys.
6758         * g10/import.c (apply_meta_data): Extend for file and url.
6759         * g10/keyserver.c (keyserver_fetch): Pass the url to
6760         import_keys_es_stream.
6761
6762         gpg: Store key origin info for new keys from a keyserver.
6763         + commit 2ca0381d077d766593db26f4215b8eddee8d7963
6764         * g10/keyserver.c (keyserver_get_chunk): Use KEYORG_KS if request was
6765         done by fingerprint.
6766         * g10/import.c (apply_meta_data): Implement that.
6767
6768         gpg: Store key origin info for new DANE and WKD retrieved keys.
6769         + commit e7068bf92ec5ca5d440346d43a382c1f625b924d
6770         * g10/import.c (apply_meta_data): Remove arg 'merge'.  Add arg 'url'.
6771         Implement WKD and DANE key origin.
6772         (import_keys_internal): Add arg 'url' and change all callers.
6773         (import_keys_es_stream): Ditto.
6774         (import): Ditto.
6775         (import_one): Ditto.
6776         * g10/keylist.c (list_keyblock_print): Fix update URL printing.
6777         * g10/call-dirmngr.c (gpg_dirmngr_wkd_get): Add arg 'r_url' to return
6778         the SOURCE.  Pass ks_status_cb to assuan_transact.
6779         * g10/keyserver.c (keyserver_import_wkd): Get that URL and pass it to
6780         the import function.
6781
6782         gpg: Filter keys received via DANE.
6783         + commit f6f0dd4d5ea85e0b16e96d7678b1d508182049a8
6784         * g10/keyserver.c (keyserver_import_cert): Use an import filter in
6785         DANE mode.
6786
6787         dirmngr: Print a SOURCE status for WKD requests.
6788         + commit e97548223948222a5c22acdf3775c7f93c1e17a9
6789         * dirmngr/server.c (cmd_wkd_get): Print a SOURCE status.
6790
6791         dirmngr: New function dirmngr_status_printf.
6792         + commit 9b88cfa0962f28894658cff8777fe7a217c6f700
6793         * dirmngr/server.c (dirmngr_status_printf): New.
6794
6795 2017-07-24  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6796
6797         g10: Make sure to emit NEED_PASSPHRASE on --import of secret key.
6798         + commit 872137b5921dd297e7d2c1def6e3868b7595feb5
6799         * call-agent.h (agent_import_key): Add keyid parameters.
6800         * call-agent.c (agent_import_key): Set keyid parameters.
6801         * import.c (transfer_secret_keys): Pass keyid parameters.
6802
6803         w32: Change directory on daemon startup.
6804         + commit 78ebc62604d77600b9865950610717d28c6027a2
6805         * agent/gpg-agent.c [HAVE_W32_SYSTEM]: Include <direct.h>.
6806         (main) [HAVE_W32_SYSTEM]: Change working directory to \.
6807         * dirmngr/dirmngr.c [HAVE_W32_SYSTEM]: Include <direct.h>.
6808         (main) [HAVE_W32_SYSTEM]: Change working directory to \.
6809         * scd/scdaemon.c [HAVE_W32_SYSTEM]: Include <direct.h>.
6810         (main) [HAVE_W32_SYSTEM]: Change working directory to \.
6811
6812         g10: Make sure to emit NEED_PASSPHRASE on --export-secret-key.
6813         + commit d8e46f10698da0bee4cd58d95f1f9832bdda0c5f
6814         * call-agent.h (agent_export_key): Add keyid parameters.
6815         * call-agent.c (agent_export_key): Set keyid parameters.
6816         * export.c (receive_seckey_from_agent): Pass keyid parameters.
6817
6818 2017-07-24  NIIBE Yutaka  <gniibe@fsij.org>
6819
6820         scd: Use unsigned int for fields.
6821         + commit 45e40487fb7bb51228c96c8966e38c643a9b9ba5
6822         * scd/app-openpgp.c (data_objects): Use unsigned ints.
6823
6824         dirmngr: More minor fix.
6825         + commit ade4b2744c848e07b87afa4f186256c2a2ef1d13
6826         * dirmngr/http.c (send_request): Care the case of !USE_TLS.
6827
6828         dirmngr: More minor fixes.
6829         + commit 789401e9557db13422f47a8c09e693f3cee0132b
6830         * dirmngr/http.c (http_verify_server_credentials): Duplicated const.
6831         * dirmngr/ldap.c (parse_one_pattern): Add comment.
6832
6833         dirmngr: Minor fix for Windows.
6834         + commit 274602820cfbb15c7cdb4525acd9793bdb472e78
6835         * dirmngr/http.c (connect_with_timeout): Use FD2INT.
6836
6837         agent: Minor fix for Windows.
6838         + commit 328fca187253c069e3630bd387a71f6d16e9820a
6839         * agent/command-ssh.c (serve_mmapped_ssh_request): Add const
6840         qualifier.
6841
6842 2017-07-21  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6843
6844         g10: Avoid caching passphrase for failed symmetric encryption.
6845         + commit e4c720fa3b31ebd3e9d764c6eab02729cf06124c
6846         * g10/mainproc.c (proc_encrypted): If error code is GPG_ERR_CIPHER_ALGO,
6847         assume the symmetric passphrase was wrong and invalidate the cache.
6848
6849 2017-07-21  Werner Koch  <wk@gnupg.org>
6850
6851         gpg: Extend --quick-set-expire to allow subkey expiration setting.
6852         + commit b55b72bb815ad5870456b89c3a011fa00991b4a8
6853         * g10/keyedit.c (keyedit_quick_set_expire): Add new arg subkeyfprs.
6854         (menu_expire): Rename arg force_mainkey to unattended and allow
6855         unattended changing of subkey expiration.
6856         * g10/gpg.c (main): Extend --quick-set-expire.
6857
6858         gpg: Fix possible double free of the card serialno.
6859         + commit e888f7af6571ecd3994fd55cc18c9e2df7fd0c60
6860         * g10/free-packet.c (copy_public_key): Copy fields serialno and
6861         updateurl.
6862
6863         gpg: Use macros to check the signature class.
6864         + commit 5818ff0ae314af08548fcc23df2b807736144a00
6865         * g10/import.c: Use the extistin macros for better readability.
6866
6867 2017-07-21  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6868
6869         g10: Clean keyblock on initial commit.
6870         + commit 609bbdf3614fbadeba7a6cbdfdf5004b23516a64
6871         * g10/import.c (import_one): If option import-clean is set,
6872         also clean on initial import, not only for merge.
6873
6874 2017-07-21  NIIBE Yutaka  <gniibe@fsij.org>
6875
6876         scd: Fix SEGV in CCID driver.
6877         + commit d8a55da715ce8447b0686f321fa43d00be34a467
6878         * scd/ccid-driver.c (intr_cb): Only kick the loop for removal.
6879         (bulk_in): Don't set POWERED_OFF when interrupt transfer is enabled.
6880
6881         g10: Don't limit at the frontend side for card capability.
6882         + commit a76b6cf9709c0a2a89fa2887075491b80f3d9608
6883         * g10/card-util.c (MAX_GET_DATA_FROM_FILE): New.
6884         (get_data_from_file): Use MAX_GET_DATA_FROM_FILE.
6885         (change_url, change_login, change_private_do): Don't limit.
6886
6887         scd: Add debug message for v3 card.
6888         + commit 892e86b0dc69193ddff018bf9b3938509dd72cb3
6889         * scd/app-openpgp.c (show_caps): Output more messages.
6890
6891 2017-07-20  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6892
6893         doc: Clarify wording of export-attributes.
6894         + commit cea4313644b531ef87b8c8e4bfddde4388cbbe0d
6895         * doc/gpg.texi: Clarify wording of export-attributes.
6896
6897 2017-07-20  Werner Koch  <wk@gnupg.org>
6898
6899         gpg: New option --with-key-origin.
6900         + commit 165cdd8121bbf80bfe2da071539d3578630f198f
6901         * g10/getkey.c (parse_key_origin): Factor list out as ...
6902         (key_origin_list): new struct.
6903         (key_origin_string): New.
6904         * g10/gpg.c (oWithKeyOrigin): New const.
6905         (opts): New option --with-key-origin.
6906         (main): Implement option.
6907         * g10/options.h (struct opt): New flag with_key_origin.
6908         * g10/keylist.c (list_keyblock_print): Print key origin info.
6909         (list_keyblock_colon): Ditto.
6910
6911         common: New function print_utf9_string.
6912         + commit bddc2e04f1ddc18be20efc0f0508be401b345f42
6913         * common/miscellaneous.c (print_utf8_string): New.
6914
6915         gpg: Make function mk_datestr public.
6916         + commit 3ee314dde16d1d69ddf840cdb8b5aa186c592262
6917         * g10/keydb.h (MK_DATESTR_SIZE): New.
6918         * g10/keyid.c (mk_datestr): Make public.  Add arg bufsize and use
6919         snprintf.  Change arg atime to u32.
6920         (datestr_from_pk): Simplify.
6921         (datestr_from_sig): Ditto.
6922         (expirestr_from_pk): Ditto.
6923         (expirestr_from_sig): Ditto.
6924         (revokestr_from_pk): Ditto.
6925
6926 2017-07-20  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
6927
6928         g10: Return proper error when gpg-agent fails to start during probe.
6929         + commit 9998b162b47931fb8a8ed961d53418d505358888
6930         * g10/getkey.c (lookup): Return immediately on any other error than
6931         GPG_ERR_NO_SECKEY from agent_probe_any_secret_key.
6932
6933 2017-07-20  NIIBE Yutaka  <gniibe@fsij.org>
6934
6935         scd: Support longer data length for special DOs for v3 card.
6936         + commit 69614d55018ddb8678d8904a52e648931f480d72
6937         * scd/app-openpgp.c (data_objects): Special DOs like "Login Data",
6938         "URL", "Private DO N" can be longer size >= 256.
6939         (struct app_local_s): Define bits for v3 card.
6940         (get_cached_data): Use extcap.max_special_do for special DOs.
6941         (app_select_openpgp): Detect if extcap_v3, kdf_do, and other bits.
6942
6943         common: logstream fix.
6944         + commit 84146b3ec44943f06c66a603de19094b930ad446
6945         * common/logging.c (set_file_fd): Don't close es_stderr.
6946
6947         dnsmngr: Fix use of CPP.
6948         + commit cc12cf386b620e658fa93a0bd40477bc16d85d98
6949         * dirmngr/dns.c (HAVE_STATIC_ASSERT, HAVE___ATOMIC_FETCH_ADD)
6950         (DNS_HAVE_SOCKADDR_UN, HAVE_SOCK_NONBLOCK): Don't use defined
6951         to be expanded for expression evaluation.
6952
6953 2017-07-19  Justus Winter  <justus@g10code.com>
6954
6955         dirmngr: Forbid redirects from .onion to clearnet URIs.
6956         + commit e7fc6e3bf0eb6ffe53e1f099d28ce45cef4a8a87
6957         * dirmngr/ks-engine-hkp.c (send_request): Forbid redirects from .onion
6958         to clearnet URIs.
6959         * dirmngr/ks-engine-http.c (ks_http_fetch): Likewise.
6960
6961 2017-07-19  Werner Koch  <wk@gnupg.org>
6962
6963         gpg: Avoid asking by fpr and then by keyid during auto-key-retrieve.
6964         + commit 2e5459457473eb4b3e7b2b14815cb94faa66e8bb
6965         * g10/mainproc.c (check_sig_and_print): Track key server request via
6966         fingerprint.
6967
6968 2017-07-19  Justus Winter  <justus@g10code.com>
6969
6970         dirmngr: Implement TLS over http proxies.
6971         + commit da91d2106a17c796ddb066a34db92d33b21c81f7
6972         * dirmngr/http.c (send_request): If a http proxy is to be used, and we
6973         want to use TLS, try to use the CONNECT method to get a connection to
6974         the target server.
6975
6976         dirmngr: Log http response in debug mode.
6977         + commit e7eabe66b6409c1f5225b751ea5c2d456a3856e6
6978         * dirmngr/http.c (parse_response): Log http response in debug mode.
6979
6980         dirmngr: Amend TLS handling.
6981         + commit 1ba220e68149fdb197accf4a15b0a11126c8b431
6982         * dirmngr/http.c (http_wait_response): Get the 'use_tls' flag from the
6983         write cookie, not from the URI.
6984
6985         dirmngr: Fix connecting to http proxies.
6986         + commit 46a4a0c0e77e19f9589088bb87357c33142c3f04
6987         * dirmngr/http.c (send_request): Do not use the 'srvtag' intended for
6988         the target host to connect to the http proxy.
6989
6990         dirmngr: Fix handling of proxy URIs.
6991         + commit 73d4781e4595634548269bafe46aeb7674c5b219
6992         * dirmngr/http.c (send_request): We do not support socks4.
6993
6994 2017-07-19  NIIBE Yutaka  <gniibe@fsij.org>
6995
6996         gpgconf: Make vars read-only explicitly.
6997         + commit 99791184ac4c7486ccdefc150b9921cd923428b9
6998         * tools/gpgconf-comp.c (gc_backend, gc_arg_type, gc_level, gc_flag)
6999         (gc_component): Add const qualifier.
7000
7001         Fix usage of ARGPARSE_OPTS.
7002         + commit fa63db89f9581186ed758c502d4e69914b774157
7003         * agent/gpg-agent.c, agent/preset-passphrase.c,
7004         dirmngr/dirmngr-client.c, dirmngr/dirmngr_ldap.c, kbx/kbxutil.c,
7005         tools/gpg-check-pattern.c, tools/gpgconf.c, tools/gpgsplit.c,
7006         tools/symcryptrun.c: Use ARGPARSE_end.
7007
7008 2017-07-18  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
7009
7010         common: Allow abbreviations of standard options.
7011         + commit f17862d47d184d7f6ef883778cf63801365599a0
7012         * argparse.h (ARGPARSE_SHORTOPT_HELP, ARGPARSE_SHORTOPT_VERSION,
7013         ARGPARSE_SHORTOPT_WARRANTY, ARGPARSE_SHORTOPT_DUMP_OPTIONS): New
7014         macros.
7015         (ARGPARSE_end): Add some placeholders for standard options.
7016         * argparse.c (arg_parse): Fill in missing standard options so
7017         default machinery works.  Check for standard options in new way.
7018         Do not write out standard options for --dump-options.
7019
7020 2017-07-18  Justus Winter  <justus@g10code.com>
7021
7022         gpgscm,w32: Fix testing for absolute paths.
7023         + commit 2e1342b78b020f5b28359b08a4f63cf11479602f
7024         * tests/gpgscm/main.c (path_absolute_p): New function.
7025         (load): Use new function.
7026
7027         dirmngr: Honor http keyserver URLs.
7028         + commit b231959728a0056094134e0fca8cc916c24ef37e
7029         * dirmngr/http.c (parse_uri): Keep an unmodified copy of the URI.
7030         * dirmngr/http.h (struct parsed_uri_s): New field 'original'.
7031         * dirmngr/ks-action.c (ks_action_get): Properly handle http and https
7032         URLs.
7033
7034         dirmngr: Fix memory leak.
7035         + commit ebb35ed7110d1a29061dfb4ccb9038645b20d7f4
7036         * dirmngr/http.c (parse_uri): Properly free partial results.
7037
7038         dirmngr: Fix memory leak.
7039         + commit 3d670fa973a03ea88b5f9459b3222a951136dd7a
7040         * dirmngr/http.c (http_release_parsed_uri): Free 'params'.
7041
7042 2017-07-17  Werner Koch  <wk@gnupg.org>
7043
7044         gpg,sm: Check compliance of the RNG.
7045         + commit a149afe338d61d86985c533cde5e7dbcd31e8698
7046         * common/compliance.c (gnupg_rng_is_compliant): New.
7047         * g10/call-agent.c (start_agent) [W32]: Check rng compliance.
7048         * sm/call-agent.c (start_agent) [W32]: Ditto.
7049         * g10/encrypt.c (encrypt_simple, encrypt_crypt): Check that the RNG is
7050         compliant.
7051         * sm/encrypt.c (gpgsm_encrypt): Ditto.
7052         * g10/sign.c (do_sign): Ditto.
7053         * sm/sign.c (gpgsm_sign): Ditto.
7054
7055         agent: New GETINFO sub-command jent_active.
7056         + commit bbbd0db34b4e387f8dc089fb7d69fdcf2ed91a01
7057         * agent/command.c (cmd_getinfo): Implement it for gcrypt >= 1.8.
7058
7059         common: New function split_fields_colon.
7060         + commit 849467870ee1c10e0a7b1e89cfc9e8214e4963fe
7061         * common/stringhelp.c (split_fields_colon): New.
7062         * common/t-stringhelp.c (test_split_fields_colon): New test.
7063         (main): Call that test.
7064
7065 2017-07-14  Justus Winter  <justus@g10code.com>
7066
7067         tests: Improve 'shell.scm' script.
7068         + commit 58eafd11ed5501c0b72fcb553eb3e097ad29b3c6
7069         * tests/openpgp/defs.scm (create-file): Unlink file first.
7070         * tests/openpgp/shell.scm: Ask whether to import legacy test keys or
7071         not, and whether to drop 'batch' from the configuration.  Add paths to
7072         all the programs to 'PATH'.
7073
7074         gpgscm: Library improvements.
7075         + commit b4d25082fd4502ec01d511c22fecd60d513b81f4
7076         * tests/gpgscm/repl.scm (prompt-yes-no?): New function.
7077         * tests/gpgscm/tests.scm (pathsep-split): Likewise.
7078         (pathsep-join): Likewise.
7079         (with-path): Use the new function.
7080
7081         gpgscm: Fail early if the test setup fails.
7082         + commit 7a6e6ad2880bbff54a75ff608d0ec97d6c405733
7083         * tests/gpgscm/tests.scm (make-environment-cache): Check status code
7084         of setup script.
7085
7086         gpg: Fix importing keys.
7087         + commit 956da89193370d5aa970cff5b77f605534481a02
7088         * g10/import.c (import_one): Fix error handling.
7089
7090 2017-07-13  Werner Koch  <wk@gnupg.org>
7091
7092         gpg: Pass key origin values to import functions.
7093         + commit 330212efb927c119bb5135856f8582c0e4e2e6b7
7094         * g10/import.c (import_keys_stream): Remove this unused function.
7095         (import_keys_internal): Add arg origin.
7096         (import_keys): Ditto.
7097         (import_keys_es_stream): Ditto.
7098         (import): Ditto.
7099         (import_one): Ditto.
7100         (apply_meta_data): New stub.
7101         (import_secret_one): Pass 0 for ORIGIN.
7102         * g10/keyserver.c (keyserver_get_chunk): For now pass 0 for ORIGIN.
7103         (keyserver_fetch): Add arg origin.
7104         (keyserver_import_cert): Pass KEYORG_DANE for ORIGIN.
7105         (keyserver_import_wkd): Pass KEYORG_WKD for ORIGIN.
7106         * g10/gpg.c (main): Pass OPT.KEY_ORIGIN to import_keys and
7107         keyserver_fetch.
7108         * g10/card-util.c (fetch_url): Pass KEYORG_URL for ORIGIN.
7109
7110         gpg: New option --key-origin.
7111         + commit fa1155e89ebb4b16ee95549b8ab72672df3a0c54
7112         * g10/keydb.h (KEYORG_): Rename to KEYORG_.
7113         * g10/packet.h (PKT_user_id): Rename field keysrc to keyorg.  Adjust
7114         users.
7115         (PKT_public_key): Ditto.
7116         (PKT_ring_trust): Ditto.
7117         * g10/options.h (struct opt): Add field key_origin.
7118         * g10/getkey.c (parse_key_origin): New.
7119         * g10/gpg.c (oKeyOrigin): New.
7120         (opts): Add "keys-origin".
7121         (main): Set option.
7122
7123 2017-07-13  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
7124
7125         doc: Document gnupg version requirement for gpg-preset-passphrase.
7126         + commit 877a321d011deb3e8501aa9cc5e9f9cd0b19dddf
7127
7128
7129 2017-07-13  Justus Winter  <justus@g10code.com>
7130
7131         gpgscm: Make loading of modules less verbose.
7132         + commit f78fe1a4ec9d343199e1f424dd09e2937c913412
7133         * tests/gpgscm/main.c (load): Increase logging threshold.
7134
7135         gpgscm: Make it impossible to catch '*interpreter-exit*'.
7136         + commit bce02a8b0f0e51775a4ee5536ccf35efc1f15ca6
7137         * tests/gpgscm/init.scm (throw'): Make it impossible to catch
7138         '*interpreter-exit*'.  This fixes 'exit' (and with it 'fail') inside
7139         'catch' statements.
7140
7141 2017-07-10  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
7142
7143         tofu: Compare squares instead of square roots.
7144         + commit d24594976686983c7186cbe4e78153888a13b6e4
7145         * g10/Makefile.am (tofu_source) [USE_TOFU]: Remove sqrtu32.h and
7146         sqrtu32.c.
7147         * g10/sqrtu32.h, g10/sqrtu32.c: Removed files.
7148         * g10/tofu.c: Compare squares instead of square roots.
7149
7150         speedo: Provide a vagrantfile to test speedo in an isolated VM.
7151         + commit 1455b406e63dd262938e49da5f83c05c17c60a8d
7152         * build-aux/Vagrantfile: New file.
7153
7154 2017-07-06  Neal H. Walfield  <neal@g10code.com>
7155
7156         doc: Improve TOFU documentation.
7157         + commit 243b2a570c30586e19b8c88e43b282d62d8eb77c
7158         * doc/gpg.texi: Improve TOFU documentation.
7159
7160 2017-07-05  Werner Koch  <wk@gnupg.org>
7161
7162         agent: Use MAX_PASSPHRASE_LEN (255) also for the loopback.
7163         + commit 3681ee7dc1e9d8c94fdb046d7be0bbcfeba1cfe9
7164         * agent/call-pinentry.c (agent_get_passphrase): Reduce maximum
7165         passphrase length as conveyed to the loopback to MAX_PASSPHRASE_LEN.
7166         * agent/genkey.c (agent_ask_new_passphrase): Extend the maximum
7167         passphrase as conveyed to the loopback to MAX_PASSPHRASE_LEN.
7168
7169         doc: Update yat2m to take care of SOURCE_DATE_EPOCH.
7170         + commit 139de02b93773615bdd95e04a7f0c1ad73b4f6fb
7171         * doc/yat2m.c (main): Set a default for OPT_DATE.
7172
7173         doc: Prefer an installed version of yat2m.
7174         + commit f6faa058749846de18cb34f1cc79867bb0029922
7175         * configure.ac (YAT2M): Check for tool.
7176         * doc/Makefile.am (yat2m-stamp): Use installed tool if possible.
7177
7178 2017-07-01  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
7179
7180         doc: Document obsolete option in gpgsm.  Closes T2231.
7181         + commit 7fb724c61655c6f75c61572d65a46e21ae112574
7182         * doc/gpgsm.texi: Mark --prefer-system-dirmngr as obsolete.
7183
7184 2017-06-28  Werner Koch  <wk@gnupg.org>
7185
7186         agent: Fix option --debug-wait.
7187         + commit ecd6c0160f49ae83001dfd150df6b1238fc479d5
7188         * agent/gpg-agent.c (opts): Typo fix.
7189
7190 2017-06-26  Justus Winter  <justus@g10code.com>
7191
7192         agent: Support unprotected ssh keys.
7193         + commit 273964798592cd479c111f47e8ce46d5b1999d6a
7194         * agent/command-ssh.c (ssh_key_to_protected_buffer): If the empty
7195         passphrase is supplied, do not protect the key.
7196
7197         tests: Improve test.
7198         + commit b49b1a87ac2695e3892fb001878da59fbc92fa37
7199         * tests/openpgp/ssh-export.scm: Split output at any whitespace.
7200
7201 2017-06-23  Werner Koch  <wk@gnupg.org>
7202
7203         agent: Shutdown on removal of the home directory.
7204         + commit 1ead1ca818bddabc3bca22c195be667993eb3e2e
7205         * common/sysutils.c (gnupg_inotify_watch_delete_self): New.
7206         * agent/gpg-agent.c (handle_connections): Rename my_inotify_fd to
7207         sock_inotify_fd.
7208         (handle_connections): Add home_inotify_fd to watch the home directory.
7209
7210         build: Add missing LIBASSUAN_CFLAGS to dirmngr/.
7211         + commit 815ecdf08a4285c75892cf9ab72feb13f3bcf590
7212         * dirmngr/Makefile.am (t_http_CFLAGS): Add LIBASSUAN_CFLAGS.
7213         (t_ldap_parse_uri_CFLAGS): Ditto.
7214         (t_dns_stuff_CFLAGS): Ditto.
7215
7216         gpg,gpgsm: Emit status code ENCRYPTION_COMPLIANCE_MODE.
7217         + commit f31dc2540acf7cd7f09fd94658e815822222bfcb
7218         * common/status.h (STATUS_ENCRYPTION_COMPLIANCE_MODE): New.
7219         * g10/encrypt.c (encrypt_crypt): Emit new status code.
7220         * sm/encrypt.c (gpgsm_encrypt): Ditto.
7221
7222 2017-06-21  Justus Winter  <justus@g10code.com>
7223
7224         gpg: Close cached keydb handle in gpgv.
7225         + commit a68a98233ab83f0c7b90e6e588b882085fe59d91
7226         * g10/gpgv.c (main): Close cached handle.
7227
7228         tests: Add test for gpgv.
7229         + commit 62274d3c309d8948405c2f966bef507638b4d5c6
7230         * tests/openpgp/Makefile.am (XTESTS): Add the new test.
7231         * tests/openpgp/gpgv.scm: New file.
7232         * tests/openpgp/signed-messages.scm: Likewise.
7233         * tests/openpgp/verify.scm: Move the signed messages to the new file
7234         and load it.
7235
7236         gpg: Fix printing keyserver URLs and notation data.
7237         + commit 890a3a70f2e1340d90c7f499358467979b182719
7238         * g10/keylist.c (show_keyserver_url): Print to 'fp', not to 'stdout'.
7239         (show_notation): Likewise.
7240
7241 2017-06-20  Justus Winter  <justus@g10code.com>
7242
7243         dirmngr: Properly handle SRV records.
7244         + commit 48aae8167dcae80d43b08167a88d9eb170781a04
7245         * dirmngr/ks-engine-hkp.c (enum ks_protocol): New type.
7246         (struct hostinfo_s): New flags indicating whether we already did a
7247         A lookup, or a SRV lookup per protocol.  Turn 'port' into an array.
7248         (create_new_hostinfo): Initialize new fields.
7249         (add_host): Update the port for the given protocol.
7250         (map_host): Simplify hosttable lookup misses.  Check the SRV records
7251         for both protocols on demand, do the A lookup just once.  Return the
7252         correct port.
7253
7254         dirmngr: Refactor variable-sized array code.
7255         + commit fc4834d213af031b456c49c1ba5b5ef8873d1f18
7256         * dirmngr/ks-engine-hkp.c (struct hostinfo_s): Add explicit length and
7257         size fields.
7258         (MAX_POOL_SIZE): New macro.
7259         (create_new_hostinfo): Initialize new fields.
7260         (host_in_pool_p): Adapt.
7261         (select_random_host): Likewise.
7262         (add_host): Likewise.  Move the resizing logic here.
7263         (hostinfo_sort_pool): New function.
7264         (map_host): Simplify.  Move the resizing logic away from here.
7265         (ks_hkp_mark_host): Adapt.
7266         (ks_hkp_print_hosttable): Likewise.
7267
7268         gpg: Fix error handling.
7269         + commit badc1cdae52bd434e5fac2e4275575afeccc2837
7270         * g10/keygen.c (generate_subkeypair): Handle errors from pinentry.
7271
7272 2017-06-19  Werner Koch  <wk@gnupg.org>
7273
7274         gpg,gpgsm: Fix compliance check for DSA and avoid an assert.
7275         + commit 3621dbe52584bc8b417f61b5370ebaa5598db956
7276         * common/compliance.c (gnupg_pk_is_compliant): Swap P and Q for DSA
7277         check.  Explicitly check for allowed ECC algos.
7278         (gnupg_pk_is_allowed): Swap P and Q for DSA check.
7279         * g10/mainproc.c (proc_encrypted): Simplify SYMKEYS check.  Replace
7280         assert by debug message.
7281
7282 2017-06-19  Justus Winter  <justus@g10code.com>
7283
7284         gpgscm: Limit the number of parallel jobs.
7285         + commit 61ef43546ba9f0209692a1569d2f033436566a02
7286         * ffi.c (do_wait_processes): Suppress the timeout error.
7287         * tests.scm (semaphore): New definition.
7288         (test-pool): Only run a bounded number of tests in parallel.
7289         (test::started?): New function.
7290         (run-tests-parallel): Do not report results, do not start the tests.
7291         (run-tests-sequential): Adapt.
7292         (run-tests): Parse the number of parallel jobs.
7293
7294         gpgscm: Improve option parsing.
7295         + commit e555e7ed7de20fbbb1e3b005c32e292f29cc4a58
7296         * tests/gpgscm/tests.scm (flag): Accept arguments of the form
7297         '--foo=bar'.
7298
7299         gpgscm: Improve error handling of foreign functions.
7300         + commit 6639aedaee051e8104d7f63b9a5812abf79440ed
7301         * tests/gpgscm/ffi.scm (ffi-fail): Do not needlessly join the error
7302         message.
7303
7304         gpgscm: Improve error reporting.
7305         + commit 4c8be58fd46bb16332e84ab8ce978087dc5c68a3
7306         * tests/gpgscm/init.scm (throw'): Guard against 'args' being atomic.
7307         * tests/gpgscm/scheme.c (Eval_Cycle): Remove any superfluous colons in
7308         error messages.
7309
7310         tests: Run the OpenPGP tests using the new extended key format.
7311         + commit b766d3d1034e6068a91755ada68f7f7dbe2943b6
7312         * tests/openpgp/all-tests.scm: Generalize a bit, and also add a
7313         variant that uses the new extended key format.
7314         * tests/openpgp/defs.scm (create-gpghome): Conditionally enable the
7315         new extended key format.
7316
7317 2017-06-19  Werner Koch  <wk@gnupg.org>
7318
7319         Change license of some files to LGPLv2.1.
7320         + commit 3419a339d9c4e800bf30e9021e05982d8c1021c1
7321         * COPYING.LIB: Rename to COPYING.LGPL3.
7322         * COPYING.LGPL21: New.
7323         * COPYING.GPL2: New.
7324         * Makefile.am: Distribute them.
7325         * AUTHORS: Update license pointers.  Add BSI as copyright holder.
7326         * common/compliance.c, common/compliance.h: Add BSI copyright notice.
7327         Break overlong lines.
7328         * dirmngr/loadswdb.c: Add BSI copyright notices.
7329         * dirmngr/server.c: Ditto.
7330         * tools/call-dirmngr.c: Change license to LGPLv2.1.  Add BSI
7331         copyright notice.
7332         * tools/call-dirmngr.h: Ditto.
7333         * tools/gpg-wks-client.c: Ditto.
7334         * tools/gpg-wks-server.c: Ditto.
7335         * tools/gpg-wks.h: Ditto.
7336         * tools/mime-maker.c: Ditto.
7337         * tools/mime-maker.h: Ditto.
7338         * tools/mime-parser.c: Ditto.
7339         * tools/mime-parser.h: Ditto.
7340         * tools/send-mail.c: Ditto.
7341         * tools/send-mail.h: Ditto.
7342         * tools/wks-receive.c: Ditto.
7343         * tools/wks-util.c: Ditto.
7344         * tools/rfc822parse.c, tools/rfc822parse.h: Change license to LGPLv2.1.
7345
7346 2017-06-19  Justus Winter  <justus@g10code.com>
7347
7348         gpg: Disable compliance module for other GnuPG components.
7349         + commit 6e23416fe61d4130918f2d1bf6e1f98d102c4610
7350         * common/compliance.c (gnupg_{pk,cipher,digest}_is_compliant): Return
7351         false if the module is not initialized.
7352         (gnupg_{pk,cipher,digest}_is_allowed): Return true if the module is
7353         not initialized.
7354         (gnupg_status_compliance_flag): Do not assert that the module is
7355         initialized.
7356         (gnupg_parse_compliance_option): Likewise.
7357         (gnupg_compliance_option_string): Likewise.
7358
7359 2017-06-14  Justus Winter  <justus@g10code.com>
7360
7361         gpg: Check and fix keys on import.
7362         + commit 9b12b45aa5e67d4d422bf75a3879df1d52dbe67f
7363         * doc/gpg.texi: Document the new import option.
7364         * g10/gpg.c (main): Make the new option default to yes.
7365         * g10/import.c (parse_import_options): Parse the new option.
7366         (import_one): Act on the new option.
7367         * g10/options.h (IMPORT_REPAIR_KEYS): New macro.
7368
7369         gpg: Refactor key checking and fixing.
7370         + commit 404fa8211b6188a0abe83ef43a4b44d528c0b035
7371         * g10/Makefile.am (gpg_sources): Add new files.
7372         * g10/gpgcompose.c (keyedit_print_one_sig): New stub.
7373         * g10/keyedit.c (sig_comparison): Move to new module.
7374         (check_all_keysigs): Likewise.
7375         (fix_keyblock): Adapt callsite.
7376         (keyedit_menu): Likewise.
7377         * g10/key-check.c: New file.
7378         * g10/key-check.h: Likewise.
7379
7380 2017-06-13  Justus Winter  <justus@g10code.com>
7381
7382         gpg: Refactor keyedit module.
7383         + commit 8095d16b3ef6b5f01ec351824855708149f1c1c3
7384         * g10/Makefile.am (gpg_SOURCES): Add new file.
7385         * g10/keyedit.c (NODFLG_*): Move flags to the new header file.
7386         (print_one_sig): Export symbol and rename accordingly.
7387         (print_and_check_one_sig): Adapt accordingly.
7388         (check_all_keysigs): Likewise.
7389         * g10/keyedit.h: New file.
7390         * g10/main.h: Drop declarations, include new header.
7391
7392         dirmngr: Implement querying nameservers over IPv6.
7393         + commit 15d2a009931f44a60b9df6325f837add208459d6
7394         * dirmngr/dns.c (dns_so_check): Reinitialize sockets on address family
7395         mismatch.
7396         (enum dns_res_state): New states for querying over IPv6.
7397         (dns_res_exec): Implement the new states by copying and modifying the
7398         IPv4 variants.  Branch to their respective counterparts if the current
7399         list of resolvers using the current address family is exhausted.
7400
7401 2017-06-13  Werner Koch  <wk@gnupg.org>
7402
7403         gpg: Disable keydb handle caching only for W32.
7404         + commit e80925171ddb20c7e76c1db88c15ce2d9b09db86
7405         * g10/getkey.c (getkey_end) [!W32]: Re-enable caching.
7406
7407         common: Fix -Wswitch warning.
7408         + commit 7c91b48f0e80266cf7491c2bb7d8aabc12362643
7409         * common/compliance.c (gnupg_digest_is_allowed): Don't include
7410         GCRY_MD_WHIRLPOOL because it is not a digest_algo_t.
7411
7412 2017-06-11  Neal H. Walfield  <neal@g10code.com>
7413
7414         gpg: Send gpgcompose --help output to stdout, not stderr.
7415         + commit 7aeac20f12ed257d3d159b304afeeac7f406c9d2
7416         * g10/gpgcompose.c (show_help): Send gpgcompose --help output to
7417         stdout, not stderr.
7418
7419         gpg: Improve some output of gpgcompose.
7420         + commit cb0484e0762a1ce05d00d949f4b70162e2f7b82c
7421
7422
7423         gpg: Support 'gpgcompose --encrypted-pop --help'
7424         + commit 4ddf4e114c8df06d89144e857b7601de0b7e5a7c
7425         * g10/gpgcompose.c (encrypted_pop_options): New variable.
7426         (encrypted_pop): Support the --help option.
7427
7428         gpg: Remove dead code.
7429         + commit 8a9066865688cf17594b2bdde4b260b0ef36d68e
7430         * g10/gpgcompose.c (filter_pop): F->PKTTYPE will never be
7431         PKT_ENCRYPTED_MDC.
7432         (encrypted_pop): Likewise and there is no option --encrypted-mdc-pop.
7433
7434 2017-06-08  Marcus Brinkmann  <mb@g10code.com>
7435
7436         artwork: Add new banner.
7437         + commit bc5503b2bf273b51d5dc59617e596f1cfb742fbc
7438         * artwork/banner/banner-full.png: New file.
7439         * artwork/banner/banner-rectangle.png: New file.
7440         * artwork/banner/banner.svg: New file.
7441         * artwork/banner/Bungee-Regular.ttf: New file.
7442         * artwork/banner/Raleway-license.txt: New file.
7443         * artwork/banner/banner-half.png: New file.
7444         * artwork/banner/banner-skyscraper.png: New file.
7445         * artwork/banner/Bungee-license.txt: New file.
7446         * artwork/banner/Raleway-ExtraBold.ttf: New file.
7447         * artwork/banner/Raleway-SemiBold.ttf: New file.
7448
7449 2017-06-08  Justus Winter  <justus@g10code.com>
7450
7451         common,gpg,sm: Restrict the use of algorithms according to CO_DE_VS.
7452         + commit a64a55e10420cf11e00062b590dffe5d0c3e8192
7453         * common/compliance.c (gnupg_pk_is_allowed): New function.
7454         (gnupg_cipher_is_allowed): Likewise.
7455         (gnupg_digest_is_allowed): Likewise.
7456         * common/compliance.h (enum pk_use_case): New definition.
7457         (gnupg_pk_is_allowed): New prototype.
7458         (gnupg_cipher_is_allowed): Likewise.
7459         (gnupg_digest_is_allowed): Likewise.
7460         * g10/decrypt-data.c (decrypt_data): Restrict use of algorithms using
7461         the new predicates.
7462         * g10/encrypt.c (encrypt_crypt): Likewise.
7463         * g10/gpg.c (main): Likewise.
7464         * g10/pubkey-enc.c (get_session_key): Likewise.
7465         * g10/sig-check.c (check_signature2): Likewise.
7466         * g10/sign.c (do_sign): Likewise.
7467         * sm/decrypt.c (gpgsm_decrypt): Likewise.
7468         * sm/encrypt.c (gpgsm_encrypt): Likewise.
7469         * sm/gpgsm.c (main): Likewise.
7470         * sm/sign.c (gpgsm_sign): Likewise.
7471         * sm/verify.c (gpgsm_verify): Likewise.
7472
7473         gpg: Fix computation of compliance with CO_DE_VS.
7474         + commit b03fab09e188f7bb10237d4f20455e4026737e4e
7475         * g10/mainproc.c (proc_encrypted): Symmetric encryption is also in
7476         compliance with CO_DE_VS.
7477
7478 2017-06-08  Werner Koch  <wk@gnupg.org>
7479
7480         dirmngr: Implement HTTP connect timeouts of 15 or 2 seconds.
7481         + commit 9b43220b8ad1a5c1cd51de3bbfff7ccbcc3fa877
7482         * dirmngr/dirmngr.c (oConnectTimeout, oConnectQuickTimeout): New
7483         enums.
7484         (opts): New options --connect-timeout and --connect-quick-timeout.
7485         (DEFAULT_CONNECT_TIMEOUT): New.
7486         (DEFAULT_CONNECT_QUICK_TIMEOUT): New.
7487         (parse_rereadable_options): Handle new options.
7488         (post_option_parsing): New.  Use instead of direct calls to
7489         set_debug() and set_tor_mode ().
7490         (main): Setup default timeouts.
7491         (dirmngr_init_default_ctrl): Set standard connect timeout.
7492         * dirmngr/dirmngr.h (opt): New fields connect_timeout and
7493         connect_quick_timeout.
7494         (server_control_s): New field timeout.
7495         * dirmngr/ks-engine-finger.c (ks_finger_fetch): Pass timeout to
7496         http_raw_connect.
7497         * dirmngr/ks-engine-hkp.c (send_request): Call
7498         http_session_set_timeout.
7499         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
7500         * dirmngr/server.c (cmd_wkd_get, cmd_ks_search, cmd_ks_get)
7501         (cmd_ks_fetch): Implement --quick option.
7502
7503         dirmngr: Allow a timeout for HTTP and other TCP connects.
7504         + commit 5b9025cfa1f9b1c67ddf2f6bf87d863e780cf157
7505         * dirmngr/http.c: Include fcntl.h.
7506         (http_session_s): Add field 'connect_timeout'.
7507         (http_session_new): Clear that.
7508         (http_session_set_timeout): New function.
7509         (my_wsagetlasterror) [W32]: New.
7510         (connect_with_timeout): New function.
7511         (connect_server): Add arg 'timeout' and call connect_with_timeout.
7512         (send_request): Add arg 'timeout' and pass it to connect_server.
7513         (http_raw_connect): Add arg 'timeout'.
7514         (http_open): Pass TIMEOUT from the session to connect_server.
7515
7516         gpg: Avoid failure exit when scdaemon is disabled but not needed.
7517         + commit 17e5afd80f247c356f03c71e8b61da424ffedabb
7518         * g10/call-agent.c (warn_version_mismatch): Use log_info if error is
7519         "not supported".
7520
7521 2017-06-07  Justus Winter  <justus@g10code.com>
7522
7523         common: Add cipher mode to compliance predicate.
7524         + commit e051e396156211449568afa0ca7505dc13eaa3b4
7525         * common/compliance.c (gnupg_cipher_is_compliant): Add mode parameter.
7526         * common/compliance.h (gnupg_cipher_is_compliant): Likewise.
7527         * g10/mainproc.c (proc_encrypted): Adapt callsite.
7528         * sm/decrypt.c (gpgsm_decrypt): Likewise.
7529
7530         common,gpg,sm: Initialize compliance module.
7531         + commit 21fc2508c979a8202dd8ca7fa7b801e0d62a5ceb
7532         * common/compliance.c (gnupg_initialize_compliance): New function.
7533         * common/compliance.h (gnupg_initialize_compliance): New prototype.
7534         * g10/gpg.c (main): Use the new function.
7535         * sm/gpgsm.c (main): Likewise.
7536
7537         common,gpg: Move the compliance option printer.
7538         + commit f440cf73eab0b0e75e3cb2e8c9e70a77f20ef1dc
7539         * common/compliance.c (gnupg_compliance_option_string): New function.
7540         * common/compliance.h (gnupg_compliance_option_string): New prototype.
7541         * g10/encrypt.c (write_pubkey_enc_from_list): Update callsite.
7542         * g10/gpg.c (main): Likewise.
7543         * g10/keyedit.c (keyedit_menu): Likewise.
7544         * g10/pkclist.c (build_pk_list): Likewise.
7545         * g10/main.h (compliance_option_string): Remove prototype.
7546         * g10/misc.c (compliance_option_string): Remove function.
7547
7548         common,gpg,sm: Move the compliance option parser.
7549         + commit 842d233d408457cfa9a8473a6748472956f44e84
7550         * common/compliance.c (gnupg_parse_compliance_option): New function.
7551         * common/compliance.h (struct gnupg_compliance_option): New type.
7552         (gnupg_parse_compliance_option): New prototype.
7553         * g10/gpg.c (parse_compliance_option): Remove function.
7554         (compliance_options): New variable.
7555         (main): Adapt callsite.
7556         * sm/gpgsm.c (main): Use the new common function.
7557         * sm/gpgsm.h (opt): New field 'compliance'.
7558
7559         gpg: Improve compliance with CO_DE_VS.
7560         + commit 027ce4ba37be1d052bca2f6109fe810ef57f4038
7561         * g10/gpg.c (set_compliance_option): The specification, section 4.1.1,
7562         forbids the use of encryption without integrity protection.
7563
7564 2017-06-07  Andre Heinecke  <aheinecke@intevation.de>
7565
7566         speedo: Fix a minor memleak in the installer.
7567         + commit 13dc75a4e7cc2959003c08940fc53c6ece7b77e4
7568         * build-aux/speedo/w32/g4wihelp.c (path_remove): Free path_new on
7569         early return.
7570
7571 2017-06-06  Andre Heinecke  <aheinecke@intevation.de>
7572
7573         speedo: Fix source tar call ambiguity.
7574         + commit 96acbdd7265f504d06783adfd6322a6675c41c0a
7575         * build-aux/speedo.mk (dist-source): Expand exclude-vc to
7576         exclude-vcs.
7577
7578 2017-06-01  Justus Winter  <justus@g10code.com>
7579
7580         gpg: Report compliance with CO_DE_VS.
7581         + commit be8ca8852629786266db4d3d69b2c2fb03bd6365
7582         * common/compliance.c (gnupg_pk_is_compliant): Add DSA with certain
7583         parameters.
7584         (gnupg_cipher_is_compliant): New function.
7585         (gnupg_digest_is_compliant): Likewise.
7586         * common/compliance.h (gnupg_cipher_is_compliant): New prototype.
7587         (gnupg_digest_is_compliant): Likewise.
7588         * common/status.h (STATUS_DECRYPTION_COMPLIANCE_MODE): New status.
7589         (STATUS_VERIFICATION_COMPLIANCE_MODE): Likewise.
7590         * doc/DETAILS: Document the new status lines.
7591         * g10/mainproc.c (proc_encrypted): Compute compliance with CO_DE_VS
7592         and report that using the new status line.
7593         (check_sig_and_print): Likewise.
7594         * sm/decrypt.c (gpgsm_decrypt): Likewise.
7595         * sm/verify.c (gpgsm_verify): Likewise.
7596
7597         common: Improve checking for compliance with CO_DE_VS.
7598         + commit 3b70f62423041e614332b90d782576ee6868a030
7599         * common/compliance.c (gnupg_pk_is_compliant): Only certain RSA key
7600         sizes are compliant.
7601
7602         gpg,common: Move the compliance framework.
7603         + commit 8a012280e0f0a462c094d106355aa436fceb1b76
7604         * common/Makefile.am (common_sources): Add new files.
7605         * common/compliance.c: New file.  Move 'gnupg_pk_is_compliant' here,
7606         and tweak it to not rely on types private to gpg.
7607         * common/compliance.h: New file.  Move the compliance enum here.
7608         * g10/keylist.c (print_compliance_flags): Adapt callsite.
7609         * g10/main.h (gnupg_pk_is_compliant): Remove prototype.
7610         * g10/misc.c (gnupg_pk_is_compliant): Remove function.
7611         * g10/options.h (opt): Use the new compliance enum.
7612         * sm/keylist.c (print_compliance_flags): Use the common functions.
7613
7614 2017-05-31  Justus Winter  <justus@g10code.com>
7615
7616         gpg: Fix compliance computation.
7617         + commit 02af509dfc2b893720aa0c7b380fd7736b2bafd0
7618         * g10/misc.c (gnupg_pk_is_compliant): Compare against CO_RFC2440, not
7619         RFC2440 which is actually a predicate.
7620
7621         sm: Simplify code.
7622         + commit f9cb15b385f64f7c9403670f03632f81a874f213
7623         * sm/verify.c (gpgsm_verify): Simplify by using a newer gcrypt
7624         interface.
7625
7626         doc: Improve documentation.
7627         + commit 485b5a6e6dfe7aa545afa926e060d516ae911e42
7628         * doc/gpgsm.texi: Mention that '--with-key-data' implies
7629         '--with-colons'.
7630
7631 2017-05-31  NIIBE Yutaka  <gniibe@fsij.org>
7632
7633         agent: Fix error from do_encryption.
7634         + commit c03e0eb01dc4632432d0472a6f8051142082bea4
7635         * agent/protect.c (do_encryption): Don't mask failure of OUTBUF
7636         allocation.
7637
7638         scd: Fix error code on failure at usb_init.
7639         + commit 8defb21d34410d000c8b776e0e3a1edd04762638
7640         * scd/ccid-driver.c (ccid_dev_scan): Return GPG_ERR_ENODEV.
7641
7642         scd: Handle a failure of libusb_init.
7643         + commit 5c33649782bf255af5a55f16eac5e85f059b00bf
7644         * scd/ccid-driver.c (ccid_get_reader_list, ccid_dev_scan): Handle
7645         failure.
7646
7647 2017-05-30  Andre Heinecke  <aheinecke@intevation.de>
7648
7649         gpg: Disable keydb handle caching.
7650         + commit d3d640b9cc98dd0d06b49a2e4d46eb67af96fe29
7651         * g10/getkey.c (getkey_end): Disable caching of the open keydb
7652         handle.
7653
7654 2017-05-30  NIIBE Yutaka  <gniibe@fsij.org>
7655
7656         agent: Fix memory leaks.
7657         + commit 996544626ea416c173a940db47f47f9e5cbd844c
7658         * agent/divert-scd.c (ask_for_card): Free WANT_KID and WANT_SN_DISP.
7659         * agent/gpg-agent.c (create_server_socket): Free UNADDR.
7660
7661 2017-05-25  Werner Koch  <wk@gnupg.org>
7662
7663         dirmngr: This towel should better detect a changed resolv.conf.
7664         + commit de3a0988ef9addccd6b5c7950fb8797afbc3978d
7665         * dirmngr/dns-stuff.c (resolv_conf_changed_p): Fix initialization time
7666         issue.
7667
7668         dirmngr: Re-init libdns resolver on towel change of resolv.conf.
7669         + commit b5f356e9fba2d99909f8f54d7b7e6836bed87b68
7670         * dirmngr/dns-stuff.c: Include sys/stat.h.
7671         (RESOLV_CONF_NAME): New macro to replace a string.
7672         (resolv_conf_changed_p): New.
7673         (libdns_init): Call new function
7674         (libdns_res_open): Ditto.
7675
7676 2017-05-24  Justus Winter  <justus@g10code.com>
7677
7678         agent: Make digest algorithms for ssh fingerprints configurable.
7679         + commit 525f2c482abb6bc2002eb878b03558fb43e6b004
7680         * agent/agent.h (opt): New field 'ssh_fingerprint_digest'.
7681         * agent/command-ssh.c (data_sign, ssh_identity_register): Honor the
7682         option for strings used to communicate with the user.
7683         * agent/findkey.c (agent_modify_description): Likewise.
7684         * agent/gpg-agent.c (cmd_and_opt_values): New value.
7685         (opts): New option '--ssh-fingerprint-digest'.
7686         (parse_rereadable_options): Set the default to MD5 for now.
7687         (main): Handle the new option.
7688         * doc/gpg-agent.texi: Document the new option.
7689
7690         agent: Write both ssh fingerprints to 'sshcontrol' file.
7691         + commit a5f046d99a084b6a95268f03c1b588e8b78083cb
7692         * agent/command-ssh.c (add_control_entry): Hand in the key, write both
7693         the MD5- and the SHA256-based fingerprint to the 'sshcontrol' file
7694         when adding ssh keys.
7695         (ssh_identity_register): Adapt callsite.
7696
7697         common: Correctly render SHA256-based ssh fingerprints.
7698         + commit 3a07a69dfc87b4fff610740d3dde8e23f0d2f8bc
7699         * common/ssh-utils.c (dummy_realloc): New function.
7700         (dummy_free): Likewise.
7701         (get_fingerprint): Prepend the fingerprint with the name of the digest
7702         algorithm.  Correctly render SHA256-based ssh fingerprints.
7703         * common/t-ssh-utils.c (sample_keys): Add SHA256 hashes for the keys.
7704         (main): Add an option to dump the keys to gather fingerprints, also
7705         print the SHA256 fingerprint for keys given as arguments, and check
7706         the SHA256 fingerprints of the test keys.
7707
7708         common: Support different digest algorithms for ssh fingerprints.
7709         + commit 3ac1a9d3a018816233a855faff059b4e0657a0f1
7710         * common/ssh-utils.c (get_fingerprint): Add and honor 'algo' parameter.
7711         (ssh_get_fingerprint{,_string}): Likewise.
7712         * common/ssh-utils.h (ssh_get_fingerprint{,_string}): Update prototypes.
7713         * common/t-ssh-utils.c (main): Adapt accordingly.
7714         * agent/command-ssh.c (agent_raw_key_from_file): Likewise.
7715         (ssh_identity_register): Likewise.
7716         * agent/command.c (do_one_keyinfo): Likewise.
7717         * agent/findkey.c (modify_description): Likewise.
7718
7719 2017-05-22  NIIBE Yutaka  <gniibe@fsij.org>
7720
7721         agent: Add const qualifier for read-only table.
7722         + commit 509e4a4d7491daf496b21e5892f4f63ab90e8e21
7723         * agent/call-pinentry.c (start_pinentry): Add const to tbl.
7724         * agent/command-ssh.c (request_specs): Add const.
7725         (ssh_key_types): Likewise.
7726         (request_spec_lookup): Add const to the return value and SPEC.
7727         (ssh_request_process): Likewise.
7728         * agent/protect.c (protect_info): Add const.
7729         (agent_unprotect): Add const to algotable.
7730
7731         g10: Fix default-key selection for signing, possibly by card.
7732         + commit fbb2259d22e6c6eadc2af722bdc52922da348677
7733         * g10/call-agent.c (warn_version_mismatch): Revert.
7734         (start_agent): Suppress version mismatch if relevant.
7735         * g10/getkey.c (get_seckey_default_or_card): New.
7736         * g10/skclist.c (build_sk_list): Use get_seckey_default_or_card.
7737
7738 2017-05-18  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
7739
7740         doc: Fix spellings.
7741         + commit 3713f67026467f63f80649c92ac4cc7973589855
7742
7743
7744         docs: Point to https://dev.gnupg.org/ .
7745         + commit 705da1eb23aef92c42d6d657b20a0984b104f72f
7746         Replace mentions of bugs.gnupg.org with https://dev.gnupg.org/.  Since
7747         the project has transitioned to a better workflow for supporting
7748         contributions, we should ensure that our documentation points to the
7749         right place.
7750
7751 2017-05-17  Justus Winter  <justus@g10code.com>
7752
7753         gpgscm: Fix checking for opcode arguments.
7754         + commit aae50e0b6a61549e226e0c7785260ad517f0ffff
7755         * tests/gpgscm/scheme.c (Eval_Cycle): Update 'pcd' after dispatching
7756         an instruction.
7757
7758         tests: Fix agent teardown in release builds.
7759         + commit 0e1729bb993648deca84a2664ae78edc848d7003
7760         * tests/openpgp/defs.scm (start-agent,stop-agent): Use gpg-conf which
7761         will properly use the '--build-prefix' argument to make gpgconf use
7762         tools from the build directory.
7763
7764 2017-05-17  NIIBE Yutaka  <gniibe@fsij.org>
7765
7766         g10: Fix gpgcompose.c.
7767         + commit ae95a7f5335e605fcd71fbe4a18ed384c88d590a
7768         * g10/gpgcompose.c (show_help): Check return value.
7769
7770         g10: Suppress error for card availability check.
7771         + commit a8dd96826f8484c0ae93c954035b95c2a75c80f2
7772         * g10/call-agent.c (start_agent): Add semantics for card; Suppress
7773         error for card check.
7774         (warn_version_mismatch): Ignore an error for scdaemon.
7775         (agent_scd_serialno): Call start_agent with
7776         FLAG_FOR_CARD_SUPPRESS_ERRORS.
7777
7778 2017-05-16  Justus Winter  <justus@g10code.com>
7779
7780         tests: Configure the environments to use scdaemon from build tree.
7781         + commit 386a7bbb245dd3ab7c4156a554adbe75d82bdf49
7782         * tests/gpgme/gpgme-defs.scm: Use the scdaemon from the build tree
7783         when writing a 'gpg-agent.conf'.
7784         * tests/gpgsm/gpgsm-defs.scm: Likewise.
7785         * tests/openpgp/defs.scm: Likewise.
7786
7787 2017-05-15  Werner Koch  <wk@gnupg.org>
7788
7789         Release 2.1.21.
7790         + commit 9574820329128f0ea8a98f9bfc0e77c73c3e0ec0
7791
7792
7793         po: Update German translation.
7794         + commit 4bd079dbdb44067688377156413dd32a82a89d22
7795
7796
7797         gpg: Do not mark ", " translatable.
7798         + commit 2d381b0f0ba97657e9fb2971eca6648bb77dd2cc
7799         * g10/tofu.c (ask_about_binding): Remove useless translation markers.
7800
7801 2017-05-15  Andre Heinecke  <aheinecke@intevation.de>
7802
7803         dirmngr,w32: Fix ldap crl read on windows.
7804         + commit abe3a9043f86b48b92ddcec47197e032e35a6f4f
7805         Summary:
7806         * dirmngr/ldap-wrapper-ce.c (outstream_cookie_s): Add buffer_read_pos.
7807         (buffer_get_data): Use seperate read pos.
7808
7809 2017-05-15  Werner Koch  <wk@gnupg.org>
7810
7811         common: Let format_text return an error.
7812         + commit 00b7767bc6fe309aa20375c859ebf708cfc7b9ea
7813         * common/stringhelp.c (format_text): Return NULL on error.
7814         * common/t-stringhelp.c (test_format_text): Adjust for change.
7815         * g10/gpgcompose.c (show_help): Abort on out of core.
7816         * g10/tofu.c (ask_about_binding): Abort on format_text error.
7817         (show_statistics): Ditto.
7818         (show_warning): Ditto.
7819
7820 2017-05-11  Justus Winter  <justus@g10code.com>
7821
7822         tests: Also run all OpenPGP tests using keyrings.
7823         + commit bc01d62dc5d520e138499df5d80fb50f9e87e3e8
7824         * tests/openpgp/all-tests.scm: Run each test twice, once with public
7825         keys stored in a keybox, once with a keyring.
7826         * tests/openpgp/defs.scm (create-gpghome): Create a public keyring to
7827         make GnuPG use that instead of creating a keybox if '--use-keyring' is
7828         given.
7829         * tests/openpgp/setup.scm: Fix flag handling and usage.
7830
7831         tests: Make it possible to run all tests using our infrastructure.
7832         + commit f4365790daa1d1400c7f0fe73ac9a6d25f0c6d0a
7833         * Makefile.am (TESTS_ENVIRONMENT): New variable.
7834         (check-all): New phony target to run all tests.
7835         * tests/gpgme/gpgme-defs.scm (have-gpgme?): New function that tests
7836         whether the GPGME test suite is available instead of exiting the
7837         process.
7838         * tests/gpgscm/init.scm (export): New macro.
7839         * tests/gpgscm/tests.scm (run-tests): New function.
7840         (load-tests): Likewise.
7841         * tests/gpgme/run-tests.scm: Simplify and move the parsing of the list
7842         of tests to 'all-tests.scm'.
7843         * tests/gpgsm/run-tests.scm: Likewise.
7844         * tests/migrations/run-tests.scm: Likewise.
7845         * tests/openpgp/run-tests.scm: Likewise.
7846         * tests/gpgme/Makefile.am: To select the tests to run, use the
7847         variable 'TESTS'.  This harmonizes the interface with the automake
7848         test suite.
7849         * tests/gpgsm/Makefile.am: Likewise.
7850         * tests/migrations/Makefile.am: Likewise.
7851         * tests/openpgp/Makefile.am: Likewise.
7852         * tests/openpgp/README: Likewise.
7853         * agent/all-tests.scm: New file.
7854         * common/all-tests.scm: Likewise.
7855         * g10/all-tests.scm: Likewise.
7856         * g13/all-tests.scm: Likewise.
7857         * tests/gpgme/all-tests.scm: Likewise.
7858         * tests/gpgsm/all-tests.scm: Likewise.
7859         * tests/migrations/all-tests.scm: Likewise.
7860         * tests/openpgp/all-tests.scm: Likewise.
7861         * tests/run-tests.scm: Likewise.
7862
7863         tests: Move the makefile parser.
7864         + commit 78d6a25a2db22ad2ae30d57ca980c0400cfef726
7865         * tests/gpgme/gpgme-defs.scm (parse-makefile, parse-makefile-expand):
7866         Move...
7867         * tests/gpgscm/makefile.scm: ... here.
7868         * tests/gpgscm/Makefile.am (EXTRA_DIST): Add new file.
7869
7870         gpgscm: Make it possible to set the logfile name.
7871         + commit 29ef34cc4cb23e7b743dbf4cc8e5761f06076b9a
7872         * tests/gpgscm/tests.scm (test): Only set the default log filename
7873         when it has not been set before.
7874
7875 2017-05-10  NIIBE Yutaka  <gniibe@fsij.org>
7876
7877         g10, sm, dirmngr, common: Add comment for fall through.
7878         + commit 0ce94a9698104d9bfc73d5a37478189564c96eb4
7879         * common/b64dec.c (b64dec_proc): Comment to clarify.
7880         * dirmngr/cdblib.c (cdb_make_put): Use same pattern to clarify.
7881         * dirmngr/dirmngr-client.c (read_pem_certificate): Likewise.
7882         * dirmngr/ks-engine-hkp.c (ks_hkp_get): Likewise.
7883         * g10/armor.c (unarmor_pump): Likewise.
7884         * g10/gpg.c (main): Likewise.
7885         * g10/import.c (read_block): Likewise.
7886         * g10/keygen.c (make_backsig): Likewise.
7887         * g10/pkclist.c (check_signatures_trust):  Likewise.
7888         * sm/gpgsm.c (main): Likewise.
7889
7890         g10: Stop compiler warning for t-stutter.
7891         + commit 98b759119c81c5b39f34f8a9a7b6a57e91ad6470
7892         * g10/t-stutter.c (do_test): Refer current_test_group_failed.
7893
7894 2017-05-08  Justus Winter  <justus@g10code.com>
7895
7896         gpg: Properly account for ring trust packets.
7897         + commit 22739433e98be80e46fe7d01d52a9627c1aebaae
7898         * g10/keyring.c (keyring_get_keyblock): Use the parser's packet count
7899         instead of counting ourself.
7900         * g10/packet.h (struct parse_packet_ctx_s): New field
7901         'n_parsed_packets'.
7902         (init_parse_packet): Initialize new field.
7903         * g10/parse-packet.c (parse): Count packets.
7904
7905 2017-05-04  Justus Winter  <justus@g10code.com>
7906
7907         tests: Support tests that are expected to fail.
7908         + commit d6b46462f8c5c705ffb7cf8af03465a926aa11d3
7909         * tests/gpgscm/tests.scm (test-pool): Rework reporting.  Filter using
7910         the computed test status instead of the return value.  Also print the
7911         new categories 'failed expectedly' and 'passed unexpectedly'.
7912         (test): If a test ends with a bang (!), it is expected to fail.  Adapt
7913         status, status-string, and xml accordingly.
7914
7915         tests: Add function to dump packets.
7916         + commit eab0138e3179f247180a639a91570e5ee2c6ad0e
7917         * tests/openpgp/defs.scm (gpg-dump-packets): New function.
7918
7919 2017-05-03  Andre Heinecke  <aheinecke@intevation.de>
7920
7921         speedo,w32: Fix silent user mode installation.
7922         + commit d378cc34a8d3d5053cf0c5ac7aa731c1bcefee22
7923         * build-aux/speedo/w32/inst.nsi (AddToPath): Move account
7924         check here.
7925         (PrintNonAdminWarning): Remove is_user_install variable.
7926
7927 2017-05-03  Justus Winter  <justus@g10code.com>
7928
7929         gpgscm: Create and re-use frame objects.
7930         + commit 8a168a6d4052ec31fed77c79bb96ffdd32bf9646
7931         * tests/gpgscm/scheme-private.h (struct scheme): New field
7932         'frame_freelist'.
7933         * tests/gpgscm/scheme.c (enum scheme_types): New type 'T_FRAME'.
7934         (type_to_string): Handle new type.
7935         (settype): New macro.
7936         (gc_disable): Make sure there is at least one frame in the free list.
7937         (mark): Handle frame objects.
7938         (finalize_cell): Likewise.
7939         (dump_stack_initialize): Initialize free list.
7940         (dump_stack_free): Simplify.
7941         (frame_length): New variable.
7942         (dump_stack_make_frame): New function.
7943         (frame_slots): Likewise.
7944         (frame_payload): New macro.
7945         (dump_stack_allocate_frame): New function.
7946         (dump_stack_deallocate_frame): Likewise.
7947         (dump_stack_preallocate_frame): Likewise.
7948         (_s_return): Unpack frame object and deallocate it.
7949         (s_save): Wrap state in an frame object.
7950         (dump_stack_mark): Mark the free list.
7951
7952         gpgscm: Merge opexe_0.
7953         + commit 9c6407d17e0cb9f4a370b1b83e7816577ec7d29d
7954         * tests/gpgscm/scheme-private.h (struct scheme): Remove field 'op'.
7955         * tests/gpgscm/scheme.c (opexe_0): Inline into 'Eval_Cycle'.
7956         (_Error_1): Return the opcode to evaluate next.
7957         (Error_1): Do not return, but set the opcode and goto dispatch.
7958         (Error_0): Likewise.
7959         (s_goto): Likewise.
7960         (s_return): Likewise.
7961         (s_return_enable_gc): Likewise.
7962         (s_thread_to): Remove superfluous cast.
7963         (_s_return): Return the opcode to evaluate next.
7964         (scheme_init_custom_alloc): Adapt to removal of field 'op'.
7965
7966 2017-05-03  Andre Heinecke  <aheinecke@intevation.de>
7967
7968         speedo,w32: Allow installation as normal user.
7969         + commit cacfd4bce94704b531f68ee76fb40789e44fde67
7970         * build-aux/speedo/w32/g4wihelp.c (ENV_HK_USER, ENV_REG_USER):
7971         New defines.
7972         (path_add): Handle is_user_install variable. Don't abort
7973         if Path reg key does not exist. Fix crash if Path reg key
7974         does not contain a semicolon.
7975         (path_remove): Handle is_user_install variable. Fix crash
7976         if Path reg key does not exist.
7977         * build-aux/speedo/w32/inst.nsi: Remove obsolete HAVE_STARTMENU
7978         this was double guarded with WITH_GUI. Add Multiuser plugin and
7979         defines for this. Use SHCTX instead of HKLM / HKCU.
7980         (PrintNonAdminWarning): Only Warn and don't abort.
7981
7982 2017-05-02  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
7983
7984         g10: Remove skeleton options files.
7985         + commit 201f86803017c1db373023f7b506d4a0dc644bbc
7986         * build-aux/speed/w32/inst.nsi: stop installing skeleton files.
7987         * doc/gpg.texi: stop documenting skeleton files.
7988         * g10/Makefile.am: stop installing skeleton files.
7989         * g10/openfile.c (copy_options_file): Remove.
7990         (try_make_homedir): do not call copy_options_file.
7991
7992 2017-04-27  NIIBE Yutaka  <gniibe@fsij.org>
7993
7994         g10: For signing, prefer available card key when no -u option.
7995         + commit 97a2394ecafaa6f58e4a1f70ecfd04408dc15606
7996         * g10/skclist.c (build_sk_list): Ask gpg-agent if card is available.
7997         Then, use the card key if any.
7998
7999 2017-04-26  NIIBE Yutaka  <gniibe@fsij.org>
8000
8001         g10: Minor clean up.
8002         + commit 2262a80c5f44433a08bc0e21b77d9efe51596f21
8003         * g10/main.h (complete_sig): Remove declaration.
8004         * g10/sign.c (complete_sig): Make it static.
8005
8006 2017-04-25  NIIBE Yutaka  <gniibe@fsij.org>
8007             Tomas Mraz
8008
8009         dirmngr: Fix aliasing problem in dns.c.
8010         + commit 247932f367f856e7ce91528e14f0aaf838150857
8011         * dirmngr/dns.c (dns_ai_setent): Care about aliasing.
8012
8013 2017-04-25  NIIBE Yutaka  <gniibe@fsij.org>
8014
8015         tests: Remove *.conf.tmpl from Makefile.
8016         + commit 7851d73fd7f424f9a649690e1cb3055feb792c51
8017         * tests/openpgp/Makefile.am (TEST_FILES): Remove gpg.conf.tmpl
8018         and gpg-agent.conf.tmpl.
8019
8020         g10: invalidate the fd cache for keyring.
8021         + commit 116cfd60779fbb3540da629db54dc2e148f4a3a2
8022         * g10/keyring.c (keyring_search_reset): Don't keep the FD cache.
8023
8024 2017-04-24  Andre Heinecke  <aheinecke@intevation.de>
8025
8026         w32: Enable wildcard expansion with mingw-w64.
8027         + commit 2e71bf30f038ca0e142acbb6f650ce029105f8a2
8028         * g10/gpg.c: Define _dowildcard = -1;
8029
8030 2017-04-24  Justus Winter  <justus@g10code.com>
8031
8032         tests: Fix Python detection.
8033         + commit ef1922b3b19df0aa7f8c15d503c603f76fc13f82
8034         * tests/gpgme/gpgme-defs.scm (python): Fix Python detection.
8035
8036         gpgscm: Refactor cell finalization.
8037         + commit d2f6798621d751cd6ae6f091c4a2af4569c5b8aa
8038         * tests/gpgscm/scheme.c (finalize_cell): Use switch, return whether
8039         the cell may be freed.
8040         (gc): Update callsite.
8041
8042         gpgscm: Tweak error message display.
8043         + commit 78547bfe8a885579438a17abadca02b62cce2844
8044         * tests/gpgscm/init.scm (throw'): If the first argument to the error
8045         is a string, display it as such.
8046
8047         tests: Deduplicate and simplify code.
8048         + commit 06a177ceea529269a7404740c60416bd6a4567b1
8049         * tests/gpgme/gpgme-defs.scm (create-file): Move...
8050         * tests/gpgsm/gpgsm-defs.scm (create-file): ... likewise...
8051         * tests/openpgp/defs.scm (create-file): Here.
8052         (create-gpghome): Use 'create-file'.
8053         * tests/openpgp/gpg-agent.conf.tmpl: Delete file.
8054         * tests/openpgp/gpg.conf.tmpl: Likewise.
8055
8056         gpgscm: Fix test.
8057         + commit 9ae63b9caefdf3e925c5928667fcd9227132d27f
8058         * tests/gpgscm/t-child.scm: Use 'string-length' on the string.
8059
8060         gpgscm: Improve syntax checking.
8061         + commit 4aab0e6ac7f2887a6f38f0cb95365dd7c30b4b18
8062         * tests/gpgscm/scheme.c (opexe_0): Make sure closure arguments are
8063         symbols.
8064
8065         gpgscm: Emit JUnit-style XML reports.
8066         + commit ee715201ae784e840b6136393289e6dbd6f4c540
8067         * tests/gpgscm/Makefile.am (EXTRA_DIST): Add new file.
8068         * tests/gpgscm/lib.scm (string-translate): New function.
8069         * tests/gpgscm/main.c (main): Load new file.
8070         * tests/gpgscm/tests.scm (dirname): New function.
8071         (test-pool): Record execution times, emit XML report.
8072         (test): Record execution times, record log file name, emit XML report.
8073         (run-tests-parallel): Write XML report.
8074         (run-tests-sequential): Likewise.
8075         * tests/gpgscm/xml.scm: New file.
8076         * tests/gpgme/Makefile.am (CLEANFILES): Add 'report.xml'.
8077         * tests/gpgsm/Makefile.am: Likewise.
8078         * tests/migrations/Makefile.am: Likewise.
8079         * tests/openpgp/Makefile.am: Likewise.
8080
8081         gpgscm: Make logging less verbose and more useful.
8082         + commit 679920781a25ae5c0e49d4bd78e6926fd661778f
8083         * tests/gpgscm/tests.scm (call-with-io): When being verbose, include
8084         the pid in the output, and avoid duplicating the command arguments.
8085
8086         gpgscm: Make test framework less functional.
8087         + commit a71f4142e13e2cc26ef0cd62f56a1ccb7ce678ee
8088         * tests/gpgscm/tests.scm (test-pool, tests): Previously, these methods
8089         updated objects by creating new updated copies of the object being
8090         manipulated.  This made the code awkward without any benefit,
8091         therefore I change it to just update the object.
8092
8093         gpgscm: Move 'trace' and 'stringify'.
8094         + commit f03d6897be904da58cad76b4bd07729922b47616
8095         * tests/gpgscm/tests.scm (trace, stringify): Move...
8096         * tests/gpgscm/lib.scm: ... here.
8097
8098         gpgscm: Avoid fruitless garbage collection cycles.
8099         + commit 245860ecaf8b9e82ca577385abd453ac92ffcd26
8100         * tests/gpgscm/scheme-private.h (CELL_MINRECOVER): New macro.
8101         * tests/gpgscm/scheme.c (_get_cell): Move the heuristic to get more
8102         cells...
8103         (gc): ... here where every caller benefits from the optimization.
8104
8105 2017-04-20  NIIBE Yutaka  <gniibe@fsij.org>
8106
8107         g13: Fix for Solaris.
8108         + commit 10519270d36586c536bfb6c4cda8ac17c01f4976
8109         * configure.ac: Check sys/mkdev.h.
8110         * g13/sh-dmcrypt.c: Include sys/mkdev.h.
8111
8112 2017-04-18  NIIBE Yutaka  <gniibe@fsij.org>
8113
8114         dirmngr: Fix final close of LISTEN_FD.
8115         + commit 4b2581dc0ea1d03e70023bb0748aa0c21c0a2173
8116         * dirmngr/dirmngr.c (handle_connections): Close LISTEN_FD.
8117
8118         dirmngr: Fix API difference for Windows.
8119         + commit 0d0a7efa8fa0accc1da851917376e2328ef33c96
8120         * dirmngr/http.c (read_server, write_server): Use assuan_fd_t.
8121         (http_wait_response): Use FD2INT to get unsigned integer fd.
8122         (read_server, write_server): Likewise.
8123         (simple_cookie_read, simple_cookie_write): Use assuan_fd_t.
8124
8125 2017-04-17  NIIBE Yutaka  <gniibe@fsij.org>
8126
8127         agent: More minor change.
8128         + commit 9296aed4bd2ad09d23339e658264e557c5312585
8129         * agent/command.c (cmd_pksign): Remove redundant assignment.
8130
8131         agent: Minor cleanup.
8132         + commit 45c52cca1401b930878a8f901b63cfbb22e9e327
8133         * agent/command-ssh.c (ssh_key_to_protected_buffer): Not touch ERR.
8134         * agent/command.c (cmd_genkey, cmd_import_key): Clean up.
8135
8136         tests: Minor memory fix.
8137         + commit b9440aa3693a4bb91e1ba8ff09e2d93ff22dd70a
8138         * tests/openpgp/fake-pinentry.c (get_passphrase): Free the memory.
8139
8140         g10: Fix parse_ring_trust.
8141         + commit 256e861bce3dc9aba8fab4df47a40cae3bede175
8142         * g10/parse-packet.c (parse_ring_trust): Fix condition.
8143
8144         g10: Minor fixes.
8145         + commit 0dec0cc281dfa26db89f8cc5ee002dea5c2b2e81
8146         * g10/export.c (cleartext_secret_key_to_openpgp): No initialization.
8147         (do_export_one_keyblock): Initialize with GPG_ERR_NOT_FOUND.
8148         * g10/getkey.c (get_best_pubkey_byname): Add non-null check.
8149         * g10/tofu.c (tofu_set_policy): ERR initialize to 0.
8150
8151         g10: Fix import/export filter property match.
8152         + commit af5f8ecf51f5e1f33e832d4946d02313b78a0536
8153         * g10/import.c (impex_filter_getval): Fix to "else if".
8154
8155 2017-04-14  NIIBE Yutaka  <gniibe@fsij.org>
8156
8157         agent: Clean up error initialize/return.
8158         + commit 36c4e540f1a4992675ee6e0acca1231325457079
8159         * agent/call-pinentry.c (start_pinentry): Return RC.
8160         * agent/command-ssh.c (ssh_handler_request_identities): Don't set ERR.
8161         * agent/findkey.c (try_unprotect_cb): Return ERR.
8162         (unprotect): Don't set RC.
8163         * agent/gpg-agent.c (handle_connections): Don't set fd.
8164
8165         dirmngr: More fix for test program.
8166         + commit adb77d095b3958482863a17c83746f33945638dc
8167         * dirmngr/t-http.c (main): Care about no TLS.
8168
8169         dirmngr: More fix for Windows.
8170         + commit 4771bad610eb59e701fe8e53468e2af22d45eeb0
8171         * dirmngr/http.c (simple_cookie_read, simple_cookie_write): Only
8172         valid with HTTP_USE_NTBTLS.
8173         (_my_socket_new): Simply cast to int since it's for debug.
8174         (_my_socket_ref, _my_socket_unref): Likewise.
8175
8176 2017-04-13  NIIBE Yutaka  <gniibe@fsij.org>
8177
8178         dirmngr: Fix http.c for sockaddr_storage.
8179         + commit 86dcb03134fd4957d51ebaa06b7991239f9ee56a
8180         dirmngr/http.c (use_socks): Use sockaddr_storage.
8181         (my_sock_new_for_addr, connect_server): Likewise.
8182
8183         dirmngr: Fix alignment of ADDR.
8184         + commit 892b33bb2c57785927ea6652091191da2deed464
8185         * dirmngr/dns-stuff.h (dns_addrinfo_s): Use struct sockaddr_storage
8186         for size and alignment.
8187         * dirmngr/dns-stuff.c (resolve_name_libdns): Follow the change.
8188         (resolve_dns_name): Use struct sockaddr_storage.
8189         (resolve_addr_standard, resolve_dns_addr): Likewise.
8190         (resolve_dns_addr): Likewise.
8191
8192         dirmngr: Fix thread key type.
8193         + commit 37018adce6ea4920b34d59afcfe4f55f716b3086
8194         * dirmngr/dirmngr.c (my_tlskey_current_fd): Use npth_key_t.
8195
8196         common, g10: Fix enumeration types.
8197         + commit 74258278efacd7069e8c1df8ff6fc3f4675d713e
8198         * common/openpgpdefs.h (CIPHER_ALGO_PRIVATE10, PUBKEY_ALGO_PRIVATE10)
8199         (DIGEST_ALGO_PRIVATE10, COMPRESS_ALGO_PRIVATE10): New.
8200         * g10/misc.c (map_pk_gcry_to_openpgp): Add type conversion.
8201         (map_cipher_openpgp_to_gcry, openpgp_cipher_algo_name)
8202         (openpgp_pk_test_algo2, map_md_openpgp_to_gcry)
8203         (pubkey_get_npkey): Add default handling.
8204
8205         dirmngr: More fix for Windows.
8206         + commit 5af104b541ed430a54eb0163a1d29e1d043f9377
8207         * dirmngr/dns.c (socket_fd_t, STDCALL): New.
8208         (dns_te_initname): Use.
8209
8210 2017-04-12  NIIBE Yutaka  <gniibe@fsij.org>
8211
8212         dirmngr: Fix type of sock.
8213         + commit 6755b3b505f79a5a233b18e85f57a0d3a455e664
8214         * dirmngr/http.c (send_request): Use assuan_fd_t for SOCK.
8215
8216         tools: Fix condition for gpg-connect-agent.
8217         + commit f52f6af834cc488d11612e349e4af023d69a45f4
8218         * tools/gpg-connect-agent.c (start_agent): Add paren.
8219
8220         dirmngr: Fix possible null reference.
8221         + commit 7ae1857c90ab43ad9e31f0fb6dbd37f25cc37278
8222         * dirmngr/dns.c (dns_error_t dns_trace_fput): Check NULL.
8223
8224         common: Simplify format_text.
8225         + commit 7b4edf14bb16fbe786e55b829a208960396ce8df
8226         * common/stringhelp.c (format_text): Don't allow IN_PLACE formatting.
8227         * common/stringhelp.h: Change the API with no IN_PLACE.
8228         * common/t-stringhelp.c (test_format_text): Follow the change.
8229         * g10/gpgcompose.c (show_help): Likewise.
8230         * g10/tofu.c (format_conflict_msg_part1, ask_about_binding)
8231         (show_statistics, show_warning): Likewise.
8232
8233         gpgscm: Fix test program.
8234         + commit 7f9032d4a8ce53ce1a972bd3c1f8d20b3776756b
8235         * tests/gpgscm/t-child.c (main): Fix for setmode.
8236
8237         dirmngr: Fix plus1_ns.
8238         + commit 60d9a9e6b4ae3af029596d14732c02f49203326d
8239         * dirmngr/dns.c (plus1_ns): Fix the initial implementation.
8240
8241         scd: Handle unexpected suspend/resume by CCID driver.
8242         + commit f053f99ed0b0c6de7b7c4a07cbd7f7d213ddf0db
8243         * scd/ccid-driver.c (bulk_in): Handle unexpected failure.
8244
8245         dirmngr: Fix dns-stuff.c in another way.
8246         + commit bd0c94939faf8ccfc117fb595e9bc0105edcafa4
8247         * dirmngr/dns-stuff.c (T_CERT): Define our own.
8248
8249         Revert "dirmngr: Fix dns-stuff.c."
8250         + commit 0b904ddea8bddaa2fd7893a9dce1df1cb5e36b00
8251         This reverts commit 1538523156be568046f632d1775eae30ea8bd556.
8252
8253         dirmngr: Fix dns-stuff.c.
8254         + commit 1538523156be568046f632d1775eae30ea8bd556
8255         * dirmngr/dns-stuff.c: Don't include arpa/nameser.h.
8256
8257         agent: Simplify stream_read_cstring.
8258         + commit c64763c3a74ecc61c2f6c5edb679a2a3879d79e7
8259         * agent/command-ssh.c (stream_read_cstring): Just call
8260         stream_read_string.
8261
8262         dirmngr: Use a function to increment network short.
8263         + commit 64904ce627b6b0661acf15b5b70103c4842bb0f3
8264         * dirmngr/dns.c (plus1_ns): New.
8265         (dns_p_push): Use it.
8266
8267         g10: Minor clean up for export.c.
8268         + commit 05218829589f6d4b09933fa19f568c2019367d5c
8269         * g10/export.c (export_ssh_key): Check IDENTIFIER for error.
8270         Release base64 thing on error of get_membuf.
8271
8272 2017-04-11  NIIBE Yutaka  <gniibe@fsij.org>
8273
8274         g13: Include sys/sysmacros.h if available.
8275         + commit c3cc9551dcc89cc25c0a0ec16d8eb12c1c221638
8276         * configure.ac: Add test for sys/sysmacros.h.
8277         * g13/sh-dmcrypt.c: Include sys/sysmacros.h.
8278
8279 2017-04-11  Justus Winter  <justus@g10code.com>
8280
8281         tests: Fix distcheck.
8282         + commit 00be2a92625e832e8dd621f2a8f72b124c6d50ca
8283         * tests/gpgscm/Makefile.am (EXTRA_DIST): Add 'gnupg.scm'.
8284
8285         tests: Avoid relying on implicit gpg commands.
8286         + commit cde626e7f7349a73d58ec3236ab3b43dec852bb5
8287         * tests/openpgp/armdetach.scm: Always use an explicit command instead
8288         of relying on gpg to guess what we want.
8289         * tests/openpgp/armdetachm.scm: Likewise.
8290         * tests/openpgp/armencrypt.scm: Likewise.
8291         * tests/openpgp/armencryptp.scm: Likewise.
8292         * tests/openpgp/armor.scm: Likewise.
8293         * tests/openpgp/armsignencrypt.scm: Likewise.
8294         * tests/openpgp/armsigs.scm: Likewise.
8295         * tests/openpgp/clearsig.scm: Likewise.
8296         * tests/openpgp/compression.scm: Likewise.
8297         * tests/openpgp/conventional-mdc.scm: Likewise.
8298         * tests/openpgp/conventional.scm: Likewise.
8299         * tests/openpgp/decrypt-dsa.scm: Likewise.
8300         * tests/openpgp/decrypt.scm: Likewise.
8301         * tests/openpgp/detach.scm: Likewise.
8302         * tests/openpgp/detachm.scm: Likewise.
8303         * tests/openpgp/ecc.scm: Likewise.
8304         * tests/openpgp/encrypt-dsa.scm: Likewise.
8305         * tests/openpgp/encrypt-multifile.scm: Likewise.
8306         * tests/openpgp/encrypt.scm: Likewise.
8307         * tests/openpgp/encryptp.scm: Likewise.
8308         * tests/openpgp/seat.scm: Likewise.
8309         * tests/openpgp/signencrypt-dsa.scm: Likewise.
8310         * tests/openpgp/signencrypt.scm: Likewise.
8311         * tests/openpgp/sigs-dsa.scm: Likewise.
8312         * tests/openpgp/sigs.scm: Likewise.
8313
8314         tests: Make tests more robust.
8315         + commit 1b28d9dbe0260b2a4645c4b5caae11d9f375c942
8316         * tests/openpgp/defs.scm (have-opt-always-trust): Execute in empty
8317         ephemeral home directory.  This prevents gpg from picking up the
8318         configuration from the current gnupghome (if any).
8319         * tests/migrations/common.scm (untar-armored): Likewise.
8320
8321         tests: Move common functionality.
8322         + commit ccd2187212c12b84c86a10fd4417a16536243179
8323         * tests/openpgp/defs.scm (with-home-directory,
8324         with-ephemeral-home-directory): Move...
8325         * tests/gpgscm/gnupg.scm: ... to this new file.
8326         * tests/gpgscm/main.c (main): Load the new file.
8327
8328 2017-04-11  NIIBE Yutaka  <gniibe@fsij.org>
8329
8330         dirmngr: Fix build for Windows.
8331         + commit 3133402241167ccad70fa888a47ffcbe04e7b4c5
8332         * dirmngr/ldap-wrapper-ce.c (outstream_cookie_writer): Use
8333         gpgrt_ssize_t.
8334
8335         g10,tools: Fix bzlib.h include order.
8336         + commit 03d77b60befa4e2f8437a80ac429cca3e54688f8
8337         * g10/compress-bz2.c: Include bzlib.h after gcrypt.h.
8338         * tools/gpgsplit.c: Likewise.
8339
8340         g10: Minor clean up for TOFU.
8341         + commit f079822b2ce06c18b7ea45efed2d29b54e38f04d
8342         * g10/tofu.c (ask_about_binding): Fix for qualifier.
8343
8344         common: Portability fix for logging.c.
8345         + commit 456c5cdb2d72bba77e2a30c8fdb1c1cebbe9b1d2
8346         * common/logging.c (S_IRGRP, S_IWGRP, S_IROTH, S_IWOTH): Avoid
8347         duplicated definition.
8348
8349         tools: Portability fix for gpgparsemail.
8350         + commit a1446163d584cdc3003c7d5b5fc6d74737c1732d
8351         * tools/rfc822parse.c (my_stpcpy): Rename from stpcpy.
8352
8353 2017-04-10  Justus Winter  <justus@g10code.com>
8354
8355         gpgscm: Fix opcode dispatch.
8356         + commit 1b6adab41d386b587f65e5c6f14a63859ac1226b
8357         * tests/gpgscm/scheme.c (opexe_0): Consider 'op', not 'sc->op'.  The
8358         former is the opcode we are currently executing.
8359
8360         gpgscm: Mmap script files.
8361         + commit c7f0d90592fd0348a3818ac897f91e6859584146
8362         * tests/gpgscm/main.c (load): Try to mmap the script.
8363         * tests/gpgscm/scheme.c (scheme_load_memory): New function, a
8364         generalization of 'scheme_load_string'.
8365         * tests/gpgscm/scheme.h (scheme_load_memory): New prototype.
8366
8367         gpgscm: Refactor checking for opcode arguments.
8368         + commit f3d1f6867792deeb9a2a63744ee9b076c41c58f3
8369         * tests/gpgscm/scheme.c (op_code_info): Fix type, add forward
8370         declaration.
8371         (check_arguments): New function.
8372         (Eval_cycle): Use the new function.
8373
8374         gpgscm: Improve syntax dispatch.
8375         + commit b628e62b5b9f7ed5cbb1bfe34727b5ee8129f7d4
8376         * tests/gpgscm/scheme.c (assign_syntax): Add opcode parameter, store
8377         opcode in the tag.
8378         (syntaxnum): Add sc parameter, retrieve opcode from tag.
8379         (opexe_0): Adapt callsite.
8380         (scheme_init_custom_alloc): Likewise.
8381
8382         gpgscm: Make tags mandatory.
8383         + commit a1ad5d6a30cf72d9b7e7bb449985dc69d5e01c4b
8384         * tests/gpgscm/opdefines.h: Make tags mandatory.
8385         * tests/gpgscm/scheme.c: Likewise.
8386         * tests/gpgscm/scheme.h: Likewise.
8387
8388         gpgscm: Add and use opcode for reversing a list in place.
8389         + commit e1bb9326dc381ae2711a81ab621e21a66388bcbd
8390         * tests/gpgscm/lib.scm (string-split-pln): Use 'reverse!'.
8391         (string-rtrim): Likewise.
8392         * tests/gpgscm/opdefines.h (reverse!): New opcode.
8393         * tests/gpgscm/scheme.c (opexe_0): Handle new opcode.
8394
8395         gpgscm: Deduplicate code.
8396         + commit 3e91019a92b9bb3bb5a8cd62336b4cf65964e45b
8397         * tests/gpgscm/scheme.c (oblist_add_by_name): Deduplicate.
8398         (new_slot_spec_in_env): Likewise.
8399
8400         gpgscm: Move dispatch table into rodata.
8401         + commit 7dff6248bddd5583988ac562318cf0d76a409d0e
8402         * tests/gpgscm/opdefines.h: Use 0 instead of NULL.
8403         * tests/gpgscm/scheme.c (op_code_info): Use char arrays instead of
8404         pointers, make arity parameters smaller.
8405         (INF_ARG): Adapt.
8406         (_OP_DEF): Likewise.
8407         (dispatch_table): Likewise.
8408         (procname): Likewise.
8409         (Eval_cycle): Likewise.
8410         (scheme_init_custom_alloc): Likewise.
8411
8412         gpgscm: Use more threaded code.
8413         + commit 6f217d116d1a12c6093bb253dbfa349bc81bc90b
8414         * tests/gpgscm/scheme.c (opexe_0): Use 's_thread_to' instead of
8415         's_goto' wherever possible.
8416
8417         gpgscm: Remove now obsolete dispatcher function from the opcodes.
8418         + commit e7ed9822e20ee4bbb4cdd9eca8121b4ade87e5ce
8419         * tests/gpgscm/opdefines.h: Remove now obsolete dispatcher function
8420         from the opcodes.
8421         * tests/gpgscm/scheme-private.h (_OP_DEF): Adapt.
8422         * tests/gpgscm/scheme.c (dispatch_func): Remove type declaration.
8423         (op_code_info): Remove 'func'.
8424         (_OP_DEF): Adapt.
8425         (Eval_Cycle): Always call 'opexe_0'.
8426
8427         gpgscm: Merge 'opexe_6'.
8428         + commit ddf444828b9b3f75d964473a2c0e77f75f094cf4
8429         * tests/gpgscm/scheme.c (opexe_6): Merge into 'opexe_0'.
8430         * tests/gpgscm/opdefines.h: Adapt.
8431
8432         gpgscm: Merge 'opexe_5'.
8433         + commit 1379df44537b67b7c2fbc0fb5bc6f7945a5d7ebb
8434         * tests/gpgscm/scheme.c (opexe_5): Merge into 'opexe_0'.
8435         * tests/gpgscm/opdefines.h: Adapt.
8436
8437         gpgscm: Merge 'opexe_4'.
8438         + commit 4f835104b9475e7d585d859b85e7d0d4cfe9aab3
8439         * tests/gpgscm/scheme.c (opexe_4): Merge into 'opexe_0'.
8440         * tests/gpgscm/opdefines.h: Adapt.
8441
8442         gpgscm: Merge 'opexe_3'.
8443         + commit d591ab65d37ee467ca91ad851ab236f2985c1ee2
8444         * tests/gpgscm/scheme.c (opexe_3): Merge into 'opexe_0'.
8445         * tests/gpgscm/opdefines.h: Adapt.
8446
8447         gpgscm: Merge 'opexe_2'.
8448         + commit 6cad38228f6ebfdc8e52960223b492597aff26a0
8449         * tests/gpgscm/scheme.c (opexe_2): Merge into 'opexe_0'.
8450         * tests/gpgscm/opdefines.h: Adapt.
8451
8452         gpgscm: Merge 'opexe_1'.
8453         + commit 154af876f05b773bf3a860fcb4cc41066da27beb
8454         * tests/gpgscm/scheme.c (opexe_1): Merge into 'opexe_0'.
8455         * tests/gpgscm/opdefines.h: Adapt.
8456
8457 2017-04-10  NIIBE Yutaka  <gniibe@fsij.org>
8458
8459         agent: Use "ll" length specifier when time_t is larger.
8460         + commit 170660ed11b56145dea4865e751ae5aff1681fe2
8461         * agent/command.c (cmd_keytocard): Use KEYTOCARD_TIMESTAMP_FORMAT.
8462
8463         scd: Relax a condition for p15 driver.
8464         + commit 7501f2e9c4e6fd94a191b381d52ec2fe1d103e29
8465         * scd/app-p15.c (read_ef_aodf): Fix.
8466
8467         scd: Relax a condition for p15 driver.
8468         + commit 3c1ad96f1ce838daf2d861b33e6611f6d3043d25
8469         * scd/app-p15.c (read_ef_aodf): Remove possibly redundant condition.
8470
8471         scd: Remove "special transport" support.
8472         + commit 34199ef677bb40eadf0da696a111f7036bc3187e
8473         * scd/ccid-driver.c (transports, my_sleep, prepare_special_transport)
8474         (writen): Remove.
8475         (ccid_dev_scan, ccid_dev_scan_finish, ccid_get_BAI): Only for USB.
8476         (ccid_open_reader, do_close_reader, bulk_out, bulk_in, abort_cmd)
8477         (ccid_poll, ccid_transceive): Likewise.
8478
8479 2017-04-07  Justus Winter  <justus@g10code.com>
8480
8481         gpgscm: Allocate small integers in the rodata section.
8482         + commit 8640fa880d7050917f4729f2c0cb506e165ee446
8483         * tests/gpgscm/Makefile.am (gpgscm_SOURCES): Add new file.
8484         * tests/gpgscm/scheme-private.h (struct cell): Move number to the top
8485         of the union so that we can initialize it.
8486         (struct scheme): Remove 'integer_segment'.
8487         * tests/gpgscm/scheme.c (initialize_small_integers): Remove function.
8488         (small_integers): New variable.
8489         (MAX_SMALL_INTEGER): Compute.
8490         (mk_small_integer): Adapt.
8491         (mark): Avoid marking objects already marked.  This allows us to run
8492         the algorithm over objects in the rodata section if they are already
8493         marked.
8494         (scheme_init_custom_alloc): Remove initialization.
8495         (scheme_deinit): Remove deallocation.
8496         * tests/gpgscm/small-integers.h: New file.
8497
8498         gpgscm: Make global data constant when possible.
8499         + commit c9c3fe883271868d3b2dd287d295cf6a8f8ffc05
8500         * tests/gpgscm/scheme-private.h (struct scheme): Make 'vptr' const.
8501         * tests/gpgscm/scheme.c (num_zero): Statically initialize and turn
8502         into constant.
8503         (num_one): Likewise.
8504         (charnames): Change type so that it can be stored in rodata.
8505         (is_ascii_name): Adapt slightly.
8506         (assign_proc): Make argument const char *.
8507         (op_code_info): Make some fields const char *.
8508         (tests): Make const.
8509         (dispatch_table): Make const.  At least it can be made read-only after
8510         relocation.
8511         (Eval_Cycle): Adapt slightly.
8512         (vtbl): Make const.
8513
8514         gpgscm: Remove arbitrary limit on number of cell segments.
8515         + commit 56638c28adc1bbe9fc052b92549a50935c0fe99c
8516         * tests/gpgscm/scheme-private.h (struct scheme): Remove fixed-size
8517         arrays for cell segments, replace them with a pointer to the new
8518         'struct cell_segment' instead.
8519         * tests/gpgscm/scheme.c (struct cell_segment): New definition.
8520         (_alloc_cellseg): Allocate the header within the segment, return a
8521         pointer to the header.
8522         (_dealloc_cellseg): New function.
8523         (alloc_cellseg): Insert the segments into a list.
8524         (_get_cell): Allocate a new segment if less than a quarter of
8525         CELL_SIGSIZE is recovered during garbage collection.
8526         (initialize_small_integers): Adapt callsite.
8527         (gc): Walk the list of segments.
8528         (scheme_init_custom_alloc): Remove initialization of removed field.
8529         (scheme_deinit): Adapt deallocation.
8530
8531         gpgscm: Fix compact vector encoding.
8532         + commit bf8b5e9042b3d86d419b2ac1987a9298c9d21500
8533         * tests/gpgscm/scheme-private.h (struct cell): Use uintptr_t for
8534         '_flags'.  This way, '_flags' has the size of a machine word.
8535
8536 2017-04-07  Werner Koch  <wk@gnupg.org>
8537
8538         gpg: Fix printing of offline taken subkey.
8539         + commit 547bc01d57528ecc27b3b5e16797967a7f88fecf
8540         * g10/keylist.c (list_keyblock_print): Set SECRET to 2 and not 0x32.
8541
8542 2017-04-07  NIIBE Yutaka  <gniibe@fsij.org>
8543
8544         scd: Internal CCID reader cleanup.
8545         + commit cc420d34880e2a050b39f969873974cfc35fa5c3
8546         * scd/ccid-reader.c (scan_usb_device): Only for scan mode, so, rename
8547         from scan_or_find_usb_device.
8548         (scan_devices): Likewise.  Remove support of special transport types.
8549         (ccid_get_reader_list): Simplify.
8550         (abort_cmd): Fix error return.
8551         (send_escape_cmd): Fix for RESULTLEN == NULL.
8552         (ccid_transceive_secure): Remove unnecessary var updates.
8553
8554         scd: Don't keep CCID reader open when card is not available.
8555         + commit 3c93595d701c59cbc9b67a7fd0bcde7ee0fada1a
8556         * scd/apdu.c (open_ccid_reader): Fail if no ATR.
8557
8558         agent: Serialize access to passphrase cache.
8559         + commit ebe12be034f052cdec871f0d8ad1bfab85d7b943
8560         * agent/cache.c (encryption_lock): Remove.
8561         (cache_lock): New.  Now, we have coarse grain lock to serialize
8562         entire cache access.
8563         (initialize_module_cache): Use CACHE_LOCK.
8564         (init_encryption, new_data): Remove ENCRYPTION_LOCK.
8565         (agent_flush_cache, agent_put_cache, agent_get_cache): Lock the cache.
8566
8567 2017-04-06  Justus Winter  <justus@g10code.com>
8568
8569         gpgscm: Avoid mutating integer.
8570         + commit f1dc34f502a68673e7a29f3fcf57b8dc6a4fac89
8571         * tests/gpgscm/scheme.c (opexe_5): Do not modify the integer in-place
8572         while printing an vector.  Integer objects may be shared, so they must
8573         not be mutated.
8574
8575         gpgscm: Initialize unused slots in vectors.
8576         + commit b83903f59ec5d49ac579f263da70ebc8dc3645b5
8577         * tests/gpgscm/scheme.c (get_vector_object): Initialize unused slots
8578         at the end of vectors.
8579
8580         tests: Fix distcheck.
8581         + commit 23f00f109ddba595db4f73a6182750177c7dd75d
8582         * tests/Makefile.am (SUBDIRS): Add 'pkits' again.  Simply dropping it
8583         makes 'make distcheck' unhappy.
8584         * tests/pkits/Makefile.am (TESTS): Remove all tests.
8585
8586         tests: Disable 'pkits' test suite.
8587         + commit af1c1a57e46a00a32d83c1a58c5f3ef6f4a1c1d1
8588         * tests/Makefile.am (SUBDIRS): Drop 'pkits'.
8589         * tests/pkits/common.sh: Fix locating 'PKITS_data.tar.bz2'.
8590         * tests/pkits/inittests: Likewise.
8591
8592         tests: Make test more robust.
8593         + commit 94645311f8a3e9ae33643512f87fbef41bf0556f
8594         * tests/openpgp/4gb-packet.scm: Skip if we do not have BZIP2.
8595         * tests/openpgp/defs.scm (have-compression-algo?): New function.
8596
8597 2017-04-05  Justus Winter  <justus@g10code.com>
8598
8599         tests: Fix setup of ephemeral home directories.
8600         + commit 01e84d429aeeb1450012ff0576a6a24de50693c6
8601         * tests/openpgp/defs.scm (with-ephemeral-home-directory): Set
8602         GNUPGHOME and cwd to the ephemeral directory before calling the setup
8603         function.
8604
8605 2017-04-04  Justus Winter  <justus@g10code.com>
8606
8607         tests: Fix setup of ephemeral home directories.
8608         + commit 32b75fb7743f35936d7014fce33c90ba97dfa374
8609         * tests/openpgp/defs.scm (with-ephemeral-home-directory): Create
8610         configuration files when we enter the context.
8611         * tests/openpgp/setup.scm: Do not use an ephemeral home directory.
8612         Tests should always use the cwd.
8613         * tests/gpgsm/setup.scm: Likewise.
8614         * tests/gpgsm/export.scm: Add explicit constructor function.
8615         * tests/openpgp/decrypt-session-key.scm: Likewise.
8616         * tests/openpgp/decrypt-unwrap-verify.scm: Likewise.
8617
8618         gpgscm: Fix copying values.
8619         + commit 6261611d3786f19fd84ccc79f45a89cadac518e8
8620         * tests/gpgscm/scheme.c (copy_value): New function.
8621         (mk_tagged_value): Use new function.
8622         (opexe_4): Likewise for OP_SAVE_FORCED.
8623
8624         gpgscm: Simplify get-output-string operation.
8625         + commit a80d4a9b50ad47eae1f8c740dd73804311e38783
8626         * tests/gpgscm/scheme.c (opexe_4): Simplify 'get-output-string'.
8627
8628         gpgscm: Simplify substring operation.
8629         + commit d858096c99705ccf2e115475f81c4cf88edbeebf
8630         * tests/gpgscm/scheme.c (opexe_2): Simplify 'substring'.
8631
8632 2017-04-04  NIIBE Yutaka  <gniibe@fsij.org>
8633
8634         agent: Minor fix for get_client_pid.
8635         + commit 5744d2038bd17b8b1be4e73d0ad3bc41772efe96
8636         * agent/command-ssh.c (get_client_pid): Use 0 to initialize.
8637
8638 2017-04-03  Werner Koch  <wk@gnupg.org>
8639
8640         Release 2.1.20.
8641         + commit e7eb9b12deaf7ebe26967bfb56e980b7efeebdc3
8642
8643
8644         dirmngr: New option --disable-ipv6.
8645         + commit 3533b854408fa93734742b2ee12b62aa0d55ff28
8646         * dirmngr/dirmngr.h (struct opt): Add field 'disable_ipv6'.
8647         * dirmngr/dirmngr.c (oDisableIPv6): New const.
8648         (opts): New option --disable-ipv6.
8649         (parse_rereadable_options): Set that option.
8650         * dirmngr/dns-stuff.c (opt_disable_ipv6): New var.
8651         (set_dns_disable_ipv6): New.
8652         (resolve_name_standard): Make use of it.
8653         * dirmngr/ks-engine-finger.c (ks_finger_fetch): Take care of
8654         OPT.DISABLE_IPV6.
8655         * dirmngr/ks-engine-hkp.c (map_host): Ditto.
8656         (send_request): Ditto.
8657         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
8658         * dirmngr/ocsp.c (do_ocsp_request): Ditto.
8659
8660         dirmngr,w32: Silence the 'certificate already cached' message.
8661         + commit fce36d7ec87be14b874813db277781c87a64ea87
8662         * dirmngr/certcache.c (load_certs_from_w32_store): Silenece an info
8663         message.
8664
8665         dirmngr: Handle EIO which is sometimes returned by cookie functions.
8666         + commit cc32ddbcba8c53d3e2cad952d72f62dc73911042
8667         * dirmngr/ks-engine-hkp.c (handle_send_request_error): Handle EIO.
8668
8669         dirmngr: Always print a warning for a missing /etc/hosts.
8670         + commit 35c843c815306f36d1efbc52f5e2f6bac3f67aec
8671         * dirmngr/dns-stuff.c (libdns_init): No Windows specific handling of a
8672         missing /etc/hosts.
8673
8674         dirmngr: Do not assume that /etc/hosts exists.
8675         + commit 5d873f288e86edfb684f4dd57ac36466b06494a4
8676         * dirmngr/dns-stuff.c (libdns_init): Do not bail out.
8677
8678         po: Update the German translation.
8679         + commit c7be01dae914c183dd99bd531a388c794d858c61
8680
8681
8682         gpgconf: Add --enable-extended-key-format for the agent.
8683         + commit d23052b04ebb0ac731aa351650c4084f080c640b
8684         * tools/gpgconf-conf.c: Add option.
8685         * agent/gpg-agent.c (main) <aGPGConfList>: Add option.
8686
8687 2017-04-03  Justus Winter  <justus@g10code.com>
8688
8689         gpgscm: Slightly improve the procedure dispatch.
8690         + commit 90932bdad607d06f4f040e3457caddba79ba8b7e
8691         * tests/gpgscm/scheme.c (procnum): Procedures always have an integer
8692         number, so we can safely use the cheaper 'ivalue_unchecked'.
8693
8694 2017-04-03  Werner Koch  <wk@gnupg.org>
8695
8696         gpg: Handle critical marked 'Reason for Revocation'.
8697         + commit 3f6d949011f485613bb4bd3e06a2643be79cce40
8698         * g10/parse-packet.c (can_handle_critical): Add
8699         SIGSUBPKT_REVOC_REASON.
8700
8701 2017-04-02  Werner Koch  <wk@gnupg.org>
8702
8703         agent: Use OCB for key protection with --enable-extended-key-format.
8704         + commit d24375271b97e45deaeb1ef0a8434c64066ba2e8
8705         * agent/protect.c (PROT_DEFAULT_TO_OCB): Remove macro.
8706         (agent_protect): Make the default protection mode depend on the extend
8707         key format option.
8708
8709 2017-04-01  Werner Koch  <wk@gnupg.org>
8710
8711         kbx: Unify blob reading functions.
8712         + commit 0039d7107bcdfce6f3b02b46ff0495cfba07882a
8713         * kbx/keybox-file.c (_keybox_read_blob): Remove.
8714         (_keybox_read_blob2): Rename to ....
8715         (_keybox_read_blob): this.  Make arg options.  Change all callers.
8716         * kbx/keybox-search.c (keybox_search): Factor fopen call out to ...
8717         (open_file): new.
8718         (keybox_seek): Als use open_file.
8719
8720 2017-03-31  Werner Koch  <wk@gnupg.org>
8721
8722         gpg: Avoid multiple open calls to the keybox file.
8723         + commit 5556eca5acd46983bff0b38a1ffbc2f07fbaba9f
8724         * g10/keydb.h (KEYDB_HANDLE): Move typedef to ...
8725         * g10/gpg.h: here.
8726         (struct server_control_s): Add field 'cached_getkey_kdb'.
8727         * g10/gpg.c (gpg_deinit_default_ctrl): Release that keydb handle.
8728         * g10/getkey.c (getkey_end): Cache keydb handle.
8729         (get_pubkey): Use cached keydb handle.
8730         * kbx/keybox-search.c (keybox_search_reset): Use lseek instead of
8731         closing the file.
8732
8733         gpg: Pass CTRL also to getkey_end.
8734         + commit aca5f494a88776d4974bfa9b0b65cb60c1b42040
8735         * g10/getkey.c (getkey_end): Add arg CTRL.  Change all callers.
8736
8737         gpg: Print more stats for the keydb and the signature cache.
8738         + commit 3a10de3bfd785aefb0150e82b6dbbc7cb9f208c8
8739         * g10/sig-check.c (sig_check_dump_stats): New.
8740         (cache_stats): New struct.
8741         (check_key_signature2): Update stats.
8742         * g10/gpg.c (g10_exit): Call new function.
8743         * g10/keydb.c (kid_not_found_cache_count): Replace by ...
8744         (kid_not_found_stats): ... new struct.  Change users.
8745         (keydb_stats): New struct.  Update the counters.
8746         (keydb_dump_stats): Print all stats.
8747
8748         gpg: Assert that an opaque parameter is really what we expect.
8749         + commit 52ba5e67cad4311d0ddbc4f2979e20afd0161d1f
8750         * g10/gpg.h (SERVER_CONTROL_MAGIC): New const.
8751         (server_control_s): Add field 'magic'.
8752         * g10/gpg.c (gpg_init_default_ctrl): Init MAGIC.
8753         * g10/import.c (impex_filter_getval): Assert MAGIC.
8754
8755 2017-03-30  Justus Winter  <justus@g10code.com>
8756
8757         gpg: Consistent use of preprocessor conditionals.
8758         + commit 5e89144cbca36c1e7eb814b3aad4b7c46cd4efbf
8759         * g10/parse-packet.c: Use '#if' instead of '#ifdef' when checking
8760         DEBUG_PARSE_PACKET.  This fixes the build with '#define
8761         DEBUG_PARSE_PACKET 0'.
8762
8763         common: Avoid undefined behavior.
8764         + commit 214fa9012296d796b78f1a3106d656639cf50aef
8765         * common/iobuf.c (iobuf_read_line): Do not consider 'length' if
8766         'buffer' is NULL.
8767
8768 2017-03-30  Werner Koch  <wk@gnupg.org>
8769
8770         gpg: Remove the use of the signature information from a KBX.
8771         + commit a6142dbdbc5783043deb847dc64998c421860941
8772         * g10/keydb.c (keyblock_cache): Remove field SIGSTATUS.
8773         (keyblock_cache_clear): Adjust for that removal.
8774         (parse_keyblock_image): Remove arg SIGSTATUS.  Remove the signature
8775         cache setting; this is now done in the parser.
8776         (keydb_get_keyblock): Do not set SIGSTATUS.
8777         (build_keyblock_image): Remove arg SIGSTATUS and simplify.  Change
8778         caller.
8779         * kbx/keybox-blob.c: Explain that the signature information is not
8780         anymore used.
8781         (_keybox_create_openpgp_blob): Remove arg SIGSTATUS and change
8782         callers.
8783         * kbx/keybox-search.c (keybox_get_keyblock): Remove arg R_SIGSTATUS
8784         and change callers.
8785         * kbx/keybox-update.c (keybox_insert_keyblock): Likewise.
8786
8787         gpg: Fix actual leak and possible leaks in the packet parser.
8788         + commit 7bf24e8146116a30c4c9d7b6dbf8bbb27fc35971
8789         * g10/packet.h (struct parse_packet_ctx_s): Change LAST_PKT deom a
8790         pointer to its struct.
8791         (init_parse_packet): Adjust for LAST_PKT not being a pointer.
8792         * g10/parse-packet.c (parse): Ditto. Free the last packet before
8793         storing a new one in case of a deep link.
8794         (parse_ring_trust): Adjust for LAST_PKT not being a pointer.
8795         * g10/free-packet.c (free_packet): Ditto.
8796         * g10/t-keydb-get-keyblock.c (do_test): Release keyblock.
8797
8798         gpg: Fix export porting of zero length user ID packets.
8799         + commit 64665404e43051fa50ee030766347e24b7d1e4d5
8800         * g10/build-packet.c (do_user_id): Avoid indeterminate length header.
8801
8802         gpg: Revamp reading and writing of ring trust packets.
8803         + commit a8895c99a7d0750132477d80cd66caaf3a709113
8804         * g10/parse-packet.c (parse_trust): Rename to ...
8805         (parse_ring_trust): this.  Change args and implement new ring trust
8806         packet format.
8807         (parse): Add special ring trust packet handling.
8808         * g10/packet.h (PKT_user_id): New fields KEYUPDATE, UPDATEURL, and
8809         KEYSRC.
8810         (PKT_public_key): Ditto.
8811         (RING_TRUST_SIG, RING_TRUST_KEY, RING_TRUST_UID): New consts.
8812         (PKT_ring_trust): New.
8813         (struct packet_struct): Remove member RING_TRUST.
8814         (strcu parse_packet_ctx_s): Add field SKIP_META.
8815         (init_parse_packet): Init SKIPT_META.
8816         * g10/free-packet.c (release_public_key_parts): Free UDPATEURL.
8817         (free_user_id): Ditto.
8818         * g10/mainproc.c (list_node): Remove printing of non-documented "rtv"
8819         lines.
8820         * g10/build-packet.c (build_packet_and_meta): New.
8821         (do_ring_trust): New.
8822         * g10/export.c (write_keyblock_to_output): Use build_packet_and_meta
8823         in backup mode.
8824         (do_export_one_keyblock): Ditto.
8825         * g10/import.c (read_block): Add arg WITH_META.  Skip ring trust
8826         packets if that ism not set.
8827         (import): Call read_block WITH_META in restore mode.
8828         * g10/keydb.h (KEYSRC_UNKNOWN, KEYSRC_FILE, KEYSRC_KS, KEYSRC_PREF_KS)
8829         (KEYSRC_WKD, KEYSRC_WKD_SD, KEYSRC_DANE): New constants.  They are not
8830         yet used, though.
8831         * g10/keydb.c (parse_keyblock_image): Allow ring trust packets.
8832         (build_keyblock_image): Ditto.  Use build_packet_and_meta.
8833         * g10/keyring.c (keyring_get_keyblock): Remove specila treatment of
8834         ring trust packets.
8835         (write_keyblock): Use build_packet_and_meta.  Remove special treatment
8836         of ring trust packets and initialization of the signature caches.
8837
8838 2017-03-29  Werner Koch  <wk@gnupg.org>
8839
8840         gpg: Extend free_packet to handle a packet parser context.
8841         + commit afa86809087909a8ba2f9356588bf90cc923529c
8842         * g10/packet.h (struct parse_packet_ctx_s): Add fields LAST_PKT and
8843         FREE_LAST_PKT.
8844         (init_parse_packet): Clear them.
8845         (deinit_parse_packet): New macro.  Change all users if
8846         init_parse_packet to also call this macro.
8847         * g10/free-packet.c (free_packet): Add arg PARSECTX and handle shallow
8848         packet copies in the context.  Change all callers.
8849         * g10/parse-packet.c (parse): Store certain packets in the parse
8850         context.
8851
8852         gpg: Change parse_packet to take a context.
8853         + commit 0526c99164d3531b5ec763ffc672407eb24b2296
8854         * g10/packet.h (struct parse_packet_ctx_s): New.
8855         (parse_packet_ctx_t): New type.
8856         (init_parse_packet): New macro.
8857         * g10/parse-packet.c (parse_packet, dbg_parse_packet): Change to take
8858         a parse context.  Change all callers to provide a context instead of
8859         directly supplying the input stream.
8860         (search_packet, dbg_search_packet): Ditto.
8861         (copy_all_packets, dbg_copy_all_packets): Init an use a parse context.
8862         (copy_some_packets, dbg_copy_some_packets): Ditto.
8863         (skip_some_packets, dbg_skip_some_packets): Ditto.
8864
8865         gpg: Export ring trust packets in backup mode.
8866         + commit f5b565a5b8de3f2a3d98bc1a655e18333aee223b
8867         * g10/export.c (write_keyblock_to_output): Export ring trust packets.
8868
8869 2017-03-28  Justus Winter  <justus@g10code.com>
8870
8871         tests,w32: Fix importing the extra key for GPGME's keylist test.
8872         + commit b20780658ebb1e1245db18c04db3e815399cf706
8873         * tests/gpgme/wrap.scm: Qualify the tests name with the extension for
8874         executables (if any).
8875
8876 2017-03-28  Werner Koch  <wk@gnupg.org>
8877
8878         gpg: Prepare for listing last_update and key origin data.
8879         + commit 4af389c9721fa534ed06a64b80705b631575c775
8880         * g10/keylist.c (list_keyblock_colon): Add empty fields 19 and 20.
8881
8882 2017-03-28  Justus Winter  <justus@g10code.com>
8883
8884         tests: Fix distcheck.
8885         + commit 5128cd74c029d57491a79ca9e918c81facdf1b76
8886         * tests/openpgp/Makefile.am (sample_msgs): Add all missing sample
8887         messages.
8888
8889         tests: Add test for '--decrypt --unwrap'.
8890         + commit 211d71f19c24da94f4c58014606125c1a29d86a2
8891         * tests/openpgp/Makefile.am (XTESTS): Add new test.
8892         * tests/openpgp/decrypt-unwrap-verify.scm: New file.
8893
8894         g10: Fix memory leak.
8895         + commit 6d3edfd972c1114f43f6b35773dc25e0256f48f4
8896         * g10/decrypt-data.c (decrypt_data): Free 'filename'.
8897
8898 2017-03-27  Justus Winter  <justus@g10code.com>
8899
8900         common: Fix connecting to the agent.
8901         + commit caf00915532e6e8e509738962964edcd14fb0654
8902         * common/homedir.c (_gnupg_socketdir_internal): Fix error handling.
8903
8904 2017-03-27  NIIBE Yutaka  <gniibe@fsij.org>
8905
8906         g10: Support specifying SERIALNO for --card-status.
8907         + commit c1e6302b347caf852a056b9c721469ccb51f44da
8908         * g10/gpg.c (main): Allow an argument for --card-status.
8909         * g10/card-util.c (current_card_status): Rename from card_status.
8910         (card_status): New, which supports multiple cards.
8911         (get_one_name): Use current_card_status.
8912
8913         scd: Change the order of applications when accessed.
8914         + commit d58275703f035e8cfd58cd1c2d0d5ac7dc59e110
8915         * scd/app.c (select_application): Move the app to top.
8916
8917         scd: Fix timeout handling for key generation.
8918         + commit 0848cfcce738150b53bfb65b78efc1e6dc9f3d26
8919         * scd/ccid-driver.c (CCID_CMD_TIMEOUT): Back to original value.
8920         (CCID_CMD_TIMEOUT_LONGER): New.
8921         (ccid_transceive): Add kludge for key generation.
8922
8923 2017-03-24  Werner Koch  <wk@gnupg.org>
8924
8925         gpg: Improve check for already compressed packets.
8926         + commit 0b3770c421a35b64823a805fa8d49ddd5c653d50
8927         * common/miscellaneous.c (is_openpgp_compressed_packet): New.
8928         (is_file_compressed): Rerad 2 more bytes and call new function.
8929
8930         agent: New option --enable-extended-key-format.
8931         + commit 2c237c13628a88ba23742da34ea18d3e205d7c53
8932         * agent/gpg-agent.c (oEnableExtendedKeyFormat): New const.
8933         (opts): New option --enable-extended-key-format.
8934         (parse_rereadable_options): Set option
8935         * agent/findkey.c (write_extended_private_key): Add arg 'update'.
8936         (agent_write_private_key): Implement new option.
8937
8938         agent: New option --stub-only for DELETE_KEY.
8939         + commit 6fab7bba879d7794e32112cf3eddd8d87130a5d7
8940         * agent/findkey.c (agent_delete_key): Add arg 'only_stubs'.
8941         * agent/command.c (cmd_delete_key): Add option --stub-only.
8942
8943 2017-03-23  Werner Koch  <wk@gnupg.org>
8944
8945         common: Implicitly do a gpgconf --create-socketdir.
8946         + commit 26086b362ff47d21b1abefaf674a6464bf0a8921
8947         * common/homedir.c (_gnupg_socketdir_internal): Create the
8948         sub-directory.
8949
8950         tests: Use gpgconf to stop the agent.
8951         + commit 2c9d9ac55ea455a5ec26428989dced0311ed46cc
8952         * tests/openpgp/defs.scm (stop-agent): Swap order of actions.  Kill
8953         all daemons using gpgconf.
8954         * tools/gpgconf.c (main) <aRemoveSocketDir>: Try to remove known
8955         socketfails on rmdir failure.  Do no fail for ENONET.
8956
8957 2017-03-23  Justus Winter  <justus@g10code.com>
8958
8959         gpgscm: Make test cleanup more robust.
8960         + commit 178b6314ab2d2268873067314744c8af74dc331e
8961         * tests/gpgscm/tests.scm (mkdtemp-autoremove): New function that
8962         cleans up at interpreter shutdown.
8963         (run-tests-parallel): Use the new function.
8964         (run-tests-sequential): Likewise.
8965         (make-environment-cache): Execute setup with an temporary working
8966         directory.
8967
8968 2017-03-21  Justus Winter  <justus@g10code.com>
8969
8970         tests: Test '--quick-set-primary-uid'.
8971         + commit fde885bbc47a4bf14a8570ac62e68adc8cf47a6e
8972         * tests/openpgp/quick-key-manipulation.scm: Test
8973         '--quick-set-primary-uid'.
8974
8975         tests,w32: Use GetTempPath to get the path for temporary files.
8976         + commit d17840c3f40111beaf97d96ad3ca52047976e221
8977         * tests/gpgscm/ffi.c (do_get_temp_path): New function.
8978         (ffi_init): Make function available.
8979         * tests/gpgscm/tests.scm (mkdtemp): Use the new function.
8980
8981 2017-03-21  Werner Koch  <wk@gnupg.org>
8982
8983         gpg: New command --quick-set-primary-uid.
8984         + commit 74c1f30ad6616186f0ab9dbaf34db6c17b1e40c4
8985         * g10/gpg.c (aQuickSetPrimaryUid): New const.
8986         (opts): New command --quick-set-primary-uid.
8987         (main): Implement it.
8988         * g10/keyedit.c (keyedit_quick_adduid): Factor some code out to ...
8989         (quick_find_keyblock): new func.
8990         (keyedit_quick_revuid): Use quick_find_keyblock.
8991         (keyedit_quick_set_primary): New.
8992
8993 2017-03-21  Justus Winter  <justus@g10code.com>
8994
8995         dirmngr: Fix error handling.
8996         + commit 483c1288a8f86dc6bf93d0d3f2865ecc246aecba
8997         * dirmngr/dns-stuff.c (libdns_init): Convert error before printing it.
8998
8999         dirmngr: Load the hosts file into libdns.
9000         + commit 88f1505f0613894d5544290a170119eb538921e5
9001         * dirmngr/dns-stuff.c (libdns_init): Actually load the hosts file into
9002         libdns.
9003
9004         tests: Create temporary directories in '/tmp'.
9005         + commit 06f1f163e96f1039304fd3cf565cf9de1ca45849
9006         * tests/gpgscm/tests.scm (mkdtemp): Create temporary directories in
9007         '/tmp' on UNIX, or in '%Temp' on Windows.
9008         * tests/migrations/common.scm (run-test): Turn error into a warning.
9009         * tests/openpgp/defs.scm (start-agent): Likewise.
9010
9011 2017-03-20  Justus Winter  <justus@g10code.com>
9012
9013         tests: Remove debugging remnants.
9014         + commit ceb4b245752bb1fb43fde7e99f8d904ab8a9b5e2
9015         * tests/gpgme/gpgme-defs.scm (run-python-tests?): Remove 'trace's.
9016
9017         tests: Fail if we cannot create the socket directory.
9018         + commit d75d20909d9f60d33ffd210def92278c0f383aad
9019         * tests/migrations/common.scm (run-test): Turn warning into an error.
9020         * tests/openpgp/defs.scm (start-agent): Likewise.
9021
9022 2017-03-20  Werner Koch  <wk@gnupg.org>
9023
9024         gpg: Add new field no 18 to the colon listing.
9025         + commit fe0b37e123ded51cc5f4cb5e3547fdfbce37a43e
9026         * g10/misc.c (gnupg_pk_is_compliant): New.
9027         * g10/keylist.c (print_compliance_flags): New.
9028         (list_keyblock_colon): Call it here.
9029         * sm/keylist.c (print_compliance_flags): New.
9030         (list_cert_colon): Call it here.
9031
9032         gpg: Remove unused stuff.
9033         + commit e2c63a13e2fa4ce39af8471a34c06d73ff3ee6f6
9034         * g10/OPTIONS: Remove.
9035         * g10/options.h (struct opt): Remove 'shm_coprocess'.
9036
9037 2017-03-17  Neal H. Walfield  <neal@g10code.com>
9038
9039         tests: Add test for issue 2959.
9040         + commit fb9d68d636490ca88925051f48b08963c324aed1
9041         * tests/openpgp/tofu.scm: Add test for --tofu-default-policy=ask.
9042
9043         gpg: Make sure the conflict set includes the current key.
9044         + commit b1106b4d640325c60a7212a4a44e4f67c0e3312d
9045         * g10/tofu.c (get_trust): Sanity check CONFLICT_SET after calling
9046         get_policy.  If POLICY is 'auto' and the default policy is 'ask', make
9047         sure CONFLICT_SET includes the current key.
9048
9049 2017-03-17  Werner Koch  <wk@gnupg.org>
9050
9051         dirmngr: Ignore warning alerts in the GNUTLS handshake.
9052         + commit 69c521df422a6c9a6b0a93e45c9373a8b6ceb28e
9053         * dirmngr/http.c (send_request) [GNUTLS]: Don't bail out on warning
9054         alerts.
9055
9056 2017-03-17  Justus Winter  <justus@g10code.com>
9057
9058         gpgscm: Simplify hash tables.
9059         + commit 6a3f857224eab108ae38e6259194b01b0ffdad8b
9060         * tests/gpgscm/scheme.c (oblist_add_by_name): We now always get a
9061         slot.  Simplify accordingly.
9062         (oblist_find_by_name): Always return the slot.
9063         (vector_elem_slot): New function.
9064         (new_slot_spec_in_env): We now always get a slot.  Remove parameter
9065         'env'.  Simplify accordingly.
9066         (find_slot_spec_in_env): Always return a slot.
9067         (new_slot_in_env): Adapt callsite.
9068         (opexe_0): Likewise.
9069         (opexe_1): Likewise.
9070         (scheme_define): Likewise.
9071
9072         gpgscm: Remove framework for immediate values.
9073         + commit 38c955599f7c6c20faeec57d8e1df7d2c0eeba18
9074         * tests/gpgscm/scheme.c (IMMEDIATE_TAG): Remove macro.
9075         (is_immediate): Likewise.
9076         (set_immediate): Likewise.
9077         (clr_immediate): Likewise.
9078         (enum scheme_types): Set the LSB in every value.
9079         (fill_vector): Adapt.
9080         (vector_elem): Likewise.
9081         (set_vector_elem): Likewise.
9082         (mark): Likewise.
9083         (gc): Test for the LSB to tell typeflags apart from pointers stored in
9084         the same memory location.
9085
9086 2017-03-16  NIIBE Yutaka  <gniibe@fsij.org>
9087
9088         agent,g10: Remove redundant SERIALNO request.
9089         + commit 8c8ce8711d9c938fcb982b0341e6b052742cb887
9090         * agent/learncard.c (agent_handle_learn): Don't call
9091         agent_card_serialno.  Get the serialno in status response.
9092         * g10/call-agent.c (agent_scd_learn): Don't request "SCD SERIALNO".
9093         (agent_scd_serialno): New.
9094         (card_cardlist_cb, agent_scd_cardlist): New.
9095
9096 2017-03-15  Justus Winter  <justus@g10code.com>
9097
9098         tests: Fix using tools from the build directory.
9099         + commit a98459d3f4ec3d196fb0adb0e90dadf40abc8c81
9100         * tests/openpgp/defs.scm (gpg-conf'): Explicitly pass the build prefix
9101         to gpgconf here...
9102         (gpg-components): ... instead of only here.
9103
9104         tests: Dump the tools that the tests are going to use.
9105         + commit c7833eca38fdb8d9ba7b59438ea87d651b8bf7ba
9106         * tests/openpgp/setup.scm: Dump the tools that the tests are going to
9107         use.  This will help us diagnose problems with the tests picking the
9108         wrong paths in the future.
9109
9110         build: Remove '--disable-tools' configuration option.
9111         + commit 6993e42088c191f18468317ba2b5b8fbc8c3edff
9112         * Makefile.am (SUBDIRS): Unconditionally include 'tools'.
9113         * configure.ac: Remove '--disable-tools' configuration option.
9114
9115 2017-03-15  NIIBE Yutaka  <gniibe@fsij.org>
9116
9117         g10: Fix check of serialno.
9118         + commit 61785b679c542bbd789395fa632eb8b5133b01ad
9119         * g10/card-util.c (card_status): Fix.
9120
9121         g10: Remove unused function.
9122         + commit ed3248219e921ee24f6f1b2985abb7e0945d70e9
9123         * g10/call-agent.c (select_openpgp): Remove.
9124
9125         tests: Fix running python condition.
9126         + commit a672ddec03f96475866d712b28be18b3fab43aef
9127         * tests/gpgme/gpgme-defs.scm (run-python-tests?): We need Python.
9128
9129 2017-03-14  Justus Winter  <justus@g10code.com>
9130
9131         tests: Skip Python tests if the bindings are not built.
9132         + commit d82abbb1b6e80d5980e6259ddcfc770e65a6b1b3
9133         * tests/gpgme/wrap.scm (python): Move variable...
9134         * tests/gpgme/gpgme-defs.scm (python): ... here.
9135         (run-python-tests?): New function.
9136         * tests/gpgme/run-tests.scm: Only run Python tests if the bindings can
9137         be located in GPGME's build directory.
9138
9139 2017-03-13  Werner Koch  <wk@gnupg.org>
9140
9141         gpg: Flush stdout before printing stats with --check-sigs.
9142         + commit 9a77b3b6e41f97b1209ad61c04b3dd33242ecae8
9143         * g10/keylist.c (print_signature_stats): Flush stdout.
9144         (list_keyblock_colon): Use es_flush instead of fflush.
9145
9146 2017-03-09  Justus Winter  <justus@g10code.com>
9147
9148         tests: Run the tests for the Python bindings of GPGME.
9149         + commit 046a15a88c83b40a753b4ad7ecc1456efa5b527f
9150         * tests/gpgme/gpgme-defs.scm (create-file): Write lines.
9151         (create-gpgmehome): Extend function to create the right environment
9152         for the Python tests.
9153         * tests/gpgme/run-tests.scm: Make an environment cache for the Python
9154         tests and enable them.
9155         * tests/gpgme/wrap.scm: Do not hardcode the path of the Python
9156         interpreter.
9157
9158         tests: Rework environment setup.
9159         + commit cca91a3f8f7e3e36b7149fc93f7b6df11d21eb1d
9160         * tests/gpgscm/tests.scm (test::scm): Add a setup argument.
9161         (test::binary): Likewise.
9162         (run-tests-parallel): Remove setup parameter.
9163         (run-tests-sequential): Likewise.
9164         (make-environment-cache): New function that handles the cache
9165         protocol.
9166         * tests/gpgme/run-tests.scm: Adapt accordingly.
9167         * tests/gpgsm/run-tests.scm: Likewise.
9168         * tests/migrations/run-tests.scm: Likewise.
9169         * tests/openpgp/run-tests.scm: Likewise.
9170
9171 2017-03-08  Werner Koch  <wk@gnupg.org>
9172
9173         wks: Put stdout into binary mode for Windows at another place.
9174         + commit ed5575ec550ff16b0b901a23c6aa3eb3d47b0575
9175         * tools/wks-util.c (wks_send_mime): Set stdout to binary.
9176
9177         wks: Put stdout into binary mode for Windows.
9178         + commit 5c83759364272b19ceafbef46d057f0430a12698
9179         * tools/send-mail.c (send_mail_to_file): Call es_set_binary.
9180
9181 2017-03-08  Justus Winter  <justus@g10code.com>
9182
9183         build: Use macOS' compatibility macros to enable all features.
9184         + commit dd60e868d2bf649a33dc96e207ffd3b8ae4d35af
9185         * configure.ac: On macOS, use the compatibility macros to expose every
9186         feature of the libc.  This is the equivalent of _GNU_SOURCE on GNU
9187         libc.
9188
9189         g10: Move more flags into the flag bitfield.
9190         + commit 2649fdfff5d9e227025956e015b67502fd4962c4
9191         * g10/packet.h (PKT_user_id): Move 'is_primary', 'is_revoked', and
9192         'is_expired' into the flags bitfield, and drop the prefix.
9193         * g10/call-dirmngr.c: Adapt accordingly.
9194         * g10/export.c: Likewise.
9195         * g10/getkey.c: Likewise.
9196         * g10/import.c: Likewise.
9197         * g10/kbnode.c: Likewise.
9198         * g10/keyedit.c: Likewise.
9199         * g10/keylist.c: Likewise.
9200         * g10/keyserver.c: Likewise.
9201         * g10/mainproc.c: Likewise.
9202         * g10/pkclist.c: Likewise.
9203         * g10/pubkey-enc.c: Likewise.
9204         * g10/tofu.c: Likewise.
9205         * g10/trust.c: Likewise.
9206         * g10/trustdb.c: Likewise.
9207
9208 2017-03-08  Werner Koch  <wk@gnupg.org>
9209
9210         dirmngr: Do not put a keyserver into a new dirmngr.conf.
9211         + commit 8f028642239fa992c6c059e3c1b4421a1813c827
9212         * g10/dirmngr-conf.skel: Do not define keyservers.
9213
9214         doc: Add a note to the trust model direct.
9215         + commit f0257b4a86b73f5b956028e68590b6d2a23ea4da
9216         * doc/gpg.texi (GPG Configuration Options): Add note.  Chnage Index
9217         from trust-mode:foo to trust-model:foo.
9218
9219 2017-03-07  Justus Winter  <justus@g10code.com>
9220
9221         Revert "build: Improve CFLAGS handling."
9222         + commit b71384c8054ce2f245ccfae02b8ee81e1adfc512
9223         This reverts commit 4b57359ef3ce0b87e15889e12ef0fcd23f62dcb4.
9224
9225         build: Improve CFLAGS handling.
9226         + commit 4b57359ef3ce0b87e15889e12ef0fcd23f62dcb4
9227         * configure.ac: Strip any flags matching '-Werror' from CFLAGS before
9228         running the tests, and add them back later on.
9229
9230 2017-03-07  Michael Haubenwallner  <michael.haubenwallner@ssi-schaefer.com>
9231
9232         gpgscm: Use system strlwr if available.
9233         + commit c22a2a89d3bd3d08b3abb8e4e33df32b480338ec
9234         * tests/gpgscm/scheme.c: Define local strlwr only when HAVE_STRLWR is
9235         not defined in config.h.
9236         * tests/gpgscm/scheme-config.h: Remove hack.
9237
9238 2017-03-07  Justus Winter  <justus@g10code.com>
9239
9240         gpg: Do not allow the user to revoke the last valid UID.
9241         + commit 591b6a9d879cbcabb089d89a26d3c3e0306054e1
9242         * g10/keyedit.c (keyedit_quick_revuid): Merge self signatures, then
9243         make sure that we do not revoke the last valid UID.
9244         (menu_revuid): Make sure that we do not revoke the last valid UID.
9245         * tests/openpgp/quick-key-manipulation.scm: Demonstrate that
9246         '--quick-revoke-uid' can not be used to revoke the last valid UID.
9247
9248 2017-03-07  NIIBE Yutaka  <gniibe@fsij.org>
9249
9250         tools: Removal of -Icommon.
9251         + commit 80fb1a8a05b2194af16027555b09bbd5d48ec9ac
9252         * tools/gpg-wks-server.c: Follow the change.
9253
9254         More change for common.
9255         + commit d6c7bf1f8ab8899faba2fb81a35b096921c38f3c
9256         * g10, scd, test, tools: Follow the change of removal of -Icommon.
9257
9258         Remove -I option to common.
9259         + commit 70aca95d6816082b289fceca8eabfcf718a6b701
9260         * dirmngr/Makefile.am (AM_CPPFLAGS): Remove -I$(top_srcdir)/common.
9261         * g10/Makefile.am (AM_CPPFLAGS): Ditto.
9262         * g13/Makefile.am (AM_CPPFLAGS): Ditto.
9263         * kbx/Makefile.am (AM_CPPFLAGS): Ditto.
9264         * scd/Makefile.am (AM_CPPFLAGS): Ditto.
9265         * sm/Makefile.am (AM_CPPFLAGS): Ditto.
9266         * tools/Makefile.am (AM_CPPFLAGS): Ditto.
9267         * Throughout: Follow the change.
9268
9269 2017-03-07  Justus Winter  <justus@g10code.com>
9270
9271         tests: Avoid overflowing signed 32 bit time_t.
9272         + commit de3838372ae3cdecbd83eea2c53c8e2656d93052
9273         * tests/openpgp/quick-key-manipulation.scm: Use expiration times in
9274         the year 2038 instead of 2105 to avoid overflowing 32 bit time_t.
9275         time_t is used internally to parse the expiraton time from the iso
9276         timestamp.
9277
9278 2017-03-07  NIIBE Yutaka  <gniibe@fsij.org>
9279
9280         agent: Resolve conflict of util.h.
9281         + commit 176e07ce10d892fa7c7b96725b38b2fec9a1f916
9282         * agent/Makefile.am (AM_CPPFLAGS): Remove -I$(top_srcdir)/common.
9283         * agent/call-pinentry.c, agent/call-scd.c: Follow the change.
9284         * agent/command-ssh.c, agent/command.c, agent/cvt-openpgp.c: Ditto.
9285         * agent/divert-scd.c, agent/findkey.c, agent/genkey.c: Ditto.
9286         * agent/gpg-agent.c, agent/pksign.c, agent/preset-passphrase.c: Ditto.
9287         * agent/protect-tool.c, agent/protect.c, agent/trustlist.c: Ditto.
9288         * agent/w32main.c: Ditto.
9289
9290         agent: Add include files.
9291         + commit bf03925751abb739f2fd9d631694d3dd33decf92
9292         * agent/command-ssh.c: Add sys/socket.h and sys/un.h.
9293
9294         agent: Fix get_client_pid for portability.
9295         + commit f7f806afa5083617f4aba02fc3b285b06a7d73d4
9296         * configure.ac: Simply check getpeerucred and ucred.h, and structure
9297         members.
9298         * agent/command-ssh.c: Include ucred.h.
9299         (get_client_pid) [HAVE_STRUCT_SOCKPEERCRED_PID]: Use sockpeercred
9300         structure for OpenBSD.
9301         [LOCAL_PEERPID]: Use LOCAL_PEERPID for macOS.
9302         [LOCAL_PEEREID]: Use LOCAL_PEEREID for NetBSD.
9303         [HAVE_GETPEERUCRED]: Use getpeerucred for OpenSolaris.
9304
9305         common: Fix warning for portability.
9306         + commit b9ab733fc0dd2ca2a7eaac0bde3a817c07af36c5
9307         * common/localename.c (do_nl_locale_name): We don't use CATEGORY.
9308
9309         tools: More portable for openpty use.
9310         + commit ce37ada87139ef418401f9f35439007a8c04a856
9311         * configure.ac (AC_CHECK_HEADERS): Add util.h libutil.h and termios.h.
9312         * tools/symcryptrun.c: Include those headers.
9313
9314         scd: Close THE_EVENT handle.
9315         + commit cc933a96f8e83bc66fb69ed33d9593acdd60c929
9316         * scd/scdaemon.c (handle_connections): Close the handle.
9317
9318 2017-03-06  Justus Winter  <justus@g10code.com>
9319
9320         tests: Harmonize temporary and socket directory handling.
9321         + commit 7e19786a5ddef637d1d9d21593fecf5a36b6f372
9322         * tests/gpgscm/tests.scm (mkdtemp): Do not magically obey the
9323         environment variable 'TMP', make sure to always return an absolute
9324         path.
9325         * tests/gpgme/Makefile.am (TMP): Drop variable.
9326         (TESTS_ENVIRONMENT): Drop 'TMP'.
9327         * tests/gpgme/gpgme-defs.scm (create-gpgmehome): Start the agent.  Do
9328         not create private key store, the agent does that for us.
9329         * tests/gpgsm/Makefile.am (TMP): Drop variable.
9330         (TESTS_ENVIRONMENT): Drop 'TMP'.
9331         * tests/gpgme/gpgme-defs.scm (create-gpgsmhome): Start the agent.  Do
9332         not create private key store, the agent does that for us.
9333         * tests/migrations/Makefile.am (TMP): Drop variable.
9334         (TESTS_ENVIRONMENT): Drop 'TMP'.
9335         * tests/migrations/common.scm (gpgconf): New variable.
9336         (run-test): Create and remove socket directory.
9337         * tests/migrations/extended-pkf.scm (src-tarball): Remove variable.
9338         (setup): Remove function.
9339         (trigger-migration): Likewise.
9340         Use 'run-test' to execute the test.
9341         * tests/migrations/from-classic.scm (src-tarball): Remove variable.
9342         (setup): Remove function.
9343         Use 'run-test' to execute the tests.
9344         * tests/openpgp/Makefile.am (TMP): Drop variable.
9345         (TESTS_ENVIRONMENT): Drop 'TMP'.
9346         * tests/openpgp/README: Do not mention 'TMP'.
9347         * tests/openpgp/defs.scm (with-home-directory): New macro.
9348         (create-legacy-gpghome): Do not create private key store, the agent
9349         does that for us.
9350         (start-agent): Make sure to terminate the right agent with 'atexit'.
9351
9352         gpgscm: Fix creation of temporary directories.
9353         + commit 171e4314ebd3ff74af3dcdc8bd68e1100e8910ea
9354         * tests/gpgscm/ffi.c (do_mkdtemp): Use a larger buffer for the
9355         template.
9356
9357 2017-03-06  Werner Koch  <wk@gnupg.org>
9358
9359         wks: Set published keys world-readable.
9360         + commit e3589110e01dc6ad04463351ec2ce17201556d09
9361         * tools/gpg-wks-server.c (check_and_publish): Set the permissions.
9362
9363         gpg: Fix attempt to double free an UID structure.
9364         + commit 4a130bbc2c2f4be6e8c6357512a943f435ade28f
9365         * g10/getkey.c (get_best_pubkey_byname): Set released .UID to NULL.
9366
9367 2017-03-06  NIIBE Yutaka  <gniibe@fsij.org>
9368
9369         scd: Fix compiler warnings for app-openpgp.c.
9370         + commit e6ca015ae182a6dbb0466441efc17c99683e9375
9371         * scd/app-openpgp.c (retrieve_key_material): Remove touching I.
9372         (do_change_pin): Make sure going to leave if PINVALUE == 0.
9373         (rsa_writekey): Emit simpler log.
9374
9375         scd: More cleanup of old code.
9376         + commit 9bf39ed75ddbd35908bcd0996f55325ff801619a
9377         * scd/app-dinsig.c (do_sign): Remove assignment to HASHALGO.
9378         * scd/app-p15.c (parse_keyusage_flags): Remove assign to MASK.
9379         (read_ef_aodf): Likewise.
9380         (read_ef_cdf): Change the control to parse_error.
9381         * scd/app-sc-hsm.c (parse_keyusage_flags): Remove assign to MASK.
9382         (read_ef_prkd): Remove assign to S.
9383         (read_ef_prkd): Check if PRKDF is not null.
9384         (read_ef_cd): Likewise for CDF.
9385
9386         scd: Clean up old code.
9387         + commit cb6337329d3c858c695a7e56e2fc31d9d50ca3fe
9388         * scd/apdu.c (CT_init, CT_data, CT_close): Remove.
9389         (ct_error_string, ct_activate_card, close_ct_reader, reset_ct_reader)
9390         (ct_get_status, ct_send_apdu, open_ct_reader): Remove.
9391         (new_reader_slot) [NEED_PCSC_WRAPPER]: Remove fd and pid handling.
9392         (writen, readn): Remove.
9393         (pcsc_get_status, pcsc_send_apdu, control_pcsc, close_pcsc_reader)
9394         (reset_pcsc_reader, open_pcsc_reader): Only DIRECT version.
9395         (apdu_open_one_reader): Remove CT_api handling.
9396         (apdu_get_status_internal, send_le): Fix to stop warnings.
9397
9398         scd: Fix API of select_file/_path.
9399         + commit 0703de01c8fbc417a99ecf8e950fc306b8c8ac9c
9400         * scd/iso7816.c (iso7816_select_file, iso7816_select_path): Remove
9401         unused arguments.
9402         * scd/app-dinsig.c (do_readcert): Follow the change.
9403         * scd/app-help.c (app_help_read_length_of_cert): Likewise.
9404         * scd/app-nks.c (keygripstr_from_pk_file, do_readcert, do_readkey)
9405         (switch_application): Likewise.
9406         * scd/app-p15.c (select_and_read_binary, select_ef_by_path)
9407         (micardo_mse, app_select_p15): Likewise.
9408         * scd/app.c (app_new_register): Likewise.
9409
9410         agent: For SSH, robustly handling scdaemon's errors.
9411         + commit 4ce4f2f683a17be3ddb93729f3f25014a97934ad
9412         * agent/command-ssh.c (card_key_list): Return 0 when
9413         agent_card_serialno returns an error.
9414         (ssh_handler_request_identities): Handle errors for card listing
9415         and proceed to other cases.
9416
9417 2017-03-03  Werner Koch  <wk@gnupg.org>
9418
9419         dirmngr: Fix commit de6d8313.
9420         + commit 67c203b6bf8d6dd489ceef3391f609986e7b7a49
9421         * dirmngr/http-common.c (get_default_keyserver): Fix assert.
9422
9423 2017-03-03  NIIBE Yutaka  <gniibe@fsij.org>
9424
9425         scd: Fix scd_kick_the_loop.
9426         + commit f9acc7d18bb90f47dafe7e32ae92f567756d6b12
9427         * scd/scdaemon.c (notify_fd): Remove.
9428         (the_event) [W32]: New.
9429         (main_thread_pid) [!W32]: New.
9430         (handle_signal): Handle SIGCONT.
9431         (scd_kick_the_loop): Use signal on UNIX and event on Windows.
9432         (handle_connections): Likewise.
9433
9434 2017-03-03  Werner Koch  <wk@gnupg.org>
9435
9436         gpg: Fix possible segv when attribute packets are filtered.
9437         + commit 5f6f3f5cae8a95ed469129f9677782c17951dab3
9438         * g10/import.c (impex_filter_getval): Handle PKT_ATTRIBUTE the same as
9439         PKT_USER_ID
9440         (apply_drop_sig_filter): Ditto.
9441
9442         gpg: Add new variables to the import and export filters.
9443         + commit 1813f3be23bdab5a42070424c47cb8daa9d9e6b7
9444         * g10/import.c (impex_filter_getval): Add new variables "expired",
9445         "revoked", and "disabled".
9446
9447 2017-03-02  Werner Koch  <wk@gnupg.org>
9448
9449         tools: Fix compile error with older gcc versions.
9450         + commit b1f48da02b474e985161aa2778d7b602a13c4292
9451         * tools/mime-parser.h: Include rfc822parse.h.
9452         (struct rfc822parse_context): Remove duplicate definition.
9453
9454         dirmngr: Rearrange files to fix de6d831.
9455         + commit 1890896fe698c55d15160a53aa6c5c22dc424031
9456         * dirmngr/http-common.c: New.
9457         * dirmngr/http-common.h: New.
9458         * dirmngr/Makefile.am (dirmngr_SOURCES): Add them.
9459         (t_http_SOURCES): Add them.
9460         (t_ldap_parse_uri_SOURCES): Add them.
9461         * dirmngr/misc.c (get_default_keyserver): Move to ...
9462         * dirmngr/http-common.c: here.
9463         * dirmngr/http.c: Include http-common.h instead of misc.h.
9464         * dirmngr/http-ntbtls.c: Ditto.
9465
9466         dirmngr: Let --gpgconf-list return the default keyserver.
9467         + commit de6d8313f6df32aaa151bee74e1db269ac1e0fed
9468         * dirmngr/misc.c (get_default_keyserver): New.
9469         * dirmngr/http.c: Include misc.h
9470         (http_session_new): Use get_default_keyserver instead of hardwired
9471         "hkps.pool.sks-keyservers.net".
9472         * dirmngr/http-ntbtls.c (gnupg_http_tls_verify_cb): Ditto.
9473         * dirmngr/dirmngr.c (main) <aGPGCongList>: Return default keyserver.
9474
9475 2017-03-02  Justus Winter  <justus@g10code.com>
9476
9477         gpg: Always initialize the trust db when generating keys.
9478         + commit 0c4d0620d327e8a2069532a5519afefe867a47d6
9479         * g10/gpg.c (main): Always initialize the trust db when generating
9480         keys.
9481         * g10/keygen.c (do_generate_keypair): We can now assume that there is
9482         a trust db.
9483
9484         gpg: Fix (quick) key generation with --always-trust.
9485         + commit 4735ab96aa5577d40ba7b3f72d863057198cc6a7
9486         * g10/keygen.c (do_generate_keypair): Only update the ownertrust if we
9487         do have a trust database.
9488         * g10/trustdb.c (have_trustdb): New function.
9489         * g10/trustdb.h (have_trustdb): New prototype.
9490         * tests/openpgp/quick-key-manipulation.scm: Remove workaround.
9491
9492 2017-03-02  Werner Koch  <wk@gnupg.org>
9493
9494         agent: Improve error message for the KEYTOCARD command.
9495         + commit d6f0f368763006abf08818bfefcd32ecedb5c20a
9496         * agent/command.c (cmd_keytocard): Always use leave_cmd.  Simplify
9497         timestamp checking and do an early test with an appropriate error
9498         message.
9499
9500 2017-03-02  Justus Winter  <justus@g10code.com>
9501
9502         g10: Signal an error when trying to revoke non-existant UID.
9503         + commit 62d21a4ab4029b32ea129f1cf3a0e1f22e2fb7b0
9504         * g10/keyedit.c (keyedit_quick_revuid): Signal an error when trying to
9505         revoke non-existant UID.
9506         * tests/openpgp/quick-key-manipulation.scm: Test that.
9507
9508         tests: Log information about ssh, add comments to test.
9509         + commit 74cb3b230c1f99afc5fd09bccc24186a63b154b0
9510         * tests/openpgp/ssh-import.scm (ssh-version-string): New variable, and
9511         log the binary and version used in the test.
9512         (ssh-supports?): Document how we test what algorithms are supported by
9513         ssh, and log ssh-keygen's replies.
9514
9515         common,tools: Always escape newlines when escaping data.
9516         + commit e064c75b08a523f738108428fe0c417a46e66238
9517         * common/stringhelp.c (do_percent_escape): Always escape newlines.
9518         * tools/gpgconf-comp.c (gc_percent_escape): Likewise.
9519
9520 2017-03-01  Werner Koch  <wk@gnupg.org>
9521
9522         Release 2.1.19.
9523         + commit 4a28c212b35739ce951bd41cfc6ef1a215846b2e
9524
9525
9526         build: Add kludge for "make distcheck" in a release build.
9527         + commit 246b27921b5dc34f367d879402725784aaee2494
9528         * configure.ac: New option --enable-gnupg-builddir-envvar.
9529         (ENABLE_GNUPG_BUILDDIR_ENVVAR): New ac_define.
9530         * common/homedir.c (gnupg_set_builddir_from_env): Consider
9531         ENABLE_GNUPG_BUILDDIR_ENVVAR.
9532         * Makefile.am (DISTCHECK_CONFIGURE_FLAGS): Rename to ...
9533         (AM_DISTCHECK_CONFIGURE_FLAGS): this to be future proof.  Add option
9534         --enable-gnupg-builddir-envvar.
9535
9536 2017-03-01  Yuri Chornoivan  <yurchor@ukr.net>
9537
9538         po: Update Ukrainian translation.
9539         + commit c7f2a59833728e99e00449da2ddb10cf66693e7e
9540
9541
9542 2017-03-01  Ineiev  <ineiev@gnu.org>
9543
9544         po: Update Russian translation.
9545         + commit 280c724fe26bfd861ac74abc71e221795d8947f0
9546
9547
9548 2017-03-01  Werner Koch  <wk@gnupg.org>
9549
9550         gpg: Make --export-options work with --export-secret-keys.
9551         + commit 891ab23411b7f20ef37d8bde81d9857b083235df
9552         * g10/export.c (export_seckeys): Add arg OPTIONS and pass it to
9553         do_export.
9554         (export_secsubkeys): Ditto.
9555         * g10/gpg.c (main): Pass opt.export_options to export_seckeys and
9556         export_secsubkeys
9557
9558         gpg: Allow creating keys using an existing ECC key.
9559         + commit 2bbdeb8ee87a6c7ec211be16391a11b7c6030bed
9560         * common/sexputil.c (get_pk_algo_from_canon_sexp): Remove arg R_ALGO.
9561         Change to return the algo id.  Reimplement using get_pk_algo_from_key.
9562         * g10/keygen.c (check_keygrip): Adjust for change.
9563         * sm/certreqgen-ui.c (check_keygrip): Ditto.
9564
9565 2017-02-28  Werner Koch  <wk@gnupg.org>
9566
9567         gpg: Do not require a trustdb for decryption.
9568         + commit e182542e90cbeff4f2ac6c8d71061356d7cdcdea
9569         * g10/trustdb.c (init_trustdb): Add and implement arg NO_CREATE.
9570         Change to return an error code.  Change all callers to to pass False
9571         for NO_CREATE.
9572         (tdb_get_ownertrust): New arg NO_CREATE.  Call init_trustdb to test
9573         for a non-existing trustdb.  Change all callers to to pass False for
9574         NO_CREATE.
9575         (tdb_get_min_ownertrust): Ditto.
9576         * g10/trust.c (get_ownertrust_with_min): Add arg NO_CREATE.  Call
9577         init_trustdb for a quick check.
9578         (get_ownertrust_info): Add arg NO_CREATE.
9579         (get_ownertrust_string): Ditto.
9580         * g10/gpgv.c (get_ownertrust_info): Adjust stub.
9581         * g10/test-stubs.c (get_ownertrust_info): Ditto.
9582         * g10/mainproc.c (list_node): Call get_ownertrust_info with NO_CREATE
9583         set.
9584         * g10/pubkey-enc.c (get_it): Ditto.
9585
9586 2017-02-28  Justus Winter  <justus@g10code.com>
9587
9588         gpgscm: Improve parsing.
9589         + commit e4583ae14e52482ab390c102d071755f91ab211d
9590         * tests/gpgscm/scheme.c (port_increment_current_line): Avoid creating
9591         the same integer if the delta is zero.  This happens a lot during
9592         parsing, and puts pressure on the memory allocator.
9593
9594         gpgscm: Fix calculating the line number.
9595         + commit 058c97f9fc485405246b1adfcc905c1891550652
9596         * tests/gpgscm/scheme.c (opexe_5): Only increment the line number on
9597         newlines.
9598
9599         gpg,tools: Make auto-key-retrieve configurable via gpgconf.
9600         + commit d379a0174cca595204b32da9a66c513a1304e6d0
9601         * g10/gpg.c (gpgconf_list): Add 'auto-key-retrieve'.
9602         * tools/gpgconf-comp.c (gc_options_gpg): Likewise.
9603
9604         tests: Improve support for gpgconf.
9605         + commit 41900175cf046dd9abe3d7a6805f6a403d68df15
9606         * tests/openpgp/defs.scm: Improve high-level inteface to gpgconf.
9607         * tests/openpgp/gpgconf.scm: Adapt.
9608         * tests/openpgp/tofu.scm: Use it to select the trust model.
9609
9610         gpg,tools: Make trust-model configurable via gpgconf.
9611         + commit ebeccd73eb85f9027f0985d77dfe901266c6ddef
9612         * g10/gpg.c (gpgconf_list): Add 'trust-model'.
9613         * tools/gpgconf-comp.c (gc_options_gpg): Likewise.
9614
9615         gpgscm: Track source locations in every kind of ports.
9616         + commit 7cc57e2c63d0fa97569736419db5c76117e7685b
9617         * tests/gpgscm/scheme-private.h (struct port): Move location
9618         information out of the union.
9619         * tests/gpgscm/scheme.c (mark): All ports need marking now.
9620         (gc): Likewise all ports on the load stack.
9621         (port_clear_location): Adapt accordingly.  Also, add an empty function
9622         for !SHOW_ERROR_LINE.
9623         (port_increment_current_line): Likewise.
9624         (port_reset_current_line): Drop function in favor of...
9625         (port_init_location): ... this new function.
9626         (file_push): Simplify.
9627         (file_pop): Likewise.
9628         (port_rep_from_filename): Likewise.
9629         (port_rep_from_file): Likewise.
9630         (port_rep_from_string): Also initialize the location.
9631         (port_rep_from_scratch): Likewise.
9632         (port_close): Simplify and generalize.
9633         (skipspace): Likewise.
9634         (token): Likewise.
9635         (_Error_1): Generalize.
9636         (opexe_5): Likewise.
9637         (scheme_deinit): Simplify and generalize.
9638         (scheme_load_named_file): Likewise.
9639         (scheme_load_string): Also initialize the location.
9640
9641 2017-02-28  Werner Koch  <wk@gnupg.org>
9642
9643         gpgv,w32: Fix --status-fd.
9644         + commit 8a67dc4c4324b617b5a3fea51c59c674488544d6
9645         * g10/gpgv.c (main): Use translate_sys2libc_fd_int for --status-fd.
9646
9647         w32: Make pipes really pollable.
9648         + commit 1192449207f41b26be8950b04df84a52c8a2a886
9649         * common/exectool.c (gnupg_exec_tool_stream) [W32]: Use _get_osfhandle
9650         to print the fd for the command line.
9651         * common/exechelp-w32.c (create_pipe_and_estream): Use es_sysopen so
9652         that the streams are actually pollable.
9653
9654 2017-02-26  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
9655
9656         dirmngr: Avoid warnings during non-ntbtls build.
9657         + commit f5782e11a560fd590221042391254c810a42e45f
9658         * dirmngr/t-http.c (my_http_tls_verify_cb): Avoid warnings when not
9659         using ntbtls.
9660
9661         trustdb: Respect --quiet during --import-ownertrust.
9662         + commit ddf01a67d6388d988f1db50a06facb21c14d9426
9663         * g10/tdbdump.c (import_ownertrust): If opt.quiet is set, do not send
9664         log_info messages.
9665
9666 2017-02-26  Manish Goregaokar  <manish@mozilla.com>
9667
9668         g10: fix typo.
9669         + commit 64ec21bebd3f136722e608649906b59c6add6947
9670         I already have copyright assignment with the FSF for GDB. I don't
9671         think I'll need to do the DCO thing.
9672
9673 2017-02-24  Werner Koch  <wk@gnupg.org>
9674
9675         gpgv: New options --log-file and --debug.
9676         + commit 7af5d61c6e210210c777be9e6e87720dd4a055d9
9677         * g10/gpgv.c (oLoggerFile, oDebug): New consts.
9678         (opts): Add options --log-file and --debug.
9679         (main): Implement options.
9680
9681 2017-02-24  Andre Heinecke  <aheinecke@intevation.de>
9682
9683         speedo,w32: Fix gpg-wks-client installation.
9684         + commit 49b4a676148523b51beca3ae929e9d78ed7ba110
9685         * build-aux/speedo/w32/inst.nsi: gpg-wks-client is an exe.
9686
9687 2017-02-23  Werner Koch  <wk@gnupg.org>
9688
9689         dirmngr: Add new debug flag "extprog"
9690         + commit 22b69b9edfdf6e6172239cbd1075ffe29077d339
9691         * dirmngr/dirmngr.h (DBG_EXTPROG_VALUE, DBG_EXTPROG): New macros.
9692         * dirmngr/dirmngr.c (debug_flags): Add flag "extprog".
9693         (handle_connections): Use a macro instead of -1 for an invalid socket.
9694         * dirmngr/loadswdb.c (verify_status_cb): Debug the gpgv call.
9695
9696         wks: Make sure that the draft 2 request is correctly detected.
9697         + commit d30e17ac62dea8913b7f353971d546b6b1a09bd5
9698         * tools/gpg-wks.h (WKS_DRAFT_VERSION): New.
9699         * tools/wks-receive.c (new_part): Move test wks draft version to ...
9700         (t2body): new callback.
9701         (wks_receive): Register this callback.
9702         * tools/gpg-wks-server.c (send_confirmation_request): Emit draft
9703         version header.
9704         (send_congratulation_message): Ditto.
9705         * tools/gpg-wks-client.c (decrypt_stream_parm_s): New.
9706         (decrypt_stream_status_cb): Check DECRYTPION_KEY status.
9707         (decrypt_stream): Get infor from new callback.
9708         (process_confirmation_request): New arg 'mainfpr'.  Check that it
9709         matches the decryption key.
9710         (read_confirmation_request): Check that the decryption key has been
9711         generated by us.
9712         (command_send): Use macro from draft version header.
9713         (send_confirmation_response): Emit draft version header.
9714
9715         wks: New callback for the mime parser.
9716         + commit a2090250829fe8989be2afc8cf41ba2a022072fc
9717         * tools/mime-parser.c (mime_parser_context_s): New field 't2body'.
9718         (parse_message_cb): Call that callback.
9719         (mime_parser_set_t2body): New.
9720
9721         gpg: Emit new status DECRYPTION_KEY.
9722         + commit effa80e0b5fd8cf9e31a984afe391c2406edee8b
9723         * common/status.h (STATUS_DECRYPTION_KEY): New.
9724         * g10/pubkey-enc.c (get_it): Emit that status.
9725
9726         dirmngr,w32: Make https with ntbtls work.
9727         + commit a42bf00b4edce789999aa3bdfce235cf726463ae
9728         * dirmngr/http.c (simple_cookie_functions): New.
9729         (send_request) [HTTP_USE_NTBTLS, W32]: Use es_fopencookie.
9730         (cookie_read): Factor some code out to ...
9731         (read_server): new.
9732         (simple_cookie_read, simple_cookie_write) [W32]: New.
9733
9734 2017-02-22  Werner Koch  <wk@gnupg.org>
9735
9736         scd,agent: Improve the OpenPGP PIN prompt texts.
9737         + commit f98c8cb013033c08e98ebedcc0e084fbd2a85b0c
9738         * scd/app-openpgp.c (get_prompt_info): Change texts.
9739         * agent/call-pinentry.c (struct entry_features): New.
9740         (getinfo_features_cb): New.
9741         (start_pinentry): Set new fucntion as status callback.
9742         (build_cmd_setdesc): New.  Replace all snprintf for SETDESC by this
9743         one.
9744
9745 2017-02-22  Andre Heinecke  <aheinecke@intevation.de>
9746
9747         scd: Nitpicks on the improved card prompts.
9748         + commit 143ca039e1e81140ae520cc1025f8e25c01acc80
9749         * src/app-openpgp.c (get_prompt_info): Change wording and order
9750         slightly.
9751
9752 2017-02-22  Werner Koch  <wk@gnupg.org>
9753
9754         scd: Improve the prompts for OpenPGP cards.
9755         + commit e3944f34e3220f96fb1be449eb6f3d7360bc2d0b
9756         * scd/app-openpgp.c (get_disp_name): New.
9757         (get_disp_serialno): New.
9758         (get_prompt_info): New.
9759         (build_enter_admin_pin_prompt): Rework the prompt texts.  Factor some
9760         code out to ...
9761         (get_remaining_tries): New.
9762         (verify_a_chv): Print a remaining counter also for the standard PIN.
9763         Rework the prompt texts.
9764
9765         * agent/divert-scd.c (ask_for_card): Pretty format an OpenPGP serial
9766         no.
9767
9768         agent: Prepend the description to a PIN prompt.
9769         + commit 6488ffb767733a2cf92ca5ba3e61fc0c53e0f673
9770         * agent/divert-scd.c (has_percent0A_suffix): New.
9771         (getpin_cb): Prepend DESC_TEXT to the prompt.
9772         * agent/findkey.c (modify_description): Rename to ...
9773         (agent_modify_description): this.  MAke global.  Add kludge to remove
9774         empty parentheses from the end.
9775         (agent_key_from_file, agent_delete_key): Adjust for above change.
9776         * agent/pksign.c (agent_pksign_do): Modify DESC_TEXT also when
9777         diverting to a card.
9778
9779         agent: Prepare to pass an additional parameter to the getpin callback.
9780         + commit 78d875a0f83bc046279b951aea76cd74f3c44fd8
9781         * agent/call-scd.c (writekey_parm_s, inq_needpin_s): Merge into ...
9782         (inq_needpin_parm_s): new struct.  Add new field 'getpin_cb_desc'.
9783         Change users to set all fields.
9784         (inq_needpin): Pass GETPIN_CB_DESC to the GETPIN_CB.
9785         (agent_card_pksign): Add arg 'desc_text' and change arg 'getpin_cb' to
9786         take an additional arg 'desc_text'.
9787         (agent_card_pkdecrypt): Ditto.
9788         (agent_card_writekey): Change arg 'getpin_cb' to take an additional
9789         arg 'desc_text'.
9790         (agent_card_scd): Ditto.
9791         * agent/divert-scd.c (getpin_cb): Add new arg 'desc_text'.
9792         (divert_pksign): Add new arg 'desc_text' and pass is to
9793         agent_card_pksign.
9794         (divert_pkdecrypt): Add new arg 'desc_text' and pass is to
9795         agent_card_pkdecrypt.
9796         * agent/pkdecrypt.c (agent_pkdecrypt): Pass DESC_TEXT to
9797         divert_pkdecrypt.
9798         * agent/pksign.c (agent_pksign_do):  Pass DESC_TEXT to
9799         divert_pksign.
9800
9801 2017-02-22  NIIBE Yutaka  <gniibe@fsij.org>
9802
9803         tests: No spelling fix for test text.
9804         + commit ef424353f342f80ca6d18ede8b63c1b02215d105
9805         * tests/openpgp/verify.scm (msg_ed25519_rshort): Revert the spelling
9806         fix.
9807
9808 2017-02-21  Werner Koch  <wk@gnupg.org>
9809
9810         dirmngr: Add special treatment for the standard hkps pool to ntbtls.
9811         + commit 831d014550863026dfefa774c961a21bd20c1e48
9812         * dirmngr/validate.h (VALIDATE_FLAG_SYSTRUST): Remove
9813         (VALIDATE_FLAG_EXTRATRUST): Remove
9814         (VALIDATE_FLAG_TRUST_SYSTEM): New.
9815         (VALIDATE_FLAG_TRUST_CONFIG): New.
9816         (VALIDATE_FLAG_TRUST_HKP): New.
9817         (VALIDATE_FLAG_TRUST_HKPSPOOL): New.
9818         (VALIDATE_FLAG_MASK_TRUST): New.
9819         * dirmngr/validate.c (check_header_constants): New.
9820         (validate_cert_chain): Call new function.  Simplify call to
9821         is_trusted_cert.
9822         * dirmngr/crlcache.c (crl_parse_insert): Pass
9823         VALIDATE_FLAG_TRUST_CONFIG to validate_cert_chain
9824         * dirmngr/server.c (cmd_validate): Use VALDIATE_FLAG_TRUST_SYSTEM and
9825         VALIDATE_FLAG_TRUST_CONFIG.
9826         * dirmngr/http-ntbtls.c (gnupg_http_tls_verify_cb): Check provided TLS
9827         context.  Set trustclass flags using the new VALIDATE_FLAG_TRUST
9828         values.
9829
9830         * dirmngr/certcache.c (cert_cache_init): Load the standard pool
9831         certificate prior to the --hkp-cacerts.
9832
9833         dirmngr: Load --hkp-cacert values into the certificate cache.
9834         + commit d1625a9a82b1e5d96bbbf2132c49c53108565ae1
9835         * dirmngr/dirmngr.c (hkp_cacert_filenames): New var.
9836         (parse_rereadable_options): Store filenames from --hkp-cacert in the
9837         new var.
9838         (main, dirmngr_sighup_action): Pass that var to cert_cache_init.
9839         * dirmngr/certcache.c (cert_cache_init): Add arg 'hkp_cacert' and load
9840         those certs.
9841         (load_certs_from_file): Use autodetect so that PEM and DER encodings
9842         are possible.
9843
9844         dirmngr: Load "sks-keyservers.netCA.pem" into the cache.
9845         + commit 9741aa24d9056b56cd5366ff5379bd8a3e6118df
9846         * dirmngr/certcache.c (load_certs_from_file): Always build this
9847         function.  Add args 'trustclasses' and 'no_error'.  Pass TRUSTCLASSES
9848         to put_cert.
9849         (load_certs_from_system): Pass CERTTRUST_CLASS_SYSTEM to
9850         load_certs_from_file.
9851         (cert_cache_init): Try to load "sks-keyservers.netCA.pem".  Don't make
9852         function fail in an out-of-core condition.
9853
9854         dirmngr: Implement trust classes for the cert cache.
9855         + commit 50b9828eacc39c1ca75cb8313db896e4bdc8b270
9856         * dirmngr/certcache.h (CERTTRUST_CLASS_SYSTEM): New.
9857         (CERTTRUST_CLASS_CONFIG): New.
9858         (CERTTRUST_CLASS_HKP): New.
9859         (CERTTRUST_CLASS_HKPSPOOL): New.
9860         * dirmngr/certcache.c (MAX_EXTRA_CACHED_CERTS): Rename to ...
9861         (MAX_NONPERM_CACHED_CERTS): this.
9862         (total_extra_certificates): Rename to ...
9863         (total_nonperm_certificates): this.
9864         (total_config_certificates): Remove.
9865         (total_trusted_certificates): Remove.
9866         (total_system_trusted_certificates): Remove.
9867         (cert_item_s): Remove field 'flags'.  Add fields 'permanent' and
9868         'trustclasses'.
9869         (clean_cache_slot): Clear new fields.
9870         (put_cert): Change for new cert_item_t structure.
9871         (load_certs_from_dir): Rename arg 'are_trusted' to 'trustclass'
9872         (load_certs_from_file): Use CERTTRUST_CLASS_ value for put_cert.
9873         (load_certs_from_w32_store): Ditto.
9874         (cert_cache_init): Ditto.
9875         (cert_cache_print_stats): Rewrite.
9876         (is_trusted_cert): Replace arg 'with_systrust' by 'trustclasses'.
9877         Chnage the test.
9878         * dirmngr/validate.c (allowed_ca): Pass CERTTRUST_CLASS_CONFIG to
9879         is_trusted_cert.
9880         (validate_cert_chain): Pass CERTTRUST_CLASS_ values to
9881         is_trusted_cert.
9882
9883         dirmngr: New Assuan option "http-crl".
9884         + commit 493c142e582ff5ef1b5fdfcb9653715ef43e83e9
9885         * dirmngr/dirmngr.h (server_control_s): New flag 'http_no_crl'.
9886         * dirmngr/dirmngr.c (dirmngr_init_default_ctrl): Set this flag.
9887         * dirmngr/server.c (option_handler): New option "http-crl"
9888         * dirmngr/http.h (HTTP_FLAG_NO_CRL): New flag.
9889         * dirmngr/http-ntbtls.c (gnupg_http_tls_verify_cb): Consult this flag.
9890         * dirmngr/ks-engine-hkp.c (send_request): Set flag depending on CTRL.
9891         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
9892
9893         * dirmngr/t-http.c (main): New option --no-crl.
9894
9895         dirmngr: Add a magic field to the http structs.
9896         + commit 39c745038181edd097e188434b3f9c971ed3987f
9897         * dirmngr/http.c (HTTP_SESSION_MAGIC): New.
9898         (http_session_s): New field 'magic'.
9899         (HTTP_CONTEXT_MAGIC): New.
9900         (http_context_s): New field 'magic'.
9901         (my_ntbtls_verify_cb): Assert MAGIC.
9902         (fp_onclose_notification): Ditto.
9903         (session_unref): Ditto.  Reset MAGIC.
9904         (http_session_new): Set MAGIC.
9905         (http_open): Ditto.
9906         (http_raw_connect): Ditto.
9907         (http_close): Assert MAGIC.  Reset MAGIC.
9908
9909         * dirmngr/t-http.c (my_http_tls_verify_cb): MArk HTTP_FLAGS unused.
9910
9911 2017-02-21  NIIBE Yutaka  <gniibe@fsij.org>
9912
9913         g10: Support primary key generation by keygrip.
9914         + commit 3fc69224b7b22ad1df1395ebcb21549384839cd1
9915         * g10/keygen.c (para_name): Add pKEYGRIP.
9916         (generate_keypair): Use pKEYGRIP for key generation.
9917         (do_generate_keypair): Call do_create_from_keygrip with pKEYGRIP.
9918
9919 2017-02-20  Werner Koch  <wk@gnupg.org>
9920
9921         dirmngr: Setup a log handler for ntbtls.
9922         + commit a022baa4a487eec769411255a64088450c4c8a49
9923         * dirmngr/dirmngr.c (my_ntbtls_log_handler) [HTTP_USE_NTBTLS]: New.
9924         (main) [HTTP_USE_NTBTLS]: Register log handler.
9925
9926         common: New function log_logv_with_prefix.
9927         + commit 3e9512e557d95c7dc36835365b127b25f6a5cdd9
9928         * common/logging.c (do_logv): Add arg 'prefmt' and print it.  Chnage
9929         call callers to pass NULL.
9930         (log_logv_with_prefix): New.
9931
9932         dirmngr.c: Make http.c build without any TLS support.
9933         + commit e174893262d8de0f52faa8abe4fc0402719a35d8
9934         * dirmngr/http.c (http_session_new): Remove used of tls_prority.
9935
9936          dirmngr: Make t-http.c work again with gnutls - second try.
9937         + commit 81ea24b8637ac08e44e9e44816689413c2ae7e08
9938         * dirmngr/t-http.c: Always include ksba.h.
9939
9940         dirmngr: Make t-http.c work again with gnutls.
9941         + commit f923873863fd863d71349f20f5568f80aecc020b
9942         * dirmngr/Makefile.am (t_http_CFLAGS, t_http_LDADD): Add KSBA flags
9943         and libs.
9944
9945 2017-02-19  Werner Koch  <wk@gnupg.org>
9946
9947         dirmngr: First take on ntbtls cert verification.
9948         + commit 64fffd0ce2a4fd9cba152cf07497b585410cc652
9949         * dirmngr/http-ntbtls.c: New.
9950         * dirmngr/Makefile.am (dirmngr_SOURCES): Add file.
9951         * dirmngr/dirmngr.h (SERVER_CONTROL_MAGIC): New.
9952         (server_conrol_s): Add field 'magic',
9953         * dirmngr/dirmngr.c (dirmngr_init_default_ctrl): Set MAGIC.
9954         (dirmngr_deinit_default_ctrl): Set MAGIC to deadbeef.
9955         * dirmngr/http.c (my_ntbtls_verify_cb): New.
9956         (http_session_new) [HTTP_USE_NTBTLS]: Remove all CA setting code.
9957         (send_request) [HTTP_USE_NTBTLS]: Set the verify callback.  Do not call
9958         the verify callback after the handshake.
9959         * dirmngr/ks-engine-hkp.c (send_request): Pass
9960         gnupg_http_tls_verify_cb to http_session_new.
9961         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
9962
9963         * dirmngr/t-http.c (my_http_tls_verify_cb): New.
9964         (main): Rename option --gnutls-debug to --tls-debug.
9965         (main) [HTTP_USE_NTBTLS]: Create a session.
9966
9967 2017-02-18  Werner Koch  <wk@gnupg.org>
9968
9969         dirmngr: Add per-session verify callback to http.c.
9970         + commit a74902cccde539ee2bd216caec0da6eb54b67c1b
9971         * dirmngr/http.h (http_verify_cb_t): New type.
9972         * dirmngr/http.c (http_session_s): Add fields flags, verify_cb, and
9973         verify_cb_value.
9974         (http_session_new): Remove arg tls_priority.  Add args verify_cb and
9975         verify-cb_value.  Store them in the session object.
9976         (send_request): Use per-session verify callback.
9977         (http_verify_server_credentials) [HTTP_USE_NTBTLS]: Return
9978         GPG_ERR_NOT_IMPLEMENTED.
9979         * dirmngr/ks-engine-hkp.c (send_request): Adjust for changed
9980         http_session_new.
9981         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
9982         * dirmngr/t-http.c (main): Ditto.
9983
9984         * dirmngr/server.c (do_get_cert_local): Replace xmalloc by malloc.
9985
9986 2017-02-17  Werner Koch  <wk@gnupg.org>
9987
9988         dirmngr: Strip the default https port from the Host: header.
9989         + commit cd32ebd152a522e362469ab969d91f8d49f28a60
9990         * dirmngr/http.c (send_request): Strip the default https port.
9991
9992         dirmngr: Add option --no-crl to the VALIDATE cmd.
9993         + commit f07811ee2c0a8044551e2ec063eda61cff7f6e39
9994         * dirmngr/validate.h: Remove enums VALIDATE_MODE_*.
9995         (VALIDATE_FLAG_SYSTRUST, VALIDATE_FLAG_EXTRATRUST)
9996         (VALIDATE_FLAG_CRL, VALIDATE_FLAG_RECURSIVE)
9997         (VALIDATE_FLAG_OCSP, VALIDATE_FLAG_TLS)
9998         (VALIDATE_FLAG_NOCRLCHECK): New constants.
9999         * dirmngr/validate.c (validate_cert_chain): Change arg 'mode' to
10000         'flags'.  Change code accordingly.  Remove NO-CRL in TLS mode kludge.
10001         * dirmngr/crlcache.c (crl_parse_insert): Change to use flag values for
10002         the validate_cert_chain call.
10003         * dirmngr/server.c (cmd_validate): Ditto.  Add new option --no-crl.
10004
10005         dirmngr: Add options --tls and --systrust to the VALIDATE cmd.
10006         + commit 070211eb990f5ea41271eba432b6a6b485cef7c7
10007         * dirmngr/certcache.h (certlist_s, certlist_t): New.
10008         * dirmngr/certcache.c (read_certlist_from_stream): New.
10009         (release_certlist): New.
10010         * dirmngr/server.c (MAX_CERTLIST_LENGTH): New.
10011         (cmd_validate): Add options --tls and --systrust.  Implement them
10012         using a kludge for now.
10013         * dirmngr/validate.c (validate_cert_chain): Support systrust
10014         checking.  Add kludge to disable the CRL checking for tls mode.
10015
10016         dirmngr: Remove use of hardcoded numbers in validate.
10017         + commit ed99af030d19305dd7cd41c41ac581306cb91fd5
10018         * dirmngr/validate.c (enum cert_usage_modes): New.
10019         (cert_usage_p): Change type of arg MODE.  Use enums instead of
10020         hardwired values.  Use a switch instead of tricky bit tests.
10021         (cert_use_cert_p, cert_use_ocsp_p, cert_use_crl_p): Adjust.
10022
10023         * dirmngr/validate.c (cert_usage_p): Rename to check_cert_usage.
10024         (cert_use_cert_p): Rename to check_cert_use_cert.
10025         (cert_use_ocsp_p): Rename to check_cert_use_ocsp.
10026         (cert_use_crl_p): Rename to check_cert_use_crl.
10027
10028         * dirmngr/validate.h (VALIDATE_MODE_CERT_SYSTRUST): New.
10029         (VALIDATE_MODE_TLS, VALIDATE_MODE_TLS_SYSTRUST): New.
10030
10031 2017-02-17  NIIBE Yutaka  <gniibe@fsij.org>
10032
10033         agent: No cards is not an error.
10034         + commit dea4b3c742acbd195d6ab12b279b4dda315f2582
10035         * agent/command-ssh.c (card_key_list): Care the case of no cards.
10036
10037         agent: Send back all public keys for available cards.
10038         + commit 3f4f64b6ac0d7160fd9e1301f95820894b219c3f
10039         * agent/call-scd.c (card_cardlist_cb, agent_card_cardlist): New.
10040         * agent/command-ssh.c (card_key_list): New.
10041         (ssh_handler_request_identities): Call card_key_list and loop for the
10042         list to send public keys for all available cards.
10043
10044 2017-02-17  Justus Winter  <justus@g10code.com>
10045
10046         gpgscm: Guard use of tagged expressions.
10047         + commit aab6ba0bb60528b9e816e430be51170cf39611b0
10048         * tests/gpgscm/init.scm (vm-history-print): Check that the tag added
10049         to expressions when parsing source files matches the expected format.
10050         * tests/gpgscm/lib.scm (assert): Likewise.
10051
10052 2017-02-17  NIIBE Yutaka  <gniibe@fsij.org>
10053
10054         scd: Fix RESET command handling (more).
10055         + commit 99d4dfe83661d05ef3a20ed04e6cec5647536738
10056         * scd/app-common.h (struct app_ctx_s): Add reset_requested.
10057         * scd/app.c (app_reset): Locking APP, set reset_requested.
10058         (deallocate_app): Release the lock.
10059         (release_application): Add LOCKED_ALREADY argument.
10060         (scd_update_reader_status_file): Hold the lock when accessing APP.
10061         When reset_requested is set, close the reader and deallocate APP.
10062         * scd/command.c (open_card_with_request, cmd_restart): Follow the
10063         change of release_application.
10064         (send_client_notifications): Here it calls release_application holding
10065         the lock.
10066
10067 2017-02-16  Werner Koch  <wk@gnupg.org>
10068
10069         dirmngr,w32: Load all system provided certificates.
10070         + commit 7006352da773d82c47797bbf11e570ecafac6501
10071         * dirmngr/certcache.c (CERTOPENSYSTEMSTORE) [W32]: New type.
10072         (CERTENUMCERTIFICATESINSTORE) [W32]: New type.
10073         (CERTCLOSESTORE) [W32]: New type.
10074         (load_certs_from_file) [W32]: Do not build.
10075         (load_certs_from_w32_store) [W32]: New.
10076         (load_certs_from_system) [W32]: Call new function.
10077
10078         dirmngr: Load all system provided certificates.
10079         + commit 9a1a5ca0bc2cfb17ccf632de3e134b6d789c6855
10080         * configure.ac: Add option --default-trust-store.
10081         (DEFAULT_TRUST_STORE_FILE): New ac_define.
10082         * dirmngr/certcache.c: Include ksba-io-support.h.
10083         (total_trusted_certificates, total_system_trusted_certificates): New.
10084         (put_cert): Manage the new counters.
10085         (cert_cache_deinit): Reset them.
10086         (cert_cache_print_stats): Print them.
10087         (is_trusted_cert): Add arg WITH_SYSTRUST.  Change all callers to pass
10088         false.
10089         (load_certs_from_file): New.
10090         (load_certs_from_system): New.
10091         (cert_cache_init): Load system certificates.
10092
10093         common: Rename remaining symbols in ksba-io-support.
10094         + commit e1dfd862367cf91b66abe86bd73664409354bb14
10095         * common/ksba-io-support.c (gpgsm_reader_eof_seen): Rename to ...
10096         (gnupg_ksba_reader_eof_seen): this.  Change all callers.
10097         (gpgsm_destroy_reader): Rename to ...
10098         (gnupg_ksba_destroy_reader): this.  Change all callers.
10099         (gpgsm_finish_writer): Rename to ...
10100         (gnupg_ksba_finish_writer): this.  Change all callers.
10101         (gpgsm_destroy_writer): Rename to ...
10102         (gnupg_ksba_destroy_writer): this.  Change all callers.
10103         * common/ksba-io-support.c (struct base64_context_s): Rename to ...
10104         (gnupg_ksba_io_s): this.
10105         * common/ksba-io-support.h (base64_context_s): Ditto.
10106         (Base64Context): Rename this typedef to ...
10107         (gnupg_ksba_io_t): this.  Change all users.
10108
10109         common: Remove gpgsm dependencies from ksba-io-support.
10110         + commit 28c31524be84f20b34573c78bd3a94a81e4b1d61
10111         * common/ksba-io-support.c: Include ksba-io-support.h instead of
10112         ../sm/gpgsm.h.  Include util.h.
10113         (writer_cb_parm_s): Remove const from 'pem_name'.
10114         (gpgsm_destroy_writer): Free 'pem_name'.
10115         (gpgsm_create_reader): Rename to ...
10116         (gnupg_ksba_create_reader): this.  Replace args CTRL and
10117         ALLOW_MULTI_PEM by a new arg FLAGS.  Change the code to evaluate
10118         FLAGS.  Change all callers to pass the FLAGS.
10119         (gpgsm_create_writer): Rename to ...
10120         (gnupg_ksba_create_writer): this.  Replace arg CTRL by new arg FLAGS.
10121         Add arg PEM_NAME.  Evaluate FLAGS.  Store a copy of PEM_NAME.  Change
10122         all callers to pass the FLAGS and PEM_NAME.
10123
10124         common: Change license of ksba-io-support.c.
10125         + commit 919e76b407ac557b0f518ec03f3cc59e9e5740c9
10126         * common/ksba-io-support.c: Change from GPLv3+ to LGPLv3+/GPLv2+.
10127
10128         sm,common: Move ksba reader and writer support to common/.
10129         + commit 04bfa6fe6597b8ffcec61cbcacdc7eb137444e80
10130         * sm/base64.c: Rename to ...
10131         * common/ksba-io-support.c: this.
10132         * common/ksba-io-support.h: New.
10133         * common/Makefile.am (common_sources): Add new files.
10134         * sm/Makefile.am (gpgsm_SOURCES): Remove base64.c
10135
10136         dirmngr: Prepare certcache for forthcoming changes.
10137         + commit 5c4e67afd6385b48065de6a0f2dd0bfd936ab90b
10138         * dirmngr/certcache.c (cert_item_s): Rename 'flags.loaded' to
10139         'flags.config'.  Add 'flags.systrust'.
10140         (total_loaded_certificates): Rename to total_config_certificates.
10141         (put_cert): Rename args for clarity.  Set SYSTRUST flag.
10142         (load_certs_from_dir): Make sure put_cert does not set the SYSTRUST
10143         flag.
10144
10145         dirmngr: Replace stpcpy chains by strconcat.
10146         + commit aef60abe6a1772e18634984a94bd70f57d57ccdd
10147         * dirmngr/certcache.c (find_cert_bysn): Use strconcat.
10148         (find_cert_bysubject): Ditto.
10149         * dirmngr/http.c (store_header): Ditto.
10150         * dirmngr/ldap.c (make_url): Ditto.
10151         * dirmngr/server.c (get_cert_local_ski): Ditto.
10152         (do_get_cert_local): Use xstrconcat.
10153
10154 2017-02-16  NIIBE Yutaka  <gniibe@fsij.org>
10155
10156         scd: Minor fixes to silence compiler warnings.
10157         + commit 7a666ccb44f43c4efbaa51c1ca16fc0b37c3399d
10158         * scd/app.c (app_reset): Initialize ERR.
10159         * scd/scdaemon.c (scd_kick_the_loop, handle_connections): Catch the
10160         return value.
10161
10162 2017-02-15  Werner Koch  <wk@gnupg.org>
10163
10164         libdns: Workaround for bracketed numerical addresses.
10165         + commit a3509e12b6626a585ce7da6ceed8cfddcba2460f
10166         * dirmngr/dns-stuff.c (resolve_name_libdns): Work around an
10167         incompatibility between the glibc resolver and libdns.
10168
10169         dirmngr: Do PTR lookups only for 'keyserver --hosttable'.
10170         + commit a75325faf163275674a91971e75f1018035ca348
10171         * dirmngr/ks-engine-hkp.c (hostinfo_s): Remove fields v4addr and
10172         v5addr and add fields iporname and iporname_valid.
10173         (create_new_hostinfo): Clear them.
10174         (add_host): Remove the code to set the v4addr and v6addr fields.
10175         (ks_hkp_print_hosttable): Remove printing of the fields.  Compute the
10176         iporname field and display it.
10177         (ks_hkp_reload): Force re-computing of the iporname field in
10178         ks_hkp_print_hosttable.
10179
10180         dirmngr: Avoid PTR lookup for hosts in a pool.
10181         + commit da2ba20868093e3054d18adc2b1bc56cb23e4ba7
10182         * dirmngr/ks-engine-hkp.c (add_host): Don't to a PTR lookup for hosts
10183         in a pool.
10184
10185 2017-02-15  Justus Winter  <justus@g10code.com>
10186
10187         tests,build: Fix distcheck.
10188         + commit 2f7b6cb279ea0ee27364fbb2b12df47e76166a39
10189         * tests/gpgscm/Makefile.am (EXTRA_DIST): Add 'time.scm'.
10190
10191         tests: Test and document other ways to create keys.
10192         + commit 90d383f1eb07fc823518dea10eb15ca390f5cf8e
10193         * doc/gpg.texi: Clarify usage and expiration arguments for key
10194         generation.
10195         * tests/openpgp/quick-key-manipulation.scm: Test all variants.
10196
10197         tests: Check expiration times of created keys.
10198         + commit 127e1e532da4083ccd3c307555b6177fab16f408
10199         * tests/gpgscm/ffi.c (do_get_time): New function.
10200         (ffi_init): Expose new function.
10201         * tests/gpgscm/ffi.scm (get-time): Document new function.
10202         * tests/gpgscm/time.scm: New file.
10203         * tests/openpgp/quick-key-manipulation.scm: Use the new facilities to
10204         check the expiration times of created keys.
10205         * tests/openpgp/tofu.scm: Use the new module.
10206
10207 2017-02-15  NIIBE Yutaka  <gniibe@fsij.org>
10208
10209         scd: Fix RESET command handling.
10210         + commit e2792813a55e091c51be7b1b089a71beb6466f1d
10211         * scd/app.c (release_application_internal): Remove.
10212         (release_application): Merge release_application_internal.
10213         (app_reset): Kick the loop and let close the reader.  Sleep is
10214         required here to wait closing.
10215         (scd_update_reader_status_file): When APP is no use, close it.
10216
10217 2017-02-14  Werner Koch  <wk@gnupg.org>
10218
10219         gpg: Make --export-ssh-key work for the primary key.
10220         + commit b456e5be91dc064fc9509ea86edab113721ed299
10221         * g10/export.c (export_ssh_key): Also check the primary key.
10222
10223 2017-02-13  Werner Koch  <wk@gnupg.org>
10224
10225         dirmngr: Do a DNS lookup even if it is missing from nsswitch.conf.
10226         + commit dee026d761ae3d7594c3dbc5b3fa842df53cc189
10227         * dirmngr/dns-stuff.c (libdns_init): Do not print error message for a
10228         missing nsswitch.conf.  Make sure that tehre is a DNS entry.
10229
10230         gpgconf: No ENOENT warning with --change-options et al.
10231         + commit 30dac0486b6357e84fbe79c612eea940b654e4d1
10232         * tools/gpgconf-comp.c (retrieve_options_from_program): Check ERRNO
10233         before printing a warning.
10234
10235         gpg: Print a warning if no command has been given.
10236         + commit 810adfd47801fc01e45fb71af9f05c91f7890cdb
10237         * g10/gpg.c (main): Print in the default case.
10238
10239 2017-02-13  Justus Winter  <justus@g10code.com>
10240
10241         g13: Fix build on macOS.
10242         + commit f8ce31a7bf1ee85e5010b628a66e6f69486e5213
10243         * g13/Makefile.am (t_common_ldadd): Add iconv.
10244
10245 2017-02-13  NIIBE Yutaka  <gniibe@fsij.org>
10246
10247         scd: Fix use case of PC/SC.
10248         + commit da4c132cca2c6df81243c9660b7348268a848f88
10249         * scd/apdu.c (apdu_open_reader): Add an argument APP_EMPTY.
10250         When CCID driver fails to open, try PC/SC if APP is nothing.
10251         * scd/app.c (select_application): Supply arg if APP is nothing.
10252
10253 2017-02-10  Werner Koch  <wk@gnupg.org>
10254
10255         gpg: Fix memory leak in the error case of signature creation.
10256         + commit 5996c7bf99f3a681393fd9589276399ebc956cff
10257         * g10/sign.c (write_signature_packets): Free SIG.  Also replace
10258         xcalloc by xtrycalloc.
10259
10260 2017-02-08  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
10261
10262         common: Avoid warning about implicit declaration of gnupg_fd_valid.
10263         + commit 8810314e377a9cb6612150a57cf99260ed0bb9f6
10264         * common/logging.c: Add #include "sysutils.h".
10265
10266 2017-02-08  Justus Winter  <justus@g10code.com>
10267
10268         gpg,common: Make sure that all fd given are valid.
10269         + commit 6823ed46584e753de3aba48a00ab738ab009a860
10270         * common/sysutils.c (gnupg_fd_valid): New function.
10271         * common/sysutils.h (gnupg_fd_valid): New declaration.
10272         * common/logging.c (log_set_file): Use the new function.
10273         * g10/cpr.c (set_status_fd): Likewise.
10274         * g10/gpg.c (main): Likewise.
10275         * g10/keylist.c (read_sessionkey_from_fd): Likewise.
10276         * g10/passphrase.c (set_attrib_fd): Likewise.
10277         * tests/openpgp/Makefile.am (XTESTS): Add the new test.
10278         * tests/openpgp/issue2941.scm: New file.
10279
10280 2017-02-07  Justus Winter  <justus@g10code.com>
10281
10282         tests: Skip key types not supported by OpenSSH.
10283         + commit 56aa85f88f6b35fb03a2dc1a95882d49a74290e3
10284         * tests/openpgp/ssh-import.scm (path): New variable.
10285         (ssh,ssh-keygen,ssh-version,ssh-supports?): Likewise.
10286
10287 2017-02-07  Werner Koch  <wk@gnupg.org>
10288
10289         wks: Add WKS-Phase headers to the server messages.
10290         + commit b30ac663cec82c89ca9a3e87e65b36d2552f1533
10291         * tools/gpg-wks-server.c (send_confirmation_request): Add custom
10292         header.
10293         (send_congratulation_message): Ditto.
10294
10295 2017-02-05  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
10296
10297         po: Manual updates of nl translation.
10298         + commit aa3f08794bfc809821e2fc30a09a5ae23925c645
10299         * po/nl.po: Apply several minor manual cleanups to nl.po that were
10300         previously applied to all the other localizations.
10301
10302         po: Copied missing nl.po translation from the 2.0 branch.
10303         + commit 8a9d4b55b09d04482b46055f0a60f01b86738df3
10304         * po/nl.po: Copy from 2.0 branch.
10305
10306         gpg: Fix aliases --list-key, --list-sig, and --check-sig.
10307         + commit f31120a5aa40b6e4e89d41d1d5d34e0f7da173b4
10308         * g10/gpg.c (opts): Define commands with ARGPARSE_c
10309         instead of ARGPARSE_s_n.
10310
10311 2017-02-04  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
10312
10313         doc: Clarify abbreviation of --help.
10314         + commit f2b276dffbe2435b17abf2b3c51684d3636f3f11
10315         * doc/gpg.texi: clarify abbreviation of --help.
10316
10317 2017-02-03  Werner Koch  <wk@gnupg.org>
10318
10319         agent: Tell pinentry the hostname the agent is running on.
10320         + commit 042fe711c76f6377cedb8f83a73ba386cee34bb7
10321         * agent/call-pinentry.c [!W32]: Incluse utsname.h
10322         (start_pinentry): Pass nodename to OPTION/owner.
10323
10324         agent: Tell the Pinentry the client's pid.
10325         + commit 309f464a5952c7d7504b875bf4853914b1242346
10326         * configure.ac: Check for SO_PEERCRED et al.
10327         * agent/agent.h (server_control_s): Add field 'client_pid'.
10328         * agent/command.c (start_command_handler): Set CLIENT_PID.
10329         * agent/command-ssh.c (get_client_pid): New.
10330         (start_command_handler_ssh): Set CLIENT_PID.
10331         * agent/call-pinentry.c (start_pinentry): Tell Pinentry the client-pid.
10332
10333         gpg: More diagnostics for a launched pinentry.
10334         + commit 7052a0d77cf8f3a445b252a809d29be445788625
10335         * agent/call-pinentry.c (start_pinentry): Call getinfo/ttyinfo.
10336         * g10/server.c (gpg_proxy_pinentry_notify): Simplify the output so
10337         that we do not change the code when adding new fields to
10338         PINENTRY_LAUNCHED.
10339
10340 2017-02-02  Neal H. Walfield  <neal@g10code.com>
10341
10342         gpg: Don't assume that strtoul interprets "" as 0.
10343         + commit 407f5f9baea5591f148974240a87dfb43e5efef3
10344         * g10/tofu.c (show_statistics): If there are not records, return 0
10345         instead of NULL.
10346
10347         tests: Improve description of test.
10348         + commit 64be8e1e8607944687f3ae45ec64aa30bf4fdf6f
10349         * tests/openpgp/issue2929.scm: Improve description of test.
10350
10351         Revert "Revert "tests: Add test demonstrating issue2929.""
10352         + commit e596b21f4b78dd27489e677699cc4ba648051b3f
10353         This reverts commit 59048b0f1aa77313573a1004cd3a9f02692a7521.
10354
10355         gpg: Ensure TOFU bindings associated with UTKs are registered as usual.
10356         + commit 769272ba87f282a69e8d5f9bb27c86e6bec4496b
10357         * g10/tofu.c (get_trust): Call get_policy before short-circuiting the
10358         policy lookup for ultimately trusted keys to make sure the binding is
10359         added to the bindings table, if necessary.
10360
10361         gpg: If there is a TOFU conflict, elide the too few message warning.
10362         + commit a08c781739e7561093f32b732c4991f2bd817ec2
10363         * g10/tofu.c (tofu_get_validity): If there was a conflict, don't also
10364         print out a warning about too few messages.
10365
10366         gpg: Only print out TOFU statistics for conflicts in interactive mode.
10367         + commit 027b81b35fe36692005b8dba22d9eb2db05e8c80
10368         * g10/tofu.c (get_trust): Add arguments POLICYP and CONFLICT_SETP.  If
10369         they are not NULL, return the policy and conflict set (if there is
10370         one), respectively.  Update callers.  If MAY_ASK is FALSE, don't print
10371         out the statistics.
10372         (tofu_register_encryption): If there is a conflict and we haven't yet
10373         printed the statistics about the conflicting bindings, do so now.
10374         (tofu_get_validity): Likewise.
10375
10376         gpg: Add newline to output.
10377         + commit 74268180e5a3acc827f3a369f1fe5971f3bbe285
10378         * g10/tofu.c (ask_about_binding): Add newline to output.
10379
10380         gpg: Remove period at end of warning.
10381         + commit 6f9d8a956b2ca0f5a0eb7acc656fc17af2f2de47
10382         * g10/tofu.c (tofu_register_encryption): Remove period at end of
10383         warning.
10384
10385 2017-02-01  Werner Koch  <wk@gnupg.org>
10386
10387         dirmngr: New option --no-use-tor and internal changes.
10388         + commit 7440119e729d3fdedda8a9b44b70f8959beea8d7
10389         * dirmngr/dns-stuff.c (disable_dns_tormode): New.
10390         * dirmngr/dirmngr.c (oNoUseTor): New const.
10391         (opts): New option --no-use-tor.
10392         (tor_mode): New var.
10393         (parse_rereadable_options): Change to use TOR_MODE.
10394         (dirmngr_use_tor): New.
10395         (set_tor_mode): Call disable_dns_tormode.  Implement oNoUseTor.
10396         * dirmngr/dirmngr.h (opt): Remove field 'use_tor'.  Replace all
10397         references by a call to dirmngr_use_tor().
10398         * dirmngr/server.c (cmd_getinfo): Distinguish between default and
10399         enforced TOR_MODE.
10400
10401 2017-02-01  NIIBE Yutaka  <gniibe@fsij.org>
10402
10403         scd: Fix regression tracking the connection count.
10404         + commit 8ddc9268f6aedef0e178b174b89245c33d8189dd
10405         * scd/scdaemon.c (get_active_connection_count): New.
10406         (start_connection_thread): Bump ACTIVE_CONNECTIONS up and down.
10407         * scd/command.c (cmd_getinfo): Add subcommand "connections".
10408
10409 2017-01-31  Justus Winter  <justus@g10code.com>
10410
10411         gpgscm: Tune the hash tables.
10412         + commit 2e78aa6ff770849415f8eb71ca70c8886e9564c8
10413         * tests/gpgscm/scheme.c (oblist_initial_value): Increase the size of
10414         the hash table based on the number of symbols used after initializing
10415         the interpreter.
10416         (new_frame_in_env): Increase the size of the hash table based on the
10417         number of variables in the global environement.
10418
10419         gpgscm: Optimize environment lookups and insertions.
10420         + commit b85d509a8f5c2e6200b8051ca1593c019abce90b
10421         * tests/gpgscm/scheme.c (pointercmp): New function.
10422         (new_slot_spec_in_env): Add and use slot for insertions.
10423         (find_slot_spec_in_env): New variant of 'find_slot_in_env' that
10424         returns the slot on failures.
10425         (find_slot_in_env): Express using the new function.
10426         (new_slot_in_env): Update callsite.
10427         (opexe_0): Optimize lookup-or-insert.
10428         (opexe_1): Likewise.
10429         (scheme_define): Likewise.
10430
10431         gpgscm: Fix build with list environments.
10432         + commit 874424ee3cc795eae9972b6259a2cc4dcdbb868e
10433         * tests/gpgscm/scheme.c (new_slot_spec_in_env): Provide preallocation
10434         inforomation if USE_ALIST_ENV.
10435
10436         gpgscm: Optimize symbol lookups and insertions.
10437         + commit cea6d114b60deaecfbc2eb1aedbdfb7e6700922f
10438         * tests/gpgscm/scheme.c (oblist_find_by_name): Keep the list of
10439         symbols sorted, return the slot where a new symbol must be inserted on
10440         lookup failures.
10441         (oblist_add_by_name): Add the new symbol at the given slot.
10442         (mk_symbol): Adjust callsite.
10443         (gensym): Likewise.
10444         (assign_syntax): Likewise.
10445
10446         gpgscm: Fix build with object list.
10447         + commit 8f0ecb16cbb3798ad18be5f05b826db2aa1aaa00
10448         * tests/gpgscm/scheme.c (oblist_add_by_name): Provide preallocation
10449         information if USE_OBJECT_LIST.
10450
10451         gpgscm: Remove unused functions.
10452         + commit 2076cdaf6b93bc73223819895cc7a67323d8cee7
10453         * tests/gpgscm/scheme.c (check_cell_alloced): Remove function.
10454         (check_range_alloced): Likewise.
10455
10456 2017-01-31  Werner Koch  <wk@gnupg.org>
10457
10458         dirmngr: Require --allow-version-check even if --use-tor is used.
10459         + commit b0e8376e19072ec3c590273c69ab3e8e5edfdaca
10460         * dirmngr/dirmngr.c (housekeeping_thread): Load swdb only if the
10461         option is set.
10462
10463 2017-01-31  NIIBE Yutaka  <gniibe@fsij.org>
10464
10465         scd: Remove --debug-disable-ticker option.
10466         + commit e17fa5c75d76af4d4684ee810cb446ecd5110560
10467         * scd/scdaemon.c (ticker_disabled): Remove.
10468         (handle_tick, need_tick): Remove.
10469         (handle_connections): Don't check ticker_disabled.
10470
10471         scd: Fix SERIALNO for multiple devices.
10472         + commit f08d37af049bf1718b301644020658dd2bb07638
10473         * scd/app.c (select_application): Fix the logic if periodical check is
10474         needed.  If it is needed for newly found device(s), kick the loop.
10475         (scd_update_reader_status_file): Return value if select(2) should be
10476         called with timeout.
10477         * scd/ccid-driver.c (ccid_require_get_status): Don't return 0 for
10478         token with no interrupt transfer for now.
10479         * scd/command.c (open_card_with_request): Fix scan by SERIALNO.
10480         * scd/scdaemon.c (update_usb): Remove.
10481         (handle_connections): Evaluate need_tick after handle_tick.
10482
10483 2017-01-30  Justus Winter  <justus@g10code.com>
10484
10485         gpgscm: Use a compact vector representation.
10486         + commit 49e2ae65e892f93be7f87cfaae3392b50a99e4b1
10487         * tests/gpgscm/scheme-private.h (struct cell): Add a compact vector
10488         representation.
10489         * tests/gpgscm/scheme.c (vector_length): Use new representation.
10490         (vector_size): New macro.
10491         (get_vector_object): Use the new representation.
10492         (fill_vector): Likewise.
10493         (vector_elem): Likewise.
10494         (set_vector_elem): Likewise.
10495         (mark): Likewise.
10496         (gc): Likewise.  Be careful not to confuse immediate values for type
10497         flags.
10498         (finalize_cell): Vectors now require finalization.
10499
10500         gpgscm: Provide framework for immediate values.
10501         + commit e343984fc50e87830905614dc87f83f810551ad1
10502         * tests/gpgscm/scheme.c (IMMEDIATE_TAG): New macro.
10503         ({is,set,clr}_immediate): Likewise.
10504         (enum scheme_types): Make type tags disjoint from immediate values.
10505         (TYPE_BITS): We need one more bit now.
10506         (ADJ,T_MASKTYPE): Compute values.
10507
10508         gpgscm: Fix setting the line of the first gc reservation.
10509         + commit d27a4435bd8c0f0971d51ddf454422fc77d48271
10510         * tests/gpgscm/scheme.c (_gc_disable): Negate guard.
10511
10512         gpgscm: Introduce macro for the vector length.
10513         + commit 489edf84c9a9c2122cef1b4e678154521525b54a
10514         * tests/gpgscm/scheme.c (vector_length): New macro.
10515         (get_vector_object): Use the new macro.
10516         (oblist_add_by_name): Likewise.
10517         (oblist_find_by_name): Likewise.
10518         (oblist_all_symbols): Likewise.
10519         (mk_vector): Likewise.
10520         (mark): Likewise.
10521         (new_slot_spec_in_env): Likewise.
10522         (find_slot_spec_in_env): Likewise.
10523         (opexe_2): Likewise.
10524         (opexe_5): Likewise.
10525
10526         Revert "tests: Add test demonstrating issue2929."
10527         + commit 59048b0f1aa77313573a1004cd3a9f02692a7521
10528         This reverts commit 5aafa56dffefe3fac55b9d0555c7c86e8a07f072.
10529
10530 2017-01-30  NIIBE Yutaka  <gniibe@fsij.org>
10531
10532         scd: Fix GetSlotStatus.
10533         + commit 2a025039c1817c7f75c35a898884849a8e5dc926
10534         * scd/apdu.c (get_status_reader): Add ON_WIRE arg, here.
10535         (ct_get_status, pcsc_get_status_direct, pcsc_get_status_wrapped)
10536         (pcsc_get_status, get_status_ccid, my_rapdu_get_status): Likewise.
10537         (reset_pcsc_reader_wrapped, open_pcsc_reader_wrapped): Follow the
10538         change.
10539         (apdu_get_status_internal): It's lower-level driver which judge
10540         it's not needed.  Otherwise, it can't detect the removal.
10541         * scd/ccid-driver.c (ccid_slot_status): After the POWERED_OFF check,
10542         we can skip sending GetSlotStatus packet on wire, when no need.
10543
10544         scd: Don't send GET_STATUS packet if not needed.
10545         + commit 7c8eee4d396a751d41fd1ee1e1b87b851fca172a
10546         * scd/apdu.c (apdu_get_status_internal): Add ON_WIRE arg.
10547         (apdu_connect): Call apdu_get_status_internal with ON_WIRE enabled.
10548         (apdu_get_status): For periodical check, call apdu_get_status_internal
10549         with ON_WIRE disabled.
10550
10551         scd: Fix cancel INTERRUPT transfer.
10552         + commit 216afba0d99582d0fbae1d6e925f4ddb349d9de3
10553         * scd/ccid-driver.c (do_close_reader): Don't lock events, but check the
10554         return value of libusb_cancel_transfer.
10555
10556 2017-01-27  NIIBE Yutaka  <gniibe@fsij.org>
10557
10558         scd: More changes on watching removal of card/reader.
10559         + commit f3d9b2582bcaa1936b4fed5ec42a889b02df2f42
10560         * scd/app-common.h (struct app_ctx_s): Rename field to
10561         periodical_check_needed.
10562         * scd/scdaemon.c (update_usb): Rename from update_fdset_for_usb.
10563         Don't use libusb_get_pollfds any more.
10564         (scd_kick_the_loop): New.
10565         (need_tick): Follow the rename.
10566         (handle_connections): No libusb event handling here.
10567         * scd/app.c (app_new_register): Follow the change of rename.
10568         (select_application, scd_update_reader_status_file): Likewise.
10569         * scd/ccid-driver.c (ccid_usb_thread_is_alive): New.
10570         (intr_cb): Call scd_kick_the_loop.
10571         (ccid_usb_thread): New.  Thread to invoke INTERRUPT callback.
10572         (ccid_open_usb_reader): Add thread invocation.
10573         (ccid_require_get_status): Remove
10574         LIBUSB_WORKS_EXPECTED_FOR_INTERRUPT_ENDP.
10575         (do_close_reader): Carefully handle handle->transfer.
10576         (get_escaped_usb_string): Insert npth_unprotect/npth_protect.
10577         (do_close_reader, bulk_out, bulk_in, abort_cmd, ccid_slot_status)
10578         (ccid_transceive, ccid_transceive_secure): Likewise.
10579
10580         scd: Fix release of transfer object.
10581         + commit f92fe33f11c44f14fd31682259fcd231e8fa9e75
10582         * scd/ccid-driver.c (intr_cb): Handle LIBUSB_TRANSFER_CANCELLED.
10583         (do_close_reader): When callback is active, call
10584         libusb_cancel_transfer and wait callback is fired off.
10585
10586         scd: Improve watching USB device removal.
10587         + commit 25cc8575da9a9b8bf60c64c8059cb5f73cc52e1d
10588         * scd/apdu.c(struct reader_table_s): Add require_get_status.
10589         (apdu_connect): Change return value meaning.  Call apdu_reset here.
10590         * scd/app.c (app_new_register): Add require_get_status.
10591         (select_application): Use the return value of apdu_connect.
10592         (scd_update_reader_status_file): Call update_fdset_for_usb with
10593         checking all_have_intr_endp.
10594         (app_list_start, app_list_finish): Remove.
10595         * scd/ccid-driver.c (struct ccid_driver_s): Add transfer.
10596         (intr_cb): Don't call libusb_transfer in this callback.
10597         (ccid_require_get_status): New.
10598         (do_close_reader): Call libusb_transfer here.
10599         * scd/scdaemon.c (update_fdset_for_usb): Remove the first argument.
10600
10601         scd: Wake up the select when new USB scan.
10602         + commit 031e3fa7b9a6770a4de1a184555250feeba0d26f
10603         * scd/scdaemon.c (update_fdset_for_usb): Wake up the select(2).
10604         (handle_connections): Use a kind of "self-pipe" technique.
10605
10606 2017-01-26  NIIBE Yutaka  <gniibe@fsij.org>
10607
10608         scd: Only submit apdu_get_status when needed.
10609         + commit 881dcdfd84ebad36bff20c895e629025bed9d94e
10610         * scd/apdu.c (apdu_dev_list_finish): Return Boolean value if
10611         all device support INTERRUPT transfer.
10612         * scd/ccid-driver.c (ccid_dev_scan_finish): Likewise.
10613         * scd/app.c (app_new_register): Fix initial value of card_status.
10614         (select_application): Call update_fdset_for_usb.
10615         (scd_update_reader_status_file): Ditto.
10616         * scd/scdaemon.c (update_fdset_for_usb, need_tick): New.
10617         (handle_connections): Call handle_tick when select returns.
10618         Let select watch USB file descriptors, too.
10619         Call libusb_handle_events_timeout_completed for INTERRUPT transfer.
10620
10621         scd: Fix APP reference counting.
10622         + commit 9b06633c811e8815c07d744f20b45405cb082367
10623         * scd/app.c (scd_update_reader_status_file): Don't call another
10624         release_application_internal.
10625         * scd/command.c (open_card_with_request): Don't require APPTYPE !=
10626         NULL.
10627
10628         scd: Add INTERRUPT endp support to CCID driver.
10629         + commit bb5ceb78c333129a44c0144f2cf49b17ede898f1
10630         * scd/app.c (scd_update_reader_status_file): Fix releas of APP.
10631         * scd/ccid-driver.c (struct ccid_driver_s): Add INTR_BUF.
10632         (intr_cb, ccid_setup_intr): New.
10633         (ccid_open_usb_reader): Call ccid_setup_intr.
10634         (ccid_slot_status): Return CCID_DRIVER_ERR_NO_READER when removed.
10635
10636 2017-01-25  Justus Winter  <justus@g10code.com>
10637
10638         gpg: Fix searching for mail addresses in keyrings.
10639         + commit 3f4f20ee6eff052c88647b820d9ecfdbd8df0f40
10640         * g10/keyring.c (compare_name): Fix KEYDB_SEARCH_MODE_MAIL* searches
10641         in keyrings when the UID is a plain addr-spec.
10642
10643         tests,w32: Fix GPGME tests requiring a pinentry.
10644         + commit 02a39f0d1ed717f6fc33392e6ce4ab421c3bcbba
10645         * tests/gpgme/gpgme-defs.scm: Use our fake pinentry, and configure it
10646         to supply the correct passphrase.
10647
10648         tests,w32: Fix gpgsm signature verification test.
10649         + commit 7d5a0ed792133d875fcedb6e23a9a3682f1a23f9
10650         * tests/gpgsm/verify.scm: Use 'call-with-binary-output-file' to avoid
10651         automatic line-ending conversion.
10652
10653         agent: Fix double free.
10654         + commit e175152ef7515921635bf1e00383e812668d13fc
10655         * agent/cache.c (agent_store_cache_hit): Make sure the update is
10656         atomic.
10657
10658         tests: Skip GPGME tests that are not built.
10659         + commit 5f2da5d439debf44615a97de788d8f720b517972
10660         * tests/gpgme/wrap.scm: Skip tests that are not built.
10661
10662         tests,w32: Fix locating GPGME's tests on Windows.
10663         + commit 6ecd8b3e71632bbcca524ad735c83bdc2a4c4a4a
10664         * tests/gpgme/run-tests.scm: Qualify the test with the executable
10665         extension.
10666
10667 2017-01-24  Werner Koch  <wk@gnupg.org>
10668
10669         gpg: Print a warning on Tor problems.
10670         + commit 770b75a746836773909af25ccb9b480e61cea677
10671         * dirmngr/ks-engine-hkp.c (tor_not_running_p): New.
10672         (map_host): Call that to print a warning.
10673         (handle_send_request_error): Ditto and avoid marking the host dead.
10674         Also print a tor_config_problem warning.  Add arg CTRL; adjust callers
10675         to pass that new arg.
10676         * g10/call-dirmngr.c (ks_status_cb): Detect and print the new
10677         warnings.
10678
10679         dirmngr: Simplify error returning inside http.c.
10680         + commit 51e5a5e5a46279809848b4ab4419f35045336010
10681         * dirmngr/http.c (connect_server): Change to return an gpg_error_t
10682         and to store socket at the passed address.
10683         (http_raw_connect, send_request): Adjust accordingly.
10684
10685         dirmngr: New option --disable-ipv4.
10686         + commit 72736af86a501592d974d46ff754a63959e183bd
10687         * dirmngr/dirmngr.c (oDisableIPv4): New const.
10688         (opts): New option --disable-ipv4.
10689         (parse_rereadable_options): Set that option.
10690         * dirmngr/dirmngr.h (opt): New field 'disable_ipv4'.
10691         * dirmngr/dns-stuff.c (opt_disable_ipv4): bew var.
10692         (set_dns_disable_ipv4): New.
10693         (resolve_name_standard): Skip v4 addresses when OPT_DISABLE_IPV4 is
10694         set.
10695         * dirmngr/ks-engine-hkp.c (map_host): Ditto.
10696         (send_request): Pass HTTP_FLAG_IGNORE_IPv4 if opt.disable_v4 is set.
10697         * dirmngr/crlfetch.c (crl_fetch): Ditto.
10698         * dirmngr/ks-engine-finger.c (ks_finger_fetch): Ditto.
10699         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
10700         * dirmngr/ocsp.c (do_ocsp_request): Ditto.
10701
10702 2017-01-24  Justus Winter  <justus@g10code.com>
10703
10704         tools: Use platform abstraction for I/O.
10705         + commit 73d6572bd0f260c5aa1e191a1ba4859ec6fa262c
10706         * tools/gpg-connect-agent.c (main): Use a gpgrt_stream_t for
10707         'script_fp'.  Adapt accordingly.
10708
10709         tools: Use platform abstraction for I/O.
10710         + commit 77b8aff4e1bb641f497e63230a5006ab70e6c3a8
10711         * tools/gpgconf-comp.c (retrieve_options_from_file): Use a
10712         gpgrt_stream_t for 'list_file'.  Adapt accordingly.
10713         (copy_file): Likewise for 'src' and 'dst'.
10714         (change_options_file): Likewise for 'src_file' and 'dest_file'.
10715         (change_options_program): Likewise for 'src_file' and 'dest_file'.
10716         (gc_process_gpgconf_conf): Likewise for 'config'.
10717
10718         tools: Use platform abstraction for renaming files.
10719         + commit bfd75e9492fc4edd86f4049a62304943a7b2a29a
10720         * tools/gpgconf-comp.c (gc_component_change_options): Use
10721         'gnupg_rename_file'.  Also, block signals across all renames in an
10722         attempt to make the whole process atomic.
10723
10724         tools: Add comments explaining the functions parameters.
10725         + commit 82e309ad06884e54693f4856412984331febdda0
10726         * tools/gpgconf-comp.c (change_options_file): Add comments explaining
10727         the functions parameters.
10728         (change_options_program): Likewise.
10729
10730         tools: Improve error handling.
10731         + commit b0348fdb26637b0bcbd68a96c1746a1613b309af
10732         * tools/gpgconf-comp.c (gp_component_change_options): Improve error
10733         handling when reading from stdin.
10734
10735         tools: Fix memory leak.
10736         + commit 5b28f025085b386e0ec49535d4cd3f875a414eb0
10737         * tools/gpgconf-comp.c (change_options_file): Fix leak.
10738
10739         tests: Add test demonstrating issue2929.
10740         + commit 5aafa56dffefe3fac55b9d0555c7c86e8a07f072
10741         * tests/openpgp/Makefile.am (XTESTS): Add new test.
10742         * tests/openpgp/issue2929.scm: New file.
10743
10744         tests: Enable gpgconf test.
10745         + commit 628ff843466b42309f850b8d65b13cf5f586b81f
10746         * tests/openpgp/Makefile.am (XTESTS): Re-add gpgconf.scm.
10747
10748 2017-01-23  Werner Koch  <wk@gnupg.org>
10749
10750         Release 2.1.18.
10751         + commit f8289b1d28f501d2f37bf9ccb5e42f7fb27b4688
10752
10753
10754         build: Change make distcheck configure and temp. remove gpgconf.scm.
10755         + commit 25e029823813e190a18b601af60efcb1fb3b84af
10756         * Makefile.am (DISTCHECK_CONFIGURE_FLAGS): Also test gpgtar and
10757         wks-tools.  Disable ntbtls.
10758         * tests/openpgp/Makefile.am (XTESTS): Temporary remove gpgconf.scm.
10759
10760         Fix format string errors and some missing error case initialization.
10761         + commit af5979a42b9468ffe0f3ac6de5a77d982c5cf8a0
10762         * common/logging.c (do_logv): Remove extra parentheses in comparison.
10763
10764         * dirmngr/dns-stuff.c (resolve_addr_libdns): Init RES so that
10765         dns_res_close is given a defined value in the error case.
10766
10767         * dirmngr/http.c (cookie_read, cookie_write) [HTTP_USE_NTBTLS]: Fix
10768         format string char.
10769
10770         * dirmngr/ks-engine-hkp.c (ks_hkp_help): Remove duplicate "const".
10771         * dirmngr/ks-engine-http.c (ks_http_help): Ditto.
10772         * dirmngr/ks-engine-kdns.c (ks_kdns_help): Ditto.
10773         * dirmngr/ks-engine-ldap.c (ks_ldap_help): Ditto.
10774
10775         * scd/app-p15.c (send_keypairinfo, do_getattr): Fix format string
10776         char.
10777         * tools/gpgconf-comp.c (gpg_agent_runtime_change): Init PID for the
10778         error case.
10779         (scdaemon_runtime_change): Ditto.
10780         (dirmngr_runtime_change): Ditto.
10781
10782         * tools/gpgconf.c (query_swdb): Init VALUE_SIZE_UL.
10783
10784         dirmngr: On SIGHUP mark all keyservers alive.
10785         + commit 3ca3da8fc4ef802b8cceec5fde398a07b4888848
10786         * dirmngr/ks-engine-hkp.c (ks_hkp_reload): New.
10787         * dirmngr/dirmngr.c (dirmngr_sighup_action): Call it.
10788
10789 2017-01-23  Gaetan Bisson  <bisson@archlinux.org>
10790
10791         libdns: Hack to skip negation term.
10792         + commit d4c0187dd93163f12e9f953366adef81ecf526a6
10793         * dirmngr/dns.c (dns_nssconf_loadfile): Skip negation terms in
10794         nsswitch.conf parser.
10795
10796 2017-01-23  Werner Koch  <wk@gnupg.org>
10797
10798         dirmngr: Print debug message only with --debug.
10799         + commit 9ae0b81e4ff08712da642456d0164f81924a91e4
10800         * dirmngr/dns-stuff.c (libdns_init): Call log_debug only if opt_debug
10801         is set.
10802
10803 2017-01-23  Phil Pennock  <gnupg-devel@spodhuis.org>
10804
10805         dirmngr: Handle missing nsswitch.conf.
10806         + commit 88ade475c56ac3712d6bd6d41ae38e1421dcb320
10807         * dirmngr/dns-stuff.c (libdns_init): Fallback to files,dns.
10808
10809 2017-01-23  Damien Goutte-Gattat  <dgouttegattat@incenp.org>
10810
10811         gpg: Fix misleading log message when checking regexp.
10812         + commit a85731ada2d361eacddc5ae92f80d34792dd4b5e
10813         * src/trustdb.c (check_regexp): Correctly print whether the
10814         regexp matched or not.
10815
10816 2017-01-23  Werner Koch  <wk@gnupg.org>
10817
10818         gpg: New export and import options "backup" and "restore".
10819         + commit 953d4ec6afd1b42feb7465ee57e48d72f033019a
10820         * g10/export.c (parse_export_options): Add "backup" and its alias
10821         "export-backup".
10822         (do_export_one_keyblock): Export ring trust packets in backup mode.
10823         * g10/import.c (parse_import_options): Add "restore" and its alias
10824         "import-restore".
10825         (read_block): Import ring trust packets.
10826
10827 2017-01-23  NIIBE Yutaka  <gniibe@fsij.org>
10828
10829         scd: Fix INTERRUPT transfer.
10830         + commit 21c9ebb908c2ad2e322e7a13e59e5880494c4d67
10831         * scd/ccid-driver.c (find_endpoint): Don't return Bulk endpoint as
10832         Interrupt endpoint.
10833         (ccid_poll): Call libusb_interrupt_transfer.
10834
10835 2017-01-19  Werner Koch  <wk@gnupg.org>
10836
10837         build: Print a commit id in the generated ChangeLog.
10838         + commit e926f30a1cda75f6334b79c303b5134f0441a3dc
10839         * build-aux/gitlog-to-changelog: Print an extra line with the commit
10840         id.
10841
10842         common: Fix buffer copy code again.
10843         + commit e031b3c16cfec583c4322c84d299b355f0849c77
10844         * common/exectool.c (my_error_from_errno): Remove.
10845         (copy_buffer_do_copy): Do without var RC.
10846         (copy_buffer_flush): Ditto.  Use ERRNO instead of es_write return
10847         code.
10848         (gnupg_exec_tool): Correctly return errors from es_read.
10849
10850 2017-01-19  Damien Goutte-Gattat  <dgouttegattat@incenp.org>
10851
10852         gpg: Allow to freeze faked system time.
10853         + commit 3daeef702b2e6a42f0f396b828f86ffc3f33fc88
10854         * g10/gpg.c (main): If the parameter for --faked-system-time
10855         ends with a '!', freeze time at the specified point.
10856         * common/gettime.c (gnupg_set_time): Allow to freeze the time
10857         at an arbitrary time instead of only the current time.
10858         * doc/gpg.texi: Update documentation for --faked-system-time.
10859
10860 2017-01-19  Werner Koch  <wk@gnupg.org>
10861
10862         common: Clarify use of vars in buffer copy code.
10863         + commit 55c9212a2338bf0b07c8cf3a69bcedaa28d48d43
10864         * common/exectool.c (my_error_from_errno): New.
10865         (copy_buffer_do_copy): Use separate vars for errno values and
10866         gpg-error values for clarity.  s/assert/log_assert/.
10867         (copy_buffer_flush): Ditto.
10868         (gnupg_exec_tool_stream): Use gpg_err_code when testing.
10869
10870 2017-01-19  NIIBE Yutaka  <gniibe@fsij.org>
10871
10872         dirmngr: Add setup of CA for NTBTLS.
10873         + commit 367349b4dcc97718f8ae1163d1389d2a46fc3453
10874         * dirmngr/http.c [HTTP_USE_NTBTLS] (http_session_new): Add CA by
10875         ntbtls_set_ca_chain.
10876
10877 2017-01-18  Justus Winter  <justus@g10code.com>
10878
10879         common: Fix flushing copy buffers.
10880         + commit 34fa2d79a07a079be472c3ff486debfdac8c6070
10881         * common/exectool.c (copy_buffer_flush): Write and flush the data, but
10882         do not hide EAGAIN from the caller.
10883         (gnupg_exec_tool_stream): Retry on EAGAIN.
10884
10885 2017-01-18  Werner Koch  <wk@gnupg.org>
10886
10887         agent: Reduce sleep time in the progress callback.
10888         + commit 3d356d165aed7d76a3ea811b1d24ed0a05ac90d4
10889         * agent/gpg-agent.c (agent_libgcrypt_progress_cb): Reduce sleep time
10890         from 100ms to 1ms or use gpgrt_yield when build against a recent
10891         libgpg-error.
10892
10893         gpgconf: Allow "all" for --launch, --kill, and --reload.
10894         + commit 2312248b2e3adffa52d8a3ac4f24fe2c88f0f569
10895         * tools/gpgconf-comp.c (gc_component_launch): Allow -1 for COMPONENT.
10896         (gc_component_kill): Ditto.
10897         (gc_component_reload): For robustness change the condition to < 0.
10898         * tools/gpgconf.c (main) <aLaunch, aKill, aReload>: Support argument
10899         "all".
10900
10901         gpg: Remove unused definitions.
10902         + commit 701f54eccf3da3319dd6d74f46b852c64d90bc52
10903         * g10/keydb.h (rt_UNKNOWN, rt_RING): Remove constants.
10904         (keyblock_pos_struct, KBPOS): Remove struct and type.
10905
10906 2017-01-18  NIIBE Yutaka  <gniibe@fsij.org>
10907
10908         scd: Cleanup SERIALNO protocol.
10909         + commit 79cea89774e6327b6785e22b7057f9e3e188ac2b
10910         * scd/app.c (app_get_serial_and_stamp): Remove.
10911         (app_get_serialno): New.
10912         (app_write_learn_status): Use send_status_direct.
10913         (app_getattr): Use app_get_serialno for SERIALNO and
10914         send with send_status_direct.
10915         * scd/app-openpgp.c (do_getattr): Likewise.
10916         * scd/command.c (cmd_serialno): Don't send TIMESTAMP of 0.
10917         (cmd_learn): Likewise.  Don't inquire with TIMESTAMP of 0.
10918
10919         scd: Add "card_list" sub command for GETINFO.
10920         + commit 8b1f24a29ebc7651437c01990215a55b1136dae0
10921         * scd/app.c (app_send_card_list): New.
10922         * scd/command.c (cmd_getinfo): Fix "status" sub command.
10923         Add "card_list" sub command.
10924
10925 2017-01-17  Werner Koch  <wk@gnupg.org>
10926
10927         build: Handle packages with dashes in --find-version.
10928         + commit a09f258b1412209763222e2e81bab79663e4d685
10929         * autogen.sh (--find-version): Improve version extraction.
10930         * (--help): Extend.
10931
10932         gpg: Clean bogus subkey binding when cleaning a key.
10933         + commit 356323768a1a29138581d0aceed0336ab8be0d5c
10934         * g10/trust.c (clean_key): Also clean bogus subkey bindings.
10935
10936         gpg: Sync print of additional sig data in --edit-key.
10937         + commit 766c25018b288a7185c6da6adac0dec01a64e94a
10938         * g10/keylist.c (show_policy_url): Implement MODE -1.
10939         (show_keyserver_url): Ditto.
10940         (show_notation): Ditto.
10941         * g10/keyedit.c (print_one_sig): Print policy URL, keyserver URL and
10942         notation data to the tty.
10943
10944         common: Remove unused function tty_print_string.
10945         + commit bae42e543799a428e59bad870aed9719dd6e6e45
10946         * common/ttyio.c (tty_print_string): Rename to ...
10947         (do_print_string): this.  Make local.  Simplify FP case by using
10948         print_utf8_buffer.  Change caller.
10949
10950         gpg: Prepare some key cleaning function for use with secret key packets.
10951         + commit adbfbf608e75cdd72ae7b3a538b91bc0e236a18f
10952         * g10/trust.c (mark_usable_uid_certs): Allow use of secret key packets.
10953         (clean_sigs_from_uid): Ditto.
10954         (clean_uid_from_key): Ditto.
10955         (clean_one_uid): Ditto.
10956         (clean_key): Ditto.
10957
10958 2017-01-16  Werner Koch  <wk@gnupg.org>
10959
10960         dirmngr: Implement hkps lookups using literal addresses.
10961         + commit e6aebfe3d0f16c483296fd125b66a44017fe15f4
10962         * dirmngr/ks-engine-hkp.c (map_host): For literal addresses do a
10963         reverse lookup.
10964
10965         dirmngr: Allow reverse DNS lookups in Tor-mode.
10966         + commit 9850124c7bdf0a0e7c1866abc85f3437257d7095
10967         * dirmngr/dns-stuff.c (resolve_dns_name): Move up in the file.
10968         (resolve_addr_libdns): New.
10969         (resolve_dns_addr): Divert to resolve_dns_addr.
10970
10971         dirmngr: Avoid network queries for literal IP addresses.
10972         + commit daae97bc14742c75408c4eb05808a2102cfe2bcf
10973         * dirmngr/dns-stuff.c (resolve_name_libdns): USe flags AI_NUMERICHOST
10974         for literal IP addresses.
10975         (resolve_name_standard): Ditto.
10976
10977         dirmngr: Fix URL creation for literal IPv6 addresses in HKP.
10978         + commit 82646bbf1a5a7d745da81b239a12667a51703dc1
10979         * dirmngr/dns-stuff.c (is_ip_address): Make the return value depend on
10980         the address family.
10981         * dirmngr/ks-engine-hkp.c (map_host): Rename arg R_POOLNAME to
10982         R_HTTPHOST because that is its purpose.  Note that the former
10983         behaviour of storing a NULL to indicate that it is not a pool has not
10984         been used.
10985         (make_host_part): Ditto.
10986         (make_host_part): Make sure that literal v6 addresses are correclty
10987         marked in the constructed URL.
10988
10989 2017-01-16  Justus Winter  <justus@g10code.com>
10990
10991         tests: Improve GPGHOME handling.
10992         + commit 8b1611a9605b636db3e07a9d81016a11b318724c
10993         * tests/openpgp/defs.scm (GPGHOME): New variable.
10994         * tests/openpgp/ssh-import.scm: Remove redundant code, use 'path-join'.
10995         * tests/openpgp/tofu.scm: Likewise.
10996
10997 2017-01-16  NIIBE Yutaka  <gniibe@fsij.org>
10998
10999         agent: Ask specific SERIALNO for pksign/pkdecrypt.
11000         + commit 0801f49b0dc7102943f0e9fa51061f50f5708ca6
11001         * agent/call-scd.c (agent_card_serialno): Add DEMAND argument.
11002         * agent/command-ssh.c (card_key_available): Follow the change.
11003         * agent/learncard.c (agent_handle_learn): Likewise.
11004         * agent/divert-scd.c (ask_for_card): Use DEMAND argument.
11005
11006         scd: Add --demand option for SERIALNO.
11007         + commit 2e6f1c99d4f66a23a752092397e20a84964edf48
11008         * scd/app.c (select_application): Add SERIALNO_BIN and SERIALNO_BIN_LEN
11009         arguments.  Return matched APP with a serial number when specified.
11010         * scd/command.c (open_card): Modify for the implicit open only.
11011         (open_card_with_request): New for explicit open and support match with a
11012         serial number.
11013         (cmd_serialno): Support --demand option.
11014         (cmd_learn, cmd_readcert, cmd_readkey, cmd_pksign, cmd_pkauth)
11015         (cmd_pkdecrypt, cmd_getattr, cmd_setattr, cmd_writecert, cmd_writekey)
11016         (cmd_genkey, cmd_random, cmd_passwd, cmd_checkpin, cmd_apdu): Follow
11017         the change of open_card.
11018
11019 2017-01-12  Werner Koch  <wk@gnupg.org>
11020
11021         build: Make autogen.sh more POSIX friendly (next try)
11022         + commit 3db76c9277d918dec9721a6439f4db3b3c06aba3
11023         * autogen.sh: Fix dd count to 5.
11024
11025         gpg: Rename a var to avoid a shadowing warning.
11026         + commit c99a09f111c5980ae034faaea61a00d9ad60463c
11027         * g10/keygen.c (keygen_set_std_prefs): Rename variable.
11028
11029         tests: Fix t-gettime for a time_t of 64 and a long of 32 bit.
11030         + commit 5c0777e1ca02ff1767755c417b64d6f78e02f475
11031         * configure.ac (AC_CHECK_HEADERS): Add stdint.h.
11032         * common/t-gettime.c: Include stdint.h.
11033         (UINTMAX_C): Define replacement.
11034         (test_isotime2epoch): Use UINTMAX_C for the >32 bit constants.
11035
11036         build: Make autogen.sh more POSIX friendly.
11037         + commit 3c00b52f7cb0fbd756c0bbe5134b8f2d69c60dd1
11038         * autogen.sh: Replace non POSIX "cp -a" and "head -c".
11039
11040         libdns: Silence -Wstrict-prototypes on some function ptrs.
11041         + commit 97372b39cd9b4c84a083eadbf072fff77799617f
11042         * dirmngr/dns.c (dns_rrtype): Ignore -Wstrict-prototypes warning.
11043
11044         libdns: Provide replacement for EPROTO.
11045         + commit 0fadff9cdde47e42f7e428bc903b3626c67ba9c0
11046         * dirmngr/dns.c (EPROTO) ![EPROTO]: Define to EPROTONOSUPPORT.
11047
11048 2017-01-11  Werner Koch  <wk@gnupg.org>
11049
11050         dirmngr: After a connection failure log a hint if Tor is not running.
11051         + commit 20dfcfe08c618d23134d5d6efef7676b090f30d3
11052         * dirmngr/ks-engine-hkp.c (handle_send_request_error): Check whether
11053         Tor is running.
11054
11055         dirmngr: Mark hosts dead on ENETDOWN.
11056         + commit 76fb2febde10da8237bbe7613830b51af2a45139
11057         * dirmngr/ks-engine-hkp.c (handle_send_request_error): Take care of
11058         ENETDOWN.
11059
11060         dirmngr: Fix Tor access for v6 addresses.
11061         + commit 09aeac41c97bc8ecb44a09886c7fdbd9a6ec5c7f
11062         * dirmngr/http.c (use_socks): New.
11063         (my_sock_new_for_addr): New.
11064         (connect_server): Replace assuan_sock_new by my_sock_new_for_addr.
11065
11066         dirmngr: Remove warnings about unused global variables.
11067         + commit 915864e7f0315b0c96315d0bcd48b1b93592353a
11068         * dirmngr/crlcache.c (oidstr_issuingDistributionPoint): Comment.
11069         * dirmngr/ocsp.c (oidstr_certHash): Comment.
11070
11071         dirmngr: Implement debug option "network" for http.
11072         + commit da894c48ec3393e7c815f575daa5a52ab37cc102
11073         * dirmngr/dirmngr.c (parse_rereadable_options): Set http debugging.
11074
11075         dirmngr: Add debug code to http.c.
11076         + commit 02ab4b0085f8b4cdfe163d25ddd0fc80753d7f4a
11077         * dirmngr/http.c (opt_verbose, opt_debug): New vars.
11078         (http_set_verbose): New function.
11079         (_my_socket_new): Add debug output.
11080         (_my_socket_ref, _my_socket_unref, session_unref): Call log_debug if
11081         OPT_DEBUG has ben set to 2 in a debugger.
11082         (http_session_new, http_session_ref): Ditto.
11083         (send_request, http_start_data): Print debug output for the request.
11084         (parse_response): Change to use log_debug_string for the response.
11085
11086         common: New function log_debug_with_string.
11087         + commit 088d71d3671e74eb088386026f0e439a7e3b5543
11088         * common/logging.c (do_logv): Factor some code out to ...
11089         (print_prefix): new.
11090         (log_logv): Add arg EXTRASTRING and print it.  Change all callers to
11091         pass NULL for it.
11092         (log_debug_with_string): New.  Uses EXTRASTRING.
11093
11094 2017-01-11  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
11095
11096         common: Avoid unnecessary ambiguity in argparse.
11097         + commit 7249ab0f95d1f6cb8ee61eefedc79801bb56398f
11098         * common/argparse.c (find_long_option): Avoid unnecessary ambiguity.
11099
11100 2017-01-10  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
11101
11102         systemd-user: Enable "systemctl --user reload {dirmngr,gpg-agent}"
11103         + commit a20a450ac4ef10847fd59a5fd3acbbd2bfcaa6a2
11104         * doc/examples/systemd-user/*.service: Add ExecReload directives to
11105           indicate the canonical way to reload the services.
11106
11107         GnuPG recommends reloading the agent and dirmngr with "gpgconf
11108         --reload".  if anyone is running them as systemd user services, they
11109         might ask them to reload in the systemd way, so teach systemd the
11110         right thing to do.
11111
11112 2017-01-10  Justus Winter  <justus@g10code.com>
11113
11114         tests: Improve gpgconf test.
11115         + commit 88e42ef08d65d4d1bc29c6cea48df19ca0d5e2bd
11116         * tests/openpgp/defs.scm (valgrind): New variable.
11117         (gpg-config): Fix clearing an option.
11118         * tests/openpgp/gpgconf.scm: Also toggle 'quiet'.
11119
11120         tools: Fix memory leaks and improve error handling.
11121         + commit 1f5caf90bfaaaf7b9d8c06c12087aeeae3748032
11122         * tools/gpgconf-comp.c (gc_option_free): New function.
11123         (gc_components_free): Likewise.
11124         (gc_components_init): Likewise.
11125         (retrieve_options_from_program): Use 'xfree', fix memory leak.
11126         (change_options_program): Improve error handling.
11127         (gc_component_change_options): Fix memory leaks.
11128         * tools/gpgconf.c (main): Initialize components.
11129         * tools/gpgconf.h (gc_components_init): New prototype.
11130
11131         tests: Add test for gpgconf.
11132         + commit c8cfc62125aceee0ca48aab5c8a9fea1ec1ef652
11133         * tests/openpgp/Makefile.am (XTESTS): Add new test.
11134         * tests/openpgp/defs.scm (percent-encode): New function.
11135         (gpg-conf): Generalize so that we can feed stdin.
11136         (gpg-config): New function.
11137         * tests/openpgp/gpgconf.scm: New file.
11138
11139         common: Fix fallback code.
11140         + commit bfd6a490129ffc7c7ac8776bf5a5da3b1ddf6d42
11141         * common/logging.c (_log_assert): Fix the variant for compilers that
11142         do not support __FUNCTION__.
11143         * common/logging.h (_log_assert): Likewise.
11144
11145 2017-01-09  Werner Koch  <wk@gnupg.org>
11146
11147         dirmngr: Use "pgpkey-hkps" and "pgpkey-hkp" for SRV record lookups.
11148         + commit 0cc975d8a1cd54115938202432e43263b8893ea4
11149         * dirmngr/ks-engine-hkp.c (map_host): Chnage arg NO_SRV to SRVTAG.
11150         (make_host_part): Rewrite.
11151
11152         dirmngr: Do not use a SRV record for HKP if a port was specified.
11153         + commit c2cbe2f87c480c62239dc4c2cbb352acd98cd267
11154         * dirmngr/http.h (parsed_uri_s): Add field EXPLICIT_PORT.
11155         * dirmngr/http.c (do_parse_uri): That it.
11156         * dirmngr/ks-engine-hkp.c (map_host): Add arg NO_SRV.
11157         (make_host_part): Ditto.
11158         (ks_hkp_resolve): Set NO_SRV from EXPLICIT_PORT.
11159         (ks_hkp_search): Ditto.
11160         (ks_hkp_get): Ditto.
11161         (ks_hkp_put): Ditto.
11162
11163 2017-01-08  Werner Koch  <wk@gnupg.org>
11164
11165         dirmngr: Implement experimental SRV record lookup for WKD.
11166         + commit 88dc3af3d4ae1afe1d5e136bc4c38bc4e7d4cd10
11167         * dirmngr/server.c (cmd_wkd_get): Support SRV records.
11168
11169         dirmngr: Improve debug output for TLS.
11170         + commit 714faea4fa7f30d42e9986358214a99aa8fa57b3
11171         * dirmngr/misc.c (dump_cert): Also print SubjectAltNames.
11172
11173         dirmngr: Change internal SRV lookup API.
11174         + commit 16078f3deea5b82ea26e2f01dbd3ef3a5ce25410
11175         * dirmngr/dns-stuff.c (get_dns_srv): Add args SERVICE and PROTO.
11176         * dirmngr/http.c (connect_server): Simplify SRV lookup.
11177         * dirmngr/ks-engine-hkp.c (map_host): Ditto.
11178         * dirmngr/t-dns-stuff.c (main): Adjust for changed get_dns_srv.
11179
11180         dirmngr: Strip root zone suffix from libdns SRV results.
11181         + commit 9fa94aa10778bbd680315e93b23175423e338c40
11182         * dirmngr/dns-stuff.c (getsrv_libdns): Strip trailing dot from the
11183         target.
11184
11185 2017-01-06  Werner Koch  <wk@gnupg.org>
11186
11187         agent,w32: Fix annoying output to DebugView.
11188         + commit 8d774904c8066d8c0f19cfffe2d568979bb8c470
11189         * agent/gpg-agent.c (startup_fd_list): Do not define for W32.
11190         (main) [W32]: Do not call get_all_open_fds.
11191
11192 2017-01-06  NIIBE Yutaka  <gniibe@fsij.org>
11193
11194         scd: Fix for --disable-ccid for scdaemon.
11195         + commit 858e14cd794e2a6125d51e652a754bbe26def997
11196         * scd/apdu.c (apdu_dev_list_finish): Don't call ccid_dev_scan_finish
11197         with no table.
11198         (apdu_open_reader): Only increment when it's zero.
11199
11200         scd: Fix for --disable-ccid-driver.
11201         + commit 62268a2732dddca7a05ca4cf45d0e4338c7dc3c4
11202         * scd/apdu.c [HAVE_LIBUSB] (apdu_dev_list_start): Conditionalize.
11203         [HAVE_LIBUSB] (apdu_dev_list_finish, apdu_open_reader): Likewise.
11204
11205         scd: Support multiple readers by CCID driver.
11206         + commit 8a41e73c31adb86d4a7dca4da695e5ad1347811f
11207         * scd/apdu.c (new_reader_slot): Lock is now in apdu_dev_list_start.
11208         (close_pcsc_reader_direct, close_ccid_reader): RDRNAME is handled...
11209         (apdu_close_reader): ... by this function now.
11210         (apdu_prepare_exit): Likewise.
11211         (open_ccid_reader): Open with dev_list.
11212         (apdu_dev_list_start, apdu_dev_list_finish): New.
11213         (apdu_open_one_reader): New.
11214         (apdu_open_reader): Support multiple readers.
11215         * scd/app.c (select_application): With SCAN, opening all readers
11216         available, and register as new APP.
11217         (app_write_learn_status): app->ref_count == 0 is valid for APP which is
11218         not yet used.
11219         (app_list_start, app_list_finish): New.
11220         * scd/ccid-driver.c (struct ccid_driver_s): Remove RID and BCD_DEVICE.
11221         Add BAI.
11222         (parse_ccid_descriptor): BCD_DEVICE is now on the arguments.
11223         (ccid_dev_scan, ccid_dev_scan_finish): New.
11224         (ccid_get_BAI, ccid_compare_BAI, ccid_open_usb_reader): New.
11225         (ccid_open_reader): Support multiple readers.
11226         (ccid_set_progress_cb, ccid_close_reader): No RID any more.
11227
11228 2017-01-05  Werner Koch  <wk@gnupg.org>
11229
11230         Silence two -Wlogical-op warnings.
11231         + commit 6170eb809033c9d144abf3b1f31f8b936878cdd4
11232         * common/tlv.c (parse_ber_header): Avoid compiler warning about a
11233         duplicate condition.
11234         * tools/gpgtar-create.c (pattern_valid_p): Likewise.
11235
11236 2017-01-05  Justus Winter  <justus@g10code.com>
11237
11238         tests: New test for --{show,override}-session-key.
11239         + commit 168c8c9d79a817c1f08a9ef976dab377f8c4c69e
11240         * tests/openpgp/Makefile.am (XTESTS): Add new test.
11241         * tests/openpgp/decrypt-session-key.scm: New file.
11242
11243         tests: Fix macro.
11244         + commit 4ded213698123a425393b89a800fda2a4ec5229d
11245         * tests/openpgp/defs.scm (with-ephemeral-home-directory): Make
11246         hygienic, use define-macro, do not change to the ephemeral home
11247         directory.
11248         * tests/gpgsm/setup.scm: Change to the ephemeral home directory.
11249         * tests/openpgp/setup.scm: Likewise.
11250
11251 2017-01-04  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
11252
11253         g10: avoid warning when --disable-tofu.
11254         + commit 38671cfe5a2a40bb991619f4cb992c42b5f1e8cd
11255         If configured with --disable-tofu, we see compiler warnings about an
11256         unused variable.  This should remove those warnings.
11257
11258 2017-01-04  Justus Winter  <justus@g10code.com>
11259
11260         tests,w32: Fix locating the components.
11261         + commit 28e149609da44fab600f6a11b385d1c8ca8e7eb9
11262         * tests/openpgp/defs.scm (percent-decode): New function.
11263         (bin-prefix): New variable.
11264         (installed?): Likewise.
11265         (tool-hardcoded): Use the new variables.
11266         (gpg-conf): Use the new function to decode the values.
11267         (gpg-components): Do not use '--build-prefix' when 'installed?'.
11268
11269 2017-01-03  Werner Koch  <wk@gnupg.org>
11270
11271         dirmngr: Make sure Tor mode is also set for DNS on SIGHUP.
11272         + commit 969512401603639e4467ede7d892f1b02582c2c9
11273         * dirmngr/dns-stuff.c (enable_dns_tormode): Always succeed.
11274         (reload_dns_stuff): Reset tor port.
11275         * dirmngr/dirmngr.c (set_tor_mode): Also enable Tor mode for DNS.
11276         (main): Remove warning that Tor mode may not fully work.
11277         * dirmngr/server.c (cmd_dns_cert): Remove explicit Tor for DNS
11278         initialization.
11279         * dirmngr/t-dns-stuff.c (main): Remove option --new-circuit and error
11280         checking for enable_dns_tormode.
11281
11282         dirmngr: New debug message on correctly initialized libdns.
11283         + commit 0004d52ba2f1245c84f95a151342ad99fd72ca3d
11284         * dirmngr/dns-stuff.c (libdns_init): Add debug level diagnostic on
11285         success.
11286
11287 2017-01-02  Justus Winter  <justus@g10code.com>
11288
11289         common: Turn assertions into expressions.
11290         + commit a1e0d4a1e75fc6e6c3392a4e1d1d27005b38d6cc
11291         * common/logging.h (log_assert): Turn this into an expression so it
11292         can be used in expressions.
11293
11294         tests: Fix faked time in the TOFU test.
11295         + commit 6d065198337b5242889723481bfa9ce81aa108bb
11296         * tests/openpgp/tofu.scm (GPG): Fix time delta.
11297
11298 2017-01-02  Werner Koch  <wk@gnupg.org>
11299
11300         g13: Improve printing of debug infos.
11301         + commit 5b6ebfb9244602d9de31d61c7eceb0c45ac8aa49
11302         * g13/g13tuple.c (all_printable): Make it work.
11303
11304         Replace use of variable-length-arrays.
11305         + commit 6b84ecbf312d98ac8cce9fe5facdc815bc742fa1
11306         * common/t-iobuf.c (main): Replace variable-length-array.
11307         * g10/gpgcompose.c (mksubpkt_callback): Ditto.
11308         (encrypted): Ditto.
11309         * g10/t-stutter.c (log_hexdump): Ditto.
11310         (oracle_test): Ditto.
11311         * g10/tofu.c (get_policy): Ditto.  Use "%zu" for size_t.
11312         * scd/app-openpgp.c (ecc_writekey): Replace variable-length-array.
11313         Check for zero length OID_LEN.
11314
11315 2017-01-02  Justus Winter  <justus@g10code.com>
11316
11317         gpgscm: Fail if too many arguments are given.
11318         + commit b0e14bd6ff8401b12b2b39f75aef94d3ad28017f
11319         * tests/gpgscm/scheme.c (opexe_0): Enable check.
11320         * tests/gpgscm/tests.scm (test::report): Remove superfluous argument.
11321
11322         gpgscm: Add 'finally', rework all macros.
11323         + commit b79274a3b7e58f88e9a8c1dc1fb24dd3e983543c
11324         * tests/gpgscm/init.scm (finally): New macro.
11325         * tests/gpgscm/tests.scm (letfd): Rewrite.
11326         (with-working-directory): Likewise.
11327         (with-temporary-working-directory): Likewise.
11328         (lettmp): Likewise.
11329
11330         gpgscm: Use boxed values for source locations.
11331         + commit e8b843508dac96e9d0a3140954dd5a3618669cec
11332         * tests/gpgscm/scheme-private.h (struct port): Use boxed values for
11333         filename and current line.  This allows us to use the same Scheme
11334         object for labeling all expressions in a file.
11335         * tests/gpgscm/scheme.c (file_push): Use boxed type for filename.
11336         (mark): Mark location objects of port objects.
11337         (gc): Mark location objects in the load stack.
11338         (port_clear_location): New function.
11339         (port_reset_current_line): Likewise.
11340         (port_increment_current_line): Likewise.
11341         (file_pop): Adapt accordingly.
11342         (port_rep_from_filename): Likewise.
11343         (port_rep_from_file): Likewise.
11344         (port_close): Likewise.
11345         (skipspace): Likewise.
11346         (token): Likewise.
11347         (_Error_1): Likewise.
11348         (opexe_0): Likewise.
11349         (opexe_5): Likewise.
11350         (scheme_deinit): Likewise.
11351         (scheme_load_file): Likewise.
11352         (scheme_load_named_file): Likewise.
11353
11354 2017-01-02  Werner Koch  <wk@gnupg.org>
11355
11356         dirmngr: Strip root zone suffix from libdns cname results.
11357         + commit b200e636ab20d2aa93d9f71f3789db5a04af0a56
11358         * dirmngr/dns-stuff.c (resolve_name_libdns): Strip trailing dot.
11359         (get_dns_cname_libdns): Ditto.
11360
11361 2016-12-30  NIIBE Yutaka  <gniibe@fsij.org>
11362
11363         scd: Fix select_application.
11364         + commit 337690441fcb19343fe56b139f5649bed7d25c83
11365         * scd/app.c (select_application): Fix the condition for open.
11366
11367         scd: Fix card removal monitor.
11368         + commit f300e12a793d59deb1a369713384eaabfa39b3e6
11369         * scd/app.c (app_reset): Call send_client_notification with REMOVAL.
11370         (scd_update_reader_status_file): Likewise.
11371         * scd/command.c (send_client_notifications): Distinguish removal.
11372
11373 2016-12-29  NIIBE Yutaka  <gniibe@fsij.org>
11374
11375         scd: Improve internal CCID driver.
11376         + commit cdc8d0bd933b958db878861587322bc541b580b3
11377         * scd/ccid-driver.c (scan_or_find_usb_device): Don't scan for
11378         configuration but use active configuration.  Support alt_setting.
11379         (scan_or_find_devices): Support alt_setting.
11380         (ccid_open_reader): Support alt_setting.
11381
11382         scd: Fix a race condition for new_reader_slot.
11383         + commit c48cf7e32ffa02ebdf00265543344c611bef0431
11384         * scd/apdu.c (reader_table_lock, apdu_init): New.
11385         (new_reader_slot): Serialize by reader_table_lock.
11386         * scd/app.c (lock_app, unlock_app, app_new_register): Fix error code
11387         usage.
11388         (initialize_module_command): Call apdu_init.
11389         * scd/scdaemon.c (main): Handle error for initialize_module_command.
11390
11391 2016-12-28  NIIBE Yutaka  <gniibe@fsij.org>
11392
11393         scd: APP centric approach for device management.
11394         + commit 4cc9fc5eb9bd91d943c185d59da4a2b4cb885ee6
11395         * scd/app.c (lock_app): Rename from lock_reader and use internal field
11396         of APP.
11397         (unlock_app): Likewise.
11398         (app_dump_state): Use APP.
11399         (application_notify_card_reset): Remove.
11400         (check_conflict): Change API for APP, instead of SLOT.
11401         (check_application_conflict): Likewise.
11402         (release_application_internal): New.
11403         (app_reset): New.
11404         (app_new_register): New.
11405         (select_application): Change API for APP, instead of SLOT.
11406         (deallocate_app, release_application): Modify for manage link.
11407         (report_change): New.
11408         (scd_update_reader_status_file): Moved from command.c and
11409         use APP list, instead of VREADER.
11410         (initialize_module_command): Moved from command.c.
11411
11412         * scd/command.c (TEST_CARD_REMOVAL): Remove.
11413         (IS_LOCKED): Simplify.
11414         (vreader_table): Remove.
11415         (vreader_slot, update_card_removed): Remove.
11416         (do_reset): Call app_reset.
11417         (get_current_reader): Remove.
11418         (open_card): Add SCAN arg.
11419         (cmd_serialno): No retry, since retry is done in lower layer in apdu.c.
11420         No do_reset, since it is done in lower layer.
11421         Add clearing card_removed flag.
11422         (cmd_disconnect): Call apdu_disconnect.
11423         (send_client_notifications): Modify for APP.
11424         (update_reader_status_file): Remove.
11425
11426         scd: Simplify monitoring card removal.
11427         + commit f9882d8336feea96e3b5e250e9093f8cca01e08b
11428         * scd/apdu.c (struct reader_table_s): Remove any_status, last_status,
11429         status, and change_counter field.
11430         (new_reader_slot, dump_reader_status, ct_activate_card, open_ct_reader)
11431         (connect_pcsc_card, open_pcsc_reader_direct, open_pcsc_reader_wrapped)
11432         (open_ccid_reader, apdu_reset): Follow the change.
11433         (ct_dump_reader_status): Remove.
11434         (apdu_get_status_internal, apdu_get_status): Remove CHANGED arg.
11435         (apdu_connect): Follow the change.
11436         * scd/command.c (struct vreader_s): Remove reset_failed, any, and
11437         changed field.
11438         (cmd_getinfo, update_reader_status_file): Follow the change.
11439
11440 2016-12-27  NIIBE Yutaka  <gniibe@fsij.org>
11441
11442         scd: Improve internal CCID driver.
11443         + commit c7ec9c42246033e14ebad679d11f3b1fbeed23b7
11444         * scd/ccid-driver.c (scan_or_find_usb_device): Fix return value.
11445         Support device with multiple CCID interfaces.  Fix the case with
11446         READERNO.  Support partial string match of "reader-port" like PC/SC
11447         driver.
11448
11449 2016-12-23  NIIBE Yutaka  <gniibe@fsij.org>
11450
11451         dirmngr: Fix for --disable-libdns usage.
11452         + commit d26c51825e2255fe58305cbc1cd74fa43f80d93e
11453         * dirmngr/dns-stuff.c (enable_recursive_resolver, set_dns_nameserver)
11454         (reload_dns_stuff): Conditionalize with USE_LIBDNS.
11455         (get_h_errno_as_gpg_error): Map HOST_NOT_FOUND to GPG_ERR_NO_NAME.
11456
11457 2016-12-22  Neal H. Walfield  <neal@g10code.com>
11458
11459         tools: Show a clearer error message if a server doesn't support WKS.
11460         + commit 1909e994cb87d6c6866a465f0c20a456d4df46cc
11461         * tools/gpg-wks-client.c (command_send): If we fail to lookup the
11462         submission address, print a better error message.  If it is because
11463         the corresponding file doesn't exist, provide the hint that the server
11464         probably doesn't support WKS.
11465
11466 2016-12-22  Werner Koch  <wk@gnupg.org>
11467
11468         wks: Let the client ignore missing policy flags.
11469         + commit e917dfcd973a3ebbf5eb584e819ffa89f932bfef
11470         * tools/gpg-wks-client.c (command_send): Ignore missing policy flags.
11471
11472 2016-12-22  NIIBE Yutaka  <gniibe@fsij.org>
11473
11474         scd: Clean up internal API for APP.
11475         + commit 8431f5a7e88e1f42d75c4a4b61f4aa9b35457204
11476         * scd/app-common.h (app_readcert, app_readkey, app_setattr, app_sign,
11477         app_auth, app_decipher, app_get_challenge, app_check_pin): Add CTRL as
11478         the second argument.
11479         * scd/app.c: Supply CTRL to lock_reader calls.
11480         * scd/command.c (cmd_readcert, cmd_readkey, cmd_pksign, cmd_auth,
11481         cmd_pkdecrypt, cmd_setattr, cmd_random, cmd_checkpin): Follow the
11482         change.
11483
11484 2016-12-21  Justus Winter  <justus@g10code.com>
11485
11486         gpgscm: Guard use of union member.
11487         + commit 6e96cdd41a0e55b672309431062f37c4a4a9f485
11488         * tests/gpgscm/scheme.c (opexe_5): Check that we have a file port
11489         before accessing filename.  Fixes a crash on 32-bit architectures.
11490
11491 2016-12-20  Werner Koch  <wk@gnupg.org>
11492
11493         tests: Avoid skipping exectool tests.
11494         + commit 6204f8104fea42d706a68e77e2dc0bca4704bddc
11495         * common/t-exectool.c (test_executing_true): Try also /usr/bin/true.
11496         (test_executing_false): Try also /usr/bin/false.
11497
11498 2016-12-20  Justus Winter  <justus@g10code.com>
11499
11500         tests: Add test suite for gpgsm.
11501         + commit 36c14139285982def6ad942d4b2d8bef7ed4ea76
11502         * configure.ac (AC_CONFIG_FILES): Add new file.
11503         * tests/Makefile.am (SUBDIRS): Add new directory.
11504         * tests/gpgsm/32100C27173EF6E9C4E9A25D3D69F86D37A4F939: New file.
11505         * tests/gpgsm/Makefile.am: Likewise.
11506         * tests/gpgsm/cert_dfn_pca01.der: Likewise.
11507         * tests/gpgsm/cert_dfn_pca15.der: Likewise.
11508         * tests/gpgsm/cert_g10code_test1.der: Likewise.
11509         * tests/gpgsm/decrypt.scm: Likewise.
11510         * tests/gpgsm/encrypt.scm: Likewise.
11511         * tests/gpgsm/export.scm: Likewise.
11512         * tests/gpgsm/gpgsm-defs.scm: Likewise.
11513         * tests/gpgsm/import.scm: Likewise.
11514         * tests/gpgsm/plain-1.cms.asc: Likewise.
11515         * tests/gpgsm/plain-2.cms.asc: Likewise.
11516         * tests/gpgsm/plain-3.cms.asc: Likewise.
11517         * tests/gpgsm/plain-large.cms.asc: Likewise.
11518         * tests/gpgsm/run-tests.scm: Likewise.
11519         * tests/gpgsm/setup.scm: Likewise.
11520         * tests/gpgsm/shell.scm: Likewise.
11521         * tests/gpgsm/sign.scm: Likewise.
11522         * tests/gpgsm/verify.scm: Likewise.
11523
11524         tests: Add macro managing ephemeral home directories.
11525         + commit c067a012c764218b94ce8de2914615a895a75f3e
11526         * tests/openpgp/defs.scm (with-ephemeral-home-directory): New macro.
11527         * tests/openpgp/setup.scm: Use the new macro.
11528
11529         tests: Move argument parser.
11530         + commit a30c0a6972cabde3858108e9020e900696094843
11531         * tests/gpgme/gpgme-defs.scm (flag): Move...
11532         * tests/gpgscm/tests.scm: ... over here.
11533
11534         tests: Add missing encrypted sample, cleanup samples handling.
11535         + commit e2ed3c1597daf3188ddce049cc3c50113d56f1b9
11536         * tests/openpgp/Makefile.am (TEST_FILES): Add new file.
11537         * tests/openpgp/defs.scm (plain-files): Add 'plain-large'.
11538         (all-files): New variable.
11539         (create-sample-files): New function.
11540         (create-legacy-gpghome): Use new function.
11541         * tests/openpgp/plain-large.asc: New file.
11542
11543 2016-12-20  Werner Koch  <wk@gnupg.org>
11544
11545         Release 2.1.17.
11546         + commit ade32464a25fdb35cc0f39e46d303ceba68ea8f6
11547
11548
11549         sm: Remove wrong example from gpgsm --help.
11550         + commit 13465e708bb67e816e4fb3a37c117ad91dc6383f
11551         * sm/gpgsm.c (opts): Remove group 303.
11552
11553         dirmngr: New option --resolver-timeout.
11554         + commit 81c012787fabf734d9c952c6f18ecac21929d4d8
11555         * dirmngr/dns-stuff.c (DEFAULT_TIMEOUT): New.
11556         (opt_timeout): New var.
11557         (set_dns_timeout): New.
11558         (libdns_res_open): Set the default timeout.
11559         (libdns_res_wait): Use configurable timeout.
11560         (resolve_name_libdns): Ditto.
11561
11562         * dirmngr/dirmngr.c (oResolverTimeout): New const.
11563         (opts): New option --resolver-timeout.
11564         (parse_rereadable_options): Set that option.
11565         (main) <aGPGConfList>: Add --nameserver and --resolver-timeout.
11566         * tools/gpgconf-comp.c (gc_options_dirmngr): Add --resolver-timeout
11567         and --nameserver.
11568
11569         * dirmngr/http.c (connect_server): Fix yesterday introduced bug in
11570         error diagnostic.
11571
11572 2016-12-19  Werner Koch  <wk@gnupg.org>
11573
11574         dirmngr: Fix problems with the getsrv function.
11575         + commit af8b68fae39b1378c769e0de6ba6437ea1aac7e3
11576         * dirmngr/dns-stuff.c (opt_debug, opt_verbose): New vars.
11577         (set_dns_verbose): New func.
11578         (libdns_switch_port_p): Add debug output.
11579         (resolve_dns_name): Ditto.
11580         (get_dns_cert): Ditto.
11581         (get_dns_cname): Ditto.
11582         (getsrv_libdns, getsrv_standard): Change SRVCOUNT to an unsigend int.
11583         (getsrv): Rename to ...
11584         ((get_dns_srv): this.  Add arg R_COUNT and return an error.  Add debug
11585         output.
11586         * dirmngr/http.c: Adjust for chnaged getsrv().
11587         * dirmngr/ks-engine-hkp.c (map_host): Ditto.
11588         * dirmngr/t-dns-stuff.c (main): Ditto.  Call set_dns_verbose.
11589         * dirmngr/dirmngr.c (parse_rereadable_options): Call set_dns_verbose.
11590
11591         build: Add target to sign the windows installer.
11592         + commit 284ec54495dddc9eb0232e959cf994234097578a
11593         * build-aux/speedo.mk (w32-sign-installer): New.
11594         (AUTHENTICODE_KEY): New.
11595         (installer-from-source): Use cp instead of mv.  Factor code out to ...
11596         (MKSWDB_commands): new macro.
11597         (sign-installer): New.
11598
11599 2016-12-19  Justus Winter  <justus@g10code.com>
11600
11601         tests: Use the common test framework for the migration tests.
11602         + commit 65a0d6a24e6299682793f213a9d2bae17c5b12d9
11603         * tests/migrations/Makefile.am (reqired_pgms): Add 'gpgscm'.
11604         (TESTS_ENVIRONMENT): Populate.
11605         (TESTS): Rename to 'XTESTS'.
11606         (xcheck): New target.
11607         (EXTRA_DIST): Add new files.
11608         (CLEANFILES): Remove log files.
11609         * tests/migrations/common.scm: Honor 'verbose', fix paths.
11610         * tests/migrations/run-tests.scm: New file.
11611         * tests/migrations/setup.scm: Likewise.
11612
11613         tests: Use sequential test runner if only one test is given.
11614         + commit 0bf16d702665a269ce5ef724c927fbbd8f7f1ce9
11615         * tests/openpgp/run-tests.scm: Use sequential test runner if only one
11616         test is given.
11617
11618 2016-12-19  Werner Koch  <wk@gnupg.org>
11619
11620         dirmngr,w32: Hack around a select problem.
11621         + commit d51499fdc522a696f23c6776c3ab248742f4e06a
11622         * dirmngr/dns.c (FD_SETSIZE): Bump up to 1024.
11623         (dns_poll): Return an error instead of hitting an assertion failure.
11624
11625 2016-12-19  Neal H. Walfield  <neal@g10code.com>
11626
11627         test: Extend TOFU tests to also check the days with signatures.
11628         + commit aec89a7297bae30f79a63fdc830530e82bab6170
11629         * tests/openpgp/tofu.scm (GPGTIME): Define the "standard" base time.
11630         (faketime): New function.
11631         (days->seconds): Likewise.
11632         (GPG): Use faketime.
11633         (check-counts): Also check the number of expected days with signatures
11634         and encryptions.  Update callers.  Extend tests.
11635
11636 2016-12-19  Justus Winter  <justus@g10code.com>
11637
11638         tests: New test for --delete-[secret-]keys.
11639         + commit a1afc450e182af02ad5e6f6ba79e9dc4332ca2bc
11640         * tests/openpgp/Makefile.am (XTESTS): Add new test.
11641         * tests/openpgp/defs.scm (keys): New variable.
11642         (have-public-key?): New function.
11643         (have-secret-key?): Likewise.
11644         (have-secret-key-file?): Likewise.
11645         * tests/openpgp/delete-keys.scm: New file.
11646         * tests/openpgp/quick-key-manipulation.scm: Move the accessors to
11647         'defs.scm'.
11648
11649         gpgscm: Change associativity of ::.
11650         + commit a45dc0849da0d944ec8c759bc8e3e733b1eb0079
11651         * tests/gpgscm/scheme.c (mk_atom): Change associativity of the ::
11652         infix-operator.  This makes it possible to naturally express accessing
11653         nested structures (e.g. a::b::c).
11654
11655         gpgscm: Display location when assertions fail.
11656         + commit 3949cbd1128585c9b810713aeffaa1455fb5aed9
11657         * tests/gpgscm/lib.scm (assert): Use location information if
11658         available.
11659
11660         gpgscm: Make exception handling more robust.
11661         + commit df00745d6eed7034b218a0c482a46d975425798a
11662         * tests/gpgscm/init.scm (throw'): Check that args is a list.
11663
11664 2016-12-19  Andre Heinecke  <aheinecke@intevation.de>
11665
11666         speedo,w32: Use nsExec::ExecToLog to avoid popups.
11667         + commit 026bbf0d5ee4510967e5f1dd3db2dee4687b0612
11668         * build-aux/speedo/w32/inst.nsi: Use ExecToLog instead of
11669         ExecWait.
11670
11671 2016-12-19  Werner Koch  <wk@gnupg.org>
11672
11673         Remove unused debug flags and add "dns" and "network".
11674         + commit e384405b6e251629fb36bcbba4f5f9ac15a39d10
11675         * g10/options.h (DBG_CARD_IO_VALUE, DBG_CARD_IO): Remove.
11676         * g10/gpg.c (debug_flags): Remove "cardio".
11677         * agent/agent.h (DBG_COMMAND_VALUE, DBG_COMMAND): Remove.
11678         * agent/gpg-agent.c (debug_flags): Remove "command".
11679         * scd/scdaemon.h (DBG_COMMAND_VALUE, DBG_COMMAND): Remove.
11680         * scd/scdaemon.c (debug_flags): Remove "command".
11681         * dirmngr/dirmngr.h (DBG_DNS_VALUE, DBG_DNS): New.
11682         (DBG_NETWORK_VALUE, DNG_NETWORK): New.
11683         * dirmngr/dirmngr.c (debug_flags): Add "dns" and "network".
11684
11685 2016-12-17  Werner Koch  <wk@gnupg.org>
11686
11687         dirmngr: Fix setup of libdns for W32.
11688         + commit e77b924fec1082faae48cdd2ff8474874a22bdf7
11689         * configure.ac (DNSLIB) {W32]: Add -liphlpapi.
11690         * dirmngr/dns-stuff.c [W32]: Include iphlpapi.h and define
11691         WIN32_LEAN_AND_MEAN.
11692         (libdns_init) [W32]: Use GetNetworkParams to get the nameserver.
11693         * dirmngr/t-dns-stuff.c (init_sockets): New.
11694         (main): Call it.
11695
11696 2016-12-16  Werner Koch  <wk@gnupg.org>
11697
11698         dirmngr: Auto-switch from Tor port to Torbrowser port.
11699         + commit 024dbd7162fc1a7694176ebad3c21ee3ea67c024
11700         * dirmngr/dns-stuff.c (libdns_tor_port): New var.
11701         (set_dns_nameserver): Clear that var.
11702         (libdns_init): Init var to the default port.
11703         (libdns_switch_port_p): New func.
11704         (resolve_dns_name): Use function to switch the port
11705         (get_dns_cert): Ditto.
11706         (getsrv): Ditto.
11707         (get_dns_cname): Ditto.
11708
11709         dirmngr: Use one context for all libdns queries.
11710         + commit c4e8a3194d6b92f596a6483e486c645de7d2ddd1
11711         * dirmngr/dns-stuff.c (libdns_reinit_pending): New var.
11712         (enable_recursive_resolver): Set var.
11713         (set_dns_nameserver): Ditto.
11714         (libdns_init): Avoid double initialization.
11715         (libdns_deinit): New.
11716         (reload_dns_stuff): New.
11717         (libdns_res_open): Act upon LIBDNS_REINIT_PENDING.
11718         * dirmngr/t-dns-stuff.c (main): Call reload_dns_stuff to release
11719         memory.
11720         * dirmngr/dirmngr.c (cleanup): Ditto.
11721         (dirmngr_sighup_action): Call reload_dns_stuff to set
11722         LIBDNS_REINIT_PENDING.
11723
11724         dirmngr: Pass Tor credentials to libdns.
11725         + commit ddb48086833f8b86f0f0d69b21a23f245090ea7a
11726         * dirmngr/dns-stuff.c (tor_credentials): Replace by ...
11727         (tor_socks_user, tor_socks_password): new vars.
11728         (enable_dns_tormode): Set these new vars.
11729         (libdns_res_open): Tell libdns the socks credentials.
11730
11731         dirmngr: Factor common libdns code out.
11732         + commit 59d3c3e4baffff52548fb5d1766ebf02dd8e1bec
11733         * dirmngr/dns-stuff.c (libdns_res_open): New.  Replace all libdns_init
11734         and dns-res_open by a call to this func.
11735         (libdns_res_submit): New wrapper.  Replace all dns_res_sumbit calls.
11736         (libdns_res_wait): New function.
11737         (resolve_name_libdns): Replace loop by libdns_res_wait.
11738         (get_dns_cert_libdns): Ditto.
11739         (getsrv_libdns): Ditto.
11740
11741         gpg,sm: A few more option for --gpgconf-list.
11742         + commit 48671f295ff233765689b6a73021f83ab845a28f
11743         * g10/gpg.c (gpgconf_list): Add --compliance and
11744         --default-new-key-algo.
11745         (parse_compliance_option):
11746         * sm/gpgsm.c (main) <gpgconf-list>: Add --enable-crl-checks.
11747
11748         gpgconf: New command --apply-profile.
11749         + commit 76cd64a5baf6057b199c01f7999b327f1f4a87bc
11750         * tools/gpgconf.c (aApplyProfile): New.
11751         (opts): New command --apply-profile.
11752         (main): Implement that command.
11753         * tools/gpgconf-comp.c (option_check_validity): Add arg VERBATIM.
11754         (change_options_program): Ditto.
11755         (change_one_value): Ditto.
11756         (gc_component_change_options): Ditto.
11757         (gc_apply_profile): New.
11758
11759         gpgconf: Fix --apply-defaults.
11760         + commit 6ca3c28da46873416822bf6ab7893db6c56a49d6
11761         * tools/gpgconf-comp.c: Skip pinentry also in process_all mode.
11762
11763 2016-12-16  Justus Winter  <justus@g10code.com>
11764
11765         doc: Mention extra information in pinentry status lines.
11766         + commit 12a5265afa7f87ad92fb571e0882e57b07a3c267
11767         * doc/DETAILS: Mention that 'PINENTRY_LAUNCHED may carry extra
11768         information.
11769
11770         sm: Fix agent communication.
11771         + commit 3c7d6a1769ed6cc90d86247a814a0dce341512a3
11772         * sm/call-agent.c (gpgsm_agent_pksign): Fix passing the control handle
11773         to the callback.
11774         (gpgsm_scd_pksign): Likewise.
11775         (gpgsm_agent_reaedkey): Likewise.
11776
11777 2016-12-16  Neal H. Walfield  <neal@g10code.com>
11778
11779         doc: Fix manual.
11780         + commit a165fa09be4bfbeb97ebe25d551a9045255e5028
11781         * doc/gpg.texi: Remove comment about options being parsed in-order.
11782         They aren't.
11783
11784         g10: Use total days, not total messages to compute TOFU validity.
11785         + commit 4a2c210b75d4266e289712e73a42c286aabb07f0
11786         * g10/tofu.c (write_stats_status): Use the number of days with
11787         signatures / encryptions to compute the validity, not the total number
11788         of signatures / encryptions.
11789         (BASIC_TRUST_THRESHOLD): Adjust given the new semantics.
11790         (FULL_TRUST_THRESHOLD): Likewise.
11791
11792         g10: Extend TOFU_STATS to emit <sign-days> and <encyrption-days>
11793         + commit 94f6b9010d2e80a75ccbb21426faf0b30195f1ab
11794         * doc/DETAILS: Add SIGN-DAYS and ENCRYPT-DAYS to the TOFU_STATS status
11795         line.
11796         * g10/tofu.c (write_stats_status): Take additional parameters
11797         signature_days and encryption_days.  Update callers.  Include them in
11798         the tfs record and TOFU status lines.
11799         (show_statistics): Compute the number of days on which we saw a
11800         message signed by FINGERPRINT, and the number of days on which we
11801         encrypted a message to it.
11802
11803 2016-12-16  Justus Winter  <justus@g10code.com>
11804
11805         doc: Improve section on unattended key generation.
11806         + commit ca02a8b78fca8815388a859962584d75169ae3ee
11807         * doc/gpg.texi: Improve the subsection on unattended key generation by
11808         suggesting the quick key manipulation interface as an alternative, and
11809         by suggesting alternatives to '%pubring' and '%secring'.  Simplify
11810         examples accordingly.
11811
11812         doc: Add documentation for programmatic use of GnuPG.
11813         + commit 116a78eb869c4c589228bd0d6deff7c7a9f92dfb
11814         * doc/gpg.texi: New subsections on programmatic use of GnuPG,
11815         ephemeral home directories, and the quick key manipulation interface.
11816
11817 2016-12-16  Neal H. Walfield  <neal@g10code.com>
11818
11819         g10: On a TOFU conflict, write the conflicting keys to the status fd.
11820         + commit fea9da4a8afab6f3a49cdbbcc4a7a21f27a6d3e8
11821         * g10/tofu.c (ask_about_binding): Emit all of the conflicting keys and
11822         their statistics on the status fd.
11823         (get_trust): Likewise, if we don't call ask_about_binding.
11824         (show_statistics): Have the caller pass the policy as returned by
11825         get_policy.  Add argument only_status_fd and don't emit any output on
11826         stdout if it is set.  Update callers.
11827
11828         g10: Add missing space.
11829         + commit 6caa2d0ba2bfc0ae93878738b0169483f6b6b462
11830         * g10/tofu.c (tofu_register_encryption): Add missing space.
11831
11832 2016-12-15  Justus Winter  <justus@g10code.com>
11833
11834         g10: Avoid translating simple error messages.
11835         + commit 6b16b02109f4bb5b934e456667ff4c0ba7bc85fd
11836         * g10/gpg.c (main): Avoid translating arguments to 'wrong_args'.
11837
11838         g10: Rework the --quick-* interface.
11839         + commit 41ad04d403de05abe54280d2a84aa51a603194e4
11840         * g10/gpg.c (opts): Rename options.
11841         (main): Update errors.
11842         * doc/gpg.texi: Update accordingly.
11843
11844         g10: Rename 'card-edit' to 'edit-card'.
11845         + commit 6e4396723e9e5865015ebf7033628fa3919cf7d1
11846         * g10/gpg.c (opts): Rename option.
11847         * g10/call-agent.c (agent_scd_learn): Update comment.
11848         * doc/gpg.texi: Update accordingly.
11849
11850         g10: Spell out --desig-revoke.
11851         + commit 3c691097ca144e9a1d4c9185636c59a848bec85c
11852         * g10/gpg.c (opts): Rename option.
11853         * doc/gpg.texi: Update accordingly.
11854
11855         g10: Shorten unreasonably long option.
11856         + commit c252627c6fd93bc305c5a5a2f013c3de2d45c6b0
11857         * g10/gpg.c (opts): Rename 'generate-revocation-certificate' to
11858         'generate-revocation'.
11859         * doc/gpg.texi: Update accordingly.
11860         * po: Update translations.
11861
11862         doc: Add aliases of all changed options.
11863         + commit bc6b76ef26f31c54ae1c29c761b8ecc437fcf565
11864         * doc/gpg.texi: Add the old version of every option that was updated
11865         with the last change set.
11866         * doc/gpgsm.texi: Likewise.
11867
11868 2016-12-15  Werner Koch  <wk@gnupg.org>
11869
11870         dirmngr: First patch to re-enable Tor support.
11871         + commit 2d1760ffe2ff46b77bd0f38db8b781d9564ae999
11872         * dirmngr/dns-stuff.c (SOCKS_PORT, TOR_PORT, TOR_PORT2): New
11873         constants.
11874         (libdns_init): Start adding tor support.
11875         (resolve_name_libdns): Pass socks hosts to dns_res_open.
11876         (get_dns_cert_libdns): Ditto.
11877         (getsrv_libdns): Ditto.
11878         (get_dns_cname_libdns): Ditto.
11879
11880 2016-12-15  Justus Winter  <justus@g10code.com>
11881
11882         build: Fix distcheck.
11883         + commit 0e2055c7d30d987a7a74923a7080b80cce470601
11884         * tests/gpgme/Makefile.am (CLEANFILES): New variable, clean test logs.
11885
11886 2016-12-14  Justus Winter  <justus@g10code.com>
11887
11888         tests: Reuse GPGME's tests.
11889         + commit 948cca9c99e701a1668bb5fd6e25f07e35381b4d
11890         * configure.ac (AC_CONFIG_FILES): Add new Makefile.
11891         * tests/Makefile.am (SUBDIRS): Add new directory.
11892         * tests/gpgme/Makefile.am: New file.
11893         * tests/gpgme/gpgme-defs.scm: Likewise.
11894         * tests/gpgme/run-tests.scm: Likewise.
11895         * tests/gpgme/setup.scm: Likewise.
11896         * tests/gpgme/wrap.scm: Likewise.
11897
11898         common: Support locating components in the build tree.
11899         + commit ca1e9749bfb069d90aa44efbf6f3d611b6104c1b
11900         * common/homedir.c (gnupg_build_directory): New variable.
11901         (gnupg_module_name_called): Likewise.
11902         (gnupg_set_builddir): New function.
11903         (gnupg_set_builddir_from_env): Likewise.
11904         (gnupg_module_name): Support locating components in the build tree.
11905         * common/util.h (gnupg_set_builddir): New prototype.
11906         * tests/openpgp/defs.scm (tools): Drop 'gpg and 'gpg-agent.
11907         (tool): Rename to 'tool-hardcoded.
11908         (gpg-conf): New function, with accessors for the results.
11909         (gpg-components): New variable.
11910         (tool): New function.
11911         * tools/gpgconf.c (enum cmd_and_opt_values): New key.
11912         (opts): New option '--build-prefix'.
11913         (main): Handle new option.
11914
11915         tests: Rework check for trust models.
11916         + commit 55dc81125abc43cd3cc8db951fc3b8a81767942d
11917         * tests/openpgp/defs.scm (gpg-has-option?): New function.
11918         (have-opt-always-trust): Use a simpler test for that option.  This way
11919         that is less distracting when we run the tests with verbose=3.
11920
11921 2016-12-14  Werner Koch  <wk@gnupg.org>
11922
11923         dirmngr: New configure option --disable-libdns.
11924         + commit d34a2bb410c7c770d26430d69ff77bd83fc407f1
11925         * configure.ac: Add option --disable-libdns
11926         (USE_LIBDNS): New ac_subst and am_conditional.
11927         (USE_C99_CFLAGS): Set only if libdns is used.
11928         * dirmngr/Makefile.am (dirmngr_SOURCES): Move dns.c and dns.h to ...
11929         (dirmngr_SOURCES) [USE_LIBDNS0: here.
11930         (t_common_src): Ditto.
11931         * dirmngr/dirmngr.c (oRecursiveResolver): New constant.
11932         (opts): New option "--recursive-resolver".
11933         (parse_rereadable_options): Set option.
11934         * dirmngr/t-dns-stuff.c (main): Add option --recursive-resolver.
11935         * dirmngr/server.c (cmd_getinfo): Depend output of "dnsinfo" on the
11936         new variables.
11937         * dirmngr/dns-stuff.c: Include dns.h only if USE_DNSLIB is defined.
11938         Also build and call dnslib functions only if USE_DNSLIB is defined.
11939         (recursive_resolver): New var.
11940         (enable_recursive_resolver): New func.
11941         (recursive_resolver_p): New func.
11942
11943         dirmngr: Implement CERT record lookup via libdns.
11944         + commit 3c2a7918eac024b5e1258ea9b272b4e8a1f1af43
11945         * dirmngr/dns-stuff.c (get_dns_cert_libdns): New.
11946         (get_dns_cert_standard): Fix URL malloc checking.
11947
11948         dirmngr: Implement CNAME and SRV record lookup via libdns.
11949         + commit 4c13e4e3debe0e55e86ae29c095f2d86eb0a6f11
11950         * dirmngr/dns-stuff.c (dns_free): New macro.
11951         (libdns): Move var to the top.
11952         (libdns_error_to_gpg_error): Map error codes to the new gpg-error
11953         codes.
11954         (resolve_name_libdns): Restructure code.
11955         (getsrv_libdns): New.
11956         (get_dns_cname_libdns): New.
11957
11958         dirmngr: Fix bugs in the standard resolver code.
11959         + commit 4a030f682ef48542ed324b28207f2c2b4847dbef
11960         * dirmngr/dns-stuff.c: Include dirmngr-err.h to set the correct error
11961         source.
11962         (get_h_errno_as_gpg_error): New.
11963         (get_dns_cert_libdns): Fix error code.
11964         (getsrv_libdns): Add arg R_COUNT and return an error code.
11965         (getsrv_standard): Ditto.  Fix handling of res_query errors and
11966         provide the correct size for the return buffer.
11967         (getsrv): Adjust for changed worker functions.
11968         (get_dns_cname_standard): Fix handling of res_query errors and provide
11969         the correct size for the return buffer.
11970
11971         dirmngr: Require a c99 compiler.
11972         + commit 392966aed9b2a5e1456c671e5d13b561a27e4bb2
11973         * configure.ac (USE_C99_CFLAGS): New ac_subst.  Set to -std=gnu99 for
11974         gcc.
11975         * dirmngr/Makefile.am (AM_CFLAGS): Add USE_C99_CFLAGS.
11976         (t_http_CFLAGS): Ditto.
11977         (t_ldap_parse_uri_CFLAGS): Ditto.
11978         (t_dns_stuff_CFLAGS): Ditto.
11979
11980         doc: Add license notes for libdns.
11981         + commit d84f5a88233c073a82fd47728574b001343784ee
11982         * COPYING.other: New.
11983         * Makefile.am (EXTRA_DIST): Add it.
11984         * AUTHORS: Add info on libdns.
11985         * build-aux/speedo/w32/pkg-copyright.txt: Add license terms.
11986
11987         common: Add replacements for error codes from gpg-error 1.26.
11988         + commit aae68a3ccd3d9870162b3ffd49eae08d5bf1b1e1
11989
11990
11991 2016-12-14  Justus Winter  <justus@g10code.com>
11992
11993         dirmngr: New libdns snapshot.
11994         + commit f8ab2c4c70ad15c4b2e45492606fb94ddaccdac7
11995
11996
11997         dirmngr: Add basic libdns support.
11998         + commit f6acd0426453d3a18536ca69d63baa0d971082ef
11999         * dirmngr/dns.c: New file.
12000         * dirmngr/dns.h: New file.
12001         * dirmngr/Makefile.am (dirmngr_SOURCES): Add new files.
12002         * dirmngr/dns-stuff.c: Include dns.h.xxx use libdns
12003         (libdns): New global var for the libdns state.
12004         (libdns_error_to_gpg_error): New.
12005         (libdns_init): New.
12006         (resolve_name_libdns): New.
12007         (get_dns_cert_libdns): New stub.
12008         (getsrv_libdns): New stub.
12009         (get_dns_cname_libdns): New stub.
12010
12011         dirmngr,build: Remove support for ADNS.
12012         + commit 2e734a3ce159de8fb60df2bd5d454f98ca710717
12013         * autogen.rc: Remove '--with-adns' argument.
12014         * configure.ac: Remove check for ADNS.
12015         * dirmngr/dns-stuff.c: Remove all code that uses ADNS.
12016         * dirmngr/server.c (cmd_getinfo): Update status line.
12017         * doc/dirmngr.texi: Do not mention ADNS.
12018
12019 2016-12-14  NIIBE Yutaka  <gniibe@fsij.org>
12020
12021         dirmngr: Improve ntbtls support.
12022         + commit 57aa42ce9b28bc17ac24491d595766fbf80762af
12023         * dirmngr/http.c [HTTP_USE_NTBTLS] (close_tls_session): Release.
12024         (send_request): Call ntbtls_set_transport.
12025         (cookie_read, cookie_write): Implement.
12026         (cookie_close): Add initial implementation for ntbtls.
12027
12028 2016-12-13  Justus Winter  <justus@g10code.com>
12029
12030         g10,sm: Spell out --passwd.
12031         + commit c1c35fb887061de05661f3411eda97546e1a52d7
12032         * g10/gpg.c (opts): Spell out option.
12033         * sm/gpgsm.c (opts): Likewise.
12034         * doc/gpg.texi: Update accordingly.
12035         * doc/gpgsm.texi: Likewise.
12036
12037         g10: Spell out --gen-revoke.
12038         + commit ec1bd3ae685e95563e38077ab3c1655fd55dea07
12039         * g10/gpg.c (opts): Spell out option.
12040         * doc/gpg.texi: Update accordingly.
12041         * po: Update translations.
12042
12043         g10: Spell out --full-gen-key.
12044         + commit 09163a6390bd9713f3a7946de739765b30ef6f64
12045         * g10/gpg.c (opts): Spell out option.
12046         (main): Likewise.
12047         * g10/keygen.c (generate_keypair): Likewise.
12048         * doc/gpg.texi: Update accordingly.
12049
12050         g10,sm: Spell out --gen-key.
12051         + commit 892c827e72b1396e3b58e2f8869cc48328a2b59c
12052         * g10/gpg.c (opts): Spell out option.
12053         * sm/gpgsm.c (opts): Likewise.
12054         * doc/gpg.texi: Update accordingly.
12055
12056         g10,sm: Spell out --check-sigs.
12057         + commit 9147737f1c6894f38b855f3cf38cd33122a1ae2a
12058         * g10/gpg.c (opts): Spell out option.
12059         * sm/gpgsm.c (opts): Likewise.
12060         * doc/gpg.texi: Update accordingly.
12061
12062         g10,sm: Spell out --list-sigs.
12063         + commit a6d6e4afe488bc05ee730e85da6a9505c6cd245a
12064         * g10/gpg.c (opts): Spell out option.
12065         * sm/gpgsm.c (opts): Likewise.
12066         * doc/gpg.texi: Update accordingly.
12067
12068         g10: Hyphenate --clearsign.
12069         + commit 04754ce3a704b1e6d38cb9a28dacf2821dc3f15f
12070         * g10/gpg.c (opts): Hyphenate option.
12071         * doc/gpg.texi: Update accordingly.
12072         * po: Update translations.
12073         * tests/openpgp: Update tests.
12074
12075         g10: Spell out --recv-keys.
12076         + commit ca598152345b40f3a236227dfc63ae04ddf777d7
12077         * g10/gpg.c (opts): Spell out option.
12078         * doc/gpg.texi: Update accordingly.
12079
12080         g10: Create expiring keys in quick key generation mode.
12081         + commit dd3dde07a9a46130ac01d849f8edf0566e44f11f
12082         * doc/gpg.texi: Document that fact.
12083         * g10/keygen.c (quick_generate_keypair): Use a default value.
12084         * tests/openpgp/quick-key-manipulation.scm: Test that fact.
12085
12086         gpgscm: Print failed and skipped tests.
12087         + commit 429891a704057437517cb0b45d11392b40fa1ee8
12088         * tests/gpgscm/tests.scm (test-pool::report): Print failed and skipped
12089         tests at the end.
12090
12091         gpgscm: Generalize the test runner.
12092         + commit d43dabf4607d3bcfc217eb9aea34d093f5aa698f
12093         * tests/gpgscm/tests.scm (test::scm) Add explicit name argument.
12094         (test::binary): Likewise.  Also, add missing unquote.
12095         * tests/openpgp/run-tests.scm: Adapt accordingly.
12096
12097         gpgscm: Move the test runner to the Scheme library.
12098         + commit 1a176b92a8aad42056ed2c4e1f49a5feb40770cf
12099         * tests/openpgp/run-tests.scm: Move most of the code...
12100         * tests/gpgscm/tests.scm: ... here.
12101
12102         tests: Refactor test runner.
12103         + commit fe36e63763c9c595bb057ac50160d2aff7c7a63f
12104         * tests/openpgp/run-tests.scm (locate-test): New function.
12105         (test): Factor-out the code starting the child process.
12106         (test::binary): New function.
12107
12108         gpgscm: Improve library functions.
12109         + commit e3876f16eb237bdeb9f79aca2e7db5e9e2d86686
12110         * tests/gpgscm/tests.scm (absolute-path?): New function.
12111         (canonical-path): Use the new function.
12112         * tests/gpgscm/lib.scm (string-split-pln): New function.
12113         (string-indexp, string-splitp): Likewise.
12114         (string-splitn): Express using the above function.
12115         (string-ltrim, string-rtrim): Fix corner case.
12116         (list->string-reversed): New function.
12117         (read-line): Fix performance.
12118
12119 2016-12-12  Werner Koch  <wk@gnupg.org>
12120
12121         gpg: Fix memory leak in ecc key generation.
12122         + commit 98433c70431dfbde99b0e89416856d1eef9ebc88
12123         * g10/keygen.c (ecckey_from_sexp): Release curve.
12124
12125         gpg: Do not use a fixed string for --gpgconf-list:default_pubkey_algo.
12126         + commit f1304ee9b21e6ceac6c13d04ceddd23fadb5c7f1
12127         * g10/keygen.c (get_default_pubkey_algo): New.
12128         (parse_key_parameter_string): Use it.
12129         * g10/gpg.c (gpgconf_list): Take value from new function.
12130
12131         gpg: Fix algo string parsing of --quick-addkey.
12132         + commit 522e6f798db9f3f3a9e0123fdc389a86ac69dedf
12133         * g10/keygen.c (parse_key_parameter_string): Fix handling of PART==1.
12134         (parse_key_parameter_part): Use default key size if only "rsa", "dsa",
12135         or "elg" is given.
12136
12137 2016-12-09  Justus Winter  <justus@g10code.com>
12138
12139         g10: Create keys that expire in simple key generation mode.
12140         + commit d568a1561642ed9b7b7b6282b86c56786d10a956
12141         * g10/keygen.c (default_expiration_interval): New variable.
12142         (generate_keypair): Use the new default.
12143
12144         tests: Add a test for '--quick-addkey'.
12145         + commit b778d8deedf344c8116362633925b8153c7f1bf1
12146         * tests/openpgp/quick-key-manipulation.scm: Test '--quick-addkey'.
12147
12148         tests: New test using all available compression algorithms.
12149         + commit 59f1562c25119a4fe27411e6350f2149d6147148
12150         * tests/openpgp/Makefile.am (XTESTS): Add new test.
12151         * tests/openpgp/compression.scm: New file.
12152         * tests/openpgp/defs.scm (all-compression-algos): New variable.
12153
12154         g10: List compression algorithms using human-readable names.
12155         + commit c8100fc0faadf8ba35e4df32b4760cc975e3a83d
12156         * g10/gpg.c (list_config): List all enabled compression algorithms
12157         under the key 'compressname'.
12158
12159         g10: Fix memory leak.
12160         + commit 3de9bad359e28ced4a2539e411d222ffd82a4a62
12161         * g10/sign.c (do_sign): Release old signature data.
12162
12163 2016-12-08  Werner Koch  <wk@gnupg.org>
12164
12165         common: Skip the Byte Order Mark in conf files.
12166         + commit 5c7d58222834793629a30248e72b6ea96e832dc4
12167         * common/argparse.c (optfile_parse): Detect and skip the UTF-8 BOM.
12168
12169         Fix 2 compiler warnings.
12170         + commit cb4c7abb774e2d95806d8b0ec6ea5cd130c1b5b8
12171         * dirmngr/loadswdb.c: Set ERR on malloc failure.
12172         * g10/passphrase.c (passphrase_to_dek): Initialize all fields of
12173         HELP_S2K.
12174
12175         wks: New option --status-fd for gpg-wks-client.
12176         + commit 4a04277ad112e0966296133795f93cf6a3daa48e
12177         * tools/wks-util.c: Include status.h.
12178         (statusfp): New global var.
12179         (wks_set_status_fd): New func.
12180         (wks_write_status): New func.
12181         * tools/gpg-wks-client.c: Include status.h.
12182         (oStatusFD): New constant.
12183         (opts): New option --status-fd.
12184         (parse_arguments): Handle that option.
12185         (main): Return STATUS_SUCCESS or STATUS_FAILURE.
12186
12187 2016-12-08  Justus Winter  <justus@g10code.com>
12188
12189         gpgscm: Better error reporting.
12190         + commit e7429b1ced0c69fa7901f888f8dc25f00fc346a4
12191         * tests/gpgscm/ffi.scm: Move the customized exception handling and
12192         atexit logic...
12193         * tests/gpgscm/init.scm: ... here.
12194         (throw): Record the current history.
12195         (throw'): New function that is history-aware.
12196         (rethrow): New function.
12197         (*error-hook*): Use the new throw'.
12198         * tests/gpgscm/main.c (load): Fix error handling.
12199         (main): Save and use the 'sc->retcode' as exit code.
12200         * tests/gpgscm/repl.scm (repl): Print call history.
12201         * tests/gpgscm/scheme.c (_Error_1): Make a snapshot of the history,
12202         use it to provide a accurate location of the expression causing the
12203         error at runtime, and hand the history trace to the '*error-hook*'.
12204         (opexe_5): Tag all lists at parse time with the current location.
12205         * tests/gpgscm/tests.scm: Update calls to 'throw', use 'rethrow'.
12206
12207         gpgscm: Keep a history of calls for error messages.
12208         + commit 404e8a4136bbbab39df7dd5119841e131998cc15
12209         * tests/gpgscm/init.scm (vm-history-print): New function.
12210         * tests/gpgscm/opdefines.h: New opcodes 'CALLSTACK_POP', 'APPLY_CODE',
12211         and 'VM_HISTORY'.
12212         * tests/gpgscm/scheme-private.h (struct history): New definition.
12213         (struct scheme): New field 'history'.
12214         * tests/gpgscm/scheme.c (gc): Mark objects in the history.
12215         (history_free): New function.
12216         (history_init): Likewise.
12217         (history_mark): Likewise.
12218         (add_mod): New macro.
12219         (sub_mod): Likewise.
12220         (tailstack_clear): New function.
12221         (callstack_pop): Likewise.
12222         (callstack_push): Likewise.
12223         (tailstack_push): Likewise.
12224         (tailstack_flatten): Likewise.
12225         (callstack_flatten): Likewise.
12226         (history_flatten): Likewise.
12227         (opexe_0): New variable 'callsite', keep track of the expression if it
12228         is a call, implement the new opcodes, record function applications in
12229         the history.
12230         (opexe_6): Implement new opcode.
12231         (scheme_init_custom_alloc): Initialize history.
12232         (scheme_deinit): Free history.
12233         * tests/gpgscm/scheme.h (USE_HISTORY): New macro.
12234
12235         gpgscm: Add flag TAIL_CONTEXT.
12236         + commit 01256694f006405c54bc2adef63ef0c8f07da9ee
12237         * tests/gpgscm/scheme.c (S_FLAG_TAIL_CONTEXT): New macro.  This flag
12238         indicates that the interpreter is evaluating an expression in a tail
12239         context (see R5RS, section 3.5).
12240         (opexe_0): Clear and set the flag according to the rules layed out in
12241         R5RS, section 3.5.
12242         (opexe_1): Likewise.
12243
12244         gpgscm: Add flags to the interpreter.
12245         + commit a4a69163d9d7e4d9f3339eb5cda0afb947180b26
12246         * tests/gpgscm/scheme-private.h (struct scheme): Add field 'flags'.
12247         * tests/gpgscm/scheme.c (S_OP_MASK): New macro.
12248         (S_FLAG_MASK, s_set_flag, s_clear_flag, s_get_flag): Likewise.
12249         (_s_return): Unpack the encoded opcode and flags.
12250         (s_save): Encode the flags along with the opcode.  Use normal
12251         integers to encode the result.
12252         (scheme_init_custom_alloc): Initialize 'op' and 'flags'.
12253
12254         gpgscm: Implement tags.
12255         + commit fcf5aea44627def43425d03881e20902e7c0331e
12256         * tests/gpgscm/opdefines.h: Add opcodes to create and retrieve tags.
12257         * tests/gpgscm/scheme.c (T_TAGGED): New macro.
12258         (mk_tagged_value): New function.
12259         (has_tag): Likewise.
12260         (get_tag): Likewise.
12261         (mark): Mark tag.
12262         (opexe_4): Implement new opcodes.
12263         * tests/gpgscm/scheme.h (USE_TAGS): New macro.
12264
12265 2016-12-08  Werner Koch  <wk@gnupg.org>
12266
12267         gpg: Fix the fix out-of-bounds access.
12268         + commit a75790b74095828f967c012eff7033f570d93077
12269         * g10/tofu.c (build_conflict_set): Revert to int* and fix calloc.
12270
12271         wks: New option --check for gpg-wks-client.
12272         + commit d8c5e8ccfdb53cc327f7520fc7badc31d0c9c666
12273         * tools/call-dirmngr.c (wkd_get_key): New.
12274         * tools/gpg-wks-client.c (aCheck): New constant.
12275         (opts): New option "--check".
12276         (main): Call command_check.
12277         (command_check): New.
12278
12279         tools: Move a function from gpg-wks-server to wks-util.c.
12280         + commit c3138decd77d788906885b638b344d0d1faf32c0
12281         * tools/gpg-wks-server.c (list_key_status_cb): Remove.
12282         (list_key): Move to ...
12283         * tools/wks-util.c (wks_list_key): here and rename.  Add new args
12284         R_FPR and R_MBOXES and remove the CTX.
12285         (list_key_status_cb): New.
12286         * tools/wks-util.c: Include ccparray.h, exectool.h, and mbox-util.h.
12287         * tools/gpg-wks-server.c (process_new_key): Replace list_key by
12288         wks_list_key.
12289         (check_and_publish): Ditto.
12290
12291 2016-12-08  Justus Winter  <justus@g10code.com>
12292
12293         gpgscm: Generalize 'for-each-p'.
12294         + commit a2bedc8ac6fcdcd1de0a9fa3d540006481387dff
12295         * tests/gpgscm/tests.scm (for-each-p): Generalize to N lists like
12296         for-each.
12297         (for-each-p'): Likewise.
12298
12299         g10: Fix out-of-bounds access.
12300         + commit 3b5b94ceab7c0ed9501c5cf54b4efa17fcd7300a
12301         * g10/tofu.c (build_conflict_set): Use 'char'.
12302
12303 2016-12-08  Werner Koch  <wk@gnupg.org>
12304
12305         tools: Fix use of uninitialized var in mime-maker.
12306         + commit dd03667ab1062bba3b9413c3f8007d63302d1b31
12307         * tools/mime-maker.c (ensure_part): Make sure to set R_PARENT on
12308         error.
12309         (add_missing_headers): Ensure that ERR is set on success.
12310
12311         * tools/wks-util.c (wks_parse_policy): Fix indentation.
12312
12313         tools: Fix memleak in gpgconf.
12314         + commit b265969154741bf9f93167699fe7ddda1d485265
12315         * tools/gpgconf.c (main): Free SOCKETDIR.
12316
12317         gpg: Fix portability problem.
12318         + commit c3008bffac68b6f31e9ae9bad837cdce5de7c0db
12319         * g10/tofu.c (build_conflict_set): Replace variable dynamic array.
12320
12321 2016-12-07  Justus Winter  <justus@g10code.com>
12322
12323         tests: Add test for '--quick-set-expire'.
12324         + commit dec2ae31a46a0f41886c7ad228865cc573f2dea9
12325         * tests/openpgp/quick-key-manipulation.scm: Test '--quick-set-expire'.
12326
12327         tests: Improve quick key manipulation test.
12328         + commit 92df40a3a2ae471fbba00d6d7040230404931fd4
12329         * tests/openpgp/quick-key-manipulation.scm: Do not update the trust
12330         database, rather be more specific when filtering the user ids.
12331
12332 2016-12-06  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
12333
12334         agent: Respect --enable-large-secmem.
12335         + commit 8636ad5023a1bdc527add40a5508f8c5b7c35221
12336         * agent/gpg-agent.c (main): Initialize secmem to the configured buffer
12337         size.
12338
12339 2016-12-06  Justus Winter  <justus@g10code.com>
12340
12341         tests: Add test importing a revocation certificate.
12342         + commit e352ead43fbb0180e1f1c71bf1a000d1954eb777
12343         * tests/openpgp/Makefile.am (XTESTS): Add new test.
12344         * tests/openpgp/import-revocation-certificate.scm: New file.
12345         * tests/openpgp/samplemsgs/revoke-2D727CC768697734.asc: Likewise.
12346
12347         tests: Rename 'error' to 'fail'.
12348         + commit 5b5d881f47c82f320abf440c20b7a1bac078a987
12349         * tests/gpgscm/tests.scm (error): Rename to 'fail'.  'error' is a
12350         primitive function (an opcode) of the TinySCHEME vm, and 'error' is
12351         also defined by R6RS.  Better avoid redefining that.  Fix all call
12352         sites.
12353         * tests/openpgp/4gb-packet.scm: Adapt.
12354         * tests/openpgp/decrypt-multifile.scm: Likewise.
12355         * tests/openpgp/ecc.scm: Likewise.
12356         * tests/openpgp/export.scm: Likewise.
12357         * tests/openpgp/gpgtar.scm: Likewise.
12358         * tests/openpgp/gpgv-forged-keyring.scm: Likewise.
12359         * tests/openpgp/import.scm: Likewise.
12360         * tests/openpgp/issue2015.scm: Likewise.
12361         * tests/openpgp/issue2346.scm: Likewise.
12362         * tests/openpgp/issue2419.scm: Likewise.
12363         * tests/openpgp/key-selection.scm: Likewise.
12364         * tests/openpgp/mds.scm: Likewise.
12365         * tests/openpgp/multisig.scm: Likewise.
12366         * tests/openpgp/setup.scm: Likewise.
12367         * tests/openpgp/signencrypt.scm: Likewise.
12368         * tests/openpgp/ssh-import.scm: Likewise.
12369         * tests/openpgp/tofu.scm: Likewise.
12370         * tests/openpgp/verify.scm: Likewise.
12371
12372         tests: Remove debugging display.
12373         + commit 89ac071eb4c7539e98c7dc17e11f57c620b54e90
12374         * tests/openpgp/tofu.scm: Remove debugging display.
12375
12376 2016-12-06  Neal H. Walfield  <neal@g10code.com>
12377
12378         tests: Update distributed files.
12379         + commit 87972fdef2cd853fb97624d0765686674a19e3c4
12380         * tests/openpgp/Makefile.am (TEST_FILES): Remove tofu-keys.asc,
12381         tofu-keys-secret.asc, tofu-2183839A-1.txt, tofu-BC15C85A-1.txt and
12382         tofu-EE37CF96-1.txt.  Add tofu/conflicting/1C005AF3.gpg,
12383         tofu/conflicting/1C005AF3-secret.gpg, tofu/conflicting/1C005AF3-1.txt,
12384         tofu/conflicting/1C005AF3-2.txt, tofu/conflicting/1C005AF3-3.txt,
12385         tofu/conflicting/1C005AF3-4.txt, tofu/conflicting/1C005AF3-5.txt,
12386         tofu/conflicting/B662E42F.gpg, tofu/conflicting/B662E42F-secret.gpg,
12387         tofu/conflicting/B662E42F-1.txt, tofu/conflicting/B662E42F-2.txt,
12388         tofu/conflicting/B662E42F-3.txt, tofu/conflicting/B662E42F-4.txt,
12389         tofu/conflicting/B662E42F-5.txt, tofu/conflicting/BE04EB2B.gpg,
12390         tofu/conflicting/BE04EB2B-secret.gpg, tofu/conflicting/BE04EB2B-1.txt,
12391         tofu/conflicting/BE04EB2B-2.txt, tofu/conflicting/BE04EB2B-3.txt,
12392         tofu/conflicting/BE04EB2B-4.txt, tofu/conflicting/BE04EB2B-5.txt and
12393         tofu/conflicting/README.
12394
12395         doc: Improve the text in the gpg manual.
12396         + commit 7572d270fcda1614648c6f08d711d5096ffebbe6
12397         * doc/gpg.texi: Improve the text.
12398
12399         g10: Avoid a memory leak.
12400         + commit 6102099985c1b82b6c0bba0464c1f913cc673e96
12401         * g10/gpg.c (main): Free KB when we're done with it.
12402
12403         tests: Change (interactive-shell) to start an interactive shell.
12404         + commit db6d8cfdc118131f497596ef1ffc121949377754
12405         * tests/gpgscm/tests.scm (interactive-shell): Start an interactive
12406         shell.
12407
12408         tests: Check the signature count in the TOFU TFS record.
12409         + commit 17c717d7c92d9a52101fea7e396fc133322a8786
12410         * tests/openpgp/tofu.scm: Check the signature count in the TOFU TFS
12411         record.
12412
12413         tests: Replace data used by the TOFU conflict test.
12414         + commit d5b18d6c55d65e8df2dd112651e3b9b3d9e6e27a
12415         * tests/openpgp/tofu-2183839A-1.txt: Remove file.
12416         * tests/openpgp/tofu-BC15C85A-1.txt: Remove file.
12417         * tests/openpgp/tofu-EE37CF96-1.txt: Remove file.
12418         * tests/openpgp/tofu-keys-secret.asc: Remove file.
12419         * tests/openpgp/tofu-keys.asc: Remove file.
12420         * tests/openpgp/tofu/conflicting/1C005AF3.gpg: New file.
12421         * tests/openpgp/tofu/conflicting/1C005AF3-secret.gpg: New file.
12422         * tests/openpgp/tofu/conflicting/1C005AF3-1.txt: New file.
12423         * tests/openpgp/tofu/conflicting/1C005AF3-2.txt: New file.
12424         * tests/openpgp/tofu/conflicting/1C005AF3-3.txt: New file.
12425         * tests/openpgp/tofu/conflicting/1C005AF3-4.txt: New file.
12426         * tests/openpgp/tofu/conflicting/1C005AF3-5.txt: New file.
12427         * tests/openpgp/tofu/conflicting/B662E42F.gpg: New file.
12428         * tests/openpgp/tofu/conflicting/B662E42F-secret.gpg: New file.
12429         * tests/openpgp/tofu/conflicting/B662E42F-1.txt: New file.
12430         * tests/openpgp/tofu/conflicting/B662E42F-2.txt: New file.
12431         * tests/openpgp/tofu/conflicting/B662E42F-3.txt: New file.
12432         * tests/openpgp/tofu/conflicting/B662E42F-4.txt: New file.
12433         * tests/openpgp/tofu/conflicting/B662E42F-5.txt: New file.
12434         * tests/openpgp/tofu/conflicting/BE04EB2B.gpg: New file.
12435         * tests/openpgp/tofu/conflicting/BE04EB2B-secret.gpg: New file.
12436         * tests/openpgp/tofu/conflicting/BE04EB2B-1.txt: New file.
12437         * tests/openpgp/tofu/conflicting/BE04EB2B-2.txt: New file.
12438         * tests/openpgp/tofu/conflicting/BE04EB2B-3.txt: New file.
12439         * tests/openpgp/tofu/conflicting/BE04EB2B-4.txt: New file.
12440         * tests/openpgp/tofu/conflicting/BE04EB2B-5.txt: New file.
12441         * tests/openpgp/tofu/conflicting/README: New file.
12442         * tests/openpgp/tofu.scm: Update accordingly.
12443
12444         g10: Remove dead code.
12445         + commit bd9ebe1404c1395edd0e029023a9e780c90f6d73
12446         * g10/tofu.c (tofu_set_policy_by_keyid): Remove function.
12447
12448 2016-12-05  Werner Koch  <wk@gnupg.org>
12449
12450         gpg: New option --quick-set-expire.
12451         + commit 41b3d0975de65d1654f5e37c626d7c9b7c9a7a4d
12452         * g10/gpg.c (aQuickSetExpire): New.
12453         (opts): New option --quick-set-expire.
12454         (main): Implement option.
12455         * g10/keyedit.c (menu_expire): Add args FORCE_MAINKEY and
12456         NEWEXPIRATION.  Change semantics of the return value.  Change caller.
12457         (keyedit_quick_set_expire): New.
12458
12459 2016-12-05  Justus Winter  <justus@g10code.com>
12460
12461         tests: New test for '--enarmor' and '--dearmor'.
12462         + commit fae4d06b0ccaa9803e0c0da56c327b0bcfffcac5
12463         * tests/openpgp/Makefile.am (XTESTS): Add new test.
12464         * tests/openpgp/enarmor.scm: New file.
12465
12466 2016-12-03  Werner Koch  <wk@gnupg.org>
12467
12468         gpg: Fix error code arg in ERRSIG status line.
12469         + commit ef10c348bffc7dad19e1832bebc453755d209420
12470         * g10/mainproc.c (check_sig_and_print): Use gpg_err_code to return an
12471         error code in ERRSIG.
12472
12473 2016-12-02  Werner Koch  <wk@gnupg.org>
12474
12475         gpg: New option --default-new-key-algo.
12476         + commit ce29272e24e7b718b8fca9b84bc728e65f3dea24
12477         * common/openpgp-oid.c (openpgp_is_curve_supported): Add optional arg
12478         R_ALGO and change all callers.
12479         * common/util.h (GPG_ERR_UNKNOWN_FLAG): New error code.
12480         * g10/options.h (struct opt): Add field DEF_NEW_KEY_ALGO.
12481         * g10/gpg.c (oDefaultNewKeyAlgo): New enum.
12482         (opts): New option "--default-new-key-algo".
12483         (main): Set the option.
12484         * g10/keygen.c: Remove DEFAULT_STD_ FUTURE_STD_ constants and replace
12485         them by ...
12486         (DEFAULT_STD_KEY_PARAM, FUTURE_STD_KEY_PARAM): new string constants.
12487         (get_keysize_range): Remove arg R_DEF and return that value instead.
12488         Change all callers.
12489         (gen_rsa): Use get_keysize_range instead of the removed
12490         DEFAULT_STD_KEYSIZE.
12491         (parse_key_parameter_part): New function.
12492         (parse_key_parameter_string): New function.
12493         (quick_generate_keypair): Refactor using parse_key_parameter_string.
12494         (generate_keypair): Ditto.
12495         (parse_algo_usage_expire): Ditto.
12496
12497 2016-12-02  Neal H. Walfield  <neal@g10code.com>
12498
12499         g10: Improve debugging output.
12500         + commit cd532bb7b866e104304e2443cc942799c385daa5
12501         * g10/tofu.c (string_to_long): Improve debugging output.
12502         (string_to_ulong): Likewise.
12503
12504 2016-12-01  Neal H. Walfield  <neal@g10code.com>
12505
12506         g10: In the TOFU module, make strings easier to translate.
12507         + commit bd1a1d8582abcfd7f29812942fa70f88d0aec7cf
12508         * g10/tofu.c: Remove dead code.
12509         (time_ago_str): Simplify implementation since we only want the most
12510         significant unit.
12511         (format_conflict_msg_part1): Use ngettext.
12512         (ask_about_binding): Likewise and only emit full sentences.
12513         (show_statistics): Likewise.
12514
12515 2016-12-01  Werner Koch  <wk@gnupg.org>
12516
12517         dirmngr: Add option --standard-resolver.
12518         + commit 304566d3327ef0a85188cce3109d46d5ff47177a
12519         * dirmngr/dirmngr.c (oStandardResolver): New constant.
12520         (opts): New option --standard-resolver.
12521         (parse_rereadable_options): Set option.
12522         * dirmngr/dns-stuff.c: Refactor all code to support the new option.
12523         (standard_resolver): New var.
12524         (enable_standard_resolver, standard_resolver_p): New func.
12525         * dirmngr/http.c (connect_server): Remove USE_DNS_SRV build
12526         conditional.
12527         * dirmngr/ks-engine-hkp.c (map_host): Ditto.
12528         * dirmngr/server.c (cmd_getinfo) <dnsinfo>: Take care of new option
12529         * configure.ac (HAVE_ADNS_IF_TORMODE): Remove var ADNSLIB.  ac_define
12530         USE_ADNS in the adns checking code.  Remove options --disable-dns-srv
12531         and --disable-dns-cert.  Always look for the system resolver.  Print
12532         warning if no system resolver was found.
12533         (USE_DNS_CERT, USE_DNS_SRV): Remove ac_defines.
12534         (HAVE_SYSTEM_RESOLVER): New ac_define.
12535         (USE_DNS_SRV): Remove am_conditional; not used anyway.
12536
12537         gpg: Let only Dirmngr decide whether CERT is supported.
12538         + commit 86efc3ee53abaf1e22b53c1b360c51829e476115
12539         * g10/getkey.c (parse_auto_key_locate): Do not build parts depending
12540         on USE_DNS_CERT.
12541
12542 2016-12-01  Justus Winter  <justus@g10code.com>
12543
12544         tests,build: Fix distcheck.
12545         + commit fbdfe6a514a95fb46f2b811a13709024e2baf252
12546         * tests/openpgp/Makefile.am (sample_msgs): Add messages required for
12547         the new test 'verify-multifile.scm'.
12548
12549         tests: Add test for '--verify --multifile'.
12550         + commit 12af8e84a32df728462da09a00a8bec24a487720
12551         * tests/openpgp/Makefile.am (XTESTS): Add new test.
12552         * tests/openpgp/verify-multifile.scm: New file.
12553
12554 2016-11-30  Justus Winter  <justus@g10code.com>
12555
12556         tests: Add test for '--encrypt --multifile'.
12557         + commit 3c0569e99498c7470ebdb639b4c5ae829af92761
12558         * tests/openpgp/Makefile.am (XTESTS): Add new test.
12559         * tests/openpgp/encrypt-multifile.scm: New file.
12560
12561 2016-11-29  Werner Koch  <wk@gnupg.org>
12562
12563         agent,dirmngr: Tiny restructuring.
12564         + commit aa6ab9e0bc67fe9ce5601047e84ea4a875e8eb64
12565         * agent/gpg-agent.c (handle_connections): Add a comment.
12566         * dirmngr/dirmngr.c (main): Move assuan_sock_close of the listening
12567         socket to ...
12568         (handle_connections): here.  Add a comment why we keep the
12569         listening socket open during a shutdown.
12570
12571         agent,dirmngr: Handle corner case in shutdown mode.
12572         + commit 854adc8ae19749e44cb79dfa0c5401f48012b13a
12573         * agent/gpg-agent.c (handle_connections): Keep on selecting on the
12574         inotify fd even when a shutdown is pending.
12575         * dirmngr/dirmngr.c (handle_connections): Ditto.  Also simplifyy the
12576         use of the HAVE_INOTIFY_INIT cpp conditional.
12577
12578         gpgsm: Allow decryption with a card returning a PKCS#1 stripped key.
12579         + commit 8489b12211098ad58c008cfb74b5cb91849cf68d
12580         * sm/decrypt.c (prepare_decryption): Handle a 16 byte session key.
12581
12582         agent,w32: Initialize nPth in server mode.
12583         + commit 81d6e98cdf4caa3aa92398fc3b8bed397b40f58d
12584         * agent/gpg-agent.c (main) [W32]: Call initialize_modules in server
12585         mode.
12586
12587         gpg: Make --decrypt with output '-&nnnn' work.
12588         + commit a5910e00ace882b8a17169faf4607163ab454af9
12589         * g10/plaintext.c (get_output_file): Check and open special filename
12590         before falling back to stdout.
12591
12592         gpg,sm: Merge the two versions of check_special_filename.
12593         + commit 60b4982836a00ef6b2a97d16f735b3f6b74dce62
12594         * sm/gpgsm.c (check_special_filename): Move to ..
12595         * common/sysutils.c (check_special_filename): here.  Add arg
12596         NOTRANSLATE.
12597         (allow_special_filenames): New local var.
12598         (enable_special_filenames): New public functions.
12599         * sm/gpgsm.c (allow_special_filenames): Remove var.
12600         (main): Call enable_special_filenames instead of setting the var.
12601         (open_read, open_es_fread, open_es_fwrite): Call
12602         check_special_filename with 0 for NOTRANSLATE.
12603         * common/iobuf.c (special_names_enabled): Remove var.
12604         (iobuf_enable_special_filenames): Remove func.
12605         (check_special_filename): Remove func.
12606         (iobuf_is_pipe_filename): Call new version of the function with
12607         NOTRANSLATE set.
12608         (do_open): Ditto.
12609         * g10/gpg.c (main): Call enable_special_filenames instead of
12610         iobuf_enable_special_filenames.
12611         * g10/gpgv.c (main): Ditto.
12612
12613 2016-11-29  Justus Winter  <justus@g10code.com>
12614
12615         g10: Fix memory leak.
12616         + commit 52385a2ba1bf7e53f500ffde5fd34f28e69cf76b
12617         * g10/decrypt.c (decrypt_messages): Properly decrease the reference
12618         count of the armor filters after pushing them.
12619
12620         tools,build: Build WKS tools against libintl.
12621         + commit 9fb5e9c14557f7567cbc7c50b9881b7d7bfa2f12
12622         * tools/Makefile.am (gpg_wks_server_LDADD): Link against libintl.
12623         (gpg_wks_client_LDADD): Likewise.
12624
12625 2016-11-29  Neal H. Walfield  <neal@g10code.com>
12626
12627         Improve some comments.
12628         + commit 522f74f7e377135cf098b6b0b9b35284c1dfc963
12629
12630
12631         g10: Extend TOFU_STATS to always show the validity.
12632         + commit 2f27cb12e30c9f6e780354eecc3ff0039ed52c63
12633         * doc/DETAILS (TOFU_STATS): Rename the VALIDITY field to SUMMARY.  Add
12634         a new field called VALIDITY.
12635         * g10/tofu.c (write_stats_status): Update output accordingly.
12636
12637 2016-11-29  Justus Winter  <justus@g10code.com>
12638
12639         tests: Add test for '--decrypt --multifile'.
12640         + commit bde4fddadc75ad6071e3fc6c0980905de14c03cb
12641         * tests/openpgp/Makefile.am (XTESTS): Add new test.
12642         * tests/openpgp/decrypt-multifile.scm: New file.
12643
12644         gpgscm: Avoid truncating pointers.
12645         + commit e062bc4da8062b822ee85096d9adfcbca8dcb56a
12646         * tests/gpgscm/scheme.c (_alloc_cellseg): Avoid truncating pointers on
12647         systems where sizeof(unsigned long) < sizeof(void *).
12648
12649 2016-11-29  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
12650
12651         dirmngr: Lazily launch ldap reaper thread.
12652         + commit f6728d13e8e544dbd4b9351ed981613e5504293f
12653         * dirmngr/dirmngr.c (main): Avoid calling ldap_wrapper_launch_thread()
12654         Before we need it.
12655         * dirmngr/ldap-wrapper.c (ldap_wrapper): Call
12656         ldap_wrapper_launch_thread() just in time (before any attempt to use
12657         an ldap subprocess).
12658
12659 2016-11-29  Werner Koch  <wk@gnupg.org>
12660
12661         build: Remove more keywords from the generated ChangeLog.
12662         + commit ecc126a7cef371e3b88e65715ba37fb77e92ea0f
12663         * build-aux/gitlog-to-changelog (parse_amend_file): Generalize keyword
12664         removal.
12665
12666 2016-11-28  Justus Winter  <justus@g10code.com>
12667
12668         tests: Add test for the ssh key export.
12669         + commit 47b8b9e2ce5af7fba117ae0b00e10bec414dcfb0
12670         * tests/openpgp/Makefile.am (XTESTS): Add new test.
12671         (sample_keys): Add new files.
12672         * tests/openpgp/samplekeys/authenticate-only.pub.asc: New file.
12673         * tests/openpgp/samplekeys/authenticate-only.sec.asc: Likewise.
12674         * tests/openpgp/ssh-export.scm: Likewise.
12675
12676         g10: Fix iteration over getkey results.
12677         + commit 4db9a425644dccaf81b51ebc97b32a9cc21941a4
12678         * g10/getkey.c (getkey_next): Only ask 'lookup' for the exact match if
12679         our caller requested the key.  Fixes a crash in 'lookup'.
12680
12681         tests: Rename ssh test.
12682         + commit cc1d21342659a7def5d662d0547579f9e0d3b109
12683         * tests/openpgp/ssh.scm: Rename to 'ssh-import.scm'.
12684         * tests/openpgp/Makefile (XTESTS): Likewise.
12685
12686 2016-11-25  NIIBE Yutaka  <gniibe@fsij.org>
12687
12688         scd: Support OpenPGP card V3 for RSA.
12689         + commit b89e63e5c326af71470124b410e6429cbd2b5c43
12690         * scd/app-openpgp.c (struct app_local_s): Remove max_cmd_data and
12691         max_rsp_data fields as Extended Capabilities bits are different.
12692         (get_cached_data) Use extcap.max_certlen_3.
12693         (get_one_do): Don't use exmode=1.
12694         (determine_rsa_response): New.
12695         (get_public_key, do_genkey): Call determine_rsa_response.
12696         (do_sign): Use keyattr[0].rsa.n_bits / 8, instead of max_rsp_data.
12697         (do_auth): Use keyattr[2].rsa.n_bits / 8, instead of max_rsp_data.
12698         (do_decipher): Likewise with Use keyattr[1].rsa.n_bits / 8.
12699         (show_caps): Remove max_cmd_data and max_rsp_data.
12700         (app_select_openpgp): Likewise.
12701
12702 2016-11-23  Justus Winter  <justus@g10code.com>
12703
12704         gpgscm: Make 'reverse' compatible with 'reverse_in_place'.
12705         + commit 005d326d19ba28005182205f25edc4f7499ec0b5
12706         * tests/gpgscm/scheme.c (reverse): Update prototype, add terminator
12707         argument.
12708         (opexe_4): Update callsite.
12709
12710         gpgscm: Clean sweeped cells.
12711         + commit 3fb9954c43425775a517060959dad01fa00238f7
12712         * tests/gpgscm/scheme.c (gc): Zero typeflag and car of free cells.
12713
12714         gpgscm: Fix initialization of 'sink'.
12715         + commit 7856e3efaad7614979bc0b91379a0a4dcbc739d5
12716         * tests/gpgscm/scheme.c (scheme_init_custom_alloc): Also initialize
12717         cdr.
12718
12719 2016-11-23  Neal H. Walfield  <neal@g10code.com>
12720
12721         g10: Avoid gratuitously loading a keyblock when it is already available.
12722         + commit 03a65a53231cc3132a50a1871e81a512c44da169
12723         * g10/trust.c (get_validity): Add new, optional parameter KB.  Only
12724         load the keyblock if KB is NULL.  Update callers.
12725         (get_validity): Likewise.
12726         * g10/trustdb.c (tdb_get_validity_core): Likewise.
12727
12728 2016-11-22  Neal H. Walfield  <neal@g10code.com>
12729
12730         g10: Use es_fopen instead of open.
12731         + commit bfeafe2d3f9bbaa7f11f3ad870a446141c038b0d
12732         * g10/tofu.c: Don't include <utime.h>, <fcntl.h> or <unistd.h>.
12733         (busy_handler): Replace use of open with es_fopen.
12734
12735         g10: If the set of UTKs changes, invalidate any changed policies.
12736         + commit 44c17bcb003a3330f595a6ab144e8439b7b630cb
12737         * g10/trustdb.c (tdb_utks): New function.
12738         * g10/tofu.c (check_utks): New function.
12739         (initdb): Call it.
12740         * tests/openpgp/tofu.scm: Modify test to check the effective policy of
12741         keys whose effective policy changes when we change the set of UTKs.
12742
12743 2016-11-22  NIIBE Yutaka  <gniibe@fsij.org>
12744
12745         scd: Fix receive buffer size.
12746         + commit 5c2db9dedfe9dbb14ffec24751ca23a69cead94e
12747         * scd/apdu.c (send_le): Fix the size, adding two for status
12748         bytes to Le.
12749
12750 2016-11-22  Justus Winter  <justus@g10code.com>
12751
12752         gpgscm: Refactor.
12753         + commit a3b258d1d15953816e0567511ecc527a4ccdd626
12754         * tests/gpgscm/scheme.c (opexe_0): Reduce code duplication.
12755
12756         gpgscm: Fix property lists.
12757         + commit d8df80427238cdbb9ae0f6dae8bc7e9c24f6e265
12758         * tests/gpgscm/opdefines.h (put, get): Check arguments.  Also rename
12759         to 'set-symbol-property' and 'symbol-property', the names used by
12760         Guile, because put and get are too unspecific.
12761         * tests/gpgscm/scheme.c (hasprop): Only symbols have property lists.
12762         (get_property): New function.
12763         (set_property): Likewise.
12764         (opexe_4): Use the new functions.
12765
12766         gpgscm: Fix installation of error handler.
12767         + commit 7b4e2ea274ace22245264f1759279390d0300a62
12768         * tests/gpgscm/ffi.scm: Set '*error-hook*' again so that the
12769         interpreter will use our function.
12770
12771         gpgscm: Use a static pool of cells for small integers.
12772         + commit 66834eb838a8892d088f6b7332084a64d9f15008
12773         * tests/gpgscm/scheme-private.h (struct scheme): New fields for the
12774         static integer cells.
12775         * tests/gpgscm/scheme.c (_alloc_cellseg): New function.
12776         (alloc_cellseg): Use the new function.
12777         (MAX_SMALL_INTEGER): New macro.
12778         (initialize_small_integers): New function.
12779         (mk_small_integer): Likewise.
12780         (mk_integer): Return a small integer if possible.
12781         (_s_return): Do not free 'op' if it is a small integer.
12782         (s_save): Use a small integer to box the opcode.
12783         (scheme_init_custom_alloc): Initialize small integers.
12784         (scheme_deinit): Free chunk of small integers.
12785         * tests/gpgscm/scheme.h (USE_SMALL_INTEGERS): New macro.
12786
12787         tests: Delay querying the avaliable algorithms.
12788         + commit 893a3f7fb46021961914a8acdf1292a80e3eba93
12789         * tests/openpgp/defs.scm: Set verbosity earlier, turn 'all-*-algos'
12790         into promises.
12791         * tests/openpgp/conventional-mdc.scm: Force the promises.
12792         * tests/openpgp/conventional.scm: Likewise.
12793         * tests/openpgp/encrypt-dsa.scm: Likewise.
12794         * tests/openpgp/encrypt.scm: Likewise.
12795         * tests/openpgp/gpgtar.scm: Likewise.
12796         * tests/openpgp/sigs.scm: Likewise.
12797
12798         g10: Fix memory leak.
12799         + commit 6ce14a805f1da687dfb8535db57730d5c7403db7
12800         * g10/tofu.c (tofu_notice_key_changed): Remove spurious duplicate call
12801         to 'hexfingerprint'.
12802
12803 2016-11-21  Neal H. Walfield  <neal@g10code.com>
12804
12805         g10: Cache the effective policy.  Recompute it when required.
12806         + commit 037f9de09298a31026ea2ab5fbd4a599b11cc34f
12807         * g10/tofu.c (initdb): Add column effective_policy to the bindings
12808         table.
12809         (record_binding): New parameters effective_policy and set_conflict.
12810         Save the effective policy.  If SET_CONFLICT is set, then set conflict
12811         according to CONFLICT.  Otherwise, preserve the current value of
12812         conflict.  Update callers.
12813         (get_trust): Don't compute the effective policy here...
12814         (get_policy): ... do it here, if it was not cached.  Take new
12815         parameters, PK, the public key, and NOW, the time that the operation
12816         started.  Update callers.
12817         (show_statistics): New parameter PK.  Pass it to get_policy.  Update
12818         callers.
12819         (tofu_notice_key_changed): New function.
12820         * g10/gpgv.c (tofu_notice_key_changed): New stub.
12821         * g10/import.c (import_revoke_cert): Take additional argument CTRL.
12822         Pass it to keydb_update_keyblock.
12823         * g10/keydb.c (keydb_update_keyblock): Take additional argument CTRL.
12824         Update callers.
12825         [USE_TOFU]: Call tofu_notice_key_changed.
12826         * g10/test-stubs.c (tofu_notice_key_changed): New stub.
12827         * tests/openpgp/tofu.scm: Assume that manually setting a binding's
12828         policy to auto does not cause the tofu engine to forget about any
12829         conflict.
12830
12831         g10: Correctly parameterize ngettext.
12832         + commit 182efc5b5d20ac0d43501a22f349a23dc06a27a4
12833         * g10/tofu.c (ask_about_binding): Correctly parameterize ngettext.
12834
12835         g10: Don't use the same variable for multiple SQL compiled statements.
12836         + commit 7142b293c870d73ce0146bfb90e6a556e0079650
12837         * g10/tofu.c (struct tofu_dbs_s): Remove unused field
12838         record_binding_update2.  Replace register_insert with
12839         register_signature and register_encryption.
12840         (tofu_register_signature): Don't use dbs->s.register_insert, but
12841         dbs->s.register_signature.
12842         (tofu_register_encryption): Don't use dbs->s.register_insert, but
12843         dbs->s.register_encryption.
12844
12845         g10: Add a convenience function for checking if a key is a primary key.
12846         + commit 91a0483c5db8ee4510981448a705981ee1cce199
12847         * g10/keydb.h (pk_is_primary): New function.
12848         * g10/tofu.c (get_trust): Use it.
12849         (tofu_register_signature): Likewise.
12850         (tofu_register_encryption): Likewise.
12851         (tofu_set_policy): Likewise.
12852         (tofu_get_policy): Likewise.
12853
12854 2016-11-21  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
12855
12856         doc: Ship example gpg-agent-browser.socket in examples/systemd-user/.
12857         + commit 0540cfbee455b197edd89b602a4b47ebf0be8588
12858         * doc/Makefile.am: Ship gpg-agent-browser.socket alongside the other
12859         systemd user service example files.
12860
12861 2016-11-21  NIIBE Yutaka  <gniibe@fsij.org>
12862
12863         agent: Fix npth + daemon mode problem.
12864         + commit 9a707a223a3d45ccf245dee7989ca144e4e6bb49
12865         * agent/gpg-agent.c (main): Remove duplicated initialization in daemon
12866         mode.
12867
12868 2016-11-18  Werner Koch  <wk@gnupg.org>
12869
12870         Release 2.1.16.
12871         + commit 0a641ad25d8c3b91dc32bb9f3f1ae49ae539a4f7
12872
12873
12874 2016-11-18  Ineiev  <ineiev@gnu.org>
12875
12876         po: Update Russian translation.
12877         + commit 11aaa9c6d4ed3e47de45b4aee925ab1065120988
12878
12879
12880 2016-11-18  NIIBE Yutaka  <gniibe@fsij.org>
12881
12882         g10: Fix flags to open for lock of ToFU.
12883         + commit 1c0b140cccfb884c6d07785c3284b9df06dccd3c
12884         * g10/tofu.c (busy_handler): Fix the flags and utime is not needed.
12885
12886 2016-11-18  Werner Koch  <wk@gnupg.org>
12887
12888         dirmngr: Use a longer timer tick interval.
12889         + commit 833eef974ad4721b9b3e247bae9c890476a936ce
12890         * dirmngr/dirmngr.c (TIMERTICK_INTERVAL): Always use 60 seconds like
12891         we did for WindowsCE.
12892
12893 2016-11-18  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
12894
12895         dirmngr: More w32 system daemon cleanup.
12896         + commit b3a917201207898059c048dd101344765201b03c
12897         * dirmngr/dirmngr.c (handle_tick): Remove w32 tests for
12898         shutdown_pending; no longer needed.
12899
12900 2016-11-18  NIIBE Yutaka  <gniibe@fsij.org>
12901
12902         g10: Fix creating a lock for ToFU.
12903         + commit b2e1b17efa952afcf7aeec8b15e9d0088dba587a
12904         * g10/tofu.c (busy_handler): Add third argument which is mandatory for
12905         O_CREATE flag.
12906
12907         scd: Don't limit to ST-2xxx for PC/SC.
12908         + commit b6066ab18a67195817babaf9eccf896c2b3c7b0e
12909         * scd/apdu.c (pcsc_vendor_specific_init): Only check vender ID.
12910
12911 2016-11-17  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
12912
12913         dirmngr: Use a default keyserver if none is explicitly set.
12914         + commit 8fb482252436b3b4b0b33663d95d1d17188ad1d9
12915         * configure.ac: Define DIRMNGR_DEFAULT_KEYSERVER.
12916         * dirmngr/server.c (ensure_keyserver): Use it if no keyservers are set.
12917         * doc/dirmngr.texi: Document this behavior.
12918
12919         dirmngr: Add system CAs if no hkp-cacert is given.
12920         + commit 7c1613d41566f7d8db116790087de323621205fe
12921         * dirmngr/dirmngr.c (http_session_new): If the user isn't talking to
12922         the HKPS pool, and they have not specified any hkp-cacert, then we
12923         should default to the system CAs, rather than nothing.
12924         * doc/dirmngr.texi: Document choice of CAs.
12925
12926         dirmngr: Register hkp-cacert even if the file doesn't exist yet.
12927         + commit c4e02a3b7ad6ee1da6bfc439921378bdbd5c029c
12928         * dirmngr/dirmngr.c (parse_readable_options): If we're unable to turn
12929         an argument for hkp-cacert into an absolute filename, terminate
12930         completely.
12931         * dirmngr/http.c (http_register_tls_ca): Show a warning if file is not
12932         immediately accessible, but register it anyway.
12933
12934 2016-11-17  Justus Winter  <justus@g10code.com>
12935
12936         gpgscm: Re-enable the garbage collector in case of errors.
12937         + commit 4f189325a409bb08f7a8eabfac3f4579288cf5c5
12938         * tests/gpgscm/scheme.c (opexe_0): Enable gc before calling 'Error_1'.
12939
12940         gpgscm: Fix string.
12941         + commit fc53a4d06eaf891143ab4efec9caffe31ebc2bc0
12942         * tests/gpgscm/scheme.c (type_to_string): Fix string.
12943
12944 2016-11-17  Werner Koch  <wk@gnupg.org>
12945
12946         dirmngr: Auto-sownload the swdb.lst.
12947         + commit bd91f92ace09263e3a91177f2a1644379baeb08a
12948         * dirmngr/dirmngr.h (struct opt): Add field allow_version_check.
12949         * dirmngr/dirmngr.c (oAllowVersionCheck): New.
12950         (opts): Add --allow-version-check.
12951         (network_activity_seen): New variable.
12952         (parse_rereadable_options): Set opt.allow_version_check.
12953         (main) <aGPGConfList>: Do not anymore set the no change flag for
12954         Windows.  Add allow-version-check.
12955         (netactivity_action): Set network_activity_seen.
12956         (housekeeping_thread): Call dirmngr_load_swdb.
12957         * tools/gpgconf-comp.c (gc_options_dirmngr): Add allow-version-check.
12958         Make "use-tor" available at Basic level.
12959
12960         dirmngr: Improve downloading of swdb.lst.
12961         + commit c45ca316a54665915ae08399484db271566db7c0
12962         * dirmngr/loadswdb.c (time_of_saved_swdb): Aslo return the "verified"
12963         timestamp.
12964         (dirmngr_load_swdb): Avoid unnecessary disk or network access witout
12965         FORCE.  Do not update swdb.lst if it did not change.
12966
12967         gpgconf: Change the displayed names of the components.
12968         + commit d8da5bc50b856db3445435780311c9f8e52a5144
12969
12970
12971 2016-11-16  Werner Koch  <wk@gnupg.org>
12972
12973         dirmngr: Add command to only load the swdb.
12974         + commit 52c10a280af6ce06eb1732ff35b095f2b8d24b9f
12975         * dirmngr/loadswdb.c: New.
12976         * dirmngr/Makefile.am (dirmngr_SOURCES): Add that file.
12977         * dirmngr/server.c: Remove includes cpparray.h and exectool.h.
12978         (cmd_loadswdb): New.
12979         (parse_version_number,parse_version_string): Remove.
12980         (my_mktmpdir, cmp_version): Remove.
12981         (fetch_into_tmpdir): Remove.
12982         (struct verify_swdb_parm_s): Remove.
12983         (verify_swdb_status_cb): Remove.
12984         (cmd_versioncheck): Remove.
12985         (register_commands): Register LOADSWDB.  Remove VERSIONCHECK.
12986
12987         scd,dirmngr: Keep the standard fds when daemonizing.
12988         + commit 4839e6d002a8ad1f7d3260792c3c9641e258f342
12989         * dirmngr/dirmngr.c (main): Before calling setsid do not close the
12990         standard fds but connect them to /dev/null.
12991         * scd/scdaemon.c (main): Ditto.  Noet that the old test for a log
12992         stream was even reverted.
12993
12994         common: Rename keybox_file_rename to gnupg_rename_file.
12995         + commit c4506a3f15bba5d257cb4c6738800c5e00ecc9a2
12996         * kbx/keybox-util.c (keybox_file_rename): Rename to ...
12997         * common/sysutils.c (gnupg_rename_file): this.  Change all callers.
12998
12999         wks: Always build gpg-wks-client.
13000         + commit c564790df723beef031d83802bd7830737bd330a
13001         * tools/Makefile.am (gpg_wks_client): Remove macro.
13002         (libexec_PROGRAMS): Add gpg-wks-client.
13003
13004         gpg: New option --override-session-key-fd.
13005         + commit 43bfaf2c5417ede621c0a07721952ea549a7a139
13006         * g10/gpg.c (oOverrideSessionKeyFD): New.
13007         (opts): Add option --override-session-key-fd.
13008         (main): Handle that option.
13009         (read_sessionkey_from_fd): New.
13010
13011 2016-11-15  Werner Koch  <wk@gnupg.org>
13012
13013         gpgv: New option --enable-special-filenames.
13014         + commit 500e594c2da530e69a63fc1a40d173458682fa0e
13015         * g10/gpgv.c (oEnableSpecialFilenames): New.
13016         (opts): Add option --enable-special-filenames.
13017         (main): Implement that option.
13018
13019         gpg: Add new compliance mode "de-vs".
13020         + commit b47603a0ac24902c5bb000f8ef27cfb99aceeb81
13021         * g10/options.h (CO_DE_VS): New.
13022         (GNUPG): Also allow CO_DE_VS.
13023         * g10/gpg.c (oDE_VS): New.
13024         (parse_compliance_option): Add "de-vs".
13025         (set_compliance_option): Set "de-vs".
13026         * g10/misc.c (compliance_option_string): Return a description string.
13027         (compliance_failure): Ditto.
13028         * g10/keygen.c (ask_algo): Take care of CO_DE_VS.
13029         (get_keysize_range): Ditto.
13030         (ask_curve): Add new field to CURVES and trun flags into bit flags.
13031         Allow only Brainpool curves in CO_DE_VS mode.
13032
13033         gpg: Use usual free semantics for packet structure free functions.
13034         + commit 8ea3b4c4102dc67ed83d4419b7171e422fc01047
13035         * g10/free-packet.c (free_attributes): Turn function into a nop for a
13036         NULL arg.
13037         (free_user_id): Ditto.
13038         (free_compressed): Ditto.
13039         (free_encrypted): Ditto.
13040         (free_plaintext): Ditto.
13041         (release_public_key_parts): Avoid extra check for NULL.
13042         * g10/getkey.c (get_best_pubkey_byname): Ditto.
13043
13044 2016-11-15  Justus Winter  <justus@g10code.com>
13045
13046         g10: Optimize key iteration.
13047         + commit 12834e84aca9d74800245f0f2f2e6b5123e76173
13048         * g10/getkey.c (get_best_pubkey_byname): Use the node returned by
13049         'getkey_next' instead of doing another lookup.
13050
13051         g10: Fix memory leak.
13052         + commit d20107f6da094edd782947abb357abae5129a12c
13053         * g10/getkey.c (finish_lookup): Clarify that we do not return a
13054         reference.
13055         (lookup): Clarify the relation between RET_KEYBLOCK and RET_FOUND_KEY.
13056         Check arguments.  Actually release the node if it is not returned.
13057
13058         g10: Fix iteration over getkey results.
13059         + commit 1d03cc77e1706f7da653153ad4b58c61e4fd2573
13060         * g10/getkey.c (getkey_next): Fix invocation of 'lookup'.  If we want
13061         to use RET_FOUND_KEY, RET_KEYBLOCK must be valid.
13062
13063         g10: Fix use-after-free.
13064         + commit bd60742925414e0ef2a497df827c1913ea211a44
13065         * g10/getkey.c (pubkey_cmp): Make a copy of the user id.
13066         (get_best_pubkey_byname): Free the user ids.
13067
13068 2016-11-15  Werner Koch  <wk@gnupg.org>
13069
13070         sm: New stub option --compliance.
13071         + commit 26c7c1d72c5f2acb3edb58d610c09a635c87bdbf
13072         * sm/gpgsm.c (oCompliance): New.
13073         (opts): Add "--compliance".
13074         (main): Implement as stub.
13075
13076 2016-11-15  NIIBE Yutaka  <gniibe@fsij.org>
13077
13078         g10: Fix memory leak.
13079         + commit 1f7639ebbe58af1b581b0be7809da9ee55482992
13080         * g10/keyedit.c (menu_adduid): Don't copy 'sig'.
13081
13082 2016-11-15  Werner Koch  <wk@gnupg.org>
13083
13084         gpg: New option --compliance.
13085         + commit f86b1a15ad4bb7bcc1e9f7d209aabcb23641f7df
13086         * g10/gpg.c (oCompliance): New.
13087         (opts): Add "--compliance".
13088         (parse_tofu_policy): Use a generic description string for "help".
13089         (parse_compliance_option): New.
13090         (main): Add option oCompliance.  Factor out code for compliance
13091         setting to ...
13092         (set_compliance_option): new.
13093
13094 2016-11-15  Justus Winter  <justus@g10code.com>
13095
13096         g10: Fix memory leak.
13097         + commit 809d67e74014cb563efd965744fd11f87bbae743
13098         * g10/keyedit.c (menu_adduid): Deallocate 'sig'.
13099
13100         gpgscm: Mark cells requiring finalization.
13101         + commit 64a58e23c38db8658423bbe26fcd650330e24a88
13102         * tests/gpgscm/scheme.c (T_FINALIZE): New macro.
13103         (mk_port): Use the new macro.
13104         (mk_foreign_object): Likewise.
13105         (mk_counted_string): Likewise.
13106         (mk_empty_string): Likewise.
13107         (gc): Only call 'finalize_cell' for cells with the new flag.
13108
13109         gpgscm: Recover more cells.
13110         + commit 93cc322ac06d3045a24aece90091f7f80f3dacb8
13111         * tests/gpgscm/scheme.c (_s_return): Recover the cell holding the
13112         opcode.
13113
13114 2016-11-14  Justus Winter  <justus@g10code.com>
13115
13116         g10: Fix memory leak.
13117         + commit 2cd281c4def1ea881b92b9aba18c1892f89c1870
13118         * g10/mainproc.c (check_sig_and_print): Free 'pk'.
13119
13120         gpgscm: Avoid cell allocation overhead.
13121         + commit 83c184a66b73f312425b01008f0495610e5329a4
13122         * tests/gpgscm/scheme-private.h (struct scheme): New fields
13123         'inhibit_gc', 'reserved_cells', and 'reserved_lineno'.
13124         * tests/gpgscm/scheme.c (GC_ENABLED): New macro.
13125         (USE_GC_LOCKING): Likewise.
13126         (gc_reservations): Likewise.
13127         (gc_reservation_failure): New function.
13128         (_gc_disable): Likewise.
13129         (gc_disable): New macro.
13130         (gc_enable): Likewise.
13131         (gc_enabled): Likewise.
13132         (gc_consume): Likewise.
13133         (get_cell_x): Consume reserved cell if garbage collection is disabled.
13134         (_get_cell): Assert that gc is enabled.
13135         (get_cell): Only record cell in the list of recently allocated cells
13136         if gc is enabled.
13137         (get_vector_object): Likewise.
13138         (gc): Assert that gc is enabled.
13139         (s_return): Add comment, adjust call to '_s_return'.
13140         (s_return_enable_gc): New macro.
13141         (_s_return): Add flag 'enable_gc' and re-enable gc if set.
13142         (oblist_add_by_name): Use the new facilities to protect the
13143         allocations.
13144         (new_frame_in_env): Likewise.
13145         (new_slot_spec_in_env): Likewise.
13146         (s_save): Likewise.
13147         (opexe_0): Likewise.
13148         (opexe_1): Likewise.
13149         (opexe_2): Likewise.
13150         (opexe_5): Likewise.
13151         (opexe_6): Likewise.
13152         (scheme_init_custom_alloc): Initialize the new fields.
13153
13154 2016-11-14  NIIBE Yutaka  <gniibe@fsij.org>
13155
13156         scd: Fix status info encoding.
13157         + commit 4ee4d0b02172cf56d9582bb99e32a65c75315b25
13158         * scd/command.c (send_status_info): Do percent plus encoding correctly.
13159
13160 2016-11-12  Werner Koch  <wk@gnupg.org>
13161
13162         agent: Improve concurrency when Libgcrypt 1.8 is used.
13163         + commit 6bf698197222bf6081c249c815aebb075e8ec820
13164         * agent/gpg-agent.c (thread_init_once): Tell Libgcrypt to reinit the
13165         system call clamp.
13166         (agent_libgcrypt_progress_cb): Do not sleep if Libgcrypt is recent
13167         enough.
13168
13169 2016-11-11  Werner Koch  <wk@gnupg.org>
13170
13171         agent: Kludge to mitigate blocking calls in Libgcrypt.
13172         + commit 4473db1ef24031ff4e26c9a9de95dbe898ed2b97
13173         * agent/gpg-agent.c (agent_libgcrypt_progress_cb): Sleep for 100ms on
13174         "need_entropy".
13175
13176         dirmngr: Prepare to trigger jobs by network activity.
13177         + commit 7b04a43c05834b937b32a596f1941e9728add5fa
13178         * dirmngr/http.c (netactivity_cb): New.
13179         (http_register_netactivity_cb): New.
13180         (notify_netactivity): New.
13181         (connect_server): Call that function.
13182         * dirmngr/dirmngr.c (main): Call http_register_netactivity_cb.
13183         (netactivity_action): New stub handler.
13184
13185 2016-11-11  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
13186
13187         agent: Clean up comments.
13188         + commit e51912f467fda963c7abcfcd4082d6eb084ba5be
13189         * agent/agent.h: Clean up comments.
13190
13191 2016-11-10  Werner Koch  <wk@gnupg.org>
13192
13193         gpg,sm: Add STATUS_ERROR keydb_search and keydb_add-resource.
13194         + commit 5d13581f4737c18430f6572dd4ef486d1ad80dd1
13195         * g10/keydb.c (keydb_add_resource): Make ANY_REGISTERED
13196         file-global.  Write a STATUS_ERROR.
13197         (maybe_create_keyring_or_box): Check for non-accessible but existant
13198         file.
13199         (keydb_search): Write a STATUS_ERROR if no keyring has been registered
13200         but continue to return NOT_FOUND.
13201         * sm/keydb.c (keydb_add_resource): Rename ANY_PUBLIC to ANY_REGISTERED
13202         and make file-global.  Write a STATUS_ERROR.
13203         (keydb_search): Write a STATUS_ERROR if no keyring has been registered
13204         but continue to return NOT_FOUND.  Also add new arg CTRL and change
13205         all callers to pass it down.
13206
13207         sm: Remove unused arg SECRET from keydb functions.
13208         + commit c8044c6e335f044d7386b9e8869bc4a0d3adff70
13209         * sm/keydb.c (struct resource_item): Remove field 'secret'.
13210         (keydb_add_resource): Remove arg 'secret' and change all callers.
13211         (keydb_new): Ditto.
13212
13213 2016-11-10  Justus Winter  <justus@g10code.com>
13214
13215         gpgscm: Recover cells from the list of recently allocated cells.
13216         + commit ee08677d63a900cea85228024861a4f5c5a87c69
13217         * tests/gpgscm/scheme.c (ok_to_freely_gc): Recover cells.
13218
13219         gpgscm: Recover cells used to maintain interpreter state.
13220         + commit e0cbd3389e2dd6ec19ee3a4c7bad81fa0f1907f5
13221         * tests/gpgscm/scheme.c (free_cell): New function.
13222         (free_cons): Likewise.
13223         (_s_return): Use the new function to recover cells used to save the
13224         state of the interpreter in 's_save'.  This reduces the need to do a
13225         garbage collection considerably.
13226
13227         gpgscm: Reduce opcode dispatch overhead.
13228         + commit d3a98ff5bc972a4c9b01b9e5338a4a59b5b4ac48
13229         * tests/gpgscm/scheme.c (s_thread_to): New macro.
13230         (CASE): Likewise.
13231         (opexe_[0-6]): Use 'CASE' instead of 'case' statements, replace
13232         's_goto' with 's_thread_to' where applicable.
13233
13234         gpgscm: Make the compile-hook configurable.
13235         + commit 568cfcde45a0d6c456d8f8be1ea0e408416badad
13236         * tests/gpgscm/scheme-private.h (struct scheme): Make field
13237         'COMPILE_HOOK' optional.
13238         * tests/gpgscm/scheme.c (opexe_0): Fix guard.
13239         (scheme_init_custom_alloc): Conditionally initialize 'COMPILE_HOOK'.
13240         * tests/gpgscm/scheme.h (USE_COMPILE_HOOK): Define to 1 by default.
13241
13242         gpgscm: Drop obsolete commented-out code.
13243         + commit 9ee184bc0afaea06785d836ed175b851b9ae532f
13244         * tests/gpgscm/scheme.c (opexe_5): Drop obsolete code.
13245
13246         gpgscm: Remove dubious stack implementation.
13247         + commit d7c5799c282a03dcce0e3d327075233353cb76cc
13248         * tests/gpgscm/scheme-private.h (struct scheme): Remove related fields.
13249         * tests/gpgscm/scheme.c: Drop all !USE_SCHEME_STACK code.
13250         * tests/gpgscm/scheme.h (USE_SCHEME_STACK): Remove macro.
13251
13252 2016-11-10  Werner Koch  <wk@gnupg.org>
13253
13254         gpg: Improve error message for --quick-gen-key.
13255         + commit 088d955bd8a6ec8bbf76c8a4c01eb08499d1d9fa
13256         * g10/keygen.c (parse_algo_usage_expire): Use a different error
13257         message for an unknown algorithm name.
13258
13259         dirmngr: Improve concurrency in the non-adns case.
13260         + commit c7ea98cd3d44abf00e32c081e5049ad1d0b1f12c
13261         * dirmngr/dns-stuff.c (map_adns_status_to_gpg_error): New.
13262         (resolve_name_adns, get_dns_cert, get_dns_cname): Use that function.
13263         (getsrv) [!USE_ADNS]: Call res_query outside of nPth.
13264
13265 2016-11-08  Justus Winter  <justus@g10code.com>
13266
13267         tests: Fix environment setup.
13268         + commit 1062953d5132af674aacfc6372e3e9f066c5d145
13269         * tests/openpgp/defs.scm (setup-legacy-environment): Do not call
13270         'setup-environment' because that will start the agent, and hence
13271         register the atexit function twice.
13272
13273         Fixes: a55393cb5f4b331cb3a715c7d9a8b91f7606f337
13274
13275         tests: Log and display output from tests when run in parallel.
13276         + commit 2a7615c48ed79e6b28710cc293ce30c812b2e5b0
13277         * tests/openpgp/run-tests.scm (test): Add field 'logfd'.
13278         (test::new, test::set-*): Adapt accordingly.
13279         (test::set-logfd): New function.
13280         (test::open-log-file): Likewise.
13281         (test::run-sync): Use the new function.
13282         (test::run-async): Likewise.
13283         (test::report): Replay the log.
13284         (run-tests-parallel): Reverse the results to restore the original
13285         order.
13286
13287         tests: Simplify test.
13288         + commit 4dd4801bfa4c3f7ba279b3d171a8ed299dbffaaa
13289         * tests/openpgp/issue2417.scm: Simplify.
13290
13291         gpgscm: Expose seek and associated constants.
13292         + commit 591d61d80f4f81176f7e236df794922df9e001a1
13293         * tests/gpgscm/ffi.c (do_seek): New function.
13294         (ffi_init): Expose 'seek' and 'SEEK_{SET,CUR,END}'.
13295         * tests/gpgscm/lib.scm: Document the new function.
13296
13297         gpgscm: Fix error message.
13298         + commit d4454837cd60981c2863955b11c9e1cc8f9e3833
13299         * tests/gpgscm/ffi.c (do_wait_processes): Fix and improve error
13300         messages.
13301
13302         tests,w32: Make cleanup more robust.
13303         + commit dd13b2a561e31045fd3d3576bab99543cd4eb6cc
13304         * tests/openpgp/run-tests.scm (run-tests-parallel): Catch errors when
13305         removing the working directory.  On Windows this can fail if there is
13306         still a process using one of the files there.
13307         (run-tests-sequential): Likewise.
13308
13309         common,w32: Simplify locking.
13310         + commit 7cbb0803847b8db618d39ff50ae6015e409ab1ae
13311         * common/asshelp.c (lock_spawning): Use the same code on Windows that
13312         we use on all other platforms.
13313         (unlock_spawning): Likewise.
13314
13315 2016-11-07  Justus Winter  <justus@g10code.com>
13316
13317         tests: Write a log file for each test.
13318         + commit 26df829fa22f027ca4a5eaf155cdaa2123afbdd5
13319         * tests/openpgp/Makefile.am (CLEANFILES): Delete logs.
13320         * tests/openpgp/run-tests.scm (test::run-sync): Write logs.
13321
13322         gpgscm: Generalize splice to write to multiple sinks.
13323         + commit abe0cc7a21d2b0b5c77cc525b999d1ede2d29185
13324         * tests/gpgscm/ffi.c (ordinal_suffix): New function.
13325         (do_splice): Generalize splice to write to multiple sinks.
13326         * tests/gpgscm/lib.scm (splice): Document this fact.
13327
13328         gpgscm: Drop 'len' argument from splice.
13329         + commit 4d98a72b88cf167295e1ecd6125b9c7a11b6239f
13330         * tests/gpgscm/ffi.c (do_splice): Drop 'len' argument, no-one uses it.
13331         * tests/gpgscm/lib.scm (splice): Document foreign function.
13332
13333         tests: Move environment creation and teardown into each test.
13334         + commit a55393cb5f4b331cb3a715c7d9a8b91f7606f337
13335         * tests/gpgscm/tests.scm (log): New function.
13336         * tests/openpgp/run-tests.scm (run-tests-parallel): Do not run the
13337         startup and teardown scripts.
13338         (run-tests-sequential): Likewise.
13339         * tests/openpgp/setup.scm: Move all functions...
13340         * tests/openpgp/defs.scm: ... here and make them less verbose.
13341         (setup-environment): New function.
13342         (setup-legacy-environment): Likewise.
13343         (start-agent): Make less verbose, run 'stop-agent' at interpreter
13344         exit.
13345         (stop-agent): Make less verbose.
13346         * tests/openpgp/finish.scm: Drop file.
13347         * tests/openpgp/Makefile.am (EXTRA_DIST): Drop removed file.
13348         * tests/openpgp/4gb-packet.scm: Use 'setup-environment' or
13349         'setup-legacy-environment' as appropriate.
13350         * tests/openpgp/armdetach.scm: Likewise.
13351         * tests/openpgp/armdetachm.scm: Likewise.
13352         * tests/openpgp/armencrypt.scm: Likewise.
13353         * tests/openpgp/armencryptp.scm: Likewise.
13354         * tests/openpgp/armor.scm: Likewise.
13355         * tests/openpgp/armsignencrypt.scm: Likewise.
13356         * tests/openpgp/armsigs.scm: Likewise.
13357         * tests/openpgp/clearsig.scm: Likewise.
13358         * tests/openpgp/conventional-mdc.scm: Likewise.
13359         * tests/openpgp/conventional.scm: Likewise.
13360         * tests/openpgp/decrypt-dsa.scm: Likewise.
13361         * tests/openpgp/decrypt.scm: Likewise.
13362         * tests/openpgp/default-key.scm: Likewise.
13363         * tests/openpgp/detach.scm: Likewise.
13364         * tests/openpgp/detachm.scm: Likewise.
13365         * tests/openpgp/ecc.scm: Likewise.
13366         * tests/openpgp/encrypt-dsa.scm: Likewise.
13367         * tests/openpgp/encrypt.scm: Likewise.
13368         * tests/openpgp/encryptp.scm: Likewise.
13369         * tests/openpgp/export.scm: Likewise.
13370         * tests/openpgp/finish.scm: Likewise.
13371         * tests/openpgp/genkey1024.scm: Likewise.
13372         * tests/openpgp/gpgtar.scm: Likewise.
13373         * tests/openpgp/gpgv-forged-keyring.scm: Likewise.
13374         * tests/openpgp/import.scm: Likewise.
13375         * tests/openpgp/issue2015.scm: Likewise.
13376         * tests/openpgp/issue2417.scm: Likewise.
13377         * tests/openpgp/issue2419.scm: Likewise.
13378         * tests/openpgp/key-selection.scm: Likewise.
13379         * tests/openpgp/mds.scm: Likewise.
13380         * tests/openpgp/multisig.scm: Likewise.
13381         * tests/openpgp/quick-key-manipulation.scm: Likewise.
13382         * tests/openpgp/seat.scm: Likewise.
13383         * tests/openpgp/shell.scm: Likewise.
13384         * tests/openpgp/signencrypt-dsa.scm: Likewise.
13385         * tests/openpgp/signencrypt.scm: Likewise.
13386         * tests/openpgp/sigs-dsa.scm: Likewise.
13387         * tests/openpgp/sigs.scm: Likewise.
13388         * tests/openpgp/ssh.scm: Likewise.
13389         * tests/openpgp/tofu.scm: Likewise.
13390         * tests/openpgp/use-exact-key.scm: Likewise.
13391         * tests/openpgp/verify.scm: Likewise.
13392         * tests/openpgp/version.scm: Likewise.
13393         * tests/openpgp/issue2346.scm: Likewise and simplify.
13394
13395         tests: Do not allow tests to be run in a shared environment.
13396         + commit ac078469cbafe85cf771fca84f376740850d10b0
13397         * tests/openpgp/README: Update.
13398         * tests/openpgp/run-tests.scm (run-tests-parallel-shared): Drop
13399         function.
13400         (run-tests-parallel-isolated): Rename to 'run-tests-parallel'.
13401         (run-tests-sequential-shared): Drop function.
13402         (run-tests-sequential-isolated): Rename to 'run-tests-sequential'.
13403
13404         tests: Fix build.
13405         + commit 37751d2b194bc33539f5b9ea0e02e9f209d2bcf6
13406         * tests/openpgp/Makefile.am: Drop dependency on 'mk-tdata'.
13407
13408         Fixes: 70215ff470c82d144e872057dfa5a478cc9195f2
13409
13410 2016-11-07  Werner Koch  <wk@gnupg.org>
13411
13412         wks: Encrypt all client mails also the target key,
13413         + commit 56e1864aa337f36317534db521fd4434d70e0784
13414         * tools/gpg-wks-client.c (encrypt_response): Add arg FINGERPRINT.
13415         (send_confirmation_response): Ditto.
13416         (process_confirmation_request): Parse out fingerprint and pass
13417         send_confirmation_response.
13418
13419 2016-11-07  Justus Winter  <justus@g10code.com>
13420
13421         tests,tools: Reimplement 'mk-tdata' in Scheme.
13422         + commit 70215ff470c82d144e872057dfa5a478cc9195f2
13423         * tests/openpgp/defs.scm (tools): Drop 'mk-tdata'.
13424         * tests/openpgp/setup.scm (make-test-data): New function.
13425         * tests/openpgp/verify.scm: Avoid 'mk-tdata'.
13426         * tools/Makefile.am (noinst_PROGRAMS): Drop 'mk-tdata'.
13427         * tools/mk-tdata.c: Drop file.
13428
13429         gpgscm,w32: Provide schemish file handling for binary files.
13430         + commit 413cc50345557e0a516f33b98e8aab19bbc8b4fe
13431         * tests/gpgscm/lib.scm (call-with-binary-input-file): New function.
13432         (call-with-binary-output-file): Likewise.
13433
13434         gpgscm: Add support for pseudo-random numbers.
13435         + commit 6e677f9b55fdb610e93134042ee41ee5c641cbdf
13436         * tests/gpgscm/ffi.c (do_getpid): New function.
13437         (do_srandom): Likewise.
13438         (random_scaled): Likewise.
13439         (do_random): Likewise.
13440         (do_make_random_string): Likewise.
13441         (ffi_init): Expose the new functions.
13442         * tests/gpgscm/lib.scm: Document the new functions.
13443
13444         g10: Fix crash.
13445         + commit 5840353d8bbcd9e75374f3bdb2547ffa7bbea897
13446         * g10/getkey.c (get_best_pubkey_byname): If 'get_pubkey_byname' does
13447         not return a getkey context, then it can return at most one key,
13448         therefore there is nothing to rank.  Also, always initialize '*retctx'
13449         to be on the safe side.
13450
13451         Fixes: ab89164be02012f1bf159c971853b8610e966301
13452
13453 2016-11-04  Justus Winter  <justus@g10code.com>
13454
13455         gpgscm: Fix printing strings containing zero bytes.
13456         + commit 1f45878a72f23d4bae08d73b614096b485f35274
13457         * tests/gpgscm/scheme.c (atom2str): Fix computing the length of Scheme
13458         strings.  Scheme strings can contain zero bytes.
13459
13460         gpgscm: Implement 'atexit'.
13461         + commit 43f8006f5c75e3d15fe200e2fa41587a73bfb07b
13462         * tests/gpgscm/ffi.scm (throw): Run *run-atexit-handlers* when
13463         terminating the interpreter.
13464         (*atexit-handlers*): New variable.
13465         (*run-atexit-handlers*): New function.
13466         (atexit): Likewise.
13467         * tests/gpgscm/main.c (main): Run *run-atexit-handlers* at normal
13468         interpreter shutdown.
13469
13470 2016-11-04  NIIBE Yutaka  <gniibe@fsij.org>
13471
13472         scd: Fix length error for READKEY.
13473         + commit cd00b07ec26c3408e6aee66957b08c6fd319b700
13474         * scd/app-openpgp.c (do_readkey): Decrement the length.
13475
13476         scd: Add --advanced option for READKEY.
13477         + commit f9da935c3eb302e75a80def51128fb6f669661d7
13478         * scd/command.c (cmd_readkey) : Support ADVANCED arg.
13479         * scd/app.c (app_readcert): Add ADVANCED arg.
13480         * scd/app-openpgp.c (do_readkey): Implement ADVANCED arg.
13481         * scd/app-nks.c (do_readkey): Error return with GPG_ERR_NOT_SUPPORTED.
13482
13483 2016-11-03  Werner Koch  <wk@gnupg.org>
13484
13485         agent: Extend the PINENTRY_LAUNCHED inquiry and status.
13486         + commit c1ea0b577a468030d2b006317ba27fc1746c4b14
13487         * agent/call-pinentry.c (start_pinentry): Get flavor and version and
13488         pass it to agent_inq_pinentry_launched.
13489         * agent/command.c (agent_inq_pinentry_launched): Add arg EXTRA.
13490         * g10/server.c (gpg_proxy_pinentry_notify): Print a new diagnostic.
13491
13492 2016-11-03  Justus Winter  <justus@g10code.com>
13493
13494         g10: Improve and unify key selection for -r and --locate-keys.
13495         + commit ab89164be02012f1bf159c971853b8610e966301
13496         * g10/getkey.c (struct pubkey_cmp_cookie): New type.
13497         (key_is_ok, uid_is_ok, subkey_is_ok): New functions.
13498         (pubkey_cmp): Likewise.
13499         (get_best_pubkey_byname): Likewise.
13500         * g10/keydb.h (get_best_pubkey_byname): New prototype.
13501         * g10/keylist.c (locate_one): Use the new function.
13502         * g10/pkclist.c (find_and_check_key): Likewise.
13503         * tests/openpgp/Makefile.am (XTESTS): Add new test.
13504         (TEST_FILES): Add new files.
13505         * tests/openpgp/key-selection.scm: New file.
13506         * tests/openpgp/key-selection/0.asc: Likewise.
13507         * tests/openpgp/key-selection/1.asc: Likewise.
13508         * tests/openpgp/key-selection/2.asc: Likewise.
13509         * tests/openpgp/key-selection/3.asc: Likewise.
13510         * tests/openpgp/key-selection/4.asc: Likewise.
13511
13512         gpgscm,tests: Add new functions to the test environment.
13513         + commit 1ec07cbc209f247fd85704f5701564e31aa56d0b
13514         * tests/gpgscm/lib.scm (first, last, powerset): New functions.
13515         * tests/gpgscm/tests.scm (interactive-shell): New function.
13516         * tests/openpgp/Makefile.am (EXTRA_DIST): Add new file.
13517         * tests/openpgp/README: Document 'interactive-shell'.
13518         * tests/openpgp/shell.scm: New file.
13519
13520 2016-11-03  Werner Koch  <wk@gnupg.org>
13521
13522         gpgconf: Add a new field to the --query-swdb output.
13523         + commit d10b67b9bc32e8feff1be86e6646fc23e58fe45d
13524         * tools/gpgconf.c (query_swdb): Insert new field with the installed
13525         version.  Check that the supplied version does not contain a colon.
13526
13527 2016-11-02  Werner Koch  <wk@gnupg.org>
13528
13529         gpgconf: Add command --query-swdb.
13530         + commit 0ed6a6df5aa421a9c5cdb1e63867f0deee79af9e
13531         * tools/gpgconf.c (aQuerySWDB): New.
13532         (opts): Add --query-swdb.
13533         (valid_swdb_name_p): New.
13534         (query_swdb): New.
13535         (main): Implement command --query-swdb.
13536
13537         common: Improve compare_string_versions.
13538         + commit 488b183811fc25c1ae49b4730491accf1adf518e
13539         * common/stringhelp.c: Include limits.h.
13540         (compare_version_strings): Change semantics to behave like strcmp.
13541         Include the patch lebel in the comparison.  Allow checking a single
13542         version string.
13543         * common/t-stringhelp.c (test_compare_version_strings): Adjust test
13544         vectors and a few new vectors.
13545         * g10/call-agent.c (warn_version_mismatch): Adjust to new sematics.
13546         * g10/call-dirmngr.c (warn_version_mismatch): Ditto.
13547         * sm/call-agent.c (warn_version_mismatch): Ditto.
13548         * sm/call-dirmngr.c (warn_version_mismatch): Ditto.
13549
13550 2016-11-02  Justus Winter  <justus@g10code.com>
13551
13552         gpgscm: Fix inclusion of readline header.
13553         + commit 60ad1a7f37ffc10e601e69a3e2d2bb14af510257
13554         * tests/gpgscm/ffi.c: Define magic macro to prevent the completion
13555         function from redefined.
13556
13557 2016-11-02  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
13558
13559         build: Fix misspelled dirmngr.
13560         + commit 5e693ddfbe44d149ce0d9393d699c613ad5ea706
13561
13562
13563         Spelling: correct spelling of "passphrase".
13564         + commit 68b59bbc42ba9ec69496758743924d54a95742f0
13565         There were several different variant spellings of "passphrase".  This
13566         should fix them all for all English text.
13567
13568         I did notice that po/it.po contains multiple instances of
13569         "passhprase", which also looks suspect to me, but i do not know
13570         Italian, so i did not try to correct it.
13571
13572 2016-11-02  Justus Winter  <justus@g10code.com>
13573
13574         g10,w32: Fix build on Windows.
13575         + commit 5d4f1408d0dd055d412ae44bb4a0f28f74617f05
13576         * g10/tofu.c (begin_transaction): Use the new 'gnupg_usleep'.
13577
13578 2016-10-31  Werner Koch  <wk@gnupg.org>
13579
13580         common: New function gnupg_usleep.
13581         + commit ad491ceec6145b3781a05dc7b4a36052abeeb4b4
13582         * configure.ac (HAVE_NANOSLEEP): Test for nanosleep.
13583         * common/sysutils.c: Always include time.h.
13584         (gnupg_usleep): New.
13585
13586 2016-10-31  Andre Heinecke  <aheinecke@intevation.de>
13587
13588         w32: Fix PKG_CONFIG_LIBDIR in --build-w32.
13589         + commit 3b6b8fe32af7568ff51066d4c2e3679df6dea86f
13590         * autogen.sh: Point pkg-config to the right location.
13591
13592 2016-10-31  Neal H. Walfield  <neal@g10code.com>
13593
13594         g10: Avoid gratuitious SQLite aborts and starving writers.
13595         + commit 7a634e48b13c5d5d295b8fed9b429e1b2109a333
13596         * g10/tofu.c: Include <time.h>, <utime.h>, <fcntl.h> and <unistd.h>.
13597         (tofu_dbs_s): Add fields want_lock_file and want_lock_file_ctime.
13598         (begin_transaction): Only yield if DBS->WANT_LOCK_FILE_CTIME has
13599         changed since we took the lock.  Don't use gpgrt_yield to yield, but
13600         sleep for 100ms.  After taking the batch lock, update
13601         DBS->WANT_LOCK_FILE_CTIME.  Also take the batch lock the first time we
13602         take the real lock.  When taking the real lock, use immediate not
13603         deferred mode to avoid gratuitious aborts.
13604         (end_transaction): When dropping the outermost real lock, drop the
13605         batch lock.
13606         (busy_handler): New function.
13607         (opendbs): Set the busy handler to it when opening the DB.  Initialize
13608         CTRL->TOFU.DBS->WANT_LOCK_FILE.
13609         (tofu_closedbs): Free DBS->WANT_LOCK_FILE.
13610
13611 2016-10-30  Neal H. Walfield  <neal@g10code.com>
13612
13613         g10: Avoid reading in keys when possible.
13614         + commit eec365a02bd35d2d5c9e4d2c8d18bcd9180cf859
13615         * g10/tofu.c (build_conflict_set): If CONFLICT_SET contains a single
13616         element, don't bother to check for cross sigs.  Add parameter PK.
13617         Update callers.
13618
13619         g10: Fix bit setting.
13620         + commit 614ca00676bb8ca12b5107fec0e4ef8818445254
13621         * g10/tofu.c (build_conflict_set): Fix bit setting.
13622
13623 2016-10-28  Werner Koch  <wk@gnupg.org>
13624
13625         gpg: Enable the Issuer Fingerprint from rfc4880bis.
13626         + commit b6f08dbb0b45059cdbbb5d9be9725e437f42a8cc
13627         * g10/build-packet.c (build_sig_subpkt_from_sig): Always write the new
13628         Issuer Fingerprint sub-packet.
13629         * g10/mainproc.c (check_sig_and_print): Always consider that
13630         sub-packet.
13631
13632 2016-10-27  Werner Koch  <wk@gnupg.org>
13633
13634         dirmngr: Fix signature checking.
13635         + commit 5a1f6a0062488aaf345b1c73ba98a540e673d619
13636         * dirmngr/server.c: Include cpparray.h.
13637         (verify_swdb_parm_s): New.
13638         (verify_swdb_status_cb): New.
13639         (cmd_versioncheck): Use gpgv to correclty verify the signature.
13640         Rename some variable to comply with GNU standards.
13641
13642         gpg: Verify multiple detached signatures with different hash algos.
13643         + commit 8fced66be35db5ac2a6bfdb9bccb2c0e582d8256
13644         * g10/mainproc.c (proc_tree): Loose check.  Enable all algos.
13645
13646         common: Add GNUPG_MODULE_NAME_GPGV.
13647         + commit ece9ade4b44fb3d5d120cfd32b23632e5efd2134
13648         * common/util.h (GNUPG_MODULE_NAME_GPGV): New.
13649         * common/homedir.c (gnupg_module_name): Implement.
13650
13651 2016-10-27  Justus Winter  <justus@g10code.com>
13652
13653         g10: Fix iteration over getkey results.
13654         + commit 8ea72a776a88f3c851e812d258355be80caa1bc1
13655         * g10/getkey.c (getkey_next): Return the public key in PK even if
13656         RET_KEYBLOCK is NULL.
13657
13658         g10: Assert preconditions.
13659         + commit 66a0091d74768ab3a4a5342d3645e1834c59045a
13660         * g10/getkey.c (get_pubkey_byname): Assert preconditions.
13661
13662 2016-10-27  Werner Koch  <wk@gnupg.org>
13663
13664         dirmngr: Do not implement --supervised in Windows.
13665         + commit cf20b23c146c9e499263654644035796475de097
13666         * dirmngr/dirmngr.c (opts) [W32]: Remove --supervised.
13667         (main) [W32]: Ditto.
13668
13669         common: Remove debug output from gnupg_get_socket_name.
13670         + commit a9c8b5fbe7ae241bf45bdee15884abc7891aedf9
13671         * common/sysutils.c (gnupg_get_socket_name): Remove debug message and
13672         use my_error_from_syserror.
13673
13674 2016-10-27  NIIBE Yutaka  <gniibe@fsij.org>
13675
13676         dirmngr: ADNS error handling fix.
13677         + commit 45dfc02b47f798f5a3b9973ca6a9f5a907d7e665
13678         * dirmngr/dns-stuff.c (resolve_name_adns, get_dns_cert, get_dns_cname):
13679         Use gpg_error and gpg_err_code_from_errno to compose the error value.
13680
13681 2016-10-27  Werner Koch  <wk@gnupg.org>
13682
13683         gpg: Convey --quick option to dirmngr for --auto-key-retrieve.
13684         + commit a15ed5a1fd5307b3ec1822daf3b138b187db0b5e
13685         * g10/call-dirmngr.c (gpg_dirmngr_ks_get): Add arg 'quick'.
13686         (gpg_dirmngr_wkd_get): Ditto.
13687         * g10/keyserver.c (keyserver_get): Add arg 'quick'.
13688         (keyserver_get_chunk): Add arg 'quick'.
13689         (keyserver_import_fprint): Ditto.  Change callers to pass 0 for it.
13690         (keyserver_import_keyid): Ditto.
13691         (keyserver_import_wkd): Ditto.
13692         * g10/mainproc.c (check_sig_and_print): Call the 3 fucntions with
13693         QUICK set.
13694
13695 2016-10-27  NIIBE Yutaka  <gniibe@fsij.org>
13696
13697         common: Fix gnupg_inotify_has_name, differently.
13698         + commit 8b3d0d1a36cab83dafb98ccb7895144edb95e298
13699         * common/sysutils.c (gnupg_inotify_has_name): Use void * to stop the
13700         warning.
13701
13702         dirmngr: More ADNS error fix.
13703         + commit 6f1d8123d61b3efac94b4c61ee75bd947790ba42
13704         * dirmngr/dns-stuff.c (get_dns_cert, getsrv, get_dns_cname): Fix return
13705         value.
13706
13707         dirmngr: Fix error return for ADNS.
13708         + commit 8a9341b42cd1891090d45cc068bff84b2b3edb50
13709         * dirmngr/dns-stuff.c (resolve_name_adns): Use RET for return value.
13710
13711         g10: Fix ECDH, clarifying the format.
13712         + commit ca0ee4e381d0b6a57e4ddc8f4bb2390eb97a2540
13713         * g10/ecdh.c (pk_ecdh_encrypt_with_shared_point): Returns error when
13714         it's short.  Clarify the format.  Handle other prefixes correctly.
13715
13716         scd: Add 0x41 prefix for x-coordinate only result.
13717         + commit 6bbd97d6c771b2e2c7cfcff6d5a823f0fb44d443
13718         * scd/app-openpgp.c (do_decipher): When it's x-coordinate only, add the
13719         prefix 0x41.
13720
13721 2016-10-27  Arnaud Fontaine  <arnaud.fontaine@ssi.gouv.fr>
13722
13723         g10: ECDH shared point format.
13724         + commit b648f28f9f8b889f1217a649ded1d45f261bb2bf
13725         * g10/ecdh.c (pk_ecdh_encrypt_with_shared_point): Improve handling of
13726         ECDH shared point format.
13727
13728 2016-10-27  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
13729
13730         dirmngr: Implement --supervised command (for systemd, etc).
13731         + commit 75f8aaf5bc2dc7fcffe2987a572d489155c91eb9
13732         * dirmngr/dirmngr.c (main): Add new --supervised command, which is a
13733         mode designed for running under a process supervision system like
13734         systemd or runit.
13735         * doc/dirmngr.texi: document --supervised option.
13736
13737         agent,common: move get_socket_name() into common.
13738         + commit 6316b28e896957adb76a61a41d2e1c2a08d9f716
13739         * agent/gpg-agent.c (get_socket_name): move to ...
13740         * common/sysutils.c (gnupg_get_socket_name): ... here.
13741
13742         dirmngr: report actual socket name.
13743         + commit 6bb6ac56cca8135666387a0b9d88dd6b50311418
13744         * dirmngr/dirmngr.[ch] (dirmngr_get_current_socket_name): new function
13745         to report known socket name.
13746         * dirmngr/server.c (cmd_getinfo): use dirmngr_get_current_socket_name
13747         to report correct socket name.
13748
13749 2016-10-27  NIIBE Yutaka  <gniibe@fsij.org>
13750
13751         common: Fix gnupg_inotify_has_name.
13752         + commit bc28f320fa6f5b9fcdb73dba5e6c582daf7992c5
13753         * common/sysutils.c (gnupg_inotify_has_name): Take care of the
13754         alignment.
13755
13756         dirmngr: Fix help string and argument.
13757         + commit 96414baf36b8e6385b71847c789d489ebe176a93
13758         * dirmngr/server.c (hlp_versioncheck): Add a newline.
13759         (cmd_versioncheck): Fix argument.
13760
13761 2016-10-26  Werner Koch  <wk@gnupg.org>
13762
13763         dirmngr: Fix hang due to deferred thread initialization.
13764         + commit d1ccab5176d7719328b287544b54b85e0277b146
13765         * dirmngr/dirmngr.c (main): Call ldap_wrapper_launch_thread after
13766         thread_init.
13767
13768         agent: Avoid double error message.
13769         + commit b77f95a4a675fd20f6eeb611f4e7b519eceb4ad3
13770         * agent/gpg-agent.c (map_supervised_sockets): Shorten error message.
13771         Remove unneeded diagnostic.
13772
13773         common: Use GPG_ERR_INV_VALUE instead of GPG_ERR_EINVAL.
13774         + commit ece13f177d948013b6f3df926406c0cd947abc25
13775         * common/sysutils.c (gnupg_inotify_watch_socket): Return
13776         GPG_ERR_INV_VALUE for a missing socket name and set proper error
13777         source.
13778
13779         tests: Improve portability of fake-pinentry.
13780         + commit 21b318452abbfe21c45c2a67dae0e3a81cff1090
13781         * tests/openpgp/fake-pinentry.c: Make all functions static.
13782         (get_passphrase): s/unlink/remove/ because that is standard C.
13783         (spacep): Rename to whitespace and change all callers.
13784         (main): Move macro out of if-then chain.
13785
13786 2016-10-26  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
13787
13788         agent: --supervised mode improvements.
13789         + commit 27f6d5b9f4b6057ddeb9ace87a1e7e61ebac63e6
13790         * agent/gpg-agent.c (map_supervised_socket): if the agent is running
13791           in --supervised mode and is not actually given LISTEN_FDNAMES
13792           directives, require at least fd 3 to be open for listening.
13793
13794         common: avoid segfault.
13795         + commit 3b5f5e0eb02ecbdcf59722755f22a9d2f88de6e6
13796         * common/sysutils.c (gnupg_inotify_watch_socket): return EINVAL if
13797           socket_name is NULL, rather than segfaulting
13798
13799 2016-10-25  Justus Winter  <justus@g10code.com>
13800
13801         agent,tests,w32: Fix relaying pinentry user data, fix fake-pinentry.
13802         + commit 852b8f0b89d447536dfdf6cd4ea91615c75491ce
13803         * agent/call-pinentry.c (start_pinentry): Also send the user data
13804         using an Assuan 'OPTION' command.
13805         * tests/openpgp/fake-pinentry.c (get_passphrase): Fix updating
13806         passphrase file.
13807         (spacep): Include newline characters.
13808         (rstrip): New function.
13809         (main): Handle Windows line endings.  Handle the userdata option, and
13810         restart with the new options.
13811
13812         tests: Do not autostart gpg-agents on teardown.
13813         + commit f88f11a25665dca7490a09088aa24edf396e4c40
13814         * tests/openpgp/defs.c (stop-agent): Use '--no-autostart' when calling
13815         gpg-connect-agent.
13816
13817 2016-10-25  Werner Koch  <wk@gnupg.org>
13818
13819         dirmngr: Allow command VERSIONCHECK to handle 3 part version numbers.
13820         + commit b120f358c25cc846ca9d841d47e71ca1a7fe02e4
13821         * dirmngr/server.c (parse_version_string): Add arg MICRO and set it.
13822         (cmp_version): Extend to handle the MICRO part.
13823         (confucius_mktmpdir): Rename to my_mktmpdir.
13824         (my_mktmpdir): xstrconcat does not fail; use strconcat.
13825         (fetch_into_tmpdir): Improve error checking.
13826
13827         common: Use strconcat in gnupg_setenv.
13828         + commit 7983f8758703071710c11bf2a255efcd71836b65
13829         * common/sysutils.c (gnupg_setenv): Replace malloc+stpcpy by
13830         strconcat.  Indent cpp conditionals.
13831         (gnupg_unsetenv): Indent cpp conditionals.
13832
13833 2016-10-24  Werner Koch  <wk@gnupg.org>
13834
13835         gpg: Replace two sprintf calls.
13836         + commit 9d6146d6f9870fbfcec15cdc4becaf094d5a90e0
13837         * g10/keygen.c (print_status_key_created): Use snprintf for now.
13838         (ask_expire_interval): Replace xmalloc and sprintf by xasprintf.
13839
13840         agent: Minor cleanup for recent change in findkey.c.
13841         + commit 8c40b3b98d3ddeda79fde981e6539c5b3b09d9a2
13842         * agent/findkey.c (agent_write_private_key): Avoid label name error.
13843
13844         agent: Slightly change structure of cmd_readkey.
13845         + commit fdb653a33ea1a24d1159880624dbbcc0867865b5
13846         * agent/command.c (cmd_readkey): Avoid a leave label in the middle of
13847         the code.  Remove the special return.
13848
13849 2016-10-24  Kai Michaelis  <kai@gnupg.org>
13850
13851         dirmngr: Fix segfault in VERSIONCHECK.
13852         + commit 5e7dfd979d2d91800d90c3ce9a66755df3217682
13853         * dirmngr/server.c (cmd_versioncheck): The VERSIONCHECK command crashes
13854         when called without program version.
13855
13856 2016-10-24  NIIBE Yutaka  <gniibe@fsij.org>
13857
13858         scd: Use canonical curve name of libgcrypt.
13859         + commit b1828c17fc475def1ee9e06f083f513f568c241b
13860         * scd/app-openpgp.c (send_key_attr): Use curve instead of OID.
13861         (ecdh_params): New.
13862         (ecc_read_pubkey): Use ecdh_params.  Use curve name.
13863         (ecc_writekey): Likewise.
13864         (ecc_curve): Rename from ecc_oid.
13865         (parse_algorithm_attribute): Use ecc_curve.
13866         * g10/call-agent.c (learn_status_cb): Use openpgp_is_curve_supported to
13867         intern the curve name string.
13868         * g10/card-util.c (card_status): Conver curve name to alias for print.
13869
13870         common: Fix openpgp_is_curve_supported.
13871         + commit 945e7ab0ddedf5f58afd97d81e101939de5b5d89
13872         * common/openpgp-oid.c (openpgp_is_curve_supported): Support both of
13873         canonical name of the curve and alias.
13874
13875         g10: Fix card keygen for decryption.
13876         + commit acef0951646b47c87ccc1c616f0105a068e7ed86
13877         * g10/keygen.c (do_generate_keypair): Fix arguments.
13878
13879 2016-10-22  NIIBE Yutaka  <gniibe@fsij.org>
13880
13881         g10: More card key generation change.
13882         + commit 987bbb2276aeb6bee2793e8406e223717b605009
13883         * g10/keygen.c (gen_card_key): Add back ALGO as the second argument.
13884         Don't get ALGO by KEY-ATTR by this function.  It's caller to provide
13885         ALGO.  Don't do that by both of caller and callee.
13886         (generate_keypair): Only put paramerters needed.  Use parameters
13887         for ALGO to call gen_card_key.
13888         (generate_card_subkeypair): Get ALGO and call gen_card_key with it.
13889
13890 2016-10-21  Andre Heinecke  <aheinecke@intevation.de>
13891
13892         g10: Write first keybox record in binary mode.
13893         + commit f7e50634be71ce3028726f23edf14454109a04a8
13894         * g10/keydb.c (maybe_create_keyring_or_box): Open in binary mode.
13895
13896 2016-10-21  NIIBE Yutaka  <gniibe@fsij.org>
13897
13898         g10,scd: Fix ECC keygen.
13899         + commit d2653b1a6db90aed073194a51fd61023d69773ec
13900         * g10/keygen.c (generate_keypair): For card key generation, fill
13901         parameters by KEY-ATTR.
13902
13903         * scd/app-openpgp.c (ecc_read_pubkey): OID should be freed at last,
13904         after its reference by OIDBUF is finished.
13905         (ecc_writekey): Likewise.
13906
13907         scd: Fix segfault changing key attr.
13908         + commit 693e657ff04756737dce025203c0deba480ea8de
13909         * asc/app-openpgp.c (change_keyattr_from_string): Release after
13910         allocated.
13911
13912 2016-10-21  NIIBE Yutaka  <gniibe@fsij.org>
13913             Arnaud Fontaine  <arnaud.fontaine@ssi.gouv.fr>
13914
13915         g10: Don't ask keysize for for non-RSA card.
13916         + commit dafce6f698bec6e9d4c0125b90754d0687294e86
13917         * g10/card-util.c (card_status): Bug fix for keyno.
13918         (ask_card_rsa_keysize, do_change_rsa_keysize): Rename.
13919         (generate_card_keys): Only ask keysize when RSA.
13920         (card_generate_subkey): Likewise.
13921
13922         g10: Support ECC for gen_card_key.
13923         + commit 161cb22f13bcd8cbdb08558d9926b2168a8297ac
13924         * g10/keygen.c (gen_card_key): Remove the first argument of ALGO.
13925         (do_generate_keypair, generate_card_subkeypair): Follow the change.
13926
13927 2016-10-21  NIIBE Yutaka  <gniibe@fsij.org>
13928
13929         Fix use cases of snprintf.
13930         + commit 6e85ac77af594035137950d801d8a1bacce548a3
13931         * agent/call-pinentry.c, agent/call-scd.c, agent/command.c,
13932         build-aux/speedo/w32/g4wihelp.c, common/get-passphrase.c,
13933         dirmngr/dirmngr.c, g10/call-agent.c, g10/cpr.c, g10/keygen.c,
13934         g10/openfile.c, g10/passphrase.c, scd/app-openpgp.c, scd/scdaemon.c,
13935         sm/call-agent.c, sm/call-dirmngr.c, sm/certreqgen.c: Fix assuming C99.
13936
13937         agent: Fix saving with FORCE=1.
13938         + commit 1ffd475f99eaff4e40950eda88702f8db9288eb5
13939         * agent/findkey.c (agent_write_private_key): Recover from an error of
13940         GPG_ERR_ENOENT when FORCE=1 and it is opened with "rb+".
13941
13942 2016-10-20  Justus Winter  <justus@g10code.com>
13943
13944         tests: Simplify test.
13945         + commit 71158d8d5f823888abc8588caa6497860ce59c06
13946         * tests/openpgp/quick-key-manipulation.scm: Avoid creating a temporary
13947         home directory, just make the uids unique.
13948
13949         tests: Flush stdout in the fake pinentry.
13950         + commit ca9597f080f70a8435daaeb5449bef0462a1402a
13951         * tests/openpgp/fake-pinentry.c (reply): Flush stdout.
13952
13953         common,w32: Fix setting environment variables on Windows.
13954         + commit 8c7c4faf3de28ca70a60e6b15f51c1b206e0ddd9
13955         * common/sysutils.c (gnupg_setenv): Also update the environment block
13956         maintained by the C runtime.
13957         (gnupg_unsetenv): Likewise.
13958         * tests/gpgscm/ffi.c (do_setenv): Fix error handling.
13959
13960         tests,w32: Cope with Windows line endings.
13961         + commit bf37916a23bd0929fc4a5f28c9a41f43c5a473f6
13962         * tests/openpgp/issue2015.scm: Rstrip line before comparison.
13963
13964         tests: Create and remove socket directories.
13965         + commit 2d794779e0fd9d9a1efc98e7bd77a296a25f4293
13966         * tests/openpgp/defs.scm (start-agent): Move function here and create
13967         the socket directory prior to starting the agent.
13968         (stop-agent): Move function here and remove the socket directory.
13969         * tests/openpgp/finish.scm: Adapt.
13970         * tests/openpgp/setup.scm: Likewise.
13971
13972 2016-10-20  NIIBE Yutaka  <gniibe@fsij.org>
13973
13974         agent, g10: Fix keygen.
13975         + commit 9a34e2142b426b98c73fd888102ea1596bbce62a
13976         * agent/command.c (cmd_readkey): Get length after card_readkey.
13977         * g10/keygen.c (gen_card_key): Fix off-by-one error.
13978
13979         scd: GENKEY updates the public key in APP.
13980         + commit b680f79cc112c4831293e259d7db2921bcd783a4
13981         * scd/app-openpgp.c (rsa_read_pubkey, ecc_read_pubkey): New.
13982         (read_public_key): New.
13983         (get_public_key, do_genkey): Use read_public_key.
13984
13985         g10: smartcard keygen change.
13986         + commit 980c037bedb968ddf155dd334c0a70b918a17759
13987         * g10/call-agent.c (scd_genkey_cb_append_savedbytes): Remove.
13988         (scd_genkey_cb): Only handle KEY-CREATED-AT and PROGRESS.
13989         (agent_scd_genkey): Remove INFO argument.  CREATETIME is now in/out
13990         argument.
13991         (agent_readkey): Use READKEY --card instead of SCD READKEY.
13992         * g10/keygen.c (gen_card_key): Use READKEY --card command of the agent
13993         to retrieve public key information from card and let the agent make
13994         a file for private key with shadow info.
13995
13996         agent: Add --card option for READKEY.
13997         + commit 82cbab906a3e72a98fdc16096f2f0451465969a2
13998         * agent/findkey.c (agent_write_shadow_key): New.
13999         * agent/command-ssh.c (card_key_available): Use agent_write_shadow_key.
14000         * agent/learncard.c (agent_handle_learn): Likewise.
14001         * agent/command.c (cmd_readkey): Add --card option.
14002
14003 2016-10-19  Kai Michaelis  <kai@gnupg.org>
14004
14005         dirmngr: improve VERSIONCHECK.
14006         + commit 72a99f582dad4cb4c3b05b97c7ebb8d537f10b79
14007         Replace strtok_r() and code formatting. Use code from libgpg-error for
14008         version comparison.
14009
14010 2016-10-18  Justus Winter  <justus@g10code.com>
14011
14012         common: Fix copying data to estreams.
14013         + commit 8dce5ee55a0268d196023224dcf3020306922490
14014         * common/exectool.c (copy_buffer_do_copy): Correctly account for
14015         partially written data in the event of errors.
14016
14017         common,w32: Communicate with child in non-blocking mode.
14018         + commit 05a1e412332dd980353a4e3e59bc75ba40bae7fc
14019         * common/exechelp-w32.c (gnupg_spawn_process): Open streams in
14020         non-blocking mode if requested.
14021
14022         common,w32: Extend gnupg_create_inbound_pipe et al.
14023         + commit f2d39a6d051413289c717b9cd2dc387a270b8e7c
14024         * common/exechelp-w32.c (do_create_pipe): Rename, add arguments, and
14025         create a stream if reqested.
14026         (gnupg_create_inbound_pipe): Use the extended function to open the
14027         stream if requested.
14028         (gnupg_create_outbound_pipe): Likewise.
14029         (gnupg_create_pipe): Update call site.
14030
14031         common,w32: Make use of default_errsource in exechelp.
14032         + commit 727ca74bb942464217e678012cccbfc347ae08a5
14033         * common/exechelp-posix.c (my_error_from_syserror, my_error): New.
14034         Use them instead of gpg_error and gpg_error_from_syserror.
14035
14036 2016-10-18  NIIBE Yutaka  <gniibe@fsij.org>
14037             Arnaud Fontaine  <arnaud.fontaine@ssi.gouv.fr>
14038
14039         scd: Support ECC key generation.
14040         + commit 34439da2d62b964a914ace66bae7e38f619582a4
14041         * scd/app-openpgp.c (get_public_key): Fix a message.
14042         (change_keyattr_from_string, ecc_writekey): Call mpi_release sooner.
14043         (do_genkey): Add ECC support.
14044
14045 2016-10-18  NIIBE Yutaka  <gniibe@fsij.org>
14046
14047         scd: minor cleanup to merge other works.
14048         + commit f1845f25dbea79c191427710fa56ed01e63a045b
14049         * scd/iso7816.c (do_generate_keypair): Use const char * for DATA.
14050         (iso7816_generate_keypair, iso7816_read_public_key): Likewise.
14051         * scd/app-openpgp.c (get_public_key): Follow the change.
14052         (do_genkey): Ditto.  Use ERR instead of RC.  Use u32 for CREATED_AT.
14053
14054 2016-10-17  Justus Winter  <justus@g10code.com>
14055
14056         gpgscm: Initialize nesting stack.
14057         + commit c2e713d9e25ef8b61e8eeb3c01ee1e31cb70b794
14058         * tests/gpgscm/scheme.c (scheme_init_custom_alloc): Initialize nesting
14059         stack.
14060
14061 2016-10-17  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
14062
14063         doc: Document how to manually shut down gpg-agent.
14064         + commit 869c06efa791bbc8330becdb3f13f7cf9506257e
14065         * doc/gpg-agent.texi: document "gpgconf --kill gpg-agent" for manual
14066           agent termination.
14067
14068         This was requested in a side-comment in https://bugs.debian.org/840669
14069
14070         doc: Point gpg-agent(1) at the right gpg manpage in SEE ALSO.
14071         + commit c53ce53ab1fa6a328c368f2a15e3ccd803f03ee2
14072         * doc/gpg-agent.texi (SEE ALSO): refer to @gpgname, instead of
14073           hard-coding "gpg2".
14074
14075 2016-10-17  NIIBE Yutaka  <gniibe@fsij.org>
14076
14077         scd: Fix keytocard for ECC.
14078         + commit 25428be52168fa9c581b7f11c95a5c63b25343b7
14079         * scd/app-openpgp.c (build_ecc_privkey_template): Size can be greater
14080         than 128 when it comes with public key for curve of larger field.
14081
14082         gpgconf: Fix for --homedir.
14083         + commit 70a8584ec4389209762eb65bb77f20f7881577be
14084         * tools/gpgconf-comp.c (gpg_agent_runtime_change,
14085         scdaemon_runtime_change, dirmngr_runtime_change): Provide the homedir
14086         arguments by --homedir when it's not default.
14087
14088 2016-10-16  Werner Koch  <wk@gnupg.org>
14089
14090         agent: Use straightforward names for the default socket names.
14091         + commit 0b0f9a3788cb5d3c26cec16cd24acc973069d280
14092         * configure.ac (GPG_AGENT_SOCK_NAME): Change name to *.extra.
14093         (GPG_AGENT_EXTRA_SOCK_NAME): Change name to *browser.
14094
14095 2016-10-15  Werner Koch  <wk@gnupg.org>
14096
14097         agent: Move inotify code to common and improve it.
14098         + commit 2f7d4c38c9e7bcc14e6e0bf219d688c40a4afecb
14099         * common/sysutils.c: Include sys/inotify.h.
14100         (my_error_from_syserror, my_error): New.
14101         (gnupg_inotify_watch_socket): New.
14102         (gnupg_inotify_has_name): New.
14103         * agent/gpg-agent.c: Do not include sys/inotify.h.
14104         (my_inotify_is_name): Remove.
14105         (handle_connections): Remove HAVE_INOTIFY_INIT protected code and use
14106         the new functions.
14107
14108 2016-10-14  Kai Michaelis  <kai@gnupg.org>
14109
14110         dirmngr: use gnupg_mkdtemp instead of mkstemp.
14111         + commit c318561ef4c97f0c2767aef377531d58174060a1
14112         MinGW on debian does not support mkstemp.
14113
14114         dirmngr: add VERSIONCHECK command.
14115         + commit f99c5fa1c970dc1122ac62371eb8d758f380ed57
14116         Given an application name and version VERSIONCHECK fetches the software
14117         version list from version.gnupg.org, verifies the signature and returns
14118         whenever the given version is older (UPDATE), current (CURRENT) or newer
14119         (ROLLBACK).
14120
14121 2016-10-13  Neal H. Walfield  <neal@g10code.com>
14122
14123         tests: Use shorter filenames.
14124         + commit 0c56ad5a8d89d69a9ed00571720b3b105f955214
14125         * tests/openpgp/tofu/cross-sigs/
14126           1938C3A0E4674B6C217AC0B987DB2814EC38277E-1.gpg: Rename from this...
14127         * tests/openpgp/tofu/cross-sigs/EC38277E-1.gpg: .. to this.
14128         * tests/openpgp/tofu/cross-sigs/
14129           1938C3A0E4674B6C217AC0B987DB2814EC38277E-1.txt: Rename from this...
14130         * tests/openpgp/tofu/cross-sigs/EC38277E-1.txt: .. to this.
14131         * tests/openpgp/tofu/cross-sigs/
14132           1938C3A0E4674B6C217AC0B987DB2814EC38277E-2.gpg: Rename from this...
14133         * tests/openpgp/tofu/cross-sigs/EC38277E-2.gpg: .. to this.
14134         * tests/openpgp/tofu/cross-sigs/
14135           1938C3A0E4674B6C217AC0B987DB2814EC38277E-2.txt: Rename from this...
14136         * tests/openpgp/tofu/cross-sigs/EC38277E-2.txt: .. to this.
14137         * tests/openpgp/tofu/cross-sigs/
14138           1938C3A0E4674B6C217AC0B987DB2814EC38277E-3.txt: Rename from this...
14139         * tests/openpgp/tofu/cross-sigs/EC38277E-3.txt: .. to this.
14140         * tests/openpgp/tofu/cross-sigs/
14141           1938C3A0E4674B6C217AC0B987DB2814EC38277E-secret.gpg: Rename from
14142           this...
14143         * tests/openpgp/tofu/cross-sigs/EC38277E-secret.gpg: .. to this.
14144         * tests/openpgp/tofu/cross-sigs/
14145           DC463A16E42F03240D76E8BA8B48C6BD871C2247-1.gpg: Rename from this...
14146         * tests/openpgp/tofu/cross-sigs/871C2247-1.gpg: .. to this.
14147         * tests/openpgp/tofu/cross-sigs/
14148           DC463A16E42F03240D76E8BA8B48C6BD871C2247-1.txt: Rename from this...
14149         * tests/openpgp/tofu/cross-sigs/871C2247-1.txt: .. to this.
14150         * tests/openpgp/tofu/cross-sigs/
14151           DC463A16E42F03240D76E8BA8B48C6BD871C2247-2.gpg: Rename from this...
14152         * tests/openpgp/tofu/cross-sigs/871C2247-2.gpg: .. to this.
14153         * tests/openpgp/tofu/cross-sigs/
14154           DC463A16E42F03240D76E8BA8B48C6BD871C2247-2.txt: Rename from this...
14155         * tests/openpgp/tofu/cross-sigs/871C2247-2.txt: .. to this.
14156         * tests/openpgp/tofu/cross-sigs/
14157           DC463A16E42F03240D76E8BA8B48C6BD871C2247-3.gpg: Rename from this...
14158         * tests/openpgp/tofu/cross-sigs/871C2247-3.gpg: .. to this.
14159         * tests/openpgp/tofu/cross-sigs/
14160           DC463A16E42F03240D76E8BA8B48C6BD871C2247-3.txt: Rename from this...
14161         * tests/openpgp/tofu/cross-sigs/871C2247-3.txt: .. to this.
14162         * tests/openpgp/tofu/cross-sigs/
14163           DC463A16E42F03240D76E8BA8B48C6BD871C2247-4.gpg: Rename from this...
14164         * tests/openpgp/tofu/cross-sigs/871C2247-4.gpg: .. to this.
14165         * tests/openpgp/tofu/cross-sigs/
14166           DC463A16E42F03240D76E8BA8B48C6BD871C2247-secret.gpg: Rename from
14167           this...
14168         * tests/openpgp/tofu/cross-sigs/871C2247-secret.gpg: .. to this.
14169         * tests/openpgp/Makefile.am (TEST_FILES): Update accordingly.
14170
14171         g10: Be more careful when checking if a binding is signed by a UTK.
14172         + commit 95d0f3e5eebd85dcf226dca14891a1215bfe93ae
14173         * g10/tofu.c (signed_by_utk): When checking if a key is signed by an
14174         ultimately trusted key, only consider the signatures on the specified
14175         user id.
14176         * tests/openpgp/tofu.scm: Add test for the above.
14177
14178         tests: Add test data to TEST_FILES.
14179         + commit d2d936fbe86d61b89cead95df633b2b575690e05
14180         * tests/openpgp/Makefile.am (TEST_FILES): Add new test data.
14181
14182         g10: Be more careful when checking cross signatures.
14183         + commit 4c0389f8eb19ae7dfd9c5d784a629b386d93cc5c
14184         * g10/tofu.c (cross_sigs): When checking cross signatures, only
14185         consider the signatures on the specified user id.
14186         * tests/openpgp/tofu.scm: Add test for the above.
14187         * tests/openpgp/tofu/cross-sigs/
14188           1938C3A0E4674B6C217AC0B987DB2814EC38277E-1.gpg:
14189           New file.
14190         * tests/openpgp/tofu/cross-sigs/
14191           1938C3A0E4674B6C217AC0B987DB2814EC38277E-1.txt: New file.
14192         * tests/openpgp/tofu/cross-sigs/
14193           1938C3A0E4674B6C217AC0B987DB2814EC38277E-2.gpg: New file.
14194         * tests/openpgp/tofu/cross-sigs/
14195           1938C3A0E4674B6C217AC0B987DB2814EC38277E-2.txt: New file.
14196         * tests/openpgp/tofu/cross-sigs/
14197           1938C3A0E4674B6C217AC0B987DB2814EC38277E-3.txt: New file.
14198         * tests/openpgp/tofu/cross-sigs/
14199           1938C3A0E4674B6C217AC0B987DB2814EC38277E-secret.gpg: New file.
14200         * tests/openpgp/tofu/cross-sigs/
14201           DC463A16E42F03240D76E8BA8B48C6BD871C2247-1.gpg: New file.
14202         * tests/openpgp/tofu/cross-sigs/
14203           DC463A16E42F03240D76E8BA8B48C6BD871C2247-1.txt: New file.
14204         * tests/openpgp/tofu/cross-sigs/
14205           DC463A16E42F03240D76E8BA8B48C6BD871C2247-2.gpg: New file.
14206         * tests/openpgp/tofu/cross-sigs/
14207           DC463A16E42F03240D76E8BA8B48C6BD871C2247-2.txt: New file.
14208         * tests/openpgp/tofu/cross-sigs/
14209           DC463A16E42F03240D76E8BA8B48C6BD871C2247-3.gpg: New file.
14210         * tests/openpgp/tofu/cross-sigs/
14211           DC463A16E42F03240D76E8BA8B48C6BD871C2247-3.txt: New file.
14212         * tests/openpgp/tofu/cross-sigs/
14213           DC463A16E42F03240D76E8BA8B48C6BD871C2247-4.gpg: New file.
14214         * tests/openpgp/tofu/cross-sigs/
14215           DC463A16E42F03240D76E8BA8B48C6BD871C2247-secret.gpg: New file.
14216         * tests/openpgp/tofu/cross-sigs/README: New file.
14217
14218         g10: Still check if the key is an UTK or cross signed in batch mode.
14219         + commit e09166c77273f459c8f87cab9224f85808af2cba
14220         * g10/tofu.c (get_trust): If POLICY is ask, but we can't ask, don't
14221         bail immediately.  Instead, check if the key in question is an
14222         ultimately trusted key or cross signed.
14223
14224         g10: If an sqlite operation fails, map the error code to GPG_ERR_GENERAL
14225         + commit 5bf92e51dfdfb4f4746ecd817d8d2240ed27ea74
14226         * g10/tofu.c (get_policy): If an sqlite operation fails, map the error
14227           code to GPG_ERR_GENERAL.
14228         (ask_about_binding): Likewise.
14229         (build_conflict_set): Likewise.
14230         (get_trust): Likewise.
14231         (show_statistics): Likewise.
14232         (tofu_register_signature): Likewise.
14233         (tofu_register_encryption): Likewise.
14234
14235         tests: Remove support for deprecated functionality.
14236         + commit 2282c3b761413dfa894300e70084bbd58908c0b1
14237         * tests/openpgp/tofu.scm: Don't remove tofu.d.  It's deprecated.
14238
14239 2016-10-12  Neal H. Walfield  <neal@g10code.com>
14240
14241         g10: When changing a TOFU binding's policy, update the conflict info.
14242         + commit 3ad17e72fa81d18c95732ddcd4def244f52bb5b1
14243         * g10/tofu.c (record_binding): Take an additional argument, CONFLICT.
14244         Set the binding's conflict accordingly.  Update callers.
14245
14246         g10: Make a singular string singular.
14247         + commit ca84f65c7cf2c6a08a01018519965a82e6c52cac
14248         * g10/tofu.c (ask_about_binding): Make the singular string singular.
14249
14250         g10: Correctly determine whether a binding has a conflict.
14251         + commit 6fdf37f0831949cb279de6dc6b247ab2ed53fe5a
14252         * g10/tofu.c (build_conflict_set): A binding has a conflict is
14253         conflict is *not* NULL, not if it is NULL.
14254
14255         g10: Fix a column's type in TOFU DB.
14256         + commit 78eda335fd1c29038b74b9cc912b6a4515fccd9f
14257         * g10/tofu.c (initdb): Change policy from a boolean to an integer.
14258
14259 2016-10-07  Justus Winter  <justus@g10code.com>
14260
14261         tests: Rework test environment setup.
14262         + commit cbbf0a7a8da1757fea29cff0daaa42a6bbb95b26
14263         * tests/openpgp/setup.scm: Import one keyring at a time.  This works
14264         around a yet to be investigated hang on Windows.  It is also much
14265         prettier.
14266
14267         tests: Improve handling of Windows newlines.
14268         + commit 1f76f8d8bc65fad98927c977baf4d5e36dafe52b
14269         * tests/gpgscm/lib.scm (string-split-newlines): New function.
14270         * tests/openpgp/default-key.scm: Use new function.
14271         * tests/openpgp/defs.scm: Likewise.
14272         * tests/openpgp/export.scm: Likewise.
14273         * tests/openpgp/import.scm: Likewise.
14274
14275         gpgscm: Improve test of low-level functions.
14276         + commit 11eac7eb2fa3392a9aa052f8f5bb9875129ab84b
14277         * tests/gpgscm/t-child.c: Print large amounts of data.
14278         * tests/gpgscm/t-child.scm: Test that this works.
14279
14280         gpgscm: Improve path handling.
14281         + commit dff266059813d22d1e2ba7e77279999cd41ceb75
14282         * tests/gpgscm/ffi.c (ffi_init): New Scheme variable '*win32*'.
14283         * tests/gpgscm/tests.scm (canonical-path): Correctly handle paths with
14284         drive letter on Windows.  Use 'path-join'.
14285         (path-expand): Use 'path-join'.
14286
14287         tools: Fix error handling.
14288         + commit 5afbfdfd59540cb882d891ff1f4afa73fe48f99a
14289         * tools/gpgtar-create.c (gpgtar_create): Do not crash if opening the
14290         tarball failed.
14291
14292 2016-10-07  NIIBE Yutaka  <gniibe@fsij.org>
14293
14294         agent: Fix get_socket_name.
14295         + commit fb3b3e1e7a4219f61a834fd07809898918611c2f
14296         * agent/gpg-agent.c (get_socket_name): Fix the size of copying.
14297
14298 2016-10-07  Werner Koch  <wk@gnupg.org>
14299
14300         gpg: Put extra parens around bit tests.
14301         + commit 5d43d28aa3c44c3a27fde823f467b0c4be1a58c2
14302         * g10/options.h (DBG_MPI): New.
14303         * g10/gpg.c (set_debug): Use macro or extra parens for binary operator.
14304         * g10/parse-packet.c (set_packet_list_mode): Use dbg macro.
14305
14306 2016-10-07  NIIBE Yutaka  <gniibe@fsij.org>
14307
14308         agent, dirmngr, scd: Fix init_common_subsystems.
14309         + commit fc0b392e766af8127094e8b529d25abb84ad1d65
14310         * common/init.c (_init_common_subsystems): Don't call
14311         gpgrt_set_syscall_clamp in this function.
14312         * agent/gpg-agent.c, dirmngr/dirmngr.c, scd/scdaemon.c: Call
14313         gpgrt_set_syscall_clamp after npth_init.
14314
14315 2016-10-06  Justus Winter  <justus@g10code.com>
14316
14317         common: Avoid pointer arithmetic on string literals.
14318         + commit 4aadc751f201f8f97c9c1f454e3a29803cce3edb
14319         * common/gettime.c (rfctimestamp): Use indexing instead.
14320         * common/signal.c (got_fatal_signal): Likewise.
14321
14322         g10: Fix singular term.
14323         + commit b0d2526bc4e5c663eeffe04500420c70cee98712
14324         * g10/tofu.c (ask_about_binding): Fix singular message.
14325
14326         g10: Use appropriate variant of 'abs'.
14327         + commit 73000d1ce0317210f5a9e5262404cc90258041ff
14328         * g10/tofu.c (ask_about_binding): Use 'labs' instead of 'abs'.
14329
14330         sm: Remove statement without effect.
14331         + commit 2d446759bd43ae38fbce9a18c955285ca535bc08
14332         * sm/call-dirmngr.c (gpgsm_dirmngr_isvalid): Remove statement without
14333         effect.
14334
14335         g10: Fix testing for debug flag.
14336         + commit 6b626824c8e30b41c47724b5ccbf761937499512
14337         * g10/parse-packet.c (set_packet_list_mode): Fix testing for debug
14338         flag.
14339
14340         tools: Improve error handling.
14341         + commit 32f81f56a8be6d13dea0a64d24f52343c7e72c84
14342         * tools/gpg-wks-server.c (copy_key_as_binary): Initialize 'argv'.
14343
14344         gpgscm: Update callsite of 'gnupg_spawn_process'.
14345         + commit 07cfb3b27a77491eae818d57f6eb660e75fa013f
14346         * tests/gpgscm/ffi.c (do_spawn_process): Adapt to the changes to
14347         'gnupg_spawn_process'.
14348
14349 2016-10-05  Werner Koch  <wk@gnupg.org>
14350
14351         wks: Send key encrypted as required by draft -02.
14352         + commit 8ce800d21919eaaba7ed4f04f712292be310fd66
14353         * tools/gpg-wks-client.c (get_key): Encrypt.
14354         (encrypt_response): Take care of --fake-submission-addr.
14355
14356         wks: Add option --fake-submission-addr to gpg-wks-client.
14357         + commit e514a5b725f0c997cef4362808b2778a3faa9cf8
14358         * tools/gpg-wks-client.c (oFakeSubmissionAddr): New.
14359         (opts): Add option --fake-submission-addr.
14360         (fake_submission_addr): New variable.
14361         (parse_arguments): Set it.
14362         (command_send): Use --fake-submission-addr.
14363
14364         agent: Another minor fix to map_supervised_sockets.
14365         + commit 1cedc32c95c2e3c3ab98af23ddc2845d51e596c1
14366         * agent/gpg-agent.c (map_supervised_sockets): Remove debug message.
14367         Provide correct fd in the second error case.
14368
14369         agent: Fix npth + supervised mode problem.
14370         + commit f57dc2b1e6f28d164f882373535dbcb0d632ca17
14371         * agent/gpg-agent.c (main): Initialize modules in supervised mode.
14372
14373 2016-10-05  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
14374
14375         agent: Fix error handling in map_supervised_sockets.
14376         + commit a2127c71dbf87c1710b43d91a733dd4c9b2953bc
14377         * agent/gpg-agent.c (map_supervised_sockets): the file descriptor to
14378           close on error is fd, not i.
14379
14380 2016-10-04  Werner Koch  <wk@gnupg.org>
14381
14382         agent: Streamline the supervised mode code.
14383         + commit 1a9c8d78ece2f31fdb1a8e2be049aa71053061fa
14384         * agent/gpg-agent.c (get_socket_path): Rename to ...
14385         (get_socket_name): this.  This is to comply with the GNU coding guide.
14386         Use xtrymalloc instead of malloc.  Do not build for W32.
14387         (map_supervised_sockets): Use strtokenize and set the the socket names
14388         here.
14389         (main): Adjust for above change.  Do not close the socket.
14390
14391         agent: Adjust cleanup for supervised mode.  Fix for W32.
14392         + commit afcfae7959f39e7d85309b9496e1f1cf9acd5cc2
14393         * agent/gpg-agent.c (opts) [W32]: Remove option --supervised.
14394         (is_supervised): Move from main() to global.
14395         (inhibit_socket_removal): New.
14396         (cleanup): Take care of supervise mode and INHIBIT_SOCKET_REMOVAL.
14397         (check_own_socket_thread): Set INHIBIT_SOCKET_REMOVAL instead of
14398         seting the socket names to empty.
14399
14400         agent: Adjust supervised mode for the new default socket names.
14401         + commit dc059af1ff007842e2633e686c87d05daf1d45e3
14402         * agent/gpg-agent.c (main): In supervised mode do not provide default
14403         socket names.  Unset DISPLAY and INSIDE_EMACS.  Use log_error and
14404         agent_exit.
14405
14406 2016-10-04  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
14407
14408         agent: Implement --supervised command (for systemd, etc).
14409         + commit 9f92b62a51d2d60f038fdbe01602865c5933fa95
14410         * agent/gpg-agent.c (get_socket_path): New function for POSIX systems
14411         to return the path for a provided unix-domain socket.
14412         (map_supervised_sockets): New function to inspect $LISTEN_FDS and
14413         $LISTEN_FDNAMES and map them to the specific functionality offered by
14414         the agent.
14415         (main): Add --supervised command.  When used, listen on already-open
14416         file descriptors instead of opening our own.
14417         * doc/gpg-agent.texi: Document --supervised option.
14418
14419 2016-10-04  Justus Winter  <justus@g10code.com>
14420
14421         build,w32: Unconditionally build tests.
14422         + commit 4a232d23a8f51bebf9ee382e480248b4bde30f28
14423         * configure.ac (run_tests, RUN_TESTS, RUN_GPG_TESTS): Remove
14424         variables.  They are misleadingly named, as they inhibit building the
14425         tests.  There is no reason not to build the tests even when
14426         cross-compiling, as they are only run if one does 'make check'.
14427         * Makefile: Adapt accordingly.
14428         * tests/Makefile.am: Adapt accordingly.  Avoid building 'asschk' on
14429         Windows as it uses non-portable functions.
14430
14431         tests,w32: Do not expose 'glob' to gpgscm.
14432         + commit 41b510f9c510f8fd1b59eb0c5dd2e2b2deaf0a1b
14433         * tests/gpgscm/ffi.c (do_glob): Remove function.
14434         (ffi_init): Likewise.
14435
14436         tests,w32: Avoid using 'glob'.
14437         + commit 949e70115eb2c04bd09da6477f6c433e6fd9a366
14438         * tests/openpgp/setup.scm: Avoid 'glob' which is not available on
14439         mingw.
14440
14441         tools: Ignore existing directories in gpgtar.
14442         + commit fbc83c0cdd390473c044953fb774571ffc636c6d
14443         * tools/gpgtar-extract.c (extract_directory): Ignore existing
14444         directories now that we have '--directory'.
14445
14446 2016-10-04  NIIBE Yutaka  <gniibe@fsij.org>
14447
14448         agent, dirmngr, scd: npth_init must be after fork.
14449         + commit eda17649f8bd3b8ce7bfc00a3c11cbcae63c845d
14450         * agent/gpg-agent.c (thread_init_once, initialize_modules): New.
14451         (main): Make sure no daemonizing-fork call after npth_init, and no npth
14452         calls before npth_init, with care of npth calls by assuan hooks.
14453         * dirmngr/dirmngr.c (thread_init): New.
14454         (main): Make sure npth_init must not be called before daemonizing fork.
14455         * scd/scdaemon.c (main): Likewise.
14456
14457 2016-09-30  Werner Koch  <wk@gnupg.org>
14458
14459         agent: Remove the warning for the GKR hijacking.
14460         + commit a43739a2456a38c01704d8a52dca441055e29bc6
14461         * g10/call-agent.c (check_hijacking): Remove.
14462         (start_agent): Remove call.
14463
14464         agent: Create the extra sockets in the standard socket dir.
14465         + commit 80cc16e0728256f6b07a12980e1f3512cf2324fa
14466         * agent/gpg-agent.c (main): Take the socketdir in account for the
14467         default sockets.
14468         * tools/gpgconf.c (list_dirs): Add "agent-extra-socket" and
14469         "agent-browser-socket".
14470
14471         agent: Kludge to allow disabling of the extra sockets.
14472         + commit 95cf7afff074613825f4442fa131145a2c0d3cf7
14473         * agent/gpg-agent.c (main): Check for special socket names.
14474
14475         wks: Avoid long trustdb checks.
14476         + commit de67055aff916455cec89fab1d95177d3b383008
14477         * tools/wks-receive.c (verify_signature): Use --always-trust.
14478
14479 2016-09-30  Justus Winter  <justus@g10code.com>
14480
14481         build: Fix build against libiconv.
14482         + commit 6054e8aaecbd355bb7559697eecaadf2225189b8
14483         * agent/Makefile.am: Add INCICONV and LIBICONV.
14484         * common/Makefile.am: Likewise.
14485         * tools/Makefile.am: Likewise.
14486
14487         agent: Enable restricted, browser, and ssh socket by default.
14488         + commit e11686f973b35869d7b299ce4726003ac22e2e3a
14489         * agent/gpg-agent.c (main): Provide defaults for 'extra-socket' and
14490         'browser-socket', enable ssh socket by default, but do not emit the
14491         'SSH_AUTH_SOCK' variable unless it has been explicitly requested.
14492         * configure.ac (GPG_AGENT_{EXTRA,BROWSER}_SOCK_NAME): New definitions.
14493         * doc/gpg-agent.texi: Update documentation.
14494
14495         w32: Fix STARTTLS on LDAP connections.
14496         + commit 8d37018050373a47566bf8ea0d894da20ed292c7
14497         * dirmngr/ks-engine-ldap.c (my_ldap_connect): Fix build against
14498         <winldap.h>.
14499
14500 2016-09-29  Werner Koch  <wk@gnupg.org>
14501
14502         wks: Partly implement draft-koch-openpgp-webkey-service-02.
14503         + commit 33800280da55a859e08dfa57f29144c89dd1bead
14504         * tools/gpg-wks.h (WKS_RECEIVE_DRAFT2): New.
14505         * tools/wks-receive.c: Include rfc822parse.h.
14506         (struct receive_ctx_s): Add fields PARSER, DRAFT_VERSION_2, and
14507         MULTIPART_MIXED_SEEN.
14508         (decrypt_data): Add --no-options.
14509         (verify_signature): Ditto.
14510         (new_part): Check for Wks-Draft-Version header.  Take care of text
14511         parts.
14512         (wks_receive): Set Parser and pass a flag value to RESULT_CB.
14513         * tools/gpg-wks-client.c (read_confirmation_request): New.
14514         (main) <aRead>: Call read_confirmation_request instead of
14515         process_confirmation_request.
14516         (command_receive_cb): Ditto.  Add arg FLAGS..
14517         (decrypt_stream_status_cb, decrypt_stream): New.
14518         (command_send): Set header Wks-Draft-Version.
14519         * tools/gpg-wks-server.c (struct server_ctx_s): Add field
14520         DRAFT_VERSION_2.
14521         (sign_stream_status_cb, sign_stream): New.
14522         (command_receive_cb): Set draft flag.
14523         (send_confirmation_request): Rework to implement protocol draft
14524         version 2.
14525
14526         * tools/gpg-wks.h (DBG_MIME_VALUE, DBG_PARSER_VALUE): New.
14527         (DBG_MIME, DBG_PARSER, DBG_CRYPTO): New.  Use instead of a plain
14528         opt.debug where useful.
14529         * tools/gpg-wks-client.c (debug_flags): Add "mime" and "parser".
14530         * tools/gpg-wks-server.c (debug_flags): Ditto.
14531
14532         tools: Convey signeddata also to the part_data callback in mime-parser.
14533         + commit c738f92c195d91662ddc7848cc3c92c7f091f1f8
14534         * tools/mime-parser.c (mime_parser_parse): Factor some code out to ...
14535         (process_part_data): new.
14536         ((mime_parser_parse): Also call process_part_data for signed data.
14537
14538         tools: Allow retrieval of signed data from mime-maker.
14539         + commit f776757ea94542e2f425840dddaf3e65b0ff7757
14540         * tools/mime-maker.c (find_part): New.
14541         (mime_maker_get_part): New.
14542
14543         tools: Change mime-maker to write out CR,LF.
14544         + commit 29db3be6e8dbc9b4dd52cd1781106fa9fa3954a5
14545         * tools/mime-maker.c (struct part_s): Add field PARTID.
14546         (struct mime_maker_context_s): Add field PARTID_COUNTER.
14547         (dump_parts): Print part ids.
14548         (mime_maker_add_header): Assign PARTID.
14549         (mime_maker_add_container): Ditto.
14550         (mime_maker_get_partid): New.
14551         (write_ct_with_boundary): Remove.
14552         (add_header): Strip trailing white spaces.
14553         (write_header): Remove trailing spaces trimming.  Add arg BOUNDARY.
14554         Handle emdedded LFs.
14555         (write_gap, write_boundary, write_body): New.
14556         (write_tree): Use new functions.
14557
14558         tools: Simplify the mime-maker container creation.
14559         + commit 95d60c6ce9e8a7a7741553af957978c1f91547c5
14560         * tools/mime-maker.c (struct part_s): Remove field MEDIATYPE.
14561         (release_parts): Ditto.
14562         (dump_parts): Print a body line only if tehre is a body.
14563         (mime_maker_add_header): Check for body or container.
14564         (mime_maker_add_container): Remove arg MEDIATYPE.  Change all callers.
14565         (mime_maker_end_container): New.
14566
14567         tools: Give mime parser callbacks access to the rfc822 parser.
14568         + commit 4ac138c84d0f344ca9442f90c96f0e1f76062a4a
14569         * tools/mime-parser.c (mime_parser_context_s): Add field MSG.
14570         (parse_message_cb): Set it.
14571         (mime_parser_rfc822parser): New.
14572         * tools/mime-parser.h: Declare rfc822parse_t for the new prototype.
14573
14574 2016-09-29  Justus Winter  <justus@g10code.com>
14575
14576         dirmngr: Fix STARTTLS on LDAP connections.
14577         + commit 9e6f8a55ed04f876635792125858ee76a948802a
14578         * dirmngr/ks-engine-ldap.c (my_ldap_connect): Fix unfortunate typo.
14579
14580 2016-09-28  Werner Koch  <wk@gnupg.org>
14581
14582         gpg: Improve WKD by importing only the requested UID.
14583         + commit cbf2ac66692daa7a324108724698d60d6c7e473f
14584         * g10/keyserver.c: Include mbox-util.h.
14585         (keyserver_import_wkd): Do not use the global import options but
14586         employ an import filter.
14587
14588         gpg: Reject import if an import filter removed all user ids.
14589         + commit 80393661bdfa7ae0288644513575e8a5d708b084
14590         * g10/import.c (any_uid_left): New.
14591         (import_one): Check that a UID is left.
14592
14593         gpg: Make import filter data object more flexible.
14594         + commit c9237bf2ba2c49588576dcece756ebf5fe89aada
14595         * g10/main.h (import_filter_t): New.
14596         * g10/import.c (struct import_filter_s): Declare struct.
14597         (import_keep_uid, import_drop_sig): Replace by ...
14598         (import_filter): new.  Adjust all users.
14599         (cleanup_import_globals): Move code to ...
14600         (release_import_filter): new.
14601         (save_and_clear_import_filter): New.
14602         (restore_import_filter): New.
14603
14604         gpg: Make sure that internal key import is done with a binary stream.
14605         + commit 829949f3823c2306022928ce782f9c9d9c5f1cc8
14606         * g10/import.c (import_keys_internal): Open stream in binary mode.
14607
14608 2016-09-27  Justus Winter  <justus@g10code.com>
14609
14610         build: Do not link gpg-connect-agent against npth.
14611         + commit 20a16833ee2bb05f735377f705899302bcf2b4d3
14612         * tools/Makefile.am: Do not link gpg-connect-agent against npth.
14613
14614         build: Fix check for resolver library on macOS.
14615         + commit 2e64ccb0f96d615b1eb87e37f230a5d761aa9c36
14616         * configure.ac: Check for the mangled name of 'dn_skipname' first.
14617
14618         common: Correctly handle modules relying on npth.
14619         + commit 2b23a321ac0b07beeac1dfa8d71f223e66c49b71
14620         * common/Makefile.am (common_sources): Drop 'call-gpg.{c,h}'.
14621         (with_npth_sources): New variable.
14622         (libcommonpth_a_SOURCES): Use the new variable.
14623
14624 2016-09-27  NIIBE Yutaka  <gniibe@fsij.org>
14625
14626         agent, sm: Set CTX after start_agent.
14627         + commit 4e4843e735f32b5e79a51d8062da55bfaab6ad77
14628         * g10/call-agent.c (agent_keytocard): Assign parm.ctx after start_agent.
14629         * sm/call-agent.c (gpgsm_agent_pksign, gpgsm_scd_pksign)
14630         (gpgsm_agent_readkey, gpgsm_agent_scd_serialno)
14631         (gpgsm_agent_scd_keypairinfo, gpgsm_agent_marktrusted)
14632         (gpgsm_agent_passwd, gpgsm_agent_get_confirmation)
14633         (gpgsm_agent_ask_passphrase, gpgsm_agent_keywrap_key)
14634         (gpgsm_agent_export_key): Likewise.
14635
14636         dirmngr: Removal of no-libgcrypt.o.
14637         + commit 836b72363168cbb0051fc2356f61788468db211c
14638         * dirmngr/Makefile.am (dirmngr_ldap_LDADD): Remove no-libgcrypt.o.
14639
14640         agent: Allow only specific digest size for ECDSA.
14641         + commit 98bc6f480ac973dccce90378dc021a2e24e58704
14642         * agent/pksign.c (do_encode_dsa): Fix validation of digest size.
14643
14644 2016-09-22  Neal H. Walfield  <neal@g10code.com>
14645
14646         g10: When adding a user id, make sure the keyblock has been prepared.
14647         + commit df5353b95eefc13135e7df50a7c197f270d6080d
14648         * g10/keyedit.c (keyedit_quick_adduid): Call merge_keys_and_selfsig on
14649         KEYBLOCK before adding the user id.
14650         * tests/openpgp/quick-key-manipulation.scm: Make sure that the key
14651         capabilities don't change when adding a user id.
14652         (key-data): New function.
14653
14654 2016-09-20  Justus Winter  <justus@g10code.com>
14655
14656         tests: Add documentation, make interactive debugging possible.
14657         + commit 7e0379a75475abfd15e0623913795779ff0f40d7
14658         * tests/openpgp/README: Add documentation about debugging and
14659         interfacing with GnuPG.
14660         * tests/openpgp/run-tests.scm (test::run-sync): Hand stdin to the
14661         child so that we can use a repl in the tests.
14662
14663         tests: Port the quick key manipulation test to Scheme.
14664         + commit 6c4c0e3ac2aeafba7a2b7c2dd92a18be8aec92b1
14665         * tests/openpgp/Makefile.am (XTESTS): Add new test.
14666         * tests/openpgp/quick-key-manipulation.scm: New file.
14667
14668         tests: Remove list of tests from the test runner.
14669         + commit 49fae88fd170f2bdc12a1794a2637260e3c73a73
14670         * tests/openpgp/run-tests.scm: Drop hardcoded list.
14671
14672         tests: Reduce runtime of excessive test.
14673         + commit 988a04b98d42ff9cc9e62007ebcc0e4c03f4047d
14674         * tests/openpgp/conventional-mdc.scm: Use only two plaintexts when
14675         iterating over all cipher algorithms.
14676
14677         dirmngr: Fix type.
14678         + commit 285d193f1e1464495bce57bd0f323468515b4513
14679         * dirmngr/dns-stuff.c (get_dns_cert): Fix type in fallback code.
14680
14681 2016-09-20  Andre Heinecke  <aheinecke@intevation.de>
14682
14683         dirmngr: Open file CRL's in binary mode.
14684         + commit 4644c27514f34f5efc555d43672a25088a611a72
14685         * dirmngr/crlcache.c (crl_cache_load): Open file in binary mode.
14686
14687 2016-09-20  NIIBE Yutaka  <gniibe@fsij.org>
14688
14689         doc: Fix a xref usage.
14690         + commit b9b4ff857034df51e055ceddce567ca97e94e075
14691
14692
14693 2016-09-20  Ineiev  <ineiev@gnu.org>
14694
14695         doc: Do not end section names with "."
14696         + commit 8078d8246fa38c3e478fc9a542117468780ace00
14697
14698
14699 2016-09-20  NIIBE Yutaka  <gniibe@fsij.org>
14700
14701         doc: minor fix for @xref.
14702         + commit 9c1b3bc25a1b38c4eda31bf12ccc10d94bb05212
14703         * doc/yat2m.c (proc_texi_cmd): Captalize "see" for xref.
14704
14705 2016-09-20  Justus Winter  <justus@g10code.com>
14706
14707         doc: Implement simple '@ref'erences.
14708         + commit 91d5e6f805aaf24a3f1f03a95998f757dce04cb2
14709         * doc/yat2m.c (proc_texi_cmd): Handle '@ref'.
14710
14711 2016-09-20  Ineiev  <ineiev@gnu.org>
14712
14713         doc: Fix full stops.
14714         + commit 0eaab1af48f600b636183321e4a4e9c6bc361610
14715         * doc/gpg-agent.texi, doc/gpg.texi, doc/gpgsm.texi,
14716         doc/instguide.texi, doc/scdaemon.texi, doc/specify-user-id.texi,
14717         doc/tools.texi: Fix.
14718
14719         doc: Fix spacings.
14720         + commit 32bcf8b73ede9c8f1469821a54dedc6be75241d2
14721         * doc/debugging.texi, doc/dirmngr.texi, doc/gpg-agent.texi,
14722         doc/gpg.texi, doc/tools.texi: Fix.
14723
14724         doc: Improve markup.
14725         + commit 377624207e9b2895ce00dfc4d1163d72f349841f
14726         * doc/gpg-agent.texi, doc/gpg.texi, doc/gpgsm.texi,
14727         doc/howto-create-a-server-cert.texi, doc/scdaemon.texi,
14728         doc/specify-user-id.texi, doc/tools.texi: Fix.
14729
14730         doc: Replace rfc0123 with RFC-0123.
14731         + commit 9d2b7bff12b268638465da222ca7cc9042bba072
14732         * doc/gpg.texi, doc/gpgsm.texi, doc/specify-user-id.texi: Fix.
14733
14734         doc: Add missing description of datafile.
14735         + commit 789916281c25e737d8fb44add5ca61f8fd25de2f
14736         * doc/gpg.texi: Fix.
14737
14738         doc: Replace UTF8 with UTF-8.
14739         + commit 00d6d8bc8772e48b6f200d359e11eb93ab65f51f
14740         * doc/gpg.texi: Fix.
14741
14742         doc: Fix mistakes.
14743         + commit f25e04005af5831053ba194a09e3afa48d1e162b
14744         * doc/dirmngr.texi, doc/gpg.texi, doc/gpgsm.texi,
14745         doc/howto-create-a-server-cert.texi,
14746         doc/scdaemon.texi, doc/tools.texi: Fix.
14747
14748         doc: Eliminate inconsistent UK English.
14749         + commit 825c1dfb3ee4c1704f42eaf064161b9731c20134
14750         * doc/dirmngr.texi, doc/gpg-agent.texi, doc/scdaemon.texi,
14751         doc/tools.texi: Fix.
14752
14753         doc: Use the right reference commands.
14754         + commit f32689f833838a742243e94c900e98f5b59a5811
14755         * doc/debugging.texi, doc/gpg-agent.texi, doc/gpg.texi, doc/gpgsm.texi,
14756         doc/tools.texi: Fix.
14757
14758         doc: Fix "Not(e) that you can(not) abbreviate".
14759         + commit 20a27d8a57c4c990fcada4278a1ce2e6fc9043e9
14760         * doc/dirmngr.texi, doc/gpg-agent.texi, doc/gpg.texi, doc/gpgsm.texi,
14761         doc/scdaemon.texi, doc/tools.texi: Fix.
14762
14763         doc: Fix typos.
14764         + commit fa346508fe323e61cf157ee30c13301e1d2117c0
14765         * doc/debugging.texi, doc/dirmngr.texi, doc/glossary.texi
14766         * doc/gpg-agent.texi, doc/gpg.texi, doc/gpgsm.texi
14767         * doc/instguide.texi, doc/opt-homedir.texi, doc/scdaemon.texi
14768         * doc/specify-user-id.texi, doc/tools.texi: Fix.
14769
14770         doc: Fix Martin Hellman's name.
14771         + commit 858af2b3473e436af53470d53cdac334edce9f09
14772         * doc/contrib.texi: Fix.
14773
14774 2016-09-19  Justus Winter  <justus@g10code.com>
14775
14776         tests: Refine the repl function.
14777         + commit 884e78efe1f3ba50513bf81c8b4804d22b25eac4
14778         * tests/gpgscm/repl.scm (repl): Add an argument 'environment'.
14779         (interactive-repl): Add an optional argument 'environment'.
14780
14781         tests: Implement interpreter shutdown using exceptions.
14782         + commit 9a0659a65c52378de1c4736a0eddf8518eb20948
14783         * tests/gpgscm/ffi.c (ffi_init): Rename 'exit' to '_exit'.
14784         * tests/gpgscm/ffi.scm (*interpreter-exit*): New variable.
14785         (throw): New function.
14786         (exit): New function.
14787
14788         tests: Correctly handle exceptions in resource handling macros.
14789         + commit 58007e52593e6b0f838de2e464ceeacf22757018
14790         * tests/gpgscm/tests.scm (letfd): Correctly release resources when an
14791         exception is thrown.
14792         (with-working-directory): Likewise.
14793         (with-temporary-working-directory): Likewise.
14794         (lettmp): Likewise.
14795
14796         tests: Refine exception handling.
14797         + commit ab483eff9a8254adf127cdee178e14ba74f0a2b3
14798         * tests/gpgscm/init.scm (catch): Bind all arguments to '*error*' in
14799         the error handler, update and fix comment.
14800         (*error-hook*): Revert to original definition.
14801         * tests/gpgscm/tests.scm (tr:do): Adapt accordingly.
14802         * tests/openpgp/issue2419.scm: Likewise.
14803
14804         tests: Use descriptive temporary file names.
14805         + commit 83a406b38a21d0eeb4963db824a27783c212d2fb
14806         * tests/gpgscm/ffi.c (do_get_isotime): New function.
14807         (ffi_init): Add parameter 'scriptname', bind new function and
14808         scriptname.
14809         * tests/gpgscm/ffi.h (ffi_init): Update prototype.
14810         * tests/gpgscm/main.c (main): Hand in the script name.
14811         * tests/gpgscm/tests.scm (mkdtemp): Use current time and script name
14812         for the names of temporary directories.
14813
14814 2016-09-19  Werner Koch  <wk@gnupg.org>
14815
14816         gpg: Fix regression in fingerprint printing.
14817         + commit 998643666c016dbacf10f813c22efc97deadec65
14818         * g10/keylist.c (list_keyblock_print): Do not depend calling
14819         print_fingerprint on opt.keyid_format.
14820
14821         dirmngr: Silence diagnostics about starting housekeeping.
14822         + commit 5bf1facc973eb6e0bfab0f8f17129534dec56e04
14823         * dirmngr/dirmngr.c (housekeeping_thread): Print info only in very
14824         verbose mode.
14825
14826 2016-09-19  Justus Winter  <justus@g10code.com>
14827
14828         g10: Fix memory leak.
14829         + commit 086d219d96caa3501048aff82a282481e07c195b
14830         * g10/tofu.c (build_conflict_set): Free 'kb_all'.
14831
14832 2016-09-19  Werner Koch  <wk@gnupg.org>
14833
14834         doc: Update license information.
14835         + commit 3899041cd2877ce9584c7bd149f232f35a07c399
14836         * tests/fake-pinentries/COPYING: Rename to  ...
14837         * COPYING.CC0: this.  Add a note on the scope of this license.
14838         * COPYING.LIB: Add a note on the scope of this license.
14839         * AUTHORS (License): Mention CC) license.
14840
14841         gpgscm: Fix gcrypt version check.
14842         + commit 47baeac50ccaaf06dc8b0cebece50f47754de6ca
14843         * tests/gpgscm/main.c (main): Check against required and not installed
14844         version.
14845
14846         gpg: Avoid malloc failure due to no key signatures.
14847         + commit 18bbefa27f9e47e1062ee4d7af09487632795ba7
14848         * g10/keyedit.c (check_all_keysigs): Check early for no key
14849         signatures.  Use xtrycalloc.
14850
14851 2016-09-17  NIIBE Yutaka  <gniibe@fsij.org>
14852
14853         Fix comment and format.
14854         + commit 7305d27f36148a7fb8c2f4ef5b94774cbd21b18e
14855         * agent/protect-tool.c (main): Fix comment.
14856         * doc/DETAILS (colon listings): Fix list.
14857         * tests/openpgp/multisig.test: Fix comment.
14858
14859 2016-09-17  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
14860
14861         Fix more spelling.
14862         + commit 0d67241e317b172a258a910c02d90639e2b08fce
14863         * NEWS, acinclude.m4, agent/command-ssh.c, agent/command.c,
14864           agent/gpg-agent.c, agent/keyformat.txt, agent/protect-tool.c,
14865           common/asshelp.c, common/b64enc.c, common/recsel.c, doc/DETAILS,
14866           doc/HACKING, doc/Notes, doc/TRANSLATE, doc/dirmngr.texi,
14867           doc/faq.org, doc/gpg-agent.texi, doc/gpg.texi, doc/gpgsm.texi,
14868           doc/instguide.texi, g10/armor.c, g10/gpg.c, g10/keyedit.c,
14869           g10/mainproc.c, g10/pkclist.c, g10/tofu.c, g13/sh-cmd.c,
14870           g13/sh-dmcrypt.c, kbx/keybox-init.c, m4/pkg.m4, sm/call-dirmngr.c,
14871           sm/gpgsm.c, tests/Makefile.am, tests/gpgscm/Manual.txt,
14872           tests/gpgscm/scheme.c, tests/openpgp/gpgv-forged-keyring.scm,
14873           tests/openpgp/multisig.test, tests/openpgp/verify.scm,
14874           tests/pkits/README, tools/applygnupgdefaults,
14875           tools/gpg-connect-agent.c, tools/mime-maker.c, tools/mime-parser.c:
14876           minor spelling cleanup.
14877
14878         move some file encodings to UTF-8.
14879         + commit 215180d1ce6c93e2b4969d746c83ac4c055d25ef
14880         * dirmgnr/cdblib.c: comment used unnecesary hyphenation
14881         * dirmngr/crlcache.h: comment was iso-8859-1
14882         * doc/contrib.text: list contributors using UTF-8 (now we can
14883           acknowledge many more people using their preferred orthography)
14884
14885         At least one other files remains in a non-UTF-8 encoding, which i'm
14886         not sure what to do with:
14887
14888          - build-aux/speedo/w32/inst.nsi is ISO-8859-1, but maybe Windows needs
14889            it that way?
14890
14891 2016-09-16  Neal H. Walfield  <neal@g10code.com>
14892
14893         g10: On failure, propagate the return code.
14894         + commit 6e930f0e4077bc7aa3d28b1ba649a82d62427d87
14895         * g10/tofu.c (tofu_register_encryption): If get_trust fails, set RC.
14896
14897         g10: Don't ignore failure.  On failure, rollback.
14898         + commit 221b0bd0e5946edaea7135bc3b6f3c5c0fc6dbca
14899         * g10/tofu.c (tofu_set_policy): If record_binding fails, fail.  If the
14900         function fails, rollback the transaction.
14901
14902         g10: Load the key block if the supplied user id list is NULL.
14903         + commit c2e563421e4fd4f0910642aa7b171bcf0b374b01
14904         * g10/tofu.c (tofu_register_encryption): Load the key block if
14905         USER_ID_LIST is NULL.
14906
14907         g10: Use the accessor functions for accessing and comparing key ids.
14908         + commit af196342bf44ce6dc42111d37539dec7ee3b3d82
14909         * g10/tofu.c (get_trust): Use the pk_main_keyid accessor function.
14910         (tofu_register_signature): Likewise.
14911         (tofu_register_encryption): Likewise.
14912         (tofu_set_policy): Likewise and also use pk_keyid and keyid_cmp.
14913
14914 2016-09-16  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
14915
14916         po: convert localizations to UTF-8.
14917         + commit 4ab8107063b641ed74fc4c9bf98304bcea573178
14918         * po/{it,et,pl,ro,gl,es,el,sk,pt,eo,hu}.po: convert to UTF-8
14919
14920         This was an automated conversion process, using:
14921
14922            for x in po/{it,et,pl,ro,gl,es,el,sk,pt,eo,hu}.po; do
14923                cs=$(grep charset= $x | cut -f2 -d= | cut -f1 -d\\)
14924                iconv -f $cs -t UTF-8 < $x >$x.tmp
14925                sed "s/$cs/UTF-8/" < $x.tmp > $x
14926                rm -f $x.tmp
14927            done
14928
14929 2016-09-16  NIIBE Yutaka  <gniibe@fsij.org>
14930
14931         scd: Add support of ECC pubkey attribute.
14932         + commit dd06d33655bc872a6310edac8e448419479d3312
14933         * scd/app-openpgp.c (ECC_FLAG_PUBKEY): New.
14934         (send_key_attr, get_public_key, ecc_writekey, do_auth, do_decipher)
14935         (parse_algorithm_attribute): Check ECC_FLAG_DJB_TWEAK.
14936         (build_ecc_privkey_template): Add ECC_Q and ECC_Q_LEN.
14937         Support offering public key when ECC_FLAG_PUBKEY sets.
14938         (ecc_writekey): Supply ECC_Q and ECC_Q_LEN.
14939         (parse_algorithm_attribute): Parse pubkey-required byte.
14940
14941 2016-09-15  Justus Winter  <justus@g10code.com>
14942
14943         g10: Add missing header.
14944         + commit c0e620cee86b5dacc941964bd187bba0dfa90eea
14945         * g10/trustdb.c: Include 'mbox-util.h'.
14946
14947 2016-09-15  Neal H. Walfield  <neal@g10code.com>
14948
14949         g10: Only consider bindings matching the signer's user id.
14950         + commit 3f7f7447316f57d002d683af4ad30ac5730b9ebe
14951         * g10/trustdb.c (tdb_get_validity_core): If the signer's user id
14952         subpacket is present, only consider matching user ids.
14953
14954         g10: Don't include the signature when printing a binding's validity.
14955         + commit dcc64663051f8af82abc11e2699649c3b35936db
14956         * g10/mainproc.c (check_sig_and_print): When printing information
14957         about a binding don't include the current signature.
14958
14959 2016-09-15  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
14960
14961         tests/fake-pinentries: fake pinentries for downstream developers.
14962         + commit 3248182d1b5a03098ee797c980fa0f0ec06e716f
14963         * tests/fake-pinentries/README.txt and
14964           tests/fake-pinentries/fake-pinentry.{sh,py,pl,php}}: New public
14965           domain (CC0) files to encourage better test suite practices from
14966           downstream developers.
14967         * tests/fake-pinentries/COPYING (new): a copy of
14968           https://creativecommons.org/publicdomain/zero/1.0/legalcode.txt
14969
14970         spelling: conenction should be connection.
14971         + commit 167273ee9d3c04f29835aa2d12fde52eebf61efb
14972         * dirmngr/server.c, sm/server.c: s/conenction/connection/
14973
14974         spelling: correct achived to achieved.
14975         + commit 7fafc3c49901c118b47d4d13a41fb3575c1f9e4b
14976
14977
14978 2016-09-15  NIIBE Yutaka  <gniibe@fsij.org>
14979
14980         tests/gpgscm: Fix use of pointer.
14981         + commit 68eb5fbd37c31ed7c0c916656131eea7bb58d13d
14982         * tests/gpgscm/scheme-private.h (struct scheme): Use (void *) for
14983         alloc_seg.
14984         * tests/gpgscm/scheme.c (alloc_cellseg): Use (void *) for cp.  Use
14985         (void *) for coercion of address calculation.
14986
14987 2016-09-14  Neal H. Walfield  <neal@g10code.com>
14988
14989         g10: Fix whitespace.
14990         + commit 9799b5d18f8fd29872b75c4d70d370af2b4e9a89
14991         * g10/tofu.c (show_statistics): Fix whitespace.
14992
14993         g10: Correctly compute the euclidean distance.
14994         + commit 05b2b13efd8ecea86d31af863cbf82c8b38dc94f
14995         * g10/tofu.c (write_stats_status): Correctly compute the euclidean
14996         distance.
14997         (show_statistics): Likewise.
14998
14999         g10: Change the default TOFU policy for UTKs to good.
15000         + commit ca91caabb5798f67c69ee96657c7cb402e7db0df
15001         * g10/tofu.c (get_trust): Change the default TOFU policy for UTKs to
15002         good.
15003
15004         g10: Add missing static qualifier.
15005         + commit 9d62b79e62ef2690e6522fe1621140fbfc10695c
15006         * g10/tofu.c (cross_sigs): Add missing static qualifier.
15007
15008         g10: Default to the "good" TOFU policy for keys signed by a UTK.
15009         + commit 8df8aa13c795e400324a782fbaea578c8f2a1398
15010         * g10/tofu.c (signed_by_utk): New function.
15011         (get_trust): If a key is signed by an ultimately trusted key, then
15012         set any bindings to good.
15013
15014 2016-09-14  Werner Koch  <wk@gnupg.org>
15015
15016         gpg: Emit a new error status line in --quick-adduid.
15017         + commit f4e11f2e9e8f58fd5f0df3148e6d7ccef0f84232
15018         * g10/keyedit.c (menu_adduid): Emit an ERROR status for an existsing
15019         user id.
15020
15021         gpg: Allow use of "default" algo for--quick-addkey.
15022         + commit 0fd332bc1f6f1f10c96da0cc91203925d3ac81eb
15023         * g10/keygen.c (quick_generate_keypair): Write a status error.
15024         (parse_algo_usage_expire): Set a default curve.
15025
15026 2016-09-13  Werner Koch  <wk@gnupg.org>
15027
15028         gpg: Improve usability of --quick-gen-key.
15029         + commit 30a011cfd6ec172cc460e59f0904a26fe2d68632
15030         * g10/keygen.c (FUTURE_STD_): New constants.
15031         (parse_expire_string): Handle special keywords.
15032         (parse_algo_usage_expire): Allow "future-default".  Simplify call to
15033         parse_expire_string.
15034         (quick_generate_keypair): Always allow an expiration date.  Replace
15035         former "test-default" by "future-default".
15036
15037 2016-09-12  Werner Koch  <wk@gnupg.org>
15038
15039         gpg: Avoid mixing up status and colon line output.
15040         + commit 31fc420727f45dd081f8ad5d056da6675dad29f2
15041         * g10/keylist.c (list_keyblock_colon): Avoid calling functions which
15042         trigger a status line output before having printed a LF.
15043
15044 2016-09-12  Justus Winter  <justus@g10code.com>
15045
15046         tests: Simplify tofu test.
15047         + commit aa81e32df7189c3eb44d4c602fd63f5b3f6a9e49
15048         * tests/openpgp/tofu.scm: Simplify now that we only have one db
15049         format.
15050
15051 2016-09-10  Ben Kibbey  <bjk@luxsci.net>
15052
15053         Portability build fix.
15054         + commit eddcba038025cdbd58aaf67cafd6d83f0ea042d5
15055         * kbx/Makefile.am: Add NETLIBS.
15056         * dirmngr/Makefile.am: Ditto for dirmngr_ldap.
15057
15058         Fix symbol conflict.
15059         + commit 937ec53eff290c3d916faebc23218c9272671c02
15060         * g10/gpgcompose.c: Rename struct siginfo to signinfo.
15061
15062 2016-09-09  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
15063
15064         gpg: print fingerprint regardless of keyid-format.
15065         + commit d757009a24eb856770fc3a3729e2f21f54d2a618
15066         * g10/keylist.c (print_fingerprint): use compact format independent of
15067           keyid-format; (print_key_line): always print the fingerprint
15068
15069 2016-09-08  Werner Koch  <wk@gnupg.org>
15070
15071         gpg: Remove option --yes from gpgv.
15072         + commit 30a9f53a0f2af6b98c26b8ddc0b4b87c38416f2a
15073         * g10/gpgv.c (opts): Remove --yes.
15074         (main): Always set opt.ANSWER_YES.
15075
15076         gpg: Add options --output and --yes to gpgv.
15077         + commit a8363b7d0bcc77b55226d5fe8f972214c968ddc3
15078         * g10/gpgv.c (oOutput, oAnswerYes): New.
15079         (opts): Add --output and --yes.
15080         (main): Implement options.
15081
15082         gpg: Make --output work with --verify.
15083         + commit bbe940c095f2bca7a1ca5f8e68ca1af98350a885
15084         * g10/mainproc.c (proc_plaintext): Handle opt.output.
15085
15086 2016-09-07  Werner Koch  <wk@gnupg.org>
15087
15088         dirmngr: Terminate on deletion of the socket file (Linux only).
15089         + commit 6308c300196ae85fd82ed383217219e0206640a4
15090         * dirmngr/dirmngr.c [HAVE_INOTIFY_INIT]: Include sys/inotify.h.
15091         (oDisableCheckOwnSocket): New.
15092         (opts): Add --disable-check-own-socket.
15093         (disable_check_own_socket): New var.
15094         (parse_rereadable_options): Set that var.
15095         (my_inotify_is_name) [HAVE_INOTIFY_INIT]: New.
15096         (handle_connections) [HAVE_INOTIFY_INIT]: New.
15097
15098 2016-09-07  Neal H. Walfield  <neal@g10code.com>
15099
15100         g10: Use the time a signature was seen, not the embedded time, for stats
15101         + commit bde29a46cedbbd2a5dfe7c91a6277c0a4ff50825
15102         * g10/tofu.c (ask_about_binding): Use the time that a signature was
15103         seen, not allegedly generated, when generating statistics.
15104
15105         tests: Don't use --tofu-db-format.
15106         + commit a937eef2d4e80cd43095802176d3db5e7fd94008
15107         * tests/openpgp/tofu.scm: Remove use of --tofu-db-format, which is
15108         deprecated.
15109
15110         g10: Check for a new binding a bit later.
15111         + commit ee06b3f7889bd99c28ac68f4781bda77d67eed00
15112         * g10/tofu.c (build_conflict_set): Check for the current key after
15113         looking for conflicts and removing any '!'.
15114
15115         g10: Change TOFU code to respect --faked-system-time.
15116         + commit 7b3e8572e3bb8a65d20577a48009251fdc7b1910
15117         * g10/tofu.c (record_binding): New parameter now.  Update callers.
15118         Don't use SQLite's strftime('%s','now') to get the current time, use
15119         NOW.
15120         (ask_about_binding): Likewise.
15121         (get_trust): New parameter now.  Update callers.
15122         (show_statistics): Likewise.
15123         (tofu_register_signature): Don't use SQLite's strftime('%s','now') to
15124         get the current time, use gnupg_get_time().
15125         (tofu_register_encryption): Likewise.
15126
15127         g10: Use the correct conversion function.
15128         + commit 56c18408d4955713d9c4e634367c7912d6564651
15129         * g10/tofu.c (show_statistics): Use string_to_ulong, not
15130         string_to_long.
15131
15132 2016-09-07  Werner Koch  <wk@gnupg.org>
15133
15134         gpg: Fix format string issues in tofu.
15135         + commit 97a67d42dc946b2d6ed81723d86e37002b5931b3
15136         * g10/tofu.c (write_stats_status): Use ulong for MESSSAGES.  Fix
15137         format strings.  Simplify by using the new write_status_printf.
15138
15139 2016-09-06  Neal H. Walfield  <neal@g10code.com>
15140
15141         g10: Make sure some functions are passed a primary key.
15142         + commit 13ddc17ddb266d74033d5739fec932034fa85c72
15143         * g10/tofu.c (get_trust): Make sure the caller provides a primary key.
15144         (tofu_register_signature): Likewise.
15145
15146         g10: Tweak TOFU's verbosity.
15147         + commit ee19eacd1d688d3a98cd66e5ef2f42079eb829f1
15148         * g10/tofu.c (time_ago_str): Only show the most significant unit.
15149         * g10/tofu.c (show_statistics): Tweak the output.
15150
15151         g10: Only show the TOFU warning once per key.
15152         + commit 67cef405cbfad2e53fc388dd6591ee4f7cb0d973
15153         * g10/tofu.c (show_statistics): Return whether to call show_warning.
15154         Move the warning from here...
15155         (show_warning): ... to this new function.
15156         (tofu_get_validity): If show_statistics returns a non-zero value, call
15157         show_warning.
15158
15159         g10: Record and show statistics for encrypted messages when using TOFU.
15160         + commit 875ac9216f1383851a82bd240cadb17c7112f6a8
15161         * g10/tofu.c: Include "sqrtu32.h".
15162         (struct tofu_dbs_s.s): Rename get_trust_gather_other_keys to
15163         get_trust_gather_signature_stats.  Add new field
15164         get_trust_gather_encryption_stats.
15165         (initdb): Create the encryptions table.
15166         (ask_about_binding): Show the encryption statistics too.
15167         (tofu_register): Rename from this...
15168         (tofu_register_signature): ... to this and update callers.
15169         (tofu_register_encryption): New function.
15170         (write_stats_status): Add parameters encryption_count,
15171         encryption_first_done and encryption_most_recent.  Update callers.
15172         Compute the trust using the euclidean distance of the signature and
15173         signature count.  Compare with twice the threshold.  Include
15174         encryption count information in the TFS and TOFU_STATS lines.
15175         (show_statistics): Also get information about the encrypted messages.
15176         * g10/trustdb.c (tdb_get_validity_core): Use it.
15177
15178         g10: Simplify the binding statistics shown for a TOFU conflict.
15179         + commit a9e6db6c7e23d9f4b8de59f5cabbf9eb6a59e626
15180         * g10/tofu.c (ask_about_binding): Simplify binding statistics.
15181
15182 2016-09-06  Justus Winter  <justus@g10code.com>
15183
15184         gpgscm: Fix detection of unbalanced parenthesis.
15185         + commit f2249b737055f84842778285bbeff5e61fa55225
15186         * tests/gpgscm/main.c (load): Print error message.
15187         * tests/gpgscm/scheme.c (opexe_0): Correctly report nesting level when
15188         loading files.
15189
15190         tests: Fix test.
15191         + commit 213b3cf465fb091dc0a205d1a08b88b950ffb85f
15192         * tests/openpgp/multisig.scm: Add missing parenthesis.
15193
15194 2016-09-06  Werner Koch  <wk@gnupg.org>
15195
15196         agent: Terminate on deletion of the socket file (Linux only).
15197         + commit 650356148af43ea619bec12e599a4981b147d5f8
15198         * configure.ac (AC_CHECK_FUNCS): Chec for inotify_init.
15199         * agent/gpg-agent.c [HAVE_INOTIFY_INIT]: Include sys/inotify.h.
15200         (my_inotify_is_name) [HAVE_INOTIFY_INIT]: New.
15201         (handle_connections) [HAVE_INOTIFY_INIT]: New.
15202
15203 2016-09-05  Justus Winter  <justus@g10code.com>
15204
15205         tests: Speed up the test suite.
15206         + commit 46c4333c372f0e1ad2aadc411490c2a330b4c5a6
15207         * tests/openpgp/run-tests.scm (test::run-sync): Pass additional
15208         arguments to the test.
15209         (test::run-sync-quiet): Likewise.
15210         (test::run-async): Likewise.
15211         (run-tests-{parallel,sequential}-isolated): Create a tarball of the
15212         gnupghome, then extract it for each test.
15213         * tests/openpgp/setup.scm: Refactor into functions, add an interface
15214         to tar-up the created environment, and untar it multiple times.
15215
15216         common: Restore a simpler variant of 'gnupg_wait_process'.
15217         + commit c97bde2dfeab23a84b4788d998934ac49ff5b797
15218         * common/exechelp-posix.c (gnupg_wait_process): Use the code prior to
15219         5ba4f604.
15220
15221         common: Fix error handling.
15222         + commit 845e2cc201d6a2cdb151e39e29516d26cb49311c
15223         * common/exechelp-posix.c (store_result): Use xtrymalloc.
15224         (gnupg_wait_processes): Likewise, and check result.
15225
15226 2016-09-05  Neal H. Walfield  <neal@g10code.com>
15227
15228         g10: Don't add user attributes to the TOFU DB.
15229         + commit 9082bde01cc18e32504ce39d55ea6dd3c05dddec
15230         * g10/trustdb.c (tdb_get_validity_core): Skip user attributes.
15231
15232 2016-09-05  Werner Koch  <wk@gnupg.org>
15233
15234         agent: Silence --debug IPC output for connections from self.
15235         + commit 0b99d1fd2a80b8efaacc731027d2b2ecd9eca699
15236         * agent/command.c (server_local_s): Add fields 'greeting_seen' and
15237         'connect_from_self'.
15238         (io_monitor): Do not log connections from self.
15239         (start_command_handler): Set flag 'connect_from_self'.
15240         * agent/gpg-agent.c (check_own_socket_thread): Disable logging.
15241         (do_start_connection_thread): Do not log conection start and
15242         termination if IPC debugging is enabled.
15243
15244         agent: Small improvement of the server's local state.
15245         + commit 2eeb5551c37659fdd59e8537fc77a9e7fb6a9204
15246         * agent/command.c (sserver_local_s): Change flags to use only one bit.
15247         (option_handler): Make an atoi return 1 or 0.
15248
15249 2016-09-05  Neal H. Walfield  <neal@g10code.com>
15250
15251         g10: Refactor cross sig check code.
15252         + commit 1f1f56e606c1cb28eec68c60bd8bcb7ab30805de
15253         * g10/tofu.c (BINDING_NEW): New enum value.
15254         (BINDING_CONFLICT): Likewise.
15255         (BINDING_EXPIRED): Likewise.
15256         (BINDING_REVOKED): Likewise.
15257         (ask_about_binding): Move cross sig check from here...
15258         (get_trust): ... and the conflict set building from here...
15259         (build_conflict_set): ... to this new function.
15260         (format_conflict_msg_part1): Replace parameter conflict with
15261         conflict_set.  Drop parameter fingerprint.  Update callers.
15262         (ask_about_binding): Drop unused parameter conflict and redundant
15263         parameter bindings_with_this_email_count.  Rename parameter
15264         bindings_with_this_email to conflict_set.  Update callers.
15265
15266 2016-09-05  Justus Winter  <justus@g10code.com>
15267
15268         tests: Update README.
15269         + commit 65a7563edbbab8f93fe901f932065687508788de
15270         * tests/openpgp/README: Update.
15271
15272         tests: Pass flags to test driver.
15273         + commit 059c79d8b447a3baa9ad0b4d3367bdb64dd2ef3b
15274         * tests/openpgp/Makefile.am (xcheck): Pass flags to 'run-tests.scm'.
15275
15276         common: Improve waiting for processes on POSIX.
15277         + commit e33111fcdac08ed2ddfbdf59b1f790569b42f695
15278         * common/exechelp-posix.c (struct terminated_child): New definition.
15279         (terminated_children): New variable.
15280         (store_result): New function.
15281         (get_result): Likewise.
15282         (gnupg_wait_process): Store results that were not requested and
15283         consider previously stored results.
15284
15285         waitpid(2) may return information about terminated children that we
15286         did not yet request, and there is no portable way to wait for a
15287         specific set of children.  As a workaround, we store the results of
15288         children for later use.
15289
15290 2016-09-05  Werner Koch  <wk@gnupg.org>
15291
15292         dirmngr: Exclude D lines from the IPC debug output.
15293         + commit de623474db3ba402c9bbd872ab6f932f46cbdde9
15294         * dirmngr/dirmngr.h: Include asshelp.h.
15295         * dirmngr/server.c (server_local_s): Add inhibit_dara_logging fields.
15296         (data_line_write): Implement logging inhibit.
15297         (data_line_cookie_close): Print non-logged D lines.
15298         (cmd_wkd_get, cmd_ks_get, cmd_ks_fetch): Do not log D lines.
15299         (dirmngr_assuan_log_monitor): New.
15300         * dirmngr/dirmngr.c (main): Register monitor function.
15301
15302         common: Add an assuan logging monitor.
15303         + commit 0ac671f8a2b65a4b339f615c6420287a549779fa
15304         * common/asshelp.c (my_log_monitor): New var.
15305         (my_libassuan_log_handler): Run that monitor.
15306         (setup_libassuan_logging): Add arg to set a log monitor and change all
15307         callers.
15308
15309         gpg: New export filter drop-subkey.
15310         + commit 0a4a03e5310946b0866a0f6a34031eda7a240162
15311         * g10/import.c (impex_filter_getval): Add properties for key packets.
15312         * g10/export.c (export_drop_subkey): New var.
15313         (cleanup_export_globals): Release that var.
15314         (parse_and_set_export_filter): Add filter "drop-subkey".
15315         (apply_drop_subkey_filter): New.
15316         (do_export_stream): Run that filter.
15317
15318         common: Add string operator gt,ge,le,lt to recsel.
15319         + commit 959cd8903fd012e63dbb156db56708dd3934b5df
15320         * common/recsel.c (recsel_parse_expr): Add them.
15321         (recsel_dump): Print them.
15322         (recsel_select): Evaluate them.
15323
15324         gpg: Use a common filter_getval for import and export.
15325         + commit c8e0d37f4152d1341ef562a190fce93a0386a759
15326         * g10/import.c (filter_getval): Rename to ...
15327         (impex_filter_getval): this.  Make global.
15328         (apply_keep_uid_filter, apply_drop_sig_filter): Adjust.
15329         * g10/export.c (filter_getval): Remove.
15330         (apply_drop_sig_filter): Use impex_filter_getval.
15331
15332 2016-09-03  NIIBE Yutaka  <gniibe@fsij.org>
15333
15334         scd: Fix an action after card removal.
15335         + commit f9e49c80e706a27d5e30d4b3237ff26367a67130
15336         * scd/command.c (update_card_removed): Call apdu_close_reader here.
15337
15338 2016-09-02  Werner Koch  <wk@gnupg.org>
15339
15340         wks: Add framework for policy flags.
15341         + commit 46362cbc0e2260e989820795a6e4245c72335172
15342         * tools/call-dirmngr.c (wkd_get_policy_flags): New.
15343         * tools/gpg-wks.h (struct policy_flags_s, policy_flags_t): New.
15344         * tools/wks-util.c (wks_parse_policy): New.
15345         * tools/gpg-wks-client.c (command_send): Get the policy flags to show
15346         a new info line.
15347         * tools/gpg-wks-server.c (get_policy_flags): New.
15348         (process_new_key): get policy flag and add a stub for "auth-submit".
15349         (command_list_domains): Check policy flags.
15350
15351         dirmngr: Add --policy-flags option to WKD_GET.
15352         + commit 505ee45106d6aa2902bbdd6326f8eb7527c273c4
15353         * dirmngr/server.c (cmd_wkd_get): Add new option.
15354
15355         common: Check read errors in name-value.c.
15356         + commit fc445b36fafc8a4cc3ce5a675ac42df7a9d9a02a
15357         * common/name-value.c: Check for read errors.
15358
15359 2016-09-02  NIIBE Yutaka  <gniibe@fsij.org>
15360
15361         scd: Release the card reader after card removal.
15362         + commit 8fe81055762d9c9e6f03fb7853a985c94ef73ac3
15363         * scd/command.c (update_reader_status_file): Call apdu_close_reader.
15364
15365         scd: Clean up unused shutdown method.
15366         + commit d1ae7103352fbda2a05f098379cd3043a0ab5566
15367         * scd/apdu.c (shutdown_ccid_reader, apdu_shutdown_reader): Remove.
15368         (reset_ccid_reader): Don't set shutdown_reader.
15369         * scd/ccid-driver.c (ccid_shutdown_reader): Remove.
15370
15371         agent: invoke scdaemon with --homedir.
15372         + commit 8b6c0bae33bdc36892f4595806665ce61f77dfd2
15373         * agent/call-scd.c (start_scd): Supply --homedir option when it's not
15374         default homedir.
15375
15376         po: Update Japanese translation.
15377         + commit afdfc954b35370fbf03aaf8dc0e496410923aa4e
15378
15379
15380 2016-09-01  Neal H. Walfield  <neal@g10code.com>
15381
15382         g10: End transaction earlier.
15383         + commit 85fad6c34c08b2850580e0644faba62d3a501b84
15384         * g10/tofu.c (ask_about_binding): End the transaction earlier.
15385
15386         g10: Don't consider cross-signed keys to be in conflict.
15387         + commit b410a3cb7683fc7c2a253e23130c44df42a6203c
15388         * g10/tofu.c (cross_sigs): New function.
15389         (ask_about_binding): If apparently conflicting keys are cross signed,
15390         then don't mark them as conflicting.
15391
15392 2016-09-01  Werner Koch  <wk@gnupg.org>
15393
15394         gpg: Avoid homedir creation by --list-config.
15395         + commit 38d369de13acb95208a0ed8d1cf82ac19173688f
15396         * g10/gpg.c (main): Do not register a key for the list config
15397         commands.
15398
15399         gpg: Simplify code to print VALIDSIG.
15400         + commit fde9fa81d3d3b25a929b532cc1960d9d9f454a0c
15401         * g10/mainproc.c (check_sig_and_print): Use hexfingerprint and
15402         write_status_printf.
15403
15404         gpg: Add new function write_status_printf.
15405         + commit 6bdadae00512b4907826f6754cdb220d06e1ac6d
15406         * g10/cpr.c (write_status_printf): New.
15407
15408         gpg: Fix printing of pubkey algo in --verbose signature verify.
15409         + commit 37e3c897252babc203447be9d2f286a4507875ad
15410         * g10/sig-check.c (check_signature2): Replace arg PK by R_PK and
15411         change the semantics.  Also clear the other R_ args on function entry,
15412         use gpg_error() and change retturn type to gpg_error_t.
15413         * g10/mainproc.c (do_check_sig): Add arg R_PK.
15414         (list_node): Pass NULL for new arg.
15415         (check_sig_and_print): Rework to make use of the returned PK.
15416
15417 2016-09-01  Neal H. Walfield  <neal@g10code.com>
15418
15419         g10: When asking about a TOFU binding conflict, default to unknown.
15420         + commit 3d44e5e8a8d1d8bf6cf5d387f50d75f84d804412
15421         * g10/tofu.c (ask_about_binding): Default to unknown.
15422
15423         g10: Add support for TRUST_NEVER.
15424         + commit f2e5cb6ffb55e49a05d452cd85e45f6f67c20abb
15425         * g10/pkclist.c (do_we_trust): Handle TRUST_NEVER, which can be
15426         returned by the TOFU trust model.
15427         (do_we_trust_pre): Print a different message if TRUSTLEVEL is
15428         TRUST_NEVER.
15429         (check_signatures_trust): Improve comment.
15430
15431         g10: Improve text.
15432         + commit 0cb0ea1633955fb7acd33fe993a4ae4e96e83ae3
15433         * g10/tofu.c (show_statistics): Improve the text (key and user id, not
15434         just key).
15435
15436         g10: Remove unused parameter.
15437         + commit 00c2850393ecc320f591f511c3534286964780c2
15438         * g10/tofu.c (show_statistics): Remove unused parameter sig_exclude.
15439         Update callers.
15440
15441 2016-09-01  Werner Koch  <wk@gnupg.org>
15442
15443         gpg: Copy the correct digest for use by TOFU.
15444         + commit 3e67b50490aef087b5769bb35145d23f6657780f
15445         * g10/mainproc.c (do_check_sig): Use the current digest algo.
15446
15447 2016-09-01  Neal H. Walfield  <neal@g10code.com>
15448
15449         g10: Be careful to not be in a transaction during long operations.
15450         + commit 4cbd2a690c5e5ed2dff49c1f4fc867b31fca689a
15451         * g10/tofu.c (begin_transaction): New parameter only_batch.  If set,
15452         only start a batch transaction if there is none and one has been
15453         requested.  Update callers.
15454         (tofu_suspend_batch_transaction): New function.
15455         (tofu_resume_batch_transaction): Likewise.
15456         (ask_about_binding): Take a ctrl_t, not a tofu_dbs_t.  Update
15457         callers.  Gather statistics within a transaction.  Suspend any batch
15458         transaction when getting user input.
15459         (get_trust): Take a ctrl_t, not a tofu_dbs_t.  Update callers.
15460         Enclose in a transaction.
15461         (tofu_get_validity): Use a batch transaction, not a normal
15462         transaction.
15463
15464 2016-09-01  Werner Koch  <wk@gnupg.org>
15465
15466         tests: Run test requiring the network only in maintainer-mode.
15467         + commit babeb6f8a9b1f8341652145bad58be6cd49e0712
15468         * dirmngr/Makefile.am (noinst_PROGRAMS, TESTS): Add module_net_tests.
15469         (module_tests): Move t-dns-test to ...
15470         (module_net_tests): here.
15471
15472 2016-08-31  Werner Koch  <wk@gnupg.org>
15473
15474         wks: Send a final message to the user.
15475         + commit 04c042f3f2a631bc6e772c33f8da5e7aa7b1902a
15476         * tools/gpg-wks-server.c (send_congratulation_message): New.
15477         (check_and_publish): Call it.
15478
15479         wks: Relax permission check for the top directory.
15480         + commit e4eac16330449f3893c11820c15e07d58fb807ff
15481         * tools/gpg-wks-server.c: Allow S_IXOTH for the top directory.
15482
15483 2016-08-31  Neal H. Walfield  <neal@g10code.com>
15484
15485         g10: On a TOFU conflict, show whether the uids are expired or revoked.
15486         + commit edfb6934caf16c6afcfd82d684d8ae9c79674d10
15487         * g10/tofu.c (struct signature_stats): Add fields is_expired and
15488         is_revoked.
15489         (signature_stats_prepend): Clear *stats when allocating it.
15490         (ask_about_binding): Also show whether the user ids are expired or
15491         revoked.
15492
15493         doc: Add a help text for tofu.conflict.
15494         + commit b69b2cb082e39a7eb56082fa80219f6f14fbd2b4
15495         * doc/help.txt (.gpg.tofu.conflict): New help text.
15496
15497         g10: Always trust ultimately trusted keys.
15498         + commit 28c235ae757e9036b0b96efc28931fa5cc74f7ee
15499         * g10/tofu.c (get_trust): Always return TRUST_ULTIMATE for ultimately
15500         trusted keys.
15501
15502         g10: Fix error detection.
15503         + commit 5b48960a8a2555db7bf992261de9e922838c9913
15504         * g10/tofu.c: first_seen == 0 is not an error.
15505
15506         g10: Update a key's TOFU policy in a transaction.
15507         + commit e4d5e3cb0d10e8f77c7100d42cfdb32051de1c18
15508         * g10/tofu.c (tofu_set_policy): Do the update in a transaction.
15509         * g10/gpg.c (main): Do a TOFU policy update in a batch transaction.
15510
15511         g10: Fix the show old policy functionality when changing a TOFU policy.
15512         + commit 247eef005cf4c34e9a82227e4ab7823e04911be4
15513         * g10/tofu.c (record_binding): Fix the show old policy functionality.
15514
15515         g10: Drop unused argument.
15516         + commit 70df5a8fd781d8774d835384ca28c4d8518bb9d0
15517         * g10/tofu.c (begin_transaction): Remove unused option only_batch.
15518
15519         gpg: Move state local to tofu.c to a private structure.
15520         + commit 268f6b7a3403d036882b4af384ba7ab2f8c8355f
15521         * g10/gpg.h (struct server_control_s.tofu): Move fields in_transaction
15522         and batch_update_started from here...
15523         * g10/tofu.c (struct tofu_dbs_s): ... to here.
15524
15525         gpg: Avoid name spaces clash with future sqlite versions (2).
15526         + commit b8184d2d74e5ddd5eb68836b53fe5568110e14dd
15527         * g10/gpgsql.h (gpgsql_arg_type): Rename SQLITE_ARG_END to
15528         GPGSQL_ARG_END, SQLITE_ARG_INT to GPGSQL_ARG_INT, SQLITE_ARG_LONG_LONG
15529         to GPGSQL_ARG_LONG_LONG, SQLITE_ARG_STRING to GPGSQL_ARG_STRING, and
15530         SQLITE_ARG_BLOB to GPGSQL_ARG_BLOB.
15531
15532 2016-08-31  Werner Koch  <wk@gnupg.org>
15533
15534         gpg: Fix regression in gpgv's printing of the keyid.
15535         + commit 76304a971fe507ea659b952932ea899463ab7166
15536         * g10/keyid.c (keystr): Take care of KF_NONE != KF_DEFAULT.
15537
15538 2016-08-30  Neal H. Walfield  <neal@g10code.com>
15539
15540         g10: Improve TOFU batch update code.
15541         + commit 371ae66e9d5c7524431773c4a479fcae1ea3b652
15542         * g10/gpg.h (tofu): Rename field batch_update_ref to
15543         batch_updated_wanted.
15544         * g10/tofu.c (struct tofu_dbs_s): Rename field batch_update to
15545         in_batch_transaction.
15546         (begin_transaction): Only end an extant batch transaction if we are
15547         not in a normal transaction.  When ending a batch transaction, really
15548         end it.  Update ctrl->tofu.batch_update_started when starting a batch
15549         transaction.
15550         (end_transaction): Only release a batch transaction if ONLY_BATCH is
15551         true.  When releasing a batch transaction, assert that there is no
15552         open normal transaction.  Only allow DBS to be NULL if ONLY_BATCH is
15553         true.
15554         (tofu_begin_batch_update): Don't update
15555         ctrl->tofu.batch_update_started.
15556         (opendbs): Call end_transaction unconditionally.
15557
15558         g10: If a key has no valid user ids, change TOFU to return TRUST_NEVER.
15559         + commit d0451440c036106895a291f9ca1c53c2d5159f8f
15560         * g10/tofu.c (tofu_get_validity): If a key has no valid (non-expired)
15561         user ids, change TOFU to return TRUST_NEVER.
15562
15563         g10: Change tofu_register & tofu_get_validity to process multiple uids.
15564         + commit 6052c147091935fc0321ba24f4a44146df70ef01
15565         * g10/tofu.c (tofu_register): Take a list of user ids, not a single
15566         user id.  Only register the bindings, don't compute the trust.  Thus,
15567         change return type to an int and remove the may_ask parameter.  Update
15568         callers.
15569         (tofu_get_validity): Take a list of user ids, not a single user id.
15570         Update callers.  Observe signatures made by expired user ids, but
15571         don't include them in the trust calculation.
15572
15573         g10: Support nested transactions on the TOFU DB.
15574         + commit 33e97813d72996d22a295773c64261f5588ce9dd
15575         * g10/gpg.h (struct server_control_s): New field in_transaction.
15576         * g10/tofu.c (struct tofu_dbs_s): Remove fields savepoint_inner and
15577         savepoint_inner_commit.
15578         (begin_transaction): Increment CTRL->TOFU.IN_TRANSACTION.  Name the
15579         savepoint according to the nesting level.
15580         (end_transaction): Name the savepoint according to the nesting level.
15581         Decrement CTRL->TOFU.IN_TRANSACTION.
15582         (rollback_transaction): Likewise.  Only ever rollback a non-batch
15583         transaction.
15584         (opendbs): Assert that there are no outstanding transactions.
15585
15586         g10: Print the info text in more situations.
15587         + commit 4c2abb221b29c9e8e0876fe986472b562ee1c99f
15588         * g10/tofu.c (ask_about_binding): Print the info text when the policy
15589         is ask and there are multiple bindings with the email address.
15590
15591         g10: Print the formatted text.
15592         + commit 0858f141a8b8d0c098a0c6097176b7225c4a9db8
15593         * g10/tofu.c (ask_about_binding): Print the formatted text, not the
15594         unformatted text.
15595
15596         g10: When showing a user id's trust, pass the current signature.
15597         + commit 8dda861ad80228da76cd5c97467008c87b8b6eee
15598         * g10/mainproc.c (check_sig_and_print): Consistently pass SIG to
15599         get_validity.
15600
15601 2016-08-29  Werner Koch  <wk@gnupg.org>
15602
15603         w32: Fix build regression due to 2aa0701.
15604         + commit 8b3e691ffbaaa218d309d5aaf8f37532308558ff
15605         * common/logging.c (fun_writer): Always declare 'name_for_err'.
15606
15607         gpgconf: Print the plain socket directory with --list-dirs.
15608         + commit 8e3fa5a4b205c534de2142e5d071712f957cf06a
15609         * tools/gpgconf.c (list_dirs): Add plain socketdir out.
15610
15611         common: Add a default socket name feature.
15612         + commit 2aa0701013f703ad93e17da3345c493c08aa04ee
15613         * common/logging.c (log_set_socket_dir_cb): New.
15614         (socket_dir_cb): New.
15615         (set_file_fd): Allow "socket://".
15616         (fun_writer): Implement default socket name.
15617         * common/init.c (_init_common_subsystems): Register default socket.
15618
15619         gpg: Make decryption of -R work w/o --try-secret-key or --default-key.
15620         + commit bdbd03608b6f508ac4732f9986a046de8a85a311
15621         * g10/getkey.c (enum_secret_keys): At state 3 enumerate the keys in all
15622         cases not just when --try-all-secrets is used.
15623
15624 2016-08-25  Werner Koch  <wk@gnupg.org>
15625
15626         gpg: Fix false negatives in Ed25519 signature verification.
15627         + commit 0a5a854510fda6e6990938a3fca424df868fe676
15628         * g10/pkglue.c (pk_verify): Fix Ed25519 signatrue values.
15629         * tests/openpgp/verify.scm (msg_ed25519_rshort): New
15630         (msg_ed25519_sshort): New.
15631         ("Checking that a valid Ed25519 signature is verified as such"): New.
15632
15633         common: Rename an odd named function.
15634         + commit 74a082bc10960b2d65d4d1e31152f988a40a2225
15635         * common/openpgp-oid.c (oid_crv25519): Rename to oid_cv25519.
15636         (openpgp_oid_is_crv25519): Rename to openpgp_oid_is_cv25519.  Change
15637         callers.
15638
15639         gpg: New option --with-tofu-info.
15640         + commit 19d12be3cea5b4ee8153287a2f2442913a5e07a1
15641         * g10/gpg.c (oWithTofuInfo): New.
15642         (opts): Add --with-tofu-info.
15643         (main): Set opt.with_tofu_info.
15644         * g10/options.h (struct opt): Add field WITH_TOFU_INFO.
15645         * g10/tofu.c (show_statistics): Add optional arg OUTFP and enter
15646         special mode if not NULL.  Change all callers.
15647         (tofu_write_tfs_record): New.
15648         * g10/keylist.c (list_keyblock_colon): Do not print the tofu policy as
15649         part of the "uid" record.  Print a new "tfs" record if the new option
15650         is set.
15651         * tests/openpgp/tofu.scm (getpolicy): Change from UID to TFS record.
15652
15653 2016-08-24  Werner Koch  <wk@gnupg.org>
15654
15655         gpg: Change TOFU_STATS to return timestamps.
15656         + commit 0f1f02acc1cdcc2cf74a97b05507bb1f062f8af2
15657         * g10/tofu.c (write_stats_status): Add arg FP to print a colon
15658         formated line.  Adjust for changed TOFU_STATS interface.
15659         (show_statistics): Let the query return timestamps and use
15660         gnupg_get-time to compute the "time ago" values.
15661
15662         common: Guarantee that gnupg_get_time does not return an error.
15663         + commit 5eb2682686b32bd82096924eeabd0c5bd347adfd
15664         * common/gettime.c (gnupg_get_time): Abor if time() failed.
15665         (gnupg_get_isotime): Remove now useless check.
15666         (make_timestamp): Remove check becuase we already checked this modulo
15667         the faked time thing.
15668
15669         wks: Add command --supported to gpg-wks-client.
15670         + commit 460568d341851ac79dd100e00e4eafcac1318148
15671         * tools/gpg-wks-client.c (aSupported): New.
15672         (opts): Add --supported.
15673         (parse_arguments): Ditto.
15674         (main): Call command_supported.
15675         (command_supported): New.
15676
15677 2016-08-22  Werner Koch  <wk@gnupg.org>
15678
15679         wks: Install gpg-wks-client under libexec.
15680         + commit c47386a11a32c5ed3b5a31fad5c3e9a9a020ca7b
15681         * tools/Makefile.am (bin_PROGRAMS): Move gpg-wks-client to ...
15682         (libexec_PROGRAMS): ...here.
15683
15684         common: Remove unused vars in simple-pwquery.
15685         + commit 62f3e0027724b23c0de5be6d1e66cfdeef7e7bc9
15686         * common/simple-pwquery.c (agent_send_option): Remove unused vars.
15687         (simple_query): Ditto.
15688         (agent_open): Ditto.  Return RC on error.
15689         (simple_pwquery): Remove unused vars.  Remove shadowing of 'p'.
15690
15691 2016-08-18  Werner Koch  <wk@gnupg.org>
15692
15693         Release 2.1.15.
15694         + commit 6bee88dd067e03e7767ceacf6a849d9ba38cc11d
15695
15696
15697         po: Update German translation.
15698         + commit 0a32153316855224acda268edb60b80d4e64b12f
15699
15700
15701 2016-08-18  Åka Sikrom  <a4@hush.com>
15702
15703         po: Update Norwegian translation.
15704         + commit ec88d7c8a9af864fad8ab5e0b9c4eb90ddcdd630
15705
15706
15707 2016-08-18  Ineiev  <ineiev@gnu.org>
15708
15709         po: Update Russian translation.
15710         + commit 6f6bfbf175653faa5cf560a7174e81a599247e80
15711
15712
15713 2016-08-18  Werner Koch  <wk@gnupg.org>
15714
15715         gpg: Add import filter "drop-sig".
15716         + commit 1b55e864421f88b8c8088639682767076abbeab0
15717         * g10/import.c (import_drop_sig): New variable.
15718         (cleanup_import_globals): Release that.
15719         (parse_and_set_import_filter): Add filter "drop-sig".
15720         (filter_getval): Implement properties for drop-sig.
15721         (apply_drop_sig_filter): New.
15722         (import_one): Apply that filter.
15723
15724         dirmngr: Remove all system daemon features.
15725         + commit d83ba4897bf217d1045c58d1b99e52bd31c58812
15726         * dirmngr/dirmngr.h (opts): Remove fields 'system_service' and
15727         'system_daemon'.
15728         * common/homedir.c (dirmngr_sys_socket_name): Remove.
15729         (dirmngr_user_socket_name): Rename to ...
15730         (dirmngr_socket_name): this.  Change call callers.
15731         * common/asshelp.c (start_new_dirmngr): Remove the system socket
15732         feature.
15733         * tools/gpgconf.c (list_dirs): Do not print "dirmngr-sys-socket".
15734         * sm/server.c (gpgsm_server): Adjust for removed system socket feature.
15735         * dirmngr/server.c (cmd_getinfo): Ditto.
15736         (cmd_killdirmngr): Remove check for system daemon.
15737         (cmd_reloaddirmngr): Ditto.
15738         * dirmngr/dirmngr.c (USE_W32_SERVICE): Remove macro.
15739         (aService): Remove.
15740         (opts): Remove --service.
15741         (w32_service_control): Remove.
15742         (real_main, call_real_main) [W32]: Remove wrapper.
15743         (main): Remove Windows system service feature.  Remove system dameon
15744         feature.  Use only the "~/.gnupg/dirmngr_ldapservers.conf" file.
15745         * dirmngr/certcache.c (load_certs_from_dir): Remove warning in the
15746         system dameon case.
15747         * dirmngr/crlcache.c (DBDIR_D): Always use "~/.gnupg/crls.d".
15748         * dirmngr/ocsp.c (validate_responder_cert): Do not call
15749         validate_cert_chain which was used only in system daemon mode.
15750         * dirmngr/validate.c (validate_cert_chain): Always use the code.
15751
15752         gpg: New option --sender.
15753         + commit de6e3217cde81df370926571e0fd65e468619803
15754         * g10/options.h (struct opt): Add field 'sender_list'.
15755         * g10/gpg.c: Include mbox-util.h.
15756         (oSender): New.
15757         (opts): Add option "--sender".
15758         (main): Parse option.
15759
15760 2016-08-16  Werner Koch  <wk@gnupg.org>
15761
15762         agent: Allow import of overly large keys.
15763         + commit b5d63e81d5c472647decc7687cef91fee0378eb8
15764         * agent/command.c (MAXLEN_KEYDATA): Double the size.
15765
15766 2016-08-14  Werner Koch  <wk@gnupg.org>
15767
15768         g13: Allow the use of a g13tab label for --mount.
15769         + commit f02ceb6c6e94c6fbfaeeafe728397be38107de4d
15770         * g13/mount.c (g13_mount_container): Do not run the first access check
15771         if syshelp is required.
15772
15773         g13: Implement --umount for dm-crypt.
15774         + commit b781113cf1391926dedf8dc943624d3bb9726318
15775         * g13/g13.c (main): Implement command --umount.
15776         * g13/mount.c (g13_umount_container): use the syshelper if needed.
15777         * g13/backend.c (be_umount_container): New.
15778         * g13/be-dmcrypt.c (be_dmcrypt_umount_container): New.
15779         * g13/call-syshelp.c (call_syshelp_run_umount): New.
15780         * g13/sh-cmd.c (cmd_umount): New.
15781         (register_commands): Register UMOUNT.
15782         * g13/sh-dmcrypt.c (sh_dmcrypt_umount_container): New.
15783
15784 2016-08-13  Werner Koch  <wk@gnupg.org>
15785
15786         g13: Fix double free bug.
15787         + commit c9a0bccc77c93c08d6980a1718dfaf238a559eb9
15788         * g13/sh-cmd.c (cmd_mount, cmd_resume): Do not xfree TIUPLES.
15789
15790         g13: Consider g13tab for a mount command.
15791         + commit 700920640211168ae1c97d0adef74ba8615d90bb
15792         * g13/sh-cmd.c (cmd_getkeyblob): New.
15793         (register_commands): Register it.
15794         * g13/call-syshelp.c (getkeyblob_data_cb): New.
15795         (call_syshelp_get_keyblob): New.
15796         * g13/mount.c: Include callsyshelp.h.
15797         (g13_mount_container): Ask syshelp whether the filename is managed by
15798         g13tab.  Call syshelp to get the encrypted keyblob in this case.
15799
15800         g13: Move some function around.
15801         + commit 37e932658cbd873ac96ff7e2067a97dffc2e0507
15802         * g13/keyblob.c (g13_keyblob_decrypt): Move to ...
15803         * g13/server.c: to here.
15804         * g13/suspend.c, g13/mount.c: Include server.h.
15805         * g13/Makefile.am (g13_syshelp_SOURCES): Add keyblob.c
15806
15807         g13: New command --find-device.
15808         + commit b57f55321295846d47144bd6b39fbbcac0127421
15809         * common/status.h (STATUS_BLOCKDEV: New.
15810         * g13/call-syshelp.c: Include "call-syshelp.h".
15811         (finddevice_status_cb, call_syshelp_find_device): New.
15812         * g13/g13.c (aFindDevice): New.
15813         (opts): Add "--find-device".
15814         (main): Implement --find-device.
15815         * g13/sh-cmd.c (cmd_finddevice): New.
15816         (register_commands): Register new command.
15817
15818 2016-08-12  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
15819
15820         Avoid leading ": " in the log output when there are no prefixes.
15821         + commit 3a75ff65fba24ea2d024bd8fef633ab7d8f7d520
15822         * common/logging.c (do_logv): When no prefixes have been requested,
15823         omit the ": " separator, since there is nothing on the left-hand
15824         side of it.
15825
15826         Call log_set_prefix() with human-readable labels.
15827         + commit 61c2a1fa6d6cb345f9d81f4bdd3f8f8ddac1ea3e
15828         * agent/preset-passphrase.c, agent/protect-tool.c, dirmngr/dirmngr.c
15829         * dirmngr/t-http.c, g10/gpg.c, g10/gpgv.c, g13/g13-syshelp.c
15830         * g13/g13.c, kbx/kbxutil.c, scd/scdaemon.c, sm/gpgsm.c
15831         * tests/gpgscm/main.c, tools/gpg-check-pattern.c
15832         * tools/gpg-connect-agent.c, tools/gpgconf.c, tools/gpgtar.c
15833         * tools/symcryptrun.c: Invoke log_set_prefix() with
15834         human-readable labels.
15835
15836 2016-08-11  Werner Koch  <wk@gnupg.org>
15837
15838         gpg: New option --input-size-hint.
15839         + commit 70b5d7c43a57a44dad60c2c700a263610748d8f4
15840         * g10/options.h: Include stdint.h.
15841         (struct opt): Add field 'input_size_hint'.
15842         * g10/gpg.c (oInputSizeHint): New.
15843         (opts): Add --input-size-hint.
15844         (main): Set opt.input_size_hint.
15845         * g10/progress.c (write_status_progress): Use the hint.
15846
15847         common: New function string_to_u64.
15848         + commit 0698324cde3e0cef7eeb6cfd1640c5eefdf13698
15849         * common/stringhelp.c (string_to_u64): New.
15850         * dirmngr/http.c (longcounter_t): Remove.
15851         (struct cookie_s): Change content_length to uint64_t.
15852         (parse_response): Use string_to_u64.
15853
15854 2016-08-11  Justus Winter  <justus@g10code.com>
15855
15856         common: Remove compatibility code.
15857         + commit 72fa314b71e4ce8780f59b16d32cabf5d4bd5451
15858         * common/Makefile.am: Drop deleted files.
15859         * common/w32-afunix.c: Delete file.
15860         * common/w32-afunix.h: Likewise.
15861
15862         common: Rework the simple password query module.
15863         + commit 14479e2515439c73e385f37e8c2b3fc517b038b9
15864         * common/simple-pwquery.c (writen, readline): Drop.
15865         (agent_send_option, agent_send_all_options, agent_open): Just use
15866         libassuan.
15867         (simple_pw_set_socket): Simplify.
15868         (default_inq_cb): New function.
15869         (simple_pwquery, simple_query): Just use libassuan.
15870         * agent/Makefile.am (gpg_preset_passphrase_LDADD): Add libassuan.
15871         * tools/Makefile.am (symcryptrun_LDADD): Likewise.
15872
15873         common: Remove simple password query error codes.
15874         + commit 9e6503b7ce019aa417099ded1dda87b68c33f912
15875         * common/simple-pwquery.h: Remove mapping function.  Move all
15876         definitions of status codes...
15877         * common/simple-pwquery.c: ... here, and define them to meaningful gpg
15878         error values.
15879         * agent/preset-passphrase.c (preset_passphrase): Use error code as-is.
15880         (forget_passphrase): Likewise.
15881         * tools/symcryptrun.c (confucius_get_pass): Likewise.
15882
15883 2016-08-10  Werner Koch  <wk@gnupg.org>
15884
15885         gpg: Print the signer's UID during verification.
15886         + commit ed5c1b0b8a4790c4fb36a3129387f7c2ef5db302
15887         * g10/parse-packet.c (parse_signature): Sanitize the value stored in
15888         SIGNERS_UID.
15889         * g10/mainproc.c (issuer_fpr_string): New.
15890         (check_sig_and_print): Print the signers' UID.  Print the issuer
15891         fingerprint in --rfc4880bis mode.
15892
15893         common: New function try_make_printable_string.
15894         + commit f2ea7e539c9a22081e3159dcbca84f57f30724ca
15895         * common/stringhelp.c (sanitize_buffer): Remove.  Move code to ...
15896         * common/miscellaneous.c (try_make_printable_string): new.
15897         (make_printable_string): Call try_make_printable_string.
15898
15899 2016-08-10  Justus Winter  <justus@g10code.com>
15900
15901         tests: Fix distcheck.
15902         + commit a6acf1f6b39c5a607f61f643a5d21309ba58685d
15903         * tests/openpgp/issue2417.scm: Copy configuration.
15904
15905 2016-08-10  Werner Koch  <wk@gnupg.org>
15906
15907         gpg: Remove tofu database format "split".
15908         + commit 5b59999ce0dd1650ebe47a74a30ded6af00eeed3
15909         * g10/options.h (struct opt): Remove field tofu_db_format.
15910         * g10/gpg.h (server_control_s): Add fields tofu.batch_update_ref and
15911         tofu.batch_update_started.
15912         * g10/gpg.c (parse_tofu_db_format): Remove.
15913         (main): Make option --tofu-db-format obsolete.
15914         * g10/tofu.c: Major rework.  Remove the pretty complicated and slower
15915         split format and with that all the caching.  Use the dbs struct
15916         directly.  Move global vars for batch update into CTRL.  Change
15917         calling conventions of some function to take CTRL or DBS pointers
15918         instead of  the former low-level database pointer.
15919
15920 2016-08-10  Justus Winter  <justus@g10code.com>
15921
15922         g10: Fix opening of trust database.
15923         + commit a27410a251cd25ca96cd6743969c4db0a0fd553f
15924         * g10/tdbio.c (tdbio_set_dbname): This function explicitly checks for
15925         the file size, but handled the case of a zero-sized file incorrectly
15926         by returning success.  Fix this by initializing the database in that
15927         case.
15928         * tests/openpgp/Makefile.am (XTESTS): Add new test.
15929         * tests/openpgp/issue2417.scm: New file.
15930
15931         tests: Fix distcheck.
15932         + commit 194b1e979c7c547afd0dfea5b2496bdfa34b20f1
15933         * tests/openpgp/Makefile.am (EXTRA_DIST): Explicitly add setup and
15934         teardown scripts now that they no longer are included in the list of
15935         tests.
15936
15937         tests: Improve temporary directory handling.
15938         + commit d9240a3a4688c263632b4168ae2e04363bc91a3a
15939         * tests/gpgscm/ffi.c (ffi_init): Rename 'mkdtemp'.
15940         * tests/gpgscm/tests.scm (mkdtemp): New function that uses a sensible
15941         location and template if no arguments are given.
15942         (with-temporary-working-directory): Simplify accordingly.
15943         (make-temporary-file): Likewise.
15944         * tests/openpgp/run-tests.scm (run-tests-parallel-isolated): Likewise.
15945         (run-tests-sequential-isolated): Likewise.
15946
15947         gpgscm: Make the name of foreign functions more unique.
15948         + commit efe973dab7f69e2b1309446b2fbcd47ce0305399
15949         * tests/gpgscm/ffi-private.h (ffi_define_function_name): Add another
15950         underscore.
15951
15952         tests: Run each test in a clean environment.
15953         + commit e13f1ea8fff3964dc3008432f5c0f26aaa2eaa35
15954         * tests/openpgp/Makefile.am (TESTS_ENVIRONMENT): Drop obsolete
15955         variables, add 'srcdir', use absolute paths.
15956         (TESTS): Rename to 'XTESTS' to avoid emitting the automake test
15957         runner.  Drop 'setup.scm' and 'finish.scm'.
15958         (xcheck): New target that runs 'run-tests.scm', our Scheme test suite
15959         runner.  It will run each test in a clean environment, isolated from
15960         the other tests.
15961         (EXTRA_DIST): Adapt accordingly.
15962         * tests/openpgp/README: Likewise.
15963
15964         tests: Make ssh test more robust.
15965         + commit b2b21580b68f3a9069562f99675b389a0d044713
15966         * tests/openpgp/ssh.scm: Drop the 'MD5:' which was not printed by
15967         previous ssh versions.
15968
15969 2016-08-10  NIIBE Yutaka  <gniibe@fsij.org>
15970
15971         agent: SSH support fix.
15972         + commit f14795d57f6c81709e9225dd3c5dfd3495cf1b2b
15973         * agent/command-ssh.c (ssh_handler_request_identities): Keep error
15974         message same.
15975
15976 2016-08-09  Werner Koch  <wk@gnupg.org>
15977
15978         agent: Fix regression in recent ssh changes.
15979         + commit e630f904993725c54ec63be00369589b7b7234d2
15980         * agent/command-ssh.c (sexp_key_construct): Lowercase the algo name.
15981
15982         gpg: Extend the PROGRESS line to give the used unit.
15983         + commit 16feb1e0ea9b5d3966f22f4ae047335b9d1b60e1
15984         * g10/progress.c (write_status_progress): Print the units parameter.
15985
15986 2016-08-09  Ben Kibbey  <bjk@luxsci.net>
15987
15988         Cleanup initialization of libgcrypt.
15989         + commit 49829c29e541546084950b8a153067db371d101a
15990         * common/init.c (init_common_subsystems): Initialize libgcrypt.
15991         * dirmngr/Makefile.am (dirmngr_ldap): Link with libgcrypt.
15992
15993 2016-08-09  NIIBE Yutaka  <gniibe@fsij.org>
15994
15995         agent: SSH support improvement.
15996         + commit ebf24e3b29766595204355d82f435a3e675bfbbc
15997         * agent/command-ssh.c (ssh_handler_request_identities): Skip a key with
15998         error, not giving up to handle the request itself.
15999         * agent/cvt-openpgp.c (extract_private_key): Support "ecdsa" key.
16000
16001 2016-08-08  Werner Koch  <wk@gnupg.org>
16002
16003         gpg: Cleanup of dek_to_passphrase function (part 2).
16004         + commit 491d6fdabb3d95905cd96d905e1f965ce8ff07e1
16005         * g10/passphrase.c (passphrase_get): Remove arg KEYID.  Change arg
16006         MODE to NOCACHE.
16007         (passphrase_to_dek): Remove args KEYID and PUBKEY_ALGO.  Split arg
16008         MODE into CREATE and NOCACHE.  Change all callers and adjust stubs.
16009         (passphrase_clear_cache): Remove args KEYID and ALGO.  They are not
16010         used.  Change caller.
16011
16012         gpg: Cleanup of dek_to_passphrase function (part 1).
16013         + commit 5b614973fe2d4b5ef402a3057c31c3ef3042a483
16014         * g10/passphrase.c (passphrase_to_dek_ext): Remove args CUSTDESC and
16015         CUSTPROMPT.  Merge into the passphrase_to_dek wrapper.
16016         (passphrase_get): Remove args CUSTOM_DESCRIPTION and CUSTOM_PROMPT.
16017
16018 2016-08-08  NIIBE Yutaka  <gniibe@fsij.org>
16019
16020         agent: More clean up of SSH support.
16021         + commit 591a8373a5d9567db9b1a1a48205e8a206c7b669
16022         * common/util.h (get_pk_algo_from_key): New.
16023         * common/sexputil.c (get_pk_algo_from_key): The implementation.
16024         * agent/gpg-agent.c: Remove include of openpgpdefs.h.
16025         * agent/command-ssh.c (struct ssh_key_type_spec): Use integer ALGO.
16026         (ssh_key_types): Update with GCRY_PK_*.
16027         (make_cstring, sexp_extract_identifier): Remove.
16028         (sexp_key_construct): Use gcry_pk_algo_name to get ALGO string.
16029         (ssh_key_to_blob): Use cadr to get value list.
16030         (ssh_key_type_lookup): Lookup with integer ALGO.
16031         (ssh_receive_key): Follow the change of ssh_key_type_lookup.
16032         (ssh_send_key_public): Likewise.  Use get_pk_algo_from_key to get ALGO.
16033
16034         tests: Add openpgp/gpgv-forged-keyring.scm.
16035         + commit 7dcad0d3503ac0d75e09efb16246dd78518986fc
16036         * tests/openpgp/gpgv-forged-keyring.scm: New.
16037         * tests/openpgp/forged-keyring.gpg: New.
16038         * tests/openpgp/Makefile.am (TESTS): Add gpgv-forged-keyring.scm.
16039         * tests/openpgp/defs.scm (tools): Add GPGV.
16040         (GPGV): New.
16041
16042 2016-08-06  Werner Koch  <wk@gnupg.org>
16043
16044         agent: Fix long standing regression tracking the connection count.
16045         + commit 40d16029ed8b334c371fa7f24ac762d47302826e
16046         * agent/gpg-agent.c (get_agent_active_connection_count): New.
16047         (do_start_connection_thread, start_connection_thread_ssh): Bump
16048         ACTIVE_CONNECTIONS up and down.
16049         * agent/command.c (cmd_getinfo): Add subcommand "connections".
16050
16051 2016-08-06  NIIBE Yutaka  <gniibe@fsij.org>
16052
16053         agent: Clean up SSH support.
16054         + commit 894789c3299dc47a8c1ccaaa7070382f0fae0262
16055         * agent/command-ssh.c (file_to_buffer): Remove.
16056         (ssh_handler_request_identities): Use agent_public_key_from_file.
16057
16058 2016-08-05  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
16059
16060         gpg: Avoid publishing the GnuPG version by default.
16061         + commit c9387e41db7520d176edd3d6613b85875bdeb32c
16062         * g10/gpg.c (main): initialize opt.emit_version to 0
16063         * doc/gpg.texi: document different default for --emit-version
16064
16065 2016-08-04  Werner Koch  <wk@gnupg.org>
16066
16067         gpg: Make sure that keygrips are printed for each subkey.
16068         + commit c8cc804f56bfefba46641f2c7078fcd67b494bae
16069         * g10/keylist.c (list_keyblock_colon): Print an emprty grip in case of
16070         an error.
16071
16072         gpg: Always print the fingerprint in colons mode.
16073         + commit 54a1ed20e203dcafeacbe21eb147efa08255dbf5
16074         * g10/keylist.c (list_keyblock_colon): Remove arg FPR.  Always print
16075         fingerprint records.  For secret keys always print keygrip records.
16076
16077         tests: Use gpgconf to set the ssh socket envvar.
16078         + commit 0c2a745a2bc21e8f439930f7c0e5d1521c2fd44c
16079         * tests/openpgp/ssh.scm ("SSH_AUTH_SOCK"): Use gpgconf.
16080
16081         gpgconf: Add limited support for -0.
16082         + commit db6f3eb926619dfe6ed2a9be197c51f9a1b6198c
16083         * tools/gpgconf.h (opt): Add field 'null'.
16084         * tools/gpgconf.c: Add option --null/-0.
16085         (list_dirs): Use it here.
16086
16087 2016-08-04  Justus Winter  <justus@g10code.com>
16088
16089         tests: Update list of tests in Scheme test runner.
16090         + commit 05cb30052cdf1d308ff7da901cfa5a809cd49479
16091         * tests/openpgp/run-tests.scm: Add missing tests.
16092
16093         tests: Fix path to fake-pinentry.
16094         + commit 3566544d04a4b81e5dd8a2883304673b2cc2f108
16095         * tests/openpgp/defs.scm: Correctly compute the path to fake-pinentry.
16096
16097 2016-08-04  NIIBE Yutaka  <gniibe@fsij.org>
16098
16099         po: Update Japanese translation.
16100         + commit 89234f7f3643bad2daddc94569f1d651ec5c835e
16101
16102
16103         po: update Japanese translation.
16104         + commit 573e0f36190346e0263bea3ae12a389f4f598d55
16105
16106
16107         g10: Fix checking key for signature validation.
16108         + commit 6f284e6ed63f514b15fe610f490ffcefc87a2164
16109         * g10/sig-check.c (check_signature2): Not only subkey, but also primary
16110         key should have flags.valid=1.
16111
16112 2016-08-03  Justus Winter  <justus@g10code.com>
16113
16114         kbx: Add missing header file.
16115         + commit e3358b246d9380008a4ba7c8f2fe03659901adaf
16116         * kbx/keybox-update.c: Add missing header file.
16117
16118 2016-08-03  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
16119
16120         More cleanup of "allow to".
16121         + commit dc107b78509807db375d3a382eb3376cd2183357
16122         * README, agent/command.c, agent/keyformat.txt, common/i18n.c,
16123           common/iobuf.c, common/keyserver.h, dirmngr/cdblib.c,
16124           dirmngr/ldap-wrapper.c, doc/DETAILS, doc/TRANSLATE,
16125           doc/announce-2.1.txt, doc/gpg.texi, doc/gpgsm.texi,
16126           doc/scdaemon.texi, doc/tools.texi, doc/whats-new-in-2.1.txt,
16127           g10/export.c, g10/getkey.c, g10/import.c, g10/keyedit.c, m4/ksba.m4,
16128           m4/libgcrypt.m4, m4/ntbtls.m4, po/ca.po, po/cs.po, po/da.po,
16129           po/de.po, po/el.po, po/eo.po, po/es.po, po/et.po, po/fi.po,
16130           po/fr.po, po/gl.po, po/hu.po, po/id.po, po/it.po, po/ja.po,
16131           po/nb.po, po/pl.po, po/pt.po, po/ro.po, po/ru.po, po/sk.po,
16132           po/sv.po, po/tr.po, po/uk.po, po/zh_CN.po, po/zh_TW.po,
16133           scd/app-p15.c, scd/ccid-driver.c, scd/command.c, sm/gpgsm.c,
16134           sm/sign.c, tools/gpgconf-comp.c, tools/gpgtar.h: replace "Allow to"
16135           with clearer text.
16136
16137         In standard English, the normal construction is "${XXX} allows ${YYY}
16138         to" -- that is, the subject (${XXX}) of the sentence is allowing the
16139         object (${YYY}) to do something.  When the object is missing, the
16140         phrasing sounds awkward, even if the object is implied by context.
16141         There's almost always a better construction that isn't as awkward.
16142
16143         These changes should make the language a bit clearer.
16144
16145         dirmngr: Emit correct spelling of "superseded".
16146         + commit 436b28c23194fa77919967338d5a61a82d242153
16147         * dirmngr/crlcache.c (list_one_crl_entry): Spell superseded correctly.
16148         * dirmngr/ocsp.c (ocsp_invalid): Likewise.
16149
16150         This might break some tools which parse the existing output and expect
16151         misspellings, but i'm not sure there are many such tools, and we
16152         should use standardized orthography going forward.
16153
16154         Fix spelling and grammar.
16155         + commit cd45cf782b91ff0f6b023913963e5258ffcbf464
16156         * agent/learncard.c: s/coccured/occurred/
16157         * doc/dirmngr.texi: s/ommitted/omitted/, s/orginally/originally/,
16158           s/reponses/responses/i
16159         * doc/gpg-agent.texi, doc/dirmngr.texi, doc/gpg.texi: Fix "allows
16160           to" to more conventional english usage.
16161         * doc/tools.texi, g10/gpgcommpose.c, tests/openpgp/armor.scm,
16162           tests/openpgp/armor.test: s/occured/occurred/
16163         * tools/gpgsplit.c: s/calcualting/calculating/
16164         * sm/server.c: s/formated/formatted/
16165
16166 2016-08-03  Werner Koch  <wk@gnupg.org>
16167
16168         gpg,gpgsm: Block signals during keyring/keybox update.
16169         + commit 48a2c93a1886589d1a0e2a4a2173e0e81311200b
16170         * kbx/keybox-util.c (keybox_file_rename): Add arg BLOCK_SIGNALS.
16171         * kbx/keybox-update.c (rename_tmp_file): Block all signals when doing
16172         a double rename.
16173         * g10/keyring.c (rename_tmp_file): Block all signals during the double
16174         rename.
16175
16176         common: New file utilproto.c.
16177         + commit 3a2421c94015432caa49e166bc5bf5c4f80ab7c7
16178         * common/util.h: Factor prototypes from signal.c out to ...
16179         * common/utilproto.h: new.
16180         * common/Makefile.am (common_sources): Add new file.
16181
16182 2016-08-01  Justus Winter  <justus@g10code.com>
16183
16184         gpgsm: Fix machine-readable key listing.
16185         + commit 40365b28c3fdf087fd58401f5a6f42f9d7d29d20
16186         * sm/keylist.c (list_cert_colon): Drop superfluous colon.
16187
16188         tests: Distribute standalone test runner.
16189         + commit c971ff0823d9a649b32fd9f169a12abc3095246e
16190         * tests/openpgp/Makefile.am (EXTRA_DIST): Add missing file
16191         'run-tests.scm'.
16192
16193 2016-07-28  Justus Winter  <justus@g10code.com>
16194
16195         tests: Fix distcheck.
16196         + commit 9e799b0e4f131126b80a5d3272c36d52b8ba1720
16197         * tests/openpgp/Makefile.am (sample_msgs): New variable.
16198         (EXTRA_DIST): Also ship the sample msgs.
16199
16200 2016-07-27  Fredrik Fornwall  <fredrik@fornwall.net>
16201
16202         build: Fix check for Android.
16203         + commit 583a464c62ce8f7d70f5fdab2c7ea73ec3348d69
16204         * configure.ac: Match other Android targets as well.
16205
16206 2016-07-26  Justus Winter  <justus@g10code.com>
16207
16208         common: Fix iobuf_peek corner case.
16209         + commit b2572b0c386fd12ac6581fcce72f8d48cbfd27c7
16210         Previously, iobuf_peek on a file smaller than 'buflen' would hang.
16211
16212         * common/iobuf.c (underflow): Generalize by adding a target parameter.
16213         (iobuf_peek): Use this to prevent looping here.
16214         * tests/openpgp/Makefile.am (TESTS): Add new test.
16215         * tests/openpgp/setup.scm (dearmor): Move function...
16216         * tests/openpgp/defs.scm (dearmor): ... here.
16217         * tests/openpgp/issue2419.scm: New file.
16218         * tests/openpgp/samplemsgs/issue2419.asc: Likewise.
16219
16220         gpgscm: Do not shadow common function name in catch macro.
16221         + commit 046338b8494c036a5e717130d3eadce0291126fc
16222         * tests/gpgscm/init.scm (catch): Do not shadow 'exit'.
16223
16224         tests: Fix distcheck.
16225         + commit 66c0dab3c722c2766828515120775b106286334e
16226         * tests/openpgp/Makefile.am (samplekeys): Add missing key.
16227
16228         gpgscm: Make the verbose setting more useful.
16229         + commit f17aecbcd98103fcd2ece537be96930f354de656
16230         * tests/gpgscm/ffi.c (do_get_verbose): New function.
16231         (do_set_verbose): Likewise.
16232         (ffi_init): Turn *verbose* into a function, add *set-verbose!*.
16233         * tests/gpgscm/tests.scm (call): Adapt accordingly.
16234         (call-with-io): Dump output if *verbose* is high.
16235         (pipe-do): Adapt accordingly.
16236         * tests/openpgp/defs.scm: Set verbosity according to environment.
16237         * tests/openpgp/run-tests.scm (test): Adapt accordingly.
16238
16239         common: Avoid excessive stack use.
16240         + commit b3610badf691178bbbf0831af9aa6b6658c1948a
16241         * common/exectool.c (copy_buffer_shred): Make passing NULL a nop.
16242         (gnupg_exec_tool_stream): Allocate copy buffers from the heap.
16243
16244         common: Rework resource cleanup when handling errors.
16245         + commit 35132a8b119dbc3393ceb0d0874917905d1a6354
16246         * common/exectool.c (gnupg_exec_tool_stream): Rework error handling.
16247
16248         common: Add unit test for exectool.
16249         + commit fe40e9c53dc0710ff73e72d05ba8040874465b55
16250         * common/Makefile.am: Build new test.
16251         * common/t-exectool.c: New file.
16252
16253 2016-07-25  Justus Winter  <justus@g10code.com>
16254
16255         g10: Fix key import statistics.
16256         + commit 4ba11251aff578394000bf480f47160f0879c763
16257         'transfer_secret_keys' collects statistics on a subkey-basis, while
16258         the other code does not.  This leads to inflated numbers when
16259         importing secret keys.  E.g. 'count' is incremented by the main
16260         parsing loop in 'import', and again in 'transfer_secret_keys', leading
16261         to a total of 3 if one key with two secret subkeys is imported.
16262
16263         * g10/import.c (import_secret_one): Adjust to the fact that
16264         'transfer_secret_keys' collects subkey statistics.
16265         * tests/openpgp/Makefile.am (TESTS): Add new test.
16266         * tests/openpgp/issue2346.scm: New file.
16267         * tests/openpgp/samplekeys/issue2346.gpg: Likewise.
16268
16269 2016-07-22  Justus Winter  <justus@g10code.com>
16270
16271         gpgscm: Make function more general.
16272         + commit 9ee23a715d5dad6bf568a2deb1c55bf15601cf51
16273         * tests/gpgscm/tests.scm (in-srcdir): Accept more path fragments.
16274
16275         g10: Properly ignore legacy keys in the keyring cache.
16276         + commit d9839c9d303a01dc1032a6de311e034fe14e81da
16277         * g10/keyring.c (keyring_rebuild_cache): Properly ignore legacy keys
16278         in the keyring cache.
16279         * tests/migrations/Makefile.am (TESTS): Add new test.
16280         * tests/migrations/common.scm (GPG-no-batch): New variable.
16281         (run-test): New function.
16282         * tests/migrations/issue2276.scm: New file.
16283         * tests/migrations/issue2276.tar.asc: Likewise.
16284
16285 2016-07-21  Justus Winter  <justus@g10code.com>
16286
16287         g10: Fix error handling.
16288         + commit 45bb9a2a46e11bc13c6b39e7b4748b7de199018e
16289         * g10/tofu.c (show_statistics): Fix error handling, 0 is a valid
16290         duration.
16291
16292         g10: Drop superfluous begin transaction.
16293         + commit 8a6f8e1e397a2d676b211f2dbc6df4a80b67442d
16294         * g10/tofu.c (record_binding): We only need a transaction for the
16295         split format.
16296
16297         gpgscm: Make assert macro more accurate.
16298         + commit 699c6c9f4b44441ab3db7f942df5b81f4cd88b06
16299         * tests/gpgscm/lib.scm (assert): Print the representation of the
16300         failed expression.
16301
16302         gpgscm: Make error message more useful.
16303         + commit 7207b2fe45bcf884e029366a2677a570234bed2e
16304         * tests/gpgscm/scheme.c (opexe_0): Include names of missing function
16305         parameters in the error message.
16306
16307         g10: Fix crash.
16308         + commit 1af2fd44f0a66fd0d94c224319db0b128d42a288
16309         * g10/tofu.c (tofu_closedbs): Fix freeing database handles up to the
16310         cache limit.  Previously, this would crash if db_cache_count == count.
16311
16312 2016-07-20  NIIBE Yutaka  <gniibe@fsij.org>
16313
16314         scd: Fix card removal/reset on multiple contexts.
16315         + commit 1598a4476466822e7e9c757ac471089d3db4b545
16316         * scd/app.c (application_notify_card_reset): Add message for debug.
16317         *scd/command.c (update_card_removed): Call release_application and set
16318         SLOT -1 here.
16319         (struct server_local_s): Remove app_ctx_marked_for_release.
16320         (do_reset): Don't mark release but call release_application here.
16321         (open_card): Remove app_ctx_marked_for_release handling.
16322         (update_reader_status_file): Don't set SLOT here, so that it can be
16323         released the APP by application_notify_card_reset in
16324         update_card_removed.
16325
16326 2016-07-19  Justus Winter  <justus@g10code.com>
16327
16328         agent: Add known keys to sshcontrol.
16329         + commit 270f7f7b8b235cc93516566702e2a1d256605cca
16330         * agent/command-ssh.c (ssh_identity_register): Add a key to sshcontrol
16331         even if it is already in the private key store.
16332         * tests/openpgp/ssh.scm: Test this.
16333
16334         tests: Add test for ssh support.
16335         + commit d7a405de8325aa945ab791dcd3bc48272af33b86
16336         * tests/gpgscm/tests.scm (path-expand): New function.
16337         * tests/openpgp/Makefile.am (TESTS): Add new test.
16338         (sample_keys): Add new keys.
16339         (CLEANFILES): Clean ssh socket and control file.
16340         * tests/openpgp/fake-pinentry.c (main): Add a default passphrase.
16341         * tests/openpgp/gpg-agent.conf.tmpl: Enable ssh support.
16342         * tests/openpgp/samplekeys/ssh-dsa.key: New file.
16343         * tests/openpgp/samplekeys/ssh-ecdsa.key: Likewise.
16344         * tests/openpgp/samplekeys/ssh-ed25519.key: Likewise.
16345         * tests/openpgp/samplekeys/ssh-rsa.key: Likewise.
16346         * tests/openpgp/ssh.scm: Likewise.
16347
16348 2016-07-19  NIIBE Yutaka  <gniibe@fsij.org>
16349
16350         scd: Fix race conditions for release_application.
16351         + commit 0c1fd4e9884ed7c1edd1819762b9e8a77f606ed3
16352         * scd/command.c (do_reset, cmd_restart): Reset app_ctx before calling
16353         release_application.
16354
16355 2016-07-18  Justus Winter  <justus@g10code.com>
16356
16357         agent: Fix passphrase cache lookups.
16358         + commit f474249366e8e143c8e6eb7f7b1a74056e46fa1f
16359         CACHE_MODE_ANY is supposed to match any cache mode except
16360         CACHE_MODE_IGNORE, but the code used '==' to compare cache modes.
16361
16362         * agent/cache.c (cache_mode_equal): New function.
16363         (agent_set_cache): Use the new function to compare cache modes.
16364         (agent_get_cache): Likewise.
16365         * tests/openpgp/Makefile.am (TESTS): Add new test.
16366         * tests/openpgp/issue2015.scm: New file.
16367
16368 2016-07-15  Justus Winter  <justus@g10code.com>
16369
16370         build: Always build gpgtar.
16371         + commit 7f4dd24b880323a5b772719dafae829c288303a8
16372         We use gpgtar to unpack test data, hence we always build it.  If the
16373         user opts out, we simply don't install it.
16374
16375         * configure.ac: Add comment.
16376         * tests/migrations/Makefile.am (required_pgms): Make sure gpgtar is
16377         built.
16378         * tools/Makefile.am: Always build gpgtar, but do not install it if the
16379         user used '--disable-gpgtar'.
16380
16381 2016-07-15  Werner Koch  <wk@gnupg.org>
16382
16383         wks: Publish as binary file.
16384         + commit b7b37716b9d2cd1b71b5f7f0e4fb2c1a43eee90a
16385         * tools/gpg-wks-server.c (copy_key_as_binary): New.
16386         (check_and_publish): Use new function instead of rename.
16387
16388 2016-07-15  Justus Winter  <justus@g10code.com>
16389
16390         gpgscm: Fix linking.
16391         + commit c49c43d7e4229fd9f1bc55e17fa32fdc334dbef6
16392         * tests/gpgscm/Makefile.am: Add -lintl.
16393
16394         g10: Fix building without trust models.
16395         + commit d21efa398874be4a15e8283c5fc382fb90f562fd
16396         * g10/pkclist.c (write_trust_status): Fall back to the previous
16397         behavior.
16398
16399         tests: Check for gpgtar.
16400         + commit 12a887050a560c4cacaf95e4cdb0cc42d8b87aa1
16401         * tests/migrations/extended-pkf.scm: Skip test if gpgtar is not built.
16402         * tests/migrations/from-classic.scm: Likewise.
16403         * tests/openpgp/gpgtar.scm: Fix check for gpgtar.
16404
16405 2016-07-14  Werner Koch  <wk@gnupg.org>
16406
16407         Release 2.1.14.
16408         + commit 09c448202ffb4c26d7ec2028351a78e2d3680396
16409
16410
16411         po: Update the German translation.
16412         + commit 23c2491f94b94fa231bde8187eb958432555eff1
16413
16414
16415 2016-07-14  Damien Goutte-Gattat  <dgouttegattat@incenp.org>
16416
16417         dirmngr: fix handling of HTTP redirections.
16418         + commit 60428c24fb29cb633c9392abb777bc4da88dbfba
16419         * dirmngr/ks-engine-http.c (ks_http_fetch): Reinitialize HTTP session
16420         when following a HTTP redirection.
16421
16422 2016-07-14  Werner Koch  <wk@gnupg.org>
16423
16424         gpg: Remove options --print-dane-records and --print-pka-records.
16425         + commit 1e9bc66a9a60de668890452d504eea3c3c614f7e
16426         * g10/gpg.c (main): Remove options but print a dedicated warning.
16427         * g10/options.h (struct opt): Remove fields 'print_dane_records' and
16428         'print_pka_records'.
16429         * g10/keylist.c (list_keyblock): Do not call list_keyblock_pka.
16430         (list_keyblock_pka): Remove.
16431
16432 2016-07-14  Åka Sikrom  <a4@hush.com>
16433
16434         po: Complete update of the Norwegian translation.
16435         + commit d6d7e4d218a1e2e2a88bc893b00967b032d194f8
16436
16437
16438 2016-07-14  Yuri Chornoivan  <yurchor@ukr.net>
16439
16440         Update Ukrainian translation.
16441         + commit 9427288ebb32141c196996315f93535fd7744901
16442
16443
16444 2016-07-14  Ineiev  <ineiev@gnu.org>
16445
16446         Update Russian translation.
16447         + commit 39c88870359bc75e9f72e08a7466fcff01bdc655
16448
16449
16450 2016-07-14  Werner Koch  <wk@gnupg.org>
16451
16452         gpg: Fix regression since 2.1 in --search-key with a fingerprint.
16453         + commit 0342369ce001b9dba04dc79e7a4eb66fbda278e7
16454         * dirmngr/ks-engine-hkp.c (ks_hkp_search): Prefix fingerprint with 0x.
16455
16456         gpgscm: Use kludge to avoid improper use of ffi_schemify_name.
16457         + commit fb14bf0a95e361b0991067e3aea2902d54be811d
16458         * tests/gpgscm/ffi.c (ffi_schemify_name): Use xstrdup instead of
16459         strdup for now.
16460
16461         build: Require latest released libraries.
16462         + commit c98995efefbdebea8f53d54ba2df4217dfd31ad4
16463         * agent/protect.c (OCB_MODE_SUPPORTED): Remove macro.
16464         (do_encryption): Always support OCB.
16465         (do_decryption): Ditto.
16466         (agent_unprotect): Ditto.
16467         * dirmngr/server.c (is_tor_running): Unconditionally build this.
16468
16469 2016-07-13  Werner Koch  <wk@gnupg.org>
16470
16471         build: Update config.{guess,sub} to {2016-05-15,2016-06-20}.
16472         + commit 66b634f27f10e4c0cb21c3f201998497d0bb24ca
16473         * build-aux/config.guess: Update.
16474         * build-aux/config.sub: Update.
16475
16476         gpg: Fix regression due to the new --mimemode options.
16477         + commit 3b8ed7650d2d63b01ec80ecf9e493b80e3ac7ef8
16478         * g10/gpg.c (opts): Re-add oTextmodeShort.
16479
16480 2016-07-13  Daiki Ueno  <ueno@gnu.org>
16481
16482         gpg: Make --try-all-secrets work for hidden recipients.
16483         + commit 82b90eee100cf1c9680517059b2d35e295dd992a
16484         * g10/getkey.c (enum_secret_keys): Really enumerate all secret
16485         keys if --try-all-secrets is specified.
16486
16487 2016-07-13  Werner Koch  <wk@gnupg.org>
16488
16489         gpg: Do not print a the short keyid if the high word is zero.
16490         + commit 7b96a8d736934e65bb2adbc17059f84dfeaf95fb
16491         * g10/keyid.c (format_keyid): Always returh long keyid ifor KF_LONG.
16492
16493         gpg: New option --mimemode.
16494         + commit e148c3caa90fbadba32bdbfea9513392e3aea598
16495         * g10/gpg.c (oMimemode): New.
16496         (opts): Add --mimemode.
16497         (main): Use --mimemode only in rfc4880bis compliance mode.
16498         * g10/options.h (struct opt): Add field "mimemode".
16499         * g10/build-packet.c (do_plaintext): Allow for mode 'm'.
16500         * g10/encrypt.c (encrypt_simple, encrypt_crypt): Use 'm' if requested.
16501         * g10/plaintext.c (handle_plaintext): Handle 'm' mode.
16502         * g10/sign.c (write_plaintext_packet): Handle 'm' mode.
16503         (sign_file, sign_symencrypt_file): Use 'm' if requested.
16504
16505         wks: Use correct key for the confirmation.
16506         + commit 95810929f75bd718dbdf2cd1c0181137a45e2456
16507         * tools/gpg-wks-client.c (send_confirmation_response): Actually
16508         encrypt to the recipient.
16509
16510         wks: New server command --list-domains.
16511         + commit 44ecc33b4a7147d9c112a72f55a42b65cef4fe67
16512         * tools/gpg-wks-server.c (aListDomains): New.
16513         (opts): Add --list-domains.
16514         (parse_arguments): Implement.
16515         (main): Ditto.  Use only one final diagnostic message.
16516         (command_list_domains): New.
16517         (check_and_publish): Remove directory creation.
16518         (get_domain_list): New.
16519         (expire_pending_confirmations): Rewrite using a list of directories.
16520         (command_cron): Get domain list and pass to
16521         expire_pending_confirmations.
16522
16523 2016-07-13  NIIBE Yutaka  <gniibe@fsij.org>
16524
16525         agent: Fix envvars for UPDATESTARTUPTTY.
16526         + commit 7be218177701af316db75057c99ca674d53cf585
16527         agent/command.c (cmd_updatestartuptty): Use session_env_list_stdenvnames
16528         to get the list.
16529
16530 2016-07-12  Werner Koch  <wk@gnupg.org>
16531
16532         g13: Fix memleak.
16533         + commit acb27915f8646a875b6bb507ff46cd1bc330c02b
16534         * g13/g13tuple.c (create_tupledesc): Init refcount to 1.
16535
16536         wks: Add --cron command to gpg-wks-server.
16537         + commit 38eb5f81d223616e3ee34bdfb41c387ce4e7df22
16538         * tools/gpg-wks-server.c (PENDING_TTL): New.
16539         (expire_one_domain, expire_pending_confirmations): New.
16540         (command_cron): New.
16541         (main): Implement --cron.
16542
16543         wks: Try to send an encrypted confirmation back.
16544         + commit 5de41c4ecef32add89044b8a550a47cce8c6d61e
16545         * tools/gpg-wks-client.c (encrypt_response_status_cb): New.
16546         (encrypt_response): New.
16547         (send_confirmation_response): Encrypt the response.
16548
16549         * tools/gpg-wks-server.c (send_confirmation_request): Use freeing of
16550         BODY and BODYENC.
16551
16552         wks: Also create DANE record.
16553         + commit d3837e0435921bfa5587a50738f5924a5fdf976a
16554         * tools/gpg-wks-server.c (copy_key_as_dane): New.
16555         (check_and_publish): Also publish as DANE record.
16556
16557         gpg: Extend import-option import-export to print PKA or DANE.
16558         + commit 9b075575cdc5851b019aed5ca5d5e18416beec8e
16559         * g10/export.c (do_export_stream): Move PKA and DANE printing helper
16560         code to ...
16561         (print_pka_or_dane_records): this fucntion.
16562         (write_keyblock_to_output): Add arg OPTIOSN and call
16563         print_pka_or_dane_records if requested.
16564
16565         gpg: Move a function from import.c to export.c.
16566         + commit 0f5b105d96780a29cc58893285e6c38482e0cc2d
16567         * g10/import.c (write_keyblock_to_output): Move to ...
16568         * g10/export.c (write_keyblock_to_output): here.  Add arg WITH_ARMOR.
16569         Also make sure never to export ring trust packets.
16570
16571 2016-07-11  Werner Koch  <wk@gnupg.org>
16572
16573         gpgconf: Enhance --list-dirs.
16574         + commit 7732b332886792b2bbf47ecf7430e953f1c55a2c
16575         * tools/gpgconf.c (main) <aListDir>: Factor code out to ...
16576         (list_dirs): new.  Rewrite to use a table.  Allow selection of a
16577         items.  Add "agent-ssh-socket".
16578
16579 2016-07-09  NIIBE Yutaka  <gniibe@fsij.org>
16580
16581         gpgv: Tweak default options for extra security.
16582         + commit e32c575e0f3704e7563048eea6d26844bdfc494b
16583         * g10/gpgv.c (main): Set opt.no_sig _cache, so that it doesn't depend on
16584         cached status.  Similarly, set opt.flags.require_cross_cert for backsig
16585         validation for subkey signature.
16586
16587 2016-07-07  Werner Koch  <wk@gnupg.org>
16588
16589         gpg: Add export options "export-pka" and "export-dane".
16590         + commit cbe467e794f3be81b8da2bcb1732b5514b13b71d
16591         * g10/options.h (EXPORT_PKA_FORMAT): New.
16592         * g10/keylist.c (list_keyblock_pka): Do not use DANE flag.
16593         * g10/export.c: Include zb32.h.
16594         (parse_export_options): Add options "export-pka" and "export-dane".
16595         (do_export): Do not armor if either of these option is set.
16596         (print_pka_or_dane_records): New.
16597         (do_export_stream): Implement new options.
16598
16599         gpg: Split a too large export function.
16600         + commit b05878f32aa507aa9087d7c992b630840b5ad71c
16601         * g10/export.c (do_export_stream): Factor some code out to ...
16602         (do_export_one_keyblock): new.
16603
16604 2016-07-07  Justus Winter  <justus@g10code.com>
16605
16606         gpgscm: Capture output of spawned processes.
16607         + commit 2f61aa0ff11b194d20307751ab686c87cd47dd56
16608         * tests/gpgscm/tests.scm (call-check): Capture stdout and stderr, and
16609         return stdout if the child exited successfully, or include stderr in
16610         the error.
16611         * tests/openpgp/version.scm: Demonstrate this by checking the stdout.
16612
16613 2016-07-06  Werner Koch  <wk@gnupg.org>
16614
16615         doc: Escape file names in generated macros.
16616         + commit 511c2522b95333226a5e45e538fed29dd44c9be3
16617         * doc/mkdefsinc.c (print_filename): New.
16618         (main): Use it here.
16619
16620         wks: Let the server take the encrytion key from the file.
16621         + commit e5896da666551da5322b2ae5458d429b9e60241e
16622         * tools/gpg-wks-server.c (encrypt_stream): Change arg 'fingerprint' to
16623         'keyfile'.
16624         (store_key_as_pending): Add arg 'r_fname' to make of the keyfile.
16625         (send_confirmation_request): Add arg 'keyfile'.
16626         (process_new_key): Pass on the name of the keyfile.
16627
16628         gpg: New options --recipient-file and --hidden-recipient-file.
16629         + commit a479804c86bc24bfab101f39464db3ecfbaedf6d
16630         * g10/gpg.c (oRecipientFile, oHiddenRecipientFile): New.
16631         (opts): Add options --recipient-file and --hidden-recipient-file.
16632         (main): Implement them.  Also remove duplicate code from similar
16633         options.
16634         * g10/keydb.h (PK_LIST_FROM_FILE): New.
16635         (PK_LIST_SHIFT): Bump up.
16636         * g10/pkclist.c (expand_group): Take care of PK_LIST_FROM_FILE.
16637         (find_and_check_key): Add and implement arg FROM_FILE.
16638         (build_pk_list): Pass new value for new arg.
16639         * g10/getkey.c (get_pubkey_fromfile): New.
16640         * g10/gpgv.c (read_key_from_file): New stub.
16641         * g10/test-stubs.c (read_key_from_file): New stub.
16642         * g10/server.c (cmd_recipient): Add flag --file.
16643         * g10/import.c (read_key_from_file): New.
16644
16645         * tests/openpgp/defs.scm (key-file1): New.
16646         (key-file2): New.
16647         * tests/openpgp/setup.scm: Add their private keys and import the
16648         key-file1.
16649         * tests/openpgp/encrypt.scm: Add new test.
16650
16651         gpg: New option --no-keyring.
16652         + commit 073be51a866cb5600479c504a44ae5ac94a449a2
16653         * g10/gpg.c (oNoKeyring): New.
16654         (opts): Add "--no-keyring".
16655         (main): Do not register any keyring if the option is used.
16656
16657         gpg: Document use of node flags in import.c and remove unused args.
16658         + commit fdfde91595109e51a5b8fafd292244ad41dfb83d
16659         * g10/import.c (NODE_GOOD_SELFSIG): New.  Use instead of 1.
16660         (NODE_BAD_SELFSIG): New.  Use instead of 2.
16661         (NODE_DELETION_MARK): New.  Use instead of 4.
16662         (NODE_FLAG_A): New.  Use to mark new nodes in merge_blocks.
16663         (chk_self_sigs): Remove unused args FNAME and PK.
16664         (import_one): Adjust call.  Simplify error return because
16665         chk_self_sigs does not return an error code.
16666         (append_uid, append_key, merge_sigs, merge_keysigs): Remove unsued
16667         args FNAME and KEYID.
16668         (merge_blocks, import_one, import_secret_one)
16669         (import_revoke_cert): Remove unused arg FNAME.
16670
16671         gpg: Get rid of an unused arg in a function in getkey.c.
16672         + commit 7e0c48eb6f18a80142ca2a0f76fe8d270a4e5b33
16673         * g10/getkey.c (pk_from_block): Remove unused arg CTX.  Change all
16674         callers.
16675
16676         gpg: Change calling convention for a function in getkey.c.
16677         + commit 9385dfeb9dd6d83608a10c7896c341f585a25a2b
16678         * g10/getkey.c (merge_selfsigs): Remove arg CTX.  Add args REQ_USAGE
16679         and WANT_EXACT.
16680         (finish_lookup): Adjust caller.  Set LOOKUP_NOT_SELECTED here...
16681         (lookup): and not here.
16682
16683 2016-07-05  Werner Koch  <wk@gnupg.org>
16684
16685         gpg: Fix possible out-of-bounds read in is_armored.
16686         + commit 5d1a9c4dc823b418db6c4686da55ee3abdf023b0
16687         * g10/armor.c (check_input): Call is_armored only if LEN >= 2.
16688         (unarmor_pump): Use a 2 byte buffer for is_armored.
16689
16690 2016-07-05  Justus Winter  <justus@g10code.com>
16691
16692         tests: Honor environment variable 'TMP'.
16693         + commit 8270580a5a70874beeffcdd16221937db4bcdc93
16694         This fixes problems with long socket names, e.g. when doing distcheck.
16695
16696         * tests/gpgscm/tests.scm (path-join): New function.
16697         (with-temporary-working-directory): Honor 'TMP'.
16698         (make-temporary-file): Likewise.
16699         * tests/migrations/Makefile.am (TMP): Default to '/tmp'.
16700         (TESTS_ENVIRONMENT): Set 'TMP'.
16701         * tests/openpgp/Makefile.am (TMP): Default to '/tmp'.
16702         (TESTS_ENVIRONMENT): Set 'TMP'.
16703
16704         gpgscm: Improve robustness and compatibility.
16705         + commit f26fe4f73e8430d93c03d95a8a24fdabd078bb20
16706         * tests/gpgscm/ffi.c (do_getenv): Avoid gccism.
16707         (do_mkdtemp): Handle errors.
16708
16709         tests/migrations: Fix distcheck.
16710         + commit b70d08827ddb56423ad610b4ebaaaf9cc763512f
16711         * tests/migrations/Makefile.am (TESTS): Rename test.
16712         (TEST_FILES): Update list.
16713         (EXTRA_DIST): Add common.scm.
16714         * tests/migrations/common.scm (GPGTAR): New variable.
16715         (dearmor): Rename and untar archive.
16716         * tests/migrations/extended-private-key-format.scm: Rename.
16717         (setup): Update.
16718         * tests/migrations/extended-pkf.tar.asc: New file.
16719         * tests/migrations/extended-private-key-format.gpghome: Delete.
16720         * tests/migrations/from-classic.gpghome: Likewise.
16721         * tests/migrations/from-classic.scm (setup): Update.
16722         * tests/migrations/from-classic.tar.asc: New file.
16723
16724         tools/gpgtar: Provide --create and --extract.
16725         + commit 0b8a3358798b7028be872a923da2e275da67d592
16726         * tools/gpgtar.c (cmd_and_opt_values): New values.
16727         (opts): New actions.
16728         (parse_arguments): Handle new actions.
16729         * tests/openpgp/gpgtar.scm: Test new interface.
16730
16731         g10: Fix out-of-bounds read.
16732         + commit a6b87981f7ddef42b25703723162c647e312b125
16733         * g10/armor.c (use_armor_filter): We need two bytes for 'is_armored'.
16734
16735 2016-07-04  Werner Koch  <wk@gnupg.org>
16736
16737         wks: Add command --read to gpg-wks-client.
16738         + commit 8c8ae043b8d65cb79e0e99c5bdbdcbf34714bd0c
16739         * tools/gpg-wks-client.c (aRead): New.
16740         (opts): Add command "--read".
16741         (main): Implement that.
16742
16743         tests: Add a gettime test for sizeof (time_t) > 4.
16744         + commit 27d158ead4a2b9c52269ef28d050a49c786c7d13
16745         * common/t-gettime.c (test_isotime2epoch): Add 4 more tests.
16746
16747 2016-07-03  Werner Koch  <wk@gnupg.org>
16748
16749         gpg: Avoid spurious failures on keyblocks with no or only deleted nodes.
16750         + commit 9177a897732b3cebf3f15c97c1f613f71b6318fe
16751         * g10/import.c (write_keyblock_to_output): Clear ERR on success.
16752
16753         wks: Let the client only export the requested UID.
16754         + commit 1bfed0bbc5ec9d60d4fb3a0f5c865923ed3563e7
16755         * tools/gpg-wks-client.c (get_key): Export only the requested uid.
16756
16757         tools: Call sendmail directly from the wks tools.
16758         + commit 7705f310f1406fe49b45e16c371b09863313f24f
16759         * tools/send-mail.c, tools/send-mail.h: New.
16760         * tools/wks-util.c: New.
16761         * tools/Makefile.am (gpg_wks_server_SOURCES): Add them.
16762         (gpg_wks_client_SOURCES): Ditto.
16763         * tools/gpg-wks.h (opt): Add fields use_sendmail and output.
16764         * tools/gpg-wks-client.c: Add options --send and --output.  Rename
16765         command --send to --create.
16766         (command_send, send_confirmation_response): Output via wks_send_mime.
16767         * tools/gpg-wks-server.c:  Add options --send and --output.
16768         (send_confirmation_request): Output via wks_send_mime.
16769         (check_and_publish): Add hack for name-value bug.
16770
16771 2016-07-02  Werner Koch  <wk@gnupg.org>
16772
16773         tools: Add options to gpg-wks-server.
16774         + commit c619035d9cd0c9cef62facf5365321289051f9a0
16775         * tools/gpg-wks.h (opt): Add 'default_from' and 'extra_headers'.
16776         * tools/gpg-wks-server.c (oFrom, oHeader): New.
16777         (parse_arguments): Set them and check args.
16778         (get_submission_address): New.
16779         (send_confirmation_request): Set correct From address.  Add extra
16780         headers.
16781         (process_new_key): Return an error code.
16782
16783         tools: Extend mime-maker.c:mime_maker_add_header.
16784         + commit 0e36a1d1fb79c2b75c081616eed00075190b38aa
16785         * tools/mime-maker.c (add_header): Check header name and allow
16786         name-value syntax.
16787         (mime_maker_add_header): Add mode for a syntax check.
16788
16789         doc: Describe filter expressions.
16790         + commit 442efa9b3ff211c692b6967a944b3d9371ad1bb7
16791         * doc/gpg.texi: Remove some superfluous .E.
16792         (FILTER EXPRESSIONS): New.
16793
16794         yat2m: Fix table formatting.
16795         + commit aae3cdb61555db4efb26f522030c8303a731d4a9
16796         * doc/yat2m.c (proc_texi_cmd): Use .TQ for @itemx.  Print a .P at the
16797         end of a level 0 table.
16798
16799 2016-07-01  Werner Koch  <wk@gnupg.org>
16800
16801         gpg: New option --export-filter.
16802         + commit 7bfc86c938d11c14ea78b196c82ceba2a2f5317d
16803         * g10/gpg.c (oExportFilter): New.
16804         (opts): Add --export-filter.
16805         (main): Handle option.
16806         * g10/export.c: Include recsel.h, init.h, and mbox-util.h.
16807         (export_keep_uid): New global var.
16808         (cleanup_export_globals): New.
16809         (parse_and_set_export_filter): New.
16810         (filter_getval): New.
16811         (apply_keep_uid_filter): New.
16812         (do_export_stream): Apply filter if set.
16813
16814         gpg: New option --import-filter.
16815         + commit 5137bf73ccc98a72c2eeac148e4d4b5d58f0a854
16816         * g10/gpg.c (oImportFilter): New.
16817         (opts): Add --import-filter.
16818         (main): Handle option.
16819         * g10/import.c: Include recsel.h, init.h, and mbox-util.h.
16820         (import_keep_uid): New global var.
16821         (cleanup_import_globals): New.
16822         (parse_and_set_import_filter): New.
16823         (filter_getval): New.
16824         (apply_keep_uid_filter): New.
16825         (import_one): Apply filter if set.
16826
16827         gpg: Allow to cache the mbox in a user id struct.
16828         + commit f015552374d69e28292a12f2b91ab34d65c9b457
16829         * g10/packet.h (PKT_user_id): Add field 'mbox'.
16830         * g10/free-packet.c (free_user_id): Free that.
16831
16832         gpg: Make sure a user ID packet has always a terminating Nul in memory.
16833         + commit d8bce478be3ae9e401841a77d189ef3c81ccb757
16834         * g10/keygen.c (write_uid): Avoid overflow.
16835
16836         common: Add function to select records etc.
16837         + commit 681c6ef757a73fc1a63a552186e038db179494aa
16838         * common/recsel.c, common/recsel.h: New.
16839         * common/t-recsel.c: New.
16840
16841         common: Smart up register_mem_cleanup_func.
16842         + commit 6446a6b3dfd3b2e68b4285870f902ed1f86b0866
16843         * common/init.c (register_mem_cleanup_func): Avoid double registration.
16844
16845 2016-07-01  Justus Winter  <justus@g10code.com>
16846
16847         common: Annotate semi-static allocation.
16848         + commit 49fdd0887c84ed7f7b858b9e7ffa146fcb7f1e87
16849         * common/argparse.c (optfile_parse): Allow string arguments to leak.
16850
16851         g10: Fix memory leak.
16852         + commit 78aeb236fe4ff3a6d51b3095148e7086f2a6e9a8
16853         * g10/keyserver.c (parse_keyserver_uri): Free URI.
16854
16855         tools/gpgtar: Annotate semi-static allocation.
16856         + commit cff63da930b6b3f0253668911e0931713b2b584a
16857         * tools/gpgtar.c (shell_parse_argv): Annotate argument vector as
16858         leaked.
16859
16860         g10: Fix memory leak.
16861         + commit c454922ffa71929c810c6ff048d902498575302f
16862         * g10/import.c (transfer_secret_keys): Release curve from the previous
16863         iteration.
16864
16865         g10: Fix build with disabled kbnode cache.
16866         + commit ff77b92aae9c8e20cbc7fa7c294adcc6a8c2f614
16867         * g10/kbnode.c (release_unused_nodes): Fix build with disabled kbnode
16868         cache.
16869
16870         g10: Fix memory leak.
16871         + commit 44d4c695722d96b3bbef16f2843f62413b9670cd
16872         * g10/trustdb.c (tdb_get_validity_core): Fix kbnode leak.
16873
16874         g10: Fix memory leak.
16875         + commit 5fafd18d474da7b763f5b82c73b6ca4288e136d7
16876         * g10/keygen.c (keygen_set_std_prefs): Fix memory leak.
16877
16878         Fix trivial memory leaks in tests.
16879         + commit 6bfbc368f90b274192d3751274816091675f5109
16880         * dirmngr/t-ldap-parse-uri.c (check_ldap_escape_filter): Free result.
16881         * g10/t-stutter.c (main): Free file name.
16882
16883 2016-06-30  Justus Winter  <justus@g10code.com>
16884
16885         tools: Fix trivial memory leak.
16886         + commit 8f39185d7bfa0bc749f9ccf4a041d2da4eba24ff
16887         * tools/gpg-connect-agent.c (main): Fix trivial memory leak.
16888
16889         g10: Fix memory leak.
16890         + commit 401db0eebbcd28dca8f4059706bfbd18d8cc7528
16891         * g10/export.c (do_export_stream): Free secret parameters.
16892
16893         g10: Fix memory leak.
16894         + commit eb4cdbefb05795b77a8a72189eff246b84442caf
16895         * g10/keygen.c (read_parameter_file): Free 'line'.
16896
16897         g10: Fix memory leak.
16898         + commit 1de362af9094e0a1a0be60f77fbea7c5190a4dcc
16899         * g10/sign.c (mk_notation_policy_etc): Free 'mbox'.
16900
16901         common: Fix memory leak.
16902         + commit 6b9a89e4c7d6f19de62e0a908a8d80c98bf99819
16903         * g10/textfilter.c (copy_clearsig_text): Free buffer.
16904
16905         common: Fix memory leak.
16906         + commit d2d19063d3adf29340aeb39f14e1b1e9aacf41e7
16907         * common/iobuf.c (iobuf_set_partial_body_length_mode): Only create
16908         context if necessary.
16909
16910         common: Fix memory leak.
16911         + commit 9037c23979866e6e085b3e32f973bcba590a2635
16912         * common/simple-pwquery.c (agent_open): Free socket path.
16913
16914         g10: Fix keybox-related memory leaks.
16915         + commit 29beea6462cca32d3278b0f7f9364ff4342327b8
16916         * g10/keydb.c (keydb_release): Clear keyblock cache.
16917         (keydb_get_keyblock): Revert previous change.
16918         * kbx/keybox-blob.c (create_blob_finish): Free previous buffer, free
16919         fixups after applying them.
16920         (_keybox_release_blob): Free buffer.  Currently, the buffer has been
16921         extracted before the keybox is released, but this is the right thing
16922         to do here.
16923
16924         g10: Fix memory leak.
16925         + commit 5869f518cbd8b41b4c9880fc593216b9efeea430
16926         * g10/compress.c (release_context): Free buffers.
16927
16928         g10: Fix memory leak.
16929         + commit 84f262102be19334534cccc66ed7eceea2714527
16930         * g10/sign.c (write_plaintext_packet): Free packet.
16931
16932         g10: Fix memory leak.
16933         + commit abae8a9dc8a00cf46291ccb40644b3a7aa477307
16934         * g10/mainproc.c (release_list): Do not exit early if list is NULL,
16935         there are other resources that must be released.
16936
16937         gpgscm: Fix reallocating string ports.
16938         + commit 5003caa8fdc80afd5748835c06621014f83e6ec4
16939         * tests/gpgscm/scheme.c (realloc_port_string): Use memcpy because
16940         Scheme strings may contain 0s.
16941
16942         gpgscm: Free memory backing string ports.
16943         + commit 599ad21104e622acbd1230d90d6a23abf9145499
16944         * tests/gpgscm/scheme.c (finalize_cell): Free memory backing string
16945         ports.
16946
16947         gpgscm: Use the allocator from libgcrypt.
16948         + commit d4ede89981c769b0626ab2b37615da1d12a3b078
16949         * tests/gpgscm/main.c (main): Use the allocator from libgcrypt.
16950
16951         w32: Fix build.
16952         + commit dbcb342eaf1738798a5378d9ecd83c7946140d54
16953         * g10/keyedit.c (keyedit_quick_revuid): Fix call to
16954         'check_trustdb_stale'.
16955
16956 2016-06-30  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
16957
16958         g10: Implement gpg --quick-revuid.
16959         + commit 55d112eeb0743e90be46d15dbae67368ee7d4b50
16960         * g10/revoke.c (get_default_uid_revocation_reason): New.
16961         * g10/keyedit.c (menu_revuid): Break out creation of uid revocation
16962         into new function core_revuid.
16963         * g10/keyedit.c (keyedit_quick_revuid): New. Selects key and
16964         uid, invokes core_revuid.
16965         * g10/gpg.c (main): Handle --quick-revuid argument.
16966         * doc/gpg.texi: Document --quick-revuid.
16967
16968 2016-06-29  Werner Koch  <wk@gnupg.org>
16969
16970         tools: Add gpg-wks-client and gpg-wks-server.
16971         + commit 5d6c83deaa11327366b0038928200b9f9f85b426
16972         * configure.ac: Add option --enable-wks-tools
16973         * tools/gpg-wks-client.c: New.
16974         * tools/gpg-wks-server.c: New.
16975         * tools/gpg-wks.h: new.
16976         * tools/wks-receive.c: New.
16977         * tools/call-dirmngr.c, tools/call-dirmngr.h: New.
16978
16979         build: Improve GNUPG_BUILD_PROGRAM macro.
16980         + commit d8ee0d79a702c92a257884bab86183d32d16ff0e
16981         * acinclude.m4 (GNUPG_BUILD_PROGRAM): Allow for dash in options.
16982
16983         tools: Add modules for MIME parsing and creating.
16984         + commit c334fa8df0e3901857e1a277d3277a873ae4af74
16985         * tools/mime-maker.c: New.
16986         * tools/mime-maker.h: New.
16987         * tools/mime-parser.c: New.
16988         * tools/mime-parser.h: New.
16989
16990 2016-06-28  Justus Winter  <justus@g10code.com>
16991
16992         gpgscm: Fix memory leaks.
16993         + commit 9c67958c4737b34c60ef2076f57234eec155eb36
16994         * tests/gpgscm/ffi-private.h (ffi_schemify_name): Fix prototype.
16995         (ffi_define_function_name): Free schemified name.
16996         (ffi_define_function): Likewise.
16997         (ffi_define_constant): Likewise.
16998         (ffi_define_variable_pointer): Likewise.
16999         * tests/gpgscm/ffi.c (do_wait_processes): Free arrays.
17000         (ffi_schemify_name): Fix type.
17001         * tests/gpgscm/main.c (main): Free 'sc'.
17002
17003         gpgscm: Free file names.
17004         + commit 6cb2be91a7cc8a9b8ec42f3956adbb19347318e3
17005         * tests/gpgscm/scheme.c (scheme_load_named_file): Free file name.
17006
17007         gpgscm: Fix buffer overflow.
17008         + commit 56cebdc30c10eaec179a6911e308074264d876ae
17009         * tests/gpgscm/scheme.c (store_string): Avoid writing past allocated
17010         buffer.
17011
17012         g10: Fix memory leaks.
17013         + commit c57501cc5fa84dbaf560c0fc18853c9540e918af
17014         * g10/keydb.c (keydb_get_keyblock): Free 'sigstatus' and 'iobuf'.
17015         * g10/t-keydb-get-keyblock.c: Fix trivial memory leaks.
17016         * g10/t-keydb.c: Likewise.
17017
17018         common: Fix memory leaks.
17019         + commit c14ef10fc347d966a1efcb5c2000cbf3aaafa905
17020         * common/ccparray.c (ccparray_put): Free old array.
17021         * common/stringhelp.c (do_make_filename): Free 'home'.
17022         * common/t-convert.c: Fix trivial memory leaks.
17023         * common/t-iobuf.c: Likewise.
17024         * common/t-mbox-util.c: Likewise.
17025         * common/t-name-value.c: Likewise.
17026         * common/t-stringhelp.c: Likewise.
17027         * common/t-strlist.c: Likewise.
17028
17029 2016-06-28  Werner Koch  <wk@gnupg.org>
17030
17031         dirmngr: add option to retrieve extra WKS info.
17032         + commit b1e8e0d4b945e077966fb98175191aed056bd957
17033         * dirmngr/server.c (cmd_wkd_get): Add option --submission-address.
17034
17035         gpg: Add hack to --quick-gen-key to create Curve25519 keys.
17036         + commit 20ca075d9605e27e25a780bcc465c7371400ca61
17037         * g10/keygen.c (quick_generate_keypair): Add special algo string
17038         "test-default".
17039
17040         common: New function rfctimestamp.
17041         + commit 1ddf5b846fc058171af5f2784dad866b73eb0205
17042         * common/gettime.c (rfctimestamp): New.
17043
17044         common: Add missing header file for clarity.
17045         + commit 781e614e3b4586da27e54caca39b6a7ed42fc7c7
17046         * common/zb32.c: Include zb32.h.
17047
17048 2016-06-28  Justus Winter  <justus@g10code.com>
17049
17050         tools/gpgtar: Fix handling of '-'.
17051         + commit 4819f687c48c7972c39ae29c7af1e891a4d57360
17052         * tools/gpgtar-extract.c (gpgtar_extract): Use stdin if file is '-'.
17053         * tools/gpgtar-list.c (gpgtar_list): Likewise.
17054
17055         common: Close input stream.
17056         + commit d36f664bfdc39c05927cb6e14fe1b3ecb7b64bfa
17057         * common/exechelp-posix.c (gnupg_spawn_process): Also close the input
17058         stream in the child.
17059
17060         common: Fix copying data from the spawned child.
17061         + commit 8f79c31b4d465eeaf81c8046c35bb8c34512dd8d
17062         Fixes intermittent gpgtar failures.
17063
17064         * common/exectool.c (copy_buffer_do_copy): Initialize 'nwritten'.
17065         (gnupg_exec_tool_stream): Loop until all data is copied.
17066
17067 2016-06-28  NIIBE Yutaka  <gniibe@fsij.org>
17068
17069         g10: Fix --list-packets.
17070         + commit 52f65281f9743c42a48bf5a3354c9ab0ecdb681a
17071         * g10/gpg.c (main): Call set_packet_list_mode after assignment of
17072         opt.list_packets.
17073         * g10/mainproc.c (do_proc_packets): Don't stop processing with
17074         --list-packets as the comment says.
17075         * g10/options.h (list_packets): Fix the comment.
17076         * g10/parse-packet.c: Fix the condition for opt.list_packets.
17077
17078 2016-06-25  Werner Koch  <wk@gnupg.org>
17079
17080         build: Add aclocal macro from pkg-config.
17081         + commit b6872353bae778d11730f5d0afd2192750777647
17082         * m4/pkg.m4: New.
17083
17084         yat2m: Silence lint warnings and fix a printf format bug.
17085         + commit 22b9bea1c3d0e944aa539a87d79e47d92ca5309f
17086         * doc/yat2m.c (ATTR_PRINTF, ATTR_NR_PRINTF, ATTR_MALLOC): New.
17087         (die, err, inf, xmalloc, xcalloc): New prototypes with attributes.
17088         (get_section_buffer): Take care of !N_SECTIONS.
17089         (proc_texi_cmd): Cast precision format arg.
17090         (proc_texi_buffer): Do not set IN_CMD when not used afterwards.
17091
17092 2016-06-24  Werner Koch  <wk@gnupg.org>
17093
17094         gpg: New import option "import-export".
17095         + commit 7bca3be65e510eda40572327b87922834ebe07eb
17096         * g10/import.c (parse_import_options): Add option "import-export".
17097         (write_keyblock_to_output): New.
17098         (import_one): Implement option.
17099
17100 2016-06-23  Werner Koch  <wk@gnupg.org>
17101
17102         gpg: New import option "import-show".
17103         + commit 1e5959ec059ba41f4de1e2f953300bc040efc16f
17104         * g10/options.h (IMPORT_SHOW): New.
17105         * g10/import.c (parse_import_options): Add "import-show".
17106         (import_one): Implement that.
17107
17108         gpg: Do not print the validity after key generation.
17109         + commit 09c6f7135150efbbeb459d4ae0189a81e9d180f8
17110         * g10/keylist.c (struct keylist_context): Add field NO_VALIDITY.
17111         (list_keyblock_print): Take care of it.
17112         (list_keyblock_direct): Add arg NO_VALIDITY.
17113         * g10/keygen.c (do_generate_keypair): Merge keyblock and print w/o
17114         validity.
17115
17116         common: Fix possible small memory leak in b64dec.c.
17117         + commit c229ba4d8b9b16052ee0b9573bed7905be602cdf
17118         * common/b64dec.c (b64dec_finish): Always release TITLE.
17119
17120 2016-06-23  Justus Winter  <justus@g10code.com>
17121
17122         tests/openpgp: Fake the system time for the tofu test.
17123         + commit e584d6468a2e72cd01e55f46104f9f96b56c0b66
17124         The keys in the tofu test are set to expire on 2016-09-17.  Fake the
17125         system time for this test.
17126
17127         This commit includes changes to the old test as well, for those who
17128         need to backport it.
17129
17130         * tests/openpgp/gpg-agent.conf.tmpl: Drop trailing newlines.
17131         * tests/openpgp/tofu.scm: Fake system time.
17132         * tests/openpgp/tofu.test: Likewise.
17133
17134         gpgscm: Handle exceptions in the transformation monad.
17135         + commit 145910afc077e7a5df6cc8b10e180dfa6ce38cc3
17136         * tests/gpgscm/tests.scm (pipe:do): Raise errors.
17137         (tr:spawn): Catch and return errors.
17138         (tr:call-with-content): Likewise.
17139         (tr:{open,write-to,pipe-do,assert-identity,assert-weak-identity}):
17140         Adapt.
17141
17142         tests/openpgp: Improve tests.
17143         + commit 1e822654c1dcfc23a9ef689f4e18c0ebba18baca
17144         * tests/openpgp/multisig.scm: Simplify test.
17145         * tests/openpgp/setup.scm (dearmor): Use pipe.
17146
17147         gpgscm: Add types for special objects.
17148         + commit 332fa86982dc811640ac8643332d8375816e5b81
17149         * tests/gpgscm/scheme.c (enum scheme_types): Add types for boolean,
17150         nil, eof, and the sink object.
17151         (type_to_string): Handle new types.
17152         (scheme_init_custom_alloc): Give special objects a type.
17153
17154         gpgscm: Fix Scheme initialization.
17155         + commit e6e56adf208f194ecafda29bb1c1c06655348432
17156         This potentially causes a crash if the garbage collector marks an eof
17157         object.
17158
17159         * tests/gpgscm/scheme.c (scheme_init_custom_alloc): Initialize
17160         'EOF_OBJ'.
17161
17162 2016-06-23  Werner Koch  <wk@gnupg.org>
17163
17164         common: Add dedicated private key functions to name-value.c.
17165         + commit 3ead21da80da4570e77036cc05303914c9b1f364
17166         * common/name-value.c (struct name_value_container): Add field
17167         'private_key_mode'.
17168         (my_error): New.  Use instead of gpg_error.
17169         (nvc_new_private_key): New.
17170         (nve_release): Add arg 'private_key_mode'.
17171         (nvc_release): Call nve_release with private_key_mode flag.
17172         (nvc_delete): Ditto.
17173         (_nvc_add): Do no special case "Key:" in non-private_key_mode.
17174         (nvc_get_private_key): Return error in non-private_key_mode.
17175         (nvc_set_private_key): Ditto.
17176         (nvc_parse):  Factor all code out to ...
17177         (do_nvc_parse): new.  Add arg 'for_private_key'.
17178         (nvc_parse_private_key): New.
17179         * agent/findkey.c (write_extended_private_key): Replace nvc_parse by
17180         nvc_parse_private_key.
17181         (read_key_file): Ditto.
17182
17183         * common/t-name-value.c (private_key_mode): New variable.
17184         (my_nvc_new): New.  Replace all callers.
17185         (test_key_extraction): Take mode in account.
17186         (run_tests): Ditto.
17187         (run_modification_tests): Ditto.
17188         (parse): Ditto.
17189         (main): Add option --parse and rename --parse to --parse-key.
17190
17191         common: Rename external symbols in name-value.c.
17192         + commit d74d23d860c1e5039bd595c31c846782c5cb8025
17193         * common/name-value.c, common/name-value.h: Rename symbol prefixes
17194         from "pkc_" to "nvc_" and from "pke_" to "nve_".  Change all callers.
17195
17196         common: Rename private-keys.c to name-value.c.
17197         + commit b841a883a2a66807aa427e65d49067584bedfbe2
17198         * common/private-keys.c: Rename to name-value.c.
17199         * common/private-keys.h: Rename to name-value.h.  Chage all users.
17200         * common/t-private-keys.c: Rename to t-name-value.c.
17201         * common/Makefile.am: Adjust accordingly.
17202
17203         common: Add PGP armor decoding to b64dec.
17204         + commit 3694579bc4eef27ed53e1845bf03be38c299ce76
17205         * common/b64dec.c (decoder_states): Add new states.
17206         (b64dec_proc): Handle PGP armored format.
17207
17208 2016-06-23  NIIBE Yutaka  <gniibe@fsij.org>
17209
17210         g10: Fix regression of card-edit/fetch.
17211         + commit 6f5ff1cfe449cf1f4cb7287bc57570eb794216b2
17212         * g10/card-util.c (fetch_url): Call keyserver_fetch instead of
17213         keyserver_import_fprint.
17214
17215 2016-06-21  Justus Winter  <justus@g10code.com>
17216
17217         tests/migrations: Convert to Scheme and re-enable.
17218         + commit f548383d9af912bf93217068cc8aa99a9a6eda93
17219         * configure.ac: Re-enable.
17220         * tests/Makefile.am: Likewise.
17221         * tests/migrations/Makefile.am (TESTS): Use Scheme tests.
17222         * tests/migrations/common.scm: New file.
17223         * tests/migrations/extended-private-key-format.scm: Likewise.
17224         * tests/migrations/from-classic.scm: Likewise.
17225         * tests/migrations/extended-private-key-format.test: Drop file.
17226         * tests/migrations/from-classic.test: Drop file.
17227
17228         gpgscm: Add more file handling functions.
17229         + commit c5e0ca5a59ebd91b67944ca125cc8cd73a9d243e
17230         * tests/gpgscm/ffi.c (do_glob): New function.
17231         (ffi_init): Define new function.
17232         * tests/gpgscm/tests.scm (basename-suffix): New function.x
17233
17234         tests/openpgp: Port the remaining tests to Scheme.
17235         + commit 0340fcdac864109e3dd6edee759efc96e4d3f84e
17236         * tests/openpgp/Makefile.am (TESTS): Add new tests.
17237         * tests/openpgp/defs.scm (gpg-with-colons): New function.
17238         (get-config): Use new function.
17239         * tests/openpgp/export.scm: New file.
17240         * tests/openpgp/tofu.scm: Likewise.
17241
17242         gpgscm: Improve test framework.
17243         + commit 65081c31e7536d8fb5effcc2c9aeeffc120c9a69
17244         * tests/gpgscm/lib.scm (echo): Move...
17245         * tests/gpgscm/tests.scm (echo): ... here.
17246         (info, error, skip): And use echo here.
17247         (file-exists?): New function.
17248         (tr:spawn): Check that source exists and if the sink has been created.
17249         (tr:call-with-content): Hand in optional arguments.
17250
17251         gpgscm: Use native string searching functions.
17252         + commit 5fbbc4b334a73150e709a4802cac99abd8ada61d
17253         * tests/gpgscm/ffi-private.h: Handle character arguments.
17254         * tests/gpgscm/ffi.c (do_string_index): New function.
17255         (do_string_rindex): Likewise.
17256         (do_string_contains): Likewise.
17257         (ffi_init): Define new functions.
17258         * tests/gpgscm/ffi.scm (ffi-define): New macro.
17259         * tests/gpgscm/lib.scm (string-index): Use native function,
17260         demonstrate behavior.
17261         (string-rindex): Likewise.
17262         (string-contains?): Likewise.
17263         Demonstrate behavior of various other functions.
17264         (read-all): Rework so that it can handle large files.
17265
17266         gpgscm: Improve error reporting.
17267         + commit d99949fc8cf541018267964629992d55c97ca9ab
17268         * tests/gpgscm/scheme.c (type_to_string): New function.
17269         (Eval_Cycle): Include actual type in error message.
17270
17271         gpgscm: Make memory allocation failures fatal.
17272         + commit 616582071a2c76c4fb529d4da549aa95ee5d78d6
17273         * tests/gpgscm/scheme.c (Eval_Cycle): Exit if we run out of memory.
17274
17275 2016-06-21  Werner Koch  <wk@gnupg.org>
17276
17277         sm: Do not install cacert and other root certificates.
17278         + commit c19b2061274cd50838e62a2acbdc7e7d24888e7e
17279         * doc/Makefile.am (dist_pkgdata_DATA): Move qualified.txt and
17280         com-certs.pem to ...
17281         (EXTRA_DIST): here.
17282
17283 2016-06-20  Werner Koch  <wk@gnupg.org>
17284
17285         gpg: Add experimental support for an issuer fpr.
17286         + commit 955baf04364721457cd99aad21942523cd50498c
17287         * common/openpgpdefs.h (SIGSUBPKT_ISSUER_FPR): New.
17288         * g10/build-packet.c (build_sig_subpkt_from_sig): Add arg PKSK and
17289         insert the issuer fpr if needed.
17290         * g10/sign.c (write_signature_packets): Pass signing key.
17291         (make_keysig_packet): Ditto.
17292         (update_keysig_packet): Ditto.
17293         * g10/parse-packet.c (dump_sig_subpkt): Print issuer fpr.
17294         (parse_one_sig_subpkt): Detect issuer fpr.
17295         (can_handle_critical): Add issuer fpr.
17296         * g10/mainproc.c (check_sig_and_print): Try to get key via fingerprint.
17297         * g10/gpgv.c (keyserver_import_fprint): New stub.
17298         * g10/test-stubs.c (keyserver_import_fprint): New stub.
17299
17300         gpg: New option --rfc4880bis.
17301         + commit ee2d9061d7abc36b857165a8395203a97380baa2
17302         * g10/options.h (struct opt): Add field flags.rfc4880bis.
17303         * g10/gpg.c (oRFC4880bis): new.
17304         (opts): add --rfc4880bis.
17305         (main): Implement that and print a warning.
17306
17307 2016-06-19  Niibe Yutaka  <gniibe@fsij.org>
17308
17309         scd: Reset nonnull_nad to zero for VENDOR_GEMPC.
17310         + commit 971064f8b7ad676326b2a468f688037a303717df
17311         * (parse_ccid_descriptor): nonnull_nad = 0 for all GEMPC device.
17312
17313 2016-06-17  Werner Koch  <wk@gnupg.org>
17314
17315         tests: Make make distcheck work again.
17316         + commit ce1689ea0720552ac900d7b2c4139caf24452018
17317         * Makefile.am (tests): Remove test code which would led to doubling
17318         calls to for e.g. "make distclean".
17319         * tests/Makefile.am: Typo fixes.
17320         * tests/gpgscm/Makefile.am (EXTRA_DIST): Fix name of License file.
17321         Add repl.scm.
17322         (check): Replace by check-local because check is a standard automake
17323         target.
17324         * tests/openpgp/Makefile.am (TESTS_ENVIRONMENT): Replace gmake0sim by
17325         automake generated macro.
17326         (EXTRA_DIST): Add defs.scm
17327
17328         gpgscm: Silence compiler warnings.
17329         + commit dfe5282e5859409849a17d68b2b3a046370f65bd
17330         * tests/gpgscm/scheme.c (mk_integer): Rename arg NUM to N.
17331         (fill_vector): Ditto.
17332         (mark): Rename var NUM to N.
17333         (set_slot_in_env): Mark SC as unused.
17334         (is_any): Mark P as unused.
17335
17336         Add license notices for TinySCHEME.
17337         + commit dc1db12d2c4f9f12bc3f7de37f76293b316c3f35
17338         * tests/gpgscm/COPYING: Rename to ...
17339         * tests/gpgscm/LICENSE.TinySCHEME: this.
17340         * AUTHORS: Add a note about TinySCHEME.
17341         * build-aux/speedo/w32/pkg-copyright.txt: Add TinySCHEME notice.
17342
17343 2016-06-17  Justus Winter  <justus@g10code.com>
17344
17345         tests/openpgp: Reimplement tests in Scheme.
17346         + commit 9609cb20e4caee739b9fc4fd36797029d2970041
17347         * Makefile.am: Build the test infrastructure on Windows.
17348         * tests/openpgp/Makefile.am (required_pgms): Add gpgscm.
17349         (TESTS_ENVIRONMENT): Make sure gpgscm and the libraries are found.
17350         (TESTS): Replace tests with the new Scheme implementations.
17351         * tests/openpgp/4gb-packet.scm: New file.
17352         * tests/openpgp/README: Likewise.
17353         * tests/openpgp/armdetach.scm: Likewise.
17354         * tests/openpgp/armdetachm.scm: Likewise.
17355         * tests/openpgp/armencrypt.scm: Likewise.
17356         * tests/openpgp/armencryptp.scm: Likewise.
17357         * tests/openpgp/armor.scm: Likewise.
17358         * tests/openpgp/armsignencrypt.scm: Likewise.
17359         * tests/openpgp/armsigs.scm: Likewise.
17360         * tests/openpgp/clearsig.scm: Likewise.
17361         * tests/openpgp/conventional-mdc.scm: Likewise.
17362         * tests/openpgp/conventional.scm: Likewise.
17363         * tests/openpgp/decrypt-dsa.scm: Likewise.
17364         * tests/openpgp/decrypt.scm: Likewise.
17365         * tests/openpgp/default-key.scm: Likewise.
17366         * tests/openpgp/defs.scm: Likewise.
17367         * tests/openpgp/detach.scm: Likewise.
17368         * tests/openpgp/detachm.scm: Likewise.
17369         * tests/openpgp/ecc.scm: Likewise.
17370         * tests/openpgp/encrypt-dsa.scm: Likewise.
17371         * tests/openpgp/encrypt.scm: Likewise.
17372         * tests/openpgp/encryptp.scm: Likewise.
17373         * tests/openpgp/finish.scm: Likewise.
17374         * tests/openpgp/genkey1024.scm: Likewise.
17375         * tests/openpgp/gpgtar.scm: Likewise.
17376         * tests/openpgp/import.scm: Likewise.
17377         * tests/openpgp/mds.scm: Likewise.
17378         * tests/openpgp/multisig.scm: Likewise.
17379         * tests/openpgp/run-tests.scm: Likewise.
17380         * tests/openpgp/seat.scm: Likewise.
17381         * tests/openpgp/setup.scm: Likewise.
17382         * tests/openpgp/signencrypt-dsa.scm: Likewise.
17383         * tests/openpgp/signencrypt.scm: Likewise.
17384         * tests/openpgp/sigs-dsa.scm: Likewise.
17385         * tests/openpgp/sigs.scm: Likewise.
17386         * tests/openpgp/use-exact-key.scm: Likewise.
17387         * tests/openpgp/verify.scm: Likewise.
17388         * tests/openpgp/version.scm: Likewise.
17389
17390         tests/gpgscm: Add a TinySCHEME-based test driver.
17391         + commit d2ce3f9eee34e380536049c0c9d26ed66273f094
17392         * configure.ac: Add new component.
17393         * tests/Makefile.am: Likewise.
17394         * tests/gpgscm/Makefile.am: New file.
17395         * tests/gpgscm/ffi-private.h: Likewise.
17396         * tests/gpgscm/ffi.c: Likewise.
17397         * tests/gpgscm/ffi.h: Likewise.
17398         * tests/gpgscm/ffi.scm: Likewise.
17399         * tests/gpgscm/lib.scm: Likewise.
17400         * tests/gpgscm/main.c: Likewise.
17401         * tests/gpgscm/private.h: Likewise.
17402         * tests/gpgscm/repl.scm: Likewise.
17403         * tests/gpgscm/scheme-config.h: Likewise.
17404         * tests/gpgscm/t-child.c: Likewise.
17405         * tests/gpgscm/t-child.scm: Likewise.
17406         * tests/gpgscm/tests.scm: Likewise.
17407
17408         tests/gpgscm: Foreign objects support for TinySCHEME.
17409         + commit 56c36f2932fe2baf8e46efdea4315cf33f3c0338
17410         * tests/gpgscm/scheme-private.h (struct cell): Add 'foreign_object'.
17411         (is_foreign_object): New prototype.
17412         (get_foreign_object_{vtable,data}): Likewise.
17413         * tests/gpgscm/scheme.c (enum scheme_types): New type.
17414         (is_foreign_object): New function.
17415         (get_foreign_object_{vtable,data}): Likewise.
17416         (mk_foreign_object): Likewise.
17417         (finalize_cell): Free foreign objects.
17418         (atom2str): Pretty-print foreign objects.
17419         (vtbl): Add new functions.
17420         * tests/gpgscm/scheme.h (struct foreign_object_vtable): New type.
17421         (mk_foreign_object): New prototype.
17422         (struct scheme_interface): Add new functions.
17423
17424         Patch from Thomas Munro,
17425         https://sourceforge.net/p/tinyscheme/patches/13/
17426
17427         tests/gpgscm: Dynamically allocate string buffer.
17428         + commit 8e5ad9aabdd57457f76078924d33acb94b75a877
17429         * tests/gpgscm/scheme-config.h (strbuff{,_size}): Make buffer dynamic.
17430         * tests/gpgscm/scheme.c (expand_strbuff): New function.
17431         (putcharacter): Adapt length test.
17432         (readstrexp): Expand buffer if necessary.
17433         (scheme_init_custom_alloc): Initialize buffer.
17434         (scheme_deinit): Free buffer.
17435
17436         Patch from Thomas Munro,
17437         https://sourceforge.net/p/tinyscheme/patches/11/
17438
17439         tests/gpgscm: Make exception value available.
17440         + commit 3b100da9ada9171d873a796eaf3351d4fceed394
17441         * tests/gpgscm/init.scm (throw): Hand exception value to the handler.
17442         (catch): And bind it to *error*.
17443
17444         tests/gpgscm: Add package macro.
17445         + commit 2907381f4a7b422823b2304ebe550acbb2f66480
17446         * tests/gpgscm/init.scm: Add package macro from manual.
17447
17448         tests/gpgscm: Expose function to open streams as Scheme ports.
17449         + commit 55275b8e2b43a3420d85a1a931e02febaa1113e7
17450         * tests/gpgscm/scheme.c (vtbl): Add 'port_from_file' to the vtable.
17451         * tests/gpgscm/scheme.h (struct scheme_interface): New field
17452         'mk_port_from_file'.
17453
17454         tests/gpgscm: Nicer error message.
17455         + commit 13bba1357478815a85f5c0db3607ebb6cd574f56
17456         * tests/gpgscm/scheme.c (opexe_0): Include the value that we tried to
17457         evaluate as function-like in the error message.
17458
17459         tests/gpgscm: Fix error hook.
17460         + commit e02c1ccae13e4eb55afef8de4f29022c709404eb
17461         * tests/gpgscm/init.scm (*error-hook*): Fix error hook so that the
17462         whole error message is displayed.
17463
17464         tests/gpgscm: Handle unhandled enumeration values.
17465         + commit 133f25703a47e9bbc28c4532934f405ecdeb2de0
17466         * tests/gpgscm/scheme.c (opexe_{3,4}): Handle unhandled enumeration
17467         values in the opcode dispatching code.
17468
17469         tests/gpgscm: Verbatim import of latest TinySCHEME.
17470         + commit cb989504cdd4f0ff902d31af871dc3ee0d9419ac
17471         Revision 110 from svn://svn.code.sf.net/p/tinyscheme/code/trunk
17472
17473         * tests/gpgscm/COPYING: New file.
17474         * tests/gpgscm/Manual.txt: Likewise.
17475         * tests/gpgscm/init.scm: Likewise.
17476         * tests/gpgscm/opdefines.h: Likewise.
17477         * tests/gpgscm/scheme-private.h: Likewise.
17478         * tests/gpgscm/scheme.c: Likewise.
17479         * tests/gpgscm/scheme.h: Likewise.
17480
17481 2016-06-17  Werner Koch  <wk@gnupg.org>
17482
17483         scd: Make option --homedir work.
17484         + commit 4e41745b3ea3bb8ffc50af6bafeb1de9c928812f
17485         * scd/scdaemon.c (opts): Add --homedir.
17486
17487 2016-06-16  Werner Koch  <wk@gnupg.org>
17488
17489         Release 2.1.13.
17490         + commit b3df4e2ac6aa9b4154e923f71b4221533043e5ac
17491
17492
17493 2016-06-16  Yuri Chornoivan  <yurchor@ukr.net>
17494
17495         po: Update Ukrainian translation.
17496         + commit d4ce1b04431cf02ebc1bdc7150ad587d599f2a95
17497
17498
17499 2016-06-16  Ineiev  <ineiev@gnu.org>
17500
17501         po: Update Russian translation.
17502         + commit 2273e4f999325cdc9d275507cd07c7e95d62a377
17503
17504
17505 2016-06-16  Werner Koch  <wk@gnupg.org>
17506
17507         po: Update German translation.
17508         + commit 69f1b0b041c251abb66f000db173a602693bb18f
17509
17510
17511         Add missing files so that make distcheck works again,
17512         + commit 4d7d292cd5b616b209dfd4302a1deffe11b7be0e
17513         * tests/openpgp/Makefile.am (CLEANFILES): Add created file
17514         "passphrases".
17515         * tools/Makefile.am (EXTRA_DIST): Add no-libgcrypt.c.
17516
17517         tools: Fix typo in function name of symcryptrun.
17518         + commit e44dd878df58dab27c9cd411d80c4c81501e649a
17519         * tools/symcryptrun.c (main): Fix typo.
17520
17521 2016-06-15  Niibe Yutaka  <gniibe@fsij.org>
17522
17523         g10: Fix another race condition for trustdb access.
17524         + commit 35a3ce2acf78a95fecbccfd8db0560cca24232df
17525         * g10/tdbio.c (create_version_record): Call create_hashtable to always
17526         make hashtable, together with the version record.
17527         (get_trusthashrec): Remove call to create_hashtable.
17528
17529 2016-06-14  Werner Koch  <wk@gnupg.org>
17530
17531         gpg: Print the subkey's curve and not the primary key curve.
17532         + commit b56aebe76657ce6efa9c6819d5a8c2a31c2bbbba
17533         * g10/keylist.c (list_keyblock_colon): Use PK2 for the subkey's curve.
17534
17535         ldap: Improve info output for v3 fallback.
17536         + commit b7e3dfcf139284d30921cf44e7bab43d4244cc37
17537         * dirmngr/dirmngr_ldap.c (fetch_ldap): Do not use log_debug in an
17538         unprotected section.  Replace log_debug by log_info in verbose mode.
17539
17540 2016-06-14  Andre Heinecke  <aheinecke@intevation.de>
17541
17542         dirmngr: Try ldap protocol V3 as fallback.
17543         + commit f989b6ee0db96c36f13f093cbbcfd1d5b472d03c
17544         * dirmngr/dirmngr_ldap.c (fetch_ldap): Try V3 Protocol in case
17545         default Protocol gives error.
17546
17547         dirmngr: Print ldap error if bind fails.
17548         + commit 5faddcb2927a997e05fb34eb270982096d1fe3a4
17549         * dirmngr/dirmngr_ldap.c (fetch_ldap): Use ldap_err2string on bind
17550         return.
17551
17552 2016-06-14  Werner Koch  <wk@gnupg.org>
17553
17554         gpgsm: Allow ciphers AES192 and SERPENT256.
17555         + commit 5f9bd7a9e1ed4edcbb6c4e908d4bea5cd7dc9e68
17556         * sm/gpgsm.c (main): Add AES192 cipher.  Allow SERPENT256.
17557
17558         doc: Add files and envvars to a new index.
17559         + commit 2423238ee4c8a8c531dfe9e45c95f2760b638faa
17560         * doc/gnupg.texi: Define new index "ef".
17561         (Environment Index): New.
17562
17563         gpg: Avoid endless loop in a tofu error case.
17564         + commit f980cd2e0e4694a38038f518f290017087d4ce33
17565         * g10/tofu.c (get_trust): Do not jump to out.
17566
17567         gpg: Split tofu's get_trust function into several smaller ones.
17568         + commit 1affdf1efc42ed22dc023c92ca5134d5bcbf2686
17569         * g10/tofu.c (get_trust): Factor code out to ...
17570         (format_conflict_msg_part1): new and to ...
17571         (ask_about_binding): new.
17572
17573 2016-06-13  Werner Koch  <wk@gnupg.org>
17574
17575         gpg: Un-deprecate option --auto-key-retrieve.
17576         + commit 9e126af215143fddbdc3949681abb9ffdb9153bb
17577         * g10/gpg.c (main): Remove deprecation warning.
17578
17579         gpg: New option --disable-signer-uid, create Signer's UID sub-packet.
17580         + commit 61e7fd68c05ed185728e9da45f7a44a2323065ad
17581         * g10/gpg.c (oDisableSignerUID): New.
17582         (opts): New option '--disable-signer-uid'.
17583         (main): Set option.
17584         * g10/options.h (opt): Add field flags.disable_signer_uid.
17585         * g10/sign.c: Include mbox-util.h.
17586         (mk_notation_policy_etc): Embed the signer's uid.
17587         * g10/mainproc.c (check_sig_and_print): Do not use WKD for auto key
17588         retrieval if --disable-signer-uid is used.
17589
17590         gpg: Try Signer's User ID sub-packet with --auto-key-retrieve.
17591         + commit 08c82b1b55d28ffd09b859205b7686bcefae5011
17592         * g10/packet.h (PKT_signature): Add field 'signers_uid'.
17593         * g10/parse-packet.c (parse_signature): Set this field.
17594         * g10/free-packet.c (free_seckey_enc): Free field.
17595         (copy_signature): Copy field.
17596         * g10/mainproc.c (akl_has_wkd_method): New.
17597         (check_sig_and_print): Extend NEWSIG status.  If WKD is enabled try to
17598         locate a missing key via the signature's Signer's User ID sub-packet.
17599         Do this right before trying a keyserver lookup.
17600
17601 2016-06-11  Werner Koch  <wk@gnupg.org>
17602
17603         gpg: Remove C-99ism, re-indent, and simplify one function.
17604         + commit 334e993a71d3abb7d30cb5ee05d578cecf0c3f67
17605         * g10/call-agent.c (struct keyinfo_data): Rename to
17606         keyinfo_data_parm_s.
17607         (agent_get_keyinfo): Replace C-99 style init.
17608         (keyinfo_status_cb): Use new fucntion split_fields.
17609         * g10/export.c (match_curve_skey_pk): Add missings returns error
17610         cases.
17611         (cleartext_secret_key_to_openpgp): Better clear PK->PKEY first.
17612
17613         common: New function split_fields.
17614         + commit 5ba99d9302cd86aee99958b71075d5288bb430aa
17615         * common/stringhelp.c (split_fields): New.
17616         * common/t-stringhelp.c: Include assert.h.
17617         (test_split_fields): New.
17618         (main): Call test.
17619
17620 2016-06-11  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
17621
17622         g10: Export cleartext keys as cleartext.
17623         + commit c41c46fa84cabbed74a13ded51fc3a817a919367
17624         * g10/export.c (do_export_stream): If a key is stored by the agent in
17625         cleartext, then try to export it as cleartext.
17626         * tests/openpgp/export.test: For secret keys that are stored in
17627         cleartext, test should try to export without pinentry interaction.
17628
17629         g10: Allow receiving cleartext secret keys from agent.
17630         + commit a3cb72af79ee645eda212f31ab0b266f2c3d9f29
17631         * g10/export.c (match_curve_skey_pk): New function, testing whether an
17632         OpenPGP public key and an S-expression use the same curve.
17633         * g10/export.c (cleartext_secret_key_to_openpgp): New function,
17634         filling in the secret key parameters of a PKT_public_key object from
17635         a corresponding cleartext S-expression.
17636         * g10/export.c, g10/main.h (receive_seckey_from_agent): Add cleartext
17637         parameter, enabling retrieval of the secret key, unlocked.
17638         * g10/export.c (do_export_stream): Send cleartext as 0, keeping current
17639         behavior.
17640         * g10/keygen.c (card_store_key_with_backup): Use cleartext=0 to ensure
17641         that smartcard backups are all passphrase-locked.
17642
17643         g10: Add openpgp_protected flag to agent secret key export functions.
17644         + commit 7de74320767d15d915942a98ff47c00175a078ed
17645         * g10/call-agent.c, g10/call-agent.h (agent_export_key): Add
17646         openpgp_protected flag.
17647         * g10/export.c (receive_seckey_from_agent): Request openpgp_protected
17648         secret keys from agent.
17649         * agent/command.c (hlp_export_key): EXPORT_KEY help text: add a
17650         brief description of the effect of --openpgp.
17651
17652         g10: report whether key in agent is passphrase-protected or not.
17653         + commit 00f30cc01c79bbdff5cdc3be795f009f15d3845e
17654         * g10/call-agent.c, g10/call-agent.h (agent_get_keyinfo): add
17655           r_cleartext parameter to report whether a key is stored without
17656           passphrase protection.
17657         * g10/gpgv.c, g10/test-stubs.c: augment dummy agent_get_keyinfo to
17658           match new API.
17659         * g10/export.c, g10/keyedit.c, g10/keygen.c, g10/keylist.c,
17660           g10/sign.c: pass NULL to agent_get_keyinfo since we do not yet
17661           need to know whether agent is passphrase-protected.
17662
17663 2016-06-08  Werner Koch  <wk@gnupg.org>
17664
17665         Explicitly restrict socket permissions.
17666         + commit 8127043d549a5843ea1ba2dc6da4906fc2258d53
17667         * agent/gpg-agent.c (create_server_socket): Call chmod before listen.
17668         * scd/scdaemon.c (create_server_socket): Ditto.
17669         * dirmngr/dirmngr.c (main): Ditto.
17670
17671         w32: Fix recent build regression.
17672         + commit 6790115fd9059e066b4e6feb6b1e3876a1c1d522
17673         * common/homedir.c (_gnupg_socketdir_internal) [W32]: Add definition
17674         for NAME.
17675         * g10/gpg.c (main) [W32]:  Fix use og gnupg_homedir.
17676
17677         * agent/gpg-agent.c (remove_socket): Remove unused var P.
17678         * scd/scdaemon.c (cleanup): Ditto.
17679
17680         gpgconf: New commands --create-socketdir and --remove-socketdir.
17681         + commit cf4910419e09daf414f76ca2c8ab685c3d488ec1
17682         * tools/gpgconf.c: Include unistd.h.
17683         (aCreateSocketDir, aRemoveSocketDir): New.
17684         (opts): Add --create-socketdir and --remove-socketdir.
17685         (main): Implement them.
17686
17687         Implement /run/user/UID/gnupg based sockets.
17688         + commit aab8a0b05292b0d06e3001a0b289224cb7156dbd
17689         * common/homedir.c: Include sys/stat.h and zb32.h.
17690         (w32_portable_app, w32_bin_is_bin): Change type from int to byte.
17691         (non_default_homedir): New.
17692         (is_gnupg_default_homedir): New.
17693         (default_homedir): Set non_default_homedir.
17694         (gnupg_set_homedir): Set non_default_homedir and make
17695         the_gnupg_homedir and absolute directory name.
17696         (gnupg_homedir): Return an absolute directory name.
17697         (_gnupg_socketdir_internal): New.
17698         (gnupg_socketdir): Implement /run/user/ based sockets.
17699         * tools/gpg-connect-agent.c (get_var_ext): Replace now obsolete
17700         make_filename by xstrdup.
17701         * tools/gpgconf.c (main): Sue gnupg_homedir for the "homedir:" output.
17702
17703         gpgconf: Add option --homedir.
17704         + commit def512eb67c8a380f3b873cee0f156deef0b6dda
17705         * tools/gpgconf.c (opts): Add --homedir.
17706         (main): Set homedir.
17707
17708         Do not use no-libgcrypt dummy for tools.
17709         + commit 173fa97102fec68670a46ae1b460231e2a183c81
17710         * tools/Makefile.am (gpgconf_SOURCES): Remove no-libgcrypt.c.
17711         (gpgconf_LDADD): Add LIBGCRYPT_LIBS.
17712         (gpg_connect_agent_LDADD): Ditto.
17713         (gpgtar_LDADD): Ditto.
17714         * dirmngr/Makefile.am (dirmngr_client_LDADD): Ditto.
17715         (t_common_ldadd): Ditto.  Remove no-libgcrypt.o.
17716
17717         Do not try to remove the enclosing directory of sockets.
17718         + commit 0faf8951544f43790c412777a926c969540174bd
17719         * agent/gpg-agent.c (remove_socket): Do not remove the enclosing
17720         directory.
17721         * scd/scdaemon.c (cleanup): Ditto.
17722
17723 2016-06-07  Werner Koch  <wk@gnupg.org>
17724
17725         common: New function gnupg_socketdir.
17726         + commit 36550dde998fa1d497098050ca2d4e1a952ed6b6
17727         * common/homedir.c (gnupg_socketdir): New.
17728         * agent/gpg-agent.c (create_socket_name): Use new function instead of
17729         gnupg_homedir.
17730         (check_own_socket): Ditto.
17731         (check_for_running_agent): Ditto.
17732         * agent/preset-passphrase.c (main): Ditto.
17733         * common/asshelp.c (start_new_gpg_agent): Ditto.
17734         * scd/scdaemon.c (create_socket_name): Ditto.
17735         * tools/gpgconf.c (main): Ditto.
17736         * tools/symcryptrun.c (main): Ditto.
17737
17738         common: Remove homedir arg from start_new_{dirmngr,gpg_agent}.
17739         + commit fb88f37c40dc156fa0b5bfba4ac85f1e553fd7e9
17740         * common/asshelp.c (start_new_gpg_agent): Remove arg 'homedir' in
17741         favor of gnupg_homedir ().  Change all callers.
17742         (start_new_dirmngr): Ditto.
17743         * common/get-passphrase.c (gnupg_prepare_get_passphrase): Remove arg
17744         'homedir'.
17745
17746         Replace use of opt.homedir by accessor functions.
17747         + commit 22a7ef01aa2c0eb77bcc40174d09104acc35cab1
17748         * common/homedir.c (the_gnupg_homedir): New var.
17749         (gnupg_set_homedir): New.
17750         (gnupg_homedir): New.
17751         * g10/options.h (struct opt): Remove 'homedir' and replace all users
17752         by the new accessor functions.
17753         * g13/g13-common.h (struct opt): Ditto.
17754         * scd/scdaemon.h (struct opt): Ditto.
17755         * sm/gpgsm.h (struct opt): Ditto.
17756         * dirmngr/dirmngr.h (struct opt): Ditto.
17757         * agent/preset-passphrase.c (opt_homedir): Ditto.
17758         * agent/protect-tool.c (opt_homedir): Ditto.
17759
17760 2016-06-07  NIIBE Yutaka  <gniibe@fsij.org>
17761
17762         po: Update Japanese translation.
17763         + commit 650abbab716750d6087a457a25fa2efaaa3567cd
17764
17765
17766         gpg: Fix command line parsing of --quick-addkey and --quick-gen-key.
17767         + commit abeeb84a94be815a16e678b319cb5c8bffde2811
17768         * g10/gpg.c (main): Compose a block by curly braces.
17769
17770 2016-06-06  Werner Koch  <wk@gnupg.org>
17771
17772         gpg: Use --keyid-format=none by default.
17773         + commit 7257ea2d450238afa4d162fab8001f74782fe43f
17774         * g10/gpg.c (main): Init keyid_format to KF_NONE.
17775         * g10/keyid.c (format_keyid): Ditto.
17776         (keystrlen): Ditto.
17777
17778         gpg: Add option --with-subkey-fingerprint.
17779         + commit 1d1cb86694fb2223de1da0b3bfffb5c62f505847
17780         * g10/gpg.c (oWithSubkeyFingerprint): New.
17781         (opts): Add --with-subkey-fingerprint[s].
17782         (main): Set that option.
17783         * g10/options.h (struct opt): Add 'with_subkey_fingerprint'.
17784         * g10/keylist.c (list_keyblock_print): Print subkey fingerprint.
17785         (print_fingerprint): Tweak printing to use compact format if
17786         desirable.
17787
17788         gpg: Implement --keyid-format=none.
17789         + commit b047388d57443f584f1c1d6333aac5218b685042
17790         * g10/gpg.c (main): Add option "none" to --keyid-format.
17791         * g10/options.h (KF_NONE): New.
17792         * g10/keyid.c (format_keyid): Implement that.
17793         (keystr): Use format "long" is KF_NONE is in use.
17794         (keystr_with_sub): Ditto.
17795         * g10/keylist.c (list_keyblock_print): Adjust indentaion for KF_NONE.
17796         Factor some code out to ...
17797         (print_key_line): new.
17798         (print_fingerprint): Add mode 20.
17799         * g10/mainproc.c (list_node): Use print_key_line.  Replace MAINKEY by
17800         flags.primary in the PK.  Fix putting a " revoked..." string into the
17801         colons format.
17802         * g10/pkclist.c (do_edit_ownertrust): Use print_key_line.  This
17803         slightly changes the putput format.
17804         * g10/revoke.c (gen_standard_revoke): Use print_key_line.  This may
17805         also put "expires: " into the output.
17806
17807 2016-06-04  Werner Koch  <wk@gnupg.org>
17808
17809         w32: Require --enable-build-timestamp for the BUILD_HOSTNAME.
17810         + commit 79b7a8a9e0d41b743ceaee20dc47294359fe0d44
17811         * configure.ac (BUILD_HOSTNAME): Set to "<anon>" bey default.
17812         * build-aux/speedo.mk (speedo_pkg_gnupg_configure): Add
17813           --enable-build-timestamp.
17814
17815 2016-06-02  Werner Koch  <wk@gnupg.org>
17816
17817         gpg: Add the fingerprint to KEY_CREATED for subkeys.
17818         + commit 8d976a6b07c5a356631791b46b590328c1451f31
17819         * g10/keygen.c (print_status_key_created): Make more robust by
17820         allowing a NULL for PK.
17821         (generate_subkeypair): Use print_status_key_created.
17822         (generate_card_subkeypair): Ditto.
17823
17824         gpg: Try to use the passphrase from the primary for --quick-addkey.
17825         + commit 1b460f049e5c1c102d8b55ad28781688252c5a6b
17826         * agent/command.c (cmd_genkey): Add option --passwd-nonce.
17827         (cmd_passwd): Return a PASSWD_NONCE in verify mode.
17828         * g10/call-agent.c (agent_genkey): Add arg 'passwd_nonce_addr' and do
17829         not send a RESET if given.
17830         (agent_passwd): Add arg 'verify'.
17831         * g10/keygen.c (common_gen): Add optional arg 'passwd_nonce_addr'.
17832         (gen_elg, gen_dsa, gen_ecc, gen_rsa, do_create): Ditto.
17833         (generate_subkeypair): Use sepeare hexgrip var for the to be created
17834         for hexgrip feature.  Verify primary key first.  Make use of the
17835         passwd nonce.  Allow for a static passphrase.
17836
17837         gpg: Extend the --quick-gen-key command.
17838         + commit 01285f909e43e8d6a48fbcc77bb5af53d567d8a2
17839         * g10/keygen.c (quickgen_set_para): Add arg 'use'.
17840         (quick_generate_keypair): Add args 'algostr', 'usagestr', and
17841         'expirestr'.  Implement primary only key mode.
17842         (parse_algo_usage_expire): Set NBITS for the default algo.
17843         * g10/gpg.c (main): Extend --quick-gen-key command.
17844
17845         gpg: Improve the new parse_subkey_algostr_usagestr fucntion.
17846         + commit dcc4cd83821667be22e502af86139bb4bd41bdf7
17847         * g10/keygen.c (parse_usagestr): Allow "cert".
17848         (generate_subkeypair): Factor expire parsing out to ...
17849         (parse_subkey_algostr_usagestr): here.  Rename to ...
17850         (parse_algo_usage_expire): this.  Add arg 'for_subkey'.  Set CERT for
17851         primary key and check that it is not set for subkeys.
17852
17853         gpg: New command --quick-addkey.
17854         + commit 8f2a053a0ffa0430d01a53b4d491a3f0fff683eb
17855         * g10/keygen.c (DEFAULT_STD_SUBKEYUSE): New.
17856         (ask_keysize): Factor code out to ...
17857         (get_keysize_range, fixup_keysize): new.
17858         (parse_parameter_usage): Factor parsing out to  ...
17859         (parse_usagestr): new.  Allow use of "encr" as alias for "encrypt".
17860         (parse_subkey_algostr_usagestr): New.
17861         (generate_subkeypair): Add new args.  Implement unattended mode.
17862
17863         * g10/keyedit.c (keyedit_quick_sign): Factor some code out to ...
17864         (find_by_primary_fpr): new.
17865         (keyedit_quick_addkey): New.
17866         * g10/gpg.c (aQuickAddKey): New.
17867         (opts): Add --quick-addkey.
17868         (main): Implement.
17869
17870         gpg: Do not abort on certain invalid packets.
17871         + commit d837f6b0eadb14ea08c1c6030b4d6adaaee8778e
17872         * g10/build-packet.c (write_fake_data): Check for non-opaque data.
17873         * g10/seskey.c (do_encode_md): Return NULL instead of abort.
17874
17875         common: New function openpgp_is_curve_supported.
17876         + commit 072acb69be55e366e2da921e3953404765fa3928
17877         * common/openpgp-oid.c: Include openpgpdefs.h.
17878         (oidtable): Add field pubkey_algo.
17879         (openpgp_is_curve_supported): New.
17880
17881 2016-06-01  NIIBE Yutaka  <gniibe@fsij.org>
17882
17883         g10: Allow User ID length >= 256.
17884         + commit db1ecc8212defdd183abbb6b1407fcc8d2dc9552
17885         * build-packet.c (do_user_id): Call write_header2 with HDRLEN not set.
17886
17887 2016-05-31  Werner Koch  <wk@gnupg.org>
17888
17889         gpg: New status code NOTATION_FLAGS.
17890         + commit 67a4bc8d536f6997f14daff4c039abd48a172100
17891         * common/status.h (STATUS_NOTATION_FLAGS: New.
17892         * g10/packet.h (struct notation): Add flags.human.
17893         (notation_t): New typedef.
17894         * g10/build-packet.c (sig_to_notation): Set flags.human.
17895         * g10/keylist.c (show_notation): Write STATUS_NOTATION_FLAGS.
17896
17897 2016-05-28  Werner Koch  <wk@gnupg.org>
17898
17899         common: Add a status callback to gnupg_exec_tool_stream.
17900         + commit 239a4d53916b47b5b0f0167a9b2c7a8915bb9c52
17901         * common/exectool.h (exec_tool_status_cb_t): New.
17902         * common/exectool.c: Include missing exectool.h.
17903         (read_and_log_buffer_t): Replace array by pointer.
17904         (gnupg_exec_tool_stream): Add args 'status_cb' and 'status_cb_value'.
17905         Change all callers to pass NULL for them.  Malloc buffer for
17906         FDERRSTATE.
17907         (read_and_log_stderr): Implement status_fd feature.
17908
17909 2016-05-27  Werner Koch  <wk@gnupg.org>
17910
17911         common: Allow a second input stream for gnupg_exec_tool_stream.
17912         + commit 44a32455c8e41400ea96db4507c8a42bdb65b3b6
17913         * common/exechelp-posix.c (do_exec): Add arg 'except' and pass to
17914         close_all_fds.
17915         (gnupg_spawn_process): Add arg 'except'.  Change callers to pass NULL
17916         for it.
17917         * common/exechelp-w32.c (gnupg_spawn_process): Add dummy arg 'except'.
17918         * common/exechelp-w32ce.c (gnupg_spawn_process): Ditto.
17919         * common/exectool.c (copy_buffer_do_copy): Allow NULL for SINK.
17920         (gnupg_exec_tool_stream): Add arg 'inextra'. Change callers to pass
17921         NULL for it.  Allow NULL for OUTPUT.
17922
17923         common: Simplify the fd closing patch 512c56a.
17924         + commit e6d9a2d07ed7aeac3944d8a7d1317c4a117356b4
17925         * common/exechelp-posix.c (get_max_fds): Use /proc/self.
17926
17927         common: Speedup closing fds before an exec.
17928         + commit 512c56af43027149e8beacf259746b8d7bf9b1a2
17929         * common/exechelp-posix.c [__linux__]: Include dirent.h.
17930         (get_max_fds) [__linux__]: Return the actual used highest fd.
17931
17932         tools: Improve debug output of rfc822parse.
17933         + commit ad75ca9c963bebbe02aae8d73e199a705764ae82
17934         * tools/rfc822parse.c (show_event): Add missing events.
17935
17936         build: Remove obsolete tests for funopen and fopencookie.
17937         + commit d755bcb89dbeaf6c7c1eca73ccabdf89b536c535
17938         * configure.ac (AC_CHECK_FUNCS): Remove tests for funopen.
17939
17940         common: Extend gnupg_create_inbound_pipe et al.
17941         + commit 5d991e333a1885adc40abd9d00c01fec4bd5d9d7
17942         * common/exechelp-posix.c (gnupg_create_inbound_pipe): Add args 'r_fp'
17943         and 'nonblock'.
17944         (gnupg_create_outbound_pipe): Ditto.
17945         * common/exechelp-w32.c (gnupg_create_inbound_pipe): Add non yet
17946         functional args 'r_fp' and 'nonblock'.
17947         (gnupg_create_outbound_pipe): Ditto.
17948         * common/exechelp-w32ce.c (gnupg_create_inbound_pipe): Ditto.
17949         (gnupg_create_outbound_pipe): Ditto.
17950
17951         common: Make use of default_errsource in exechelp.
17952         + commit 96c7901ec1c79be732570811223d3ea54875abfe
17953         * common/exechelp-posix.c (my_error_from_syserror, my_error): New.
17954         Use them instead of gpg_error and gpg_error_from_syserror.
17955         (create_pipe_and_estream): Remove arg ERRSOURCE and fix use of
17956         OUTBOUND which has a wrong name.  Adjust callers.
17957         (gnupg_spawn_process): Remove arg ERRSOURCE and replace by use of
17958         DEFAULT_ERRSOURCE.
17959         * common/exechelp-w32.c (gnupg_spawn_process): Ditto.
17960         * common/exechelp-w32ce.c (gnupg_spawn_process): Ditto.
17961         * common/exectool.c (gnupg_exec_tool_stream):  Do not pass
17962         GPG_ERROR_FROM_SYSERROR.
17963         * tools/gpgconf-comp.c (gc_component_check_options): Ditto.
17964         (retrieve_options_from_program): Ditto.
17965
17966         gpg: Keep current and total of PROGESS status lines small enough.
17967         + commit 6c957c3d880c069bb843cc58fdcebb9fc344727e
17968         * g10/progress.c (progress_filter): Factor status wrote out to...
17969         (write_status_progress): New.  Scale values down.
17970
17971 2016-05-27  NIIBE Yutaka  <gniibe@fsij.org>
17972
17973         configure: Detection of libusb on FreeBSD.
17974         + commit b3e043ba905fdf2efcdadbd7022ac53f4408b748
17975         * configure.ac (LIBUSB_LIBS): Use LIBUSB_NAME for AC_CHECK_LIB.
17976
17977 2016-05-25  Werner Koch  <wk@gnupg.org>
17978
17979         build: Switch to new URL for swdb.lst.
17980         + commit 74028096e06d2904f77b74b373750264e5b7b1ea
17981
17982
17983 2016-05-24  Werner Koch  <wk@gnupg.org>
17984
17985         gpgtar: Simplify code by using ccparray.
17986         + commit 91bc7833836f19256d56984c94cacf44853ff5c8
17987         * tools/gpgtar-create.c (gpgtar_create): Use ccparray functions.
17988         * tools/gpgtar-extract.c (gpgtar_extract): Ditto.
17989         * tools/gpgtar-list.c (gpgtar_list): Ditto.
17990
17991         common: Add simple dynamic array function.
17992         + commit 2421f7f7ed74ed20372efd63a2efd58d3b55005c
17993         * common/ccparray.c: New.
17994         * common/ccparray.h: New.
17995         * common/t-ccparray.c: New.
17996         * common/Makefile.am (common_sources): Add files.
17997         (module_tests): Add test file.
17998         (t_ccparray_LDADD): New.
17999
18000 2016-05-23  Justus Winter  <justus@g10code.com>
18001
18002         tests: Test the pinentry interactions when exporting keys.
18003         + commit b9d1e099c3ec3163c86afe627ecbe028db1facf6
18004         * tests/openpgp/export.test: Test pinentry interactions.
18005
18006         tests: Add support for a passphrase queue to fake pinentry.
18007         + commit 4994153924e0948a657edddaef54a39a6001beff
18008         * tests/openpgp/fake-pinentry.c (get_passphrase): New function.
18009         (main): Add option --passphrasefile and read passphrases from it.
18010
18011         tests: Add logging to fake pinentry.
18012         + commit 41b10c66ec1dd33633386f4fc8013ddeab7737ca
18013         * tests/openpgp/fake-pinentry.c (log_stream): New variable.
18014         (reply): New function.
18015         (spacep,skip_options,option_value): Copy from common.
18016         (main): Parse arguments, add --logfile option, write logfile.
18017
18018         tests: Add export test.
18019         + commit a54e89a58576108fcae10ceeb4fc65822aecc170
18020         * tests/openpgp/Makefile.am (TESTS): Add new file.
18021         * tests/openpgp/export.test: New file.
18022
18023 2016-05-21  Werner Koch  <wk@gnupg.org>
18024
18025         gpg: Speed up key listing in Tofu mode.
18026         + commit 78bb08425af5b1edb7f3ef0119013529b3a9e4ba
18027         * g10/tofu.c (get_trust): Add arg PK.  Uses this instead of a an extra
18028         lookup of the public key by fingerrpint.
18029         (tofu_register): Pass PK to get_trust.
18030         (tofu_get_validity): Ditto.
18031
18032         *g10/tofu.c (tofu_register): Remove unused FINGERPRINT_PP.
18033
18034         gpg: Avoid name spaces clash with future sqlite versions.
18035         + commit b1ba460d8f3358342c2ee2927114d36e767a439f
18036         * g10/sqlite.c: Rename to gpgsql.c.  Change function prefixes to
18037         gpgsql_.
18038         * g10/sqlite.h: Rename to gpgsql.h.
18039         * g10/tofu.c: Adjust for changes.
18040
18041         gpg: Explicitly close a combined Tofu DB.
18042         + commit 006a6126131ffd59d9a47889ac031f932ecc5d0b
18043         * g10/tofu.c (tofu_closedbs): Close combined DB.
18044
18045         gpg: Store the Tofu meta handle for databases in CTRL.
18046         + commit 754b1c463034a634a678d8efc76c27fd46aad9b9
18047         * g10/gpg.h (struct tofu_dbs_s, tofu_dbs_t): New declarations.
18048         (struct server_control_s): Add field tofu.dbs.
18049         * g10/tofu.c (struct dbs): Rename to tofu_dbs_s.  Replace all users by
18050         by tofu_dbs_t.
18051         (opendbs):  Add arg CTRL.  Cache the DBS in CTRL.
18052         (closedbs): Rename to tofu_closedbs and make global.  Add arg CTRL.
18053         (tofu_register): Add arg CTRL.  Change all callers.  Do not call
18054         closedbs.
18055         (tofu_get_validity): Ditto.
18056         (tofu_set_policy): Ditto.
18057         (tofu_get_policy): Ditto.
18058         (tofu_set_policy_by_keyid): Add arg CTRL.
18059         * g10/gpg.c (gpg_deinit_default_ctrl): Call tofu_closedbs.
18060
18061         gpg: Pass CTRL object down to the trust functions.
18062         + commit 027c4e55522b8e18711a3331932a9869ab89ca26
18063
18064
18065         gpg: Fix the TOFU_STATS_LONG status.
18066         + commit fd973ee1c18aa8fe764e09ba4dff589309b2d78d
18067         * g10/tofu.c (show_statistics): Print TOFU STATS with formatting
18068         characters.
18069
18070 2016-05-19  Werner Koch  <wk@gnupg.org>
18071
18072         gpg: Print "[  never ]" instead of err for validity.
18073         + commit 437c97ab6a34ff1936001dd05209193b4466a81d
18074         * g10/trust.c (uid_trust_string_fixed): Handle NEVER.
18075
18076 2016-05-18  Werner Koch  <wk@gnupg.org>
18077
18078         dirmngr: Adjust the WKD lookup to specs version -01.
18079         + commit cf97769906337d65289ad58225a5ecc53c715550
18080         * dirmngr/server.c (cmd_wkd_get): Remove second occurrence of the
18081         domain part.
18082
18083 2016-05-17  Werner Koch  <wk@gnupg.org>
18084
18085         gpg: Emit new status line KEY_CONSIDERED.
18086         + commit ff71521d9698c7c5df94831a1398e948213af433
18087         * common/status.h (STATUS_KEY_CONSIDERED): New.
18088         * g10/getkey.c: Include status.h.
18089         (LOOKUP_NOT_SELECTED, LOOKUP_ALL_SUBKEYS_EXPIRED): New.
18090         (finish_lookup): Add arg R_FLAGS.  Count expired and revoked keys and
18091         set flag.  Check a requested usage before checking for expiraion or
18092         revocation.
18093         (print_status_key_considered): New.
18094         (lookup): Print new status.
18095
18096 2016-05-11  NIIBE Yutaka  <gniibe@fsij.org>
18097
18098         g10: Fix signature checking.
18099         + commit 83a90a916e8e2f8e44c3b11d11e1dd75f65a87fb
18100         * g10/sig-check.c (check_signature_over_key_or_uid): Fix call to
18101         walk_kbnode.
18102
18103 2016-05-10  Werner Koch  <wk@gnupg.org>
18104
18105         gpg: Allow unattended deletion of secret keys.
18106         + commit ac9ff644b12c4dfa55d466af8ae6af54d1646893
18107         * agent/command.c (cmd_delete_key): Make the --force option depend on
18108         --disallow-loopback-passphrase.
18109         * g10/call-agent.c (agent_delete_key): Add arg FORCE.
18110         * g10/delkey.c (do_delete_key): Pass opt.answer_yes to
18111         agent_delete_key.
18112
18113 2016-05-09  Werner Koch  <wk@gnupg.org>
18114
18115         gpg: Fix buglet in the check_all_keysigs function.
18116         + commit 693838f0125d5d0c963fa3771b1bd117702af697
18117         * g10/keyedit.c (sig_comparison): Actually compare the pubkey
18118         algorithms.
18119
18120         gpg: Request a "save" after cmd "check" fixed something.
18121         + commit d33b35f7481caa0dcb25f9fa7d6c5bb27895297a
18122         * g10/keyedit.c (keyedit_menu) <cmdCHECK>: Set modified.
18123
18124 2016-05-09  NIIBE Yutaka  <gniibe@fsij.org>
18125
18126         po: Update Japanese translation.
18127         + commit ff870d59f067d3c5415e231c02a50d5dceac7e48
18128
18129
18130 2016-05-04  Werner Koch  <wk@gnupg.org>
18131
18132         Release 2.1.12.
18133         + commit 00df5b1236cac5c7a48638a4613278c5aab486f8
18134
18135
18136         speedo,w32: Remove the installation directory page.
18137         + commit fb1e9df48465c2f77a65dddd257572fdc79d9450
18138         * build-aux/speedo/w32/inst.nsi (MUI_PAGE_DIRECTORY): Remove.
18139
18140         gpg: Fix const char pointer mismatch with gettext.
18141         + commit 920b1421b35d1404b8360bd8feac0be659840543
18142         * g10/tofu.c (get_trust): Use const char *.
18143
18144         speedo: Build sqlite with static-libgcc.
18145         + commit edce430b039b313cc2d79402a7bd21347490c3be
18146         * build-aux/speedo/patches/sqlite.patch: New.
18147         * Makefile.am (EXTRA_DIST): Add file.
18148
18149         speedo: Also try patch files w/o version number.
18150         + commit 9ea258fa5b45bb5454ee3f5906df5d5eebdec0dd
18151         * build-aux/speedo.mk (SPKG_template): Try such a patch file.
18152
18153 2016-05-04  Andre Heinecke  <aheinecke@intevation.de>
18154
18155         speedo,w32: Install sqlite.
18156         + commit 2b78223d7587c68e2e27a3d7b365219228da7947
18157         * build-aux/speedo/w32/inst.nsi (-sqlite, -un.sqlite): New.
18158
18159         speedo,w32: Fix uninstallation.
18160         + commit 5ec76fd0c300b52366cf8d1407fe1c8de3a8a9d4
18161         * build-aux/speedo/w32/inst.nsi (-un.gnupg): Delete distsigkey and
18162         dirmngr-conf.skel
18163
18164         speedo,w32: Install localisation.
18165         + commit 3f58fc64666101e160e9b13fedb6cdaebeb91a7a
18166         * build-aux/speedo/w32/inst.nsi (-libgpg-error, GnuPG): Install l10n.
18167         (-un.libgpg-error, -un.gnupg): Uninstall l10n files.
18168
18169 2016-05-04  Werner Koch  <wk@gnupg.org>
18170
18171         tests: Disable the migrations tests.
18172         + commit d696eb396a9c88319358da4333feb653994d5408
18173         * tests/Makefile.am (SUBDIRS): Remove migrations.
18174         * configure.ac (AC_CONFIG_FILES): Remove migrations Makefile.
18175
18176 2016-05-04  Ineiev  <ineiev@gnu.org>
18177
18178         po: Update Russian translation.
18179         + commit 4fd13ab78dd228d8ff85659cddc2076af8728ebe
18180
18181
18182 2016-05-04  Werner Koch  <wk@gnupg.org>
18183
18184         po: Update German translation.
18185         + commit 75f31cdd42eed3555952ac478055d52af841f702
18186
18187
18188         Some minor string changes and fixed a printf format.
18189         + commit d00625dae60f26617d2e1bd4f22c6b35a4e92c91
18190         * g10/build-packet.c (notation_value_to_human_readable_string): Use
18191         %zu for size_t.
18192
18193         build: Update config.{guess,sub} to 2016-04-02 and 2016-03-30.
18194         + commit 04cc7c3786d91881f83a72799dab058476602a31
18195         * build-aux/config.guess: Update.
18196         * build-aux/config.sub: Update.
18197
18198         agent: Make --allow-loopback-pinentry the default.
18199         + commit 3ef0938cfd8637e9801369f142eb8dd564f2ca61
18200         * agent/gpg-agent.c (oNoAllowLoopbackPinentry): New.
18201         (opts): Add --no-allow-loopback-pinentry.  Hide
18202         description of --allow-loopback-pinentry.
18203         (parse_rereadable_options): Set opt.allow_loopback_pinentry by
18204         default.
18205         (main): Replace allow-loopback-pinentry by no-allow-loopback-pinentry
18206         in the gpgconf list.
18207         * tools/gpgconf-comp.c (gc_options_gpg_agent): Ditto.
18208
18209 2016-05-03  Werner Koch  <wk@gnupg.org>
18210
18211         common: Print https URLs in help messages.
18212         + commit 9e28617e260261de3972c20698b5a01561330e1c
18213         * common/argparse.c (strusage): Print https URLS.
18214
18215         tests: Silence output of some tests.
18216         + commit 33aacc3d4bbd6a82d7e7ceca058970879741b7da
18217         * common/t-exechelp.c (print_open_fds): Silence non-verbose output.
18218         (test_close_all_fds): Ditto.
18219         * common/t-session-env.c (show_stdnames): Indent output.
18220         * g10/test.c (TEST): Silence non-verbose okay output.
18221         (exit_tests): Ditto.
18222         * tools/gpg-zip.in (tar_verbose_opt): Add option --quiet.
18223         * tests/openpgp/gpgtar.test (GPGZIP): Pass option --quiet.
18224         * tests/openpgp/mds.test: Indent MD5 notice.
18225         * tests/openpgp/version.test: Indent --version output.
18226
18227         gpg: Emit status lines TOFU_STATS and TOFU_STATS_LONG.
18228         + commit 83865be35cff5355a5c4575cc3b50609819b0baa
18229         * g10/tofu.c (NO_WARNING_THRESHOLD): Rename to BASIC_TRUST_THRESHOLD.
18230         (FULL_TRUST_THRESHOLD): New.
18231         (write_stats_status): New.
18232         (show_statistics): Call new function.  Print TOFU_STATS_LONG.
18233
18234 2016-05-02  Werner Koch  <wk@gnupg.org>
18235
18236         gpg: Extend TRUST_foo status lines with the trust model.
18237         + commit ae1889320b822d48f7118a29391605e9ac992701
18238         * g10/trustdb.h (TRUST_FLAG_TOFU_BASED): New.
18239         * g10/trustdb.c (trust_model_string): Lowercase the strings.  Add arg
18240         "model" and change callers to call with OPT.TRUST_MODEL.
18241         * g10/tofu.c (tofu_wot_trust_combine): Set TRUST_FLAG_TOFU_BASED.
18242         * g10/pkclist.c (write_trust_status): New.
18243         (check_signatures_trust): Call new function.
18244
18245         gpg: Improve line wrapping for a tofu message.
18246         + commit 5cef6118580fe658a27d32e85696d88775ad417a
18247         * g10/tofu.c (time_ago_str): Mark non-breakable spaces.
18248         (show_statistics): Remove marks.
18249
18250         gpg: Re-format some tofu messages.
18251         + commit d73e83c3b678add11a5754e199e528aeb39ec8ce
18252         * common/status.h (STATUS_TOFU_USER, STATUS_TOFU_STATS)
18253         (STATUS_TOFU_STATS_SHORT, STATUS_TOFU_STATS_LONG): New.
18254         * g10/tofu.c (NO_WARNING_THRESHOLD): New.
18255         (record_binding, tofu_register): Take care of --dry-run.
18256         (show_statistics): Print STATUS_TOFU_USER.  Reformat some messages.
18257         Fix the ngettext/strcmp thing.  Use log_string instead of log_info.
18258         Use NO_WARNING_THRESHOLD constant.
18259         (get_trust): Use format_text and print a compact fingerprint.
18260
18261 2016-05-02  NIIBE Yutaka  <gniibe@fsij.org>
18262
18263         scd: More fix of error return path.
18264         + commit 6677d8b61446eb5760a30a2488c992d6e895a9ed
18265         * scd/command.c (open_card): Return GPG_ERR_ENODEV on the failure of
18266         apdu_connect.
18267
18268 2016-04-29  Werner Koch  <wk@gnupg.org>
18269
18270         common: Extend log_string to indent lines.
18271         + commit 35f4b6aafdf1889ed1ae569af5852f47738fe993
18272         * common/logging.c (do_logv): Add indentation when called via
18273         log_string.
18274
18275         gpg: Factor some code code out of tofu.c.
18276         + commit dcad99c98616a6031ddfde313c920339e4012378
18277         * g10/tofu.c (string_to_long): New.
18278         (string_to_ulong): New.
18279         (get_single_unsigned_long_cb): Replace strtol/strtoul by new function.
18280         (get_single_long_cb): Ditto.
18281         (signature_stats_collect_cb):  Ditto.
18282         (get_policy): Ditto.
18283         (show_statistics): Ditto.  Uese es_free instead of free.
18284
18285         gpg: Remove all assert.h and s/assert/log_assert/.
18286         + commit 64bfeafa52a5ed3fa82bdc0ce7ef0edddeef188c
18287
18288
18289         common: Improve log_assert.
18290         + commit 9740dff9f4d18ba764dc7173d4902e94e3f0c2e8
18291         * common/logging.c (bug_at): Do not i18n the string.
18292         (_log_assert): New.
18293         * common/logging.h (log_assert): Use new function and pass line
18294         information.
18295
18296 2016-04-28  NIIBE Yutaka  <gniibe@fsij.org>
18297
18298         scd: Fix error return path.
18299         + commit cb4fee8bb645745ff199f7428e19226d5bc63dab
18300         * scd/ccid-driver.c (bulk_in): Remove EAGAIN handling.
18301         Handle LIBUSB_ERROR_NO_DEVICE to return CCID_DRIVER_ERR_NO_READER.
18302
18303 2016-04-27  NIIBE Yutaka  <gniibe@fsij.org>
18304
18305         scd: Fix memory leaks.
18306         + commit 508b0deb70d39d388149be9a63fab24cc956a239
18307         * scd/ccid-driver.c (scan_or_find_usb_device): Return on
18308         LIBUSB_ERROR_NO_MEM.  Free CONFIG before return except on error.
18309         (scan_or_find_devices): Free device list.
18310
18311 2016-04-27  Werner Koch  <wk@gnupg.org>
18312
18313         gpg: Add experimental AKL method "wkd" and option --with-wkd-hash.
18314         + commit 87de9e19edf0311ca0342e15ef44ebe40e32861e
18315         * g10/getkey.c (parse_auto_key_locate): Add method "wkd".
18316         (get_pubkey_byname): Implement that method.  Also rename a variable.
18317         * g10/call-dirmngr.c (gpg_dirmngr_wkd_get): New.
18318         * g10/keyserver.c (keyserver_import_wkd): New.
18319         * g10/test-stubs.c (keyserver_import_wkd): Add stub.
18320         * g10/gpgv.c (keyserver_import_wkd): Ditto.
18321         * g10/options.h (opt):  Add field 'with_wkd_hash'.
18322         (AKL_WKD): New.
18323
18324         * g10/gpg.c (oWithWKDHash): New.
18325         (opts): Add option --with-wkd-hash.
18326         (main): Set that option.
18327         * g10/keylist.c (list_keyblock_print): Implement that option.
18328
18329         dirmngr: Add experimental command WKD_GET.
18330         + commit c83c6f212e9bc98a9ea8dd8102bc16edd1a03050
18331         * dirmngr/server.c (cmd_wkd_get): New.
18332         (register_commands): Add command WKD_GET.
18333
18334         dirmngr: Use system provided root CAs with KS_FETCH.
18335         + commit c3aeda82b8d00b87a5af72b4075c487c10dfdf6b
18336         * dirmngr/ks-engine-http.c (ks_http_fetch): Use HTTP_FLAG_TRUST_SYS.
18337
18338 2016-04-26  Werner Koch  <wk@gnupg.org>
18339
18340         http: Allow to request system defined CAs for TLS.
18341         + commit fd765df6a7883c3d841abeb657330a1aab4b7756
18342         * dirmngr/http.h (HTTP_FLAG_TRUST_DEF, HTTP_FLAG_TRUST_SYS): New.
18343         * dirmngr/http.c (http_session_new): Add arg "flags".
18344         * dirmngr/ks-engine-hkp.c (send_request): Use new flag
18345         HTTP_FLAG_TRUST_DEF for the new arg of http_session_new.
18346         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
18347         * dirmngr/t-http.c (main): Ditto.
18348
18349 2016-04-25  Werner Koch  <wk@gnupg.org>
18350
18351         common: Minor fixes for the new private-keys.c.
18352         + commit b7fa4960c292ef1a290d32b7f46bb741bbfc0923
18353         * common/private-keys.c (my_error_from_syserror): New.  Use it in
18354         place of gpg_error_from_syserror.
18355         (_pkc_add, pkc_lookup, pke_next_value): Use ascii_strcasecmp.
18356         (pkc_parse): Use xtrystrdup and append_to_strlist_try as intended.
18357
18358         (_pkc_add): Add braces around if-statement.
18359
18360         common: Use new function to print a failure of xtrymalloc.
18361         + commit 8776abbe02935e720018f3ef6ffd48f21435ff8b
18362         * common/miscellaneous.c (xoutofcore): New.
18363         * common/strlist.c (append_to_strlist): Use instead of abort.
18364         (append_to_strlist_try): Use xtrymalloc instead of xmalloc.
18365
18366 2016-04-21  Justus Winter  <justus@g10code.com>
18367
18368         common: Add support for the new extended private key format.
18369         + commit 12af2630cf4d1a39179179925fac8f2cce7504ff
18370         * agent/findkey.c (write_extended_private_key): New function.
18371         (agent_write_private_key): Detect if an existing file is in extended
18372         format and update the key within if it is.
18373         (read_key_file): Handle the new format.
18374         * agent/keyformat.txt: Document the new format.
18375         * common/Makefile.am: Add the new files.
18376         * common/private-keys.c: New file.
18377         * common/private-keys.h: Likewise.
18378         * common/t-private-keys.c: Likewise.
18379         * common/util.h (alphap, alnump): New macros.
18380         * tests/migrations: Add test demonstrating that we can cope with the
18381         new format.
18382
18383         common: Add 'free_strlist_wipe' which wipes memory.
18384         + commit c6d1f2f08c68efe7e80887219064a8ce6365128f
18385         * common/strlist.c (free_strlist_wipe): New function.
18386         * common/strlist.h (free_strlist_wipe): New prototype.
18387
18388         common: Add 'append_to_strlist_try' which can fail.
18389         + commit 95303ee11df12f284e98d02dba993eda9e425383
18390         * common/strlist.c (append_to_strlist): Use the new function.
18391         (append_to_strlist_try): New function.
18392         * common/strlist.h (append_to_strlist_try): New prototype.
18393
18394         agent: Convert key format document to org.
18395         + commit 342cc488890241b41e49f50886617115342721d6
18396         * agent/keyformat.txt: Convert to org mode.
18397
18398         tests: Make migration test more robust and silent.
18399         + commit 0c35e09278514f1e3377a4b0a9b1f44dd39b1bf4
18400         * tests/migrations/from-classic.test: Fix in-tree build, silence test.
18401
18402 2016-04-21  Werner Koch  <wk@gnupg.org>
18403
18404         w32: Use --enable-gpg2-is-gpg by default.
18405         + commit d81de224ecd542922dda649a492dd9550509d7bc
18406         * autogen.rc: Add option also for plain Windows.
18407
18408         w32: Replace libiconv DLL by iconv feature of libgpg-error.
18409         + commit bd4d65615b3a5360d455b99e77bd113ad90f1539
18410         * configure.ac: Do nor require libiconv for W32.
18411         * common/utf8conv.c [W32]: Do not incluce iconv.h.  Request
18412         libgpg-error iconv macros.
18413         (jnlib_iconv): Use ICONV_CONST macro.
18414         * build-aux/speedo/w32/inst.nsi [!WITH_GUI]: Do not install libiconv.
18415         * build-aux/speedo.mk (speedo_spkgs) [!WITH_GUI]: Likewise.
18416
18417 2016-04-20  Justus Winter  <justus@g10code.com>
18418
18419         agent: Sanitize permissions of the private key directory.
18420         + commit f8adf1a3234655877a4f985d627d98567507002c
18421         * agent/gpg-agent.c (create_private_keys_directory): Set permissions.
18422         * common/sysutils.c (modestr_to_mode): New function.
18423         (gnupg_mkdir): Use new function.
18424         (gnupg_chmod): New function.
18425         * common/sysutils.h (gnupg_chmod): New prototype.
18426         * tests/migrations/from-classic.test: Test migration with existing
18427         directory.
18428
18429         tests: Test the migration from a classic GnuPG home directory.
18430         + commit defbc70b4a16264e067daf76678ecfb9d030dee4
18431         * configure.ac: Add new directory.
18432         * tests/Makefile.am (SUBDIRS): Likewise.
18433         * tests/migrations/Makefile.am: New file.
18434         * tests/migrations/from-classic.gpghome/pubring.gpg.asc: Likewise.
18435         * tests/migrations/from-classic.gpghome/secring.gpg.asc: Likewise.
18436         * tests/migrations/from-classic.gpghome/trustdb.gpg.asc: Likewise.
18437         * tests/migrations/from-classic.test: Likewise.
18438
18439 2016-04-20  Werner Koch  <wk@gnupg.org>
18440
18441         speedo: Use swdb.lst to define the SQLite version.
18442         + commit 2385b9f1ddc4938e45c01a12a804f4b77d253305
18443         * build-aux/speedo.mk: Change sqlite to use our mirror and the
18444         swdb.lst file.
18445         * build-aux/speedo/w32/inst.nsi: gpg is now build and installed as
18446         gpg.
18447
18448 2016-04-19  Werner Koch  <wk@gnupg.org>
18449
18450         gpg: Improve UID selction of --quick-sign-key.
18451         + commit d02de6c0a4a55a2720cfa5caddcbfc4ce988a2ec
18452         * g10/keyedit.c (keyedit_quick_sign): Improve UID selection and print
18453         error for non-found userids.
18454
18455         gpg: Avoid debug like output at start of --edit-key.
18456         + commit 085b19fc9aa7f2f9b82a97824b117e71390964ec
18457         * g10/keyedit.c (check_all_keysigs): Print info only after something
18458         has been modified.
18459
18460 2016-04-15  Andre Heinecke  <aheinecke@intevation.de>
18461
18462         dirmngr: Fix https never reported in general help.
18463         + commit 6272f24312f2efe8707a7712858c85cd5a42e6fa
18464         * dirmngr/ks-engine-http.c (ks_hkp_help): Also print https
18465         when supported and no uri provided.
18466
18467         dirmngr: Fix https incorrectly reported in help.
18468         + commit a0642856b25622c81d3464979c47ff2a30af58fa
18469         * dirmngr/ks-engine-http.c (ks_hkp_help): Only print https if tls
18470         is supported.
18471
18472 2016-04-14  Werner Koch  <wk@gnupg.org>
18473
18474         agent: Fix regression due to recent commit 4159567.
18475         + commit 8c3fb2360f154a971d2a390e4937acb22a44a8c2
18476         * agent/protect.c (do_encryption): Fix CBC hashing.
18477
18478         agent: Allow gpg-protect-tool to handle openpgp-native protection.
18479         + commit 6df75ec70afeb1a5ad9a00557e1245e1514c37b5
18480         * agent/protect-tool.c (read_and_unprotect): Add arg ctrl and pass to
18481         agent_unprotect.
18482         (main): Allocate a simple CTRL object and pass it to
18483         read_and_unprotect.
18484         (convert_from_openpgp_native): Remove stub.
18485         (agent_key_available, agent_get_cache): New stubs.
18486         (agent_askpin): New emulation for the one in call-pinentry.c.
18487         (agent_write_private_key): New to dump key.
18488         * agent/Makefile.am (gpg_protect_tool_SOURCES): Add cvt-openpgp.c
18489
18490         tests: Set fake-pinentry's stdout and stdin to _IOLBF.
18491         + commit 94504b3d5af126abb591dedda1ca0f0970822f55
18492         * tests/openpgp/fake-pinentry.c (main): Call setvbuf.  Show passphrase
18493         at startup.  Increase buffer.
18494
18495 2016-04-12  Werner Koch  <wk@gnupg.org>
18496
18497         agent: Implement new protection mode openpgp-s2k3-ocb-aes.
18498         + commit 4159567f7ed7a1139fdc3a6c92988e1648ad84ab
18499         * agent/protect.c (agent_protect): Add arg use_ocb.  Change all caller
18500         to pass -1 for default.
18501         * agent/protect-tool.c: New option --debug-use-ocb.
18502         (oDebugUseOCB): New.
18503         (opt_debug_use_ocb): New.
18504         (main): Set option.
18505         (read_and_protect): Implement option.
18506
18507         * agent/protect.c (OCB_MODE_SUPPORTED): New macro.
18508         (PROT_DEFAULT_TO_OCB): New macro.
18509         (do_encryption): Add args use_ocb, hashbegin, hashlen, timestamp_exp,
18510         and timestamp_exp_len.  Implement OCB.
18511         (agent_protect): Change to support OCB.
18512         (do_decryption): Add new args is_ocb, aadhole_begin, and aadhole_len.
18513         Implement OCB.
18514         (merge_lists): Allow NULL for sha1hash.
18515         (agent_unprotect): Change to support OCB.
18516         (agent_private_key_type): Remove debug output.
18517
18518         indent: Help Emacs not to get confused by conditional compilation.
18519         + commit 7faf131c8b8710419df3dc13a1228d1977c55f53
18520         * agent/protect.c (calibrate_get_time) [W32]: Use separate function
18521         calls for W32 and W32CE.
18522
18523 2016-04-07  Justus Winter  <justus@g10code.com>
18524
18525         g10: Fix exporting secret keys of certain sizes.
18526         + commit 02cf1357dd5ee34a57371f55b9d312b8b9e3a7e8
18527         * g10/build-packet.c (do_key): Do not use the header length specified
18528         by the public key packet from the keyring, but let 'write_header2'
18529         compute the required length.
18530
18531 2016-04-06  Justus Winter  <justus@g10code.com>
18532
18533         Revert "g10: Support armored keyrings in gpgv."
18534         + commit 76ca869197e304daa5a8dd96ea43113ec7b28354
18535         This reverts commit abb352de51bc964c06007fce43ed6f6caea87c15.
18536
18537 2016-04-05  Justus Winter  <justus@g10code.com>
18538
18539         dirmngr: Autodetect PEM format in dirmngr-client.
18540         + commit 9354293b8c9f234939bc04182f15e2fe512e914e
18541         * dirmngr/dirmngr-client.c (init_asctobin): New function.
18542         (main): Move the initialization code to the new function.
18543         (read_pem_certificate): Initialize base64 table.
18544         (read_certificate): Try to decode certificates given in files as PEM
18545         first.
18546
18547 2016-04-05  Werner Koch  <wk@gnupg.org>
18548
18549         build: Fix for: Build gpgcompose only in maintainer mode.
18550         + commit f45ed07a0fffa3adbc75b9d5726108a066927599
18551         * g10/Makefile.am (noinst_PROGRAMS): Always add module_tests.
18552
18553         doc: Install gpg and gpgv man pages under the correct name.
18554         + commit 4dc4fb1c14b3096bb1cdc5923c0d1eb419036805
18555         * doc/mkdefsinc.c (main): Add double include guard.  Set variable
18556         gpgtwohack. Define macros gpgname and gpgvname.
18557         * doc/gpg.texi: Remove macro definition for gpgname.  Use Texinfo var
18558         gpgtwohack to prepare the man pages.  Use @gpgname everywhere.
18559         * doc/gpgv.texi: Likewise.
18560         * doc/Makefile.am (myman_pages): Remove gpg2.1 and gpgv2.1 but add
18561         them depending on USE_GPG2_HACK.
18562
18563         build: Build gpgcompose only in maintainer mode.
18564         + commit 4b5341dc333983a15f649601fdddc42ba9161433
18565         * g10/Makefile.am (noinst_PROGRAMS): Add gpgcompose only in maintainer
18566         mode.
18567
18568         gpg: Replace use of "gpg2" by GPG_NAME.
18569         + commit 7b58a1118d98543ed6854447d7b403877638ba54
18570
18571
18572 2016-04-04  Werner Koch  <wk@gnupg.org>
18573
18574         Now build "gpg" binary but install as "gpg2"
18575         + commit 96bcd4220f1f1313afe12097d8dc62342ac8de0d
18576         * configure.ac (USE_GPG2_HACK): New ac_define am_conditional.
18577         * common/homedir.c (gnupg_module_name): Replace use of macro
18578         NAME_OF_INSTALLED_GPG.
18579         * g10/keygen.c (generate_keypair): Ditto.
18580         * g10/Makefile.am (bin_PROGRAMS): Remove.
18581         (noinst_PROGRAMS): Add gpg or gpg2 and gpgv or gpg2.
18582         (gpg2_hack_list): New.
18583         (use_gpg2_hack): New.
18584         (gpg2_SOURCES): Rename to gpg_SOURCES.
18585         (gpgv2_SOURCES): Rename to gpgv_SOURCES.
18586         (gpg2_LDADD): Rename to gpg_LDADD.
18587         (gpgv2_LDADD): Rename to gpgv_LDADD.
18588         (gpg2_LDFLAGS): Rename to gpg_LDFLAGS.
18589         (gpgv2_LDFLAGS): Rename to gpgv2_LDFLAGS.
18590         (install-exec-hook): Remove WinCE specific rules and add new rules.
18591         (uninstall-local): Uninstall gpg/gpg2 and gpgv/gpgv2.
18592         * tests/openpgp/Makefile.am (required_pgms): s/gpg2/gpg/.
18593         * tests/openpgp/defs.inc: Ditto.
18594         * tests/openpgp/gpgtar.test: Ditto.
18595         * tests/openpgp/mkdemodirs: Ditto.
18596         * tests/openpgp/signdemokey: Ditto.
18597
18598         * Makefile.am (DISTCHECK_CONFIGURE_FLAGS): Remove obsolete
18599         --enable-mailto, add --enable-gpg2-is-gpg.
18600
18601         tests: Add missing file.
18602         + commit c6ed863491ec3a1e0fcf9cbe2c93c87468306c29
18603         * tests/openpgp/Makefile.am (TEST_FILES): Add plain-largeo.asc.
18604
18605 2016-04-04  Justus Winter  <justus@g10code.com>
18606
18607         g10: Support armored keyrings in gpgv.
18608         + commit abb352de51bc964c06007fce43ed6f6caea87c15
18609         * doc/gpgv.texi: Document the feature.
18610         * g10/Makefile.am (gpgv2_SOURCES): Add dearmor.c.
18611         * g10/dearmor.c (dearmor_file): Add sink argument.
18612         * g10/gpg.c (main): Adapt accordingly.
18613         * g10/gpgv.c (make_temp_dir): New function.
18614         (main): De-armor keyrings.
18615         * g10/main.h (dearmor_file): Adapt prototype.
18616
18617         tests: Fix default key test.
18618         + commit dd5902cc45bae7582f8a0bc91a0a7f4d8ae45d8c
18619         * tests/openpgp/default-key.test: Avoid using the option
18620         '--trust-model' unconditionally.
18621
18622 2016-04-01  Justus Winter  <justus@g10code.com>
18623
18624         build: Check for conflicting trust model options.
18625         + commit 6060ea898fda499211c9d5030fff41d58f899fb0
18626         * configure.ac: Disable TOFU if configured without trust models, and
18627         check for conflicting options.
18628
18629         g10: Remove option --always-trust if compiled without trust models.
18630         + commit b74185b6eaeaae4754726ff203e11977777f568c
18631         * g10/gpg.c (opts): Remove option --always-trust if compiled without
18632         trust models.
18633
18634 2016-03-31  Justus Winter  <justus@g10code.com>
18635
18636         speedo,w32: Build libsqlite3.
18637         + commit e7171f559590422cc52dbcb8d78d94569b31012f
18638         * build-aux/speedo.mk (speedo_spkgs): Add libsqlite3 on w32.
18639         (libsqlite3_ver): New variable.
18640         (speedo_pkg_libsqlite3_tar): Likewise.
18641
18642         g10: Use gpg-error abstraction of sched_yield.
18643         + commit 8be9dab2dd2f83ca922c01542c63b404e34bdfd9
18644         * g10/tofu.c (begin_transaction): Use 'gpgrt_yield'.
18645
18646 2016-03-29  Werner Koch  <wk@gnupg.org>
18647
18648         gpg: Fix NULL-segv for missing tofu DB.
18649         + commit e2c5781788f765815532410a77077ddbb72513e9
18650         * g10/tofu.c (opendb): Guard call to timeout function.
18651
18652 2016-03-22  Werner Koch  <wk@gnupg.org>
18653
18654         gpg: Improve message when asking for key capabilities.
18655         + commit fc30c079a348436868968850dabf653b91f82419
18656         * g10/keygen.c (ask_key_flags): Improve message.
18657
18658         gpg: Remove the extra prompt for Curve25519.
18659         + commit 7f919063d3e426104fe58ae779a9a066140014c1
18660         * g10/keygen.c (MY_USE_ECDSADH): New macro local to ask_curve.
18661         (ask_curve): Use a fixed table of curve names and reserve a slot for
18662         Curve448.  Simplify CurveNNNN/EdNNNN switching.
18663         (ask_curve): Remove the Curve25519 is non-standard prompt.
18664
18665 2016-03-19  Werner Koch  <wk@gnupg.org>
18666
18667         gpg: Silence trustdb computation with --quiet.
18668         + commit af9a4afbf0b518c8acff98e50135b2beb6c722c3
18669         * g10/trustdb.c (validate_keys): Do not print log_info stuff in quiet
18670         mode.
18671
18672 2016-03-17  Werner Koch  <wk@gnupg.org>
18673
18674         sm: Always create a keybox header when creating a new keybox.
18675         + commit 1aad5c6277ea3852ff57bbf680f61c9136ce4d5c
18676         * sm/keydb.c (maybe_create_keybox): Create the header blob.
18677
18678 2016-03-17  Neal H. Walfield  <neal@g10code.com>
18679
18680         doc: Improve documentation of --enable-large-rsa.
18681         + commit 1dc7f55a4095ee42ce2d8c3eb41b7162edf2ca2e
18682         * doc/gpg.texi (--enable-large-rsa): Improve text.
18683
18684 2016-03-17  NIIBE Yutaka  <gniibe@fsij.org>
18685
18686         agent: allow removal of the shadowed key.
18687         + commit 8588c2dbc4c4d1b53796f3dbe8489b932dca7a60
18688         * agent/findkey.c (agent_delete_key): Remove the key when asked.
18689
18690 2016-03-16  NIIBE Yutaka  <gniibe@fsij.org>
18691
18692         g10: Add const qualifier.
18693         + commit b752d2c93778e6a1c1de3eddf8fc725b0ddd354e
18694         * g10/gpgcompose.c (show_help): Those are strings not to be modified.
18695
18696 2016-03-15  Werner Koch  <wk@gnupg.org>
18697
18698         gpg: Do not rely on a certain evaluation order.
18699         + commit 60b34f96f4f390670462d719c0d797e622cee4d4
18700         * g10/keyedit.c (print_and_check_one_sig): Call check_key_signature
18701         before derefing IS_SELFSIG.
18702
18703 2016-03-14  Werner Koch  <wk@gnupg.org>
18704
18705         scd: Add manufacturer id 0x000a.
18706         + commit 834b84c0ee4990393daa5e44afbab5b0aaed0758
18707         * g10/card-util.c (get_manufacturer): Add it.
18708
18709 2016-03-10  Kevin J. McCarthy  <kevin@8t8.us>
18710
18711         g10: Silence message if --quiet is given.
18712         + commit 4f578cb2fc192f44070bb0d18dffaa3863ed0d92
18713         * g10/getkey.c (parse_def_secret_key): Silence message if --quiet is
18714         given.
18715
18716 2016-03-08  Neal H. Walfield  <neal@g10code.com>
18717
18718         gpg: Add a new test.
18719         + commit b17577eac6b7599a4bab6fd3ecb04715aa01367c
18720         * g10/Makefile.am (EXTRA_DIST): Add t-stutter-data.asc.
18721         (module_tests): Add t-stutter.
18722         (t_stutter_SOURCES): New variable.
18723         (t_stutter_LDADD): New variable.
18724
18725 2016-03-07  Justus Winter  <justus@g10code.com>
18726
18727         sm: Implement pinentry loopback and reading passphrases from fd.
18728         + commit eea139c56ef55081d8cd8df2a35ce507386e0f17
18729         * doc/gpgsm.texi: Document '--pinentry-mode' and '--passphrase-fd'.
18730         * sm/Makefile.am (gpgsm_SOURCES): Add new files
18731         * sm/call-agent.c (struct default_inq_parm_s): New definition.
18732         (start_agent): Pass in the pinentry mode.
18733         (default_inq_cb): Handle 'PASSPHRASE' and 'NEW_PASSPHRASE' inquiries.
18734         Adapt all call sites to the new callback cookie.
18735         * sm/gpgsm.c (cmd_and_opt_values): Add new values.
18736         (opts): Add new options.
18737         (main): Handle new options.
18738         * sm/gpgsm.h (struct opt): Add field 'pinentry_mode'.
18739         * sm/passphrase.c: New file.
18740         * sm/passphrase.h: Likewise.
18741
18742         sm: Remove unused argument '--fixed-passphrase'.
18743         + commit 53ed98eda77ff2dcf390cebd0cec9f2665661863
18744         * doc/gpgsm.texi: Drop description.
18745         * sm/gpgsm.c (cmd_and_opt_values): Drop enum value.
18746         (opts): Drop argument.
18747         (main): Drop argument handling.
18748         * sm/gpgsm.h (struct opt): Drop field 'fixed_passphrase'.
18749
18750         kbx: Avoid undefined behavior.
18751         + commit a68ca5a90457ac97eee4efd7fdea596d27c54697
18752         * kbx/keybox-file.c (_keybox_read_blob2): Cast to unsigned int before
18753         shifting.
18754
18755 2016-03-07  NIIBE Yutaka  <gniibe@fsij.org>
18756
18757         scd: Bug fix for a device with multiple interfaces.
18758         + commit 7a32f87cccddb40521bfdd4eb2d0dc9c88fb3fe5
18759         * scd/ccid-driver.c (scan_or_find_usb_device): Use IFC_NO when
18760         accessing interface information.
18761
18762 2016-03-04  Justus Winter  <justus@g10code.com>
18763
18764         build: Make libusb a hard requirement if the ccid driver is requested.
18765         + commit e997552161b2dd8aabf350adee14e208e1545aef
18766         * configure.ac: Print an error message and die if the internal ccid
18767         driver is requested but no suitable libusb is found.
18768
18769         g10: Drop superfluous declaration.
18770         + commit 1e4b7823008daea1a22a6f0f9b379fdec37a4cd4
18771         * g10/main.h (disable_core_dumps): Drop declaration.
18772
18773         g10: Guard code against errors.
18774         + commit 40f6529ceeea806fc011135a9fa3a3590a9534ac
18775         * g10/keygen.c (do_generate_keypair): Check for errors, in which case
18776         'pri_psk' is NULL.
18777
18778 2016-03-03  Justus Winter  <justus@g10code.com>
18779
18780         dirmngr: Add more missing CFLAGS.
18781         + commit 9f0ba5089e664447c36cee3d9249f95e4ea39957
18782         * dirmngr/Makefile.am (t_ldap_parse_uri_CFLAGS): Add
18783         'GCRYPT_CFLAGS'.
18784         (t_dns_stuff_CFLAGS): Likewise.
18785
18786         tests/openpgp: Skip gpgtar test if it has not been built.
18787         + commit a883d4c0f8125e809c144ec69e76c9f522102d8f
18788         * tests/openpgp/gpgtar.test: Check if executable exists.
18789
18790 2016-03-02  Neal H. Walfield  <neal@g10code.com>
18791
18792         gpg: Add new program gpgcompose.
18793         + commit d040628ddf2c09ddc9581ff365680a568ad24278
18794         * g10/packet.h: Include "util.h".
18795         * g10/encrypt.c (encrypt_seskey): Don't mark as static.
18796         * g10/gpgcompose.c: New file.
18797         * g10/Makefile.am (noinst_PROGRAMS): Add gpgcompose.
18798         (gpg2_SOURCES): Split everything but gpg.c into...
18799         (gpg_sources): ... this new variable.
18800         (gpgcompose_SOURCES): New variable.
18801         (gpgcompose_LDADD): Likewise.
18802         (gpgcompose_LDFLAGS): Likewise.
18803
18804         gpg: More robustly detect valid non-armored OpenPGP messages.
18805         + commit 605276ef8cd449bfd574ae6c498fa5d7d265c5c7
18806         * g10/armor.c (is_armored): More robustly detect valid non-armored
18807         OpenPGP messages.
18808
18809         common: Provide a function for mapping packet types to strings.
18810         + commit 24e0f1d56e6f56e7fb52b5c6bdb100131e12dfe3
18811         * common/openpgpdefs.h (pkttype_str): New function.
18812
18813         gpg: Rename pop_filter to iobuf_pop_filter and export it.
18814         + commit 1463f9b9624fae97cc89df3aa4546655ee893f7c
18815         * common/iobuf.c (pop_filter): Rename from this...
18816         (iobuf_pop_filter): ... to this.  Don't mark it as static.
18817
18818         gpg: Split write_pubkey_enc_from_list.
18819         + commit 7eac4942b537c4b3710d34e6adb9c5d36338f38b
18820         * g10/encrypt.c (write_pubkey_enc_from_list): Split the body of this
18821         function out into...
18822         (write_pubkey_enc): ... this new function.
18823
18824         gpg: Allow the caller to write the contents of a plaintext packet.
18825         + commit 2fdb950471bd36f046672254ff26ca94797cc9f1
18826         * g10/build-packet.c (do_plaintext): Change the semantics such that if
18827         PT->BUF is NULL, it is the caller's responsibility to write the
18828         content (and disable partial body length mode, if appropriate).
18829
18830         gpg: Add a new function for creating binary notations.
18831         + commit 1a624586149f9e34206e5d5e1ba0b7d2b7004c80
18832         * g10/build-packet.c (blob_to_notation): New function.
18833
18834         gpg: Refactor the printing of binary notations.
18835         + commit fd2d00ccf558b1ac1184967d8702ef01cd60bf60
18836         * g10/build-packet.c (sig_to_notation): Break printing of binary
18837         notations into...
18838         (notation_value_to_human_readable_string): ... this new function.
18839         Provide a small preview of the binary data substituting non-printable
18840         characters with '?'.
18841
18842 2016-03-02  Uldis Anšmits  <uldis.ansmits@tieto.com>
18843
18844         tests/openpgp: Make tests more portable.
18845         + commit 1cdb744d91ab33563fc0b3156fb05694caa55278
18846         * tests/openpgp/default-key.test: Avoid 'grep -q'.
18847         * tests/openpgp/gpgtar.test: Avoid 'grep -qe' and 'diff -q'.
18848         * tests/openpgp/use-exact-key.test: Avoid 'grep -q'.
18849
18850 2016-03-02  Justus Winter  <justus@g10code.com>
18851
18852         common: Consolidate Assuan server argument handling.
18853         + commit e77c85577d1bdd77ad3b81907145fd68f2653c01
18854         * common/Makefile.am (common_sources): Add new files.
18855         * common/server-help.c: New file.
18856         * common/server-help.h: Likewise.
18857         * agent/command.c: Drop argument handling primitives in favor of using
18858         the consolidated ones.
18859         * dirmngr/server.c: Likewise.
18860         * g10/server.c: Likewise.
18861         * g13/server.c: Likewise.
18862         * scd/command.c: Likewise.
18863         * sm/server.c: Likewise.
18864
18865 2016-03-01  Justus Winter  <justus@g10code.com>
18866
18867         dirmngr: Add missing CFLAGS.
18868         + commit 9a1778abcae0a7afe33be8e02b6d9a909463cd54
18869         * dirmngr/Makefile.am (t_ldap_parse_uri_CFLAGS): Add
18870         'GPG_ERROR_CFLAGS'.
18871         (t_dns_stuff_CFLAGS): Likewise.
18872
18873         tools: Drop superfluous include.
18874         + commit 3a1d142f9b71721a631cf2037665e9def60aa384
18875         * tools/gpgtar.c: Do not include unused 'npth.h'.
18876
18877 2016-02-26  Werner Koch  <wk@gnupg.org>
18878
18879         gpg: Prettify a 2 octet hex output.
18880         + commit 2de0d41219a522e01f050d475b3ddecb9173fc7d
18881         * g10/sig-check.c (check_key_signature2): Wrap line and use %02x.
18882
18883 2016-02-25  Neal H. Walfield  <neal@g10code.com>
18884
18885         gpg: Show debugging info if a sig with an unsupported sig class is used.
18886         + commit 87515e39295e4b7eaec1641c38e1ac32e8d39a91
18887         * g10/sig-check.c (check_key_signature2): If SIG->CLASS is
18888         unsupported, show some debugging information.  Don't use BUG to fail.
18889         Just return GPG_ERR_BAD_SIGNATURE.
18890
18891         gpg: More carefully encode a packet's length.
18892         + commit 960f5e26f2cda3ac6e6b30548fa808a690c39ffc
18893         * g10/build-packet.c (write_header2): Make sure the length bits are
18894         cleared.  Fail if HDRLEN is set and the specified length can't be
18895         encoded in the available space.
18896
18897         gpg: Avoid directly twiddling bits.
18898         + commit 105a5629c7e938ec7b3c9c338ebe7bdfee4cfdad
18899         * g10/build-packet.c (do_plaintext): Use ctb_new_format_p to check the
18900         packet's format.
18901         (write_header2): Likewise.
18902
18903         gpg: Add some asserts.
18904         + commit c9636a1acc952eb8e1355089bc2e229dece98165
18905         * g10/build-packet.c (ctb_new_format_p): New function.
18906         (ctb_pkttype): New function.
18907         (do_user_id): Add some asserts.
18908         (do_key): Likewise.
18909         (do_symkey_enc): Likewise.
18910         (do_pubkey_enc): Likewise.
18911         (do_plaintext): Likewise.
18912         (do_encrypted): Likewise.
18913         (do_encrypted_mdc): Likewise.
18914         (do_compressed): Likewise.
18915         (do_signature): Likewise.
18916         (do_signature): Likewise.
18917         (write_header2): Likewise.
18918
18919         gpg: Avoid an unnecessary copy.
18920         + commit 512bc72e1f8544341529174142273d857f45540c
18921         * g10/build-packet.c (sig_to_notation): Avoid an unnecessary copy of
18922         the data: the size of the packet is fixed.
18923
18924 2016-02-23  Neal H. Walfield  <neal@g10code.com>
18925
18926         common: Reduce buffer size.
18927         + commit 75861b663bbb37214143c2ff7b1b4d1d10ba2657
18928         * common/iobuf.c (iobuf_copy): Change buffer size from 1 MB to 32 KB.
18929
18930         common: Improve a function's documentation and comments.
18931         + commit 14d27b2cadf9b0bb413f2b8bad2d81c1d370c2e7
18932         * common/iobuf.c (iobuf_set_partial_body_length_mode): Fix
18933         documentation and comment.  Add an assert.
18934
18935         common: Add log_assert.
18936         + commit f57a91afb69c58f9d8d9632801650f28c7dc1e0d
18937         * common/logging.h (log_assert): New macro.
18938
18939         gpg: Use higher-level functions.
18940         + commit 33ac735a781325c4d47cdf6216813866ab93562e
18941         * g10/build-packet.c (do_symkey_enc): Use iobuf_write instead of
18942         iobuf_put in a loop.  Use iobuf_copy instead of iobuf_read and
18943         iobuf_write in a loop.  Move the memory wiping from here...
18944         * common/iobuf.c (iobuf_copy): ... to here.
18945
18946         common: Check for an error before reading.
18947         + commit 8066f8a3470f9d2f3682a28641a7b09eca29a105
18948         * common/iobuf.c (iobuf_copy): If DEST has a pending error, don't
18949         start copying.
18950
18951         common: More accurately name function.
18952         + commit 903466e124841cb29f518afa6b7706d490737ac3
18953         * common/iobuf.c (iobuf_set_partial_block_mode): Rename from this...
18954         (iobuf_set_partial_body_length_mode): ... to this.  Update callers.
18955
18956 2016-02-23  Werner Koch  <wk@gnupg.org>
18957
18958         g13: Add commands --suspend and --remove.
18959         + commit f7968db30b0e0ccae038e354568accb0a05d877c
18960         * g13/g13.c (aSuspend, aResume): New.
18961         (opts): Add commands --suspend and --resume.
18962         (main): Implement dummy command aUmount.  Implement commands aResume
18963         and aSuspend.
18964         * g13/sh-cmd.c (cmd_suspend): New.
18965         (cmd_resume): New.
18966         (register_commands): Add commands RESUME and SUSPEND.
18967         * g13/server.c (cmd_suspend): New.
18968         (cmd_resume): New.
18969         (register_commands): Add commands RESUME and SUSPEND.
18970         * g13/be-dmcrypt.c (be_dmcrypt_suspend_container): New.
18971         (be_dmcrypt_resume_container): New.
18972         * g13/backend.c (be_suspend_container): New.
18973         (be_resume_container): New.
18974         * g13/suspend.c, g13/suspend.h: New.
18975         * g13/mount.c (parse_header, read_keyblob_prefix, read_keyblob)
18976         (decrypt_keyblob, g13_is_container): Move to ...
18977         * g13/keyblob.c: new file.
18978         (keyblob_read): Rename to g13_keyblob_read and make global.
18979         (keyblob_decrypt): Rename to g13_keyblob_decrypt and make global.
18980         * g13/sh-dmcrypt.c (check_blockdev): Add arg expect_busy.
18981         (sh_dmcrypt_suspend_container): New.
18982         (sh_dmcrypt_resume_container): New.
18983         * g13/call-syshelp.c (call_syshelp_run_suspend): New.
18984         (call_syshelp_run_resume): New.
18985
18986         g13: Run mount after dmsetup.
18987         + commit f26867928c451443769fecc41c3283e077e8c49f
18988         * g13/g13-syshelp.c (main): Reject userids with a slash.
18989         * g13/sh-dmcrypt.c (sh_dmcrypt_mount_container): Run mount if a
18990         mountpoint is known.
18991
18992 2016-02-23  Justus Winter  <justus@g10code.com>
18993
18994         tests/openpgp: Qualify executables with extension.
18995         + commit ede0061febe5b2edde6a1a79d599e3c7c0faed5a
18996         * tests/openpgp/Makefile.am (required_pgms): Qualify executables with
18997         '$EXEEXT'.
18998
18999         tests/openpgp: Reimplement 'pinentry.sh' in c.
19000         + commit 01dcc2cf2f2f00235ffa7d0718ecb468370980cc
19001         * tests/openpgp/Makefile.am: Build new program.
19002         * tests/openpgp/defs.inc: Use the new program.
19003         * tests/openpgp/fake-pinentry.c: New file.
19004
19005         tests/openpgp: Avoid dependency on source files.
19006         + commit 785a7f463ec4e937304ce1263c5e6a46e8079137
19007         * tests/openpgp/plain-largeo.asc: New file.
19008         * tests/openpgp/version.test: Dearmor the new file instead of relying
19009         on the source being present.
19010
19011         tests/openpgp: Fix file removal.
19012         + commit 629284120ff359b98a178b6cddf0e005e5f4db1a
19013         * tests/openpgp/version.test: Fix file removal.
19014
19015         common/exechelp: Provide a way to wait for multiple processes.
19016         + commit 5ba4f6047b84e4cfdb3e6bc88e574ca7a455da81
19017         * common/exechelp-posix.c (gnupg_wait_process): Generalize to
19018         'gnupg_wait_processes'.
19019         * common/exechelp-w32.c (gnupg_wait_process): Likewise.
19020         * common/exechelp-w32ce.c (gnupg_wait_process): New function stub.
19021         * common/exechelp.h (gnupg_wait_process): New prototype.
19022
19023         common/exechelp: Add general pipe function.
19024         + commit 9f4a8d4ea173b4b4cb4d4f06b4004d43e2f4b97a
19025         * common/exechelp-posix.c (gnupg_create_pipe): New function.
19026         * common/exechelp-w32.c (INHERIT_{READ,WRITE,BOTH}): New macros.
19027         (create_inheritable_pipe): Generalize so that both ends can be
19028         inherited.
19029         (do_create_pipe): Rename argument accordingly.
19030         (gnupg_create_{in,out}bound_pipe): Use new flags.
19031         (gnupg_create_pipe): New function.
19032         (gnupg_spawn_process): Use new flags.
19033         * common/exechelp-w32ce.c (gnupg_create_pipe): New stub.
19034         * common/exechelp.h (gnupg_create_pipe): New prototype.
19035
19036         common/exechelp: Mute the Windows version.
19037         + commit 54acc87c1e0b100accbfd02cfce59a897f2f0ce1
19038         * common/exechelp-w32.c (gnupg_wait_process): Do not print an error if
19039         the exit code can be returned.  This makes the Windows version behave
19040         like the POSIX version.
19041
19042         common/exechelp: Avoid magic numbers.
19043         + commit 709e2a7e9a3197e8ded4be0b05c138e8d5adbca6
19044         * common/exechelp-w32.c (do_create_pipe): Use symbolic names.
19045
19046         common/exechelp: Disable debugging by default.
19047         + commit 5d8f7b16c8490d6951772fa98c1f075a952cc571
19048         * common/exechelp-w32.c (DEBUG_W32_SPAWN): Set to 0.
19049
19050         common/exechelp: Fix handle leak.
19051         + commit dd670366d7aedb07e9420d1f8575197acfae1914
19052         * common/exechelp-w32.c (gnupg_spawn_process_detached): Close process
19053         handle.
19054
19055         common/exechelp: Fix opening the 'nul' device.
19056         + commit 8857590006266da200427f2d4f9e8c27fbc89ed9
19057         * common/exechelp-w32.c (gnupg_spawn_process): Fix opening the 'nul'
19058         device.
19059
19060         common/exechelp: Fix error handling.
19061         + commit f5a4b6a3a39a2b78d33769184d6133d5e256e02c
19062         * common/exechelp-w32.c (gnupg_spawn_process): Close the right handle.
19063
19064         common/exechelp: Fix pipe creation.
19065         + commit b0125ae9850973b89010517b1dbce04125a51d51
19066         * common/exechelp-w32.c (gnupg_spawn_process): Fix the creation of the
19067         input pipe.
19068
19069         tools/mk-tdata: Fix data generation on Windows.
19070         + commit 661ba477e01b796db161fa612b46c353393c6b10
19071         * tools/mk-tdata.c (main): Set stdout to binary mode to avoid newline
19072         conversion.
19073
19074 2016-02-19  Neal H. Walfield  <neal@g10code.com>
19075
19076         gpg: Systematically detect and fix signatures that are out of order.
19077         + commit 2d1d795481bc011447284f8ce0a3ae96a08daf17
19078         * g10/keyedit.c (sig_comparison): New function.
19079         (fix_key_signature_order): Merge functionality into...
19080         (check_all_keysigs): ... this function.  Rewrite to eliminate
19081         duplicates and use a systematic approach to detecting and moving
19082         signatures that are out of order instead of a heuristic.
19083         (fix_keyblock): Don't call fix_key_signature_order.  Call
19084         check_all_keysigs instead after collapsing the uids.
19085
19086         gpg: Split check_key_signature2.
19087         + commit 44cdb9d73f1a0b7d2c8483a119b9c4d6caabc1ec
19088         * g10/sig-check.c (hash_uid_node): Rename from this...
19089         (hash_uid_packet): ... to this.  Take a PKT_user_id instead of a
19090         KBNODE.
19091         (check_key_signature2): Split the basic signature checking
19092         functionality into...
19093         (check_signature_over_key_or_uid): ... this new function.
19094
19095         gpg: Split print_and_check_one_sig.
19096         + commit 5fbd80579aea0f75ca1d2700515c5b8747a75c7d
19097         * g10/keyedit.c (print_and_check_one_sig): Split the print
19098         functionality into...
19099         (print_one_sig): ... this new function.
19100
19101         gpg: Split the function check_signature_end.
19102         + commit ac5aea95455372145f3f06df2b4c1584d759d660
19103         * g10/sig-check.c (check_signature_end): Break the basic signature
19104         check into...
19105         (check_signature_end_simple): ... this new function.
19106
19107         gpg: Use format_keyid rather than manually formatting the keyid.
19108         + commit 10671c3a4c18ea26035a5819a9f2b8fd6c7e41ea
19109         * g10/keyedit.c (menu_addrevoker): Use format_keyid rather than
19110         manually formatting the keyid.
19111         * g10/keygen.c (card_write_key_to_backup_file): Likewise.
19112
19113         gpg: Initialize the primary key when generating a key.
19114         + commit bf9d1248c80205795e26156f67aff0b3f796cfce
19115         * g10/keygen.c (do_generate_keypair): Initialize
19116         pri_psk->flags.primary, pri_psk->keyid and pri_psk->main_keyid.
19117
19118         gpg: Add accessor & utility functions for pk->keyid and pk->main_keyid.
19119         + commit c45633a571bf663bc7f3610fc481acded6acfc19
19120         * g10/keydb.h (keyid_cmp): New function.
19121         * g10/keyid.c (pk_keyid): New function.
19122         (pk_main_keyid): New function.
19123         (keyid_copy): New function.
19124         (pk_keyid_str): New function.
19125         * g10/packet.h (PKT_public_key): Update comments for main_keyid and
19126         keyid.
19127
19128 2016-02-18  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
19129
19130         gpgparsemail: Allow weirdly-mixed pkcs7 signatures.
19131         + commit 7e7f35a2d7d40267a4dd30791df77420efeebfa7
19132         * tools/gpgparsemail.c: Add and check info->signing_protocol_2.
19133
19134         gpg: Clean up dangling agent_open and agent_closed declarations.
19135         + commit 813df2fe6656e55bea4d0be07cc964a140218412
19136         * g10/keydb.h: Remove agent_open, agent_close declarations/
19137         * g10/migrate.c: #include <unistd.h> for access()
19138
19139 2016-02-16  Werner Koch  <wk@gnupg.org>
19140
19141         w32: Make scdaemon build again due to libusb problem.
19142         + commit e1ceff16765b0342531709cf97d03ef0158c29d5
19143         * configure.ac: Add hack to disable libusb for Windows.  Also use
19144         $host instead of $target in the switch
19145          --
19146
19147         The new test for libusb does not support cross-compiling.  As a quick
19148         workaround we disable libusb for Windows because we can't use it anyway.
19149
19150         w32: Do not error out if gpgconf is not installed.
19151         + commit 44b02e1beb4f38f26551d932827d5317fddd27c2
19152         * common/homedir.c (check_portable_app): Remove error message.
19153
19154 2016-02-16  Neal H. Walfield  <neal@g10code.com>
19155
19156         gpg: Make ASCII armor decoding more robust to encoding errors.
19157         + commit 2f02ed75a9671a7aae36968d5a1618f71b491325
19158         * g10/armor.c (radix64_read): If the = is followed by the string "3D",
19159         check if the following four characters are valid radix 64 and are
19160         followed by a new line.  If so, warn and ignore the '3D'.
19161
19162 2016-02-16  Werner Koch  <wk@gnupg.org>
19163
19164         doc: Add a gnupg-module-overview picture.
19165         + commit a1c11283af759c1045a8bb75815db325f415ded4
19166         * doc/gnupg-module-overview.svg: New.
19167         * doc/debugging.texi (Component interaction): New.
19168         * doc/Makefile.am (EXTRA_DIST): Add PNG and PDF versions of
19169         gnupg-module-overview.svg.  Remove two eps files.
19170         (BUILT_SOURCES): Add gnupg-module-overview.pdf and .png.  Remove
19171         gnupg-card-architecture.epsl
19172         (gnupg_TEXINFOS): Add gnupg-module-overview.svg
19173         (gnupg.dvi): New.
19174         (DISTCLEANFILES): Remove build eps files.
19175
19176 2016-02-15  NIIBE Yutaka  <gniibe@fsij.org>
19177
19178         common, g10: Fix indentation to silence GCC-6.
19179         + commit ea9cfcfbf76de232221f31787c53d5f46361a9f0
19180         * common/iobuf.c (iobuf_ioctl): Fix.
19181         * g10/encrypt.c (encrypt_filter): Likewise.
19182         * g10/keyring.c (prepare_search): Likewise.
19183
19184         dirmngr: fix for memory alignment.
19185         + commit 6fbe12a51e8fe2649ffe5a8a02aa93026a8f02cd
19186         * dirmngr/dns-stuff.c (get_dns_cert): Cast through void *.
19187         (getsrv, get_dns_cname): Make sure it's aligned for HEADER.
19188
19189 2016-02-14  Werner Koch  <wk@gnupg.org>
19190
19191         gpg: Add hidden key-edit subcommand "change-usage".
19192         + commit 9b28b82e7c40d1eacc446d5932cd613c56378ed8
19193         * g10/keyedit.c (cmdCHANGEUSAGE): New.
19194         (cmds): Add command "change-usage".
19195         (keyedit_menu): Handle that command.
19196         (menu_changeusage): New.
19197         * g10/keygen.c (keygen_add_key_flags): New.
19198         (ask_key_flags): Add optional arg current.
19199
19200 2016-02-14  Neal H. Walfield  <neal@g10code.com>
19201
19202         gpg: Improve API documentation.
19203         + commit 9663b088480cef6734a3c5892d5ddbbd60ecc1a4
19204         * g10/seskey.c (make_session_key): Improve documentation.
19205         (encode_session_key): Improve documentation.
19206         * g10/encrypt.c (encrypt_seskey): Remove gratuitous initialization.
19207         * g10/dek.h (DEK): Improve documenation.
19208
19209         gpg: Fix calc_header_length when LEN is 0 and improve documentation.
19210         + commit 5cdde08ea869ef02111f618ad782d392a296eb7f
19211         * g10/build-packet.c (calc_header_length): Return the correct haeder
19212         size when LEN is 0.  Fix documentation.
19213
19214         gpg: Fix format_keyid when dynamically allocating the buffer.
19215         + commit c0268c449d0f3d23be5ec7b92fe92e7e078166cf
19216         * g10/keyid.c (format_keyid): Return a char *, not a const char *.  If
19217         BUFFER is NULL, then set LEN to the static buffer's size.
19218
19219         common: Fix comment.
19220         + commit ad43dc6cfc2b610a4e34fe55811bd937f9c3238b
19221         * common/iobuf.c (iobuf_flush_temp): Fix comment.
19222
19223 2016-02-13  Werner Koch  <wk@gnupg.org>
19224
19225         g13: Require a confirmation before g13 is used for DM-Crypt.
19226         + commit 86f3bb144ad75461eb9b7ac1e59046ac75efccac
19227         * g13/g13-syshelp.c (g13_syshelp_i_know_what_i_am_doing):
19228         * g13/sh-dmcrypt.c (sh_dmcrypt_create_container): Call it.
19229         (sh_dmcrypt_mount_container): Call it.
19230
19231         g13: Second chunk of code to support dm-crypt.
19232         + commit b0e6ab1109d05fc664f46e17d721fe9b01d38115
19233         * g13/be-dmcrypt.c, g13/be-dmcrypt.h: New.
19234         * g13/Makefile.am (g13_SOURCES): Add them.
19235         * g13/backend.c: Include be-dmcrypt.h and call-syshelp.h.
19236         (no_such_backend): Rename to _no_such_backend and provide replacement
19237         macro.
19238         (be_is_supported_conttype): Support DM-Crypt.
19239         (be_take_lock_for_create): Call set_segvice for DM-Crypt.
19240         (be_create_new_keys): Make it a dummy for DM-Crypt.
19241         (be_create_container): Call be_dmcrypt_create_container.
19242         (be_mount_container): call be_dmcrypt_mount_container.
19243         * g13/g13-syshelp.c (main): Enable verbose mode.
19244         * g13/g13tuple.c (get_tupledesc_data): New.
19245         * g13/g13tuple.h (unref_tupledesc): New.
19246         * g13/g13.h (server_control_): Add field "recipients".
19247         * g13/g13.c (main): Fix setting of recipients via cmdline.
19248         (g13_deinit_default_ctrl): Release recipients list.
19249         (g13_request_shutdown): New.  Replace all direct update of
19250         shutdown_pending by calls this function.
19251         * g13/server.c (server_local_s): Remove field recipients which is now
19252         part of CTRL.
19253         (reset_notify, cmd_recipient, cmd_create): Adjust for this change.
19254         * g13/create.c (encrypt_keyblob): Rename to g13_encrypt_keyblob.
19255         (g13_create_container): Support DM-Crypt.
19256         * g13/mount.c (parse_header): Allow for meta data copies.
19257         (g13_mount_container): Support DM-Crypt.
19258         * g13/sh-cmd.c (cmd_create): Make it work.
19259         (cmd_mount): New.
19260         * g13/sh-dmcrypt.c (sh_dmcrypt_create_container): Make it work.
19261         (sh_dmcrypt_mount_container): New.
19262
19263         g13: Improve dump_keyblob.
19264         + commit 13f745b50dc7031755faadb2d3476a6b6aafc739
19265         * g13/g13tuple.c: Include keyblob.h.
19266         (find_tuple_uint): Factor code out to ...
19267         (convert_uint): new.
19268         (all_printable): New.
19269         * g13/mount.c (dump_keyblob: Move and rename to ...
19270         * g13/g13tuple.c (dump_tupledesc): here.  Revamp and pretyy print uint
19271         values.
19272
19273         g13: Define 3 new tags.
19274         + commit 59fc3507d18072833559f227ecab8aa00cad9466
19275         * g13/keyblob.h (KEYBLOB_TAG_CONT_NSEC): New.
19276         (KEYBLOB_TAG_ENC_NSEC): New.
19277         (KEYBLOB_TAG_ENC_OFF): New.
19278
19279         g13: Rename utils.c to g13tuple.c.
19280         + commit 82d12156ef5f948d44934ed44d79d24cc9e94366
19281         * g13/utils.c: Rename to g13tuple.c.
19282         * g13/utils.h: Rename to g13tuple.h.  Change all users.
19283         * g13/Makefile.am: Adjust accordingly
19284
19285         g13: Add functions to handle uint in a keyblob.
19286         + commit 4f152f3276b6d40d2568a27e74903dd18b41d752
19287         * g13/utils.c (append_tuple_uint): New.
19288         (find_tuple_uint): New.
19289         * g13/t-utils.c: New.
19290         * g13/Makefile.am (noinst_PROGRAMS, TESTS): New.
19291         (module_tests, t_common_ldadd): New.
19292         (t_utils_SOURCES, t_utils_LDADD): New.
19293
19294         g13: Re-factor high level create code.
19295         + commit dc1dbc43a6bfb2f3e6a1cc2ca089e0318b3af0ed
19296         * g13/create.c (g13_create_container): Factor some code out to ...
19297         * g13/backend.c (be_take_lock_for_create): new.
19298
19299         g13: Return an error for non-existing device.
19300         + commit 3087197008d2b12bf9f0d7d1f2aca500db816e7c
19301         * g13/sh-cmd.c (cmd_device): Set ERR.
19302
19303         g13: Fix releasing of a syshelp context.
19304         + commit 6390beca54f55e8d36ff767b99ae9ff68b15f10e
19305         * g13/call-syshelp.c (call_syshelp_release): Allow a NULL arg.
19306
19307         g13: Switch over to common/exectool.c.
19308         + commit c5d7045dafcfb569c11c90c04ea7a75328c80084
19309         * g13/sh-exectool.c: Remove.  It has been replaced by common/exectool.c.
19310         * g13/Makefile.am (g13_syshelp_SOURCES): Remove sh-exectool.c
19311         * g13/sh-blockdev.c: Include exectool.h.  Change sh_exec_tool to
19312         gnupg_exec-tool.
19313         * g13/sh-dmcrypt.c: Ditto.
19314
19315         common: Make gnupg_exec_tool conform to spec.
19316         + commit d19d6e1856c9a1acbf48e8b2e39b3d9171aa9f7f
19317         * common/exectool.c (gnupg_exec_tool): Allocate extra byte.  Allow
19318         zero length read.  Append hidden byte.  Release memory on error.
19319
19320         g13: First chunk of code to support dm-crypt.
19321         + commit 81494fd30d3815502247a721f50d9eadf86a73fa
19322         * g13/call-syshelp.c, g13/call-syshelp.h: New.
19323         * g13/g13-syshelp.c, g13/g13-syshelp.h: New.
19324         * g13/sh-cmd.c: New.
19325         * g13/sh-blockdev.c: New.
19326         * g13/sh-exectool.c: New.
19327         * g13/sh-dmcrypt.c: New.
19328         * g13/Makefile.am (sbin_PROGRAMS): Add g13-syshelp.c
19329         (g13_syshelp_SOURCES): New.
19330         (g13_syshelp_LDADD): New.
19331
19332         * g13/g13.c (opts): Add option --type.
19333         (g13_deinit_default_ctrl): New.
19334         (main): Implement that option.  Call g13_deinit_default_ctrl.
19335         * g13/g13.h (struct call_syshelp_s): New declaration.
19336         (server_control_s): Add field syshelp_local.
19337         * g13/keyblob.h (KEYBLOB_TAG_CREATED): New.
19338         (KEYBLOB_TAG_ALGOSTR): New.
19339         (KEYBLOB_TAG_HDRCOPY): New.
19340         * g13/backend.c (be_parse_conttype_name): New.
19341         (be_get_detached_name): Add CONTTYPE_DM_CRYPT.
19342
19343         tests: Remove some harmless warnings in regression tests.
19344         + commit d711f5c7697cd4bc5dc6d9fd01706cabc771dad2
19345         * tests/openpgp/gpg-agent.conf.tmpl: Remove --use-standard-socket.
19346
19347 2016-02-12  Neal H. Walfield  <neal@g10code.com>
19348
19349         common: Change simple_query to ignore status messages.
19350         + commit acac103ba5772ae738ce5409d17feab80596cde6
19351         * common/simple-pwquery.c (simple_query): Ignore status messages.
19352
19353 2016-02-12  NIIBE Yutaka  <gniibe@fsij.org>
19354
19355         g10: Make sure to have the directory for trustdb.
19356         + commit d9f9b3be036747c9f55060aed47896f951bfb853
19357         * g10/tdbio.c (tdbio_set_dbname): Return earlier if !CREATE.  Check
19358         the directory and create it if none before calling take_write_lock.
19359
19360 2016-02-02  Neal H. Walfield  <neal@g10code.com>
19361
19362         doc: Note that rngd can also be used to quickly generate insecure keys.
19363         + commit 75311cfe18071b94c66121a9785b133b6df345a3
19364         * doc/gpg-agent.texi (Agent Options): Add comment to the description
19365         of --debug-quick-random that rngd can also be used to quickly generate
19366         key.
19367
19368 2016-01-27  Werner Koch  <wk@gnupg.org>
19369
19370         scd: Fix size_t/int mismatch in libusb.
19371         + commit 3d952a2fe5da9d84c20d3debdcc1e425b08781c6
19372         * scd/ccid-driver.c (bulk_in, abort_cmd, ccid_poll): Change msglen to
19373         int.
19374
19375         scd: Fix detection of libusb.
19376         + commit 1b90b52a56b4f808ad29a7ef79aeafc03c7424b4
19377         * configure.ac (HAVE_LIBUSB): Clear if no header file was found.
19378         (LIBUSB_LIBS): Ditto.
19379
19380         dirmngr: Build fix for FreeBSD (EAI macros)
19381         + commit 4d67144142f04184b835e50314eb21b882b9e00a
19382         * dirmngr/dns-stuff.c (map_eai_to_gpg_error): Map EAI_NODATA and
19383         EAI_ADDRFAMILY only if defined.
19384
19385 2016-01-27  NIIBE Yutaka  <gniibe@fsij.org>
19386
19387         scd: Migrate to new API of libusb 1.0.
19388         + commit d0d97089706286fafd3c8ff56f3b5bf7ac07c6e0
19389         * configure.ac (LIBUSB_CPPFLAGS): New.
19390         * scd/Makefile.am (AM_CPPFLAGS): Add LIBUSB_CPPFLAGS.
19391         * scd/ccid-driver.c: Use libusb 1.0 API.
19392
19393 2016-01-26  Werner Koch  <wk@gnupg.org>
19394
19395         Release 2.1.11.
19396         + commit e9e5e83ec14459c2fc9060c54fc8e7381b541acd
19397
19398
19399 2016-01-26  Andre Heinecke  <aheinecke@intevation.de>
19400
19401         gpgtar,w32: Fix gpgtar 8 bit encoding handling on W32.
19402         + commit 3e50236d4ecc3601b2641bf4273a0ff64bb5fdc4
19403         * common/utf8conv.c (wchar_to_utf8): Factor code out to ...
19404         (wchar_to_cp): new.
19405         (utf8_to_wchar): Factor code out to ...
19406         (cp_to_wchar): new.
19407         (wchar_to_native): New.
19408         (native_to_wchar): New.
19409         * tools/gpgtar-create.c (fillup_entry_w32): Use native_to_wchar.
19410         (scan_directory): Use wchar_to_native.
19411
19412 2016-01-26  NIIBE Yutaka  <gniibe@fsij.org>
19413
19414         g10: Fix segfault on unsupported curve.
19415         + commit b8bb16c6c08d3c2947f1ff67419b36eb203c5c1a
19416         * g10/call-agent.c (learn_status_cb): Don't use NULL for strcmp.
19417
19418         sm: small fix for GCC 6.
19419         + commit d33a34004bef028068538f099c32a0e292a004c3
19420         * sm/export.c (insert_duptable): Use unsigned 0.
19421
19422 2016-01-25  Werner Koch  <wk@gnupg.org>
19423             Daiki Ueno  <ueno@gnu.org>
19424
19425         gpg: Print PROGRESS status lines during key generation.
19426         + commit fbe1cf67aadc5a33cf815ddbcfc9669e43caa123
19427         * g10/call-agent.c (cache_nonce_status_cb): Rewrite by using
19428         has_leading_keyword.  Handle PROGRESS lines.
19429
19430 2016-01-25  Werner Koch  <wk@gnupg.org>
19431
19432         agent: Send PROGRESS status lines to the client.
19433         + commit ee87c653bf4b495714e8e6b024d0a8ace3a33452
19434         * agent/gpg-agent.c (struct progress_dispatch_s): New.
19435         (progress_dispatch_list): New.
19436         (main): Register libgcrypt pogress handler.
19437         (agent_libgcrypt_progress_cb): New.
19438         (agent_set_progress_cb): New.
19439         (unregister_progress_cb): New.
19440         (agent_deinit_default_ctrl): Call unregister.
19441         * agent/command.c (progress_cb): New.
19442         (start_command_handler): Register progress callback.
19443
19444         speedo: Allow use of SHA-256 checksums.
19445         + commit 039a55716b8abd22ce23a96dce34cf2dc4be1862
19446         * build-aux/getswdb.sh: Add option --find-sha256sum.
19447         * build-aux/speedo.mk (libgpg_error_sha2): New var.  Also for all
19448         other packages.
19449         (SHA2SUM): New.
19450         (SETVARS, SETVARS_W64): Prefer sha256sum over sha1sum.
19451         (installer-from-source): Create swdb fragment.
19452
19453 2016-01-22  Werner Koch  <wk@gnupg.org>
19454
19455         dirmngr: Indicate that serial numbers are hexadecimal.
19456         + commit 12c665b36cdc4b7189549698fc4cc1b3523b18f5
19457         * dirmngr/misc.c (hexify_data): Add arg with_prefix.  Adjust all
19458         callers.
19459         * dirmngr/crlcache.c (cache_isvalid): Print "0x" in front of the S/N.
19460
19461         dirmngr: Provide the keyserver pool name even if there is no CNAME.
19462         + commit 77bceb2902dd489443073d91836ea54376c60bf6
19463         * dirmngr/ks-engine-hkp.c (map_host): Fix setting of r_poolname.
19464
19465 2016-01-22  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
19466             wk@gnupg.org
19467
19468         dirmngr: Use sks-keyservers CA by default for the hkps pool.
19469         + commit afb8696126ff0babaab23e884ff5da008281e3b7
19470         * dirmngr/Makefile.am (dist_pkgdata_DATA): Add sks-keyservers.netCA.pem.
19471         * dirmngr/http.c (http_session_new): Add optional arg
19472         intended_hostname and set a default cert.
19473         * dirmngr/ks-engine-hkp.c (send_request): Pass httphost to
19474         http_session_new.
19475
19476 2016-01-22  Werner Koch  <wk@gnupg.org>
19477
19478         gpg: Allow new user ids with only the mail address.
19479         + commit fc0c71dfe5ea8f1c683101948c23f5d2064ee4cd
19480         * g10/keygen.c (ask_user_id): Allow empty name.
19481
19482 2016-01-21  Werner Koch  <wk@gnupg.org>
19483
19484         gpg: Improve header text of the auto-created revocations.
19485         + commit bb99b40bd1e624f58ca806ca16dc73d4d594a30a
19486         * g10/revoke.c (gen_standard_revoke): Improve header text for the
19487         file.  Add info output.
19488
19489         gpg: Make --auto-key-retrieve work with dirmngr configured server.
19490         + commit 09117e769a093467cb47154f36d7dda613313e33
19491         * g10/call-dirmngr.c (gpg_dirmngr_ks_list): Make R_KEYSERVER optional.
19492         * g10/keyserver.c (keyserver_any_configured): New.
19493         (keyserver_put): Remove arg keyserver because this will always receive
19494         opt.keyserver which is anyway used when connecting dirmngr.  Do not
19495         check opt.keyserver.
19496         (keyserver_import_cert): Replace opt.keyserver by
19497         keyserver_any_configured.
19498         * g10/mainproc.c (check_sig_and_print): Ditto.
19499         * g10/import.c (revocation_present): Ditto.
19500         * g10/getkey.c (get_pubkey_byname): Ditto.
19501         * g10/gpgv.c (keyserver_any_configured): Add stub.
19502         * g10/test-stubs.c (keyserver_any_configured): Add stub.
19503
19504 2016-01-20  Werner Koch  <wk@gnupg.org>
19505
19506         gpg: Silence message about ignoring revoked user ids.
19507         + commit bdb61351776c038d668310d9b5e5c32588ef6519
19508         * g10/trustdb.c (tdb_get_validity_core): Print message only in debug
19509         mode.
19510
19511         agent: New option --pinentry-timeout.
19512         + commit 499743387f4d07847a2842358bc54f9237e0c2a7
19513         * agent/gpg-agent.c (oPinentryTimeout): New.
19514         (opts): Add new option.
19515         (parse_rereadable_options): PArse that option.
19516         (main): Tell gpgconf about this option.
19517         * agent/call-pinentry.c (start_pinentry): Send option to Pinentry.
19518         * tools/gpgconf-comp.c (gc_options_gpg_agent): Add Option.
19519
19520 2016-01-19  Werner Koch  <wk@gnupg.org>
19521
19522         gpg: Streamline use of error messages in tofu.c.
19523         + commit cfa41890bb5ff306c07dad295136601fe47566a7
19524         * g10/tofu.c: Make use of print_further_info to reduce the number of
19525         different error messages to be translated.  Also streamline some
19526         messages.
19527
19528         common: Add substitute code for libgpg-error < 1.22.
19529         + commit 8b7f64f9dfc80b2a0ad235996b47369c2ba9b48f
19530         * common/util.h (GPG_ERR_DB_CORRUPTED): New.
19531
19532         gpg: Add function print_further_info.
19533         + commit d96e76d15f61812b950b64a60bc47117785a9dac
19534         * g10/misc.c (print_further_info): New.
19535
19536 2016-01-18  Werner Koch  <wk@gnupg.org>
19537
19538         g10: Improve strings printed by tofu.c.
19539         + commit 79778a8dd5f61a6b7abeeb44b75d82932db788b7
19540         * g10/tofu.c: Include ttyio.h.  Change many strings to help
19541         translating.  Make use of ngettext wehere needed.
19542         (CONTROL_L): New.
19543         (TIME_AGO_UNIT_SMALL_NAME): Remove this and all similar *_NAME macros.
19544         (time_ago_unit): Remove.
19545         (get_trust): Use tty_prints and cpr_get only for the actual prompt.
19546         Add Ctrl-L hack.
19547         (show_statistics): Use two English strings for singular and plural.
19548
19549         * po/POTFILES.in: Add tofu.c.
19550
19551         gpg: Use "days" in "...newer than..." diagnostics.
19552         + commit 9309bda9581715d304305c8c5116f2cbb31aec77
19553         * g10/sig-check.c (check_signature_metadata_validity): Use days if
19554         useful.
19555
19556         Use ngettext for some strings.
19557         + commit 437965e5622612941ed0fa55584811c65069242e
19558         * scd/app-openpgp.c (build_enter_admin_pin_prompt): Use ngettext for
19559         some diagnostics.
19560         (do_genkey): Ditto.
19561         * g10/keyedit.c (check_all_keysigs, menu_delsig, menu_clean): Ditto.
19562         * g10/keylist.c (print_signature_stats): Ditto.
19563         * g10/keyserver.c (keyserver_refresh): Ditto.
19564         * g10/sig-check.c (check_signature_metadata_validity): Ditto.
19565         * g10/sign.c (do_sign): Ditto.
19566         * g10/trustdb.c (reset_trust_records): Ditto.
19567         (validate_keys): Use a table like diagnostic output.
19568
19569 2016-01-15  Werner Koch  <wk@gnupg.org>
19570
19571         kbx,w32: Use shorter retry intervals for keybox_file_rename.
19572         + commit 3cccd5a83b96e4558642dcdf5d974f64ebdb9817
19573         * kbx/keybox-util.c (keybox_file_rename): Restart retry intervals
19574         after 800ms.
19575
19576 2016-01-14  Werner Koch  <wk@gnupg.org>
19577
19578         w32: Fix deadlock introduced by keybox_file_rename.
19579         + commit 663c5d129a8f400cc6eb8ab7b91772d6e578152d
19580         * g10/keyring.c (keyring_lock) [W32]: Flush the close cache before
19581         locking.
19582         * kbx/keybox-init.c (keybox_lock) [W32]: Close the file before
19583         locking.
19584
19585         gpg: Detect race between pubring.gpg and pubring.kbx use.
19586         + commit 3b1248e007a6bf830a3230ee2d9cc548205ec31a
19587         * g10/keydb.c (maybe_create_keyring_or_box): Detect race condition.
19588
19589         kbx: New function keybox_file_rename to replace rename.
19590         + commit 8241ed59d05e06252647b26477ed5c2f84895a26
19591         * kbx/keybox-util.c: Include windows.h.
19592         (keybox_file_rename): New.
19593         * kbx/keybox-update.c (rename_tmp_file): Replace remove+rename by
19594         keybox_file_rename.
19595         * g10/keyring.c (rename_tmp_file): Ditto.
19596
19597         kbx: Add function keybox_tmp_names to avoid code duplication.
19598         + commit f5cceef115f0307664956d01c48b1b397fdad4b3
19599         * kbx/keybox-update.c (create_tmp_file): Move some code to...
19600         * kbx/keybox-util.c (keybox_tmp_names): new.
19601         * g10/keyring.c: Include keybox.h.
19602         (create_tmp_file): Replace parts by keybox_tmp_names.
19603
19604         gpg: Make --list-options show-usage the default.
19605         + commit 360534bde770f4845669de223154216d249b954b
19606         * g10/gpg.c (main): Add LIST_SHOW_USAGE.
19607
19608 2016-01-13  Werner Koch  <wk@gnupg.org>
19609
19610         kbx: Change return type of search functions to gpg_error_t.
19611         + commit c7ca0f73dbe7c080b79f93f90f00ba2396fc4bd0
19612         * kbx/keybox-search.c (keybox_search_reset): Change return type to
19613         gpg_error_t.
19614         (keybox_search): Ditto.  Also handle GPG_ERR_EOF.
19615         * sm/keydb.c (keydb_search_reset): Ditto.
19616
19617         gpg: Improve error code from lock_all.
19618         + commit 9b6c91469a804c60289a2ed21334dfd856c294bb
19619         * g10/keydb.c (lock_all): Do not clobber RC during failur cleanup.
19620
19621         kbx: Improve and fix keybox_lock.
19622         + commit 8f1368d5e3f7654ad9cb100053535f728dff2344
19623         * kbx/keybox-init.c (keybox_lock): Make sure ERR is initialized.  Get
19624         error codes from dotlock functions.
19625
19626         common: Make sure dotlock functions set a proper ERRNO.
19627         + commit 4aceebf36f103eb380e21d12a1f08b7d6ea7cc8e
19628         * common/dotlock.c (map_w32_to_errno): New.
19629         (read_lockfile): Return a proper ERRNO.
19630         (dotlock_create_unix): Do not let log functions clobber ERRNO.
19631         (dotlock_take_unix): Ditto.
19632         (dotlock_release_unix): Ditto.
19633         (dotlock_create_w32): Set proper ERRNO.
19634         (dotlock_take_w32): Ditto.
19635         (dotlock_release_w32): Ditto.
19636
19637         kbx: Implement keybox_lock for use by gpg.
19638         + commit 160862978628b07ed5150ec2c8abad6af1656bc3
19639         * kbx/keybox-defs.h: Include dotlock.h and logging.h.
19640         (CONST_KB_NAME): Remove.  Replace usage by KB_NAME.
19641         (struct keybox_name): Add field "lockhd".
19642         * kbx/keybox-init.c (keybox_register_file): Init LOCKHD.
19643         (keybox_lock): Chnage to return gpg_error_t.  Implement locking.
19644
19645         gpg: Make sure to mark a duplicate registered keybox as primary.
19646         + commit 9dc355ad3ae0026ab04c424dc984d748b8fad393
19647         * kbx/keybox-init.c (keybox_register_file): Change interface to return
19648         the token even if the file has already been registered.
19649         * g10/keydb.c (primary_keyring): Rename to primary_keydb.
19650         (maybe_create_keyring_or_box): Change return type to gpg_error_t.
19651         (keydb_add_resource): Ditto. s/rc/err/.
19652         (keydb_add_resource): Mark an already registered as primary.
19653         * sm/keydb.c (maybe_create_keybox): Change return type to gpg_error_t.
19654         (keydb_add_resource): Ditto. s/rc/err/.
19655         (keydb_add_resource): Adjust for changed keybox_register_file.
19656
19657 2016-01-13  NIIBE Yutaka  <gniibe@fsij.org>
19658
19659         Fix to support git worktree.
19660         + commit 96237b9a63a50aed1884cb06f84279b977d6a8fa
19661         * autogen.sh, Makefile.am, doc/Makefile.am: Use -e for testing .git.
19662
19663 2016-01-12  Werner Koch  <wk@gnupg.org>
19664
19665         ssh: Accept OpenSSH *cert-v01 key variants.
19666         + commit e2f984b4afffaa89bdeba2f5d447b5681237177e
19667         * agent/command-ssh.c (SPEC_FLAG_WITH_CERT): New.
19668         (ssh_key_types): Add OpenSSH cert types.
19669         (stream_read_string): Allow a dummy read.
19670         (ssh_receive_mpint_list): Pass SPEC by reference.
19671         (ssh_receive_mpint_list): New arg CERT and use it.
19672         (ssh_receive_key): Read certificate into an estream object and modify
19673         parser to make use of that object.
19674
19675 2016-01-12  NIIBE Yutaka  <gniibe@fsij.org>
19676
19677         common: Fix iobuf API of filter function for alignment.
19678         + commit 4b4639b0b04dc82c550fa711dd7193e13fc4a428
19679         * common/iobuf.h: Fix comment.
19680
19681         common: Fix iobuf API of filter function for alignment.
19682         + commit 3f52c7da3940ec06572270d511000dc7fe9c27d2
19683         * common/iobuf.h (IOBUFCTRL_DESC): Change the call semantics.
19684         * common/iobuf.c (iobuf_desc): Add the second argument DESC.
19685         (print_chain, iobuf_close, do_open, iobuf_sockopen, iobuf_ioctl)
19686         (iobuf_push_filter2, pop_filter, iobuf_write_temp): Change calls
19687         of iobuf_desc.
19688         (file_filter, file_es_filter, sock_filter, block_filter): Fill the
19689         description.
19690         * common/t-iobuf.c (every_other_filter, double_filter): Likewise.
19691         * g10/armor.c, g10/cipher.c, g10/compress-bz2.c, g10/compress.c,
19692         g10/decrypt-data.c, g10/encrypt.c, g10/mdfilter.c, g10/progress.c,
19693         g10/textfilter.c: Likewise.
19694
19695 2016-01-11  Werner Koch  <wk@gnupg.org>
19696
19697         gpg: Fix NULL de-ref for ambiguous key check in --export-ssh-keys.
19698         + commit b280aa6423c9492e8c5a9afa57339d06d957996d
19699         * g10/getkey.c: Allow arg RET_KEYBLOCK to be NULL.
19700
19701 2016-01-09  Werner Koch  <wk@gnupg.org>
19702
19703         tools: Remove gpgkey2ssh.
19704         + commit eb9c021631174fde4c1c444bbc533a7a46d570cd
19705         * tools/gpgkey2ssh.c: Remove.
19706         * tools/Makefile.am (bin_PROGRAMS): Ditto.
19707
19708 2016-01-08  Werner Koch  <wk@gnupg.org>
19709
19710         gpg: Support ECDSA keys with --export-ssh-key.
19711         + commit b2da3951a395366bf1644bc4c4eb42d657effe17
19712         * g10/export.c (key_to_sshblob): Add hack for ECDSA.
19713
19714         gpg: New command --export-ssh-key.
19715         + commit 4970868d8d84d3a64b067e5aafc9f097621758d3
19716         * g10/export.c: Include membuf.h and host2net.h.
19717         (key_to_sshblob): New.
19718         (export_ssh_key): New.
19719         * g10/gpg.c (aExportSshKey): New.
19720         (opts): Add command.
19721         (main): Implement that command.
19722
19723         gpg: Add an exact search flag to the PK struct.
19724         + commit 34bca9cd4b8517795833cb754b0d5b1dd33b08ed
19725         * g10/getkey.c (merge_selfsigs_subkey): Clear exact flag.
19726         (finish_lookup): Set exact flag.
19727         * g10/packet.h (PKT_public_key): Add field flags.exact.
19728
19729         Print warnings if old daemon versions are used.
19730         + commit 2aa42baaf3dd7c3ae613ae0c61760a17c8adfcd0
19731         * common/status.h (STATUS_WARNING): New.
19732         * g10/call-agent.c (warn_version_mismatch): New.
19733         (start_agent): Call warn function.
19734         * g10/call-dirmngr.c: Include status.h.
19735         (warn_version_mismatch): New.
19736         (create_context): Call warn function.
19737         * sm/call-agent.c (warn_version_mismatch): New.
19738         (start_agent): Call warn function.
19739         (gpgsm_agent_learn): Call warn function.
19740         * sm/call-dirmngr.c (warn_version_mismatch): New.
19741         (prepare_dirmngr): Call warn function.
19742
19743         common: New function compare_version_strings.
19744         + commit 4d7ac43ff71fdadfd2e04621f74840a82fbe788a
19745         * common/stringhelp.c (parse_version_number): New.
19746         (parse_version_string): New.
19747         (compare_version_strings): New.
19748         * common/t-stringhelp.c (test_compare_version_strings): New.
19749         (main): Call test.  Return ERRCOUNT instead of 0.
19750
19751         common: New function get_assuan_server_version.
19752         + commit 496643291e1e346434e9c98405c5a370957eb7d3
19753         * common/asshelp.c: Include membuf.h.
19754         (get_assuan_server_version): New.
19755         * g10/call-agent.c (agent_get_version): Use new function.
19756
19757         common: New put_membuf_cb to replace static membuf_data_cb.
19758         + commit 833ba5faa1340aff80a205acbb701d4ae1d594d0
19759         * common/membuf.c (put_membuf_cb): New.
19760         * agent/call-scd.c (membuf_data_cb): Remove.  Change callers to use
19761         put_membuf_cb.
19762         * common/get-passphrase.c (membuf_data_cb): Ditto.
19763         * g10/call-agent.c (membuf_data_cb): Ditto.
19764         * sm/call-agent.c (membuf_data_cb): Ditto.
19765
19766 2016-01-07  Werner Koch  <wk@gnupg.org>
19767
19768         gpg: Return an error code from keygrip_from_pk.
19769         + commit 8fd406c317ad7c2e375ae4f7d20656dadf6d7fcc
19770         * g10/keyid.c (keygrip_from_pk): Return an error code.
19771
19772         gpg: Avoid warnings about possible NULL deref.
19773         + commit 8a56a38387c10c02ba0790c655dd5c1d08e4a724
19774         * g10/getkey.c (cache_public_key): Protect deref of CE which actually
19775         can't happen.
19776         * g10/keygen.c (quickgen_set_para): s/sprintf/snprintf/.
19777         * g10/tofu.c (end_transaction, rollback_transaction): Allow NULL for
19778         DB.
19779         * g10/trustdb.c (update_min_ownertrust): Remove useless clearling of
19780         ERR.
19781
19782         gpg: Fix warnings about useless assignments.
19783         + commit 008aa6e6d4b213c3a0d15509eb46cf168b6f2c94
19784         * g10/armor.c (parse_hash_header): Remove duplicate var assignment.
19785         * g10/getkey.c (cache_user_id): Ditto.
19786         * g10/keygen.c (ask_curve): Ditto.  This also fixes a small memory
19787         leak.
19788
19789         * g10/keygen.c (proc_parameter_file): Remove useless assignment or
19790         pointer increment.
19791         (generate_keypair): Ditto.
19792         * g10/getkey.c (finish_lookup, lookup): Ditto.
19793         * g10/card-util.c (change_pin): Ditto.
19794         * g10/gpg.c (main) <aVerify>: Ditto.
19795         * g10/import.c (import): Ditto.
19796         (print_import_check): Ditto
19797         * g10/keyring.c (do_copy): Ditto.
19798         * g10/tdbio.c (tdbio_read_record): Ditto.
19799         * g10/trustdb.c (tdb_update_ownertrust): Ditto.
19800         (update_validity): Ditto.
19801
19802         * g10/server.c (cmd_passwd): Remove useless call to skip_options.
19803
19804         sm: Avoid warnings about useless assignments.
19805         + commit 126aebbb82667d160c8c4435898efeb3b43c4ec8
19806         * sm/call-dirmngr.c (prepare_dirmngr): Remove setting of ERR.
19807         (unhexify_fpr): Remove useless computation on N.
19808         * sm/certchain.c (do_validate_chain): Remove clearing of RC.  Remove
19809         useless setting of RC.
19810         * sm/fingerprint.c (gpgsm_get_keygrip): Remove setting of RC.
19811         * sm/gpgsm.c (build_list): Replace final stpcpy by strcpy.
19812         * sm/keydb.c (keydb_clear_some_cert_flags): Remove clearing of RC.
19813         * sm/server.c (cmd_getauditlog): Comment unused skip_options.
19814
19815         kbx: Avoid warnings about useless assignments.
19816         + commit 0de7d61437bd0bfbe645d5eed7a62df03129fb32
19817         * kbx/keybox-dump.c (_keybox_dump_blob): Remove setting of IN_RANGE
19818         and the last increment of P.
19819
19820         gpg: Fix DNS cert lookup returning an URL.
19821         + commit a41638acf4808caa619f4f3f4c0dcd12be00d6f8
19822         * g10/call-dirmngr.c (dns_cert_status_cb): Store URL status in the URL
19823         param.  The old code was entirely buggy (c+p error).
19824
19825 2016-01-06  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
19826
19827         Fix keystrlen to work when OPT.KEYID_FORMAT is KF_DEFAULT.
19828         + commit 2c3e67430d9b523c85c81ae562223fd51e3608cc
19829         * g10/keyid.c (keystrlen): If opt.keyid_format is KF_DEFAULT unset,
19830         default to KF_SHORT.
19831         (format_keyid): Default to KF_SHORT, not KF_0xLONG.
19832
19833 2016-01-06  Werner Koch  <wk@gnupg.org>
19834
19835         gpg: Silence some regression tests.
19836         + commit c7389ae90fa4a70766400cc241ff6a45aa750324
19837         * g10/test.c (TEST): Print diagnostics only in verbose mode.
19838
19839         gpg: Avoid using an uninitialized SALT on premature EOF.
19840         + commit 85cc7449fb00ac85b0c2eecd22bd38b23f33edf5
19841         * g10/parse-packet.c (parse_key): Check for premature end of salt.
19842
19843         gpg: Silence warnings found by static analyzer.
19844         + commit 09accc0e3d74e6289bed40b5bfc6479981cabfe4
19845         * g10/keyedit.c (change_passphrase): Remove useless init of ANY.
19846         (keyedit_quick_adduid): Remove useless setting of ERR.
19847         * g10/parse-packet.c (parse_key): Remove PKTLEN from condition because
19848         it has been checked before the loop.
19849         (parse_plaintext): Remove useless init of PKTLEN.
19850
19851         kbx: Avoid faulty fclose in an error case.
19852         + commit db82b6131d437bf6ba34db0e08b7dfa9edb11e45
19853         * kbx/keybox-update.c (blob_filecopy): Do not close an uninitialized
19854         file pointer after a failure to create a temp file.
19855         * kbx/keybox-openpgp.c (next_packet): Remove duplicate assignment of
19856         PKTLEN.
19857
19858         dirmngr: Silence one regression test.
19859         + commit 6deafb92abe100ff67e3a0a230a39e8c0ad41900
19860         * dirmngr/t-dns-stuff.c (main): Do not print info during standard
19861         "make check".
19862
19863         common: Avoid warnings about useless assignments.
19864         + commit e64317c15e9960f3173d374e589f7c3565a4ad08
19865         * common/b64enc.c (b64enc_finish): Remove var assignment which is not
19866         used later.
19867         * common/iobuf.c (file_filter): Ditto.
19868         * common/tlv.c (do_find_tlv): Ditto.
19869         * common/userids.c (classify_user_id): Ditto.
19870
19871         tests: Use info and error instead of a plain echo.
19872         + commit 1fbfa1bf0a6ad0dc7ed67d12252643c2c6c7370a
19873         * tests/openpgp/4gb-packet.test: Use error and info.
19874
19875         common: Do not deref vars in tests after a fail().
19876         + commit 0a00115ee2049ab2357b7a14a51c7da185ffcabd
19877         * common/t-convert.c (test_bin2hex): Turn if conditions into if-else
19878         chains to avoid accessing unchecked data.
19879         (test_bin2hexcolon): Ditto.
19880         * common/t-mapstrings.c (test_map_static_macro_string): Ditto.
19881         * common/t-stringhelp.c (test_percent_escape): Ditto.
19882         (test_make_filename_try): Ditto.
19883         (test_make_absfilename_try): Ditto.
19884         * common/t-timestuff.c (test_timegm): Ditto.
19885
19886 2016-01-05  Werner Koch  <wk@gnupg.org>
19887
19888         gpg: Align notes about minimal keysize with actual checks.
19889         + commit e70f7a54f29d727def2cfe9ea5ab9d461b4ce842
19890         * g10/keygen.c (ask_keysize): Use 768 for the minimal value for DSA in
19891         export mode.  Improve readability.
19892
19893 2016-01-05  NIIBE Yutaka  <gniibe@fsij.org>
19894
19895         agent: Fix RSA verification for card.
19896         + commit ff3b607fc879b70665c187500022cc63e2a0cd86
19897         * agent/pksign.c (agent_pksign_do): Use S-exp of public key, instead
19898         of shadowed key.
19899
19900 2016-01-04  Neal H. Walfield  <neal@g10code.com>
19901
19902         gpg: Fix double free.
19903         + commit 575c15a090913d86cf8d75b2bc4471e371f234b9
19904         * g10/getkey.c (get_pubkeys): Fix double free.
19905
19906 2015-12-24  NIIBE Yutaka  <gniibe@fsij.org>
19907
19908         agent: IMPORT_KEY with --force option fix.
19909         + commit 79b51bb8727bd3485229ac8ff5987558156d5d83
19910         * agent/cvt-openpgp.c (convert_from_openpgp_main): Add an option not
19911         to check existing key.
19912         (convert_from_openpgp): Ditto.
19913         (convert_from_openpgp_native): Call convert_from_openpgp_main with
19914         dontcare_exist=0.
19915         * agent/command.c (cmd_import_key): Call with dontcare_exist=force.
19916
19917         g10: Use --force when importing key for bkuptocard.
19918         + commit 5ca57f1a697e875bae5a5c73f1a580c42ca75343
19919         * g10/call-agent.c (agent_import_key): Add an argument FORCE.
19920         * g10/import.c (transfer_secret_keys): Likewise.
19921         (import_secret_one): Call transfer_secret_keys with FORCE=0.
19922         * g10/keyedit.c (keyedit_menu): Call with FORCE=1.
19923
19924         g10: Remove subcommand checkbkupkey for --key-edit.
19925         + commit 44aee35e69540510617aea4b886ef845590960fe
19926         * g10/keyedit.c (keyedit_menu): Remove cmdCHECKBKUPKEY support.
19927
19928         g10: Allow relative path for specifying the file for bkuptocard.
19929         + commit ee433d2b00c93b5a4e4ed54b9fb5806361df1b71
19930         * g10/keyedit.c (keyedit_menu): Assume the file is under GNUPGHOME.
19931         Also support tilda expansion.
19932
19933         g10: fix regression of bkuptocard subcommand in --edit-key.
19934         + commit 40959add1ba0efc1f4aa87fa075fa42423eff73c
19935         * g10/keyedit.c (keyedit_menu): Call transfer_secret_keys.
19936         * g10/import.c (transfer_secret_keys): Make it global function.
19937         Allow stats==NULL.
19938
19939         agent: Support --force option for IMPORT_KEY.
19940         + commit e684c634df814b12d399dcdc375c35d3e9a137af
19941         * agent/command.c (cmd_keywrap_key): New option --force.
19942
19943 2015-12-23  Werner Koch  <wk@gnupg.org>
19944
19945         gpg: Rename struct pubkey to pukey_s and add pubkey_t.
19946         + commit a9cbdcfd9c364557787f4a173cc59f14c067946e
19947         * g10/keydb.h (struct pubkey): Rename to pubkey_s.
19948         (pubkey_t): New.  Change all struct pubkey_s to use this type.
19949         * g10/getkey.c (get_pubkeys): Rename arg keys to r_keys.
19950
19951         gpg: Simplify status message code from commit b30c15bf.
19952         + commit 363ed2e892adc97fae97111bb56b64f9f809e8d5
19953         * g10/keygen.c (card_write_key_to_backup_file): Simplify by using
19954         hexfingerprint.
19955
19956         gpg: Add standard free() semantic to pubkey_free.
19957         + commit 04c9cddda95f2a8ca5c0cf10bb3dd6accf56cf45
19958         * g10/getkey.c (pubkey_free): Check for NULL arg.
19959
19960         gpg: Fix use of assert from commit dc417bf0.
19961         + commit ef7b7e91600f35b4d682a6267001a8d30f0fa49f
19962         * g10/keydb.c (keydb_update_keyblock): De-ref after the assert.  Use
19963         %zu for size_t.
19964
19965         gpg: Do not translate debug output.
19966         + commit b0c9867fb74d5a00335e6606d5bdcc5342ce26cd
19967         * g10/getkey.c (parse_def_secret_key): Do not make strings passed to
19968         log_debug translatable.
19969
19970 2015-12-23  NIIBE Yutaka  <gniibe@fsij.org>
19971
19972         scd: Fix commit b30c15bf (again).
19973         + commit aecf1a3c57ca8bf8050a3743b62fe142ccf9eb22
19974         * g10/keygen.c (do_generate_keypair): Clear the variable S.
19975
19976 2015-12-22  Neal H. Walfield  <neal@g10code.com>
19977
19978         gpg: Fix type.
19979         + commit 5c759924fb92b6de7ab3baed7871e5114ebd2505
19980         * g10/keygen.c (card_write_key_to_backup_file): Change n to a size_t.
19981
19982         gpg: Fix error message.
19983         + commit 4654384fe7a4dcee113dacf27c398b13dea5d0be
19984         * g10/getkey.c (parse_def_secret_key): Fix error message.
19985
19986         gpg: Don't check for ambiguous keys.
19987         + commit 7195b94345b0bb937477dc47fc5ec27fb108a099
19988         * g10/gpg.c (struct result): Move from here...
19989         * g10/keydb.h (struct pubkey): ... to here.  Update users.
19990         * g10/gpg.c (check_user_ids): Move from here...
19991         * g10/getkey.c (get_pubkeys): ... to here.  Update users.  Use
19992         get_pubkey_byname to look up the keys (this also prunes invalid keys).
19993         (pubkey_free): New function.
19994         (pubkeys_free): New function.
19995         * g10/gpg.c (main): Don't check for ambiguous key specifications.
19996
19997         gpg: Lazily evaluate --default-key.
19998         + commit dc52995d85048ed12ae8b9f330e9ca41a4030aae
19999         * g10/gpg.c (main): If --encrypt-to-default-key is specified, don't
20000         add --default-key's value to REMUSR here...
20001         * g10/pkclist.c (build_pk_list): ... do it here.
20002         * tests/openpgp/Makefile.am (TESTS): Add default-key.test.
20003         * tests/openpgp/default-key.test: New file.
20004
20005         gpg: Remove unused parameter.
20006         + commit ffe0b7a6dd6bfaec62f81f511b3caf08978bb269
20007         * g10/pkclist.c (build_pk_list): Remove parameter use, which is always
20008         called set to PUBKEY_USAGE_ENC.  Update callers.
20009
20010         gpg: Improve check for ambiguous keys.
20011         + commit 4103850c2e51274984f69443dee34295cbb8c282
20012         * g10/gpg.c (check_user_ids): When checking for ambiguous keys, ignore
20013         encryption-only keys when a signing key is needed and vice-versa.
20014
20015         gpg: Fix TOCTTOU when updating keyblocks.
20016         + commit dc417bf0c555a7416d0aedde6645fd1087660f92
20017         * g10/keydb.c (keydb_update_keyblock): Don't replace the record at the
20018         current offset.  After taking the lock, extract the fingerprint from
20019         the keyblock, find it and then replace it.
20020
20021         Only add the user supplied CFLAGS after running any autoconf tests.
20022         + commit 02eb9fc9d5863abcfed6af704e618f8cac7cc2e8
20023         * configure.ac: Only add the user supplied CFLAGS after running any
20024         autoconf tests.
20025
20026         gpg: Suppress a warning.
20027         + commit 1cceba163b17b5e9fd7c89e5b40e3d7e1cffc885
20028         * dirmngr/dns-stuff.c (enable_dns_tormode): Reference new_circuit to
20029         avoid a warning when ADNS is not available.
20030
20031         gpg: Remove dead code.
20032         + commit 4143cc1c3783c54a6f733f08a4739e4e5fb0c8b3
20033         * kbx/keybox-defs.h (struct keybox_found_s): Remove unused fields
20034         offset and n_packets.
20035
20036         gpg: Display the key that is invalid, not the search description.
20037         + commit 7fe4be0416cdc9269011bc4213b8a22d6ced295c
20038         * g10/getkey.c (parse_def_secret_key): Display the key that is
20039         invalid, not the search description.
20040
20041         gpg: Mark more options as coming from the config file (when this holds)
20042         + commit 478ca6c75bbf529f95974224dfb7d71bd5860a96
20043         * g10/gpg.c (main): When --default-key or --encrypt-to-default-key is
20044         taken from the config file, note this.
20045
20046         gpg: Use enums instead of defines.
20047         + commit ee8a8ec1cf4605e5af427f9c8b01b3609c82cbe7
20048         * g10/keydb.h (PK_LIST_ENCRYPT_TO): Change from a macro to an enum.
20049         (PK_LIST_HIDDEN): Likewise.
20050         (PK_LIST_CONFIG): Likewise.
20051         (PK_LIST_SHIFT): Likewise.n
20052
20053 2015-12-21  NIIBE Yutaka  <gniibe@fsij.org>
20054
20055         po: Update Japanese translation.
20056         + commit d8392299f311f8cfcf8bc02679dd3ae7ef8cc6d7
20057
20058
20059         g10: clean up of headers for card.
20060         + commit ab9a9bce77d014159c68460f5a7c263fb72f3c1c
20061         * g10/main.h (save_unprotected_key_to_card): Remove.
20062         * g10/options.h (ctapi_driver, pcsc_driver, disable_ccid): Remove.
20063
20064 2015-12-21  Werner Koch  <wk@gnupg.org>
20065
20066         common: New file fwddecl.h.
20067         + commit 98f9e14323bf806f674b3cc259e19ef6219b4378
20068         * common/util.h (server_control_s, ctrl_t): Move to ...
20069         * common/fwddecl.h: New file.
20070         * common/call-gpg.h: Replace typedef by fwddecl.h.  Change include
20071         protection macro name.
20072         * common/Makefile.am (common_sources): Add fwddecl.h.
20073
20074 2015-12-18  Werner Koch  <wk@gnupg.org>
20075
20076         build: Add required macro for pkg-config.
20077         + commit af142854a73567836a0ca44ad62900469c23d531
20078         * configure.ac (PKG_PROG_PKG_CONFIG): New.
20079
20080 2015-12-18  NIIBE Yutaka  <gniibe@fsij.org>
20081
20082         g10: Remove deprecated internal functions.
20083         + commit 72eaff1aa610f3c89a755f212760157e1932d847
20084         * g10/keygen.c (do_ask_passphrase, generate_raw_key)
20085         (gen_card_key_with_backup, save_unprotected_key_to_card): Remove.
20086
20087         g10: Fix a regression for generating card key with backup.
20088         + commit b30c15bf7c5336c4abb1f9dcd974cd77ba6c61a7
20089         * g10/main.h (receive_seckey_from_agent): Declare.
20090         * g10/keygen.c (card_write_key_to_backup_file): New.
20091         (card_store_key_with_backup): New.
20092         (do_generate_keypair): Create a key on host for encryption key when
20093         backup is requested.  Then, call card_store_key_with_backup.
20094
20095 2015-12-17  NIIBE Yutaka  <gniibe@fsij.org>
20096
20097         g10: factor out a function for secret key retrieval.
20098         + commit e644aa7f5943174e3f7ba9408af71531fd125a0b
20099         * g10/export.c (receive_seckey_from_agent): New.
20100         (do_export_stream): Use it.
20101
20102 2015-12-16  Neal H. Walfield  <neal@g10code.com>
20103
20104         gpg: When checking for ambiguous keys, ignore invalid keys.
20105         + commit fc010b6c7fe14e609734e448775fa384421bdef1
20106         * g10/gpg.c (check_user_ids): When checking for ambiguous keys, ignore
20107         disabled, revoked and expired keys (if appropriate for the provided
20108         option).
20109
20110 2015-12-15  Werner Koch  <wk@gnupg.org>
20111
20112         common: Use default_errsource for call-gpg and exectool.
20113         + commit 4ffe44c5874ed655d82adfa7a85439fab91cde03
20114         * common/call-gpg.c (my_error_from_syserror, my_error_from_errno): New.
20115         Use these wrappers.
20116         * common/exectool.c (my_error_from_syserror): New.  Use these
20117         wrappers.
20118
20119         gpg: Reduce number of strings to translate.
20120         + commit 345ec7323d643528d2f904765708b5ecfe51f57b
20121         * g10/getkey.c (parse_def_secret_key): Do not make debug messages
20122         translatable.  Make use of print_reported_error.
20123
20124         gpg: New function to printed a detailed error code.
20125         + commit 2ea1aebc924c3f0b2269f83cb1b80c75d9fa069c
20126         * g10/misc.c (print_reported_error): New.
20127
20128 2015-12-15  Neal H. Walfield  <neal@g10code.com>
20129
20130         gpg: Improve the keyblock cache's transparency.
20131         + commit f369efd6712148dc7ed40dba6d1ff5b0e169431a
20132         * kbx/keybox-search.c (keybox_seek): New function.
20133         * g10/keydb.c (keydb_search): When reading from the cache, seek to
20134         just after the cached record.
20135
20136         gpg: Improve the keyblock cache's transparency.
20137         + commit 2e4e10c1dcd8dfeafec51f44ebf26acfeb770c41
20138         * kbx/keybox-search.c (keybox_offset): New function.
20139         * g10/keydb.c (struct keyblock_cache): Add fields resource and offset.
20140         (keyblock_cache_clear): Reset HD->KEYBLOCK_CACHE.RESOURCE and
20141         HD->KEYBLOCK_CACHE.OFFSET.
20142         (keydb_search): Don't use the cached result if it comes before the
20143         current file position.  When caching an entry, also record the
20144         position at which it was found.
20145
20146         gpg: Use more descriptive names.
20147         + commit 0ea186db645da2b51a7e71f46793d447f2de5e3d
20148         * g10/keyring.c (KR_NAME): Rename this...
20149         (KR_RESOURCE): ... to this.  Update users.
20150         (struct keyring_name): Rename this...
20151         (struct keyring_resource): ... to this.  Update users.
20152         (struct off_item): Rename this...
20153         (struct key_present): ... to this.  Update users.
20154         (OffsetHashTable): Rename this...
20155         (key_present_hash_t): ... to this.  Update users.
20156         (kr_offtbl): Rename this...
20157         (key_present_hash): ... to this.  Update users.
20158         (kr_offtbl_ready): Rename this...
20159         (key_present_hash_ready): ... to this.  Update users.
20160         (KEY_PRESENT_HASH_BUCKETS): New define.  Replace use of literals
20161         with this.
20162         (new_offset_item): Rename this...
20163         (key_present_value_new): ... to this.  Update users.
20164         (release_offset_items): Drop dead code.
20165         (new_offset_hash_table): Rename this...
20166         (key_present_hash_new): ... to this.  Update users.
20167         (release_offset_hash_table): Drop dead code.
20168         (lookup_offset_hash_table): Rename this...
20169         (key_present_hash_lookup): ... to this.  Update users.
20170         (update_offset_hash_table): Rename this...
20171         (key_present_hash_update): ... to this.  Drop unused parameter off.
20172         Update users.
20173         (update_offset_hash_table_from_kb): Rename this...
20174         (key_present_hash_update_from_kb): ... to this.  Drop unused parameter
20175         off.  Update users.
20176
20177 2015-12-15  NIIBE Yutaka  <gniibe@fsij.org>
20178
20179         sm: Handle gcry_pk_encrypt return value.
20180         + commit 4ee881bff4c8fdfa4b3b7a4b7afab611471e97f1
20181         * sm/encrypt.c (encrypt_dek): Don't ignore failure of gcry_pk_encrypt.
20182
20183 2015-12-14  Werner Koch  <wk@gnupg.org>
20184
20185         common: Change license of isascii.c to all-premissive,
20186         + commit 7baca033070e7811f75e2021100adf8e6a48907f
20187         * common/isascii.c: Change.
20188
20189         common: Change license of some modules to LGPLv3+/GPLv2+.
20190         + commit 7d129a7391115ff1d6a3541078a37a630ab7819f
20191         * common/status.c: Change from GPLv3 to LGPLv3+/GPLv2+.
20192         * common/status.h: Ditto.
20193         * common/yesno.c: Ditto.
20194         * common/common-defs.h: Ditto.
20195         * common/gettime.h: Ditto.
20196         * common/keyserver.h: Ditto.
20197
20198         common: Change license for exectool to LGPLv3+/GPLv2+.
20199         + commit 467e18b74b4790dcbdf3c816206d2fbaf170a12a
20200         * common/exectool.c, common/exectool.h: Change license.
20201
20202         common: Rename sh-exectool to exectool.
20203         + commit d80e1bc430bf64debdb6b08f0b7e5c42836781fa
20204         * common/sh-exectool.c: Rename to exectool.c.
20205         * common/sh-exectool.h: Rename to exectool.h.
20206         * common/Makefile.am (common_sources): Adjust for rename.
20207         * common/exectool.c (sh_exec_tool_stream): Rename to
20208         gnupg_exec-tool-stream.
20209         (sh_exec_tool): Rename to gnupg_exec_tool.
20210         * tools/gpgtar-create.c (gpgtar_create): Adjust for changes.
20211         * tools/gpgtar-extract.c: Adjust for changes.
20212         * tools/gpgtar-list.c: Adjust for changes.
20213
20214 2015-12-14  Damien Goutte-Gattat  <dgouttegattat@incenp.org>
20215
20216         gpg: Print ownertrust in TOFU+PGP trust model.
20217         + commit f5aa51aaacfe13ab9528aa9b88d8ce8eb61362fc
20218         * g10/keyedit.c: Print ownertrust in TOFU+PGP trust model.
20219
20220 2015-12-14  Neal H. Walfield  <neal@g10code.com>
20221
20222         gpg: Fix --default-key checks.
20223         + commit e573e6188dada4d70f6897aa2fda3c3af8c50441
20224         * g10/getkey.c (parse_def_secret_key): Don't just check if a secret
20225         key is available for the public key, also consider subkeys.  Also
20226         check that the key has the signing capability, is not revoked, is not
20227         expired and is not disabled.  Print a warning if there was a least one
20228         value passed to --default-key and all were ignored.
20229
20230 2015-12-14  NIIBE Yutaka  <gniibe@fsij.org>
20231
20232         scd: Fix regression for generating RSA keys on card.
20233         + commit d40975cbe8ff86fcc4a1b4963fdffc66ddee85ce
20234         * scd/app-openpgp.c (do_genkey): Strip leading zeros for fingerprint
20235         computation.
20236
20237 2015-12-12  Werner Koch  <wk@gnupg.org>
20238
20239         gpg: Use a regular type instead of a void* for import stats.
20240         + commit 4d3395ef1fcde0b8c454c09956863959d590ede6
20241         * g10/import.c (struct stats_s): Rename to import_stats_s.  Change all
20242         users.
20243         * g10/main.h (import_stats_t): New.  Change fucntions to use this
20244         instead of a void pointer.
20245
20246         Remove replacements for libgpg-error < 1.21.
20247         + commit f0ae40b0c901e5f5c04c6ed5b2ab96ab7340b2bd
20248         * common/util.h: Remove replacement macros for libgpg-error<1.21.
20249         * common/types.h: Ditto.
20250         * common/mischelp.h: Ditto.
20251         * common/t-mapstrings.c: Include t-support.h before stringhelp.h
20252         * common/t-stringhelp.c: Ditto.
20253         * common/t-support.h: Always include gpg-error.h.
20254         * kbx/keybox-search.c: Do not include stringhelp.h so that keybox-defs
20255         comes first.
20256
20257 2015-12-11  Neal H. Walfield  <neal@g10code.com>
20258
20259         gpg: Fix buffer overflow.
20260         + commit 1605e34fc365edd473aac15c9b4e5aadc1d95cf5
20261         * g10/keydb.c (keydb_search_desc_dump): Fix buffer overflow.
20262
20263 2015-12-11  Justus Winter  <justus@g10code.com>
20264
20265         agent: Improve error handling.
20266         + commit 25f0f053cd306200a6211b5cf397838a59835ee7
20267         * agent/pksign.c (agent_pksign_do): Improve error handling.
20268
20269         Fix required libgpg-error version.
20270         + commit d6e01493cad6ff32f356185c7a2d2b5c2b86a937
20271         * configure.ac (NEED_GPG_ERROR_VERSION): We need version 1.21 for the
20272         poll interface.
20273
20274 2015-12-11  Neal H. Walfield  <neal@g10code.com>
20275
20276         gpg: Don't error out if a key occurs multiple times in the keyring.
20277         + commit 6dc37c5fb60acbfd5ba2ab979852383eac8944e0
20278         * g10/gpg.c (check_user_ids): Don't error out if a key occurs multiple
20279         times in the keyring.  Instead, print a warning.  When printing out
20280         fingerprint prints, use format_hexfingerprint to format them.
20281
20282 2015-12-10  Daniel Hoffend  <dh@dotlan.net>
20283
20284         scd: Fix removal of unplugged usb readers on Windows.
20285         + commit d1a97585c5e73fbc7d4cf90e38f76ffc5aea305f
20286         * scd/apdu.c (pcsc_error_to_sw): map PCSC_E_NO_SERVICE and
20287         PCSC_E_SERVICE_STOPPED to the internal SW_HOST_NO_READER error code.
20288
20289 2015-12-07  Justus Winter  <justus@g10code.com>
20290
20291         tests: Add some more gpgtar tests.
20292         + commit 1c8eae95a8b3b89bc0f49cb5f4938101634583dc
20293         * tests/openpgp/gpgtar.test: Add more tests.
20294
20295         dirmngr: Initialize http status code.
20296         + commit 71726b627dcff015dc12568021b31d8ccede788a
20297         * dirmngr/ks-action.c (ks_action_search): Initialize 'http_status' as
20298         it is unused if LDAP is used to search for keys.
20299
20300 2015-12-04  Daiki Ueno  <ueno@gnu.org>
20301
20302         gpg: Write ERROR status on delete-key cancellation.
20303         + commit b5cd68852d0e3485c9e13a8ddb70f05f36a65cb9
20304         * g10/delkey.c (do_delete_key): Write ERROR status code with the error
20305         location "delete_key.secret", when the user cancelled the operation on
20306         Pinentry.
20307
20308 2015-12-04  Justus Winter  <justus@g10code.com>
20309
20310         dirmngr: Stricter handling of http error codes.
20311         + commit 6d64ef869dfbcb7aaa802b80ed648393147e40d8
20312         * dirmngr/ks-action.c (ks_action_search): Only retry if the keyserver
20313         responded with a '404 Not Found'.
20314         * dirmngr/ks-engine-hkp.c (send_request): Return http status code.
20315         (ks_hkp_search): Likewise.
20316         (ks_hkp_{get,put}): Adapt call to 'send_request'.
20317         * dirmngr/ks-engine.h (ks_hkp_search): Update prototype.
20318
20319         dirmngr: Really search all keyservers for patterns.
20320         + commit 6ac57a482f7ae02db1bee4e4b861288fc6905adc
20321         * dirmngr/ks-action.c (ks_action_search): Search all configured
20322         keyservers for the given patterns.
20323
20324         dirmngr: Handle http status '501 Not Implemented'.
20325         + commit a8308ba5231682ce7c7d591a17e7e940fbd63189
20326         * dirmngr/ks-engine-hkp.c (send_request): Handle status 501 and return
20327         GPG_ERR_NOT_IMPLEMENTED.
20328
20329         tools/gpgtar: Implement symmetric encryption.
20330         + commit 582e684a48eb4f3716cecf7dc73eb93046efcfad
20331         * tests/openpgp/gpgtar.test: Add test case.
20332         * tools/gpgtar-create.c (gpgtar_create): Pass '--symmetric' flag to
20333         gpg.
20334         * tools/gpgtar.c (parse_arguments): We do handle the argument now.
20335
20336         tools/gpgtar: Implement signing.
20337         + commit 45c814f348c89acd8d21d0607ffcf68e5c5c399e
20338         * tests/openpgp/gpgtar.test: Test signing.
20339         * tools/gpgtar-create.c (gpgtar_create): Add 'sign' option, add the
20340         appropriate gpg arguments to implement signing and selecting the local
20341         user.
20342         * tools/gpgtar.c (parse_options): We do handle '--local-user' now.
20343         (main): Handle signing, encrypting, and doing both when creating an
20344         archive.
20345         * tools/gpgtar.h (gpgtar_create): Update prototype.
20346
20347         tools/gpgtar: Use the new exectool helper.
20348         + commit 0c0dafd8e89bb702e856c661c1561e10cdcaf37f
20349         * tools/Makefile.am: gpgtar now requires neither npth nor libassuan.
20350         * tools/gpgtar-create.c (gpgtar_create): Use the new 'sh-exectool'
20351         helper.
20352         * tools/gpgtar-extract.c (gpgtar_extract): Likewise.
20353         * tools/gpgtar-list.c (gpgtar_list): Likewise.
20354         * tools/gpgtar.c (main): Set default gpg program.  Drop the
20355         initialization of npth and libassuan.
20356
20357         common: Add a stream interface to 'sh-exectool'.
20358         + commit a81aca6e1c2a4529d416d1989f15d7338d2ee81e
20359         * common/sh-exectool.c (struct copy_buffer): Add infrastructure for
20360         copying between streams.
20361         (copy_buffer_{init,shred,do_copy,flush}): New functions.
20362         (sh_exec_tool_stream): Rework 'sh_exec_tool' to operate on streams.
20363         (nop_free): New function.
20364         (sh_exec_tool): Express this in terms of 'sh_exec_tool_stream'.
20365         * common/sh-exectool.h (sh_exec_tool_stream): New prototype.
20366
20367         common: Add header file and build the new code.
20368         + commit d955cb5e0700c6d2b6b26cb210b5a176d22d4235
20369         * common/Makefile.am (common_sources): Add new files.
20370         * common/sh-exectool.h: New file.
20371
20372 2015-12-04  Werner Koch  <wk@gnupg.org>
20373
20374         common: Add code to execute a helper.
20375         + commit 2ae07f826aa551db8adf714158fce962790a6b54
20376         * common/sh-exectool.c: New file.
20377
20378         Release 2.1.10.
20379         + commit 9fadfdb3109f7ea42aaaa9d745b64c6c90cb8233
20380
20381
20382 2015-12-04  NIIBE Yutaka  <gniibe@fsij.org>
20383
20384         po: Japanese translation.
20385         + commit 762fcc027b0b4cc88c1f633804de619273d6a8b9
20386
20387
20388 2015-12-04  Werner Koch  <wk@gnupg.org>
20389
20390         speedo,w32: Improve installer.
20391         + commit 0fe3614d9afe42ecf80bbc932366ceeaba0a0ecc
20392         * build-aux/speedo/w32/inst.nsi (SEC_gnupg): Install dirmngr.conf and
20393         distsigkey.gpg.
20394         (un.gnupglast): Stop dirmngr.
20395
20396         gpg: Do not pre-check keys given on the command line.
20397         + commit 28311d1fa56bfbd801103a8475597459132874f4
20398         * g10/keydb.h (PK_LIST_ENCRYPT_TO, PK_LIST_HIDDEN, PK_LIST_CONFIG)
20399         (PK_LIST_SHIFT): New.
20400         * g10/pkclist.c (build_pk_list): Use them here.
20401         * g10/gpg.c (check_user_ids, main): Ditto.
20402
20403         * g10/gpg.c (main): Set PK_LIST_CONFIG for REMUSR and LOCUSR.
20404         (check_user_ids): Skip check for command line specified options.
20405
20406         dirmngr: Add command to print the resolver version.
20407         + commit 4ff2cae7dee36ffee854c5f05c3e8ee9eb0308dd
20408         * dirmngr/server.c (cmd_getinfo): Add sub-command "dnsinfo".
20409
20410         gpg: Allow "help" as value for --tofu-policy.
20411         + commit 59f6192cb766612ad215bc6a3af13d5b137139e4
20412         * g10/gpg.c (parse_tofu_policy): Add keyword "help".
20413         (parse_tofu_db_format): Ditto.
20414
20415         Do not translate messages printed with log_debug.
20416         + commit 218a52787a87be6b7481a39f87d212d6ef594e97
20417         * common/asshelp.c (start_new_gpg_agent): Do not i18n string.
20418         (start_new_dirmngr): Ditto.
20419         * g10/mainproc.c (proc_encrypted): Ditto.  Print only if debug is
20420         enabled.
20421
20422 2015-12-04  NIIBE Yutaka  <gniibe@fsij.org>
20423
20424         scd: Fix for removing the prefix.
20425         + commit f03976f1101f539a2782cd9e87d640fc32a022db
20426         * scd/app-openopg.c (do_decipher): Fix the condition.
20427
20428         scd: Simplify saving application context.
20429         + commit 9639af5f16a7ed908cbce2415330b9fcd88edc90
20430         * scd/app.c (lock_table): Remove LAST_APP field.
20431         (lock_reader, app_dump_state, application_notify_card_reset)
20432         (release_application): Follow the change.
20433         (check_conflict): New.
20434         (check_application_conflict): Lock the slot and call check_conflict.
20435         (select_application): Call check_conflict and not use LAST_APP.
20436
20437         scd: More fix for Curve25519 prefix handling.
20438         + commit f747adfa21551e083bc947540c64c94a96dcc059
20439         * scd/app-openpgp.c (do_decipher): Handle trancated cipher text.
20440         Also fix xfree bug introduced.
20441
20442 2015-12-03  Werner Koch  <wk@gnupg.org>
20443
20444         scd: Another fix for Curve25519 prefix handling.
20445         + commit e28f2e7a2f265af8bbdb4979e9679b4396dccdd5
20446         * scd/app-openpgp.c (do_decipher): Check 0x02 also for 16+1 byte long
20447         INDATA.
20448         (do_decipher): Fix integer arithmetic in void pointer.
20449         (do_decipher): Add missing memcpy.
20450
20451         build: Avoid dependecy problems in "make distcheck".
20452         + commit 0f61599ed0bd1cc6842067d040bb58ec0a451715
20453         * doc/Makefile.am (gnupg.texi): Depend on defs.inc.
20454
20455         build: Change how caller provided CFLAGS are used by configure.
20456         + commit 4e9957250eee3521dc979912a4818e58ffddc5b8
20457         * configure.ac: Append instead of prepend caller provided CFLAGS.
20458
20459         gpg: Add variant of 'key "%s" not found: %s' error message.
20460         + commit 5e2c5e9ec5b75fae886e1294adbdb7ad2ac12827
20461         * g10/gpg.c (check_user_ids): Change error message.
20462         * g10/delkey.c (do_delete_key): Ditto.
20463
20464         gpg: Make keyidlist more robust in case of errors.
20465         + commit 50a568e7380752454c029eac2b57d8803b1cb287
20466         * g10/keyserver.c (keyidlist): Clear *KLIST on error.
20467
20468         gpg: Take care of keydb_new returning NULL.
20469         + commit a28ac99efead8be73ea1704abe1611ccc4811c54
20470         * g10/keydb.c (keydb_new): Print an error message if needed.  Also use
20471         xtrycalloc because we return an error anyway.
20472         * g10/delkey.c (do_delete_key): Handle error retruned by keydb_new.
20473         * g10/export.c (do_export_stream): Ditto.
20474         * g10/getkey.c (get_pubkey): Ditto.
20475         (get_pubkey_fast): Ditto.
20476         (get_pubkeyblock): Ditto.
20477         (get_seckey): Ditto.
20478         (key_byname): Ditto.
20479         (get_pubkey_byfprint): Ditto.
20480         (get_pubkey_byfprint_fast): Ditto.
20481         (parse_def_secret_key): Ditto.
20482         (have_secret_key_with_kid): Ditto.
20483         * g10/import.c (import_one): Ditto.
20484         (import_revoke_cert): Ditto.
20485         * g10/keyedit.c (keyedit_quick_adduid): Ditto.
20486         * g10/keygen.c (quick_generate_keypair): Ditto.
20487         (do_generate_keypair): Ditto.
20488         * g10/trustdb.c (validate_keys): Ditto.
20489         * g10/keyserver.c (keyidlist): Ditto.
20490         * g10/revoke.c (gen_desig_revoke): Ditto.
20491         (gen_revoke): Ditto.
20492         * g10/gpg.c (check_user_ids): Ditto.
20493         (main): Do not print an error message for keydb_new error.
20494         * g10/keylist.c (list_all): Use actual error code returned by
20495         keydb_new.
20496
20497         * g10/t-keydb-get-keyblock.c (do_test): Abort on keydb_new error.
20498         * g10/t-keydb.c (do_test): Ditto.
20499
20500         * g10/keyring.c (keyring_new): Actually return an error so that the
20501         existing keydb_new error checking makes sense for a keyring resource.
20502         (keyring_rebuild_cache): Take care of keyring_new returning an error.
20503
20504         gpg: Change some error messages.
20505         + commit 9fcc047d921bde95b6807325b7fd2b697e89907f
20506         * g10/getkey.c (parse_def_secret_key): Change error message.  Replace
20507         log_debug by log_info.
20508         * g10/gpg.c (check_user_ids): Make function static.  Change error
20509         messages.
20510         (main): Change error messages.
20511         * g10/revoke.c (gen_revoke): Ditto.
20512
20513 2015-12-03  NIIBE Yutaka  <gniibe@fsij.org>
20514
20515         scd: Fix "Conflicting usage" bug.
20516         + commit f42c50dbf00c2e6298ca6830cbe6d36805fa54a3
20517         * scd/apdu.c (apdu_close_reader): Call CLOSE_READER method even if we
20518           got an error from apdu_disconnect.
20519         * scd/app-common.h (no_reuse): Remove.
20520         * scd/app.c (application_notify_card_reset): Deallocate APP here.
20521         (select_application, release_application): Don't use NO_REUSE.
20522
20523         scd: Fix for Curve25519 prefix handling.
20524         + commit 11b2691eddc42e91651e4f95dd2731255a3e9211
20525         * scd/app-openpgp.c (do_decipher): More condition for AES decipher.
20526           Handle the prefix in cipher text.  Always add the prefix in result.
20527
20528 2015-12-03  Neal H. Walfield  <neal@g10code.com>
20529
20530         gpg: Use the matching key if the search description is exact.
20531         + commit cedbd4709eed6fead9d1b271f96860c00547c77c
20532         * g10/gpg.c (check_user_ids): If the search description is for an
20533         exact match (a keyid or fingerprint that ends in '!'), then use the
20534         matching key, not the primary key.
20535         * tests/openpgp/Makefile.am (TESTS): Add use-exact-key.test.
20536         (priv_keys): Add privkeys/00FE67F28A52A8AA08FFAED20AF832DA916D1985.asc,
20537         privkeys/1DF48228FEFF3EC2481B106E0ACA8C465C662CC5.asc,
20538         privkeys/A2832820DC9F40751BDCD375BB0945BA33EC6B4C.asc,
20539         privkeys/ADE710D74409777B7729A7653373D820F67892E0.asc and
20540         privkeys/CEFC51AF91F68A2904FBFF62C4F075A4785B803F.asc.
20541         (sample_keys): Add
20542         samplekeys/E657FB607BB4F21C90BB6651BC067AF28BC90111.asc.
20543         * tests/openpgp/privkeys/00FE67F28A52A8AA08FFAED20AF832DA916D1985.asc:
20544         New file.
20545         * tests/openpgp/privkeys/1DF48228FEFF3EC2481B106E0ACA8C465C662CC5.asc:
20546         New file.
20547         * tests/openpgp/privkeys/A2832820DC9F40751BDCD375BB0945BA33EC6B4C.asc:
20548         New file.
20549         * tests/openpgp/privkeys/ADE710D74409777B7729A7653373D820F67892E0.asc:
20550         New file.
20551         * tests/openpgp/privkeys/CEFC51AF91F68A2904FBFF62C4F075A4785B803F.asc:
20552         New file.
20553         * tests/openpgp/samplekeys/E657FB607BB4F21C90BB6651BC067AF28BC90111.asc:
20554         New file.
20555         * tests/openpgp/use-exact-key.test: New file.
20556         * tests/openpgp/version.test: Install the new private keys.
20557
20558 2015-12-02  Werner Koch  <wk@gnupg.org>
20559
20560         build: Require at least Libassuan 2.4.1.
20561         + commit 69db3285e4612ad24462149a4d64cc32c090a491
20562         * configure.ac (NEED_LIBASSUAN_VERSION): Set to 2.4.1.
20563         * agent/gpg-agent.c (create_server_socket): Remove check for
20564         libassuan >= 2.3.0 and >= 2.1.4.
20565         (main): Remove check for libassuan >= 2.1.4.
20566         * scd/scdaemon.c (create_server_socket): Remove check for
20567         libassuan >= 2.1.4.
20568         * dirmngr/dirmngr.c (set_tor_mode): Remove check for
20569         libassuan >= 2.3.0.
20570         * dirmngr/http.c (http_raw_connect, send_request): Remove checks for
20571         libassuan >= 2.3.0.
20572
20573 2015-12-02  Neal H. Walfield  <neal@g10code.com>
20574
20575         gpg: Improve documentation.
20576         + commit 28195f8d27aa0fc9daf5b74fb24de87c36e04739
20577         * g10/tofu.c (initdb): Improve documentation.
20578
20579         gpg: Fix type mismatch resulting in a buffer overflow.
20580         + commit c73d75103cbd34975e2bd28e9924caee05eaf829
20581         * g10/tofu.c (record_binding): Change policy_old's type from an enum
20582         tofu_policy to a long: this variable is passed by reference and a long
20583         is expected.
20584
20585 2015-12-02  Werner Koch  <wk@gnupg.org>
20586
20587         dirmngr: Switch to an onion address if Tor is running.
20588         + commit 28e2513721ff0cec920564d4087f3600cce8672e
20589         * dirmngr/dirmngr.h (opt): Turn field 'keyserver' into an strlist.
20590         * dirmngr/dirmngr.c (parse_rereadable_options): Allow multiple
20591         --keyserver options.
20592         * dirmngr/server.c (server_local_s): Add field 'tor_state'.
20593         (release_uri_item_list): New.
20594         (release_ctrl_keyservers): Use it.
20595         (start_command_handler): Release list of keyservers.
20596         (is_tor_running): New.
20597         (cmd_getinfo): Re-implement "tor" subcommand using new fucntion.
20598         (ensure_keyserver): Rewrite.
20599         * g10/dirmngr-conf.skel: Add two keyserver options.
20600
20601         http: Enhance parser to detect .onion addresses.
20602         + commit 17ac843871d5f350f26edff0187f94ced923f534
20603         * dirmngr/http.h (parsed_uri_s): Add flag 'onion'.
20604         * dirmngr/http.c (do_parse_uri): Set that flag.
20605         * dirmngr/t-http.c (main): Print flags.
20606
20607 2015-12-02  Neal H. Walfield  <neal@g10code.com>
20608
20609         common,gpg: Fix processing of search descriptions ending in '!'.
20610         + commit 10cca02c4c70eee993d4df0a1d20ae841992efe9
20611         * g10/gpg.c (check_user_ids): If the search description describes a
20612         keyid or fingerprint and ends in a '!', include the '!' in the
20613         rewritten description.
20614         * common/userids.c (classify_user_id): Accept keyids and fingerprints
20615         ending in '!'.
20616
20617 2015-12-01  Justus Winter  <justus@g10code.com>
20618
20619         dirmngr: Improve error handling.
20620         + commit 9c34711539fc2c34aea8da0fd49ae6aa28991518
20621         * dirmngr/dns-stuff.c (getsrv): Avoid looking at 'header' before
20622         checking for errors, but silently ignore errors when looking up SRV
20623         records.
20624
20625 2015-12-01  Werner Koch  <wk@gnupg.org>
20626
20627         build: Let configure show the the status of Tor support.
20628         + commit 3be12d1e1b8334fb2bba307ec9efbc004f1dbf8d
20629         * configure.ac (show_tor_support): New
20630
20631 2015-11-30  Werner Koch  <wk@gnupg.org>
20632
20633         doc: Make make distcheck work again.
20634         + commit 4ecb5db804003c10c57bdc0dc7f1d9649c5ba6f8
20635         * doc/Makefile.am (DISTCLEANFILES): Add gpgkey2ssh.1
20636
20637         yat2m: Add keyword @url.
20638         + commit b4756a54a55fcd51717c149e19191a2eeaa6a919
20639         * doc/yat2m.c (proc_texi_cmd): Add keyword @url.
20640
20641         doc: Build man pages with the same date as the info files.
20642         + commit 081c902f16a2f251df4593f090b3978dfa473a26
20643         * doc/Makefile.am (yat2m-stamp): Use option --date.
20644
20645         yat2m: New option --date.
20646         + commit 75eb071354d1f862bac09c56c8ab81dae8883270
20647         * doc/yat2m.c (opt_date): new.
20648         (isodatestring): Use it if set.
20649         (main): New option --date.
20650
20651 2015-11-27  Werner Koch  <wk@gnupg.org>
20652
20653         gpg: Avoid extra translation strings.
20654         + commit 686f31c3d5aee0d2825265869ae92ca95cdcabae
20655         * g10/keyedit.c (menu_expire): Use only one prompt.
20656
20657         kbx: Include gpg-error prior to mischelp.h.
20658         + commit 436a154ea85e4dffbde7c3b316fbfca1b066aa2a
20659         * kbx/keybox-init.c: Change order of includes.
20660
20661         gpg,w32: Fix a format string error.
20662         + commit 7c856f99144b84ac30e0c9a192f09dc36d93190a
20663         * g10/keyring.c (keyring_search): Fix format string for off_t.
20664
20665         Silence compiler warnings related to not using assuan_fd_t.
20666         + commit 501436ab0f9d8e7d56b2f5e344006be5f5a3c653
20667         * common/call-gpg.c (start_gpg): Use assuan_fd_t.  Note that the
20668         declaration was already fixed by a previous change.
20669         * dirmngr/server.c (cmd_getinfo): Use assuan_fd_t.
20670
20671         Avoid incompatible pointer assignment warnings on Windows.
20672         + commit 64e87083394d38998feab359caac917bcc6139d3
20673         * common/logging.c (fun_writer): Use gpgrt_ssize_t instead of ssize_t.
20674         * dirmngr/server.c (data_line_cookie_write): Ditto.
20675         * sm/certdump.c (format_name_writer): Ditto.
20676         * sm/server.c (data_line_cookie_write): Ditto.
20677         * dirmngr/http.c (cookie_read, cookie_write): Ditto.
20678
20679         dirmngr: Avoid a declarations after statements.
20680         + commit 100f34e869df899a695f5e5ef1b8e092baf91751
20681         * tools/gpgtar.c (parse_arguments): Use a block for a local varibale
20682         definition.
20683
20684         dirmngr: Avoid casting away a const from an char**.
20685         + commit 6501741d2c1beb8060198a39a1aa950cb11b386f
20686         * dirmngr/ldap.c (start_cert_fetch_ldap): Do not use pointers from
20687         global variables.
20688
20689         dirmngr: Allow testing for a running Tor via "getinfo tor".
20690         + commit da5a232199ef93be219e933a7eaf4ccfc6d24d61
20691         * dirmngr/server.c (cmd_getinfo): Print an S line if Tor is not
20692         running.
20693
20694 2015-11-26  Werner Koch  <wk@gnupg.org>
20695
20696         g13: Fix commit 1a045b13.
20697         + commit 82f6abb4807c89388052ab442368d9e09fb84aea
20698         * g13/g13.c (main): Use existsing function.
20699
20700         common: Fix off-by-one access in the new format_text.
20701         + commit 61941a984964308b09c7fc1b3438fb99d0b3c917
20702         * common/stringhelp.c (format_text): Use existsing fucntion to trim
20703         trailing spaces.  Fix off-by-one access.
20704
20705         dirmngr: Improve output of "getinfo tor".
20706         + commit d226e67856e7197c581dcd2cef0f1e687bee0ac9
20707         * dirmngr/server.c (cmd_getinfo): Print a message along with OK.
20708
20709         dirmngr: Let Libassuan employ nPth wrappers for connect.
20710         + commit f95cff1cc9e7a4d9f6b7c45188ec47e70f9874dc
20711         * dirmngr/http.c (my_unprotect, my_protect): Remove.
20712         (connect_server): Do not use these wrappers.
20713
20714 2015-11-26  Justus Winter  <justus@g10code.com>
20715
20716         tools/gpgtar: Add '--dry-run'.
20717         + commit 676b2d7081291f7e47a66755ab07af259fea130b
20718         * tools/gpgtar-extract.c (extract_{regular,directory}): Honor
20719         '--dry-run'.
20720         * tools/gpgtar.c (enum cmd_and_opt_values): New value.
20721         (opts): Add '--dry-run'.
20722         (parse_arguments): Handle '--dry-run'.
20723         * tools/gpgtar.h (opt): Add field 'dry_run'.
20724
20725         tools/gpgtar: Handle '--gpg-args'.
20726         + commit 69a8440f44fa025e33a4cc32d17695c9ac385043
20727         * tools/gpgtar-create.c (gpgtar_create): Use given arguments.
20728         * tools/gpgtar-extract.c (gpgtar_extract): Likewise.
20729         * tools/gpgtar-list.c (gpgtar_list): Likewise.
20730         * tools/gpgtar.c (enum cmd_and_opt_values): New value.
20731         (opts): Add 'gpg-args'.
20732         (parse_arguments): Handle arguments.
20733         * tools/gpgtar.h (opt): Add field 'gpg_arguments'.
20734         * tests/openpgp/gpgtar.test: Simplify accordingly.
20735
20736         common: Make the GPG arguments configurable in call-gpg.
20737         + commit 1a045b1324efabe7423a8d00245f01718ed72556
20738         * common/call-gpg.c (start_gpg): Add parameter 'gpg_arguments'.
20739         (_gpg_encrypt, gpg_encrypt_blob, gpg_encrypt_stream): Likewise.
20740         (_gpg_decrypt, gpg_decrypt_blob, gpg_decrypt_stream): Likewise.
20741         * common/call-gpg.h: Adapt prototypes.
20742         * g13/create.c (encrypt_keyblob): Adapt callsite.
20743         * g13/g13-common.h (opt): Add field 'gpg_arguments'.
20744         * g13/g13.c (main): Construct default arguments.
20745         * g13/mount.c (decrypt_keyblob): Adapt callsite.
20746         * tools/gpgtar-create.c (gpgtar_create): Likewise.
20747         * tools/gpgtar-extract.c (gpgtar_extract): Likewise.
20748         * tools/gpgtar-list.c (gpgtar_list): Likewise.
20749
20750         tools/gpgtar: Handle '--tar-args' for compatibility with gpg-zip.
20751         + commit 2eb3248058330dd5c37560d9887db5b5266c54fe
20752         * tools/gpgtar.c (enum cmd_and_opt_values): New value.
20753         (opts): Add new group for tar options, rearrange a little, add
20754         '--tar-args'.
20755         (tar_opts): New variable.
20756         (shell_parse_stringlist): New function.
20757         (shell_parse_argv): Likewise.
20758         (parse_arguments): Add option argument, handle '--tar-args'.
20759         (main): Fix invokation of 'parse_arguments'.
20760         * tests/openpgp/gpgtar.test: Simplify decryption.
20761
20762         tools/gpgtar: Rework argument parsing.
20763         + commit 35c0c8b211bc891335e822379b33ea34fbc1f84f
20764         * tools/gpgtar.c (main): Move argument parsing into its own function.
20765
20766 2015-11-25  Justus Winter  <justus@g10code.com>
20767
20768         tests: Add tests for gpgtar and gpg-zip.
20769         + commit 556e8c44267fe3b829ca06286e9b5637ca1a6a73
20770         * tests/openpgp/Makefile.am (TESTS): Add new file.
20771         * tests/openpgp/gpgtar.test: New file.
20772
20773         tools/gpgtar: Handle '--directory' argument.
20774         + commit 127aba9a4d6c1aabb4a18a74b16d3bddc6eb5c54
20775         * tools/gpgtar-extract.c (gpgtar_extract): Only generate a directory
20776         name if none is given via arguments.
20777         * tools/gpgtar.c (enum cmd_and_opt_values): New constant.
20778         (opts): Add argument.
20779         (main): Parse argument.
20780         * tools/gpgtar.h (opt): New field 'directory'.
20781
20782         tools/gpgtar: Handle '--gpg' argument.
20783         + commit 89e104eb38c3a6896892ff09db11cb1bae2bb0d3
20784         * tools/gpgtar-create.c (gpgtar_create): Use given gpg program.
20785         * tools/gpgtar-extract.c (gpgtar_extract): Likewise.
20786         * tools/gpgtar-list.c (gpgtar_list): Likewise.
20787         * tools/gpgtar.c (enum cmd_and_opt_values): New constant.
20788         (opts): Add argument.
20789         (main): Handle argument.
20790         * tools/gpgtar.h (opt): Add field 'gpg_program'.
20791
20792         tools/gpgtar: Improve error handling.
20793         + commit f76fb047c15914ba44dc9423d235484758bcd721
20794         * tools/gpgtar-create.c (gpgtar_create): Return an error code, fix
20795         error handling.
20796         * tools/gpgtar-extract.c (gpgtar_extract): Likewise.
20797         * tools/gpgtar-list.c (read_header): Return an error code.
20798         (gpgtar_list): Return an error code, fix error handling.
20799         (gpgtar_read_header): Return an error code.
20800         * tools/gpgtar.c: Add missing include.
20801         (main): Print an generic error message if a command failed and no
20802         error has been printed yet.
20803         * tools/gpgtar.h (gpgtar_{create,extract,list,read_header}): Fix the
20804         prototypes accordingly.
20805
20806         tools: Add encryption and decryption support to gpgtar.
20807         + commit 40dbee86f3043aff8a8c2055521e270318e33068
20808         * tools/Makefile.am: Amend CFLAGS and LDADD.
20809         * tools/gpgtar-create.c (gpgtar_create): Add encrypt flag and encrypt
20810         stream if requested.
20811         * tools/gpgtar-extract.c (gpgtar_extract): Likewise for decryption.
20812         * tools/gpgtar-list.c (gpgtar_list): Likewise.
20813         * tools/gpgtar.c (main): Initialize npth and assuan.  Parse recipient
20814         and local user, and note which flags are currently ignored.  Adapt
20815         calls to gpgtar_list and friends.
20816         (tar_and_encrypt): Drop stub function and prototype.
20817         (decrypt_and_untar): Likewise.
20818         (decrypt_and_list): Likewise.
20819         * tools/gpgtar.h (gpgtar_{create,extract,list}): Add encryption or
20820         decryption argument.
20821
20822         common: Add stream interface to call-pgp.
20823         + commit 03bf88f32c8d203d5b3bfbbc48cc45e6c08cc187
20824         * common/call-gpg.c (struct writer_thread_parms): Add field 'stream'.
20825         (writer_thread_main): Support reading from a stream.
20826         (start_writer): Add stream argument.
20827         (struct reader_thread_parms): Add field 'stream'.
20828         (reader_thread_main): Support writing to a stream.
20829         (start_reader): Add stream argument.
20830         (_gpg_encrypt): Add stream api.
20831         (gpg_encrypt_blob): Adapt accordingly.
20832         (gpg_encrypt_stream): New function.
20833         (_gpg_decrypt): Add stream api.
20834         (gpg_decrypt_blob): Adapt accordingly.
20835         (gpg_decrypt_stream): New function.
20836         * common/call-gpg.h (gpg_encrypt_stream): New prototype.
20837         (gpg_decrypt_stream): Likewise.
20838
20839         common: Refactor the call-gpg code.
20840         + commit cb18d802308bde4e28219417bb4d107a4c0001b4
20841         * common/call-gpg.c (gpg_{en,de}crypt_blob): Move most of the code
20842         into two new functions, _gpg_encrypt and _gpg_decrypt.
20843
20844         g13: Move 'call-gpg.c' to common.
20845         + commit ba1a5cc17d43d9cba32447876f06a8ab8f97e5ae
20846         * common/Makefile.am (common_sources): Add files.
20847         * g13/call-gpg.c: Move to 'common' and adapt slightly.  Add a
20848         parameter to let callees override the gpg program to execute.
20849         * g13/call-gpg.h: Likewise.
20850         * g13/Makefile.am (g13_SOURCES): Drop files.
20851         * g13/create.c (encrypt_keyblob): Hand in the gpg program to execute.
20852         * g13/mount.c (decrypt_keyblob): Likewise.
20853
20854 2015-11-24  Neal H. Walfield  <neal@g10code.com>
20855
20856         gpg: When comparing keyids, use the keyid, not the fingerprint's suffix.
20857         + commit e9c16fee2576c772de9d4fb5d53fee28e4b84202
20858         * g10/keyedit.c (menu_select_key): Use spacep and hexdigitp instead of
20859         inline tests.  Don't compare P to the suffix of the fingerprint.  If P
20860         appears to be a keyid, do an exact compare against the keyid.  If it
20861         appears to be a fingerprint, do an exact compare against the
20862         fingerprint.
20863
20864 2015-11-23  Neal H. Walfield  <neal@g10code.com>
20865
20866         gpg: Reflow long texts.
20867         + commit 19362a8dd7ee986c082a5afc5a446f939991ec0f
20868         * common/stringhelp.c (format_text): New function.
20869         * common/t-stringhelp.c (stresc): New function.
20870         (test_format_text): New function.  Test format_text.
20871         * g10/tofu.c (get_trust): Use format_text to reflow long texts.
20872         (show_statistics): Likewise.
20873
20874         common: Extend utf8_charcount to include the string's length.
20875         + commit 5b84b0d660c8329e184d98682665aaea7e1703d2
20876         * common/stringhelp.c (utf8_charcount): Take additional parameter,
20877         len.  Process at most LEN bytes.
20878
20879 2015-11-23  Justus Winter  <justus@g10code.com>
20880
20881         dirmngr: Fix http lookups when libadns is used.
20882         + commit b75e1b3d8b1643640d046f7f8e89adf5b1caa7a3
20883         * dirmngr/dns-stuff.c (resolve_name_adns): Fill in the port.
20884
20885         dirmngr: Fix SRV record lookups when using the system resolver.
20886         + commit 946faaff04f3340ed6db9e89c5036dc5f9beca6a
20887         * dirmngr/dns-stuff.c (getsrv): Fix error handling.
20888
20889         dirmngr: Honor ports specified in SRV records.
20890         + commit 73c1a86ad937d7be027eece991c69aaeb6a1f092
20891         * dirmngr/ks-engine-hkp.c (struct hostinfo_s): New field 'port'.
20892         (create_new_hostinfo): Initialize 'port'.
20893         (add_host): Add host parameter and update the hosttable entry.
20894         (map_host): Return port if known, adjust calls to 'add_host'.
20895         (make_host_part): Let 'map_host' specify the port if known.
20896
20897         dirmngr: Support hkp server pools using SRV records.
20898         + commit c9f5aa15793b3c05c1b92af401b23ab34d3e6196
20899         * dirmngr/ks-engine-hkp.c (map_host): Handle SRV records.
20900
20901         dirmngr: Refactor 'map_host'.
20902         + commit 3f52f6bcacfe3877d30a21464e93e9240bc75085
20903         * dirmngr/ks-engine-hkp.c (add_host): New function.
20904         (map_host): Use the new function.
20905
20906         dirmngr: Fix pool detection.
20907         + commit 23ea641ba2a063cc99c82869061703d48bc674b2
20908         * dirmngr/ks-engine-hkp (arecords_is_pool): Fix counting IP addresses.
20909
20910         dirmngr: Refactor 'map_host'.
20911         + commit 2b43a0515868b8720009e48d7a1f32d571767f14
20912         * dirmngr/ks-engine-hkp.c (arecords_is_pool): New function.
20913         (map_host): Use the new function.
20914
20915         dirmngr: Start dirmngr on demand.
20916         + commit a9e0b1dd6c106e243e3fbbaa1838b56a1f1c8584
20917         * common/asshelp.h: Include 'util.h'.
20918         * dirmngr/dirmngr-client.c (main): Use 'start_new_dirmngr' to connect
20919         to the dirmngr.
20920         (start_dirmngr): Drop now unused declaration and function.
20921
20922 2015-11-23  Neal H. Walfield  <neal@g10code.com>
20923
20924         gpg: If sqlite is not available, don't build things depending on it.
20925         + commit 770c06ed4e6c1097d6e305a0a9427c3c783b787c
20926         * configure.ac: Define the automake conditional SQLITE3.
20927         * tests/openpgp/Makefile.am (TESTS): Move the sqlite3 dependent tests
20928         to...
20929         (sqlite3_dependent_tests): ... this new variable.  If SQLITE3 is not
20930         defined, then clear this variable.
20931
20932         gpg: Allow updating the expiration time of multiple subkeys at once.
20933         + commit b64b33bb80a8cf5dcc1fdbc62023d019fe2c8cb1
20934         * g10/keyedit.c (menu_expire): Allow updating the expiration time of
20935         multiple subkeys at once.
20936
20937         gpg: Don't crash if key is not passed an argument.
20938         + commit 19f099463c82c119288a05eaefc42bf09d617377
20939         * g10/keyedit.c (menu_select_key): Don't crash if P is NULL.
20940
20941 2015-11-20  Neal H. Walfield  <neal@g10code.com>
20942
20943         gpg: Fail if the search description passed to --gen-revoke is ambiguous.
20944         + commit 178af9c3f56d385fe28a9e5e8bde0ab34c0b260e
20945         * g10/revoke.c (gen_revoke): Error out if the search description is
20946         ambiguous.
20947
20948         gpg: Refactor print_seckey_info.
20949         + commit f8a65ac96b27a0963892892ce6e93b37b8df1ad7
20950         * g10/keylist.c (print_seckey_info): Break formatting functionality
20951         into...
20952         (format_seckey_info): ... this new function.
20953
20954         gpg: Improve an error message.
20955         + commit 46e128d44a0456dc603bc9e25a4c5d8da903b078
20956         * g10/revoke.c (gen_revoke): Provide a more descriptive error message
20957         if searching for a key fails.
20958
20959 2015-11-19  Justus Winter  <justus@g10code.com>
20960
20961         dirmngr: Improve error handling.
20962         + commit 6b14df5525777ee0330a34a7b335359f562616a4
20963         * dirmngr/crlcache.c (crl_cache_cert_isvalid): Add missing break.
20964
20965         dirmngr: Fix memory leak.
20966         + commit b223cde311e4e02f7983e33fe3d7214287dfb678
20967         * dirmngr/ldap.c (start_cert_fetch_ldap): Avoid leaking all malloc'ed
20968         arguments.
20969
20970         agent: Improve error handling.
20971         + commit a1650b1edf80c2526c0576547b3a574e8d30f1fa
20972         * agent/trustlist.c (istrusted_internal): Initialize 'err'.
20973
20974         common: Avoid undefined behavior.
20975         + commit eb957ffc4797fb019c505510295af244baf5be38
20976         * common/iobuf.c (iobuf_esopen): Initialize 'len' as 'file_es_filter'
20977         will make use of it.
20978
20979         g10: Avoid undefined behavior.
20980         + commit 52f7f195b119dc01bdf3ae200fdc8e04a0bb9bcb
20981         * g10/trust.c (clean_one_uid): Avoid a computation involving an
20982         uninitialized value.
20983
20984         scd: Improve error handling.
20985         + commit 6a37b45a7f13cf5d2ae7d6c9cd796a4bd197b80d
20986         * scd/app-openpgp.c (get_public_key): Improve error handling.
20987
20988 2015-11-18  Justus Winter  <justus@g10code.com>
20989
20990         dirmngr: Gracefully handle premature termination of TLS streams.
20991         + commit eb54fca4bf3ef8e0cd50b01df5b40e0d6d318d7e
20992         * dirmngr/http.c (close_tls_session): New function.
20993         (session_unref): Use the new function to close the TLS stream.
20994         (cookie_read): If the stream terminated prematurely, close it and
20995         return a short read.
20996
20997 2015-11-17  Neal H. Walfield  <neal@g10code.com>
20998             Michael Mönch  <michael.moench@marktjagd.de>
20999
21000         tools: Fix option parsing for gpg-zip.
21001         + commit 84ebf15b06e435453b2f58775f97a3a1c61a7e55
21002         * tools/gpg-zip.in: Correctly set GPG when --gpg is specified.
21003         Correctly set TAR when --tar is specified.  Pass TAR_ARGS to tar.
21004
21005 2015-11-17  Neal H. Walfield  <neal@g10code.com>
21006
21007         gpg: Allow selecting subkeys using a keyid.
21008         + commit 0b86c7463c8c057496b38e06c00f0ae4288dad49
21009         * g10/keyedit.c (menu_select_key): Take an additional argument, p.
21010         Update callers.  If P is a hex string, then assume that P is a key id
21011         or fingerprint and select subkeys with matching key ids or
21012         fingerprints.
21013         * doc/gpg.texi: Update documentation for the key subcommand.
21014
21015 2015-11-17  Justus Winter  <justus@g10code.com>
21016
21017         dirmngr: Fix specifying keyservers by IP address.
21018         + commit 1e3dbb15affd6d75a477aa17715d8e5470988c08
21019         * dirmngr/ks-engine-hkp.c (map_host): Update the original 'hosttable'
21020         entry instead of creating another one.
21021
21022 2015-11-17  Neal H. Walfield  <neal@g10code.com>
21023
21024         gpg: Change keydb_search to not return legacy keys.
21025         + commit 58e4a492e2c8e908d16135486ed601f602f1e38d
21026         * g10/keyring.c (keyring_search): Take new argument, ignore_legacy.
21027         If set, skip any legacy keys.  Update callers.
21028         * g10/keydb.c (keydb_search): Skip any legacy keys.
21029         (keydb_search_first): Don't skip legacy keys.  Treat them
21030         as an error.
21031         (keydb_search_next): Likewise.
21032         (keydb_search_fpr): Likewise.
21033         * g10/export.c (do_export_stream): Likewise.
21034         * g10/getkey.c (lookup): Likewise.
21035         (have_secret_key_with_kid): Likewise.
21036         * g10/keylist.c (list_all): Likewise.
21037         (keyring_rebuild_cache): Likewise.
21038         * g10/keyserver.c (keyidlist): Likewise.
21039         * g10/trustdb.c (validate_key_list): Likewise.
21040
21041         gpg: Correctly handle an error.
21042         + commit 848726f5c02faddb0b0fd24ce1a66893f5325675
21043         * g10/keyring.c (keyring_search): If a compare function returns an
21044         error, treat it as an error.
21045
21046         gpg: Correctly handle keyblocks followed by legacy keys.
21047         + commit ad9befab12376b3a49cde410996ac9f0013d0871
21048         * g10/keyring.c (keyring_get_keyblock): If we encounter a legacy
21049         packet after already having some non-legacy packets, then treat the
21050         legacy packet as a keyblock boundary, not as part of the keyblock.
21051         * g10/t-keydb-get-keyblock.c: New file.
21052         * g10/t-keydb-get-keyblock.gpg: New file.
21053         * g10/Makefile.am (EXTRA_DIST): Add t-keydb-get-keyblock.gpg.
21054         (module_tests): Add t-keydb-get-keyblock.
21055         (t_keydb_get_keyblock_SOURCES): New variable.
21056         (t_keydb_get_keyblock_LDADD): Likewise.
21057
21058         gpg: Make debugging search descriptors easier.
21059         + commit 11ec4785df1646643966d872b1b53ef675092c98
21060         * g10/keydb.c (dump_search_desc): Rename from this...
21061         (keydb_search_desc_dump): ... to this.  Only process a single search
21062         descriptor.  Improve output.  Don't mark as static.  Update callers.
21063
21064         gpg: Add function format_keyid.
21065         + commit a052c30d31c0f6b532fea081f4a9bee083f5440f
21066         * g10/options.h (opt.keyid_format): Add new value KF_DEFAULT.
21067         * g10/keyid.c (format_keyid): New function.
21068         (keystr): Use it.
21069
21070         gpg: Use a more appropriate error code.
21071         + commit eae982ed6d69644258afe9c4ad1be553853d8403
21072         * g10/gpg.c (check_user_ids): Return a more appropriate error code if
21073         a user id is ambiguous.
21074
21075 2015-11-17  Justus Winter  <justus@g10code.com>
21076
21077         Fix typos found using codespell.
21078         + commit a9e0905342e847e8961ec4fe9b3aaedf05e33423
21079         * agent/cache.c: Fix typos.
21080         * agent/call-pinentry.c: Likewise.
21081         * agent/call-scd.c: Likewise.
21082         * agent/command-ssh.c: Likewise.
21083         * agent/command.c: Likewise.
21084         * agent/divert-scd.c: Likewise.
21085         * agent/findkey.c: Likewise.
21086         * agent/gpg-agent.c: Likewise.
21087         * agent/w32main.c: Likewise.
21088         * common/argparse.c: Likewise.
21089         * common/audit.c: Likewise.
21090         * common/audit.h: Likewise.
21091         * common/convert.c: Likewise.
21092         * common/dotlock.c: Likewise.
21093         * common/exechelp-posix.c: Likewise.
21094         * common/exechelp-w32.c: Likewise.
21095         * common/exechelp-w32ce.c: Likewise.
21096         * common/exechelp.h: Likewise.
21097         * common/helpfile.c: Likewise.
21098         * common/i18n.h: Likewise.
21099         * common/iobuf.c: Likewise.
21100         * common/iobuf.h: Likewise.
21101         * common/localename.c: Likewise.
21102         * common/logging.c: Likewise.
21103         * common/openpgp-oid.c: Likewise.
21104         * common/session-env.c: Likewise.
21105         * common/sexputil.c: Likewise.
21106         * common/sysutils.c: Likewise.
21107         * common/t-sexputil.c: Likewise.
21108         * common/ttyio.c: Likewise.
21109         * common/util.h: Likewise.
21110         * dirmngr/cdblib.c: Likewise.
21111         * dirmngr/certcache.c: Likewise.
21112         * dirmngr/crlcache.c: Likewise.
21113         * dirmngr/dirmngr-client.c: Likewise.
21114         * dirmngr/dirmngr.c: Likewise.
21115         * dirmngr/dirmngr_ldap.c: Likewise.
21116         * dirmngr/dns-stuff.c: Likewise.
21117         * dirmngr/http.c: Likewise.
21118         * dirmngr/ks-engine-hkp.c: Likewise.
21119         * dirmngr/ks-engine-ldap.c: Likewise.
21120         * dirmngr/ldap-wrapper.c: Likewise.
21121         * dirmngr/ldap.c: Likewise.
21122         * dirmngr/misc.c: Likewise.
21123         * dirmngr/ocsp.c: Likewise.
21124         * dirmngr/validate.c: Likewise.
21125         * g10/encrypt.c: Likewise.
21126         * g10/getkey.c: Likewise.
21127         * g10/gpg.c: Likewise.
21128         * g10/gpgv.c: Likewise.
21129         * g10/import.c: Likewise.
21130         * g10/keydb.c: Likewise.
21131         * g10/keydb.h: Likewise.
21132         * g10/keygen.c: Likewise.
21133         * g10/keyid.c: Likewise.
21134         * g10/keylist.c: Likewise.
21135         * g10/keyring.c: Likewise.
21136         * g10/mainproc.c: Likewise.
21137         * g10/misc.c: Likewise.
21138         * g10/options.h: Likewise.
21139         * g10/packet.h: Likewise.
21140         * g10/parse-packet.c: Likewise.
21141         * g10/pkclist.c: Likewise.
21142         * g10/pkglue.c: Likewise.
21143         * g10/plaintext.c: Likewise.
21144         * g10/server.c: Likewise.
21145         * g10/sig-check.c: Likewise.
21146         * g10/sqlite.c: Likewise.
21147         * g10/tdbio.c: Likewise.
21148         * g10/test-stubs.c: Likewise.
21149         * g10/tofu.c: Likewise.
21150         * g10/trust.c: Likewise.
21151         * g10/trustdb.c: Likewise.
21152         * g13/create.c: Likewise.
21153         * g13/mountinfo.c: Likewise.
21154         * kbx/keybox-blob.c: Likewise.
21155         * kbx/keybox-file.c: Likewise.
21156         * kbx/keybox-init.c: Likewise.
21157         * kbx/keybox-search-desc.h: Likewise.
21158         * kbx/keybox-search.c: Likewise.
21159         * kbx/keybox-update.c: Likewise.
21160         * scd/apdu.c: Likewise.
21161         * scd/app-openpgp.c: Likewise.
21162         * scd/app-p15.c: Likewise.
21163         * scd/app.c: Likewise.
21164         * scd/ccid-driver.c: Likewise.
21165         * scd/command.c: Likewise.
21166         * scd/iso7816.c: Likewise.
21167         * sm/base64.c: Likewise.
21168         * sm/call-agent.c: Likewise.
21169         * sm/call-dirmngr.c: Likewise.
21170         * sm/certchain.c: Likewise.
21171         * sm/gpgsm.c: Likewise.
21172         * sm/import.c: Likewise.
21173         * sm/keydb.c: Likewise.
21174         * sm/minip12.c: Likewise.
21175         * sm/qualified.c: Likewise.
21176         * sm/server.c: Likewise.
21177         * tools/gpg-check-pattern.c: Likewise.
21178         * tools/gpgconf-comp.c: Likewise.
21179         * tools/gpgkey2ssh.c: Likewise.
21180         * tools/gpgparsemail.c: Likewise.
21181         * tools/gpgtar.c: Likewise.
21182         * tools/rfc822parse.c: Likewise.
21183         * tools/symcryptrun.c: Likewise.
21184
21185 2015-11-16  Neal H. Walfield  <neal@g10code.com>
21186
21187         gpg: Fix error checking and improve error reporting.
21188         + commit 8e2bea22b0927f4f95a248cc7517f407a705d8a8
21189         * g10/gpg.c (check_user_ids): Differentiate between a second result
21190         and an error.  If the key specification is ambiguous or an error
21191         occurs, set RC appropriately.
21192
21193 2015-11-14  Werner Koch  <wk@gnupg.org>
21194
21195         gpg: Use only one fingerprint formatting function.
21196         + commit 3689c2105aab6a4304e9464c5b20207d69b9a133
21197         * g10/gpg.h (MAX_FORMATTED_FINGERPRINT_LEN): New.
21198         * g10/keyid.c (hexfingerprint): Add optional args BUFFER and BUFLEN.
21199         Change all callers.
21200         (format_hexfingerprint): New.
21201         * g10/keylist.c (print_fingerprint): Change to use hexfingerprint.
21202         * g10/tofu.c (fingerprint_format): Remove.  Replace calls by
21203         format_hexfingerprint.
21204
21205 2015-11-13  Werner Koch  <wk@gnupg.org>
21206
21207         gpg: Simplify the tofu interface by using the public key packet.
21208         + commit e7d7160ab7cd4e6b460bfe36fd3a7275adadb4e2
21209         * g10/tofu.c (fingerprint_str): Remove.
21210         (tofu_register): Take a public key instead of a fingerprint as arg.
21211         Use hexfingerprint() to get a fpr from the PK.
21212         (tofu_get_validity): Ditto.
21213         (tofu_set_policy, tofu_get_policy): Simplify by using hexfingerprint.
21214         * g10/trustdb.c (tdb_get_validity_core): Pass the primary key PK to
21215         instead of the fingerprint to the tofu functions.
21216
21217         gpg: Make trusted-key override for Tofu robust against swapped tofu.db.
21218         + commit 7de8376430625c1f6f3a58ae16276deca8ff6a82
21219         * g10/tofu.c (get_trust): For the UTK check lookup the key by
21220         fingerprint.
21221
21222         gpg: Fix regression in --locate-keys (in 2.1.9).
21223         + commit 7e59fb21f728b5f54468cd35b1415a2f86003d4f
21224         * g10/getkey.c (getkey_ctx_s): Add field "extra_list".
21225         (get_pubkey_byname): Store strings in the context.
21226         (getkey_end): Free EXTRA_LIST.
21227
21228 2015-11-12  Werner Koch  <wk@gnupg.org>
21229
21230         gpg: Print a new EXPORTED status line.
21231         + commit 2038adf16d0e7eeb614043aae17b16a867de6b70
21232         * common/status.h (STATUS_EXPORTED): New.
21233         * g10/export.c (print_status_exported): New.
21234         (do_export_stream): Call that function.
21235
21236         gpg: Print export statistics to the status-fd.
21237         + commit e3c48335f9c5081c6080bceafa7a04140403427a
21238         * common/status.h (STATUS_EXPORT_RES): New.
21239         * g10/main.h (export_stats_t): New.
21240         * g10/export.c (export_stats_s): New.
21241         (export_new_stats, export_release_stats): New.
21242         (export_print_stats): New.
21243         (export_pubkeys, export_seckeys, export_secsubkeys)
21244         (export_pubkey_buffer, do_export): Add arg "stats".
21245         (do_export_stream): Add arg stats and update it.
21246         * g10/gpg.c (main) <aExport, aExportSecret, aExportSecretSub>: Create,
21247         pass, and print a stats object to the export function calls.
21248
21249         * g10/export.c (export_pubkeys_stream): Remove unused function.
21250
21251         dirmngr: Do not block during ADNS calls.
21252         + commit a3b26d6c0839ec18d1dc226bb537d5067c86d574
21253         * dirmngr/dns-stuff.c: Include npth.h
21254         (my_unprotect, my_protect): New wrapper.
21255         (resolve_name_adns): Put unprotect/protect around adns calls.
21256         (get_dns_cert): Ditto.
21257         (getsrv): Ditto.
21258         (get_dns_cname): Ditto.
21259
21260         dirmngr: New option --nameserver.
21261         + commit a2cc1d57552ccac7b2f9a0c6423b171b2a168b2a
21262         * dirmngr/dirmngr.c (oNameServer): New.
21263         (opts): Add --nameserver.
21264         (parse_rereadable_options): Act upon oNameServer.
21265         * dirmngr/dns-stuff.c (DEFAULT_NAMESERVER): New.
21266         (tor_nameserver): New.
21267         (set_dns_nameserver): New.
21268         (my_adns_init): Make name server configurable.
21269
21270 2015-11-11  Neal H. Walfield  <neal@g10code.com>
21271
21272         gpg: Fix cache consistency problem.
21273         + commit 7546e818791988c00b8635dab5b899265d8d9f42
21274         g10/keyring.c (keyring_search): Only mark the cache as completely
21275         filled if we start the scan from the beginning of the keyring.
21276
21277 2015-11-10  Neal H. Walfield  <neal@g10code.com>
21278
21279         gpg: Default to the the PGP trust model.
21280         + commit 67c701d1e53f56305e3b8771c683c45bb9672305
21281         * g10/trustdb.c (init_trustdb): If we can't read the trust model from
21282         the trust DB, default to TM_PGP, not TM_TOFU_PGP.
21283
21284         gpg: Default to the flat TOFU DB format.
21285         + commit 951f277b6bf8178560105538d38e2a07a96865bd
21286         * g10/tofu.c (opendbs): If the TOFU DB format is set to auto and there
21287         is no TOFU DB, default to the flat format.
21288
21289 2015-11-09  Werner Koch  <wk@gnupg.org>
21290
21291         dirmngr: Change to new ADNS Tor mode init scheme.
21292         + commit 288c9919dc45496b2380eeac487a8539692d6842
21293         * dirmngr/dns-stuff.c (tor_credentials): New.
21294         (enable_dns_tormode): Add arg new_circuit and update tor_credentials.
21295         (my_adns_init): Rework to set Tor mode using a config file options and
21296         always use credentials.
21297         * dirmngr/server.c (cmd_dns_cert): Improve error message.
21298         * dirmngr/t-dns-stuff.c (main): Add option --new-circuit.
21299
21300         dirmngr: Improve detection of ADNS.
21301         + commit f92e95175e90120362a7d6376fb32307e11267b5
21302         * configure.ac (HAVE_ADNS_FREE): New ac_define.
21303
21304 2015-11-09  NIIBE Yutaka  <gniibe@fsij.org>
21305
21306         scd: Add reder information to --card-status.
21307         + commit bce0e3f71df0709a7d323a688ddf2690c1727a6c
21308         * g10/call-agent.h, g10/call-agent.c (agent_release_card_info)
21309         g10/card-util.c (card_status): Add READER.
21310         * scd/apdu.c (close_ccid_reader, open_ccid_reader): Handle RDRNAME.
21311         (apdu_get_reader_name): New.
21312         * scd/ccid-driver.c (ccid_open_reader): Add argument to RDRNAME_P.
21313         * scd/command.c (cmd_learn): Return READER information.
21314
21315 2015-11-06  Werner Koch  <wk@gnupg.org>
21316
21317         gpg: Avoid new strings.
21318         + commit 2242658efe0c975a46c3316bc9171ddbce085e2c
21319         * g10/decrypt-data.c (decrypt_data): Use already translated strings.
21320
21321         common: Fix commit f99830b.
21322         + commit 20125333e7b822e8c70ac8cef986649f0654eb56
21323         * common/userids.c (classify_user_id): Avoid underflow.  Use spacep to
21324         also trim tabs.
21325
21326 2015-11-06  Neal H. Walfield  <neal@g10code.com>
21327
21328         gpg: Fix formatting string.
21329         + commit 28e198201e580b39bceb9c151df07fc0e936a91d
21330         * g10/decrypt-data.c (decrypt_data): Fix formatting string.
21331
21332         gpg: Add new option --only-sign-text-ids.
21333         + commit a74aeb5dae1f673fcd98b39a6a0496f3c622709a
21334         * g10/options.h (opt): Add field only_sign_text_ids.
21335         * g10/gpg.c (enum cmd_and_opt_values): Add value oOnlySignTextIDs.
21336         (opts): Handle oOnlySignTextIDs.
21337         (main): Likewise.
21338         * g10/keyedit.c (sign_uids): If OPT.ONLY_SIGN_TEXT_IDS is set, don't
21339         select non-text based IDs automatically.
21340         (keyedit_menu): Adapt the prompt asking to sign all user ids according
21341         to OPT.ONLY_SIGN_TEXT_IDS.
21342         * doc/gpg.texi: Document the new option --only-sign-text-ids.
21343
21344         common: When classifying keyids and fingerprints, reject trailing junk.
21345         + commit f99830b72812395da5451152bdd2f2d90a7cb7fb
21346         * common/userids.c (classify_user_id): Trim any trailing whitespace.
21347         Before assuming that a hexstring corresponds to a key id or
21348         fingerprint, make sure that it is NUL terminated.
21349
21350         gpg: Check for ambiguous or non-matching key specs.
21351         + commit e8c53fca954d33366e3494a6d4eecc3868282bcc
21352         * g10/gpg.c (check_user_ids): New function.
21353         (main): Check that any user id specifications passed to --local-user
21354         and --remote-user correspond to exactly 1 user.  Check that any user
21355         id specifications passed to --default-key correspond to at most 1
21356         user.  Warn if any user id specifications passed to --local-user or
21357         --default-user are possible ambiguous (are not specified by long keyid
21358         or fingerprint).
21359         * g10/getkey.c (parse_def_secret_key): Don't warn about possible
21360         ambiguous key descriptions here.
21361
21362         common: Add new function strlist_rev.
21363         + commit f38bac8883ea2e9ed8e2836f97a953efb85e774c
21364         * common/strlist.c (strlist_rev): New function.
21365         * common/t-strlist.c: New file.
21366         * common/Makefile.am (common_sources): Add strlist.c and strlist.h.
21367         (module_tests): Add t-strlist.
21368         (t_strlist_LDADD): New variable.
21369
21370         common: Include required, but not included headers in t-support.h.
21371         + commit 23e163473f050d1f2c08f589beb9dab283b7d624
21372         * common/t-support.h: Include <stdlib.h> and <stdio.h>.
21373
21374 2015-11-05  Neal H. Walfield  <neal@g10code.com>
21375
21376         gpg: Indicate which characters are invalid.
21377         + commit a958ffd148a46f3757d1c309bb13555638044640
21378         * g10/keygen.c (ask_user_id): Indicate which characters are invalid.
21379
21380         gpg: Add support for unwrapping the outer level of encryption.
21381         + commit ec409e62aea6cc829299be794f9d035d033cb51b
21382         * g10/decrypt-data.c (decrypt_data): If OPT.UNWRAP_ENCRYPTION is set,
21383         copy the data to the output file instead of continuing to process it.
21384         * g10/gpg.c (enum cmd_and_opt_values): Add new value oUnwrap.
21385         (opts): Handle oUnwrap.
21386         (main): Likewise.
21387         * g10/options.h (opt): Add field unwrap_encryption.
21388         * g10/plaintext.c (handle_plaintext): Break the output file selection
21389         functionality into ...
21390         (get_output_file): ... this new function.
21391
21392         common: Add a function for copying data from one iobuf to another.
21393         + commit fd4b9e232805b2e30b29903568c95cc0aad8bbec
21394         * common/iobuf.c (iobuf_copy): New function.
21395
21396         doc: Note that gpgkey2ssh is deprecated.
21397         + commit 2b0e0a53b4db8c44e299f57a9f4f9fc1b825e707
21398         * doc/tools.texi (gpgkey2ssh): Note that gpgkey2ssh is deprecated.
21399
21400         tools: Fix gpgkey2ssh's most gratuitous errors.  Use gpg2, not gpg.
21401         + commit cd2d685230ecafb7df504ef2b16cf1ec9a014300
21402         * tools/gpgkey2ssh.c (main): Add support for --help.  Replace the most
21403         gratuitous asserts with error messages.  Invoke gpg2, not gpg.
21404
21405 2015-11-05  Neal H. Walfield  <neal@g10code.com>
21406             Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
21407
21408         doc: Add documentation for gpgkey2ssh.
21409         + commit 2b27acc3435e73fad7460b551a36b4064cdd58be
21410         * doc/tools.texi: Add documentation for gpgkey2ssh.
21411
21412 2015-11-04  Neal H. Walfield  <neal@g10code.com>
21413
21414         gpg: Print a better error message for --multifile --sign --encrypt.
21415         + commit 6897bbf1aa9bf0a61b186ea1a9bcb463fb1fd10e
21416         * g10/gpg.c (main): Print a better error message for --multifile
21417         --sign --encrypt.
21418
21419         gpg: Add --encrypt-to-default-key.
21420         + commit de9b2340153d70b083494d1a277a384dcf43bff0
21421         * g10/getkey.c (parse_def_secret_key): Drop the static qualifier and
21422         export the function.
21423         * g10/gpg.c (enum cmd_and_opt_values): Add value oEncryptToDefaultKey.
21424         (opts): Handle oEncryptToDefaultKey.
21425         (main): Likewise.
21426         * g10/options.h (opt): Add field encrypt_to_default_key.
21427
21428         gpg: Allow multiple --default-key options.  Take the last available key.
21429         + commit e16d7168c54e5f7bc2f0037806ee4f730930eaf0
21430         * g10/getkey.c (parse_def_secret_key): New function.
21431         (get_seckey_default): Add parameter ctrl.  Update callers.  Use
21432         parse_def_secret_key to get the default secret key, if any.
21433         (getkey_byname): Likewise.
21434         (enum_secret_keys): Likewise.
21435         * g10/options.h (opt): Change def_secret_key's type from a char * to a
21436         strlist_t.
21437         * g10/gpg.c (main): When processing --default-key, add the key to
21438         OPT.DEF_SECRET_KEY.
21439         * g10/gpgv.c (get_session_key): Add parameter ctrl.  Update callers.
21440         * g10/mainproc.c (proc_pubkey_enc): Likewise.
21441         (do_proc_packets): Likewise.
21442         * g10/pkclist.c (default_recipient): Likewise.
21443         * g10/pubkey-enc.c (get_session_key): Likewise.
21444         * g10/sign.c (clearsign_file): Likewise.
21445         (sign_symencrypt_file): Likewise.
21446         * g10/skclist.c (build_sk_list): Likewise.
21447         * g10/test-stubs.c (get_session_key): Likewise.
21448
21449 2015-11-04  NIIBE Yutaka  <gniibe@fsij.org>
21450
21451         scd: Fix error handling with libusb-compat library.
21452         + commit 1e94a672efb8bf66f416bc63bf6670e509a21fe5
21453         * scd/ccid-driver.c (bulk_out): Use LIBUSB_ERRNO_NO_SUCH_DEVICE.
21454
21455         scd: fix change_keyattr.
21456         + commit c5a9fedba66361ddd9f596528882750068543298
21457         * scd/app-openpgp.c (change_keyattr_from_string): Fix parsing.
21458
21459 2015-11-03  Werner Koch  <wk@gnupg.org>
21460
21461         gpg: Change out of core error message.
21462         + commit 44ad9f29d43f40bbc1840454880f4af3df1c5295
21463         * g10/tofu.c (fingerprint_str): Die with the error code returned by
21464         the failed function.
21465         (time_ago_str): Ditto.  Do not make a comma translatable.
21466         (fingerprint_format): Use "%zu" for a size_t.
21467
21468         gpg: Make translation easier.
21469         + commit 62b8cd5495dcac9a0f8a3d88c7bd4cd80997fd3f
21470         * g10/import.c (import_secret_one): Split info string for easier
21471         translation.
21472
21473 2015-11-03  Neal H. Walfield  <neal@g10code.com>
21474
21475         gpg: Also show when the most recently signed message was observed.
21476         + commit 621afac37e5555fd68054531e611ead444b62928
21477         * g10/tofu.c (show_statistics): Also show when the most recently
21478         signed message was observed.
21479
21480         gpg: Split a utility function out of a large function.
21481         + commit 36326112290b6eef47c9dada30dddbdf408680e4
21482         * g10/tofu.c (show_statistics): Break the time delta to string code
21483         into...
21484         (time_ago_str): ... this new function.
21485
21486         gpg: Fix message formatting.
21487         + commit c8ef9f9a64d13ea8b9b4ade62525243abe2976ba
21488         * g10/tofu.c (get_trust): Fix message formatting.
21489
21490         gpg: Don't store formatting fingerprints in the TOFU DB.
21491         + commit 8ae3946d28c43e30ef692ba6cf1a7fa4ed65ecc5
21492         * g10/tofu.c (fingerprint_pp): Split this function into...
21493         (fingerprint_str): ... this function...
21494         (fingerprint_format): ... and this function.
21495         (record_binding): Store the unformatted fingerprint in the DB.  Only
21496         use the formatting fingerprint when displaying a message to the user.
21497         (get_trust): Likewise.
21498         (show_statistics): Likewise.
21499         (tofu_register): Likewise.
21500         (tofu_get_validity): Likewise.
21501         (tofu_set_policy): Likewise.
21502         (tofu_get_policy): Likewise.
21503
21504 2015-11-02  NIIBE Yutaka  <gniibe@fsij.org>
21505
21506         g10: notify a user when importing stub is skipped.
21507         + commit 06f3eadb22986d9ebde9efff2794eb1d45d6c6d4
21508         * g10/import.c (transfer_secret_keys): Return GPG_ERR_NOT_PROCESSED
21509         when stub_key_skipped.
21510         (import_secret_one): Notify a user, suggesting --card-status.
21511
21512 2015-10-31  Neal H. Walfield  <neal@g10code.com>
21513
21514         gpg: Consider newlines to be whitespace in an SQL statement.
21515         + commit 18cd09246f5dcddcafb8662afd84fa046e36de3f
21516         * g10/sqlite.c (sqlite3_stepx): When making sure that there is no
21517         second SQL statement, ignore newlines.
21518
21519 2015-10-30  Werner Koch  <wk@gnupg.org>
21520
21521         common: Improve t-zb32 to be used for manual encoding.
21522         + commit d89a9fca46d9bba497dde0793b57217c800b0e8d
21523         * common/t-support.h (no_exit_on_fail, errcount): New.
21524         (fail): Bump errcount.
21525         * common/t-zb32.c (main): Add options to allow manual use.
21526
21527         common: Add separate header for zb32.c.
21528         + commit 5aadb4b62d26e1bfb40a1ce444a81c2a5a56159c
21529         * common/util.h (zb32_encode): Move prototype to ...
21530         * common/zb32.h: new.  Include this for all callers of zb32_encode.
21531
21532 2015-10-29  Neal H. Walfield  <neal@g10code.com>
21533
21534         gpg: Display the correct error message.
21535         + commit 641df615da4937b0073c420a0503c5810c237972
21536         * g10/trustdb.c (validate_keys): If tdbio_update_version_record fails,
21537         RC does not contain the error code.  Save the error code in rc2 and
21538         use that.
21539
21540         gpg: Eliminate a memory leak.
21541         + commit d68bdc553a206e54234d5d53ad35c4ba34133118
21542         * g10/trustdb.c (validate_key_list): Don't leak the keyblocks on
21543         failure.
21544
21545         gpg: Remove unused prototype.
21546         + commit ef052591ba51ee16bafc3c5b79d837ed8f01b520
21547         g10/keyring.h (keyring_locate_writable): Remove unused prototype.
21548
21549         gpg: Eliminate a memory leak.
21550         + commit 89eee5f6b7ca3da7ebdcc3e5d069701d0834b39e
21551         * g10/gpg.c (main): Don't leak OPT.DEF_RECIPIENT.
21552
21553         gpg: Fix keyring support.
21554         + commit 99c84b49b787dab8da26cf61eed24dd4a2b77fd9
21555         * g10/keydb.c (keydb_rebuild_caches): Only mark the cached as prepared
21556         if it is actually prepared, which it only is if the resource is a
21557         keybox.
21558
21559         gpg: Change sqlite3_stepx to pass the sqlite3_stmt * to the callback.
21560         + commit 421827424fe87855307fe3e803b42ffa02738600
21561         * g10/sqlite.h (enum sqlite_arg_type): Add SQLITE_ARG_BLOB.
21562         (sqlite3_stepx_callback): New declaration.
21563         (sqlite3_stepx): Change the callback's type to sqlite3_stepx_callback,
21564         which passes an additional parameter, the sqlite3_stmt *.  Update
21565         users.
21566
21567         gpg: Move sqlite helper functions into their own file.
21568         + commit 351f4213e192aa11500c0c590d11183edbe326c5
21569         * g10/tofu.c (sqlite3_exec_printf): Move from here...
21570         * g10/sqlite.c (sqlite3_exec_printf): ... to this new file.  Don't
21571         mark as static.
21572         * g10/tofu.c (sqlite3_stepx): Move from here...
21573         * g10/sqlite.c (sqlite3_stepx): ... to this new file.  Don't
21574         mark as static.
21575         * g10/tofu.c (enum sqlite_arg_type): Move from here...
21576         * g10/sqlite.h (enum sqlite_arg_type): ... to this new file.
21577
21578 2015-10-29  NIIBE Yutaka  <gniibe@fsij.org>
21579
21580         doc: Don't install gpg-zip.1.
21581         + commit d25e29ad9374da1c11ccfc38f392dbab2d707042
21582         * doc/Makefile.am (myman_pages): Remove gpg-zip.1.
21583         (DISTCLEANFILES): Add gpg-zip.1.
21584
21585 2015-10-28  Werner Koch  <wk@gnupg.org>
21586
21587         sm: Allow combination of usage flags --gen-key.
21588         + commit 8b6c83dcb086ef09b2676e4d5b0111c88b7b8bf8
21589         * sm/certreqgen.c (create_request): Re-implement building of the
21590         key-usage extension.
21591
21592 2015-10-28  Damien Goutte-Gattat  <dgouttegattat@incenp.org>
21593
21594         doc: Document some changed default options.
21595         + commit e095a3fcf2ccc6cc4e258111dc395558069a1164
21596         * doc/gpg.texi: Update the description of some options which are
21597           now enabled by default.
21598
21599 2015-10-28  Werner Koch  <wk@gnupg.org>
21600
21601         dirmngr: Fix NULL-deref while loading a CRL.
21602         + commit fa15a71daff8414bf4112bc2826dc495ff2fb01f
21603         * dirmngr/crlcache.c (crl_parse_insert): Set error before leaping to
21604         failure.
21605
21606         dirmngr: Minor cleanup of the SRV RR code.
21607         + commit 949a5cfdabcafab93c1ac092c0459b59318805b9
21608         * dirmngr/dns-stuff.c: Include unistd.h.
21609         (getsrv): Run srand only once.
21610         * dirmngr/t-dns-stuff.c (main): Allow passing another name for --srv
21611         and change output format.
21612
21613         dirmngr: Add a getaddrinfo wrapper backend using ADNS.
21614         + commit e026efb4363bc6e3c41ed533daf06f103ebd2e32
21615         * dirmngr/dns-stuff.c: Replace all use of default_errsource.
21616         (my_adns_init): Move to top.
21617         (resolve_name_adns): New.
21618         (resolve_dns_name) [USE_ADNS]: Divert to new func.
21619
21620 2015-10-26  Werner Koch  <wk@gnupg.org>
21621
21622         gpg: Do not call an extra get_validity if no-show-uid-validity is used.
21623         + commit a6c2c098435a703ca02abf651ff4fa45e5a4db9a
21624         * g10/mainproc.c (check_sig_and_print): Do not call the informational
21625         get_validity if we are not going to use it.
21626
21627 2015-10-26  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
21628
21629         gpg: Ensure all weak digest rejection notices are shown.
21630         + commit 91015d021b3dcbe21ad0e580a4f34c523abf9e72
21631         * g10/main.h: Add rejection_shown flag to each weakhash struct
21632         * g10/misc.c (print_digest_algo_note, additional_weak_digest): Do not
21633         treat MD5 separately; (print_digest_rejected_note): Use
21634         weakhash.rejection_shown instead of static shown.
21635         * g10/options.h (opt): Change from additional_weak_digests to
21636         weak_digests.
21637         * g10/sig-check.c: Do not treat MD5 separately.
21638         * g10/gpg.c (main): Explicitly set MD5 as weak.
21639         * g10/gpgv.c (main): Explicitly set MD5 as weak.
21640
21641 2015-10-26  Werner Koch  <wk@gnupg.org>
21642
21643         w32: Make it build again if Tofu support is not available.
21644         + commit 0d37a40fc34519e93af3ceffff2cd726d29576d3
21645         * g10/keylist.c (public_key_list) [!USE_TOFU]: Do not call tofu
21646         functions.
21647
21648         dirmngr: Support Tor hidden services.
21649         + commit 4524a2a3714f263d56bb7db349c169b456994fd9
21650         * dirmngr/dns-stuff.c (is_onion_address): New.
21651         * dirmngr/ks-engine-hkp.c (hostinfo_s): Add field "onion".
21652         (map_host): Special case onion addresses.
21653         (ks_hkp_print_hosttable): Print an 'O' for an onion address.
21654         * dirmngr/http.c (connect_server): Special case onion addresses.
21655
21656         dirmngr,w32: Remove gethostbyname hack and make it build again.
21657         + commit 7735bbe539af35ce16e270946d5ae798c5989d6e
21658         * dirmngr/http.c (connect_server) [W32]: Remove gethostbyname hack;
21659         we require getaddrinfo anyway.
21660         * dirmngr/dns-stuff.c (AI_ADDRCONFIG): Add replacement if not defined.
21661         (map_eai_to_gpg_error) [W32]: Take care of unsupported codes.
21662
21663 2015-10-26  Neal H. Walfield  <neal@g10code.com>
21664
21665         gpg: Make sure we only have a single SQL statement.
21666         + commit c18fb0d99b633bb267dead6e7c46229f4b780bc3
21667         * g10/tofu.c (sqlite3_stepx): Make sure SQL only contains a single SQL
21668         statement.
21669
21670         gpg: When the TOFU DB is in batch mode, periodically drop the locks.
21671         + commit 5b0ed7674dc718ee98e0c80aa93ce014f2b51411
21672         * g10/tofu.c: Include <sched.h>.
21673         (batch_update_started): New variable.
21674         (begin_transaction): If we've been in batch mode for a while, then
21675         commit any extant batch transactions.
21676         (tofu_begin_batch_update): If we are not in batch mode, initialize
21677         batch_update_started.
21678
21679 2015-10-25  Werner Koch  <wk@gnupg.org>
21680
21681         dirmngr: Add workaround for broken getaddrinfo.
21682         + commit 5e7ac031f513ad3b60e4f092fa72b3bec0676515
21683         * dirmngr/dns-stuff.c (resolve_name_standard): On failure retry by
21684         first resolving the CNAME.
21685         (get_dns_cname): New.
21686
21687         * dirmngr/t-dns-stuff.c (main): Add option --cname.
21688
21689         dirmngr: Better handle systems without IPv6 or IPv4.
21690         + commit 0e3c9f184a5fb3e41277700d690febc2eee9600a
21691         * dirmngr/dns-stuff.c (resolve_name_standard): Use AI_ADDRCONFIG.
21692
21693         dirmngr: Replace use of getnameinfo by resolve_dns_addr.
21694         + commit 927f34603d942868af6a7bd0f347681bbad76a94
21695         * dirmngr/ks-engine-hkp.c (my_getnameinfo): Remove.
21696         (map_host): Use resolve_dns_addr.
21697
21698         dirmngr: Implement a getnameinfo wrapper.
21699         + commit 816505958ac4308ee0dfe787d1b706982428b6cc
21700         * dirmngr/dns-stuff.h (DNS_NUMERICHOST): New.
21701         (DNS_WITHBRACKET): New.
21702         * dirmngr/dns-stuff.c (resolve_name_standard): Factor code out to...
21703         (map_eai_to_gpg_error): new.
21704         (resolve_addr_standard): New.
21705         (resolve_dns_addr): New.
21706
21707         * dirmngr/ks-engine-hkp.c (is_ip_address): Move to ...
21708         * dirmngr/dns-stuff.c (is_ip_address): here.  Add support for non
21709         bracketed v6 addresses.
21710
21711         * dirmngr/t-dns-stuff.c: Remove header netdb.h.
21712         (main): Add option --bracket.  Use resolve_dns_name instead of
21713         getnameinfo.
21714
21715 2015-10-23  Neal H. Walfield  <neal@g10code.com>
21716
21717         gpg: Provide an interface to patch TOFU updates.
21718         + commit 7f65e84ac035e8f7a25639a6b09eb6000115e337
21719         * g10/tofu.c (struct db): Rename begin_transaction to savepoint_batch.
21720         Rename end_transaction to savepoint_batch_commit.  Update users.
21721         Remove field rollback.  Add fields savepoint_inner and
21722         savepoint_inner_commit.  Add field batch_update.
21723         (dump_cache): New function.
21724         (batch_update): New variable.
21725         (begin_transaction). New function.
21726         (end_transaction): New function.
21727         (rollback_transaction): New function.
21728         (tofu_begin_batch_update): New function.
21729         (tofu_end_batch_update): New function.
21730         (closedb): End any pending batch transaction.
21731         (closedbs): Assert that none of the DBs have a started batch
21732         transaction if we not in batch mode.
21733         (record_binding): Use the begin_transaction, end_transaction and
21734         rollback_transaction functions instead of including the SQL inline.
21735         Also start a batch mode transaction if we are using the flat format.
21736         (tofu_register): Use the begin_transaction, end_transaction and
21737         rollback_transaction functions instead of including the SQL inline.
21738         * g10/gpgv.c (tofu_begin_batch_update): New function.
21739         (tofu_end_batch_update): New function.
21740         * g10/test-stubs.c (tofu_begin_batch_update): New function.
21741         (tofu_end_batch_update): New function.
21742
21743         gpg: Cache prepared SQL queries and open DB connections.
21744         + commit 297cf8660ce346638e42934d84d746768f8bb10a
21745         * g10/tofu.c: Include <stdarg.h>.
21746         (prepares_saved) [DEBUG_TOFU_CACHE]: New variable.
21747         (queries) [DEBUG_TOFU_CACHE]: New variable.
21748         (struct db): Add fields prevp, begin_transaction, end_transaction,
21749         rollback, record_binding_get_old_policy, record_binding_update,
21750         record_binding_update2, get_policy_select_policy_and_conflict,
21751         get_trust_bindings_with_this_email, get_trust_gather_other_user_ids,
21752         get_trust_gather_other_keys, register_already_seen, and
21753         register_insert.
21754         [DEBUG_TOFU_CACHE]: Add field hits.
21755         (STRINGIFY): New macro.
21756         (STRINGIFY2): New macro.
21757         (enum sqlite_arg_type): New enum.
21758         (sqlite3_stepx): New function.
21759         (combined_db): Remove variable.
21760         (opendb): Don't cache the combined db.
21761         (struct dbs): New struct.  Update users to use this as the head of the
21762         local DB list rather than overloading struct db.
21763         (unlink_db): New function.
21764         (link_db): New function.
21765         (db_cache): New variable.
21766         (db_cache_count): New variable.
21767         (DB_CACHE_ENTRIES): Define.
21768         (getdb): If the dbs specific cache doesn't include the DB, look at
21769         DB_CACHE.  Only if that also doesn't include the DB open the
21770         corresponding DB.
21771         (closedb): New function.
21772         (opendbs): Don't open the combined DB.  Just return an initialized
21773         struct dbs.
21774         (closedbs): Don't close the dbs specific dbs.  Attach them to the
21775         front of DB_CACHE.  If DB_CACHE contains more than DB_CACHE_ENTRIES,
21776         close enough dbs from the end of the DB_CACHE list such that DB_CACHE
21777         only contains DB_CACHE_ENTRIES.  Don't directly close the dbs, instead
21778         use the new closedb function.
21779         [DEBUG_TOFU_CACHE]: Print out some statistics.
21780         (record_binding): Use sqlite3_stepx instead of sqlite3_exec or
21781         sqlite3_exec_printf.
21782         (get_policy): Likewise.
21783         (get_trust): Likewise.
21784         (tofu_register): Likewise.
21785
21786         gpg: Return the DBs meta-handle rather than the sqlite3 handle.
21787         + commit cd879d4bd69a578be5a1ff96497f8c1181885563
21788         * g10/tofu.c (getdb): Return a struct db * instead of an sqlite *.
21789         Update users.
21790
21791         gpg: Use the proper type.
21792         + commit 3c4c89cc35280164b509977c5288b0a06d6f530e
21793         * g10/options.h: Include "tofu.h".
21794         (opt.tofu_default_policy): Change type to enum tofu_policy.
21795         * g10/gpgv.c (enum tofu_policy): Don't redeclare.
21796         * g10/test-stubs.c (enum tofu_policy): Likewise.
21797
21798 2015-10-22  Werner Koch  <wk@gnupg.org>
21799
21800         dirmngr: Implement Tor mode for SRV RRs.
21801         + commit 8b06d7f41aec6cb993445935dba7c60e033d026a
21802         * dirmngr/dns-stuff.c (get_dns_cert): Factor adns init out to...
21803         (my_adns_init): new.
21804         (getsrv)[USE_ADNS]: Use my_adns_init.
21805         (getsrv)[!USE_ADNS]: Return an error if Tor mode is active.
21806
21807         * dirmngr/t-dns-stuff.c: Add option --use-tor.
21808
21809         dirmngr: Do not use MAXDNAME.
21810         + commit e03a4a94bb67d4a6c958b37671f83456e203f325
21811         * dirmngr/dns-stuff.c (getsrv): Replace MAXDNAME.
21812         * dirmngr/dns-stuff.h (MAXDNAME): Remove.
21813         (struct srventry): Use a fixed value instead of MAXDNAME.
21814         * dirmngr/http.c (connect_server): Use DIMof instead of MAXDNAME.
21815         Malloc a helper array.
21816
21817         Move SRV RR code from common/ to dirmngr/.
21818         + commit 41bb01ae792af78edd28bf1b735cacc0b3ac428a
21819         * common/srv.c: Merge into dirmngr/dns-stuff.c.  Delete file.
21820         * common/srv.h: Merge into dirmngr/dns-stuff.h.  Delete file.
21821         * common/Makefile.am (common_sources): Remove srv.c and srv.h.
21822         * g10/keyserver.c: Do not include srv.h.  The code using it is anyway
21823         disabled.
21824         * dirmngr/http.c: Remove header srv.h and stubs.
21825         * dirmngr/t-dns-stuff.c: Add option --srv.
21826
21827 2015-10-21  Werner Koch  <wk@gnupg.org>
21828
21829         dirmngr: Use the new DNS wrapper for the HTTP module.
21830         + commit 1e34007c972c1d7730cfcacd88f6bbebba7dec1d
21831         * dirmngr/t-http.c (main): Init assuan sockets.
21832         * dirmngr/http.c: Include dns-stuff.h.
21833         (connect_server)[!HAVE_GETADDRINFO]: Remove all code.
21834         (connect_server): Change to use resolve_dns_name.
21835
21836         dirmngr: Allow use of http.c if USE_NPTH is not defined.
21837         + commit b6af3377e14fad35b9c6041b11888cabce6e8a56
21838         * dirmngr/http.c (send_request): Always set the gnutls pull/push
21839         functions.
21840         (my_npth_read): Rename to ...
21841         (my_gnutls_read) .. this.  Use system read if !USE_NPTH.
21842         (my_npth_write): Rename to ...
21843         (my_gnutls_write) .. this.  Use system write if !USE_NPTH.
21844
21845         dirmngr: Check that getaddrinfo is available.
21846         + commit 6fafda979df8e7e117f8e6929bcce89513a6e746
21847         * dirmngr/Makefile.am (t_http_SOURCES): Add dns-stuff.c.
21848         (t_ldap_parse_uri_SOURCES): Ditto.
21849         * dirmngr/dns-stuff.c: Bail out if neither ADNS nor getaddrinfo is
21850         available.
21851
21852         dirmngr: Use the new DNS wrapper for the HKP engine.
21853         + commit afbe87fa2d259b665b2d67a038a8535cfcfee094
21854         * dirmngr/ks-engine-hkp.c (my_getnameinfo): Change arg type to
21855         dns_addrinfo_t.
21856         (map_host): Replace getaddrinfo by resolve_dns_name.
21857
21858         dirmngr: Implement a getaddrinfo wrapper.
21859         + commit 8bccbf477878fd99baa96e11db9db99aaf1e8d91
21860         * dirmngr/dns-stuff.h: Include some header files.
21861         (dns_addinfo_t, dns_addrinfo_s): New.
21862         * dirmngr/dns-stuff.c: Always include DNS related headers.
21863         (free_dns_addrinfo): New.
21864         (resolve_name_standard): New.
21865         (resolve_dns_name): New.
21866
21867         * dirmngr/t-dns-stuff.c: Include netdb.h.
21868         (main): Keep old default mode with no args but else print outout of
21869         resolve_dns_name.  Revamp option parser.
21870
21871         common: Add more replacement error codes.
21872         + commit ffe60eb3d2b8f7d6c506804ce4645d695c91f237
21873         * common/util.h (GPG_ERR_SERVER_FAILED): New.
21874         (GPG_ERR_NO_KEY): New.
21875         (GPG_ERR_NO_NAME): New.
21876
21877 2015-10-21  Neal H. Walfield  <neal@g10code.com>
21878
21879         gpg: If the saved trust model is unknown, default to tofu+pgp.
21880         + commit 9afeb4cca10c3632495fe71b23df99a4878bd3a5
21881         * g10/trustdb.c (init_trustdb): If the saved trust model is unknown,
21882         default to tofu+pgp instead of pgp.
21883
21884         gpg: Don't accidentally free UTK_LIST.
21885         + commit 8c3b7915d675ca5346c17244654d5c6ab583ac44
21886         * g10/trustdb.c (validate_keys): Don't free UTK_LIST.
21887
21888         gpg: When evaluating trust reg exps, treat tofu+pgp like pgp.
21889         + commit cbaca254ac818c49c18d4480d3c7bd246cc57ae8
21890         * g10/trustdb.c (validate_one_keyblock): When checking trust regular
21891         expressions, treat the tofu+pgp trust model the same as the pgp trust
21892         model.
21893
21894         gpg: If a key is ultimate trusted, return that in the tofu model.
21895         + commit df57390d68482c5b3fa5ff3a42a29ae1b6cbb23c
21896         * g10/tofu.c (get_trust): If the policy is auto or none, check if the
21897         key is ultimately trusted.  If so, return that.
21898         (tofu_register): If the key is ultimately trusted, don't show any
21899         statistics.
21900         (tofu_get_validity): Likewise.
21901
21902         gpg: Keep the trust DB up to date for the tofu and tofu+pgp models.
21903         + commit d05ff81732e20e6f9d6d7a6281a96a312b001abb
21904         * g10/trustdb.c (init_trustdb): Recognize tofu and tofu+pgp as
21905         possibly saved trust models.  Also register the ultimately trusted
21906         keys if the trust model is tofu or tofu+pgp.
21907         (check_trustdb): Don't skip if the trust model is tofu or tofu+pgp.
21908         (update_trustdb): Likewise.
21909         (tdb_check_trustdb_stale): Likewise.
21910         (validate_keys): If the trust model is TOFU, just write out the
21911         ultimately trusted keys.
21912
21913         gpg: Factor out code into a standalone function.
21914         + commit 243f90afba87e99ca42e2451ac5cc59d00a044ac
21915         * g10/trustdb.c (tdb_keyid_is_utk): New function.
21916         (add_utk): Use it.
21917
21918         dirmngr: Allow building with libassuan < 2.3.
21919         + commit a79045e38d239a7f6e787cf7c1132772c737cc0e
21920         * dirmngr/http.c (send_request): Use newer assuan function only if
21921         available.
21922
21923 2015-10-21  Neal H. Walfield  <neal@g10code.com>
21924             Andre Heinecke  <aheinecke@intevation.de>
21925
21926         gpg: Make the tofu DB check and initialization atomic.
21927         + commit 85bd7d9491f8cc13c2b03f19b4f70ea13b45c704
21928         * g10/tofu.c (initdb): Make the version check and the database
21929         initialization atomic.
21930
21931 2015-10-21  Werner Koch  <wk@gnupg.org>
21932
21933         build: Make --disable-g13 the default.
21934         + commit 485e0a221deb5c68f29b6a7a110b349dbe41c027
21935         * Makefile.am (DISTCHECK_CONFIGURE_FLAGS): Add --enable-g13.  Remove
21936         --enable-gpgtar because that is enabled anyway.
21937         * configure.ac: Do not build g13 by default.
21938
21939         dirmngr: Rename file dns-cert.c.
21940         + commit 5055b617a94587580bc16a56bb82333077b05693
21941         * dirmngr/dns-cert.c: Rename to dirmngr/dns-stuff.c.
21942         * dirmngr/dns-cert.h: Rename to dirmngr/dns-stuff.h and change
21943         includers.
21944         * dirmngr/t-dns-cert.c: Rename to dirmngr/t-dns-stuff.c.
21945         * dirmngr/Makefile.am: Adjust.
21946
21947         common: Add status code for use by g13.
21948         + commit 42571a38344e39f747315f754700a8181b8744fe
21949         * common/status.h (STATUS_PLAINTEXT_FOLLOWS): New.
21950
21951 2015-10-20  Werner Koch  <wk@gnupg.org>
21952
21953         dirmngr: Prefer ADNS over system resolver.
21954         + commit 58ebe50bdf4837e9ab2d3f8c6e5fcf28c66f26e9
21955         * configure.ac (HAVE_ADNS_IF_TORMODE): New ac_define.
21956         (USE_DNS_CERT): Prefer ADNS over the system resolver.
21957         * dirmngr/dns-cert.c (tor_mode): New global var.
21958         (enable_dns_tormode): New func.
21959         (get_dns_cert): Use DNS resolver at 8.8.8.8 in tor-mode.
21960         * dirmngr/server.c (cmd_dns_cert): If supported allow DNS requests.
21961
21962         w32: Allow building again.
21963         + commit c83b627174f46e841f1ccc018322fe499969c267
21964         * dirmngr/http.c (connect_server): Fix called function name.
21965
21966         build: Allow building without SQLlite support.
21967         + commit 734c61dc9d4915605816803182c9adcc1594e008
21968         * configure.ac: Add option --dsiable-tofu and --disable-sqlite.
21969         (NEED_SQLITE_VERSION): New var.
21970         (USE_TOFU): New ac_define and am_conditional.
21971         * autogen.sh (build-w32): Add PKG_CONFIG_LIBDIR to configure so that
21972         pkg-config find the correct .pc file.
21973
21974         * g10/Makefile.am (tofu_source): New.  Build only if enabled.
21975         * g10/gpg.c (parse_trust_model)[!USE_TOFU]: Disable tofu models.
21976         (parse_tofu_policy)[!USE_TOFU]: Disable all.
21977         (parse_tofu_db_format)[!USE_TOFU]: Disable all.
21978         (main) <aTOFUPolicy>[!USE_TOFU]: Skip.
21979         * g10/keyedit.c (show_key_with_all_names_colon)[!USE_TOFU]: Do not
21980         call tofu functions.
21981         * g10/keylist.c (list_keyblock_colon)[!USE_TOFU]: Ditto.
21982         * g10/trustdb.c (tdb_get_validity_core)[!USE_TOFU]: Skip tofu
21983         processing.
21984
21985 2015-10-20  Neal H. Walfield  <neal@g10code.com>
21986
21987         gpg: Don't die immediately if the TOFU DB is locked.
21988         + commit 26d457c218c2e93b2e2cf316f0c1074c70894d0f
21989         * g10/tofu.c (opendb): Don't die immediately if the DB is locked.
21990
21991         gpg: Improve output.
21992         + commit bc9ff6c85e2d89be4ee873b8a72a214759a66157
21993         * g10/tofu.c (get_trust): Also show the binding when indicating a
21994         conflict occurred.
21995
21996         gpg: Synchronize translation template.
21997         + commit 251c070f91e2c65baa3f1195f14a176440a8aafa
21998         * g10/tofu.c (show_statistics): Synchronize translation template.
21999
22000         gpg: When showing conflicts, also show bindings with no recorded sigs.
22001         + commit d3eca517745a862432fcfeaa729e5333b15ffa6a
22002         * g10/tofu.c (signature_stats_collect_cb): If the time_ago column is
22003         NULL, then both time_ago and count should be 0.
22004         (get_trust): Reverse the direction of the join so that we also get
22005         statistics about bindings without any signatures.
22006
22007         gpg: Improve text.
22008         + commit 445f94bc81b20959a667a4ad80ea6c73059540bf
22009         * g10/tofu.c (show_statistics): Improve text.
22010
22011         gpg: Use the right variable to display the information.
22012         + commit 4957e3236796979b58f35628351505ea5f4e936a
22013         * g10/tofu.c (get_trust): Use the right variable to display the
22014         conflicting key.
22015
22016         gpg: Make failing to create a directory a soft error.
22017         + commit eb8a0b051faa03584b3820200e10301936e82f51
22018         * g10/tofu.c (getdb): Don't exit if we can't create the directory.
22019         Just return an error.
22020
22021         common: Make sure tilde expansion works for the mkdir functions.
22022         + commit c3bb9fccb7963a0918b9ec6a4f10d568fac7c125
22023         * common/mkdir_p.c (gnupg_amkdir_p): Use make_filename_try on the
22024         first directory component as well.
22025
22026         gpg: Remove unused prototype digest_algo_from_sig.
22027         + commit d1a0b520b15bb941cdbf66c2e832c617af778ac8
22028         * g10/packet.h (digest_algo_from_sig): Remove prototype without a
22029         corresponding implementation.
22030
22031 2015-10-19  Werner Koch  <wk@gnupg.org>
22032
22033         dirmngr: Allow building with libassuan < 2.3.
22034         + commit 4e42ad300b3de9fab25095a9e82431b1ea2740e7
22035         * dirmngr/dirmngr.c (set_tor_mode): Use newer assuan function only if
22036         available.
22037         * dirmngr/http.c (http_raw_connect): Ditto.
22038
22039 2015-10-19  Neal H. Walfield  <neal@g10code.com>
22040
22041         gpg: Fix --desig-revoke.
22042         + commit c37621166e9cc2a818de73bc99287a393dbb5744
22043         * g10/revoke.c (gen_desig_revoke): Add additional parameter ctrl.
22044         Check that the secret key is available.  If not, display an error
22045         message.
22046
22047         gpg: Improve function documentation and some comments.
22048         + commit a608ee750dd83bf77a5fb4f0ab5bcf812436ba4d
22049         * g10/main.h: Improve function documentation.
22050         * g10/packet.h.h: Improve function documentation.
22051         * g10/sig-check.c: Improve function documentation and some comments.
22052
22053         gpg: Improve and regularize naming of signature checking functions.
22054         + commit 0433e667029508d6933e8798d3d95bcdde70a7aa
22055         * g10/packet.h (signature_check): Rename from this...
22056         (check_signature): ... to this.  Update users.
22057         (signature_check2): Rename from this...
22058         (check_signature2): ... to this.  Update users.
22059         * g10/sig-check.c (do_check): Rename from this...
22060         (check_signature_end): ... to this.  Update users.
22061         (do_check_messages): Rename from this...
22062         (check_signature_metadata_validity): ... to this.  Update users.
22063
22064         gpg: Mark local function as static.
22065         + commit 547a1b3fb881bb8581d03dbf4eacf49163eaa4b5
22066         * g10/tdbio.c (put_record_into_cache): Mark as static.
22067
22068 2015-10-19  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
22069
22070         gpg: Print warning when rejecting weak digests.
22071         + commit b98939812abf6c643c752ce7c325f98039a1a9e2
22072         * g10/misc.c (print_md5_rejected_note): Rename to ..
22073         (print_digest_rejected_note): this.  Parameterize function to take an
22074         enum gcry_md_algos.
22075         * g10/sig-check.c: Use print_digest_rejected_note() when rejecting
22076         signatures.
22077
22078         gpg: Add option --weak-digest to gpg and gpgv.
22079         + commit 76afaed65e3b0ddfa4923cb577ada43217dd4b18
22080         * g10/options.h: Add additional_weak_digests linked list to opts.
22081         * g10/main.h: Declare weakhash linked list struct and
22082         additional_weak_digest() function to insert newly-declared weak
22083         digests into opts.
22084         * g10/misc.c: (additional_weak_digest): New function.
22085         (print_digest_algo_note): Check for deprecated digests; use proper
22086         gcry_md_algos type.
22087         * g10/sig-check.c: (do_check): Reject weak digests in addition to MD5.
22088         * g10/gpg.c: Add --weak-digest option to gpg.
22089         * doc/gpg.texi: Document gpg --weak-digest option.
22090         * g10/gpgv.c: Add --weak-digest option to gpgv.
22091         * doc/gpgv.texi: Document gpgv --weak-digest option.
22092
22093 2015-10-19  Werner Koch  <wk@gnupg.org>
22094
22095         dirmngr: Make --use-tor work - still leaks DNS.
22096         + commit 6983fd131f648ba4acd57b266de9868911874d14
22097         * dirmngr/dirmngr.c (set_tor_mode): New.
22098         (main, reread_configuration): Call it.
22099         * dirmngr/http.c (http_raw_connect, send_request): Check whether TOR
22100         mode is enabled if the FORCE_TOR flag is given.
22101
22102         dirmngr: Use Assuan socket wrappers for http.c.
22103         + commit 8c609eaf35b547f02979ef0b206520dd0853b294
22104         * dirmngr/http.c: Include assuan.h.  Changed all code taking a socket
22105         descriptor from int to assuan_fd_t.
22106         (my_unprotect, my_protect): New.
22107         (my_connect): Remove.
22108         (_my_socket_new, _my_socket_unref): use assuan_sock_close.
22109         (connect_server): Use assuan_sock_connect, assuan_sock_new, and
22110         assuan_sock_close.
22111         * dirmngr/Makefile.am (t_common_ldadd): Add LIBASSUAN_LIBS.
22112
22113 2015-10-19  Neal H. Walfield  <neal@g10code.com>
22114
22115         gpg: Fix formatting.
22116         + commit 253afa244487dd8129816615ac2865c9fe812aaf
22117         * g10/tofu.c (get_trust): Fix formatting.
22118
22119         gpg: Don't forget to free some memory.
22120         + commit e56a116f9a1171ccf8b3293887a217953a46fc20
22121         * g10/tofu.c (tofu_register): Free SIG_DIGEST before returning.
22122
22123         gpg: If a conflict occurs in batch mode, record that.
22124         + commit 55d88454652543c98d74376977d855e394df6c92
22125         * g10/tofu.c (get_trust): If a conflict occurs when MAY_ASK is false,
22126         set conflict to the key.  When prompting the user, don't show the
22127         conflicting key if the conflicting key is the current key.
22128
22129 2015-10-18  Werner Koch  <wk@gnupg.org>
22130
22131         gpg: Silence two more warnings.
22132         + commit c2c400714854d5a127a6966200d345d0d6cfc7d4
22133         * g10/trustdb.c (tdb_get_validity_core): Silence a warning.
22134         * g10/tofu.c (tofu_register): Move SIG_DIGEST computation to the top
22135         so that it is not uninitialized in case of an early error.
22136
22137         gpg: Fix harmless compiler warnings.
22138         + commit 558bcd43ae0a841cf1e58e06f5d72a19d5bc70cd
22139         * g10/tofu.h (_tofu_GET_POLICY_ERROR): New.  This avoids warnings
22140         about undefined enum values in a switch.
22141         * g10/trustdb.h (_tofu_GET_TRUST_ERROR): New.
22142         * g10/tofu.c (TIME_AGO_FUTURE_IGNORE): Move to the top.
22143         (opendbs): Avoid compiler warning (use braces).
22144         (GET_POLICY_ERROR): Replace define by enum _tofu_GET_POLICY_ERROR.
22145         (get_policy): Remove assert.
22146         (GET_TRUST_ERROR): Replace by _tofu_GET_TRUST_ERROR macro.
22147         (show_statistics): Undef MIN_SECS et al. after use.
22148
22149         common: Avoid warning about const char ** assignment.
22150         + commit e64c805b0c270d859ddf2c35d573110cf25e8d48
22151         * common/mkdir_p.c (gnupg_amkdir_p): Also strdup first item.  Return
22152         an error on malloc failure.
22153         (gnupg_mkdir_p): Fix type of dirs and tmp_dirs.
22154
22155         Move http module from common/ to dirmngr/.
22156         + commit 5aa1b392b1bf6fcf4cd380862c5affac39a4f34d
22157         * common/http.c: Move to ../dirmngr/.
22158         * common/http.h: Move to ../dirmngr/.
22159         * common/t-http.c: Move to ../dirmngr/.
22160         * common/tls-ca.pem: Move to ../dirmngr/.
22161         * common/Makefile.am: Do not build libcommontls.a libcommontlsnpth.a.
22162         Remove http.c related stuff.
22163         * po/POTFILES.in: Move http.c to dirmngr/.
22164         * dirmngr/Makefile.am (EXTRA_DIST): Add tls-ca.pem.
22165         (module_maint_tests): New.
22166         (noinst_PROGRAMS): Add module_maint_tests.
22167         (dirmngr_SOURCES): Add http.c and http.h.
22168         (dirmngr_LDADD): Remove libcommontlsnpth.
22169         (t_common_ldadd): Ditto.
22170         (t_http_SOURCES, t_http_CFLAGS, t_http_LDADD): New.
22171         (t_ldap_parse_uri_SOURCES): Add http.c.
22172         (t_ldap_parse_uri_CFLAGS): Build without npth.
22173         ($(PROGRAMS)): Do not require libcommontls.a libcommontlsnpth.a.
22174         * dirmngr/dirmngr.h, dirmngr/ks-engine.h: Fix include of http.h.
22175
22176 2015-10-18  Neal H. Walfield  <neal@g10code.com>
22177
22178         g10: Fix assert.
22179         + commit 128a456e775edf393d47e40bb9ae8b62434e2978
22180         * g10/tofu.c (get_trust): Fix assert.
22181
22182         g10: Add TOFU support.
22183         + commit f77913e0ff7be4cd9c6337a70ac715e6f4a43572
22184         * configure.ac: Check for sqlite3.
22185         (SQLITE3_CFLAGS): AC_SUBST it.
22186         (SQLITE3_LIBS): Likewise.
22187         * g10/Makefile.am (AM_CFLAGS): Add $(SQLITE3_CFLAGS).
22188         (gpg2_SOURCES): Add tofu.h and tofu.c.
22189         (gpg2_LDADD): Add $(SQLITE3_LIBS).
22190         * g10/tofu.c: New file.
22191         * g10/tofu.h: New file.
22192         * g10/options.h (trust_model): Define TM_TOFU and TM_TOFU_PGP.
22193         (tofu_db_format): Define.
22194         * g10/packet.h (PKT_signature): Add fields digest and digest_len.
22195         * g10/gpg.c: Include "tofu.h".
22196         (cmd_and_opt_values): Declare aTOFUPolicy, oTOFUDefaultPolicy,
22197         oTOFUDBFormat.
22198         (opts): Add them.
22199         (parse_trust_model): Recognize the tofu and tofu+pgp trust models.
22200         (parse_tofu_policy): New function.
22201         (parse_tofu_db_format): New function.
22202         (main): Initialize opt.tofu_default_policy and opt.tofu_db_format.
22203         Handle aTOFUPolicy, oTOFUDefaultPolicy and oTOFUDBFormat.
22204         * g10/mainproc.c (do_check_sig): If the signature is good, copy the
22205         hash to SIG->DIGEST and set SIG->DIGEST_LEN appropriately.
22206         * g10/trustdb.h (get_validity): Add arguments sig and may_ask.  Update
22207         callers.
22208         (tdb_get_validity_core): Add arguments sig and may_ask.  Update
22209         callers.
22210         * g10/trust.c (get_validity) Add arguments sig and may_ask.  Pass them
22211         to tdb_get_validity_core.
22212         * g10/trustdb.c: Include "tofu.h".
22213         (trust_model_string): Handle TM_TOFU and TM_TOFU_PGP.
22214         (tdb_get_validity_core): Add arguments sig and may_ask.  If
22215         OPT.TRUST_MODEL is TM_TOFU or TM_TOFU_PGP, compute the TOFU trust
22216         level.  Combine it with the computed PGP trust level, if appropriate.
22217         * g10/keyedit.c: Include "tofu.h".
22218         (show_key_with_all_names_colon): If the trust mode is tofu or
22219         tofu+pgp, then show the trust policy.
22220         * g10/keylist.c: Include "tofu.h".
22221         (public_key_list): Also show the PGP stats if the trust model is
22222         TM_TOFU_PGP.
22223         (list_keyblock_colon): If the trust mode is tofu or
22224         tofu+pgp, then show the trust policy.
22225         * g10/pkclist.c: Include "tofu.h".
22226         * g10/gpgv.c (get_validity): Add arguments sig and may_ask.
22227         (enum tofu_policy): Define.
22228         (tofu_get_policy): New stub.
22229         (tofu_policy_str): Likewise.
22230         * g10/test-stubs.c (get_validity): Add arguments sig and may_ask.
22231         (enum tofu_policy): Define.
22232         (tofu_get_policy): New stub.
22233         (tofu_policy_str): Likewise.
22234         * doc/DETAILS: Describe the TOFU Policy field.
22235         * doc/gpg.texi: Document --tofu-set-policy, --trust-model=tofu,
22236         --trust-model=tofu+pgp, --tofu-default-policy and --tofu-db-format.
22237         * tests/openpgp/Makefile.am (TESTS): Add tofu.test.
22238         (TEST_FILES): Add tofu-keys.asc, tofu-keys-secret.asc,
22239         tofu-2183839A-1.txt, tofu-BC15C85A-1.txt and tofu-EE37CF96-1.txt.
22240         (CLEANFILES): Add tofu.db.
22241         (clean-local): Add tofu.d.
22242         * tests/openpgp/tofu.test: New file.
22243         * tests/openpgp/tofu-2183839A-1.txt: New file.
22244         * tests/openpgp/tofu-BC15C85A-1.txt: New file.
22245         * tests/openpgp/tofu-EE37CF96-1.txt: New file.
22246         * tests/openpgp/tofu-keys.asc: New file.
22247         * tests/openpgp/tofu-keys-secret.asc: New file.
22248
22249 2015-10-16  Neal H. Walfield  <neal@g10code.com>
22250
22251         common: Prefix the mkdir functions with gnupg_.  Make args const.
22252         + commit 93e855553eba03f5c31682e0aaf39f18f29860b7
22253         * common/mkdir_p.h (mkdir_p): Rename from this...
22254         (gnupg_mkdir_p): ... to this.  Change directory_component's type from
22255         char * to const char *.
22256         (amkdir_p): Rename from this...
22257         (gnupg_amkdir_p): ... to this.  Change directory_component's type from
22258         char * to const char *.
22259         * common/mkdir_p.c (mkdir_p): Rename from this...
22260         (gnupg_mkdir_p): ... to this.  Change directory_component's type from
22261         char * to const char *.
22262         (amkdir_p): Rename from this...
22263         (gnupg_amkdir_p): ... to this.  Change directory_component's type from
22264         char * to const char *.
22265
22266 2015-10-14  NIIBE Yutaka  <gniibe@fsij.org>
22267
22268         cleanup: Fix confusion between gpg_error_t and gpg_err_code_t.
22269         + commit 3de5ef759895837fe499cff7fb1fa7798e6d5754
22270         * dirmngr/crlcache.c (hash_dbfile): Use gpg_error_t for ERR.
22271         * kbx/keybox-update.c (keybox_set_flags): Call
22272         gpg_err_code_from_syserror.
22273
22274 2015-10-13  NIIBE Yutaka  <gniibe@fsij.org>
22275
22276         po: Update Japanese translation.
22277         + commit 0b4ebc398cc8aad3f25f84034cd6b129e55f1368
22278
22279
22280 2015-10-12  Werner Koch  <wk@gnupg.org>
22281
22282         gpg: Try hard to use MDC also for sign+symenc.
22283         + commit 4584125802be11833a5b289e864b45eedc2b45fd
22284         * g10/encrypt.c (use_mdc): Make it a global func.
22285         * g10/sign.c (sign_symencrypt_file): Use that function to decide
22286         whether to use an MDC.
22287         * tests/openpgp/conventional-mdc.test: Add a simple test case.
22288
22289 2015-10-09  Werner Koch  <wk@gnupg.org>
22290
22291         Release 2.1.9.
22292         + commit 086b8738f71ba26d36287db81f6d78116053ba66
22293
22294
22295 2015-10-09  NIIBE Yutaka  <gniibe@fsij.org>
22296
22297         agent: simplify agent_get_passphrase.
22298         + commit 5a12c45666cd16bc750d7f0e63620c295feb77ea
22299         * agent/call-pinentry.c (agent_get_passphrase): Simplify.
22300
22301         agent: fix agent_askpin.
22302         + commit 818fa4f71e1056831b35d0f8aff715c0e1d537e6
22303         * agent/call-pinentry.c (agent_askpin): Fix off-by-one error.
22304
22305         agent: Fix function return type for check_cb and agent_askpin.
22306         + commit f70f6695368444d8058305ab696e5e5a1bace18c
22307         * agent/call-pinentry.c (unlock_pinentry): Return gpg_error_t.
22308         (start_pinentry, setup_qualitybar): Likewise.
22309         (agent_askpin): Fix return value check of check_cb.
22310         * agent/command-ssh.c (reenter_compare_cb): Return gpg_error_t.
22311         (ssh_identity_register): Fix return value check of agent_askpin.
22312         * agent/cvt-openpgp.c (try_do_unprotect_cb): Return gpg_error_t.
22313         * agent/findkey.c (try_unprotect_cb): Likewise.
22314         * agent/genkey.c (reenter_compare_cb): Return gpg_error_t.
22315         (agent_ask_new_passphrase): Fix return value check of agent_askpin.
22316
22317 2015-10-08  Andre Heinecke  <aheinecke@intevation.de>
22318
22319         dirmngr: Default to http protocol for http-proxy.
22320         + commit ea079d283de6bf4ac70d7530fac70938e7c5e8f5
22321         * common/http.c (send_request): Fix handling for hostname:port string.
22322
22323 2015-10-08  Werner Koch  <wk@gnupg.org>
22324
22325         common: Allow building of mkdir_p.c for Windows.
22326         + commit 4c298525903f844eee95ecbcdc45f5ac034fa148
22327         * common/mkdir_p.c: Change license and comment debug statements.
22328         (amkdir_p, mkdir_p): Fail on malloc error and use default_errsource to
22329         build an error code.  Change return value to gpg_error_t.
22330         (amkdir_p): Use gnupg_mkdir.
22331
22332         * common/membuf.c: Include util.h first to avoid redefined macro
22333         warnings.
22334
22335         gpg: Add option --print-dane-records.
22336         + commit d7b8e76f9930750d669405dee3108c9bc8e87b91
22337         * g10/options.h (opt): Add field "print_dane_records".
22338         * g10/gpg.c (oPrintDANERecords): new.
22339         (opts): Add --print-dane-records.
22340         (main): Set that option.
22341         * g10/export.c (do_export): Remove EXPORT_DANE_FORMAT handling.
22342         (do_export_stream): Add EXPORT_DANE_FORMAT handling.
22343         * g10/keylist.c (list_keyblock_pka): Implement DANE record printing.
22344
22345         * g10/gpgv.c (export_pubkey_buffer): New stub.
22346         * g10/test-stubs.c (export_pubkey_buffer): New stub.
22347
22348         gpg: Pass CTRL parameter to all key listing functions.
22349         + commit b6d621583fc9cbda6f9376a24f2f4cf11499a4fd
22350         * g10/keylist.c (public_key_list): Add arg CTRL.
22351         (secret_key_list): Ditto.
22352         (list_all, list_one): Ditto.
22353         (locate_one): Ditto.
22354         (list_keyblock_pka): Ditto.
22355         (list_keyblock): Ditto.
22356         (list_keyblock_direct): Ditto.
22357         * g10/keygen.c (proc_parameter_file): Add arg CTRL.
22358         (read_parameter_file): Ditto.
22359         (quick_generate_keypair): Ditto.
22360         (do_generate_keypair): Ditto.
22361         (generate_keypair): Pass arg CTRL.
22362         * g10/gpg.c (main): Pass arg CTRL to quick_generate_keypair.
22363
22364 2015-10-07  Werner Koch  <wk@gnupg.org>
22365
22366         gpg: Remove unfinished experimental code to export as S-expressions.
22367         + commit a400958323d93036dca9c63135b167012ea64f8b
22368         * g10/options.h (EXPORT_SEXP_FORMAT): Remove.
22369         (EXPORT_DANE_FORMAT): New.
22370         * g10/export.c (parse_export_options): Remove "export-sexp-format".
22371         (export_seckeys): Adjust for removed option.
22372         (export_secsubkeys): Ditto.
22373         (do_export): Prepare for DANE format.
22374         (build_sexp, build_sexp_seckey): Remove.
22375         (do_export_stream): Remove use of removed functions.
22376
22377 2015-10-06  Werner Koch  <wk@gnupg.org>
22378
22379         gpg: Add new --auto-key-locate mechanism "dane".
22380         + commit 9ac31f91b10059474da1c9580fb99e94278d4c11
22381         * g10/call-dirmngr.c (gpg_dirmngr_dns_cert): Allow fetching via DANE.
22382         * g10/keyserver.c (keyserver_import_cert): Add arg "dane_mode".
22383         * g10/options.h (AKL_DANE): New.
22384         * g10/getkey.c (get_pubkey_byname): Implement AKL_DANE.
22385         (parse_auto_key_locate): Ditto.
22386
22387         dirmngr: Addlow fetching keys using OpenPGP DANE.
22388         + commit 264a81d82737369ee8beef771cf2bd2cd874320a
22389         * dirmngr/server.c (cmd_dns_cert): Add option --dane.
22390
22391         dirmngr: Improve DNS code to retrieve arbitrary records.
22392         + commit 211b8084ee4391baec35e8c5bd75a9ecbcb889a7
22393         * dirmngr/dns-cert.c (get_dns_cert): Add hack to retrieve arbitrary
22394         resource records.
22395         * dirmngr/dns-cert.h (DNS_CERTTYPE_RRBASE): New.
22396         (DNS_CERTTYPE_RR61): New.
22397
22398         dirmngr: Change DNS code to make additions easier.
22399         + commit 6cf80dc77ec5df3722924301ff4be2475966937b
22400         * dirmngr/dns-cert.c (get_dns_cert) [!USE_ADNS]: Change loop to allow
22401         adding more resource types.
22402
22403         dirmngr: Make commands RELOADDIRMNGR and KILLDIRMNGR work properly.
22404         + commit 7faf45effcd47d2d04d35090a1e01a1dbb99ec70
22405         * dirmngr/server.c (cmd_killdirmngr): Set assuan close flag.
22406         (cmd_reloaddirmngr): Use check_owner_permission.
22407
22408         dirmngr: Do tilde expansion for --hkp-cacert.
22409         + commit 9db6547a00cded92c00c8f8382b1b605be1027d2
22410         * dirmngr/dirmngr.c (parse_rereadable_options): Do tilde expansion and
22411         check for cert file existance in option --hkp-cacert.
22412
22413         gpg: Fail decryption for AES etc message w/o MDC.
22414         + commit 625e292108cc0fd9077769587a8c22abe7805e33
22415         * g10/mainproc.c (proc_encrypted): Fail for modern messages w/o MDC.
22416
22417 2015-10-06  NIIBE Yutaka  <gniibe@fsij.org>
22418
22419         agent: Fix verification of signature for smartcard.
22420         + commit 4a5bd1720f5a3dbb26f5daeb03725cae29be7e24
22421         * agent/pksign.c (agent_pksign_do): Use public key smartcard.
22422
22423         agent: Fix non-allocation for pinentry_loopback.
22424         + commit ce2a84b58833fd308d5fe11756721f39c953280a
22425         * agent/call-pinentry.c (agent_get_passphrase): Don't allocate, it will
22426         be allocated by pinentry_loopback.
22427
22428 2015-10-05  Werner Koch  <wk@gnupg.org>
22429
22430         gpg: Install a dirmngr.conf file.
22431         + commit f3959f14b6c496c726bbca5230becb7b6844a234
22432         * g10/dirmngr-conf.skel: New.
22433         * g10/Makefile.am (EXTRA_DIST): Add file.
22434         (install-data-local, uninstall-local): Install that file.
22435         * g10/openfile.c (copy_options_file): Add arg "name", return a value,
22436         simplify with xstrconcat, and factor warning message out to:
22437         (try_make_homedir): here.  Also install dirmngr.conf.
22438         * g10/options.skel: Remove --keyserver entry.
22439
22440         gpg: Deprecate the --keyserver option.
22441         + commit ae471fa978589fb61ecb0f89bbfe4d43cf2d5eac
22442         * g10/keyserver.c (keyserver_refresh): Change return type to
22443         gpg_error_t.  Use gpg_dirmngr_ks_list to print the name of the
22444         keyserver to use.
22445         (keyserver_search): Do not print the "no keyserver" error
22446         message.  The same error is anyway returned from dirmngr.
22447         * g10/call-dirmngr.c (ks_status_parm_s): Add field "keyword".
22448         (ks_status_cb): Handle other status keywords.
22449         (gpg_dirmngr_ks_list): New.
22450         * tools/gpgconf-comp.c (gc_options_gpg): Deprecate "keyserver".
22451         (gc_options_dirmngr): Add "Keyserver" group and "keyserver".
22452
22453         dirmngr: Add option --keyserver.
22454         + commit a48e6de603c3a312f02b1b5fdb813032eeae9074
22455         * dirmngr/dirmngr.c (oKeyServer): New.
22456         (opts): Add "keyserver".
22457         (parse_rereadable_options): Parse that options
22458         (main): Add option to the gpgconf list.
22459         * dirmngr/dirmngr.h (opt): Add field "keyserver".
22460         * dirmngr/server.c (ensure_keyserver): New.
22461         (make_keyserver_item): New.  Factored out from
22462         (cmd_keyserver): here.  Call ensure_keyserver.
22463         (cmd_ks_search): Call ensure_keyserver.
22464         (cmd_ks_get): Ditto.
22465         (cmd_ks_fetch): Ditto.
22466         (cmd_ks_put): Ditto.
22467
22468         dirmngr: Make clear that --use-tor is not yet ready for use.
22469         + commit 438730323a5d9bbf8dd5cd60d479b6c03f8721d0
22470         * dirmngr/dirmngr.c (main): Print a warning if --use-tor has been
22471         given.
22472         * tools/gpgconf-comp.c (gc_options_dirmngr): Make --use-tor invisible.
22473
22474         gpgconf: Change displayed name of Dirmngr to "Key Acquirer".
22475         + commit c6400c1aa82239f1c154ca27596600cae964515d
22476         * tools/gpgconf-comp.c (gc_component): Change printed name.
22477
22478 2015-10-02  Werner Koch  <wk@gnupg.org>
22479
22480         dirmngr: Fix use-after-free due to a realloc shrinking.
22481         + commit 75c64c2b6d77856b90903cc3b7c6a2f62ff8eb7b
22482         * dirmngr/ks-engine-hkp.c (map_host): Do not use original pointer
22483         after realloc.
22484
22485         agent: Fix alignment problem with the second passphrase struct.
22486         + commit ddf9dd135acd2b3635bb986f6dfc0e4e446d5fad
22487         * agent/genkey.c (agent_ask_new_passphrase): Use a separate malloc for
22488         PI2.  Check return value of the malloc function.
22489         * agent/command-ssh.c (ssh_identity_register): Use a separate malloc
22490         for PI2.  Wipe PI2.
22491
22492 2015-10-01  Werner Koch  <wk@gnupg.org>
22493
22494         gpg: Fix a practical hang after use of --faked-system-time.
22495         + commit 2acceba5cc299796c7b5b1851a9baeb75d9f32a1
22496         * g10/sign.c (update_keysig_packet): Bail out if we would need to long
22497         for a new timestamp.
22498
22499         gpg: Print more info with "check selfsig".
22500         + commit 2c60663a72f090573c4869e305b098b4b1fb23bd
22501         * g10/keyedit.c (print_and_check_one_sig): Print more Some sigsub
22502         packets.
22503
22504         gpg: Add debug helper to --edit-keys's check sub-command.
22505         + commit 13a3f65968f4a8205ca664cc46b1a53de4dc489b
22506         * g10/keyedit.c (print_and_check_one_sig): Add arg "extended" and
22507         print an asterisk for the chosen selfsig.
22508         (check_all_keysigs): Add arg "only_selfsig"
22509         (keyedit_menu) <cmdCHECK>: Add optional arg "selfsig".
22510
22511 2015-10-01  NIIBE Yutaka  <gniibe@fsij.org>
22512
22513         common: Fix strsplit.
22514         + commit a9895a5a72a851c5fcc70f16d5f8f588cc885751
22515         * common/stringhelp.c (strsplit): Fix arguments order.
22516
22517 2015-09-30  Neal H. Walfield  <neal@g10code.com>
22518
22519         common: Add mkdir_p.
22520         + commit c8584a1e559bc720412e1a2fc546a54ff4517205
22521         * common/mkdir_p.c: New file.
22522         * common/mkdir_p.h: New file.
22523         * common/Makefile.am (common_sources): Add mkdir_p.c and mkdir_p.h.
22524
22525         common: Remove unused files.
22526         + commit 5576146ede40b42bc632fd9697dd429a4d1409cf
22527         * common/xmalloc.c: Remove file.
22528         * common/xmalloc.h: Remove file.
22529
22530         common: Include <gpg-error.h>.
22531         + commit 270d3f55f9193ebda5e1b642d58daf905019914d
22532         * common/logging.h: Include <gpg-error.h>.
22533
22534 2015-09-29  Neal H. Walfield  <neal@g10code.com>
22535
22536         g10: Remove unused struct cmp_help_context_s.
22537         + commit 8ab63e4b5018044ecfb0b9910412487066886826
22538         * g10/sig-check.c (struct cmp_help_context_s) Remove unused struct.
22539
22540         g10: Avoid an unnecessary copy.
22541         + commit 12443eafa6e19b94a8b554126423e2a5ccc2dd7e
22542         * g10/sig-check.c (signature_check2): Avoid copying PK to RET_PK.
22543         Instead, directly use the provided storage.  If none is provided
22544         allocate some.
22545
22546 2015-09-29  NIIBE Yutaka  <gniibe@fsij.org>
22547
22548         ssh: Fix fingerprint computation for EdDSA key.
22549         + commit 5c067d54d349fdfb3243634789c8841515d2c28f
22550         * common/ssh-utils.c (get_fingerprint): Handle the prefix of 0x40.
22551         * common/t-ssh-utils.c (sample_keys): Add a new key.
22552
22553         agent: RSA signature verification by gpg-agent.
22554         + commit cfbe6ba9cf1414e9aa4977e2bbaecaa43154b2ae
22555         * g10/sign.c (do_sign): Let verify signature by gpg-agent.
22556         * agent/pksign.c (agent_pksign_do): Call gcry_pk_verify for RSA.
22557
22558 2015-09-28  Werner Koch  <wk@gnupg.org>
22559
22560         common: Provide two new error code replacements.
22561         + commit f1effdc5ecd0cc52a28db7ae28a5c28f33486542
22562         * common/util.h (GPG_ERR_FALSE, GPG_ERR_TRUE): Rew replcements.
22563
22564         common: Change calling convention for gnupg_spawn_process.
22565         + commit 83811e3f1f0c615b2b63bafdb49a35a0fc198088
22566         * common/exechelp.h (GNUPG_SPAWN_NONBLOCK): New.
22567         (GNUPG_SPAWN_RUN_ASFW, GNUPG_SPAWN_DETACHED): Macro to replace the
22568         numbers.
22569         * common/exechelp.h (gnupg_spawn_process): Change function to not take
22570         an optional stream for stdin but to return one.
22571         * common/exechelp-posix.c (gnupg_spawn_process): Implement change.
22572         (create_pipe_and_estream): Add args outbound and nonblock.
22573         * common/exechelp-w32.c (gnupg_spawn_process): Implement change.
22574
22575 2015-09-28  NIIBE Yutaka  <gniibe@fsij.org>
22576
22577         scd: Handle error correctly.
22578         + commit 6bb7206e357acfd7276a8f1334c0f0c9cc6ed100
22579         * scd/apdu.c (apdu_connect): Initialize variables and check an error
22580         of apdu_get_status_internal.
22581
22582 2015-09-22  Werner Koch  <wk@gnupg.org>
22583
22584         ssh: Add 256, 384 and 521 bit test keys for the fingerprint.
22585         + commit 12ff806d1b63d08cb43d131065d51353495d9346
22586         * common/t-ssh-utils.c (sample_keys): Add 3 new keys.
22587
22588         ssh: Fix fingerprint computation for 384 bit ECDSA keys.
22589         + commit 2167951b275bae51cf669c02547e2e7ea8fbe2ee
22590         * common/ssh-utils.c (get_fingerprint): Fix hashed string.
22591
22592 2015-09-19  NIIBE Yutaka  <gniibe@fsij.org>
22593
22594         agent: Fix importing ECC key.
22595         + commit 1542dc604b9c3e6a6a99750c48f7800e72584a89
22596         * agent/cvt-openpgp.c (convert_from_openpgp_main): Only encrypted
22597         parameters are stored as opaque.
22598         (apply_protection): ARRAY members are all normal, non-opaque MPI.
22599         (extract_private_key): Get public key as normal, non-opaque MPI.
22600         Remove support of ECC key with '(flags param)'.
22601         Remove support of "ecdsa" and "ecdh" keys of our experiment.
22602
22603         scd: Fix KEYTOCARD handling for ECC key.
22604         + commit 708b7eccdef8d274bd5578b9a5fd908e9685c795
22605         * scd/app-openpgp.c (ecc_writekey): Only public key can be native
22606         format.
22607
22608 2015-09-19  Neal H. Walfield  <neal@g10code.com>
22609
22610         common: Add new function strlist_length.
22611         + commit 8499c4f84a664bedbdf5a5689cb02420909f1968
22612         * common/strlist.c (strlist_length): New function.
22613
22614 2015-09-18  Werner Koch  <wk@gnupg.org>
22615
22616         gpgconf: Change displayed name of Dirmngr to "Network Manager".
22617         + commit 819bba75aaed11ecef2e274add173718358212b9
22618         * tools/gpgconf-comp.c (gc_component): Change printed name.
22619
22620         dirmngr: Add option --use-tor as a stub.
22621         + commit c091816b4a90d7eea6f8601ec1522a0a006794e8
22622         * dirmngr/dirmngr.h (opt): Add field "use_tor".
22623         * dirmngr/dirmngr.c (oUseTor): New.
22624         (opts): Add --use-tor.
22625         (parse_rereadable_options): Set option.
22626         (main): Tell gpgconf about that option.
22627
22628         * dirmngr/crlfetch.c (crl_fetch): Pass TOR flag to the http module and
22629         return an error if LDAP is used in TOR mode.
22630         (ca_cert_fetch): Return an error in TOR mode.
22631         (start_cert_fetch): Ditto.
22632         * dirmngr/ks-engine-finger.c (ks_finger_fetch): Pass TOR flag to the
22633         http module.
22634         * dirmngr/ks-engine-hkp.c (send_request): Ditto.
22635         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
22636         * dirmngr/ks-engine-ldap.c (ks_ldap_get): Return an error in TOR mode.
22637         (ks_ldap_search): Ditto.
22638         (ks_ldap_put): Ditto.
22639         * dirmngr/ocsp.c (do_ocsp_request): Ditto.  Also pass TOR flag to the
22640         http module.
22641
22642         * dirmngr/server.c (option_handler): Add "honor-keyserver-url-used".
22643         (cmd_dns_cert): Return an error in TOR mode.
22644         (cmd_getinfo): Add subcommand "tor"
22645         * tools/gpgconf-comp.c (gc_options_dirmngr): Add TOR group.
22646
22647         gpg: Report a conflict between honor-keyserver-url and TOR.
22648         + commit d5a3142b8f2e5603357182f34f0b081b47eda23c
22649         * g10/call-dirmngr.c (create_context): Send option and print a verbose
22650         error.
22651
22652         http: Add flag to force use of TOR (part 1)
22653         + commit b4bc1c8b10c7a794fa108678b80f76366a65c47d
22654         * common/http.h (HTTP_FLAG_FORCE_TOR): New.
22655         * common/http.c (http_raw_connect, send_request): Detect flag and
22656         return an error for now.
22657
22658 2015-09-17  NIIBE Yutaka  <gniibe@fsij.org>
22659
22660         po: Update Japanese translation.
22661         + commit f986b23e13eaa2d7705733b4bf6b5210311f181a
22662
22663
22664         scd: Fix ccid-driver timeout for OpenPGPcard v2.1.
22665         + commit 6510df3a7cd2b5bf44fac1e4d50ee54b8c897daa
22666         * scd/ccid-driver.c (CCID_CMD_TIMEOUT): New.
22667         (ccid_transceive_apdu_level, ccid_transceive): Use.
22668
22669 2015-09-16  Werner Koch  <wk@gnupg.org>
22670
22671         agent: New option --pinentry-invisible-char.
22672         + commit 93d257c81952cbb08a744a9cea6749639aa32cd7
22673         * agent/gpg-agent.c (oPinentryInvisibleChar): New.
22674         (opts): Add option.
22675         (parse_rereadable_options): Set option.
22676         * agent/agent.h (opt): Add field pinentry_invisible_char.
22677         * agent/call-pinentry.c (start_pinentry): Pass option to pinentry.
22678
22679         g13: Move some code to a separate module.
22680         + commit 9e65bbd255c43f0e59f35b0003052234d69042be
22681         * g13/g13-common.c, g13/g13-common.h: New.
22682         * g13/Makefile.am (g13_SOURCES): Add new files.
22683         * g13/g13.c (g13_errors_seen): Move to g13-common.c.
22684         (cmdline_conttype): New.
22685         (main): Use g13_init_signals and g13_install_emergency_cleanup.
22686         (emergency_cleanup, g13_exit): Move to g13-common.c.
22687         * g13/g13.h: Move OPT and some other code to g13-common.h.
22688
22689         gpg: Fix skip function dummy parameter.
22690         + commit 8eb3a1797a1e7cb59a8342a8aa917756fe67949f
22691         * g10/trustdb.c (search_skipfnc): Fix dummy argument
22692
22693         gpg: Change last commit to avoid extra translations.
22694         + commit f71ed902def81f9408d9094289d8a97abaa0f609
22695         * g10/keyedit.c (keyedit_menu): Do not print usage hints in expert
22696         mode.
22697
22698 2015-09-16  Neal H. Walfield  <neal@g10code.com>
22699
22700         g10: Improve error message.
22701         + commit 172af881a1cfe82dfec1c43102d6c464e67ef230
22702         * g10/keyedit.c (keyedit_menu): When complaining that a user ID or key
22703         must be selected, indicate what command to use to do this.
22704
22705         g10: Be more careful when merging self-signed data.
22706         + commit 6845737736d3264d7ee8b7364d908951010084c9
22707         * g10/getkey.c (merge_selfsigs_main): Stop looking for self-signed
22708         data belonging to the public key when we encounter an attribute packet
22709         or a subkey packet, not just a user id packet.  When looking for
22710         self-signed data belonging to a user id packet, stop when we see a
22711         user attribute packet.
22712
22713         g10: Simplify some complicated boolean expressions.
22714         + commit c31e089129c0102c1710522d71fbe1880e84d68e
22715         * g10/getkey.c (finish_lookup): Simplify logic.
22716
22717         g10: Also mark revoked and expired keys as unusable.
22718         + commit 77c2ad4a817c129b899708399ed2078a52b452b8
22719         * g10/getkey.c (skip_unusable): Also mark the key as unusable if it
22720         has been revoked or has expired.
22721
22722         g10: Release resources when returning an error in get_seckey.
22723         + commit 1b601de06a57c78537a336093d2531d8c58bc0d2
22724         * g10/getkey.c (get_seckey): If the key doesn't have a secret key,
22725         release *PK.
22726
22727         g10: Improve documentation and comments for getkey.c.
22728         + commit cab581c486e1987445092b1afdf2cba1f62d017d
22729         * g10/getkey.c: Improve documentation and comments for most
22730         functions.  Move documentation for public functions from here...
22731         * g10/keydb.h: ... to here.
22732
22733         g10: Remove unused function have_any_secret_key.
22734         + commit 7333e704efde6923d4b914b37e9a92c4a5bab156
22735         * g10/getkey.c (have_any_secret_key): Remove function.
22736
22737         g10: Bring cache semantics closer to non-cache semantics.
22738         + commit 5e233e12f55be00f5659c63bc32fbdca2ec93136
22739         * g10/getkey.c (get_pubkey_fast): When reading from the cache, only
22740         consider primary keys.
22741
22742         g10: Break out of the loop earlier.
22743         + commit 3940f10af7915b080bf4ed25ceb7e20b52e3cd3e
22744         * g10/getkey.c (have_secret_key_with_kid): Once we find the relevent
22745         key or subkey, stop searching.
22746
22747         g10: Don't skip legacy keys if the search mode is KEYDB_SEARCH_MODE_NEXT
22748         + commit 50affffe93a07643f2610c7a5f3d6f61988855e8
22749         * g10/getkey.c (lookup): Also don't skip legacy keys if the search
22750         mode is KEYDB_SEARCH_MODE_NEXT.
22751
22752         g10: Remove unused function get_seckeyblock_byfprint.
22753         + commit efbaa8f891812e13ae9e689299aa2cd51781ccb3
22754         * g10/keydb.h (get_seckeyblock_byfprint): Remove prototype.
22755         * g10/getkey.c (get_seckeyblock_byfprint): Remove function.
22756
22757         g10: Remove unused function get_seckey_byfprint.
22758         + commit e2b300801ed7143fa924df5442ec2b61079c0bbb
22759         * g10/keydb.h (get_seckey_byfprint): Remove prototype.
22760         * g10/getkey.c (get_seckey_byfprint): Remove function.
22761
22762         g10: Simplify get_seckey_byname: it was never called with NAME not NULL.
22763         + commit 80dbf8006ffe52e77930b0a6dca9d8caba8c3fd5
22764         * g10/keydb.h (get_seckey_byname): Rename from this...
22765         (get_seckey_default): ... to this.  Drop the parameter name.  Update
22766         users.
22767         * g10/getkey.c (get_seckey_byname): Rename from this...
22768         (get_seckey_default): ... to this.  Drop the parameter name.  Drop the
22769         code which assumed that NAME is not NULL.
22770
22771         g10: Eliminate the redundant function get_keyblock_byfprint.
22772         + commit dc69804ab0576fbc87297215d63b37a680d74d4d
22773         * g10/keydb.h (get_keyblock_byfprint): Remove prototype.  Replace use
22774         of this function with get_pubkey_byfprint.
22775         * g10/getkey.c (get_pubkey_byname): Remove function.
22776
22777         g10: Simplify semantics of get_pubkey_byname.
22778         + commit 911fcca36d61afd061e9e6dc0584bb069353db89
22779         * g10/getkey.c (get_pubkey_byname): If R_KEYBLOCK is not NULL, return
22780         the keyblock in R_KEYBLOCK independent of whether PK is set or not.
22781
22782         g10: Eliminate the redundant function get_pubkey_byname.
22783         + commit b4672e4d48fb1e1e4d17551c4c828763d1dfbb57
22784         * g10/getkey.c (get_pubkey_byname): Remove function.
22785         (lookup): Replace use of get_pubkey_byname by get_pubkey_byfprint.
22786
22787         g10: Eliminate the redundant function get_pubkey_end.
22788         + commit 65e58ae6748c280c8633d2ca5f227ebe1220805d
22789         * g10/keydb.h (get_pubkey_end): Remove declaration.  Replace use of
22790         function with getkey_end.
22791         * g10/getkey.c (get_pubkey_byname): Remove function.
22792
22793         g10: Eliminate the redundant function get_pubkey_next.
22794         + commit be6743b2e19241f66148bf89c3442d8e2ebcd63e
22795         * g10/keydb.h (get_pubkey_next): Remove prototype.
22796         * g10/getkey.c (get_pubkey_next): Remove function.
22797         * g10/keylist.c (locate_one): Use getkey_next instead of
22798         get_pubkey_next.
22799
22800         kbx: Change skipfnc's prototype so that we can provide all information.
22801         + commit 9acbeac23668a1d0dabca27d7825430d76e095c2
22802         * kbx/keybox-search-desc.h (struct keydb_search_desc.skipfnc): Change
22803         third parameter to be the index of the user id packet in the keyblock
22804         rather than the packet itself.  Update users.
22805
22806         g10: Remove unused prototype (get_pubkey_byfpr).
22807         + commit 83e17ab1b4cf4420f2abaf9e1f4017a9473fb281
22808         * g10/keydb.h (get_pubkey_byfpr): Remove unused prototype.
22809
22810         g10: Remove unused function (get_pubkey_bynames).
22811         + commit b06f96ba4f57f55194efcd37a0e3a2aa5450b974
22812         * g10/keydb.h (get_pubkey_bynames): Remove prototype.
22813         * g10/getkey.c (get_pubkey_bynames): Remove function.
22814
22815         g10: Simplify code.  Turn struct getkey_ctx_s.found_key into an argument
22816         + commit d47e84946ee010917cfc3501062721b74afbb771
22817         * g10/getkey.c (struct getkey_ctx_s): Remove field found_key.
22818         (lookup): Add argument ret_found_key.  If not NULL, set it to the
22819         found key.  Update callers.
22820         (pk_from_block): Add argument found_key.  Use it instead of
22821         CTX->FOUND_KEY.  Update callers.
22822         (finish_lookup): Return a KBNODE (the found key) instead of an int.
22823         Don't set CTX->FOUND_KEY.  Return the found key instead.
22824
22825         g10: Remove unused field struct getkey_ctx_s.kbpos.
22826         + commit c110e186e07fb1035dc757d322274f939df1c86d
22827         * g10/getkey.c (struct getkey_ctx_s): Remove field kbpos.
22828         (getkey_end): Don't clear CTX->KBPOS.
22829
22830         g10: Simplify code: remove field struct getkey_ctx_s.keyblock.
22831         + commit 3798f73c07f33576bd02ba4a3256c626bd80752f
22832         * g10/getkey.c (struct getkey_ctx_s): Remove field keyblock.
22833         (finish_lookup): Add parameter keyblock.  Update caller to pass this.
22834         (lookup): Add new local variable keyblock.  Use this instead of
22835         ctx->keyblock for referencing the keyblock.
22836
22837 2015-09-16  NIIBE Yutaka  <gniibe@fsij.org>
22838
22839         agent: Fix registering SSH Key of Ed25519.
22840         + commit 7d5999f0964c9412c0e18eb1adefdb729be68cd4
22841         * agent/command-ssh.c (stream_read_string): Add the prefix of 0x40.
22842
22843 2015-09-15  NIIBE Yutaka  <gniibe@fsij.org>
22844
22845         po: Update Japanese translation.
22846         + commit faee25e670cfeb0d0166d7c59cc6a0b3842ee34d
22847
22848
22849 2015-09-10  Werner Koch  <wk@gnupg.org>
22850
22851         Release 2.1.8.
22852         + commit 311816f6cf9d411dba060603e3c5d01c72824645
22853
22854
22855         tests: Silence the 5gb-packet test.
22856         + commit 7a0c3cc760367024305d23e2124ea4cbc7e802df
22857         * tests/openpgp/4gb-packet.test: Send output to /dev/null.
22858
22859         g10: Fix make distcheck problem.
22860         + commit e92a8ab021672b19e5cd397fa555fcc8a3401e8b
22861         * g10/test.c: Include string.h.
22862         (prepend_srcdir): New.  Taken from Libgcrypt.
22863         (test_free): New.
22864         * g10/t-keydb.c (do_test): Malloc the filename.
22865         * g10/Makefile.am (AM_CPPFLAGS): Remove -DSOURCE_DIR
22866         (EXTRA_DIST): Add t-keydb-keyring.kbx.
22867
22868         g10: Improve portability of the new test driver.
22869         + commit fbf24cd09abcdc3dec21db4114ab2db99ce21e4c
22870         * g10/test.c: Include stdio.h and stdlib.h.
22871         (verbose): New.
22872         (print_results): Rename to exit_tests.
22873         (main): Remove atexit and call exit_tests.  Set verbose.
22874         (ASSERT, ABORT): Call exit_tests instead of exit.
22875
22876 2015-09-09  Werner Koch  <wk@gnupg.org>
22877
22878         dirmngr: Allow sending much larger keyblocks.
22879         + commit 19545e3a2d2990cba6d62f98cdb1f665b38ba4f1
22880         * dirmngr/server.c (MAX_CERT_LENGTH): Increase to 16k.
22881         (MAX_KEYBLOCK_LENGTH): Increase to 20M.
22882
22883 2015-09-07  NIIBE Yutaka  <gniibe@fsij.org>
22884
22885         scd: Force key attribute change for writekey.
22886         + commit f10b427d0e2be333776fee2df8150145da36e587
22887         * scd/app-openpgp.c (change_rsa_keyattr): New.
22888         (change_keyattr_from_string): Use change_rsa_keyattr.
22889         (rsa_writekey): Call change_rsa_keyattr when different size.
22890         (ecc_writekey): Try to change key attribute.
22891
22892         scd: KEYNO cleanup.
22893         + commit fd689e85423d0d80d725f0315c52d94f0e9766f8
22894         * scd/app-openpgp.c (get_public_key, send_keypair_info, do_readkey)
22895         (change_keyattr, change_keyattr_from_string, ecc_writekey, do_genkey)
22896         (compare_fingerprint, check_against_given_fingerprint): KEYNO starts
22897         from 0.
22898
22899 2015-09-02  Neal H. Walfield  <neal@g10code.com>
22900
22901         g10: Remove unused field req_algo.
22902         + commit bd0c902f1de46eda03a065da41487e7e01ab4c50
22903         * g10/packet.h (PKT_public_key): Remove unused field req_algo.  Remove
22904         users.
22905         * g10/getkey.c (struct getkey_ctx_s): Remove unused field req_algo.
22906         Remove users.
22907
22908         g10: Use a symbolic constant instead of a literal.
22909         + commit 1f03d4cd940fed26fc3ffa1742728d68c55ee5d1
22910         * g10/trustdb.c (KEY_HASH_TABLE_SIZE): Define.
22911         (new_key_hash_table): Use KEY_HASH_TABLE_SIZE instead of a literal.
22912         (release_key_hash_table): Likewise.
22913         (test_key_hash_table): Likewise.
22914         (add_key_hash_table): Likewise.
22915
22916         g10: Add test for keydb as well as new testing infrastructure.
22917         + commit ee7ec1256b24dc340656c331ef92fc59cad817b6
22918         * g10/Makefile.am (EXTRA_DIST): Add test.c.
22919         (AM_CPPFLAGS): Add -DSOURCE_DIR="\"$(srcdir)\"".
22920         (module_tests): Add t-keydb.
22921         (t_keydb_SOURCES): New variable.
22922         (t_keydb_LDADD): Likewise.
22923         * g10/t-keydb.c: New file.
22924         * g10/t-keydb-keyring.kbx: New file.
22925         * g10/test-stubs.c: New file.
22926         * g10/test.c: New file.
22927
22928         g10: Make the keyblock cache per-handle rather than global.
22929         + commit 60bc518645d3acfd4dcb79e61a2be6ce001e93aa
22930         * g10/keydb.c (keyblock_cache): Don't declare this variable.  Instead...
22931         (struct keyblock_cache): ... turn its type into this first class
22932         object...
22933         (struct keydb_handle): ... and instantiate it once per database
22934         handle.  Update all users.
22935         (keydb_rebuild_caches): Don't invalidate the keyblock cache.
22936
22937         g10: If iobuf_seek fails when reading from the cache, do a hard read.
22938         + commit f076fa190e09eab5c586650d81e241e0bb85ce25
22939         * g10/keydb.c (keydb_get_keyblock): If the iobuf_seek fails when
22940         reading from the cache, then simply clear the cache and try reading
22941         from the database.
22942
22943         iobuf: Reduce verbosity of test.
22944         + commit 219de84df9a8408fffedbb2600f5eb4c441950b6
22945         * common/t-iobuf.c (main): Reduce verbosity.
22946
22947         iobuf: Add the IOBUF_INPUT_TEMP type to improve input temp handling.
22948         + commit f2d75ac7dc58f5ea59b231be6b83fea939b43ab8
22949         * common/iobuf.h (enum iobuf_use): Add new member, IOBUF_INPUT_TEMP.
22950         * common/iobuf.c (iobuf_temp_with_content): Create the iobuf as an
22951         IOBUF_INPUT_TEMP, not an IOBUF_INPUT buffer.  Assert that LENGTH ==
22952         A->D.SIZE.
22953         (iobuf_push_filter2): If A is an IOBUF_INPUT_TEMP, then make the new
22954         filter an IOBUF_INPUT filter and set its buffer size to
22955         IOBUF_BUFFER_SIZE.
22956         (underflow): If A is an IOBUF_INPUT_TEMP, then just return EOF; don't
22957         remove already read data.
22958         (iobuf_seek): If A is an IOBUF_INPUT_TEMP, don't discard the buffered
22959         data.
22960         (iobuf_alloc): Allow USE == IOBUF_INPUT_TEMP.
22961         (pop_filter): Allow USE == IOBUF_INPUT_TEMP.
22962         (iobuf_peek): Allow USE == IOBUF_INPUT_TEMP.
22963         (iobuf_writebyte): Fail if USE == IOBUF_INPUT_TEMP.
22964         (iobuf_write): Fail if USE == IOBUF_INPUT_TEMP.
22965         (iobuf_writestr): Fail if USE == IOBUF_INPUT_TEMP.
22966         (iobuf_flush_temp): Fail if USE == IOBUF_INPUT_TEMP.
22967
22968         iobuf: Rename IOBUF_TEMP to IOBUF_OUTPUT_TEMP.
22969         + commit 5ff5e72b9c275fbd978136b1028bbf251af26e57
22970         * common/iobuf.h (enum iobuf_use): Rename IOBUF_TEMP to
22971         IOBUF_OUTPUT_TEMP.  Update users.
22972
22973         iobuf: Use a first-class enum.
22974         + commit 24259d856b6cbdd679035512a8fb7c042de8f02e
22975         * common/iobuf.h (enum iobuf_use): Name the IOBUF_OUTPUT, etc. enum.
22976         (struct iobuf_struct): Change the field use's type to it.
22977
22978         iobuf: Fix test.
22979         + commit 8522cdc2264804d0677b7c0a447a0b45cf4195e3
22980         * common/t-iobuf.c (content_filter): If there is nothing to read,
22981         don't forget to set *LEN to 0.
22982         (main): Fix checks.
22983
22984 2015-09-01  Werner Koch  <wk@gnupg.org>
22985
22986         agent: Protect commit 135b1e3 against misbehaving Libgcrypt.
22987         + commit 9ba4ccdaf5e128fbea51ff142c63d4b359c7264d
22988         * agent/command-ssh.c (ssh_key_to_blob): Check DATALEN.
22989
22990         gpg: Remove option --no-sig-create-check.
22991         + commit f9c83d84e7d33df76898975f5ac852efa9c4882a
22992         * g10/gpg.c (opts): Remove --no-sig-create-check.
22993         * g10/options.h (struct opt): Remove field no_sig_create_check.
22994         * g10/sign.c (do_sign): Always check unless it is RSA and we are using
22995         Libgcrypt 1.7.
22996
22997         common: Assume an utf-8 locale on iconv errors.
22998         + commit 99c9bf7defd6c1ac9cc49c84e6c78eeb886a6952
22999         * common/utf8conv.c (handle_iconv_error): Use utf-8 as fallback.
23000
23001         common: Fix regression in building argpase.c standalone.
23002         + commit bc23e69b70191f887dcb937007833d0187af181f
23003         * common/argparse.c (is_native_utf8) [GNUPG_MAJOR_VERSION]: New.
23004
23005 2015-08-31  Neal H. Walfield  <neal@g10code.com>
23006
23007         g10: Don't leak memory if we fail to initialize a new database handle.
23008         + commit 04a6b903d0354be2c69c7f2c98987de17d68416e
23009         * g10/keydb.c (keydb_new): If we fail to open a keyring or keybox
23010         correctly release all resources.
23011
23012         g10: Improve interface documentation of the keydb API.
23013         + commit 360b699e9b4b8f99bd790b3cd158cd6f0fd7c131
23014         * g10/keydb.c: Improve code comments and documentation of internal
23015         interfaces.  Improve documentation of public APIs and move that to...
23016         * g10/keydb.h: ... this file.
23017
23018         g10: Don't cache search results if the search didn't scan the whole DB.
23019         + commit efd1ead9e779eb3bd37384258e08ad921a934612
23020         * g10/keydb.c (struct keydb_handle): Add new field is_reset.
23021         (keydb_new): Initialize hd->is_reset to 1.
23022         (keydb_locate_writable): Set hd->is_reset to 1.
23023         (keydb_search): Set hd->is_reset to 0.  Don't cache a key not found if
23024         the search started from the beginning of the database.
23025
23026         g10: Have keydb_search_first call keydb_search_reset before searching.
23027         + commit 11d8ffc939a4d20cfb0082b2d966b1e1a7d61f8d
23028         * g10/keydb.c (keydb_search_first): Reset the handle before starting
23029         the search.
23030
23031         g10: Remove unused parameter.
23032         + commit 0377db4b3581561b1ffc5bb7c3b4d698e8993b3a
23033         * g10/keydb.h (keydb_locate_writable): Remove unused parameter
23034         reserved.  Update users.
23035
23036 2015-08-31  NIIBE Yutaka  <gniibe@fsij.org>
23037
23038         agent: Fix SSH public key for EdDSA.
23039         + commit 135b1e32f01beaceba8a4ecc774e23b56aca1d24
23040         * agent/command-ssh.c (ssh_key_to_blob): Remove the prefix 0x40.
23041
23042 2015-08-26  Neal H. Walfield  <neal@g10code.com>
23043
23044         g10: Simplify cache.  Only include data that is actually used.
23045         + commit fad91071cadff43d77ce2e524dfb03999ba6678e
23046         * g10/keydb.c (struct kid_list_s): Rename from this...
23047         (struct kid_not_found_cache_bucket): ... to this.  Update users.
23048         Remove field state.
23049         (kid_list_t): Remove type.
23050         (KID_NOT_FOUND_CACHE_BUCKETS): Define.  Use this instead of a literal.
23051         (kid_found_table): Rename from this...
23052         (kid_not_found_cache_bucket): ... to this.  Update users.
23053         (kid_found_table_count): Rename from this...
23054         (kid_not_found_cache_count): ... to this.  Update users.
23055         (kid_not_found_p): Only return whether a key with the specified key id
23056         is definitely not in the database.
23057         (kid_not_found_insert): Remove parameter found.  Update callers.
23058         (keydb_search): Only insert a key id in the not found cache if it is
23059         not found.  Rename local variable once_found to already_in_cache.
23060
23061 2015-08-25  Werner Koch  <wk@gnupg.org>
23062
23063         Add configure option --enable-build-timestamp.
23064         + commit 9d07f6930aaa40dce92104e8c99241713d92eed2
23065         * configure.ac (BUILD_TIMESTAMP): Set to "<none>" by default.
23066
23067         gpg: Emit ERROR status for key signing failures.
23068         + commit 51b9b8fba4ee326013c2cc911c70cde4c5f81fc7
23069         * g10/keyedit.c (sign_uids): Write an ERROR status for a signing
23070         failure.
23071         (menu_adduid, menu_addrevoker, menu_revsig): Ditto.
23072         (menu_revuid, menu_revkey, menu_revsubkey): Ditto.
23073
23074         gpg: Print a new FAILURE status after most commands.
23075         + commit 9cdff09743c473a12359bfdb914578ede0e4e3e2
23076         * common/status.h (STATUS_FAILURE): New.
23077         * g10/cpr.c (write_status_failure): New.
23078         * g10/gpg.c (main): Call write_status_failure for all commands which
23079         print an error message here.
23080         * g10/call-agent.c (start_agent): Print an STATUS_ERROR if we can't
23081         set the pinentry mode.
23082
23083 2015-08-24  Neal H. Walfield  <neal@g10code.com>
23084
23085         agent: Raise the maximum password length.  Don't hard code it.
23086         + commit 348a6ebb63523305ce9f47d0f3e8a9086c338fed
23087         * agent/agent.h (MAX_PASSPHRASE_LEN): Define.
23088         * agent/command-ssh.c (ssh_identity_register): Use it instead of a
23089         hard-coded literal.
23090         * agent/cvt-openpgp.c (convert_from_openpgp_main): Likewise.
23091         * agent/findkey.c (unprotect): Likewise.
23092         * agent/genkey.c (agent_ask_new_passphrase): Likewise.
23093
23094 2015-08-24  Werner Koch  <wk@gnupg.org>
23095
23096         sm: Support secret key export via the Assuan interface.
23097         + commit 3cf02192a890d04f8f558cb72d46f9bd7a378322
23098         * sm/server.c (cmd_export): Add options --secret, --raw, and --pkcs12.
23099
23100 2015-08-23  Werner Koch  <wk@gnupg.org>
23101
23102         dirmngr: Allow sending of Zack's key.
23103         + commit 84f4c8811fc5bdd78693c4dc289389a8337cc257
23104         * dirmngr/server.c (MAX_KEYBLOCK_LENGTH): Increase to 1 MiB.
23105
23106         gpg: Fix regression in packet parser from Aug 19.
23107         + commit 88317ae8c829bfeb1689415efbd32b7a232d7bd0
23108         * g10/parse-packet.c (parse): Use an int to compare to -1.  Use
23109         buf32_to_ulong.
23110
23111         gpg: Show not found keys with --locate-key --verbose.
23112         + commit 00def10d365a88ce2d034ea9a5d6be4b03285fa4
23113         * g10/keylist.c (locate_one): Print a diagnostic for a not-found key.
23114
23115 2015-08-21  Neal H. Walfield  <neal@g10code.com>
23116
23117         common: Don't incorrectly reject 4 GB - 1 sized packets.
23118         + commit 09f2a7bca624d0492e1d7ab29ce19542249c13ff
23119         * g10/parse-packet.c (parse): Don't reject 4 GB - 1 sized packets.
23120         Add the constraint that the type must be 63.
23121         * kbx/keybox-openpgp.c (next_packet): Likewise.
23122         * tests/openpgp/4gb-packet.asc: New file.
23123         * tests/openpgp/4gb-packet.test: New file.
23124         * tests/openpgp/Makefile.am (TESTS): Add 4gb-packet.test.
23125         (TEST_FILES): Add 4gb-packet.asc.
23126
23127         common: Don't assume on-disk layout matches in-memory layout.
23128         + commit 4f37820334fadd8c5036ea6c42f3dc242665c4a9
23129         * g10/packet.h (PKT_signature): Change revkey's type from a struct
23130         revocation_key ** to a struct revocation_key *.  Update users.
23131
23132         common: Don't incorrectly copy packets with partial lengths.
23133         + commit b3226cadf9bbef4a367072396e5b0abf37afff2d
23134         * g10/parse-packet.c (parse): We don't handle copying packets with a
23135         partial body length to an output stream.  If this occurs, log an error
23136         and abort.
23137
23138         common: Check parameters more rigorously.
23139         + commit 0143d5c1ca4d12ac252c14f01931f48131591065
23140         * g10/parse-packet.c (dbg_copy_all_packets): Check that OUT is not
23141         NULL.
23142         (copy_all_packets): Likewise.
23143
23144         common: Don't continuing processing on error.
23145         + commit 48e792cc951a9d00fad0691ef7411c9e22cf675a
23146         * g10/parse-packet.c (dbg_parse_packet): Also return if parse returns
23147         an error.
23148         (parse_packet): Likewise.
23149         (dbg_search_packet): Likewise.
23150         (search_packet): Likewise.
23151
23152         common: Better respect the packet's length when reading it.
23153         + commit 73af66a0aada8f30d8f400fdc4f69e233fb53089
23154         * g10/parse-packet.c (parse_signature): Make sure PKTLEN doesn't
23155         underflow.  Be more careful that a read doesn't read more data than
23156         PKTLEN says is available.
23157
23158 2015-08-20  Werner Koch  <wk@gnupg.org>
23159
23160         po: Add lost translation of validity strings.
23161         + commit 0d5a4138f27187e7828ef8216758edc9b48b2c64
23162         * po/POTFILES.in (trust.c): Add missing file.
23163         * po/de.po: Changed German validity strings.
23164         * doc/help.de.txt: Ditto.
23165
23166 2015-08-20  Neal H. Walfield  <neal@g10code.com>
23167
23168         g10/parse-packet.c:parse: Try harder to not ignore an EOF.
23169         + commit 0add91ae1ca3718e8140af09294c595f47c958d3
23170         * g10/parse-packet.c (parse): Be more robust: make sure to process any
23171         EOF.
23172
23173         g10/parse-packet.c: Replace literal with symbolic expression.
23174         + commit 24a72dffa75a04611c98343140c4eb0fbfe2a59f
23175         * g10/parse-packet.c (dump_hex_line): Use sizeof rather than the
23176         buffer's size.
23177
23178         Add documentation for g10/parse-packet.c.
23179         + commit 026feff4a8e3090fb152af72c73aaa80c78e4551
23180         * g10/packet.h: Add documentation for functions defined in
23181         parse-packet.c.
23182         * g10/parse-packet.c: Improve comments for many functions.
23183
23184         g10/packet.h: Remove unused argument from enum_sig_subpkt.
23185         + commit c46e8bfe9a1ae3f1e5327d0451cffd6e4567b449
23186         * g10/packet.h (enum_sig_subpkt): Remove argument RET_N.  Update
23187         callers.
23188         * g10/parse-packet.c (enum_sig_subpkt): Remove argument RET_N.
23189
23190         g10/parse-packet.c:mpi_read: Detect EOF and correct boundary conditions.
23191         + commit c271feb53664dbf2b4ccbae90a31b8e726481e2d
23192         * g10/parse-packet.c (mpi_read): Improve documentation.  Correctly
23193         handle an EOF.  On overflow, correctly return the number of bytes read
23194         from the pipeline.
23195
23196         common/iobuf.c: Make control flow more obvious.
23197         + commit 49f922286fa8adb2d2ca730eb7bbe67e684b20de
23198         * common/iobuf.c (iobuf_read): Make control flow more obvious.
23199         (iobuf_get_filelength): Likewise.
23200         (iobuf_get_fd): Likewise.
23201         (iobuf_seek): Likewise.
23202
23203         common/iobuf.c: Add some sanity checks to catch programmer bugs.
23204         + commit c5da750cf3d53277fe6d86776bfe0d2304b05151
23205         * common/iobuf.c (iobuf_alloc): Check that BUFSIZE is not 0.
23206         (iobuf_readbyte): Check that A is an input filter.  Check that the
23207         amount of read data is at most the amount of buffered data.
23208         (iobuf_read): Check that A is an input filter.
23209         (iobuf_writebyte): Check that A is not an input filter.
23210         (iobuf_writestr): Check that A is not an input filter.
23211         (iobuf_flush_temp): Check that A is not an input filter.
23212
23213         common/iobuf.c:iobuf_write_temp: Elide redundant code.
23214         + commit e291b631c3b1aedf529078190cd51e2acfcd1d92
23215         * common/iobuf.c (iobuf_write_temp): Don't repeat iobuf_flush_temp.
23216         Use it directly.
23217
23218         common/iobuf.c: Have iobuf_writestr use iobuf_write, not iobuf_writebyte
23219         + commit a6d4bca3b576c3c5dba1aa6e8c1039089e14147b
23220         * common/iobuf.c (iobuf_write): Don't write a byte at a time.  Use
23221         iobuf_write.
23222
23223         common/iobuf: Improve documentation and code comments.
23224         + commit 1bfd1e43246c16e20f819bf5381ca21abde54458
23225         common/iobuf.h: Improve documentation and code comments.
23226         common/iobuf.c: Likewise.
23227
23228         common/iobuf.c: Adjust buffer size of filters in front of temp filters.
23229         + commit 0d40c4e83f6fbfea2f494f1f88412d3132ff98bd
23230         * common/iobuf.c (iobuf_push_filter2): If the head filter is a temp
23231         filter, use IOBUF_BUFFER_SIZE for the new filter.
23232
23233         common/iobuf.c: Buffered data should not be processed by new filters.
23234         + commit 827cc922d84d8113d4f13ebbed1314e03da5f7d2
23235         * common/iobuf.c (iobuf_push_filter2): If the pipeline is an output or
23236         temp pipeline, the new filter shouldn't assume ownership of the old
23237         head's internal buffer: the data was written before the filter was
23238         added.
23239         * common/t-iobuf.c (double_filter): New function.
23240         (main): Add test cases for the above bug.
23241
23242         common/iobuf.c: Flush the pipeline in iobuf_temp_to_buffer.
23243         + commit 616181f3c757160af8539869a6d929faca4962c4
23244         * common/iobuf.c (iobuf_temp_to_buffer): Flush each filter in the
23245         pipeline and copy the data from the last (not the first) filter's
23246         internal buffer.
23247
23248         common/iobuf.c: Combine iobuf_open, iobuf_create and iobuf_openrw.
23249         + commit 15ae99f887f4694de8468625d455d487d283f719
23250         * common/iobuf.c (do_open): New function, which is a generalization of
23251         iobuf_open, iobuf_Create, iobuf_openrw.
23252         (iobuf_open): Call do_open.
23253         (iobuf_create): Likewise.
23254         (iobuf_openrw): Likewise.
23255
23256         common/iobuf.h: Remove iobuf_open_fd_or_name.
23257         + commit 8402815d8e0e04a44362968f88b3d484d2395402
23258         * common/iobuf.h (iobuf_open_fd_or_name): Remove prototype.  Replace
23259         use with either iobuf_open or iobuf_fdopen_nc, as appropriate.
23260         * common/iobuf.c (iobuf_open): Remove function.
23261
23262         common/iobuf.c: Rename iobuf_flush and make it a static function.
23263         + commit 6d49a2b6691f2dd0d8ac34a15f18cc2a0c3ba5d3
23264         * common/iobuf.h (iobuf_flush): Remove prototype.
23265         * common/iobuf.c (filter_flush): New static prototype.
23266         (iobuf_flush): Rename...
23267         (filter_flush): ... to this.  Make static.  Simplify code.  Update
23268         callers.
23269
23270         common/iobuf.c: Don't abort freeing a pipeline if freeing a filter fails
23271         + commit 1f94646a86348128f585301fcd605e5e703fd77d
23272         * common/iobuf.c (iobuf_cancel): Don't abort freeing a pipeline if
23273         freeing a filter fails.  This needs to a memory leak.  Instead, keep
23274         freeing and return the error code of the first filter that fails.
23275
23276         common/iobuf.c: Improve iobuf_peek.
23277         + commit a250f73783c06d7789ac65a395d9247f4ab44c26
23278         * common/iobuf.c (underflow): Take additional parameter
23279         clear_pending_eof.  If not set, don't clear a pending eof when
23280         returning EOF.  Update callers.
23281         (iobuf_peek): Fill the internal buffer, if needed, to be able to
23282         better satisfy any request.
23283
23284         common/iobuf.c: When requested, fill the buffer even if it is not empty.
23285         + commit c7ad36eb0d7f872fc15e793aa1d0b6b89bc471d6
23286         * common/iobuf.c (underflow): Don't require that the buffer be empty.
23287         When called, fill any available space.
23288
23289         common/t-iobuf.c: Add a test case for multiple EOFs.
23290         + commit e76c75d8726558dc9084710253f0f6780e06fad3
23291         common/t-iobuf.c (main): Add a test case for multiple EOFs in an INPUT
23292         pipeline.
23293
23294         common/iobuf.c: Better respect boundary conditions in iobuf_read_line.
23295         + commit 4e32c602f5c40cca5f8f40e642ccb10d3f8c5614
23296         * common/iobuf.c (iobuf_read_line): Be more careful with boundary
23297         conditions.
23298         * common/iobuf.h: Include <gpg-error.h>.
23299         * common/t-iobuf.c: New file.
23300         * common/Makefile.am (module_tests): Add t-iobuf.
23301         (t_mbox_util_LDADD): New variable.
23302
23303         common/iobuf.c: Fix filter type for iobuf_temp_with_content.
23304         + commit fa9fda23c2c8cf6982b7263f6882ed8687d98c16
23305         * common/iobuf.c (iobuf_temp_with_content): Set the filter type to
23306         IOBUF_INPUT, not IOBUF_TEMP, which is only for output filters that
23307         write into a dynamic buffer.
23308
23309         common/iobuf.h: Remove unimplemented prototypes.
23310         + commit 75fd86bbd175e085a93c1ad62f50ae936494b307
23311         * common/iobuf.h (iobuf_unread): Remove unimplemented prototype.
23312         (iobuf_clear_eof): Likewise.
23313         (iobuf_append): Likewise.
23314
23315         common/iobuf.c: Refactor code to not need the desc field.
23316         + commit 679acc671e621847f50d6b4dca10a22c62500b9a
23317         * common/iobuf.h (struct iobuf_struct): Remove field desc.
23318         * common/iobuf.c (iobuf_desc): New function.  When a filter's
23319         description is needed, use this instead of the filter's desc field.
23320
23321         common/iobuf.h: Clarify semantics of nofast.  Simplify implementation.
23322         + commit 12fc56bcb51d984a6e86fc1eb7952f9976c67043
23323         * common/iobuf.h (struct iobuf_struct): Clarify semantics of nofast.
23324         Simplify use of nofast to implement just these semantics.
23325
23326         common/iobuf.c: Remove dead code (directfp).
23327         + commit e8c0b6abf88309c23a70df0abbd38d42fa22a786
23328         * common/iobuf.h (struct iobuf_struct): Remove field directfp.  Remove
23329         all uses of it.
23330
23331         common/iobuf.c: Remove dead code (opaque).
23332         + commit f05d60b3813a97e316a067680d7598b74621a522
23333         * common/iobuf.h (struct iobuf_struct): Remove field opaque.  Remove
23334         all uses of it.
23335
23336         common/iobuf.h: Replace further use of literals with symbolic constants.
23337         + commit c06eabac8e85f7f79414363836f093415e8da62e
23338         * common/iobuf.c: Move BLOCK_FILTER_INPUT,
23339         BLOCK_FILTER_OUTPUT_BLOCK_FILTER_TEMP from here...
23340         * common/iobuf.h: ... to here and rename to IOBUF_INPUT, IOBUF_OUTPUT
23341         and IOBUF_TEMP, respectively.  Where appropriate, use these macros
23342         instead of a literal.
23343
23344 2015-08-17  Werner Koch  <wk@gnupg.org>
23345
23346         gpg: Avoid linking to Libksba.
23347         + commit 91357b7722f2bf0d3765ec72855bdc96732df9d6
23348         * kbx/keybox.h (KEYBOX_WITH_X509): Do not define.
23349         * sm/Makefile.am (AM_CPPFLAGS): Define it here.
23350         (common_libs): Change to libkeybox509.a
23351         * g10/Makefile.am (AM_CFLAGS): remove KSBA_CFLAGS.
23352         (gpg2_LDADD, gpgv2_LDADD): Remove KSBA_LIBS
23353         * kbx/Makefile.am (noinst_LIBRARIES): Add libkeybox509.a.
23354         (libkeybox509_a_SOURCES): New.
23355         (libkeybox_a_CFLAGS): New.
23356         (libkeybox509_a_CFLAGS): New.
23357         (kbxutil_CFLAGS): New.
23358         * kbx/keybox-search.c (has_keygrip) [!KEYBOX_WITH_X509]: Declare args
23359         as unused.
23360
23361 2015-08-16  Ben Kibbey  <bjk@luxsci.net>
23362
23363         Fix pinentry loopback and passphrase contraints.
23364         + commit bba74cdd95ea98b5a7c3a12823b229341e91504e
23365         * agent/command.c (cmd_get_passphrase): Don't repeat passphrase for
23366         pinentry loopback mode.
23367         * agent/genkey.c (check_passphrase_constraints): Immediately return when
23368         pinentry mode is loopback.
23369
23370         Fix sending INQUIRE_MAXLEN for symmetric data.
23371         + commit 93f5295df512269dd8fecbd649b11cbacf78e864
23372         * g10/passphrase.c (passphrase_to_dek_ext): Write the status message.
23373
23374 2015-08-15  Ben Kibbey  <bjk@luxsci.net>
23375
23376         Inform a user about inquire length limit.
23377         + commit f126ca61565922b3b938c3486614b9bd7e6e454c
23378         * common/status.h (INQUIRE_MAXLEN): New.
23379         * g10/call-agent.c (default_inquire_cb): Send STATUS_INQUIRE_MAXLEN.
23380         client when inquiring a passphrase over pinentry-loopback.
23381
23382         Allow --gen-key to inquire a passphrase.
23383         + commit 233b5fedabd80a34452e748132e65b5944310428
23384         * g10/gpg.c (main): test for --command-fd during --gen-key parse.
23385
23386         When --command-fd is set then imply --batch to let gpg inquire a
23387         passphrase rather than requiring a pinentry.
23388
23389 2015-08-11  Werner Koch  <wk@gnupg.org>
23390
23391         Release 2.1.7.
23392         + commit b5e081973b56b21214fc0c65ba9015dd026328b4
23393
23394
23395 2015-08-10  NIIBE Yutaka  <gniibe@fsij.org>
23396
23397         agent: fix ECC key handling.
23398         + commit 8704c70108218a60f8fb2ee0e558ca8ed125600d
23399         * agent/cvt-openpgp.c (get_keygrip, convert_secret_key)
23400         (convert_transfer_key): CURVE is the name of curve.
23401
23402 2015-08-08  Neal H. Walfield  <neal@g10code.com>
23403
23404         common/iobuf.c: Replace use of literals with symbolic constants.
23405         + commit c80643c5ecbee89f343ef087313870cee1334fe4
23406         * common/iobuf.c (BLOCK_FILTER_INPUT): Define.  Where appropriate, use
23407         this instead of a literal.
23408         (BLOCK_FILTER_OUTPUT): Likewise.
23409         (BLOCK_FILTER_TEMP): Likewise.
23410
23411 2015-08-07  Werner Koch  <wk@gnupg.org>
23412
23413         gpg: Allow gpgv to work with a trustedkeys.kbx file.
23414         + commit 5b7a80b1ab91d2f199065e5dd14e85f42918975d
23415         * g10/keydb.h (KEYDB_RESOURCE_FLAG_GPGVDEF): New.
23416         * g10/keydb.c (keydb_add_resource): Take care of new flag.
23417         * g10/gpgv.c (main): Use new flag.
23418
23419         agent: Add option --force to the DELETE_KEY command.
23420         + commit a68c5c5c7fe4ec8665e252e5062292f6c7b94fdd
23421         * agent/findkey.c (agent_delete_key): Add arg "force".
23422         * agent/command.c (cmd_delete_key): Add option --force.
23423
23424         common: Change alias for Curve25519 to "cv25519".
23425         + commit 9f31ab3d216ed74d6f392a62e3f95e0591174119
23426         * common/openpgp-oid.c (oidtable): Change alias.
23427
23428 2015-08-06  Werner Koch  <wk@gnupg.org>
23429
23430         gpg: Remove duplicated printing of the curve name in "sub" lines.
23431         + commit fb754dc6170d12edf3d35c48340b8d7b1ded20f7
23432         * g10/keylist.c (list_keyblock_print): Do not print extra curve name.
23433
23434         gpg: Add commands "fpr *" and "grip" to --edit-key.
23435         + commit fbb6c25ab5dbb5f2b1f1eb342ca7caa3f955d8c9
23436         * g10/keyedit.c (cmdGRIP): New.
23437         (cmds): Add command "grip".
23438         (keyedit_menu) <cmdFPR>: Print subkeys with argument "*".
23439         (keyedit_menu) <cmdGRIP>: Print keygrip.
23440         (show_key_and_fingerprint): Add arg "with_subkeys".
23441         (show_key_and_grip): New.
23442         * g10/keylist.c (print_fingerprint): Add mode 4.
23443
23444         gpg: Adjust UID line indentation for common key algos.
23445         + commit 969542c8c2f48a60c1d68b7bf70b0c00374bacba
23446         * g10/keylist.c (list_keyblock_print): Change UID line indentation
23447         * g10/mainproc.c (list_node): Ditto.
23448
23449 2015-08-06  NIIBE Yutaka  <gniibe@fsij.org>
23450
23451         Curve25519 support.
23452         + commit e5891a82c39997b65ce9ff90eb6120db7bedd399
23453         * agent/cvt-openpgp.c (get_keygrip): Handle Curve25519.
23454         (convert_secret_key, convert_transfer_key): Ditto.
23455         * common/openpgp-oid.c (oidtable): Add Curve25519.
23456         (oid_crv25519, openpgp_oid_is_crv25519): New.
23457         * common/util.h (openpgp_oid_is_crv25519): New.
23458         * g10/ecdh.c (pk_ecdh_encrypt_with_shared_point): Handle the case
23459         with Montgomery curve which uses x-only coordinate.
23460         * g10/keygen.c (gen_ecc): Handle Curve25519.
23461         (ask_curve): Change the API and second arg is to return subkey algo.
23462         (generate_keypair, generate_subkeypair): Follow chage of ask_curve.
23463         * g10/keyid.c (keygrip_from_pk): Handle Curve25519.
23464         * g10/pkglue.c (pk_encrypt): Handle Curve25519.
23465         * g10/pubkey-enc.c (get_it): Handle the case with Montgomery curve.
23466         * scd/app-openpgp.c (ECC_FLAG_DJB_TWEAK): New.
23467         (send_key_attr): Work with general ECC, Ed25519, and Curve25519.
23468         (get_public_key): Likewise.
23469         (ecc_writekey): Handle flag_djb_tweak.
23470
23471         common: extend API of openpgp_oid_to_curve for canonical name.
23472         + commit a6e40530898622fbc5d76557a7da5e69368ecaa4
23473         * common/openpgp-oid.c (openpgp_oid_to_curve): Add CANON argument.
23474         * common/util.h: Update.
23475         * g10/import.c (transfer_secret_keys): Follow the change.
23476         * g10/keyid.c (pubkey_string): Likewise.
23477         * g10/keylist.c (list_keyblock_print, list_keyblock_colon): Likewise.
23478         * parse-packet.c (parse_key): Likewise.
23479         * scd/app-openpgp.c (send_key_attr, get_public_key): Likewise.
23480
23481 2015-08-05  NIIBE Yutaka  <gniibe@fsij.org>
23482
23483         scd: Fix ecc_oid.
23484         + commit d088d2c81690a89051349ddc8a82fe222625f4e0
23485         * scd/app-openpgp.c (ecc_oid): Call with OIDBUF.
23486
23487         scd: Fix ECC support.
23488         + commit 0751571cac0f5aef2862c34a184f7f09ad9cb203
23489         * scd/app-openpgp.c (send_key_attr): Send KEYNO.
23490         (get_public_key): Fix SEXP composing.
23491         (ecc_writekey): Fix OID length calculation.
23492         (ecc_oid): Prepend the length before query.
23493         (parse_algorithm_attribute): Handle the case the curve is not available.
23494
23495 2015-08-04  Werner Koch  <wk@gnupg.org>
23496
23497         gpg: Fix duplicate key import due to legacy key in keyring.
23498         + commit 4a326d7c9a3b09efcccf4de00d6c003829ad89e8
23499         * g10/keydb.c (keydb_search_fpr): Skip legacy keys.
23500
23501         gpg: Properly handle legacy keys while looking for a secret key.
23502         + commit f05a63b10428df2878b1bb6fde57a2fc2aa99105
23503         * g10/getkey.c (have_secret_key_with_kid): Skip legacy keys.
23504
23505 2015-07-31  Werner Koch  <wk@gnupg.org>
23506
23507         gpg: Fix endless loop for expired keys given by fpr.
23508         + commit 328a6b6459a5ce4a70b374262f221ada20c40878
23509         * g10/getkey.c (lookup): Disable keydb caching when continuing a
23510         search.
23511
23512 2015-07-29  Werner Koch  <wk@gnupg.org>
23513
23514         gpg: Do not return "Legacy Key" from lookup if a key is expired.
23515         + commit 23d8609f4b5ec3432323a676fd7ef225c0ef71a1
23516         * g10/getkey.c (lookup): Map GPG_ERR_LEGACY_KEY.
23517
23518         gpg: Indicate secret keys and cards in a key-edit listing.
23519         + commit 8b2b988309cbc5af339beb0a55ff71d7464eb646
23520         * g10/keyedit.c (sign_uids): Add arg "ctrl".
23521         (show_key_with_all_names_colon): Ditto.
23522         (show_key_with_all_names): Ditto.
23523
23524         * g10/keyedit.c (show_key_with_all_names): Print key record
23525         indicators by checking with gpg-agent.
23526         (show_key_with_all_names): Ditto.  May now also print sec/sbb.
23527
23528 2015-07-28  Werner Koch  <wk@gnupg.org>
23529
23530         gpg: Remove the edit-key toggle command.
23531         + commit 7ef09afd1a6a37c7f22e7c3d898f0c917b08f940
23532         * g10/keyedit.c (cmds): Remove helptext from "toggle".
23533         (keyedit_menu): Remove "toggle" var and remove the sub/pub check
23534         against toggle.
23535
23536         common,w32: Avoid unused var warning about msgcache.
23537         + commit 4bc75337f31374b7424d7bdebf839dd91ec80c0a
23538         * common/i18n.c (USE_MSGCACHE): New.
23539         (msgcache) [!USE_MSGCACHE]: Do not define.
23540         (i18n_localegettext): Repalce #if conditions by USE_MSGCACHE.
23541
23542         w32: Try more places to find an installed Pinentry.
23543         + commit 18f1e627c697d75175b79fe095305fa775f20841
23544         * common/homedir.c (get_default_pinentry_name): Re-implement to
23545         support several choices for Windows.
23546
23547 2015-07-26  Werner Koch  <wk@gnupg.org>
23548
23549         scd: Fix size_t/unsigned int mismatch.
23550         + commit 55e64f47a52d76e097a01eb4044a88a4e10d6a87
23551         * scd/app-openpgp.c (ecc_writekey): Use extra var n.
23552
23553         Replace GNUPG_GCC_A_ macros by GPGRT_ATTR_ macros.
23554         + commit d382242fb6789973ce8d246ec154a4a1468c24c0
23555         * common/util.h: Provide replacement for GPGRT_ATTR_ macros when using
23556         libgpg-error < 1.20.
23557         * common/mischelp.h: Ditto.
23558         * common/types.h: Ditto.
23559
23560 2015-07-25  NIIBE Yutaka  <gniibe@fsij.org>
23561
23562         scd: support any curves defined by libgcrypt.
23563         + commit ef080d5c7fb7f3b75c3c57c011f78a312b8e13a9
23564         * g10/call-agent.h (struct agent_card_info_s): Add curve field.
23565         * g10/call-agent.c (learn_status_cb): Use curve name.
23566         * g10/card-util.c (card_status): Show pubkey name.
23567         * scd/app-openpgp.c (struct app_local_s): Record OID and flags.
23568         (store_fpr): Use ALGO instead of key type.
23569         (send_key_attr): Use curve name instead of OID.
23570         (get_public_key): Clean up by OID to curve name.
23571         (ecc_writekey): Support any curves in libgcrypt.
23572         (do_genkey, do_auth, ): Follow the change.
23573         (ecc_oid): New.
23574         (parse_algorithm_attribute): Show OID here.
23575
23576 2015-07-23  Peter Wu  <peter@lekensteyn.nl>
23577
23578         build: ignore scissor line for the commit-msg hook.
23579         + commit d24165bce2823c2f5dcb39b7b84c9aa00802a8ee
23580         * build-aux/git-hooks/commit-msg: Stop processing more lines when the
23581           scissor line is encountered.
23582
23583 2015-07-23  NIIBE Yutaka  <gniibe@fsij.org>
23584
23585         scd: Format change to specify "rsa2048" for KEY-ATTR.
23586         + commit dbf4534f49a1fe3823bd6d6d7bb4d9df863b4789
23587         * g10/card-util.c (do_change_keysize): Put "rsa".
23588         * scd/app-openpgp.c (change_keyattr, change_keyattr_from_string):
23589         Change the command format.
23590         (rsa_writekey): Check key type.
23591         (do_writekey): Remove "ecdh" and "ecdsa" support which was available
23592         in experimental libgcrypt before 1.6.0.
23593
23594 2015-07-22  Werner Koch  <wk@gnupg.org>
23595
23596         Avoid a leading double slash in make_filename.
23597         + commit 69d2c9b09bd9d0b86b9f2feb585037a2c11795b0
23598         * common/stringhelp.c (do_make_filename): Special case leading '/'.
23599
23600 2015-07-21  NIIBE Yutaka  <gniibe@fsij.org>
23601
23602         scd: change_keyattr_from_string for ECC.
23603         + commit 9901be395684dd1b35d83685a719291347684ab1
23604         * scd/app-openpgp.c (change_keyattr, change_keyattr_from_string):
23605         Support ECC.
23606         (rsa_writekey): Don't change key attribute.
23607
23608 2015-07-17  NIIBE Yutaka  <gniibe@fsij.org>
23609
23610         scd: Use openpgpdefs.h for constants.
23611         + commit f5d356fb5bbbd0e05a753612455253e4bc335266
23612         * scd/app-openpgp.c: Include openpgpdefs.h.
23613
23614 2015-07-16  Neal H. Walfield  <neal@g10code.com>
23615
23616         Don't segfault if the first 'auto-key-locate' option is 'clear'.
23617         + commit f2ee673c99825d5189631031ddec2dbf54dbd482
23618         * g10/getkey.c (free_akl): If AKL is NULL, just return.
23619
23620 2015-07-10  NIIBE Yutaka  <gniibe@fsij.org>
23621
23622         agent: Support non-NLS build.
23623         + commit b3286af36d452fc801be573a057b0838d53a2edd
23624         * agent/agent.h: Use ENABLE_NLS and define L_() macro.
23625
23626 2015-07-09  NIIBE Yutaka  <gniibe@fsij.org>
23627
23628         scd: Remove unused files.
23629         + commit 67b2dc7636e47baefd5aafe0eb45b4730f974481
23630         * scd/Makefile.am (sc_copykeys_*): Remove.
23631         * scd/sc-copykeys.c: Remove.
23632         * scd/pcsc-wrapper.c: Remove.
23633         * scd/{card-common.h,card-dinsig.c,card-p15.c,card.c}: Remove.
23634
23635 2015-07-08  NIIBE Yutaka  <gniibe@fsij.org>
23636
23637         g10: Use canonical name for curve.
23638         + commit 5b46726931049e060d8fbfa879db7907078a9aed
23639         * g10/import.c (transfer_secret_keys): Use canonical name.
23640         * common/openpgp-oid.c (openpgp_curve_to_oid): Return NULL on error.
23641         * g10/keyid.c (pubkey_string): Follow change of openpgp_curve_to_oid.
23642         * g10/keylist.c (list_keyblock_print, list_keyblock_colon): Ditto.
23643         * g10/parse-packet.c (parse_key): Ditto.
23644
23645 2015-07-03  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
23646
23647         drop long-deprecated gpgsm-gencert.sh.
23648         + commit 1be2cebf7ff5837c8b548b4f4afbf1b8b28211bc
23649          * tools/gpgsm-gencert.sh: remove deprecated script entirely.  It is
23650            fully replaced by gpgsm --gen-key
23651          * doc/tools.texi: remove gpgsm-gencert.sh documentation
23652          * .gitignore: no longer ignore gpgsm-gencert.sh manpage
23653          * doc/Makefile.am: quit making the manpage
23654          * tools/Makefile.am: quit distributing the script
23655          * doc/howto-create-a-server-cert.texi: overhaul documentation to use
23656            gpgsm --gen-key and tweak explanations
23657
23658 2015-07-02  NIIBE Yutaka  <gniibe@fsij.org>
23659
23660         po: Update Japanese translation.
23661         + commit 3502b3cc0f5ff92ab89a0da8b1e344a8ad615737
23662
23663
23664         scd: Support AES decryption for OpenPGPcard v3.0.
23665         + commit 45c49a0030c7a01ec011ce810ddb3aaef734e9bf
23666         * scd/app-openpgp.c (do_decipher): Support AES decryption.
23667
23668 2015-07-01  Werner Koch  <wk@gnupg.org>
23669
23670         Release 2.1.6.
23671         + commit a499eeb6a6545d87ac9f1b64e32017bfdb4f67e6
23672
23673
23674 2015-07-01  Daiki Ueno  <ueno@gnu.org>
23675
23676         agent: Unset INSIDE_EMACS on gpg-agent startup.
23677         + commit f1490a3a0ecf4a5a03373c9563f7709630232ee3
23678         * agent/gpg-agent.c (main): Unset INSIDE_EMACS envvar.
23679
23680 2015-07-01  Werner Koch  <wk@gnupg.org>
23681
23682         common: Implement i18n_localegettext.
23683         + commit a65447f0d64d0c53ddbdcfc988f26ecc9a8a6f08
23684         * common/i18n.c (msg_cache_s, msg_cache_head_s): New.
23685         (msgcache): New.
23686         (i18n_localegettext): Implement locale dependent lookup.
23687
23688 2015-06-30  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
23689
23690         Pass DBUS_SESSION_BUS_ADDRESS for gnome3.
23691         + commit 816824953c91959c23a57c047bdba6a902ffdde6
23692         * common/session-env.c (stdenvnames): Add DBUS_SESSION_BUS_ADDRESS.
23693
23694 2015-06-30  Werner Koch  <wk@gnupg.org>
23695
23696         Flag the L_() function with attribute format_arg.
23697         + commit 232af382e563fcbe15589a3ccae7d6908a17c44d
23698         * agent/agent.h (LunderscorePROTO): New.
23699         * common/util.h (GNUPG_GCC_ATTR_FORMAT_ARG): New.
23700         * common/i18n.h (GNUPG_GCC_ATTR_FORMAT_ARG): New. Use for
23701         i18n_localegettext.  Expand LunderscorePROTO.
23702         * agent/genkey.c (check_passphrase_constraints): Use xtryasprintf
23703         again to keep the old translations.
23704
23705         agent: Use different translation func for Pinentry strings.
23706         + commit e76d4c05b24211f3981ab69cddb3fccc17d21e0e
23707         * po/Makevars (XGETTEXT_OPTIONS): Add keyword "L_".
23708         * common/i18n.c (i18n_localegettext): New stub.
23709         * common/i18n.h: Expand the LunderscoreIMPL macro.
23710         * agent/agent.h (L_): New.
23711         (LunderscoreIMPL): New.
23712         * agent/call-pinentry.c (setup_qualitybar): Add arg ctrl anc change
23713         caller.
23714         * agent/findkey.c (try_unprotect_cb): Add local var ctrl.
23715         * agent/genkey.c (check_passphrase_constraints): Replace xtryasprintf
23716         by xtrystrdup to avoid gcc warning.  Unfortinately this changes the
23717         string.
23718         (agent_ask_new_passphrase): Cleanup the use of initial_errtext.
23719
23720         gpg: Make show-sig-subpackets work again.
23721         + commit 010e4281c3e15e2f86589dd1da419531ead519ef
23722         * g10/gpg.c (parse_list_options): Fix offset for subpackets.
23723
23724 2015-06-29  Werner Koch  <wk@gnupg.org>
23725
23726         agent: Prepare for Libassuan with Cygwin support.
23727         + commit b6076579311029aa76c00377d9a804b1578bf58f
23728         * agent/gpg-agent.c (create_server_socket): Add arg "cygwin".  Call
23729         assuan_sock_set_flag if Assuan version is recent enough.
23730         (main): Create ssh server socket with Cygwin flag set.
23731
23732 2015-06-29  Neal H. Walfield  <neal@gnu.org>
23733
23734         Show passphrase constraints errors as password prompt errors.
23735         + commit 2778c6f8f40d73272075ce04c07097f65c94054e
23736         * agent/agent.h (check_passphrase_constraints): Add parameter
23737         failed_constraint and remove parameter silent.  Update callers.
23738         * agent/genkey.c (check_passphrase_constraints): Add parameter
23739         failed_constraint and remove parameter silent.  If FAILED_CONSTRAINT
23740         is not NULL and OPT.ENFORCE_PASSPHRASE_CONSTRAINTS is FALSE, save the
23741         error text in *FAILED_CONSTRAINT and don't call take_this_one_anyway
23742         or take_this_one_anyway2.  If FAILED_CONSTRAINT is NULL, act as if
23743         SILENT was set.
23744         (agent_ask_new_passphrase): Change initial_errtext's type from a const
23745         char * to a char *.  Pass it to check_passphrase_constraints.  If it
23746         contains malloc's memory, free it.
23747
23748 2015-06-29  Neal H. Walfield  <neal@g10code.com>
23749
23750         Improve documentation for default-cache-ttl and default-cache-ttl-ssh.
23751         + commit 0416aed4abf6cea94458d2e38eb4a5e6bfea2d8b
23752         * doc/gpg-agent.texi (Agent Options): Improve documentation for
23753         default-cache-ttl and default-cache-ttl-ssh.
23754
23755         Don't raise max-cache-ttl to default-cache-ttl.
23756         + commit 60cf69ff9d61a2cd37fc4468f232fd41aa70a651
23757         * agent/gpg-agent.c (finalize_rereadable_options): Don't raise
23758         max-cache-ttl to default-cache-ttl.  Likewise for max-cache-ttl-ssh
23759         and default-cache-ttl-ssh.
23760
23761         Improve the description of old packets with an indeterminate length.
23762         + commit 68c217f457a772984d0afbdd341f18de7c867505
23763         * g10/parse-packet.c (parse): Make the description more accurate when
23764         listing packets: old format packets don't support partial lengths,
23765         only indeterminate lengths (RFC 4880, Section 4.2).
23766
23767 2015-06-29  Werner Koch  <wk@gnupg.org>
23768
23769         agent: Add --verify to the PASSWD command.
23770         + commit 9bca96dbc5c32bdd00196462fde8c9ab94aeb28d
23771         * agent/command.c (cmd_passwd): Add option --verify.
23772
23773         agent,w32: Do not create a useless socket with --enable-putty-support.
23774         + commit 7a387331645736eaeaaef57770beef5fa741bc22
23775         * agent/agent.h (opt): Remove field ssh_support.
23776         * agent/gpg-agent.c (ssh_support): New.  Replace all opt.ssh_support
23777         by this.
23778         (main): Do not set ssh_support along with setting putty_support.
23779
23780         gpgsm: Add command option "offline".
23781         + commit 2c9c46e2a2b8f9a1bdc1ef46a135b5fc7d1a8073
23782         * sm/server.c (option_handler): Add "offline".
23783         (cmd_getinfo): Ditto.
23784         * sm/certchain.c (is_cert_still_valid):
23785         (do_validate_chain):
23786         * sm/gpgsm.c (gpgsm_init_default_ctrl): Default "offline" to the value
23787         of --disable-dirmngr.
23788         * sm/call-dirmngr.c (start_dirmngr_ext): Better also check for
23789         ctrl->offline.
23790
23791 2015-06-26  NIIBE Yutaka  <gniibe@fsij.org>
23792
23793         scd: Support button flag and AES key data for OpenPGPcard v3.0.
23794         + commit d2fdf2e1b6cd447bb1c36df0ac7d8e669802fa22
23795         * scd/app-openpgp.c (do_getattr, show_caps, app_select_openpgp):
23796         Support button and symmetric decryption.
23797         (do_setattr): Support setting AESKEY.
23798
23799 2015-06-25  Andre Heinecke  <aheinecke@intevation.de>
23800
23801         sm: Fix cert storage for ephemeral certs.
23802         + commit 5e1a844ae9b6730b4b8a2c9178ea9bc121560c28
23803         * sm/keydb.c (keydb_store_cert): Clear ephemeral flag for
23804         existing certs if store should not be ephemeral.
23805
23806 2015-06-23  Werner Koch  <wk@gnupg.org>
23807
23808         Allow use of debug flag names for all tools.
23809         + commit 54a0ed3d9b10a3c6dfb3d6a4d20b693a3183f8f6
23810         * g13/g13.c: Make use of debug_parse_flag.
23811         * scd/scdaemon.c: Ditto.
23812         * sm/gpgsm.c: Ditto
23813         * agent/gpg-agent.c: Ditto.  But do not terminate on "help"
23814         * dirmngr/dirmngr.c: Ditto.
23815
23816         common: Improve fucntion parse_debug_flag.
23817         + commit 8195e55d0c134a45f7c9bd95c8b5741781841c18
23818         * common/miscellaneous.c (parse_debug_flag): Add hack not to call
23819         exit.  Add "none" and "all" flags.
23820
23821 2015-06-23  NIIBE Yutaka  <gniibe@fsij.org>
23822
23823         scd: pinpad workaround for PC/SC implementations.
23824         + commit 5e1d2fe6555d06f9dcd2daac713b2edfbc0428a5
23825         * scd/adpu.c (pcsc_pinpad_verify, pcsc_pinpad_modify): Bigger buffer
23826         for TPDU card reader.
23827
23828 2015-06-22  Werner Koch  <wk@gnupg.org>
23829
23830         gpg: Allow debug flag names for --debug.
23831         + commit 4698e5b203bd983503b5fd784fcd09dd3bc3a15e
23832         * g10/gpg.c (opts): Change arg for oDebug to a string.
23833         (debug_flags): New; factored out from set_debug.
23834         (set_debug): Remove "--debug-level help".  Use parse_debug_flag to
23835         print the used flags.
23836         (main): Use parse_debug_flag for oDebug.
23837
23838         common: Add function parse_debug_flag.
23839         + commit 22147952b744958ec46d356e942540356ff7d93e
23840         * common/miscellaneous.c (parse_debug_flag): New.
23841         * common/util.h (struct debug_flags_s): New.
23842
23843         common: Add function strtokenize.
23844         + commit d37f47081d41584efc0c397432811f9cfa5d5867
23845         * common/stringhelp.c: Include assert.h.
23846         (strtokenize): New.
23847         * common/t-stringhelp.c (test_strtokenize): New.
23848
23849         gpg: Fix regression due to recent commit 6500f33.
23850         + commit e0873a3372800d51c90ca656450f937dbae9c169
23851         * g10/keydb.c (kid_list_s): Keep a state in the table.
23852         (kid_not_found_table): Rename to kid_found_table.
23853         (n_kid_not_found_table): Rename to kid_found_table_count.
23854         (kid_not_found_p): Return found state.
23855         (kid_not_found_insert): Add arg found.
23856         (keydb_search): Store found state in the table.
23857
23858 2015-06-22  NIIBE Yutaka  <gniibe@fsij.org>
23859
23860         scd: Fix Cherry ST-2000 support for pinpad input.
23861         + commit 444e9232aa9e00aacd939cbf7bdb881b550dfebe
23862         * scd/apdu.c (pcsc_vendor_specific_init): Set pinmax to 15.
23863         * scd/ccid-driver.c (ccid_transceive_secure): Add zero for the
23864         template of APDU.
23865
23866 2015-06-20  Werner Koch  <wk@gnupg.org>
23867
23868         gpg: Print number of good signatures with --check-sigs.
23869         + commit 0948c4f217308ffa0ec61ce189d387fd61b02bbd
23870         * g10/keylist.c (keylist_context): Add field good_sigs.
23871         (list_keyblock_print): Updated good_sigs.
23872         (print_signature_stats): Print number of good signatures and use
23873         log_info instead of tty_printf.
23874
23875         gpg: Improve speed of --check-sigs and --lish-sigs.
23876         + commit 6500f338a35f4148606480c79f3a0c1b0d15f13a
23877         * g10/keydb.c (kid_list_t): New.
23878         (kid_not_found_table, n_kid_not_found_table): New.
23879         (kid_not_found_p, kid_not_found_insert, kid_not_found_flush): New.
23880         (keydb_insert_keyblock): Flush the new cache.
23881         (keydb_delete_keyblock): Ditto.
23882         (keydb_update_keyblock): Ditto.
23883         (keydb_search): Use the new cache.
23884         (keydb_dump_stats): New.
23885         * g10/gpg.c (g10_exit): Dump keydb stats.
23886
23887 2015-06-19  Werner Koch  <wk@gnupg.org>
23888
23889         gpg: Add more log_clock calls to keydb.c.
23890         + commit 53e9b86085ac70ede8a0b1de9018ccbfe55b0932
23891         * g10/keydb.c (keydb_get_keyblock): Add log_clock calls.
23892
23893         gpg: Print available debug flags using "--debug-level help".
23894         + commit 663a31f1ea2fc5a43c822e916cf20fece5243851
23895         * g10/gpg.c (set_debug): Add "help" option and use a table for the
23896         flags.
23897
23898         gpg: Fix export problem in case an old keyring has PGP-2 keys.
23899         + commit c5604eeee4b64a44a1ca1d517ace14fc1cbda298
23900         * g10/export.c (do_export_stream): Skip legacy keys.
23901
23902 2015-06-18  Werner Koch  <wk@gnupg.org>
23903
23904         dirmngr: Fix the cleanup zombies fix (685b782).
23905         + commit c97198371b7307e64afdd323231977b2247f64ec
23906         * dirmngr/ldap-wrapper.c (ldap_wrapper_thread): Do not close the
23907         stdout reader after EOF from read_log_data.
23908         * dirmngr/crlcache.c (crl_cache_reload_crl): Close the reader before
23909         the next iteration.
23910
23911 2015-06-17  Werner Koch  <wk@gnupg.org>
23912
23913         agent: Print a warning for obsolete options.
23914         + commit 010d26a85bfe15c4aa12eefeab851dbde0609c26
23915         * g10/misc.c (obsolete_scdaemon_option): Move to
23916         * common/miscellaneous.c (obsolete_option): ... here.
23917         * agent/gpg-agent.c (main): Use obsolete_option for the 3 obsolete
23918         options.
23919
23920 2015-06-16  Werner Koch  <wk@gnupg.org>
23921
23922         dirmngr: Cleanup zombies and fix hang on shutdown.
23923         + commit 685b782a18adb90bbf78956682e4e7f89fed678c
23924         * dirmngr/ldap-wrapper.c (ldap_wrapper_thread): Move nfds computation
23925         into the loop.  Check the queue also on timeout.  Close log_fd and
23926         reader context on EOF or error.
23927
23928         dirmngr: Avoid accessing uninitialized memory in log callback.
23929         + commit 82c72e2db7bc5b633768d59822f2e2a353fa6e32
23930         * dirmngr/dirmngr.c (pid_suffix_callback): Clear int_and_ptr_u before
23931         use.
23932         (start_connection_thread): Ditto.
23933         (handle_connections): Ditto.
23934
23935 2015-06-16  Neal H. Walfield  <neal@g10code.com>
23936
23937         Don't prompt for the password multiple times in pinentry loopback mode.
23938         + commit eac081ba1278855fa223b031b527498fec558bc7
23939         * g10/gpg.c (main): If OPT.PINENTRY_MODE is PINENTRY_MODE_LOOPBACK,
23940         clear OPT.PASSPHRASE_REPEAT.
23941
23942 2015-06-16  NIIBE Yutaka  <gniibe@fsij.org>
23943
23944         po: Update Japanese Translation.
23945         + commit 15540f6233bd041b06708862a6d9535cbcabe330
23946
23947
23948 2015-06-15  Werner Koch  <wk@gnupg.org>
23949
23950         doc: Add defs.inc to BUILT_SOURCES.
23951         + commit ef273a9afc7840b75cfb9b8af78d117b7d672c6a
23952
23953
23954 2015-06-11  Werner Koch  <wk@gnupg.org>
23955
23956         Release 2.1.5.
23957         + commit 9b7bdfae82f74a147a5dbf0fac0f78cde77a207b
23958
23959
23960         agent: Fix --extra-socket on Windows.
23961         + commit 985918aab025cf0ac9db411b88a47c4b985e5e95
23962         * agent/gpg-agent.c (start_connection_thread): Rename to ...
23963         (do_start_connection_thread): this.  Factor nonce checking out to ...
23964         (start_connection_thread_std): this,
23965         (start_connection_thread_extra): this,
23966         (start_connection_thread_browser): and this.
23967
23968         agent: Add experimental option --browser-socket.
23969         + commit 008435b95cbca19adc217178dc9d793eca584345
23970         * agent/agent.h (opt): Add field "browser_socket".
23971         * agent/command.c (cmd_setkeydesc): Use a different message for
23972         restricted==2.
23973         * agent/gpg-agent.c (oBrowserSocket): New.
23974         (opts): Add --browser-socket.
23975         (socket_name_browser, redir_socket_name_browser): New.
23976         (socket_nonce_browser): New.
23977         (cleanup): Cleanup browser socket.
23978         (main): Implement option.
23979         (start_connection_thread_browser): New.
23980         (handle_connections): Add arg listen_fd_browser and use it.
23981
23982 2015-06-10  Daiki Ueno  <ueno@gnu.org>
23983
23984         agent: Add option --allow-emacs-pinentry.
23985         + commit 691dae270b3b741178912599724d69adabdb48b9
23986         * agent/agent.h (opt): Add field allow_emacs_pinentry.
23987         * agent/call-pinentry.c (start_pinentry): Act upon new var.
23988         * agent/gpg-agent.c (oAllowEmacsPinentry): New.
23989         (opts): Add option --allow-emacs-pinentry.
23990         (parse_rereadable_options): Set this option.
23991         * tools/gpgconf-comp.c (gc_options_gpg_agent): Add new option.
23992
23993 2015-06-09  Werner Koch  <wk@gnupg.org>
23994
23995         doc: Do not used fixed file names in the manuals.
23996         + commit 25331bba5554a39d226d32433add7784b2e170b8
23997         * doc/mkdefsinc.c: New.
23998         * doc/Makefile.am: Include cmacros.am.
23999         (EXTRA_DIST): Add mkdefsinc.c defsincdate.
24000         (BUILT_SOURCES): Add defsincdate
24001         (CLEANFILES): Add mkdefsinc and defs.inc.
24002         (mkdefsinc): New rule.
24003         (yat2m-stamp): Depend on defs.inc.
24004         ($(myman_pages) gnupg.7): Ditto.
24005         (gnupg.texi): Remove rule to touch itself.
24006         (dist-hook): New.
24007         (defsincdate): New.
24008         (defs.inc): New.
24009         * doc/gnupg.texi: Remove inclusion of version.texi.  Include defs.inc.
24010         Also include defs.inc in all files used to build man files.  Change
24011         fixed directory names to those from defs.inc.
24012
24013         dirmngr: Avoid crash due to an empty crls.d/DIR.txt.
24014         + commit 255dadd76d5a2101d2c5450741326b67253fa9ea
24015         * dirmngr/crlcache.c (check_dir_version): Avoid segv.
24016
24017 2015-06-08  Werner Koch  <wk@gnupg.org>
24018
24019         doc: Change the manual source to be only for GnuPG 2.1.
24020         + commit abbefdd04d7ee30218506caeae1fd858569c9f0a
24021
24022
24023         Convey envvar INSIDE_EMACS to the pinentry.
24024         + commit c672572bd50966187cc823585efed673b66ff942
24025         * common/session-env.c (stdenvnames): Add it.
24026
24027         agent: Add command "getinfo std_env_names".
24028         + commit 8425db6a26bf66dad16dfbc26be9af7d272f31d3
24029         * agent/command.c (cmd_getinfo): Add new sub-command.
24030
24031 2015-06-05  NIIBE Yutaka  <gniibe@fsij.org>
24032
24033         scd: do_decipher change for OpenPGPcard v3.0.
24034         + commit cf508a1f7f4c8926dc554be68a2d46f5ce272ac0
24035         * scd/app-openpgp.c (do_decipher): Add a header for ECDH.
24036
24037 2015-06-04  Werner Koch  <wk@gnupg.org>
24038
24039         gpg: Replace -1 by GPG_ERR_NOT_FOUND in tdbio.c.
24040         + commit a4a15195c2a3729025a3ba3439ac8860083fceeb
24041         * g10/tdbio.c (lookup_hashtable): Return GPG_ERR_NOT_FOUND.
24042         * g10/tdbdump.c (import_ownertrust): Test for GPG_ERR_NOT_FOUND.
24043         * g10/trustdb.c (read_trust_record): Ditto.
24044         (tdb_get_ownertrust, tdb_get_min_ownertrust): Ditto.
24045         (tdb_update_ownertrust, update_min_ownertrust): Ditto.
24046         (tdb_clear_ownertrusts, update_validity): Ditto.
24047         (tdb_cache_disabled_value): Ditto.
24048
24049         gpg: Cleanup error code path in case of a bad trustdb.
24050         + commit f170240ef735edc481f60e51527cbb5ee1acfd55
24051         * g10/tdbio.c (tdbio_read_record): Fix returning of the error.
24052
24053         gpg: Fix output in case of a corrupted trustdb.
24054         + commit bf06d04f53296f4b4b73b9360cf1571559bb2295
24055         * g10/tdbdump.c (list_trustdb): Add arg FP and change callers to pass
24056         es_stdout.
24057         * g10/tdbio.c (upd_hashtable): On a corrupted trustdb call
24058         list_trustdb only in verbose > 1 mode and let it dump to stderr.
24059
24060 2015-05-29  NIIBE Yutaka  <gniibe@fsij.org>
24061
24062         scd: Fix key template of ECC.
24063         + commit e5c69e87beebe99d362ac721ce4ea6b057a30a99
24064         * scd/app-openpgp.c (build_ecc_privkey_template): Use correct value.
24065
24066 2015-05-28  NIIBE Yutaka  <gniibe@fsij.org>
24067
24068         g10: Fix a race condition initially creating trustdb.
24069         + commit fe5c6edaed78839303d67e01e141cfc6b5de9aec
24070         * g10/tdbio.c (take_write_lock, release_write_lock): New.
24071         (put_record_into_cache, tdbio_sync, tdbio_end_transaction): Use
24072         new lock functions.
24073         (tdbio_set_dbname): Fix the race.
24074         (open_db): Don't call dotlock_create.
24075
24076 2015-05-27  NIIBE Yutaka  <gniibe@fsij.org>
24077
24078         g10: Remove g10/signal.c.
24079         + commit 6cb18a8f975b7ff7ca79c1fb0cddcd4b66be90fb
24080         * g10/signal.c: Remove.
24081         * g10/main.h: Remove old function API.
24082         * g10/tdbio.c: Use new API, even in the dead code.
24083
24084 2015-05-20  Werner Koch  <wk@gnupg.org>
24085
24086         agent: Cleanup caching code for command GET_PASSPHRASE.
24087         + commit 23d2ef83cda644c6a83499f9327350d3371e8a17
24088         * agent/command.c (cmd_get_passphrase): Read from the user cache.
24089
24090 2015-05-19  Neal H. Walfield  <neal@g10code.com>
24091
24092         agent: When the password cache is cleared, also clear the ext. cache.
24093         + commit 3a9305439b75ccd4446378d4fd87da087fd9c892
24094         * agent/agent.h (agent_clear_passphrase): New declaration.
24095         * agent/call-pinentry.c (agent_clear_passphrase): New function.
24096         * agent/command.c (cmd_clear_passphrase): Call agent_clear_passphrase.
24097
24098         agent: Modify agent_clear_passphrase to support an ext. password cache.
24099         + commit e201c20f25e7bed29088186c5f717d43047a0f4b
24100         * agent/agent.h (agent_get_passphrase): Add arguments keyinfo and
24101         cache_mode.  Update callers.
24102         * agent/call-pinentry.c (agent_get_passphrase): Add arguments keyinfo
24103         and cache_mode.  If KEYINFO and CACHE_MODE describe a cachable key,
24104         then send SETKEYINFO to the pinentry.
24105
24106 2015-05-19  NIIBE Yutaka  <gniibe@fsij.org>
24107
24108         g10: detects public key encryption packet error properly.
24109         + commit c771963140cad7c1c25349bcde27e427effc0058
24110         g10/mainproc.c (proc_pubkey_enc): Only allow relevant algorithms for
24111         encryption.
24112
24113 2015-05-15  Werner Koch  <wk@gnupg.org>
24114
24115         build: Make --disable-gpgsm work.
24116         + commit 43ea8f5d884dd108bb27d8e1610fa28802295a06
24117         * Makefile.am: Always build kbx/
24118         * g10/Makefile.am (AM_CFLAGS): Include KSBA_CFLAGS.
24119
24120 2015-05-12  Werner Koch  <wk@gnupg.org>
24121
24122         Release 2.1.4.
24123         + commit a67ead6525d7597a9e0b152c5971f6290f7912f3
24124
24125
24126         speedo: Add make option SELFCHECK=0 to build a new release.
24127         + commit 21b0701e2e044894c53ff59d22c5c6a172780c25
24128         * build-aux/getswdb.sh: Add option --skip-selfcheck.
24129         * build-aux/speedo.mk: Add option SELFCHECK.
24130
24131 2015-05-11  Werner Koch  <wk@gnupg.org>
24132
24133         common: Cope with AIX problem on number of open files.
24134         + commit 987532b038a2d9b9e76c0de425ee036ca2bffa1b
24135         * common/exechelp-posix.c: Limit returned value for too hight values.
24136
24137         gpg-connect-agent: Fix quoting of internal percent+ function.
24138         + commit 26e2eb98d3d8405b335b43c8e86deacf622cd957
24139         * tools/gpg-connect-agent.c (get_var_ext) <percent, percent+): Also
24140         escape '+'.
24141
24142         agent: Add option --no-allow-external-cache.
24143         + commit d7293cb317acc40cc9e5189cef33fe9d8b47e62a
24144         * agent/agent.h (opt): Add field allow_external_cache.
24145         * agent/call-pinentry.c (start_pinentry): Act upon new var.
24146         * agent/gpg-agent.c (oNoAllowExternalCache): New.
24147         (opts): Add option --no-allow-external-cache.
24148         (parse_rereadable_options): Set this option.
24149
24150         agent: Add strings for use by future Pinentry versions.
24151         + commit 02d5e1205489aa5027a87a64552eaf15984dc22d
24152         * agent/call-pinentry.c (start_pinentry): Add more strings.
24153
24154         agent: Add option --debug-pinentry.
24155         + commit 14232c3870c5ef5d2fa15e8ed3f302b1ba29d25c
24156         * agent/gpg-agent.c (oDebugPinentry): New.
24157         (opts): Add --debug-pinentry.
24158         (parse_rereadable_options): Set that option.
24159         * agent/call-pinentry.c (start_pinentry): Pass option to
24160         assuan_set_flag.
24161
24162 2015-05-08  Werner Koch  <wk@gnupg.org>
24163
24164         gpg: Avoid cluttering stdout with trustdb info in verbose mode.
24165         + commit b03a2647299a6c8764a2574590cbaccdff9e497d
24166         * g10/trustdb.c (validate_keys): Call dump_key_array only in debug
24167         mode.
24168
24169         gpg: Fix wrong output in list mode.
24170         + commit 7039f87375b3c89d6e63837b811ed2be71c8d9db
24171         * g10/parse-packet.c (parse_gpg_control): Replace puts by es_fputs to
24172         LISTFP.
24173
24174         gpg: New command --quick-adduid.
24175         + commit 64e809b791645f343feb69112baba8e2700e454b
24176         * g10/keygen.c (ask_user_id): Factor some code out to ...
24177         (uid_already_in_keyblock): new.
24178         (generate_user_id): Add arg UIDSTR.  Fix leaked P.
24179         * g10/keyedit.c (menu_adduid): Add new arg uidstring.  Adjust caller.
24180         (keyedit_quick_adduid): New.
24181         * g10/gpg.c (aQuickAddUid): New.
24182         (opts):  Add command --quick-adduid.
24183         (main): Implement that.
24184
24185         gpg: Add push/pop found state feature to keydb.
24186         + commit 3c439c0447f8a7468a61bbdc4c9a101ef2451dcb
24187         * g10/keydb.c (keydb_handle): Add field saved_found.
24188         (keydb_new): Init new field.
24189         (keydb_push_found_state, keydb_pop_found_state): New.
24190         * g10/keyring.c (kyring_handle): Add field saved_found.
24191         (keyring_push_found_state, keyring_pop_found_state): New.
24192
24193         gpg: Minor code merging in keyedit.
24194         + commit b772e459fa91cdc7facd95227ebc0faba20a7003
24195         * g10/keyedit.c (fix_keyblock): Rename to fix_key_signature_order.
24196         (fix_keyblock): New.  Call fix_key_signature_order and other fix
24197         functions.
24198         (keyedit_menu): Factor code out to new fix_keyblock.
24199         (keyedit_quick_sign): Ditto.  Check for primary fpr before calling
24200         fix_keyblock.
24201
24202 2015-05-07  Werner Koch  <wk@gnupg.org>
24203
24204         agent: Minor change for 56b5c9f.
24205         + commit 436f2060721e997479a9dd5be8dfc73627dd49c9
24206         * agent/call-pinentry.c (agent_askpin): Move option setting to ...
24207         (start_pinentry): here.  Fix error code check.
24208
24209 2015-05-07  Kristian Fiskerstrand  <kf@sumptuouscapital.com>
24210
24211         dirmngr: Fix segfault in ldap engine.
24212         + commit d0d4984cfec54dee727b9e9d33d09e33c6f2e182
24213         (ks-engine-ldap.c) Fix segfault caused by missing check whether uri is
24214         initialized
24215
24216 2015-05-07  Neal H. Walfield  <neal@g10code.com>
24217
24218         agent: Improve support for externally cached passwords.
24219         + commit 56b5c9f94f2e55d096be585ed061ccf1c9ec0de6
24220         * agent/call-pinentry.c (PINENTRY_STATUS_PASSWORD_FROM_CACHE): New
24221         constant.
24222         (pinentry_status_cb): Add it to *FLAGS if PASSWORD_FROM_CACHE was
24223         provided.
24224         (agent_askpin): Pass "OPTION allow-external-password-cache" to the
24225         pinentry.  Always pass SETKEYINFO to the pinentry.  If there is no
24226         stable identifier, then use "--clear".  If the password is incorrect
24227         and PINENTRY_STATUS_PASSWORD_FROM_CACHE is set in *PINENTRY_STATUS,
24228         then decrement PININFO->FAILED_TRIES.
24229
24230         agent: Or in the value; don't overwrite the variable.
24231         + commit 74944330ba7229ed0cbe23cc0f573962a444bd07
24232         * agent/call-pinentry.c (pinentry_status_cb): Or in
24233         PINENTRY_STATUS_CLOSE_BUTTON; don't overwrite *FLAG.
24234
24235         agent: Avoid magic numbers.  Use more accurate names.
24236         + commit d3b5cad2346bd5747789dc62d7804fa5c15f4f3b
24237         * agent/call-pinentry.c (PINENTRY_STATUS_CLOSE_BUTTON): New constant.
24238         (PINENTRY_STATUS_PIN_REPEATED): Likewise.
24239         (close_button_status_cb): Rename from this...
24240         (pinentry_status_cb): ... to this.  Use the constants.
24241         (agent_askpin): Rename local variable from close_button to
24242         pinentry_status.  Use symbolic constants rather than magic numbers.
24243
24244 2015-05-07  Werner Koch  <wk@gnupg.org>
24245
24246         gpg: Improve 'General key info' line of --card-status.
24247         + commit 874ef16e70ab750db7b153f17a7e859a0db6a2f1
24248         * g10/keylist.c (print_pubkey_info): Print either "pub" or "sub".
24249
24250         * g10/getkey.c (get_pubkey_byfprint): Add optional arg R_KEYBLOCK.
24251         * g10/keyid.c (keyid_from_fingerprint): Adjust for change.
24252         * g10/revoke.c (gen_desig_revoke): Adjust for change.
24253         * g10/card-util.c (card_status): Simplify by using new arg.  Align
24254         card-no string.
24255
24256         * g10/card-util.c (card_status): Remove not used GnuPG-1 code.
24257
24258         gpg: Fix regression not displaying the card serial number.
24259         + commit 173b26c8f83a3c623165a96c315bf9ed4b90edcc
24260         * g10/call-agent.c (keyinfo_status_cb): Detect KEYINFO.
24261
24262 2015-05-06  Werner Koch  <wk@gnupg.org>
24263
24264         speedo,w32: Install a native pinentry.
24265         + commit 154abaf3c97dae43ba972e4482680a287f3e5c39
24266         * build-aux/speedo.mk: Always build pinentry for w32.
24267         (speedo_pkg_pinentry_configure): Adjust to modern pinentry.
24268         * build-aux/speedo/w32/inst.nsi: Install native pinentry under the
24269         name pinentry-basic.exe.
24270
24271 2015-05-01  NIIBE Yutaka  <gniibe@fsij.org>
24272
24273         g10: fix cmp_public_key.
24274         + commit f77fd572db658959fa40aa8c181be919e688b707
24275         * g10/free-packet.c (cmp_public_keys): Compare opaque
24276         data at the first entry of the array when it's unknown algo.
24277
24278 2015-04-30  NIIBE Yutaka  <gniibe@fsij.org>
24279
24280         scd: PC/SC reader selection by partial string match.
24281         + commit 01a2a61bc4b34817c4216888265f65d59a33dad3
24282         * scd/apdu.c (open_pcsc_reader_direct): Partial string match.
24283
24284 2015-04-24  Werner Koch  <wk@gnupg.org>
24285
24286         common: Remove JNLIB from boiler plate (jnlib merge).
24287         + commit 172b6193488f433a206fd88f85d8c4a5d1eb7fdf
24288         * common/README.jnlib: Remove.
24289
24290         common: Rename log and gcc attribute macros (jnlib merge).
24291         + commit 26d7e0d7accf269c15fb4bc23e5e80580bfb7fe3
24292         * common/logging.h: Rename JNLIB_LOG_* to GPGRT_LOG_*.
24293         * common/mischelp.h: Rename JNLIB_GCC_* to GPGRT_GCC_*.
24294
24295         common: Remove two JNLIB_ macros (jnlib merge).
24296         + commit 575230d91bba95697518da418ea0e8712f889a0f
24297         * configure.ac: Merge seperate jnlib checks.
24298         (HAVE_JNLIB_LOGGING): Remove.
24299         * common/logging.c, common/simple-pwquery.c (JNLIB_NEED_AFLOCAL):
24300         Rename to GNUPG_COMMON_NEED_AFLOCAL.  Change all tests.
24301
24302         common: Remove libjnlib-config.h (jnlib merge).
24303         + commit 17bcd087082d01c48c60ff20d7f9a40f34c6969f
24304         * common/libjnlib-config.h: Remove.
24305         * common/common-defs.h (getenv) [HAVE_GETENV]: New.  From removed
24306         header.
24307         (getpid) [HAVE_W32CE_SYSTEM]: New.  From removed header.
24308         * common/argparse.c: Include util.h and common-defs.h.  Replace
24309         jnlib_ macro names for non-GNUPG builds by x* names.
24310         * common/dotlock.c: Ditto.
24311         * common/logging.c: Include util.h and common-defs.h.  Replace jnlib_
24312         symbol names by x* names.
24313         * common/strlist.c: Ditto.
24314         * common/utf8conv.c: Ditto.
24315         * common/w32-reg.c: Ditto.
24316         * common/mischelp.c: Ditto.  Also remove _jnlib_free.
24317         * common/stringhelp.c: Ditto.
24318         (JNLIB_LOG_WITH_PREFIX): Do not depend on this macro.
24319         * common/logging.h (JNLIB_LOG_WITH_PREFIX): Do not depend on this
24320         macro.
24321
24322 2015-04-23  Werner Koch  <wk@gnupg.org>
24323
24324         gpg: Move all DNS access to Dirmngr.
24325         + commit 154f3ed2bf64de801ae0f9796338a2767ec6357b
24326         * common/dns-cert.h: Move to ../dirmngr/.
24327         * common/dns-cert.c: Move to ../dirmngr/.  Change args to return the
24328         key as a buffer.
24329         * common/t-dns-cert.c: Move to ../dirmngr/.
24330         * common/pka.c, common/pka.h, common/t-pka.c: Remove.
24331
24332         * dirmngr/server.c (data_line_cookie_write): Factor code out to
24333         data_line_write and make it a wrapper for that.
24334         (data_line_write): New.
24335         (cmd_dns_cert): New.
24336         (register_commands): Register new command.
24337
24338         * g10/Makefile.am (LDADD): Remove DNSLIBS.
24339         * g10/call-dirmngr.c (dns_cert_parm_s): New.
24340         (dns_cert_data_cb, dns_cert_status_cb): New.
24341         (gpg_dirmngr_dns_cert): New.
24342         (gpg_dirmngr_get_pka): New.
24343         * g10/gpgv.c (gpg_dirmngr_get_pka): New dummy function.
24344         * g10/keyserver.c (keyserver_import_cert): Replace get_dns_cert by
24345         gpg_dirmngr_dns_cert.
24346         (keyserver_import_pka): Replace get_pka_info by gpg_dirmngr_get_pka.
24347         * g10/mainproc.c: Include call-dirmngr.h.
24348         (pka_uri_from_sig): Add CTX arg. Replace get_pka_info by
24349         gpg_dirmngr_get_pka.
24350
24351         common: Minor change of hex2str to allow for embedded nul.
24352         + commit ce11cc39ea7e011040debc9339a2310a714efe7e
24353         * common/convert.c (hex2str): Set ERRNO.  Return adjusted COUNT.
24354
24355 2015-04-23  NIIBE Yutaka  <gniibe@fsij.org>
24356
24357         common: removal of t-support.c from t_jnlib_src.
24358         + commit a7264e3a6a83189a9e43edf5e99f5ac7ee42a2ab
24359         * common/Makefile.am (t_jnlib_src): Remove t-support.c.
24360
24361 2015-04-21  Werner Koch  <wk@gnupg.org>
24362
24363         gpg: Make keyserver-option http_proxy work.
24364         + commit c4d98734c5df39f57a71f0ec1c0c80e82ff08508
24365         * g10/options.h (opt): Add field keyserver_options.http_proxy.
24366         * g10/keyserver.c (warn_kshelper_option): Add arg noisy.
24367         (parse_keyserver_options): Parse into new http_proxy field.
24368         * g10/call-dirmngr.c (create_context): Send the http-proxy option.
24369
24370         common: Make proper use of http proxy parameter.
24371         + commit 54e55149f2af96eff08bfd6f70ef13d007fb58c7
24372         * common/http.c (is_hostname_port): New.
24373         (send_request): Fix proxy name parsing.
24374
24375         dirmngr: Add http proxy support for keyservers.
24376         + commit a0dead5edce07838cf5ff3ec7205a3bff2a6ef70
24377         * dirmngr/dirmngr.h (server_control_s): Add field http_proxy.
24378         * dirmngr/dirmngr.c (dirmngr_init_default_ctrl): Copy http_proxy value
24379         from OPT.
24380         (dirmngr_deinit_default_ctrl): New.
24381         (main): Call dirmngr_deinit_default_ctrl.
24382         * dirmngr/server.c (start_command_handler): Ditto.
24383         (option_handler): Add option "http-proxy".
24384         * dirmngr/crlfetch.c (crl_fetch): Take http_proxy from CTRL.
24385         * dirmngr/ocsp.c (do_ocsp_request): Ditto.
24386         * dirmngr/ks-engine-hkp.c (send_request): Add proxy support.
24387         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
24388
24389         gpg: Do not use honor-keyserver-url sub-option by default.
24390         + commit 727fe4f8d7d5fc3eac0b0aa6fafa4a314686d7dc
24391
24392
24393         gpg: Make preferred keyservers work.
24394         + commit ae0d65f86413a82a40cf68e08aaeca405eee8c78
24395         * g10/call-dirmngr.c (dirmngr_local_s): Add field set_keyservers_done.
24396         (create_context): Move keyserver setting to ...
24397         (open_context): here.
24398         (clear_context_flags): New.
24399         (gpg_dirmngr_ks_get): Add arg override_keyserver.
24400         * g10/keyserver.c (keyserver_refresh): Improve diagnostics.
24401         (keyserver_get_chunk): Ditto.  Pass OVERRIDE_KEYSERVER to ks_get.
24402
24403         gpg: Update sub-options of --keyserver-options.
24404         + commit da1990bac71f6447d8ebd169c3b3b186e9f287d9
24405         * g10/options.h (KEYSERVER_HTTP_PROXY): New.
24406         (KEYSERVER_USE_TEMP_FILES, KEYSERVER_KEEP_TEMP_FILES): Remove.
24407         (KEYSERVER_TIMEOUT): New.
24408         * common/keyserver.h (KEYSERVER_TIMEOUT): Remove.
24409         * g10/keyserver.c (keyserver_opts): Remove obsolete "use-temp-files"
24410         and "keep-temp-files". Add "http-proxy" and "timeout".
24411         (parse_keyserver_options): Remove 1.2 compatibility option
24412         "honor-http_proxy".  Remove "use-temp-files" and "keep-temp-files"
24413         code.
24414
24415 2015-04-14  Werner Koch  <wk@gnupg.org>
24416
24417         agent: Send the new SETKEYINFO command to the Pinentry.
24418         + commit 2180845959839705200e3172dbafc94b70b9007f
24419         * agent/call-pinentry.c (agent_askpin): Add args keyinfo and
24420         cache_mode.  Change all callers to pass (NULL,0) for them.  Send
24421         SETKEYINFO command.
24422         * agent/findkey.c (unprotect): Pass the keygrip and the cache_mode for
24423         the new args.
24424
24425 2015-04-14  NIIBE Yutaka  <gniibe@fsij.org>
24426
24427         scd: better handling of extended APDU.
24428         + commit 971d558e862db878a7310e06ed7116dbe36886ab
24429         * scd/apdu.c (send_le): Bug fix for not append Z when lc<0&&le<0.
24430         * scd/app-common.h (struct app_ctx_s): Use bit fields for flags.
24431         * scd/ccid-driver.c (CCID_MAX_BUF): New.  Only for OpenPGPcard.
24432         (struct ccid_driver_s): New field of max_ccid_msglen.
24433          Remove ifsd field.
24434         (parse_ccid_descriptor): Initialize max_ccid_msglen.
24435         (ccid_transceive_apdu_level): Implement sending extended APDU in
24436         chain of CCID message.
24437
24438 2015-04-13  Werner Koch  <wk@gnupg.org>
24439
24440         gpg: Fix NULL-segv due to invalid imported data.
24441         + commit 25fce93ba19d997e234a674d5cc98df82c5b5496
24442         * g10/free-packet.c (my_mpi_copy): New.
24443         (copy_public_key, copy_signature): Use instead of mpi_copy.
24444
24445 2015-04-13  Neal H. Walfield  <neal@g10code.com>
24446
24447         dirmngr: If LDAP is not enable, don't build the LDAP bits.
24448         + commit 5cde5bf37339cdeb0bd0a33d39477382eafebede
24449         * dirmngr/Makefile.am (dirmngr_SOURCES): Only include
24450         ks-engine-ldap.c, ldap-parse-uri.c and ldap-parse-uri.h if USE_LDAP
24451         is TRUE.
24452         (module_tests): Only add t-ldap-parse-uri if USE_LDAP is TRUE.
24453         * dirmngr/ks-action.c: Only include "ldap-parse-uri.h" if USE_LDAP is
24454         TRUE.
24455         (ks_action_help): Don't invoke LDAP functionality if USE_LDAP is not
24456         TRUE.
24457         (ks_action_search): Likewise.
24458         (ks_action_get): Likewise.
24459         (ks_action_put): Likewise.
24460         * dirmngr/server.c: Only include "ldap-parse-uri.h" if USE_LDAP is
24461         TRUE.
24462         (cmd_keyserver): Don't invoke LDAP functionality if USE_LDAP is not
24463         TRUE.
24464
24465 2015-04-13  Werner Koch  <wk@gnupg.org>
24466
24467         common: Do without nested fucntions to support non-gcc.
24468         + commit 454f60399c7318fffd3de2afadd58c7a490178bd
24469         * common/t-stringhelp.c (test_strsplit): Remove nested function.
24470
24471 2015-04-11  Werner Koch  <wk@gnupg.org>
24472
24473         Release 2.1.3.
24474         + commit b1e1959d59a12b53c016ca9c95aee3a62c0bfc00
24475
24476
24477 2015-04-11  Yuri Chornoivan  <yurchor@ukr.net>
24478
24479         po: Update Ukrainian translation.
24480         + commit 896f438967b66b4836419aa737c706ced6b6454a
24481
24482
24483 2015-04-11  Ineiev  <ineiev@gnu.org>
24484
24485         po: Update and review Russian translation.
24486         + commit b69d7064f30c38ffe18e71de6a0fc14b5da0452f
24487
24488
24489 2015-04-10  Werner Koch  <wk@gnupg.org>
24490
24491         dirmngr,w32: Make it build for Windows.
24492         + commit c8bb5000d4c86a055348dc08352f573c599743a7
24493         * dirmngr/Makefile.am (t_common_ldadd): Add missing libs.
24494
24495         Remove obsolete directories from AM_CPPFLAGS.
24496         + commit 67158ff155ef52fd54a6bbe680551c0e12b31e69
24497
24498
24499         dirmngr,w32: Replace functions not available under Windows.
24500         + commit 0fb224c2c5e0c6770d4a6044d62d84f6bbc1b26b
24501         * dirmngr/ks-engine-ldap.c (extract_attributes): Replace isoptime and
24502         gmtime_r.
24503
24504         common: Add new function gnupg_gmtime.
24505         + commit 5d60c7f7e05a06e46e23bafe61cef09ad32aa998
24506         * common/gettime.c (gnupg_gmtime): New.
24507         (gnupg_get_isotime): Use it.  Also take care of an gmtime_t returning
24508         an error.
24509
24510         common: Add new function isodate_human_to_tm.
24511         + commit f6670100b7a15b2071c2e4062f5c5a678f2a30f6
24512         * common/gettime.c (isotime_human_p): Add arg date_only.
24513         (isodate_human_to_tm): New.
24514         * common/t-gettime.c (test_isodate_human_to_tm): New.
24515         (main): Call new test.
24516
24517         dirmngr,w32: Avoid name clash with existing function.
24518         + commit 6ad95fe6f1f130c8f6d139a9bd57fc4a0d38292b
24519         * dirmngr/ks-engine-ldap.c (ldap_connect): Rename to my_ldap_connect.
24520
24521         gpgparsemail: Fix last commit (3f2bdac)
24522         + commit 9433661419043431a6cfc7d84c8450e0b2f6c353
24523         * tools/rfc822parse.c (parse_field): Replace break by goto.
24524
24525 2015-04-09  Werner Koch  <wk@gnupg.org>
24526
24527         gpgparsemail: Fix case of zero length continuation lines.
24528         + commit 3fbeba64a8bfb2b673230c124a3d616b6568fd2f
24529         * tools/rfc822parse.c (parse_field): Loop after continuation line.
24530
24531 2015-04-08  Werner Koch  <wk@gnupg.org>
24532
24533         sm: Fix certificate lookup in dirmngr cache.
24534         + commit 6619ead2cfd2abcb95b66dc70622fdeef624fb8a
24535         * sm/call-dirmngr.c (get_cached_cert): Fix typo in LOOKUP command.
24536
24537 2015-04-06  Werner Koch  <wk@gnupg.org>
24538
24539         gpg: Print the user id in --fast-list-mode.
24540         + commit c2383407bba5eefea486464a31e02846124c9da5
24541         * g10/keylist.c (list_keyblock_print, list_keyblock_colon): Change.
24542
24543         gpg: Prepare to pass additional context to the list functions.
24544         + commit 67a58118ab6171c0cf28b65a39973062690d1313
24545         * g10/keylist.c (struct sig_stats): Rename to keylist_context and add
24546         field check_sigs.
24547         (keylist_context_release): New.
24548         (list_all): Set listctx.check_sigs and call release func.
24549         (list_one): Ditto.
24550         (locate_one): Ditto.
24551         (list_keyblock_print): Use .check_sigs field.  Repalce arg opaque by
24552         listctx.
24553         (list_keyblock): Ditto.  Make static.
24554         (list_keyblock_direct): New.
24555         * g10/keygen.c (do_generate_keypair): Replace list_keyblock by
24556         list_keyblock_direct.
24557
24558         gpg: Merge duplicated code for get_user_id et al.
24559         + commit f577d5c1a747d673fa1d5c012ce3e3b78b699c6a
24560         * g10/getkey.c (get_user_id_string): Add args mode and r_LEN.
24561         (get_user_id_string_native): Add new args.
24562         (get_long_user_id_string, get_user_id): Rewrite using
24563         get_user_id_string.
24564
24565         gpg: Add new option --debug-iolbf.
24566         + commit c581ed717ad2cc4be90c46253baa44a0d3ba5b80
24567         * g10/gpg.c (oDebugIOLBF): new.
24568         (opts): Add --debug-iolbf.
24569         (main): Set option.
24570
24571         Rename DBG_ASSUAN to DBG_IPC and add separate DBG_EXTPROG.
24572         + commit 24a75201da6be72edf85b96dbc0c01c747d02c6a
24573         * g10/options.h (DBG_EXTPROG_VALUE): Separate from DBG_IPC_VALUE.
24574
24575         Fix use of DBG_CACHE and DBG_LOOKUP.
24576         + commit 2f099eb62ac6491675bbcccaca4e076b2d8e7ea0
24577         * dirmngr/dirmngr.h (DBG_LOOKUP_VALUE): Change to 8192.
24578         * g10/options.h (DBG_LOOKUP_VALUE, DBG_LOOKUP): New.
24579         * g10/getkey.c: Use DBG_LOOKUP instead of DBG_CACHE at most places.
24580
24581         gpg: Rename a debug macro.
24582         + commit 4de8a58e44262a25564e2acef8c8865d1755982e
24583         * g10/options.h (DBG_CIPHER_VALUE): Rename to DBG_CRYPTO_VALUE.
24584         (DBG_CIPHER): Rename to DBG_CRYPTO.
24585
24586 2015-04-05  Werner Koch  <wk@gnupg.org>
24587
24588         gpg: Fix DoS while parsing mangled secret key packets.
24589         + commit d901efcebaefaf6eae4a9b9aa8f0c2c055d3518a
24590         * g10/parse-packet.c (parse_key): Check PKTLEN before calling mpi_read
24591         et al.
24592
24593 2015-04-03  NIIBE Yutaka  <gniibe@fsij.org>
24594
24595         g10: Fix keytocard.
24596         + commit f82c4a6d0d76e716b6a7b22ca964fa2da1f962a0
24597         g10/call-agent.h (agent_scd_learn): Add FORCE option.
24598         g10/call-agent.c (agent_scd_learn): Implement FORCE option.
24599         g10/keygen.c (gen_card_key): Follow the change of option.
24600         g10/card-util.c (change_pin, card_status, factory_reset): Likewise.
24601         g10/keyedit.c (keyedit_menu): Update private key storage by
24602         agent_scd_learn.
24603
24604         agent: Add --force option for LEARN.
24605         + commit 4ffadb74b3ada8a5d69ef8d87f4326df9bd97e97
24606         * agent/command.c (cmd_learn): Handle --force option.
24607         (cmd_keytocard): Don't update key storage file.
24608         * agent/agent.h (agent_handle_learn): Add FORCE.
24609         * agent/learncard.c (agent_handle_learn): Implement FORCE to update
24610         key stroage file.
24611
24612 2015-03-31  Neal H. Walfield  <neal@g10code.com>
24613
24614         dirmngr: Don't use alloca.
24615         + commit d0ff2ee04187fbedacbe4d3884ee75d957a0b8c6
24616         * dirmngr/ks-engine-ldap.c (ks_ldap_put): Replace use of alloca with
24617         xmalloc and xfree.
24618
24619         dirmngr: Simplify truncation of long strings in debug code.
24620         + commit 802eec0ca49b92104c92f18c9a6a04c34de74168
24621         * dirmngr/ks-engine-ldap.c (modlist_dump): Simplify truncation of long
24622         strings.
24623
24624         dirmngr: Use a better error code.
24625         + commit 7f6d7948c1e56e09c1bdaa5143e1b5558c4376dd
24626         * dirmngr/ldap-parse-uri.c (ldap_parse_uri): On error, return
24627         GPG_ERR_GENERAL, not GPG_ERR_ASS_GENERAL.
24628
24629         dirmngr: Better encapsulate the keyservers variable.
24630         + commit 348c520040a31f5c322183c0654a34978e2baf6f
24631         * dirmngr/dirmngr.h (struct server_control_s): Move field keyservers
24632         from here...
24633         * dirmngr/server.c (struct server_local_s): ... to here.  Update
24634         users.
24635         * dirmngr/ks-action.h (ks_action_resolve): Add argument keyservers.
24636         (ks_action_search): Likewise.
24637         (ks_action_get): Likewise.
24638         (ks_action_put): Likewise.
24639         * dirmngr/ks-action.c (ks_action_resolve): Add argument keyservers.
24640         Use it instead of ctrl->keyservers.
24641         (ks_action_search): Likewise.
24642         (ks_action_get): Likewise.
24643         (ks_action_put): Likewise.
24644
24645 2015-03-28  Neal H. Walfield  <neal@g10code.de>
24646
24647         gpg: Only use the last specified keyserver.
24648         + commit f26ba14028d34845ae10aae552b90681907e377d
24649         * g10/gpg.c (main): Only use the last specified keyserver.
24650
24651 2015-03-25  Werner Koch  <wk@gnupg.org>
24652
24653         dirmngr: Fix resource leaks and check rare errors.
24654         + commit bec10ae4b5a870303c800cdf3cd906044613fc2d
24655         * dirmngr/ks-engine-ldap.c (keyspec_to_ldap_filter): Fix resource
24656         leak.
24657         (ks_ldap_search): Check error from es_fopenmem.  Use LDAP_ERR where
24658         required.
24659         (modlist_dump): Check error from es_fopenmem.
24660         (uncescape): s/int/size_t/.  Use existing macros.
24661         (extract_attributes): Use existing trim function.
24662         (ks_ldap_put): Do not segv on error from modlist_dump.
24663
24664         dirmngr: Minor cleanups.
24665         + commit 6c701af121782c2feb4ee51e559a7420df00471f
24666         * dirmngr/ks-engine-ldap.c [__riscos__]: Remove doubled util.h.
24667         (ldap_to_gpg_err): s/GPG_ERR_GENERAL/GPG_ERR_INTERNAL/.
24668         (tm2ldaptime): Use snprintf.
24669         (ldap_connect): Get error code prior to log_error and and use modern
24670         function.   Use xfree, xtrustrdup etc.
24671         (modlist_lookup): Use GNUPG_GCC_A_USED.
24672         (modlist_free): Use xfree.
24673
24674         common: Add macro GNUPG_GCC_A_USED.
24675         + commit 99ef9cd7f589b51921bfbe8d52735c104ef260e3
24676         * common/util.h (GNUPG_GCC_A_USED): New.
24677
24678         sm: Change default algos to SHA256 (CSR) and AES128 (bulk encryption).
24679         + commit 1e4d8ddbe3ad7ee8f1c1d1798694d91f792776c0
24680         * sm/certreqgen.c (create_request): Change default hash algo.
24681         * sm/gpgsm.c (DEFAULT_CIPHER_ALGO): Change default bulk cipher algo.
24682
24683 2015-03-24  Werner Koch  <wk@gnupg.org>
24684
24685         gpg,w32: Handle forward slash in --keyring option.
24686         + commit bdd22e3a0846d38a0b6cdb822476ad2f15d03455
24687         * g10/keydb.c (keydb_add_resource): Allow forward slash under Windows.
24688
24689 2015-03-23  Neal H. Walfield  <neal@g10code.de>
24690
24691         Improve documentation for ks_hkp_get.
24692         + commit 7a56b6b3aa8b7a07bd80a3fcd5114bd1af359fa3
24693         * dirmngr/ks-engine-hkp.c (ks_hkp_get): Improvement documentation.
24694
24695         Improve documenation of http_parse_uri.
24696         + commit 00a16cf49336ee0b4ce21eb05a79db955af053e0
24697         * common/http.c (http_parse_uri): Improve documentation.
24698
24699         Add support to talking to LDAP key servers.
24700         + commit 51341badb623927f2a358588c725a356fc77dbe7
24701         * g10/call-dirmngr.c (record_output): New function.
24702         (ks_put_inq_cb): Use it here to generate a --with-colons like output
24703         instead of a custom format.
24704         * dirmngr/ks-action.c: Include "ldap-parse-uri.h".
24705         (ks_action_help): If the provided URI is an LDAP URI, then use
24706         ldap_parse_uri to parse.  Call ks_ldap_help.
24707         (ks_action_search): If passed an LDAP URI, then call ks_ldap_search.
24708         (ks_action_get): Likewise.
24709         (ks_action_put): Likewise.  Also, change data from a 'const void *' to
24710         a 'void *' and add info and infolen parameters.  Add note that
24711         function may modify DATA.
24712         * dirmngr/ks-action.h (ks_action_put): Update declaration accordingly.
24713         * dirmngr/server.c: Include "ldap-parse-uri.h".
24714         (cmd_keyserver): If ITEM->URI is an LDAP URI, parse it using
24715         ldap_parse_uri.
24716         (hlp_ks_put): Improve documentation.
24717         (cmd_ks_put): Also pass info and infolen to ks_action_put.  Improve
24718         documentation.
24719         * dirmngr/ks-engine.h (ks_ldap_help): New declaration.
24720         (ks_ldap_search): Likewise.
24721         (ks_ldap_get): Likewise.
24722         (ks_ldap_put): Likewise.
24723         * dirmngr/ks-engine-ldap.c: New file.
24724         * dirmngr/Makefile.am (dirmngr_SOURCES): Add ks-engine-ldap.c,
24725         ldap-parse-uri.c and ldap-parse-uri.h.
24726         (dirmngr_LDADD) [USE_LDAP]: Add $(ldaplibs).
24727
24728         Import _gpgme_parse_timestamp from gpgme as parse_timestamp.
24729         + commit 81e83060856f02f6cfc7b48f8032e0cf14fc6c68
24730         * common/gettime.h (parse_timestamp): New declaration.
24731         * common/gettime.c (_win32_timegm): New function imported from
24732         gpgme/src/conversion.c:_gpgme_timegm.
24733         (parse_timestamp): New function imported from
24734         gpgme/src/conversion.c:_gpgme_parse_timestamp.
24735
24736         Move copy_stream function to misc.c.
24737         + commit 9e79a15f74c428624b0049a3f6a077c1bc7c731d
24738         * dirmngr/ks-action.c (copy_stream): Move function from here...
24739         * dirmngr/misc.c (copy_stream): ... to here and drop the static
24740         qualifier.
24741         * dirmngr/misc.h (copy_stream): Add declaration.
24742
24743         Move armor_data to misc.c.
24744         + commit 63552852bf191985b4b55aa524bc397c5b1d1515
24745         * dirmngr/ks-engine-hkp.c (armor_data): Move function from here...
24746         * dirmngr/misc.c (armor_data): ... to here and drop static qualifier.
24747         * dirmngr/misc.h: New declaration.
24748
24749         Add new LDAP utility functions.
24750         + commit 1a75b7c39f0a84f518711438565645a34fb2673f
24751         * dirmngr/Makefile.am (module_tests): New variable.
24752         (noinst_PROGRAMS): New primary.  Set it to $(module_tests).
24753         (TESTS): New variable.  Set it to $(module_tests).
24754         (t_common_src): New variable.
24755         (t_common_ldadd): Likewise.
24756         (t_ldap_parse_uri_SOURCES): New primary.
24757         (t_ldap_parse_uri_LDADD): Likewise.
24758         * dirmngr/ldap-parse-uri.c: New file.
24759         * dirmngr/ldap-parse-uri.h: Likewise.
24760         * dirmngr/t-ldap-parse-uri.c: Likewise.
24761         * dirmngr/t-support.h: Likewise.
24762
24763         Add new function uri_query_lookup.
24764         + commit e23b3ba5ffd3134a72da176a039e4d6c4f3ff595
24765         * common/http.h (uri_query_lookup): New declaration.
24766         * common/http.c (uri_query_lookup): The corresponding implementation.
24767
24768         Add new function strlist_find.
24769         + commit 79907ad256f5b84f36cbebdc92e5a05d9e266557
24770         * common/strlist.h (strlist_find): New declaration.
24771         * common/strlist.c (strlist_find): New function.
24772
24773         common: Add new helper function, strsplit.
24774         + commit b18ffcb81a3839dbf09603d70ebb8b80f65892d3
24775         * common/stringhelp.h (strsplit): New declaration.
24776         * common/stringhelp.c (strsplit): New function.
24777         * common/t-stringhelp.c (test_strsplit): New function.
24778         (main): Call it here.
24779
24780 2015-03-20  Werner Koch  <wk@gnupg.org>
24781
24782         gpg: Consider a mailbox only userid in mail search mode.
24783         + commit bebab54027d8c63574a2680c60481cfe9b88c240
24784         * kbx/keybox-search.c: Include mbox-util.h.
24785         (blob_cmp_mail): Improve OpenPGP uid parsing.
24786
24787         common: Add function is_valid_mailbox_mem.
24788         + commit a0eb2e4e8cef9ca6a5dfbae6440fa6cd583d0805
24789         * common/mbox-util.c (mem_count_chr): New.
24790         (my_memstr): New.
24791         (has_invalid_email_chars): Change args to work on a buffer.
24792         (is_valid_mailbox_mem): New.
24793         (is_valid_mailbox): Rewrite to use is_valid_mailbox_mem.
24794
24795         gpg: Find keys using mail addresses with garbage after the '>'
24796         + commit 783a4a98378fa1aa222d5cb7427dd37151feb08b
24797         * kbx/keybox-search.c (blob_cmp_mail): Stop comparing at the '>'.
24798
24799         common: Fix syntax error when building with gnutls.
24800         + commit 5136e39c6466de90697153ea253c4b540c1f7d1a
24801         * common/http.c (send_request): Add missing comma.
24802
24803 2015-03-19  Werner Koch  <wk@gnupg.org>
24804
24805         gpg: Emit status line NEWSIG before signature verification starts.
24806         + commit e7ddaad0fd2c8774a1d3367adfaa68014eaf65de
24807         * g10/mainproc.c (check_sig_and_print): Emit STATUS_NEWSIG.
24808
24809         agent: Compute correct MPI length header for protected ECC keys.
24810         + commit cf83ff01fce3ddcbde6d97dffa0db6f277588e25
24811         * agent/cvt-openpgp.c (apply_protection): Strip leading zeroes from
24812         opaque MPIs to comply with the OpenPGP spec.
24813
24814         hkps: Fix host name verification when using pools.
24815         + commit dc10d466bff53821f23d2cb4814c259d40c5d9c5
24816         * common/http.c (send_request): Set the requested for SNI.
24817         * dirmngr/ks-engine-hkp.c (map_host): Return the poolname and not
24818         the selecting a host.
24819
24820         Define replacement error codes from libgpg-error 1.19.
24821         + commit 28bb3ab686c1c994f67a92b6846b3726c58a0bc3
24822         * common/util.h: Add GPG_ERR_LDAP codes for libgpg-error < 1.19.
24823
24824 2015-03-17  Andre Heinecke  <aheinecke@intevation.de>
24825
24826         gpgtar: Fix extracting files with !(size % 512)
24827         + commit 6cbbb0bec98e1acefc4c7163cc41a507469db920
24828         * tools/gpgtar-extract.c (extract_regular): Handle size multiples
24829           of RECORDSIZE.
24830
24831 2015-03-17  Werner Koch  <wk@gnupg.org>
24832
24833         common: Add feature to ease using argparse's usage().
24834         + commit 9078b75a73600fc6b7b5502ceee8de032bb9c446
24835         * common/argparse.c (show_help): Take care of flag value
24836         (usage): Ditto.
24837
24838         common: Allow standalone build of argparse.c.
24839         + commit eb5f2c0af6691229300ac120ee44815cb27ed38e
24840         * common/argparse.h: Remove types.h - not required.
24841         * common/argparse.c: Change to allow standalone use.
24842
24843 2015-03-16  Werner Koch  <wk@gnupg.org>
24844
24845         gpg: Create all MPIs with RFC-4880 correct length headers.
24846         + commit ab17f7b6c392782718f57eaea94fc18a0ff49389
24847         * g10/build-packet.c (gpg_mpi_write): Strip leading zeroes.
24848
24849         gpg: Allow printing of MPI values in --list-mode.
24850         + commit bcc8250bc5b9a357c6d1444f03e334edec573ede
24851         * g10/parse-packet.c (set_packet_list_mode): Set mpi_print_mode.
24852         * g10/misc.c (mpi_print): Do not print an extra leading zero.
24853
24854         gpg: Fix broken write of opaque MPI length header.
24855         + commit 8bc1debfefb7cd4b0be724317793d59dea37d677
24856         * g10/build-packet.c (gpg_mpi_write): Use a char array for the length.
24857
24858 2015-03-15  Werner Koch  <wk@gnupg.org>
24859
24860         gpg: Fix possible dead code elimination.
24861         + commit 1a9f13bc663daa75c5009f6a0bf7d7483f12cce0
24862         * g10/encrypt.c: Change condition for detecting a real file.
24863
24864         g13: Fix pointer wrap check.
24865         + commit 4bc3a2e954afc2ba7dbe79ba5f740184b7d4cd73
24866         * g13/utils.c (find_tuple, next_tuple): Cast pointer to size_t before
24867         doing an overflow check.
24868
24869         agent: Remove useless conditions in command.c.
24870         + commit 3a35c9740ab792068ec4b3732ecfaa17bf4fc7f0
24871         * agent/command.c (cmd_setkeydesc): Remove NULL check.
24872         (cmd_get_passphrase): Ditto.
24873         (cmd_clear_passphrase): Ditto.
24874         (cmd_get_confirmation): Ditto.
24875         (cmd_getval): Ditto.
24876         (cmd_putval): Ditto.
24877
24878         agent: Fix length test in sshcontrol parser.
24879         + commit 3529dd8bb5bafc4e02915648d5f409bd27a9cc37
24880         * agent/command-ssh.c (ssh_search_control_file): Check S before
24881         upcasing it.
24882
24883         agent: Remove useless conditions.
24884         + commit 95415bdec77a608e6052ba3e2a5d857a8e8f7689
24885         * agent/genkey.c (agent_ask_new_passphrase): Remove useless condition.
24886         * agent/command-ssh.c (ssh_identity_register): Ditto.
24887
24888         gpg: Remove useless condition.
24889         + commit c59b410cf1d5676de7061e5a183c01227aa8e760
24890         * g10/keylist.c (list_keyblock_colon): Remove useless condition (PK).
24891         (list_keyblock_print):  Likewise.
24892
24893         scd: Fix possible NULL deref in apdu.c.
24894         + commit ef0a3abf7305133d071bf1a94a7f461082f9a9aa
24895         * scd/apdu.c (control_pcsc_direct): Take care of BUFLEN being NULL.
24896         (control_pcsc_wrapped): Ditto.
24897
24898         common: Make openpgp_oid_to_str more robust.
24899         + commit 35db798c2df7f31b52a9dd9d55ea60ae1f325be9
24900         * common/openpgp-oid.c (openpgp_oid_to_str): Take care of
24901         gcry_mpi_get_opaque returning NULL.  Remove useless condition !BUF.
24902
24903 2015-03-11  Werner Koch  <wk@gnupg.org>
24904
24905         agent: Improve error reporting from Pinentry.
24906         + commit efde50f92af241d8357db83e280a6ece62f6397f
24907         * agent/call-pinentry.c (unlock_pinentry): Add error logging.  Map
24908         error source of uncommon errors to Pinentry.
24909
24910 2015-03-10  Werner Koch  <wk@gnupg.org>
24911
24912         gpg: Change --print-pka-records into an option.
24913         + commit 7b5b52f3268b093eebbac3f199fb69bf246d9cd1
24914         * g10/gpg.c (aPrintPKARecords): Rename to oPrintPKARecords and do not
24915         use it as a command.
24916         * g10/keylist.c (list_keyblock): List PKA rceords also for secret
24917         keys.
24918
24919         gpg: Add --list-gcrypt-config and "curve" item for --list-config.
24920         + commit 14af2be022ccaf826db048fc16959d0222ff1134
24921         * common/openpgp-oid.c (curve_supported_p): New.
24922         (openpgp_enum_curves): New.
24923         * common/t-openpgp-oid.c (test_openpgp_enum_curves): New.
24924         (main): Add option --verbose.
24925         * g10/gpg.c (opts): Add --list-gcrypt-config.
24926         (list_config): Add items "curve" and "curveoid".  Remove unused code.
24927
24928 2015-03-09  NIIBE Yutaka  <gniibe@fsij.org>
24929
24930         scd: fix for 64-bit arch.
24931         + commit bb5a1b7c738d74d5b46340ec7b50000a2d343ca9
24932         * agent/pksign.c (agent_pksign_do): Use int.
24933         * scd/app-openpgp.c (get_public_key): Likewise.
24934
24935 2015-03-04  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
24936
24937         gpg: avoid chatter about trustdb when --quiet.
24938         + commit 82146af85b65498a69b28913593dc1ffeb6b6fed
24939         * g10/trustdb.c (tdb_check_trustdb_stale): avoid log_info() when
24940           opt.quiet
24941
24942 2015-02-26  Werner Koch  <wk@gnupg.org>
24943
24944         gpg: Lowercase mailbox for PKA lookups.
24945         + commit c071be698efadef1ad01fd3d329d1b486a372927
24946         * common/stringhelp.c (ascii_strlwr): New.
24947         * common/mbox-util.c (mailbox_from_userid): Downcase result.
24948
24949         gpg: Fix memory leak due to PKA lookup.
24950         + commit 91baea2dcde6c1e5ca9e8fa7020d9ab4551d1bca
24951         * g10/keyserver.c (keyserver_import_pka): Move the xfree.
24952
24953 2015-02-25  Werner Koch  <wk@gnupg.org>
24954
24955         gpg: Switch to a hash and CERT record based PKA system.
24956         + commit 2fc27c8696f5cf2ddf3212397ea49bff115d617b
24957         * common/dns-cert.c (get_dns_cert): Make r_key optional.
24958         * common/pka.c: Rewrite for the new hash based lookup.
24959         * common/t-pka.c: New.
24960         * configure.ac: Remove option --disable-dns-pka.
24961         (USE_DNS_PKA): Remove ac_define.
24962         * g10/getkey.c (parse_auto_key_locate): Always include PKA.
24963
24964         common: Allow requesting a specific certtype with get_dns_cert()
24965         + commit af60152a4632ef26ca950a424429b15b6c69038d
24966         * common/dns-cert.c (get_dns_cert): Add arg want_certtype.  Change all
24967         callers.
24968         (CERTTYPE_): Move constants to ...
24969         * common/dns-cert.h: here as DNS_CERTTYPE_.
24970
24971         Move new mailbox.c source file to common/.
24972         + commit 9913253610bac69e9503800e85696491e018e327
24973         * g10/mailbox.c: Move to ...
24974         * common/mbox-util.c: new file.
24975         * common/mbox-util.h: New. Include where needed.
24976         * g10/t-mailbox.c: Move to ...
24977         * common/t-mbox-util.c: new file.
24978
24979 2015-02-24  Werner Koch  <wk@gnupg.org>
24980
24981         gpg: Add command --print-pka-records.
24982         + commit e2d93402801a2cb822c723e891fd98233fdb3fd5
24983         * g10/gpg.c (main): Add command --print-pka-records.
24984         * g10/options.h (struct opt): Add field "print_pka_records".
24985         * g10/keylist.c (list_keyblock_pka): New.
24986         (list_keyblock): Call it if new option is set.
24987         (print_fingerprint): Add mode 10.
24988
24989         gpg: Add function to extract the mailbox.
24990         + commit 93fa3d5c1760f3fee5412fb29d58fbd60db16ea9
24991         * g10/misc.c (has_invalid_email_chars, is_valid_mailbox)
24992         (is_valid_user_id): Move to ...
24993         * g10/mailbox.c: new file.
24994         (string_has_ctrl_or_space, has_dotdot_after_at): New.
24995         (has_invalid_email_chars): New.
24996
24997         * g10/t-mailbox.c: New.
24998         * g10/Makefile.am (module_tests): Add t-mailbox.
24999         (t_mailbox_SOURCES, t_mailbox_LDADD): New.
25000
25001 2015-02-23  Werner Koch  <wk@gnupg.org>
25002
25003         gpg: Add option to print fingerprints in ICAO spelling.
25004         + commit ae09515b9d3aae653b62a32ea5b4a9b9e557fc52
25005         * g10/gpg.c: Add option --with-icao-spelling.
25006         * g10/options.h (struct opt): Add with_icao_spelling.
25007         * g10/keylist.c (print_icao_hexdigit): New.
25008         (print_fingerprint): Print ICAO spelling.
25009
25010         gpg: Skip legacy keys while searching keyrings.
25011         + commit a8116aacd91b7e775762a62c268fab6cc3c77438
25012         * g10/getkey.c (search_modes_are_fingerprint): New.
25013         (lookup): Skip over legacy keys.
25014
25015         common: Fix regression due to commit 2183683b.
25016         + commit d9f6eea6115df7959564123eb99d633ce5bba42e
25017         * common/dns-cert.c (get_dns_cert): Remove cruft.
25018
25019 2015-02-19  Werner Koch  <wk@gnupg.org>
25020
25021         gpg: Replace remaining uses of stdio by estream.
25022         + commit d2a70fd8348d6c11d1960caf2afe0701833dad6a
25023         * g10/sign.c (sign_file):  Use log_printf instead of stderr.
25024         * g10/tdbdump.c (export_ownertrust): Use estream fucntions.
25025         (import_ownertrust): Ditto.
25026         * g10/tdbio.c (tdbio_dump_record): Ditto.  Change arg to estream_t.
25027
25028         gpg: Fix segv due to NULL value stored as opaque MPI.
25029         + commit 76c8122adfed0f0f443cce7bda702ba2b39661b3
25030         * g10/build-packet.c (gpg_mpi_write): Check for NULL return from
25031         gcry_mpi_get_opaque.
25032         (gpg_mpi_write_nohdr, do_key): Ditto.
25033         * g10/keyid.c (hash_public_key): Ditto.
25034
25035 2015-02-12  Werner Koch  <wk@gnupg.org>
25036
25037         scd: Fix regression in 2.1.2 (due to commit 2183683)
25038         + commit 07a71da479daaac43b8c5b1034a1e66f96bdbc48
25039         * scd/apdu.c (pcsc_vendor_specific_init): Replace use of
25040         bufNN_to_uint by direct code.
25041
25042 2015-02-12  Andre Heinecke  <aheinecke@intevation.de>
25043
25044         dirmngr: Initialize cache from sysconfig dir.
25045         + commit 070d7bf940efa60db2b0734273b9b3736d18338a
25046         * dirmngr/certcache.c (cert_cache_init): Load certificates
25047         from sysconfig dir instead of the homeidr.
25048         * dirmngr/dirmngr.c (main): Removed parsing of obsolete
25049         homedir_data option.
25050         * dirmngr/dirmngr.h (opt): Removed homedir_data.
25051         * doc/dirmngr.texi: Update and clarify certs directory doc.
25052
25053 2015-02-11  Werner Koch  <wk@gnupg.org>
25054
25055         Release 2.1.2.
25056         + commit fc17562cc4f8d531ae7f0887cf2a96dcc224b021
25057
25058
25059         dirmngr: Avoid warning about unused function.
25060         + commit 8219c87c301ec669f07528e8d8108655f7b705be
25061         * dirmngr/dirmngr.c (my_gnutls_log): Build only if gnutls is used.
25062
25063         build: Update standard build-aux files.
25064         + commit 81e93e251e52e427a29556de75640c7933bb5aad
25065
25066
25067         Use inline functions to convert buffer data to scalars.
25068         + commit 2183683bd633818dd031b090b5530951de76f392
25069         * common/host2net.h (buf16_to_ulong, buf16_to_uint): New.
25070         (buf16_to_ushort, buf16_to_u16): New.
25071         (buf32_to_size_t, buf32_to_ulong, buf32_to_uint, buf32_to_u32): New.
25072
25073 2015-02-09  Werner Koch  <wk@gnupg.org>
25074
25075         gpg: Prevent an invalid memory read using a garbled keyring.
25076         + commit f0f71a721ccd7ab9e40b8b6b028b59632c0cc648
25077         * g10/keyring.c (keyring_get_keyblock): Whitelist allowed packet
25078         types.
25079         * g10/keydb.c (parse_keyblock_image): Ditto.
25080
25081         gpg: Fix a NULL-deref in export due to invalid packet lengths.
25082         + commit 0835d2f44ef62eab51fce6a927908f544e01cf8f
25083         * g10/build-packet.c (write_fake_data): Take care of a NULL stored as
25084         opaque MPI.
25085
25086         gpg: Fix a NULL-deref due to empty ring trust packets.
25087         + commit 39978487863066e59bb657f5fe4e8baab510da7e
25088         * g10/parse-packet.c (parse_trust): Always allocate a packet.
25089
25090 2015-02-04  Werner Koch  <wk@gnupg.org>
25091
25092         gpg-agent: Use "pinentry-basic" as fallback.
25093         + commit 0de5c6a9a783ed9dc69cecbf34eadcaace4be243
25094         * common/homedir.c (get_default_pinentry_name): New.
25095         (gnupg_module_name): Use that for the default pinentry.
25096         (gnupg_module_name_flush_some): New.
25097         * agent/gpg-agent.c (agent_sighup_action): Flush some module names.
25098         * agent/call-pinentry.c (start_pinentry): Do not modify
25099         opt.pinentry_program.
25100
25101         w32: Add manifest to gpg.
25102         + commit 05428d12561bc7eb872a81444918dfe706477a41
25103         * g10/gpg.w32-manifest.in: New.
25104         * g10/gpg-w32info.rc: Add manifest.
25105         * g10/Makefile.am (EXTRA_DIST): Add manifest.
25106         (gpg-w32info.o): Depend on manifest.
25107         * configure.ac (BUILD_VERSION): New.
25108         (AC_CONFIG_FILES): Add manifest.
25109
25110 2015-02-03  Werner Koch  <wk@gnupg.org>
25111
25112         Update copyright years.
25113         + commit 3f67426a89bf4b37e1d2662fddc3eb4fa474c4ad
25114         * common/w32info-rc.h.in (W32INFO_COMPANYNAME): Change to "The GnuPG
25115         Project".
25116
25117 2015-02-02  Werner Koch  <wk@gnupg.org>
25118
25119         w32: Change default Windows install dir and add bin to PATH.
25120         + commit 8872657b2a52dd9698224b80e5672e23c5405eda
25121         * build-aux/speedo.mk (WITH_GUI): New macro.  The Windows installer is
25122         now build by default without any GUI stuff.
25123         * build-aux/speedo/w32/inst.nsi: Change standard installation
25124         directory.
25125         (AddToPath, un.RemoveFromPath): New.
25126         (gnupginst): Add bin directory to the PATH.
25127
25128 2015-02-01  Werner Koch  <wk@gnupg.org>
25129
25130         w32: Allow for Unicocde installation directory.
25131         + commit 616633b7713081ecc39419494879947cc7f163d0
25132         * common/homedir.c (w32_rootdir): Use Unicode fucntion not only for
25133         WinCE.
25134
25135 2015-01-30  Joshua Rogers  <git@internot.info>
25136
25137         kbx: Fix resource leak.
25138         + commit 7db6c82cec49b7c56c403a8ea98364086baf75f3
25139         * kbx/keybox-update.c (blob_filecopy): Fix resource leak.  On error
25140         return, 'fp' and 'newfp' was never closed.
25141
25142 2015-01-29  Werner Koch  <wk@gnupg.org>
25143
25144         agent: Fix use of imported but unprotected openpgp keys.
25145         + commit 6ab0fac575a8b04152a199cb300a08436b096753
25146         * agent/agent.h (PRIVATE_KEY_OPENPGP_NONE): New.
25147         * agent/command.c (do_one_keyinfo): Implement it.
25148         * agent/findkey.c (agent_key_from_file): Ditto.
25149         (agent_key_info_from_file): Ditto.
25150         (agent_delete_key): Ditto.
25151         * agent/protect.c (agent_private_key_type): Add detection for openpgp
25152         "none" method.
25153
25154 2015-01-29  NIIBE Yutaka  <gniibe@fsij.org>
25155
25156         po: Update Japanese Translation.
25157         + commit 6c368533f5211bed62e8638f522cef65c7ba4b87
25158
25159
25160 2015-01-28  Werner Koch  <wk@gnupg.org>
25161
25162         gpg: Limit the size of key packets to a sensible value.
25163         + commit 382ba4b137b42d5f25a7e256bb7c053ee5ac7b64
25164         * g10/parse-packet.c (MAX_KEY_PACKET_LENGTH): New.
25165         (MAX_UID_PACKET_LENGTH): New.
25166         (MAX_COMMENT_PACKET_LENGTH): New.
25167         (MAX_ATTR_PACKET_LENGTH): New.
25168         (parse_key): Limit the size of a key packet to 256k.
25169         (parse_user_id): Use macro for the packet size limit.
25170         (parse_attribute): Ditto.
25171         (parse_comment): Ditto.
25172
25173         gpg: Fix buffering problem in --list-config.
25174         + commit d8eea25b8b7becbfa3f059be6f5966a2f1aa7112
25175         * g10/gpg.c (list_config): Replace print_sanitized_string2 by
25176         es_write_sanitized.
25177
25178         * common/stringhelp.c (print_sanitized_buffer2): Remove.
25179         (print_sanitized_buffer, print_sanitized_utf8_buffer): Remove.
25180         (print_sanitized_utf8_buffer, print_sanitized_utf8_string): Remove.
25181         (print_sanitized_string): Remove.
25182
25183         * sm/certdump.c (print_dn_part, print_dn_parts): Remove arg FP.
25184         (pretty_print_sexp, gpgsm_print_name2, gpgsm_print_name): Remove.
25185
25186         Add a hook to be called right after main.
25187         + commit 0c2bfd9d5a49a6134188f8f7820f6ccdebd9f181
25188         * common/init.c (early_system_init): New stub function.
25189
25190         gpg: Allow predefined names as answer to the keygen.algo prompt.
25191         + commit b1d5ed6ac842469afcb84868d0f6641dc286a6c7
25192         * g10/keygen.c (ask_algo): Add list of strings.
25193
25194         agent: Add some extra robustness to extract_private_key.
25195         + commit 795965437732e50f6216d7f5db0e6174e90548a9
25196         * agent/cvt-openpgp.c (extract_private_key): Add arg "arraysize".
25197         Make sure that R_FLAGS and R_CURVE are set to NULL.
25198
25199 2015-01-28  NIIBE Yutaka  <gniibe@fsij.org>
25200
25201         scd: Fix varargs call for 64-bit arch on ECC keys.
25202         + commit f6d3c6e5263d84b94ebe13df9ff39b02109a2acb
25203         * scd/app-openpgp.c (store_fpr): Remove CARD_VERSION from the
25204         arguments.
25205         (rsa_writekey): Follow the change.
25206         (do_genkey): Likewise.
25207         (ecc_writekey): Likewise.  Cast to size_t.
25208
25209 2015-01-27  Werner Koch  <wk@gnupg.org>
25210
25211         gpg: Fix segv introduced to commit 4d7c9b0.
25212         + commit 6eebc56687935f3e993eac374b9f4cc5ad3bcf2b
25213         * g10/keygen.c (get_parameter_passphrase): Take care of R == NULL.
25214
25215 2015-01-27  NIIBE Yutaka  <gniibe@fsij.org>
25216
25217         agent: Fix agent_public_key_from_file for ECC.
25218         + commit 9453d645d4a489f038829c80343c124fff62d635
25219         * agent/cvt-openpgp.c (extract_private_key): New.
25220         (convert_to_openpgp): Use extract_private_key.
25221         * agent/findkey.c (agent_public_key_from_file): Use
25222         extract_private_key.
25223
25224 2015-01-26  Werner Koch  <wk@gnupg.org>
25225
25226         sm: Simplify fix ed8383c6.
25227         + commit 6c87d1ce66d8e93e6c0f16c06116e9179f6158ba
25228         * sm/minip12.c (p12_build): Release PWBUF only at the end.
25229
25230 2015-01-25  Joshua Rogers  <git@internot.info>
25231
25232         ccid: Remove incorrect expression leading to errors.
25233         + commit 274d7b17a90908a90ba6ad295c08a79b287fc231
25234         * scd/ccid-driver.c (send_escape_cmd): Fix setting of 'rc'.
25235
25236 2015-01-23  Werner Koch  <wk@gnupg.org>
25237
25238         gpgconf: Fix validity check for UINT32 values.
25239         + commit 3f6abb57a7b5e54b593c5775c8f7a07d61119705
25240         * tools/gpgconf-comp.c (option_check_validity): Enable check for
25241         UINT32.
25242
25243 2015-01-22  Werner Koch  <wk@gnupg.org>
25244
25245         gpg: Improve skipping of PGP-2 keys.
25246         + commit 09e8f35d3808d6e49f891360c341aae3869e8650
25247         * g10/keydb.c (keydb_search_first, keydb_search_next): Skip legacy
25248         keys.
25249         * g10/keyring.c (keyring_get_keyblock): Handle GPG_ERR_LEGACY_KEY.
25250         (prepare_search): Ditto.
25251         (keyring_rebuild_cache): Skip legacy keys.
25252         * g10/keyserver.c (keyidlist): Ditto.
25253         * g10/trustdb.c (validate_key_list): Ditto.
25254
25255         gpg: Add dedicated error code for PGP-2 keys.
25256         + commit 6f3d11d8837b00e3a1c4fa881066855c0321d6b2
25257         * g10/parse-packet.c (parse_key): Return GPG_ERR_LEGACY_KEY for PGP2
25258         keys.
25259         * g10/import.c (read_block): Simplify by checking GPG_ERR_LEGACY_KEY.
25260         * g10/getkey.c (lookup): Silence error message for PGP-2 keys.
25261
25262         * common/util.h (GPG_ERR_LEGACY_KEY): Add replacement for older
25263         libgpg-error.
25264
25265         gpg: Replace remaining old error code macros by GPG_ERR_.
25266         + commit 11142e0ad7bc9a9e3c3dccf958d8dbd3312cb993
25267         * g10/gpg.h (g10_errstr): Remove macro and change all occurrences by
25268         gpg_strerror.
25269         (G10ERR_): Remove all macros and change all occurrences by their
25270         GPG_ERR_ counterparts.
25271
25272         gpg: Remove an unused variable.
25273         + commit a23c30fb59c0a216763a7972028995d3be42a844
25274         * g10/getkey.c (getkey_ctx_s): Remove last_rc.
25275
25276 2015-01-21  Werner Koch  <wk@gnupg.org>
25277
25278         dirmngr: Fix TLS build problems.
25279         + commit 091c35ec726a4fa4691c2665b13adee6a34b5b66
25280         * dirmngr/Makefile.am (AM_CFLAGS): Add flags for TLS libs.
25281
25282         gpg: Support --passphrase with --quick-gen-key.
25283         + commit 4d7c9b0e9aceedd924d600978bc1b6cae7d5c456
25284         * g10/keygen.c: Include shareddefs.h.
25285         (quick_generate_keypair): Support static passphrase.
25286         (get_parameter_passphrase): New.
25287         (do_generate_keypair): Use it.
25288
25289         gpg: Re-enable the "Passphrase" parameter for batch key generation.
25290         + commit aa99ebde778b7b563f35025f1b48954757f840be
25291         * agent/command.c (cmd_genkey): Add option --inq-passwd.
25292         * agent/genkey.c (agent_genkey): Add new arg override_passphrase.
25293         * g10/call-agent.c (inq_genkey_parms): Handle NEWPASSWD keyword.
25294         (agent_genkey): Add arg optional arg "passphrase".
25295         * g10/keygen.c (common_gen, gen_elg, gen_dsa, gen_ecc)
25296         (gen_rsa, do_create): Add arg "passphrase" and pass it through.
25297         (do_generate_keypair): Make use of pPASSPHRASE.
25298         (release_parameter_list): Wipe out a passphrase parameter.
25299
25300 2015-01-19  Werner Koch  <wk@gnupg.org>
25301
25302         kbx: Minor cleanup for the previous fix.
25303         + commit 7be1b7d8017cb7ebf1a3855edec0ef5e342cc9c5
25304         * kbx/keybox-search.c (blob_get_keyid): Rename to
25305         blob_get_first_keyid. Check number of keys and remove blob type check.
25306
25307 2015-01-19  Damien Goutte-Gattat  <dgouttegattat@incenp.org>
25308
25309         kbx: Call skipfnc callback to filter out keys.
25310         + commit c5956592c171e6fe988e74161aa99636b7f12e4b
25311         * kbx/keybox-search.c (blob_get_keyid): New.
25312         (keybox-search): Call skipfnc callback function.
25313
25314 2015-01-13  Andreas Schwier  <andreas.schwier@cardcontact.de>
25315
25316         scd: Allow for certificates > 1024 with PC/SC.
25317         + commit 16a1330fa16f6b23e2661c0175c431ab40da45ff
25318         * scd/pcsc-wrapper.c (handle_transmit): Enlarge buffer to 4096 too
25319         allow for larger certificates.
25320
25321 2015-01-08  NIIBE Yutaka  <gniibe@fsij.org>
25322
25323         dirmngr: Fix error code path of map_host.
25324         + commit 657a26f3af1b3f817d6cde2d091273d332571247
25325         * dirmngr/ks-engine-hkp.c (map_host): Fix error return.
25326
25327 2015-01-08  Joshua Rogers  <git@internot.info>
25328
25329         scd: fix get_public_key for OpenPGPcard v1.0.
25330         + commit 100b322f5da3066bab5a2b0eb234c631c581c0e4
25331         * scd/app-openpgp.c (get_public_key): correctly close 'fp' upon use.
25332
25333 2015-01-07  NIIBE Yutaka  <gniibe@fsij.org>
25334
25335         dirmngr: fix LDAP query PATTERNS limit check.
25336         + commit 22b15fccffe613f455f9748c048c8e451724a842
25337         * dirmngr/ldap.c (start_cert_fetch_ldap): fix ARGC limitation.
25338
25339         scd: fix merge failure.
25340         + commit 602f17b5a775f02e0e33a54d3155929dc00e4f53
25341         * scd/apdu.c (pcsc_pinpad_verify): Remove wrong lines inserted by
25342         merge.
25343
25344 2015-01-05  Werner Koch  <wk@gnupg.org>
25345
25346         sm,g13: Init local vars to avoid compiler warnings.
25347         + commit 9bf40849a9f86204e113712c4cc285f1ac16127a
25348         * sm/misc.c (transform_sigval): Init RSA_S_LEN.
25349         * g13/mount.c (read_keyblob): Init HEADERLEN.
25350
25351         gpg: Remove unused args from a function.
25352         + commit 616e511f278bf9af04dc66bbb8b05b37bf541f37
25353         * g10/keyserver.c (parse_keyserver_uri): Remove args configname and
25354         configlineno.  Change all callers.
25355
25356         gpg: Clear a possible rest of the KDF secret buffer.
25357         + commit 56e688823345bbcfef220b13eb418854f8798b16
25358         * g10/ecdh.c (pk_ecdh_encrypt_with_shared_point): Fix order of args.
25359
25360         build: Require automake 1.14.
25361         + commit 445bb17d5fe6b53db078082fb033dbc67eea8307
25362         * configure.ac (AM_INIT_AUTOMAKE): Add serial-tests.
25363
25364 2015-01-04  Werner Koch  <wk@gnupg.org>
25365
25366         agent: Make --allow-loopback-pinentry gpgconf changeable.
25367         + commit ac2cb47fc5c0be539aaa07fd141acdbc0934800f
25368
25369
25370 2014-12-22  Joshua Rogers  <git@internot.info>
25371
25372         tools: Free variable before return.
25373         + commit cf88337f8a4f8c98aca4b1da5921d18567b4f474
25374         * tools/gpgconf-comp.c: Free 'dest_filename' before it is returned
25375         upon error.
25376
25377 2014-12-22  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
25378
25379         sm: Avoid double-free on iconv failure.
25380         + commit ed8383c618e124cfa708c9ee87563fcdf2f4649c
25381         * sm/minip12.c: (p12_build) if jnlib_iconv_open fails, avoid
25382         double-free of pwbuf.
25383
25384         scd: Avoid double-free on error condition in scd.
25385         + commit b0b3803e8c2959dd67ca96debc54b5c6464f0d41
25386         * scd/command.c (cmd_readkey): avoid double-free of cert
25387
25388         avoid future chance of using uninitialized memory.
25389         + commit 367b073ab5f439ccf0750461d10c69f36998bd62
25390         * common/iobuf.c: (iobuf_open): initialize len
25391
25392         avoid double-close in unusual dotlock situations.
25393         + commit 628b111fa679612e23c0d46505b1ecbbf091897d
25394         * common/dotlock.c: (dotlock_create_unix) avoid double-close()
25395          in unusual situations.
25396
25397         gpgkey2ssh: clean up varargs.
25398         + commit 351bca9047d748c3c4f7e9a3cdc476af127b1da3
25399         * tools/gpgkey2ssh.c (key_to_blob) : ensure that va_end is called.
25400
25401 2014-12-22  Werner Koch  <wk@gnupg.org>
25402
25403         doc: Fix memory leak in yat2m.
25404         + commit 6056d2467310260ddc0db2fe65b737ace6febcaa
25405         * doc/yat2m.c (write_th): Free NAME.
25406
25407         dirmngr: Fix memory leak.
25408         + commit 5a556e4e88bcbc926c0922070acaf5f7b25d18fb
25409         * dirmngr/server.c (cmd_ks_search, cmd_ks_get): Fix memory leak.
25410
25411         * dirmngr/ks-engine-hkp.c (ks_hkp_mark_host): Remove double check.
25412
25413         dirmngr: Remove un-needed check.
25414         + commit 0d5cb55402c44fb5f731ecf85705f845f3091aa7
25415         * dirmngr/crlfetch.c (crl_fetch): Check that URL is not NULL.
25416
25417         dirmngr,gpgsm: Return NULL on fail.
25418         + commit abd5f6752d693b7f313c19604f0723ecec4d39a6
25419         * dirmngr/ldapserver.c (ldapserver_parse_one): Set SERVER to NULL.
25420         * sm/gpgsm.c (parse_keyserver_line): Ditto.
25421
25422 2014-12-22  NIIBE Yutaka  <gniibe@fsij.org>
25423
25424         scd: ECDH Support.
25425         + commit bdc8efbdd124d836c36cf482216e375421f72891
25426         * agent/divert-scd.c (divert_pkdecrypt): Support ECDH.
25427         * scd/app-openpgp.c (get_algo_byte, store_fpr): Support ECDH.
25428         (send_key_attr): Support ECDH.  Fix EdDSA algorithm value.
25429         (retrieve_key_material): Initialize fields.
25430         (get_public_key, ecc_writekey, do_writekey): Support ECDH.
25431         (ecdh_writekey): Remove.
25432         (do_decipher): Support ECDH.
25433         (parse_algorithm_attribute): Support ECDH.  Fix EdDSA.
25434
25435 2014-12-19  Werner Koch  <wk@gnupg.org>
25436
25437         agent: Make sure --max-cache-ttl is >= --default-cache-ttl.
25438         + commit 76140141699b545f7a988bf5fc101063917e8ce3
25439         * agent/gpg-agent.c (finalize_rereadable_options): New.
25440         (main, reread_configuration): Call it.
25441
25442         agent: Keep the session environment for restricted connections.
25443         + commit 14601eacb51f6c8a60d3d57aee1be11debd94c68
25444         * agent/command-ssh.c (setup_ssh_env): Move code to ...
25445         * agent/gpg-agent.c (agent_copy_startup_env): .. new function.  Change
25446         calllers.
25447         * agent/command.c (start_command_handler): Call that fucntion for
25448         restricted connections.
25449
25450         agent: Fix string prepended to remotely initiated prompts.
25451         + commit aad8963f7b9d13b319abd413db8f42ec467db913
25452         * agent/command.c (cmd_setkeydesc): Use %0A and not \n. Make
25453         translatable.
25454
25455 2014-12-18  Werner Koch  <wk@gnupg.org>
25456
25457         build: Remove option to build without agent.
25458         + commit abec64f3cb04e49ca48cc476a5830a920e2ebf8f
25459         * configure.ac (build-agent): Set to yes.
25460
25461 2014-12-17  Werner Koch  <wk@gnupg.org>
25462
25463         gpgconf: Exit with failure if --launch fails.
25464         + commit 5cb6df8996623c00eaa2a39e3037101585442f7e
25465         * tools/gpgconf-comp.c (gc_component_launch): Return an error code.
25466         * tools/gpgconf.c (main): Exit if launch failed.
25467
25468 2014-12-16  Werner Koch  <wk@gnupg.org>
25469
25470         Release 2.1.1.
25471         + commit 08c00cd4fe432d6852ad1d5c34a234c56aa3617c
25472
25473
25474         po: Update the German translation.
25475         + commit 4ba740bd4734c43e7876f6f6380cc5963789d510
25476
25477
25478 2014-12-16  Petr Pisar  <petr.pisar@atlas.cz>
25479
25480         po: Update Czech translation.
25481         + commit 30560491fe42562f4bbdb17d3213f7210f549a0f
25482
25483
25484 2014-12-16  Werner Koch  <wk@gnupg.org>
25485
25486         gpg: Show private DO information in the card status.
25487         + commit ce9212924039fba4e479760bba86c61b0d91c469
25488         * g10/call-agent.c (agent_release_card_info): Free private_do.
25489         (learn_status_cb): Parse PRIVATE-DO-n stati.
25490
25491 2014-12-16  Ineiev  <ineiev@gnu.org>
25492
25493         po: Update Russian translation.
25494         + commit 5ab5b3fa6921f08dd0a498fe0381735e803d01e3
25495
25496
25497 2014-12-16  Jedi  <jedi@jedi.org>
25498
25499         po: Update zh_TW translation.
25500         + commit 668dc6b32cb97608ef65b85d917c86f5aec896ce
25501
25502
25503 2014-12-15  Werner Koch  <wk@gnupg.org>
25504
25505         gpg: Add sub-command "factory-reset" to --card-edit.
25506         + commit dd65e21cb4934b40e6f2f7a8095f39fd6d9971bc
25507         * common/util.h (GPG_ERR_OBJ_TERM_STATE): New.
25508         * scd/iso7816.c (map_sw): Add this error code.
25509         * scd/app-openpgp.c (do_getattr): Return the life cycle indicator.
25510         * scd/app.c (select_application): Allow a return value of
25511         GPG_ERR_OBJ_TERM_STATE.
25512         * scd/scdaemon.c (set_debug): Print the DBG_READER value.
25513         * g10/call-agent.c (start_agent): Print a status line for the
25514         termination state.
25515         (agent_scd_learn): Make arg "info" optional.
25516         (agent_scd_apdu): New.
25517         * g10/card-util.c (send_apdu): New.
25518         (factory_reset): New.
25519         (card_edit): Add command factory-reset.
25520
25521         gpg: Fix regression in notation data regression.
25522         + commit fc9a35d2dec2f838abac831fd88dca494773e082
25523         * g10/misc.c (pct_expando): Reorder conditions for clarity.
25524         * g10/sign.c (write_signature_packets): Fix notation data creation.
25525
25526         gpg: Avoid extra LF in notaion data listing.
25527         + commit b4e402cb5c6d7fc507e8d5131969145b49640e50
25528         * g10/keylist.c (show_notation): Use log_printf.
25529
25530 2014-12-12  Werner Koch  <wk@gnupg.org>
25531
25532         scd: Fix possibly inhibited checkpin of the admin pin.
25533         + commit 68b4e7c9e4de0dc3580ca5af3cfd0f20a2691b5e
25534         * scd/app-openpgp.c (do_check_pin): Do not check a byte of a released
25535         buffer.
25536
25537         gpg: Let --card--status create a shadow key (card key stub).
25538         + commit f3f9f9b2844c35f7942ee904d5222523615cdad4
25539         * agent/command.c (cmd_learn): Add option --sendinfo.
25540         * agent/learncard.c (agent_handle_learn): Add arg "send" andsend
25541         certifciate only if that is set.
25542         * g10/call-agent.c (agent_scd_learn): Use --sendinfo.  Make INFO
25543         optional.
25544         (agent_learn): Remove.
25545         * g10/keygen.c (gen_card_key): Replace agent_learn by agent_scd_learn.
25546
25547         gpg: Fix possible read of unallocated memory.
25548         + commit 193815030d20716d9a97850013ac3cc8749022c9
25549         * g10/parse-packet.c (can_handle_critical): Check content length
25550         before calling can_handle_critical_notation.
25551
25552 2014-12-11  Werner Koch  <wk@gnupg.org>
25553
25554         build: Replace deprecated autconf macro.
25555         + commit 1d8ebe4d54eef37da65e7bd5d7386bc04f344447
25556         * m4/intl.m4: s/AM_PROG_MKDIR_P/AC_PROG_MKDIR_P/
25557         * m4/po.m4: Ditto.
25558
25559 2014-12-08  Werner Koch  <wk@gnupg.org>
25560
25561         dirmngr: Improve dead host detection.
25562         + commit e8c0ed779579293b3f4592d9337bc15ee0fc3fdd
25563         * dirmngr/ks-engine-hkp.c (handle_send_request_error): Mark host dead
25564         also for 2 other error messages.
25565
25566         http: Improve diagnostic messages.
25567         + commit 6d5f12834124ba5ee0e54261531abf95c36c116c
25568         * common/http.c (send_request): Print TLS alert info
25569         (connect_server): Detect bogus DNS entry.
25570
25571         gpg: Obsolete some keyserver helper options.
25572         + commit 5bf93f4ea7a11381dd256b5fd4e5913366828265
25573         * g10/options.h (opt): Remove keyserver_options.other.
25574         * g10/gpg.c (main): Obsolete option --honor-http-proxt.
25575         * g10/keyserver.c (add_canonical_option): Replace by ...
25576         (warn_kshelper_option): New.
25577         (parse_keyserver_uri): Obsolete "x-broken-http".
25578
25579         dirmngr: Return a proper error for all dead hosts.
25580         + commit b72ece6d74d3e385e818ead748eba0cb111b95b3
25581         * dirmngr/ks-engine-hkp.c (map_host): Change to return an gpg_error_t.
25582         Return an error code for all dead hosts.
25583         (make_host_part): Change to return an gpg_error_t.  Change all
25584         callers.
25585
25586         gpg: Write a status line for a failed --send-keys.
25587         + commit 66ab8f807c96b778f2a2c82b58d3e15ac295e1b2
25588         * g10/keyserver.c (keyserver_put): Write an status error.
25589
25590 2014-12-08  NIIBE Yutaka  <gniibe@fsij.org>
25591
25592         scd: Fix for EdDSA.
25593         + commit c50c11d5751f46ddb38244a5a07d8274e1e10922
25594         * scd/app-openpgp.c (get_algo_byte): It catches 22.
25595         (store_fpr): It's MPI usually, but it's opaque bytes for EdDSA.
25596
25597 2014-12-05  Andre Heinecke  <aheinecke@intevation.de>
25598
25599         Document no-allow-mark-trusted option.
25600         + commit f4ed04fca8885301b567ec004ffff0d6e24f4611
25601             doc: Document no-allow-mark-trusted for gpg-agent
25602
25603             * doc/gpg-agent.texi: Change allow-mark-trusted doc to
25604             no-allow-mark-trusted.
25605
25606             --
25607             Since rev. 78a56b14 allow-mark-trusted is the default option
25608             and was replaced by no-allow-mark-trusted to disable the
25609             interactive prompt.
25610
25611 2014-12-05  NIIBE Yutaka  <gniibe@fsij.org>
25612
25613         scd: Fix for NIST P-256.
25614         + commit 8720125f5a283ede34e52c2493b8a9b0226ae62c
25615         * g10/card-util.c (card_store_subkey): Error check.
25616         * scd/app-opengpg.c (ecc_writekey): Support NIST P-256.
25617         (do_writekey): Error check.
25618
25619 2014-12-04  Werner Koch  <wk@gnupg.org>
25620
25621         gpg: Allow import of large keys.
25622         + commit 63e7891f0f9f0228d93c6cd979fbf2797da2b67d
25623         * g10/import.c (import): Skip too large keys.
25624         * kbx/keybox-file.c (IMAGELEN_LIMIT): Change limit from 2MB to 5MB.
25625
25626 2014-12-03  Werner Koch  <wk@gnupg.org>
25627
25628         gpg: Remove option aliases --[no-]throw-keyid and --notation-data.
25629         + commit 17b4662984b4669d8dcbbd6705ccfbe6c263319c
25630         * g10/gpg.c (opts): Remove them.
25631         * g10/options.h (opt): s/throw_keyid/throw_keyids/ and change users.
25632
25633 2014-12-02  Werner Koch  <wk@gnupg.org>
25634
25635         agent: Replace some sprintf.
25636         + commit fabcf1440a6900b9471f11e4f2a015e9f2d1a74c
25637         * agent/call-scd.c (agent_card_pksign): Replace sprintf by bin2hex.
25638         * agent/command-ssh.c (ssh_identity_register): Ditto.
25639         * agent/pkdecrypt.c (agent_pkdecrypt): Replace sprintf by
25640         put_membuf_printf.
25641
25642 2014-12-01  Werner Koch  <wk@gnupg.org>
25643
25644         tools: Improve watchgnupg portability.
25645         + commit 0367a4b8cfbf1f197e093ca2b83b27e0a409c3c7
25646         * configure.ac (AC_CHECK_HEADERS): Check for sys.select.h
25647         * tools/watchgnupg.c: Include it.
25648
25649         gpg: Fix export bug using exact search with only one key in the keybox.
25650         + commit f1c3eb4b16ca43b5d3712a3b54c22d17ce85af47
25651         * g10/export.c (do_export_stream): Disable caching.
25652         * g10/keyserver.c (keyidlist): Ditto.
25653
25654         scd: Implement socket redirection.
25655         + commit 2f90b7c21b2f84ca2bf5f4555da9233e84606b4e
25656         * scd/scdaemon.c (ENAMETOOLONG): New.
25657         (redir_socket_name): New.
25658         (cleanup): Take care of a redirected socket.
25659         (main): Pass redir_socket_name to create_server_socket.
25660         (create_socket_name): Remove superfluous length check.
25661         (create_server_socket): Add arg r_redir_name and implement
25662         redirection.  Replace assert for older Assuan by an error message.
25663
25664         dirmngr: Implement socket redirection.
25665         + commit eede0e59bf6281777da7391752ae4191f3e51204
25666         * dirmngr/dirmngr.c (ENAMETOOLONG): new.
25667         (redir_socket_name): New.
25668         (main): Add Assuan socket redirection.
25669         (cleanup): Adjust cleanup for redirection.
25670
25671 2014-11-28  Werner Koch  <wk@gnupg.org>
25672
25673         agent: Implement socket redirection.
25674         + commit e1f515b19c7f63b6d0b0253319b9fc41dabed657
25675         * agent/gpg-agent.c (ENAMETOOLONG): New.
25676         (redir_socket_name, redir_socket_name_extra)
25677         (redir_socket_name_ssh): New.
25678         (remove_socket): Take care of the redir names.
25679         (main): Pass the redir names to create_server_socket.
25680         (create_socket_name): Remove length check - that is anyway done later.
25681         (create_server_socket): Add arg r_redir_name and implement redirection
25682         if Libassuan is at least 2.14.
25683
25684         gpg: Change another BUG() call to a regular error message.
25685         + commit e59b1cc7471dd161a627b290c645ef7bd0d9d42c
25686         * g10/mainproc.c (proc_tree): Replace BUG by a proper error messages.
25687
25688         Add option --no-autostart.
25689         + commit 7aee3579be6e24a1aa280e75615fc3a11ceef960
25690         * g10/gpg.c: Add option --no-autostart.
25691         * sm/gpgsm.c: Ditto.
25692         * g10/options.h (opt): Add field autostart.
25693         * sm/gpgsm.h (opt): Ditto.
25694         * g10/call-agent.c (start_agent): Print note if agent was not
25695         autostarted.
25696         * sm/call-agent.c (start_agent): Ditto.
25697         * g10/call-dirmngr.c (create_context): Likewise.
25698         * sm/call-dirmngr.c (start_dirmngr_ext): Ditto.
25699
25700 2014-11-27  Мирослав Николић  <wk@gnupg.org>
25701
25702         gpg-agent: Add restricted connection feature.
25703         + commit f173cdcdfbfd083b035516a406c2c754f38a0ace
25704         * agent/agent.h (opt): Add field extra_socket.
25705         (server_control_s): Add field restricted.
25706         * agent/command.c: Check restricted flag on many commands.
25707         * agent/gpg-agent.c (oExtraSocket): New.
25708         (opts): Add option --extra-socket.
25709         (socket_name_extra): New.
25710         (cleanup): Cleanup that socket name.
25711         (main): Implement oExtraSocket.
25712         (create_socket_name): Add arg homedir and change all callers.
25713         (create_server_socket): Rename arg is_ssh to primary and change
25714         callers.
25715         (start_connection_thread): Take ctrl as arg.
25716         (start_connection_thread_std): New.
25717         (start_connection_thread_extra): New.
25718         (handle_connections): Add arg listen_fd_extra and replace the
25719         connection starting code by parameterized loop.
25720         * common/asshelp.c (start_new_gpg_agent): Detect the use of the
25721         restricted mode and don't fail on sending the pinentry environment.
25722
25723         * common/util.h (GPG_ERR_FORBIDDEN): New.
25724
25725         agent: Make auditing of the option list easier.
25726         + commit ccee34736b57a42ec4bdcb0d3181bdc6a08b0fff
25727         * agent/gpg-agent.c (opts): Use ARGPARSE_ macros.
25728
25729 2014-11-26  Kristian Fiskerstrand  <kf@sumptuouscapital.com>
25730
25731         dirmngr: Only report hkps scheme when available.
25732         + commit 68a7ccc0c870cce6ab9fefb1aa6fd100e1de129b
25733         * dirmngr/ks-engine-hkp.c (ks_hkp_help): Make use of TLS macros.
25734
25735 2014-11-26  Werner Koch  <wk@gnupg.org>
25736
25737         gpg: Change a bug() call to a regular error message.
25738         + commit 1c2140346d6ef9c35e303099d2d15be57869b4d5
25739         * g10/decrypt-data.c (decrypt_data): Return an error code instead of
25740         calling BUG().
25741
25742 2014-11-25  Werner Koch  <wk@gnupg.org>
25743
25744         Fix buffer overflow in openpgp_oid_to_str.
25745         + commit 8445ef24fc31e1fe0291e17f90f9f06b536e34da
25746         * common/openpgp-oid.c (openpgp_oid_to_str): Fix unsigned underflow.
25747
25748         * common/t-openpgp-oid.c (BADOID): New.
25749         (test_openpgp_oid_to_str): Add test cases.
25750
25751 2014-11-24  Werner Koch  <wk@gnupg.org>
25752
25753         gpg: Fix use of uninit.value in listing sig subpkts.
25754         + commit 596ae9f5433ca3b0e01f7acbe06fd2e424c42ae8
25755         * g10/parse-packet.c (dump_sig_subpkt): Print regex subpacket
25756         sanitized.
25757
25758         gpg: Fix off-by-one read in the attribute subpacket parser.
25759         + commit 0988764397f99db4efef1eabcdb8072d6159af76
25760         * g10/parse-packet.c (parse_attribute_subpkts): Check that the
25761         attribute packet is large enough for the subpacket type.
25762
25763         gpg: Fix batch generation of ECC keys.
25764         + commit b716e6a69919b89c7887d6c7c9b97e58d18fdf95
25765         * g10/keygen.c (get_parameter_algo): Map ECC algorithm strings
25766         directly.
25767
25768 2014-11-24  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
25769
25770         Distinguish between ARGPARSE_AMBIGUOUS_{OPTION,COMMAND}
25771         + commit eed16ccebf8fd1fdf9709affbd5c831f6957b8ae
25772         * common/argparse.c (initialize): Use correct value.
25773
25774         gpg: Refer to --throw-keyids instead of --throw-keyid.
25775         + commit a3cf781e3bc144aff60e007b9ba59bff7b1b2c9e
25776         * g10/encrypt.c: adjust error message
25777
25778 2014-11-21  Werner Koch  <wk@gnupg.org>
25779
25780         gpg: Track number of skipped v3 keys on import.
25781         + commit 44c9cc18968b3e1d7568ec41ebf28a07285c61bb
25782         * g10/import.c (stats_s): Add field v3keys.
25783         (import): Update this field.
25784         (import_print_stats): Print v3 key count.
25785         (read_block): Skip v3 keys and return a count for them.
25786
25787         gpg: Fix regression in parse_key.
25788         + commit 94a54425144e412bc83e44b7c6323282f49f650f
25789         * g10/parse-packet.c (parse): Better return just the gpg_err_code.
25790         (parse_key): Return the error code.
25791
25792         speedo: Add simple logos to the installer.
25793         + commit 9a85b91e925ac0798d56820353bf5858b212277f
25794         * build-aux/speedo/w32/README.txt: Include GnuPG Readme.
25795         * build-aux/speedo/w32/gnupg-logo-150x57.bmp: New.
25796         * build-aux/speedo/w32/gnupg-logo-164x314.bmp: New.
25797         * build-aux/speedo/w32/inst.nsi: Add logos.
25798         * build-aux/speedo.mk ($(bdir)/NEWS.tmp): Extract news items.
25799
25800 2014-11-20  Werner Koch  <wk@gnupg.org>
25801
25802         gpg: Fix hash detection for ECDSA.
25803         + commit f80c2dd78d522f12b2c7afbd5c0763a97d87d2bd
25804         * g10/sign.c (sign_file): Use DSA or ECDSA and not DSA|EdDSA.
25805
25806         Fix linker problem on OS X.
25807         + commit cd2c6f36fe5d1d1d45546f5168aead5cbe6487e0
25808         * common/init.c (default_errsource): Move to the .data segmemt.
25809
25810 2014-11-19  Werner Koch  <wk@gnupg.org>
25811
25812         gpg-connect-agent: Add convenience option --uiserver.
25813         + commit 164a6a9dd4af26668dd0d01061688bf1ceff44bf
25814
25815
25816         Add "gpgconf --kill dirmngr" and avoid useless launch before a kill.
25817         + commit 0e7dd40342bd56810c27db1c38c1928f56f43bfd
25818         * common/asshelp.c (start_new_gpg_agent): Add arg autostart.  Change
25819         all callers to use 1 for it.
25820         (start_new_dirmngr): Ditto.
25821         * tools/gpg-connect-agent.c: Add option --no-autostart.
25822         (main): Default autostart to 1.
25823         (start_agent): Implement no-autostart.
25824         * tools/gpgconf-comp.c (gpg_agent_runtime_change): Use --no-autostart.
25825         (scdaemon_runtime_change): Ditto.
25826         (dirmngr_runtime_change): New.
25827
25828         po: Copied missing translations from the 2.0 branch.
25829         + commit 329ece46bf83871f01eb833d5ebec6da36bfcce0
25830         * po/LINGUAS: Add new translations.
25831
25832 2014-11-17  Werner Koch  <wk@gnupg.org>
25833
25834         gpg: Fix a NULL-deref for invalid input data.
25835         + commit 32e85668b82f6fbcb824eea9548970804fb41d9e
25836         * g10/mainproc.c (proc_encrypted): Take care of canceled passpharse
25837         entry.
25838
25839 2014-11-13  Werner Koch  <wk@gnupg.org>
25840
25841         gpg: Make the use of "--verify FILE" for detached sigs harder.
25842         + commit 69384568f66a48eff3968bb1714aa13925580e9f
25843         * g10/openfile.c (open_sigfile): Factor some code out to ...
25844         (get_matching_datafile): new function.
25845         * g10/plaintext.c (hash_datafiles): Do not try to find matching file
25846         in batch mode.
25847         * g10/mainproc.c (check_sig_and_print): Print a warning if a possibly
25848         matching data file is not used by a standard signatures.
25849
25850         gpg: Fix a missing LF in debug output.
25851         + commit 22748338da9a78d20aefe3656ba40b0f9d34a681
25852         * g10/kbnode.c (dump_kbnode): Print a LF.
25853
25854         gpg: Remove PGP-2 related cruft.
25855         + commit e30cb8f61792e3808f7c8f343fc8545e6c81fe74
25856         * g10/armor.c (parse_hash_header,carmor_filter): Ignore MD5 in hash
25857         header.
25858         (fake_packet): Remove pgp-2 workaround for white space stripping.
25859         * g10/filter.h (armor_filter_context_t): Remove field pgp2mode.
25860         * g10/options.h (opt): Remove field pgp2_workarounds.
25861         * g10/gpg.c (main): Do not set this field.
25862         * g10/gpgv.c (main): Ditto.
25863         * g10/mainproc.c (proc_encrypted): Use SHA-1 as fallback s2k hash
25864           algo.  Using MD5 here is useless.
25865         (proc_plaintext): Remove PGP-2 related woraround
25866         (proc_tree): Remove another workaround but keep the one for PGP-5.
25867
25868 2014-11-12  Werner Koch  <wk@gnupg.org>
25869
25870         gpg: Improve perceived speed of secret key listings.
25871         + commit 81e177be10273885573f5d1fd88a1ee23479f4ab
25872         * g10/keylist.c (list_keyblock): Flush stdout for secret keys.
25873
25874         gpg: Fix regression in --refresh-keys.
25875         + commit eecbed004ca1e9ca23c3892c3a5e6dd174ddf93b
25876         * g10/keyserver.c (keyserver_get): Factor all code out to ...
25877         (keyserver_get_chunk): new.  Extimate line length.
25878         (keyserver_get): Split up requests into chunks.
25879
25880         gpg: Add import options "keep-ownertrust".
25881         + commit ffc2307843ce6c4ac3c8d99ba8c70ffa1ae28e39
25882         * g10/options.h (IMPORT_KEEP_OWNERTTRUST): New.
25883         * g10/import.c (parse_import_options): Add "keep-ownertrust".
25884         (import_one): Act upon new option.
25885
25886 2014-11-11  Werner Koch  <wk@gnupg.org>
25887
25888         Remove use of gnulib (part 2)
25889         + commit b8cdfac353ad96d4ef025c066c16dbde34805661
25890         * configure.ac (strpbrk): Add to AC_CHECK_FUNCS.
25891         (gl_EARLY): Remove.
25892         * common/stringhelp.c (strpbrk) [!HAVE_STRPBRK]: New.
25893         * common/sysutils.c (gnupg_mkdtemp): New.  Based on code from
25894         glibc-2.6.
25895         (gnupg_setenv): Rewrite.
25896         (gnupg_unsetenv): Rewrite.
25897         * g10/exec.c: Include sysutils.h and replace mkdtemp by gnupg_mkdtemp.
25898         * g13/be-encfs.c: Ditto.
25899         * g13/mount.c: Ditto.
25900         * tools/symcryptrun.c (confucius_mktmpdir): Ditto.
25901
25902         Remove use of gnulib (part 1)
25903         + commit 1adf719b2d8e2d5b912bf6655731e7e586402654
25904         * gl/: Remove entire tree.
25905         * configure.ac: Remove gnulib tests and the gl/ Makefile.
25906         (setenv): Add to AC_CHECK_FUNCS.
25907         * autogen.rc (extra_aclocal_flags): Set to empty.
25908         * Makefile.am (ACLOCAL_AMFLAGS): Remove -I gl/m4
25909         (SUBDIRS): Remove gl/.
25910         * agent/Makefile.am (common_libs): Remove ../gl/gnulib.a
25911         * common/Makefile.am (t_common_ldadd): Ditto.
25912         * dirmngr/Makefile.am (dirmngr_LDADD): Ditto.
25913         (dirmngr_ldap_LDADD, dirmngr_client_LDADD): Ditto.
25914         * g10/Makefile.am (needed_libs): Ditto.
25915         * g13/Makefile.am (g13_LDADD): Ditto.
25916         * kbx/Makefile.am (kbxutil_LDADD): Ditto.
25917         ($(PROGRAMS)): Ditto.
25918         * scd/Makefile.am (scdaemon_LDADD): Ditto.
25919         * sm/Makefile.am (common_libs): Ditto.
25920         * tools/Makefile.am (common_libs, commonpth_libs): Ditto.
25921
25922         * agent/gpg-agent.c: Remove "mkdtemp.h"
25923         * g10/exec.c: Ditto.
25924         * scd/scdaemon.c: Ditto.
25925         * tools/symcryptrun.c: Ditto.
25926         * common/sysutils.c: Remove "setenv.h"
25927
25928         * common/t-timestuff.c: Use putenv if setenv is not available.
25929
25930 2014-11-07  Werner Koch  <wk@gnupg.org>
25931
25932         gpg: Remove warning message for non-implemented search modes.
25933         + commit 7362c8c6e60939588e817384ae2e29195cb3f518
25934         * kbx/keybox-search.c (keybox_search): Silently ignore.
25935         * doc/specify-user-id.texi: Docuement '@", '+', and '.' search
25936         prefixes.
25937
25938         w32: Fix http access module.
25939         + commit f0f5cb6b3e525f696b8820c517190e1d84f3b885
25940         * common/http.c (write_server) [W32]: Rework to use send() instead of
25941         write even when build with npth.
25942         (cookie_read) [W32]: Rework to use recv() instead of read even when
25943         build with npth.
25944
25945         build: Add method to use a custom swdb.lst and use adns with Windows.
25946         + commit c7c79e31937e2d2fdb4042641786c229e31fbfae
25947         * build-aux/getswdb.sh: Add option --skip-verify.
25948         * build-aux/speedo.mk: Add config var CUSTOM_SWDB.  Tage adns version
25949         from swdb and build for Windows with adns.
25950
25951         build: Improve test for ADNS.
25952         + commit f7e1be24c8fcf588d4e48aa53a85b22bd035e3b0
25953         * configure.ac <adns>: Use adns_free as probe function for libadns.
25954         (HAVE_ADNS_FREE): Remove bogus tests to set this and remove the macro.
25955         (ADNSLIBS): Do not ac_subst - it is only used within configure.
25956
25957 2014-11-05  Werner Koch  <wk@gnupg.org>
25958
25959         speedo: Append the date to the Windows installer.
25960         + commit 8ec0b384a86bd7f67a60ab43ff1540e80c3f729d
25961         * build-aux/speedo.mk (BUILD_DATESTR): New.
25962         (dist-source, installer): Use it.
25963
25964         Release 2.1.0.
25965         + commit e22b459b910762f77245283746de34c67ebc72da
25966
25967
25968         Avoid sign extension when shifting the MSB.
25969         + commit 91b826a38880fd8a989318585eb502582636ddd8
25970         * sm/fingerprint.c (gpgsm_get_short_fingerprint): Cast MSB before
25971         shifting.
25972         * g10/build-packet.c (delete_sig_subpkt): Ditto.
25973
25974 2014-11-04  Werner Koch  <wk@gnupg.org>
25975
25976         Remove all expired common CA certificates.
25977         + commit 46fa1e0fe9f7407f12aa854e5cdb54624af3e89b
25978         * doc/com-certs.pem: Remove certifciates.
25979
25980 2014-11-02  Werner Koch  <wk@gnupg.org>
25981
25982         gpg: Avoid extra pinentries for each subkey in --export-secret-keys.
25983         + commit f8c993fbe28bf02f1d7aadec823a9dfc935398fa
25984         * agent/command.c (cmd_export_key): Actually implement the cache_nonce
25985         feature.
25986         * g10/export.c (do_export_stream): Make use of a cache_nonce.
25987
25988         gpg: Fix endless loop in keylisting with fingerprint.
25989         + commit d95f05c314adfecbe0af9073f964030010442f9b
25990         * g10/getkey.c (getkey_next): Disable cache.
25991
25992         gpg: Minor cleanup for key listing related code.
25993         + commit 440e8f517008107a9fe1b72cb659b97b7d840de6
25994         * g10/getkey.c (get_pubkey_next): Divert to getkey_next.
25995         (get_pubkey_end): Move code to getkey_end.
25996         * g10/keydb.c (keydb_search_reset): Add a debug statement.
25997         (dump_search_desc): Add arg HD and print the handle.
25998
25999         gpg: Do not show an useless passphrase prompt in batch mode.
26000         + commit a929f36693567e57eca89fb48f23cada8ce7291a
26001         * g10/keygen.c: Remove unused PASSPHRASE related code.
26002         (proc_parameter_file): Remove useless asking for a passphrase in batch
26003         mode.
26004
26005 2014-10-31  Werner Koch  <wk@gnupg.org>
26006
26007         gpg: Remove superfluous check for Libgcrypt >= 1.4.0.
26008         + commit f4df71aa2d544ec46a2ded3055ffb21b9842129e
26009         * g10/gpg.c (main): Remove check.
26010
26011         kbx: Let keydb_search skip unwanted blobs.
26012         + commit 935edf88ab29b2f63afc2a0e3af1b33c92033ab7
26013         * kbx/keybox.h (keybox_blobtype_t): New.
26014         * kbx/keybox-defs.h (BLOBTYPE_*): Replace by KEYBOX_BLOBTYPE_*.
26015         * kbx/keybox-search.c (keybox_search): Add arg want_blobtype and skip
26016         non-matching blobs.
26017         * sm/keydb.c (keydb_search): Pass KEYBOX_BLOBTYPE_X509 to keybox_search.
26018         * g10/keydb.c (keydb_search): Pass KEYBOX_BLOBTYPE_PGP to keybox_search.
26019
26020         gpg: Fix --rebuild-keydb-caches.
26021         + commit 28ae8ad70b3b802e67344468a4765eee6e291c68
26022         * g10/parse-packet.c (parse_key): Store even unsupported packet
26023         versions.
26024         * g10/keyring.c (keyring_rebuild_cache): Do not copy keys with
26025         versions less than 4.
26026
26027         gpg: Fix testing for secret key availability.
26028         + commit 433208a5536608c2b40525eebadbbdeb7780d7f2
26029         * g10/getkey.c (have_secret_key_with_kid): Do not change the search
26030         mode.
26031
26032         build: Avoid distributing backup files etc.
26033         + commit b47fe2b14e2a610706bdeff9dbd9a5f7bd6f6b3a
26034         * Makefile.am (EXTRA_DIST): Do not include directories.
26035
26036 2014-10-30  Werner Koch  <wk@gnupg.org>
26037
26038         tests: Speed up the genkey1024.test by using not so strong random.
26039         + commit 9546aa3cc87fc83a40768a12fbbceb19496ce129
26040         * agent/gpg-agent.c (oDebugQuickRandom): New.
26041         (opts): New option --debug-quick-random.
26042         (main): Use new option.
26043         * common/asshelp.c (start_new_gpg_agent): Add hack to pass an
26044         additional argument for the agent name.
26045         * tests/openpgp/defs.inc: Pass --debug-quick-random to the gpg-agent
26046         starting parameters.
26047         * tests/openpgp/version.test: Ditto.
26048
26049 2014-10-29  Werner Koch  <wk@gnupg.org>
26050
26051         common: Check option arguments for a valid range.
26052         + commit 0d73a242cb53522669cf712b5ece7d1ed05d003a
26053         * common/argparse.h (ARGPARSE_INVALID_ARG): New.
26054         * common/argparse.c: Include limits h and errno.h.
26055         (initialize): Add error strings for new error constant.
26056         (set_opt_arg): Add range checking.
26057
26058         Fix stdint.h problem for Apple.
26059         + commit f5592fcff308007322a201c970a6d5e8763c9fe3
26060         * gl/stdint_.h [__APPLE__]: Include hack.
26061
26062 2014-10-27  Werner Koch  <wk@gnupg.org>
26063
26064         speedo: Fixes for native build.
26065         + commit 158fe900183daf745821dea7a70cf1c673cd8de0
26066         * build-aux/speedo.mk (TARGETOS): Init with empty string.
26067         (speedo_pkg_gnupg_configure): Use --enable-gpg2-is-gpg only for w32.
26068         (INST_VERSION, INST_PROD_VERSION): Create only for w32.
26069
26070 2014-10-24  Werner Koch  <wk@gnupg.org>
26071
26072         agent: Support pinentries with integrated repeat passphrase feature.
26073         + commit c9aadcb3a248632c07391ff3d829bece9320a901
26074         * agent/agent.h (struct pin_entry_info_s): Add fields repeat_okay and
26075         with_repeat.
26076         * agent/call-pinentry.c (close_button_status_cb): Rewrite and check
26077         for PIN_REPEAT.  Change users to check only the relevant bit.
26078         (agent_askpin): Support repeat logic of new Pinentries.
26079
26080         * agent/command-ssh.c (ssh_identity_register): Use the new repeat
26081         feature.
26082         * agent/genkey.c (agent_ask_new_passphrase): Ditto.
26083
26084 2014-10-19  Werner Koch  <wk@gnupg.org>
26085
26086         gpg: Silence "packet with obsolete versoin" warnings.
26087         + commit 472a4a0d82add2d17154fa38e0074eaea56c28c1
26088         * g10/parse-packet.c (parse_key): Print warning only in very verbose
26089         mode.
26090
26091         gpg: Make card key generation work again.
26092         + commit 1b8decc4767f0c55867327bdf3113204efcd19a7
26093         * g10/call-agent.c (agent_scd_learn): Rename from agent_learn.
26094         (agent_learn): New.
26095         * g10/keygen.c (gen_card_key): Call new agent-learn.
26096
26097 2014-10-17  Werner Koch  <wk@gnupg.org>
26098
26099         dirmngr: Allow building without LDAP support.
26100         + commit 6d9491842d5da597980eaa59e1e3e2137965fe09
26101         * configure.ac: Add option --disable-ldap.
26102         (USE_LDAP): New ac_define and am_conditional.
26103         * dirmngr/Makefile.am: Take care of USE_LDAP.
26104         * dirmngr/dirmngr.c (!USE_LDAP): Make all ldap options dummy options
26105         and do not call any ldap function.
26106         * dirmngr/server.c (!USE_LDAP): Do not call any ldap function.
26107         * dirmngr/crlfetch.c (!USE_LDAP): Ditto.
26108
26109         w32: Set SYSROOT to help finding config scripts.
26110         + commit a13705f4c18db56765f4af31376e81241dbabebe
26111         * autogen.sh <build-w32>: Set SYSROOT.
26112
26113         gpg: Remove all support for v3 keys and always create v4-signatures.
26114         + commit 8fd150b05b744fe9465057c12529d5e6b6b02785
26115         * g10/build-packet.c (do_key): Remove support for building v3 keys.
26116         * g10/parse-packet.c (read_protected_v3_mpi): Remove.
26117         (parse_key): Remove support for v3-keys.  Add dedicated warnings for
26118         v3-key packets.
26119         * g10/keyid.c (hash_public_key): Remove v3-key support.
26120         (keyid_from_pk): Ditto.
26121         (fingerprint_from_pk): Ditto.
26122
26123         * g10/options.h (opt): Remove fields force_v3_sigs and force_v4_certs.
26124         * g10/gpg.c (cmd_and_opt_values): Remove oForceV3Sigs, oNoForceV3Sigs,
26125         oForceV4Certs, oNoForceV4Certs.
26126         (opts): Turn --force-v3-sigs, --no-force-v3-sigs, --force-v4-certs,
26127         --no-force-v4-certs int dummy options.
26128         (main): Remove setting of the force_v3_sigs force_v4_certs flags.
26129         * g10/revoke.c (gen_revoke, create_revocation): Always create v4 certs.
26130         * g10/sign.c (hash_uid): Remove support for v3-signatures
26131         (hash_sigversion_to_magic): Ditto.
26132         (only_old_style): Remove this v3-key function.
26133         (write_signature_packets): Remove support for creating v3-signatures.
26134         (sign_file): Ditto.
26135         (sign_symencrypt_file): Ditto.
26136         (clearsign_file): Ditto.  Remove code to emit no Hash armor line if
26137         only v3-keys are used.
26138         (make_keysig_packet): Remove arg SIGVERSION and force using
26139         v4-signatures.  Change all callers to not pass a value for this arg.
26140         Remove all v3-key related code.
26141         (update_keysig_packet): Remove v3-signature support.
26142         * g10/keyedit.c (sign_uids): Always create v4-signatures.
26143
26144         * g10/textfilter.c (copy_clearsig_text): Remove arg pgp2mode and
26145         change caller.
26146
26147 2014-10-13  Werner Koch  <wk@gnupg.org>
26148
26149         gpg: Remove extra RSA import status line.
26150         + commit fab89f159bcb36ea7285af661d5756eefa981822
26151         * g10/import.c (stats_s): Remove field "imported_rsa".
26152         (import_print_stats): Do not print separate value for RSA.
26153         (import_one): Remove the RSA counter.
26154
26155         gpg: Fix informative printing of user ids.
26156         + commit 21c0ea6bafafbcc4a2e07f0ac76275cc0229e9a0
26157         * g10/getkey.c (keyid_list): Add field "fpr".
26158         (cache_user_id): Store fpr and check for dups only by fpr.
26159         (get_pubkey_byfpr): New.
26160         (get_user_id_string): Make static and use xasprintf.
26161         (get_long_user_id_string): Use xasprintf.
26162         (get_user_id_byfpr): New.
26163         (get_user_id_byfpr_native): New.
26164         * g10/keyid.c (fingerprint_from_pk): Make arg RET_LEN optional.
26165         * g10/import.c (import_one): Use get_user_id_byfpr_native.
26166
26167         gpg: Allow importing keys with duplicated long key ids.
26168         + commit c60814a5ce13932d933b363abc0c60c12783ae2f
26169         * g10/keydb.c (keydb_handle): Add field no_caching.
26170         (keyblock_cache): Repalce field kid by fpr.
26171         (keydb_disable_caching): New.
26172         (keydb_search): Use the fingerprint as cache index.
26173
26174         * g10/import.c (import_one): Use the fingerprint and not the kid to
26175         lookup the key.  Call keydb_disable_caching beofre re-searching for
26176         update.
26177
26178         * tests/openpgp/import.test: Add a test case.
26179
26180         tests: Speed up conventional encryption tests for gpg.
26181         + commit 2543f0ab9c7b4247347688863f898667bae31984
26182         * tests/openpgp/conventional-mdc.test: Add an s2k-count option.
26183         * tests/openpgp/conventional.test: Ditto.
26184
26185 2014-10-12  Werner Koch  <wk@gnupg.org>
26186
26187         gpg: Minor change for better readability.
26188         + commit 2d68dc437e7de92619abe3a019b0a7606487b6bf
26189         * g10/build-packet.c (write_version): Remove.
26190         (do_pubkey_enc, do_onepass_sig): Write version directly.
26191
26192 2014-10-10  Werner Koch  <wk@gnupg.org>
26193
26194         doc: Fix a man page rendering problem.
26195         + commit 5b5e5a6027ae1743719e112aa4e9055f1b8133a7
26196         * doc/gpg-agent.texi (Agent Configuration): Fix rendering of the
26197         sshcontrol example.
26198
26199 2014-10-10  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
26200
26201         gpg: Add build and runtime support for larger RSA keys.
26202         + commit 6cabb7a2a18f871b8c3d5de58bcdc5aaa5b201af
26203         * configure.ac: Added --enable-large-secmem option.
26204         * g10/options.h: Add opt.flags.large_rsa.
26205         * g10/gpg.c: Contingent on configure option: adjust secmem size,
26206         add gpg --enable-large-rsa, bound to opt.flags.large_rsa.
26207         * g10/keygen.c: Adjust max RSA size based on opt.flags.large_rsa
26208         * doc/gpg.texi: Document --enable-large-rsa.
26209
26210 2014-10-09  Werner Koch  <wk@gnupg.org>
26211
26212         gpg: Skip overlong keys and a print a warning.
26213         + commit 2ca90f78cee91c43b8d538d1cb92728f8e1452d5
26214         * kbx/keybox-search.c (keybox_search): Add arg r_skipped and skip too
26215         long blobs.
26216         * sm/keydb.c (keydb_search): Call keybox_search with a dummy param.
26217         * g10/keydb.c (struct keydb_handle): Add field skipped_long_blobs.
26218         (keydb_search_reset): Reset that field.
26219         (keydb_search): Update that field.
26220         (keydb_get_skipped_counter): New.
26221         * g10/keylist.c (list_all): Print count of skipped keys.
26222
26223         gpg: Sync keylist output and warning messages.
26224         + commit 60e21d8b85888b8c9ea15c70268f98d780fdf5fb
26225         * g10/keylist.c (list_all): Flush stdout before logging.
26226         * g10/misc.c (print_pubkey_algo_note): Ditto.
26227         (print_cipher_algo_note): Ditto.
26228         (print_digest_algo_note): Ditto.
26229         (print_md5_rejected_note): Ditto.
26230
26231         kbx: Fix handling of overlong keys.
26232         + commit b6507bb80e4e4aa5c85a918fdcf5c28cccb75081
26233         * kbx/keybox-file.c (IMAGELEN_LIMIT): Change limit from 10^6 to 2MiB.
26234         (_keybox_read_blob2): Skip too long record records.
26235         (_keybox_write_blob): Do not accept too long record.
26236         * kbx/keybox-dump.c (file_stats_s): Add field skipped_long_blobs.
26237         (_keybox_dump_file): Print new counter.
26238         (_keybox_dump_file): Skip too long records.
26239         ----
26240
26241         To test this feature you may set the limit back to 1MiB and use key
26242         F7F0E70F307D56ED which is in my local copy close to 2MiB.  Without
26243         this patch it was possible to import the key but access to that key
26244         and all keys stored after it was not possible.
26245
26246         gpg: Take care to use pubring.kbx if it has ever been used.
26247         + commit ec332d58efc50f6508b87fc9f51db68c39cee044
26248         * kbx/keybox-defs.h (struct keybox_handle): Add field for_openpgp.
26249         * kbx/keybox-file.c (_keybox_write_header_blob): Set openpgp header
26250         flag.
26251         * kbx/keybox-blob.c (_keybox_update_header_blob): Add arg for_openpgp
26252         and set header flag.
26253         * kbx/keybox-init.c (keybox_new): Rename to do_keybox_new, make static
26254         and add arg for_openpgp.
26255         (keybox_new_openpgp, keybox_new_x509): New.  Use them instead of the
26256         former keybox_new.
26257         * kbx/keybox-update.c (blob_filecopy): Add arg for_openpgp and set the
26258         openpgp header flags.
26259
26260         * g10/keydb.c (rt_from_file): New.  Factored out and extended from
26261         keydb_add_resource.
26262         (keydb_add_resource): Switch to the kbx file if it has the openpgp
26263         flag set.
26264
26265         * kbx/keybox-dump.c (dump_header_blob): Print header flags.
26266
26267 2014-10-09  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
26268
26269         Avoid unnecessary library linkage.
26270         + commit 27fe067efea883629354450a042ad09e47d90ff8
26271         * dirmngr/Makefile.am: Avoid $(DNSLIBS) for dirmngr_ldap
26272         * g10/Makefile.am: $(LIBREADLINE) is only for gpg2; gpgv2 does not
26273         need $(LIBASSUAN_LIBS)
26274         * sm/Makefile.am: gpgsm does not need $(ZLIBS)
26275         * tools/Makefile.am: gpgconf does not need $(NPTH_LIBS)
26276
26277 2014-10-08  Werner Koch  <wk@gnupg.org>
26278
26279         gpg: Avoid error exit if keygrip computations fails in a key listing.
26280         + commit 3ae6afc1336d42bd95fa0b7f5f83bd299ae26b97
26281         * g10/keyid.c (keygrip_from_pk): Use log_info and clear array on error.
26282
26283 2014-10-03  Werner Koch  <wk@gnupg.org>
26284
26285         Release 2.1.0-beta864.
26286         + commit 0943c7cc23371943e9670a2f35c318d847cbac6a
26287
26288
26289         gpg: Allow creating a cert-only primary key.
26290         + commit bc8583f247898a1fa45f6de834d34b335ab1952c
26291         * g10/keygen.c (ask_key_flags): Allow a 'c' in direct entry.
26292
26293         build: Add configure options --disable-{ntb,gnu}tls.
26294         + commit 6522a68d8d11e15ee77102e6830f251c2d9f440d
26295         * configure.ac: Add --disable-ntbtls and --disable-gnutls.
26296
26297 2014-10-03  Andre Heinecke  <aheinecke@intevation.de>
26298
26299         gpg: Check gpg-agent version before 2.1 migration.
26300         + commit a6fcdbc9e0fc0e45a3badc23813e689e83059b61
26301         * g10/call-agent.c, g10/call-agent.h (agent_get_version): New.
26302         * g10/migrate.c (migrate_secring): Abort migration if
26303         agent_get_version returns not at least 2.1.0
26304
26305 2014-10-03  Werner Koch  <wk@gnupg.org>
26306
26307         po: Update German translation.
26308         + commit b15d5d42adf31c0797797ebe19c471ab6f52c668
26309
26310
26311         Remove support for the GPG_AGENT_INFO envvar.
26312         + commit 9c380384dafb213334f8834178c5ceb0bf33db6e
26313         * agent/agent.h (opt): Remove field use_standard_socket.
26314         * agent/command.c (cmd_killagent): Always allow killing.
26315         * agent/gpg-agent.c (main): Turn --{no,}use-standard-socket and
26316         --write-env-file into dummy options.  Always return true for
26317         --use-standard-socket-p. Do not print the GPG_AGENT_INFO envvar
26318         setting or set that envvar.
26319         (create_socket_name): Simplify by removing non standard socket
26320         support.
26321         (check_for_running_agent): Ditto.
26322         * common/asshelp.c (start_new_gpg_agent): Remove GPG_AGENT_INFO use.
26323         * common/simple-pwquery.c (agent_open): Ditto.
26324         * configure.ac (GPG_AGENT_INFO_NAME): Remove.
26325         * g10/server.c (gpg_server): Do not print the AgentInfo comment.
26326         * g13/server.c (g13_server): Ditto.
26327         * sm/server.c (gpgsm_server): Ditto.
26328         * tools/gpgconf.c (main): Simplify by removing non standard socket
26329         support.
26330
26331 2014-10-02  Werner Koch  <wk@gnupg.org>
26332
26333         gpg: Fix regression removing SHA256.
26334         + commit 688a903b4b3ad348c0d09e9d3fab8a12f4f94311
26335         * g10/misc.c (map_md_openpgp_to_gcry): Always use SHA256.
26336
26337         First changes for future use of NTBTLS.
26338         + commit f2361e6d582d4343d71d294ed1da654afe7750ee
26339         * configure.ac (NEED_NTBTLS_ABI, NEED_NTBTLS_VERSION): New.
26340         (HTTP_USE_NTBTLS): New.  Prefer over GNUTLS.
26341         * m4/ntbtls.m4: New.
26342         * m4/Makefile.am (EXTRA_DIST): Add new file.
26343         * common/http.c: Add conditionals to eventually use NTBTLS.
26344
26345         build: Update m4 scripts.
26346         + commit 6bc0cd6202033be113999dbf27be4014bdf2c784
26347         * m4/gpg-error.m4: Update from Libgpg-error git master.
26348         * m4/libgcrypt.m4: Update from Libgcrypt git master.
26349         * configure.ac: Declare SYSROOT a precious variable.  Add extra error
26350         message for library configuration mismatches.
26351
26352 2014-09-29  Werner Koch  <wk@gnupg.org>
26353
26354         doc: Remove GnuPG-1 related parts from gpg.texi.
26355         + commit edd191e5b006dc6ace1d41672e7201cbe58c41c9
26356         * doc/Makefile.am (YAT2M_OPTIONS): Add 2.1 to the source info.
26357         * doc/gpg.texi: Remove gpg1 related texts.
26358
26359 2014-09-27  Werner Koch  <wk@gnupg.org>
26360
26361         gpg: Default to SHA-256 for all signature types on RSA keys.
26362         + commit d33246700578cddd1cb8ed8164cfbba50aba4ef3
26363         * g10/main.h (DEFAULT_DIGEST_ALGO): Use SHA256 in --gnupg and SHA1 in
26364         strict RFC or PGP modes.
26365         * g10/sign.c (make_keysig_packet): Use DEFAULT_DIGEST_ALGO also for
26366         RSA key signatures.
26367         * configure.ac: Do not allow to disable sha256.
26368
26369         gpg: Simplify command --gen-key and add --full-gen-key.
26370         + commit f3625bb018fa8d5bc754f982996f8788386f0a9d
26371         * g10/gpg.c (aFullKeygen): New.
26372         (opts): Add command --full-key-gen.
26373         (main): Implement it.
26374         * g10/keygen.c (DEFAULT_STD_ALGO): Replace wrong GCRY_PK_RSA although
26375         the value is identical.
26376         (DEFAULT_STD_CURVE): New.
26377         (DEFAULT_STD_SUBALGO): New.
26378         (DEFAULT_STD_SUBKEYSIZE): New.
26379         (DEFAULT_STD_SUBCURVE): New.
26380         (quick_generate_keypair): Use new macros here.
26381         (generate_keypair): Add arg "full" and fix call callers. Do not ask
26382         for keysize in non-full node.
26383         (ask_user_id): Add arg "full" and simplify for non-full mode.
26384
26385 2014-09-26  Werner Koch  <wk@gnupg.org>
26386
26387         gpg: Add shortcut for setting key capabilities.
26388         + commit 7ff4ea2160e87a16bf701552d3b9c7ab1c42f9ec
26389         * g10/keygen.c (ask_key_flags): Add shortcut '='.
26390         * doc/help.txt (gpg.keygen.flags): New.
26391
26392 2014-09-25  Werner Koch  <wk@gnupg.org>
26393
26394         gpg: Do not always print dashes in obsolete_option.
26395         + commit 20c6da50d4f6264d26d113d7de606971f719a0ca
26396         * g10/gpg.c (main): Pass option names to obsolete_option without
26397         double dash.
26398         * g10/misc.c (obsolete_option, obsolete_scdaemon_option): Print double
26399         dash only for command line options.
26400
26401 2014-09-25  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
26402
26403         gpg: Warn about (but don't fail) on scdaemon options in gpg.conf.
26404         + commit 371c2b14b0347209efd23b4e54e1981a12d7aeab
26405         * g10/gpg.c: Add config options that should belong in scdaemon.conf
26406         * g10/main.h, g10/misc.c (obsolete_scdaemon_option): New.
26407
26408 2014-09-22  Werner Koch  <wk@gnupg.org>
26409
26410         speedo: Check that wget and gpgv are installed.
26411         + commit 59b6f6f16e095162358ac2001aeb2c058de2fd1e
26412         * build-aux/getswdb.sh: Check for required tools.
26413
26414         speedo: Autodetect sha1sum tools.
26415         + commit 2427bc5bc76b00cfe790e1f370113f5b4199e8fa
26416         * build-aux/getswdb.sh: Add option --find-sha1sum.
26417         * build-aux/speedo.mk (check-tools): New phony target.  Not yet used.
26418         (SHA1SUM): New var.  Use it instead of sha1sum.
26419
26420         gpg: Create default keyring with .kbx suffix.
26421         + commit bc2f5c1d1afbe8ba413e594639fd05f19df32f75
26422         * g10/keydb.c (maybe_create_keyring_or_box): Rename arg for clarity.
26423         (keydb_add_resource): Fix order of args to maybe_create_keyring_or_box
26424         and check and create .kbx.
26425
26426 2014-09-20  Werner Koch  <wk@gnupg.org>
26427
26428         gpg: --delete-secret-key - check that a secret key exists.
26429         + commit 1d33d03f0bb576601f5eef1a548cbc519f251b17
26430         * g10/delkey.c (do_delete_key): Check availibility of a secret key.
26431
26432         gpg: Make algorithm selection prompt for ECC more clear.
26433         + commit cf648fc5c8cb20bfea4fd303631ba311bbaf3659
26434         * g10/keygen.c (ask_algo): Change 9 to "ECC and ECC".
26435
26436 2014-09-18  Werner Koch  <wk@gnupg.org>
26437
26438         Release 2.1.0-beta834.
26439         + commit 93f158df381af86036332c4314c2d4a64eab3e62
26440
26441
26442         speedo: Distribute needed files.
26443         + commit 72a16d80d4505aa0ff509aae41f848bbe42ed129
26444         * Makefile.am (EXTRA_DIST): Add speedo stuff.
26445
26446         build: Enable gpgtar by default.
26447         + commit 345a8374f31e637a99e6438e527670cf6845ca05
26448
26449
26450         common: Do not build maintainer modules in non-maintainer mode.
26451         + commit 927db789c19cbe5656ff980841ee37dd3a8989e7
26452         * common/Makefile.am (module_maint_tests): Use only in maintainer
26453         mode.
26454         (t_common_cflags): New.
26455
26456         common: Remove superfluous statements.
26457         + commit cad181b5ece3ab6910575c82c731ce2b47271a09
26458         * common/exechelp-posix.c: Remove weak pragmas.
26459         * common/sexputil.c (make_canon_sexp_from_rsa_pk): Remove double
26460         const.
26461
26462         g13: Avoid segv after pipe creation failure.
26463         + commit 6e7bcabd781a3ca9ad7dd90d962fb2a239feab4a
26464         * g13/call-gpg.c (gpg_encrypt_blob): Init some vars in case of an
26465         early error.
26466         (gpg_decrypt_blob): Ditto.
26467
26468         scd: Fix int/short mismatch in format string of app-p15.c.
26469         + commit b17e8bbf20239e840763f98d3e62f16efdc82ba3
26470         * scd/app-p15.c (parse_certid): Use snprintf and cast value.
26471         (send_certinfo): Ditto.
26472         (send_keypairinfo): Ditto.
26473         (do_getattr): Ditto.
26474
26475         agent: Init a local variable in the error case.
26476         + commit f82a6e0f08725008c5bbf702a5f4c175ea09f01c
26477         * agent/pksign.c (do_encode_md): Init HASH on error.
26478
26479         agent: Remove left over debug output.
26480         + commit 4f35ef499ac913036b7b69296a62afe8159b90b8
26481         * agent/command-ssh.c (ssh_signature_encoder_eddsa): Remove debug
26482         output.
26483
26484         agent: Silence compiler warning for a debug message.
26485         + commit ba6f8b3d9ec83b35c4f3839853567491fee2f99c
26486         * agent/call-pinentry.c (agent_query_dump_state): Use %p for
26487         POPUP_TID.
26488
26489         sm: Silence compiler warnings.
26490         + commit 34b2e8c7dcb0edb28f99edbd788d73491334e3c0
26491         * sm/certreqgen-ui.c (gpgsm_gencertreq_tty): Remove unused var I.
26492         * sm/certreqgen.c (proc_parameters): Init PUBLIC to avoid compiler
26493         warning.
26494
26495         gpg: Silence a compiler warning.
26496         + commit 6a0c3fa19cfcdd590b96691e8a8ffb48fb5e0ec4
26497         * g10/parse-packet.c (enum_sig_subpkt): Replace hack.
26498
26499         gpg: Replace a hash algo test function.
26500         + commit 327134934d79d141d92170ad3b4a6ef3cb718ee0
26501         * g10/gpg.c (print_mds): Replace openpgp_md_test_algo.
26502
26503         speedo: Various fixes.
26504         + commit 2f065d7ab6c514013eb8504281f50284764c26ec
26505         * build-aux/speedo.mk: Take zlib and bzip2 from ftp.gnupg.org.  Minor
26506         other fixes.
26507
26508 2014-09-17  Werner Koch  <wk@gnupg.org>
26509
26510         gpg: Print a warning if the subkey expiration may not be what you want.
26511         + commit ae3d1bbb65b65cf3c57bb14886be120f5e31635d
26512         * g10/keyedit.c (subkey_expire_warning): New.
26513         (keyedit_menu): Call it when needed.
26514
26515         gpg: Improve passphrase caching.
26516         + commit 457bce5cd39146df047e4740162125c32c738789
26517         * agent/cache.c (last_stored_cache_key): New.
26518         (agent_get_cache): Allow NULL for KEY.
26519         (agent_store_cache_hit): New.
26520         * agent/findkey.c (unprotect): Call new function and try to use the
26521         last stored key.
26522
26523         * g10/revoke.c (create_revocation): Add arg CACHE_NONCE and pass to
26524         make_keysig_packet.
26525         (gen_standard_revoke): Add arg CACHE_NONCE and pass to
26526         create_revocation.
26527         * g10/keygen.c (do_generate_keypair): Call gen_standard_revoke with
26528         cache nonce.
26529
26530 2014-09-12  Werner Koch  <wk@gnupg.org>
26531
26532         gpg: Use algorithm id 22 for EdDSA.
26533         + commit 83c2d2396cc9fa6bdd887a560830fc0f48b01b08
26534         * common/openpgpdefs.h (PUBKEY_ALGO_EDDSA): Change to 22.
26535         * g10/keygen.c (ask_curve): Reword the Curve25519 warning note.
26536
26537 2014-09-11  Werner Koch  <wk@gnupg.org>
26538
26539         gpg: Stop early on bogus old style comment packets.
26540         + commit 3d250d21d36e8a0935b645f1ed5134ef9083530e
26541         * g10/parse-packet.c (parse_key): Take care of too short packets for
26542         old style commet packets.
26543
26544 2014-09-10  Werner Koch  <wk@gnupg.org>
26545
26546         dirmngr: Support https for KS_FETCH.
26547         + commit 84419f42da0fd436a9e0e669730157e74ce38b77
26548         * dirmngr/ks-engine-hkp.c (cert_log_cb): Move to ...
26549         * dirmngr/misc.c (cert_log_cb): here.
26550         * dirmngr/ks-engine-http.c (ks_http_fetch): Support 307-redirection
26551         and https.
26552
26553         dirmngr: Fix the ks_fetch command for the http scheme.
26554         + commit 3b20cc21de86ac8a475bdefd3aebb02a12fb8d0b
26555         * common/http.c (http_session_ref): Allow for NULL arg.
26556
26557 2014-09-08  Werner Koch  <wk@gnupg.org>
26558
26559         gpg: Fix memory leak in ECC encryption.
26560         + commit 98f65291d7abecc1e4d618125f33b6ce759e0892
26561         * g10/pkglue.c (pk_encrypt): Fix memory leak and streamline error
26562         handling.
26563
26564 2014-09-02  Werner Koch  <wk@gnupg.org>
26565
26566         gpg: Fix export of NIST ECC keys.
26567         + commit bf2fc12b83b45953f7afa403b8d91c36d0b50ec9
26568         * common/openpgp-oid.c (struct oidtable): New.
26569         (openpgp_curve_to_oid): Rewrite and allow OID as input.
26570         (openpgp_oid_to_curve): Make use of the new table.
26571
26572         agent: Fix import of OpenPGP EdDSA keys.
26573         + commit afe85582ddc2ebc285728bf6417f8929fd0b3281
26574         * agent/cvt-openpgp.c (get_keygrip): Special case EdDSA.
26575         (convert_secret_key): Ditto.
26576         (convert_transfer_key): Ditto.
26577         (apply_protection): Handle opaque MPIs.
26578
26579         (do_unprotect): Check FLAG_OPAQUE instead of FLAG_USER1 before
26580         unpacking an opaque mpi.
26581
26582 2014-09-01  Kyle Butt  <kylebutt@gmail.com>
26583
26584         gpg: Fix export of ecc secret keys by adjusting check ordering.
26585         + commit 4054d86abcb7ad953ed9e988b1765cb9266faefd
26586         * g10/export.c (transfer_format_to_openpgp): Move the check against
26587         PUBKEY_MAX_NSKEY to after the ECC code adjusts the number of
26588         parameters.
26589
26590 2014-09-01  Werner Koch  <wk@gnupg.org>
26591
26592         agent: Allow key unprotection using AES-256.
26593         + commit c913e09ebdbb1a1e9838a0a5897448841f5e9bc3
26594         * agent/protect.c (PROT_CIPHER): Rename to GCRY_CIPHER_AES128 for
26595         clarity.
26596         (do_decryption): Add args prot_cipher and prot_cipher_keylen.  USe
26597         them instead of the hardwired values.
26598         (agent_unprotect): Change to use a table of protection algorithms.
26599         Add AES-256 variant.
26600
26601 2014-08-28  Werner Koch  <wk@gnupg.org>
26602
26603         gpg: Do not show "MD5" and triplicated "RSA" in --version.
26604         + commit be98b5960ebd48929c399b0b91c95bfc0cb9749b
26605         * g10/gpg.c (build_list_pk_test_algo): Ignore RSA aliases
26606         (build_list_md_test_algo): Ignore MD5.
26607
26608         gpg: Do not show "MD5" and triplicated "RSA" in --version.
26609         + commit 40ad42dbe3c67d8103aedb6b584f4bedc5f93307
26610         * g10/gpg.c (build_list_pk_test_algo): Ignore RSA aliases
26611         (build_list_md_test_algo): Ignore MD5.
26612
26613 2014-08-26  Werner Koch  <wk@gnupg.org>
26614
26615         gpg: Remove CAST5 from the default prefs and order SHA-1 last.
26616         + commit 15cfd9a3bcdd561091a28c8f989c616b87348463
26617         * g10/keygen.c (keygen_set_std_prefs): Update prefs.
26618
26619         Switch to the libgpg-error provided estream.
26620         + commit 519305feb888b529c005b40445d041a088a2f8fc
26621         * configure.ac (NEED_GPG_ERROR_VERSION): Reguire 1.14.
26622         (GPGRT_ENABLE_ES_MACROS): Define.
26623         (estream_INIT): Remove.
26624         * m4/estream.m4: Remove.
26625         * common/estream-printf.c, common/estream-printf.h: Remove.
26626         * common/estream.c, common/estream.h: Remove.
26627         * common/init.c (_init_common_subsystems): Call gpgrt initialization.
26628
26629         gpg: Allow for positional parameters in the passphrase prompt.
26630         + commit a731c22952278c12c601b73d7581fda3a15a4b5b
26631         * g10/passphrase.c (passphrase_get): Replace sprintf by xasprintf.
26632
26633 2014-08-20  Werner Koch  <wk@gnupg.org>
26634
26635         gpg: Fix "can't handle public key algorithm" warning.
26636         + commit cb680c5ea540738692a5c74951802b0fdc658e85
26637         * g10/parse-packet.c (unknown_pubkey_warning): Check for encr/sign
26638         capabilities.
26639
26640 2014-08-19  Werner Koch  <wk@gnupg.org>
26641
26642         speedo: Get version numbers from online database.
26643         + commit 31649e72fd106a990614ce3cf720640a841ba722
26644         * build-aux/getswdb.sh: New.
26645         * build-aux/speedo.mk: Get release version numbers from swdb.lst.
26646
26647         build: Create VERSION file via autoconf.
26648         + commit 4fc1c712e986f280057b1bce7ca4696ba6d95dfc
26649         * Makefile.am (dist-hook): Remove creation of VERSION.
26650         (EXTRA_DIST): Add VERSION.
26651         * configure.ac: Let autoconf create VERSION.
26652
26653 2014-08-18  Werner Koch  <wk@gnupg.org>
26654
26655         gpg: Install the current release signing pubkey.
26656         + commit e5da80bc1888bf8801e69c9ff99f7f47550f7a09
26657         * g10/distsigkey.gpg: New.
26658
26659         agent: Return NO_SECKEY instead of ENONET for PKSIGN and others.
26660         + commit 3981ff15f3c0829ba22cd37794353502d996683c
26661         * agent/pksign.c (agent_pksign_do): Replace ENONET by NO_SECKEY.
26662         * agent/findkey.c (agent_key_from_file): No diagnostic for NO_SECKEY.
26663         * agent/pkdecrypt.c (agent_pkdecrypt): Replace checking for ENOENT.
26664
26665         kbx: Make user id and signature data optional for OpenPGP.
26666         + commit e4aa006e4807285ffdd881e4e05af3bc47c5c964
26667         * kbx/keybox-blob.c (_keybox_create_openpgp_blob): Remove restriction.
26668
26669         gpg: Change default cipher for --symmetric from CAST5 to AES-128.
26670         + commit 57df1121c18b004dd763b35eabf7b51fc9e8ec38
26671         * g10/main.h (DEFAULT_CIPHER_ALGO): Chhange to AES or CAST5 or 3DES
26672         depending on configure option.
26673         * g10/gpg.c (main): Set opt.s2k_cipher_algo to DEFAULT_CIPHER_ALGO.
26674
26675         yat2m: Support @set and @value.
26676         + commit 425d0750168f6b66a5d78a857cf21375a8f129eb
26677         * doc/yat2m.c (variablelist): New.
26678         (set_variable): New.
26679         (macro_set_p): Also check the variables.
26680         (proc_texi_cmd): Support the @value command.
26681         (parse_file): Support the @set command.
26682         (top_parse_file): Release variablelist.
26683
26684         yat2m: Support the $* command for man page rendering.
26685         + commit 7e51ef0f77962f5fb215da53817caf28899ca190
26686
26687
26688 2014-08-17  Werner Koch  <wk@gnupg.org>
26689
26690         estream: Change license from GPL to LPGL.
26691         + commit af1196512f505e8a3a338f9b72394fa3585a5234
26692         * common/estream-printf.c, common/estream-printf.h: Change license.
26693         * common/estream.c, common/estream.h: Ditto.
26694
26695 2014-08-14  Werner Koch  <wk@gnupg.org>
26696
26697         Release 2.1.0-beta783.
26698         + commit a13198d9bcee368a8de7a401feb017efc83ff795
26699
26700
26701         po: Update the German (de) translation.
26702         + commit fe9ff33b9dc8793957998341cf4bcf5e50827b41
26703
26704
26705         sm: Create homedir and lock empty keybox creation.
26706         + commit c4b60cdae8dbf68206fd105fd09adeb61a9dafe4
26707         * sm/gpgsm.h (opt): Add field "no_homedir_creation".
26708         * sm/gpgsm.c (main): Set it if --no-options is used.
26709         * sm/keydb.c (try_make_homedir): New.  Similar to the one from
26710         g10/openfile.c.
26711         (maybe_create_keybox): New.  Similar to the one from g10/keydb.c.
26712         (keydb_add_resource): Replace some code by maybe_create_keybox.
26713
26714         gpg: Screen keyserver responses.
26715         + commit c23c18c1543d1ff58f0f78baaa6a8e319c659ecb
26716         * g10/main.h (import_screener_t): New.
26717         * g10/import.c (import): Add screener callbacks to param list.
26718         (import_one): Ditto.
26719         (import_secret_one): Ditto.
26720         (import_keys_internal): Ditto.
26721         (import_keys_stream): Ditto.
26722         * g10/keyserver.c (struct ks_retrieval_screener_arg_s): New.
26723         (keyserver_retrieval_screener): New.
26724         (keyserver_get): Pass screener to import_keys_es_stream().
26725
26726         scd: Minor changes to app-sc-hsm.
26727         + commit a61b28df1f29b1e306115282ec1ce580fa54945a
26728         * scd/app-sc-hsm.c: Re-indendet some parts and set some vars to NULL
26729         after xfree for improbed robustness.
26730         (read_ef_prkd): Replace serial operator by blocks for better
26731         readability.
26732         (apply_PKCS_padding): Rewrite for easier auditing.
26733         (strip_PKCS15_padding): Ditto.  Add stricter check on SRCLEN.
26734
26735         gpg: Disable an MD5 workaround for pgp2 by default.
26736         + commit ae29b52119aa419989b773b2d6abb6e287dfc81b
26737         * g10/sig-check.c (do_check): Move some code to ...
26738         * g10/misc.c (print_md5_rejected_note): new function.
26739         * g10/mainproc.c (proc_tree, proc_plaintext): Enable MD5 workaround
26740         only if option --allow-weak-digest-algos is used.
26741
26742         gpg: Remove options --pgp2 and --rfc1991.
26743         + commit 2b8d8369d59249b89526c18c5ac276e6445dc35e
26744         * g10/gpg.c (oRFC1991, oPGP2): Remove
26745         (opts): Remove --pgp2 and --rfc1991.
26746         * g10/options.h (CO_PGP2, CO_RFC1991): Remove.  Remove all users.
26747         (RFC2440, PGP2): Remove.  Remove all code only enabled by these
26748         conditions.
26749         * tests/openpgp/clearsig.test: Remove --rfc1991 test.
26750
26751         build: Fix autogen.sh base version hack.
26752         + commit 49c9a958e0b786850309bca555d4465c97d337e1
26753         * autogen.sh <find-version>: Fix.
26754
26755         gpg: Remove --compress-keys and --compress-sigs feature.
26756         + commit 71b55e91f02cdb65a8884892f71c4c7bf8a75247
26757         * g10/gpg.c (oCompressKeys, oCompressSigs): Remove.
26758         (opts): Turn --compress-keys and --compress-signs in NOPs.
26759         * g10/options.h (opt): Remove fields compress_keys and compress_sigs.
26760         * g10/export.c (do_export): Remove compress_keys feature.
26761         * g10/sign.c (sign_file): Remove compress_sigs feature.
26762
26763 2014-08-13  Werner Koch  <wk@gnupg.org>
26764
26765         gpg: Add list-option "show-usage".
26766         + commit 7d0492075ea638607309b3ea6a792b0e95ea7d98
26767         * g10/gpg.c (parse_list_options): Add "show-usage".
26768         * g10/options.h (LIST_SHOW_USAGE): New.
26769         * g10/keyid.c (usagestr_from_pk): Add arg FILL.  Change caller.
26770         * g10/keylist.c (list_keyblock_print): Print usage info.
26771
26772 2014-08-12  Werner Koch  <wk@gnupg.org>
26773
26774         gpg: Make --with-colons work again for --search-keys.
26775         + commit a57c33c855c6757c8770529ee71f0f90744cd7a6
26776         * g10/keyserver.c (search_line_handler): Replace log_debug by
26777         es_printf.
26778
26779 2014-08-08  NIIBE Yutaka  <gniibe@fsij.org>
26780
26781         po: Update Japanese translation.
26782         + commit 2d9f76e07082fc231303ac2c6ae1aea3c98fa2e4
26783
26784
26785 2014-07-25  Werner Koch  <wk@gnupg.org>
26786
26787         scd: Minor and editorial changes to app-sc-hsm.c.
26788         + commit 2e936915cf2f830e60d974d607b08822645f5753
26789         * scd/app-sc-hsm.c (select_and_read_binary): Use SW_ macro.
26790         (parse_certid): Remove useless test.
26791         (send_certinfo, send_keypairinfo): Shrink malloc to the needed size.
26792         (do_getattr): Ditto.
26793         (verify_pin): Use SW_ macro.
26794         (do_decipher): Replace OFS variable and extend comment.
26795
26796         scd: Add a new status word code.
26797         + commit e49c851ff54d5ecf856411bf6cdee721695ea172
26798         * scd/apdu.h (SW_REF_DATA_INV): New.
26799         * scd/apdu.c (apdu_strerror): Add string.
26800
26801 2014-07-25  Andreas Schwier  <andreas.schwier@cardcontact.de>
26802
26803         scd: Support for SmartCard-HSM.
26804         + commit 8eb9224f32ddf1c9e1490c4d9688a177f8b6ae64
26805         * scd/app-sc-hsm.c: New.
26806         * scd/app.c (select_application, get_supported_applications): Register
26807         new app.
26808
26809 2014-07-25  Werner Koch  <wk@gnupg.org>
26810
26811         gpg: Switch to an EdDSA format with prefix byte.
26812         + commit 557cc11a605dd280d03c52d8b546deed8c4c714d
26813         * g10/keygen.c (gen_ecc): USe "comp" for EdDSA.
26814
26815 2014-07-23  Werner Koch  <wk@gnupg.org>
26816
26817         agent: Show just one warning with all failed passphrase constraints.
26818         + commit b3378b3a56fc90ba8ae38e6298b23a378305af32
26819         * agent/genkey.c (check_passphrase_constraints): Build a final warning
26820         after all checks.
26821
26822         agent: Only one confirmation prompt for an empty passphrase.
26823         + commit a24510d53bb23e3a680ed2c306e576268c07060d
26824         * agent/genkey.c (check_passphrase_constraints): Moev empty passphrase
26825         check to the front.
26826
26827         gpg: Add command --quick-gen-key.
26828         + commit ea186540db5b418bc6f6e5ca90337672c9981c88
26829         * g10/gpg.c (aQuickKeygen): New.
26830         * g10/misc.c (is_valid_user_id): New stub.
26831         * g10/keygen.c (quickgen_set_para): New.
26832         (quick_generate_keypair): New.
26833
26834         common: Add cpr_get_answer_is_yes_def()
26835         + commit 75127bc4561787aa9bc1cf976658e20192446d7f
26836         * g10/cpr.c (cpr_get_answer_is_yes): Factor code out to ....
26837         (cpr_get_answer_is_yes_def): ...new.
26838
26839         gpg: Make --quick-sign-key promote local key signatures.
26840         + commit 17404b2fccbc74c4f0b2364cc08e9dcc64175cf8
26841         * g10/keyedit.c (sign_uids): Promote local sigs in quick mode.
26842
26843 2014-07-22  Werner Koch  <wk@gnupg.org>
26844
26845         scd: Do not use the pcsc-wrapper.
26846         + commit bc6b452129178658da7241903ca2174c79281752
26847         * scd/apdu.c (NEED_PCSC_WRAPPER): Do not define.
26848         * scd/Makefile.am (libexec_PROGRAMS): Remove gnupg-pcsc-wrapper
26849         (gnupg_pcsc_wrapper_SOURCES): Remove.
26850         (gnupg_pcsc_wrapper_LDADD): Remove.
26851         (gnupg_pcsc_wrapper_CFLAGS): Remove.
26852
26853 2014-07-21  Werner Koch  <wk@gnupg.org>
26854
26855         gpg: Improve --list-packets output for faulty packets.
26856         + commit 5b34e347b612765f31061d077b7c343e08662ba9
26857         * g10/parse-packet.c: Add list_mode output for certain failures.
26858
26859         gpg: Cap size of attribute packets at 16MB.
26860         + commit bab9cdd971f35ff47e153c00034c95e7ffeaa09a
26861         * g10/parse-packet.c (parse_attribute): Avoid xmalloc failure and cap
26862         size of packet.
26863
26864 2014-07-03  Werner Koch  <wk@gnupg.org>
26865
26866         Release 2.1.0-beta751.
26867         + commit 5ae34f574baca2b98a09fd982c941855558408e1
26868
26869
26870         gpg: Make show-uid-validity the default.
26871         + commit 5214d8f02bf65fb0a4af15ff80cf1369ccd4c167
26872
26873
26874         tests: Fix end-of-all-ticks test for Western locales.
26875         + commit 3533860ee316918dd47501c53e910bfd0032b39d
26876         * common/t-timestuff.c (test_timegm): Use timegm if available.
26877         (main): Set TX to UTC if timegm is not available.
26878
26879 2014-07-03  Kristian Fiskerstrand  <kf@sumptuouscapital.com>
26880
26881         gpg: Spelling error.
26882         + commit b51af333bdf77c042c9fe748616e80d1f5e4d3f9
26883
26884
26885 2014-06-30  Werner Koch  <wk@gnupg.org>
26886
26887         gpg: Auto-create revocation certificates.
26888         + commit 03018ef9eec75e4d91ea53c95547a77dedef8f80
26889         * configure.ac (GNUPG_OPENPGP_REVOC_DIR): New config define.
26890         * g10/revoke.c (create_revocation): Add arg "leadin".
26891         (gen_standard_revoke): New.
26892         * g10/openfile.c (get_openpgp_revocdir): New.
26893         (open_outfile): Add MODE value 3.
26894         * g10/keyid.c (hexfingerprint): New.
26895         * g10/keygen.c (do_generate_keypair): Call gen_standard_revoke.
26896
26897         estream: Fix minor glitch in "%.*s" format.
26898         + commit aa5b4392aac99382d96be94782ae745e0a42484a
26899         * common/estream-printf.c (pr_string): Take care of non-nul terminated
26900         strings.
26901
26902         gpg: Rearrange code in gen_revoke.
26903         + commit 3a01b220715b3d1a90d94353e4980ab5a1ea8f26
26904         * g10/revoke.c (gen_revoke): Factor some code out to ...
26905         (create_revocation): new.
26906
26907         gpg: Create exported secret files and revocs with mode 700.
26908         + commit c434de4d83ccfaca8bde51de5c2ac8d9656e4e18
26909         * common/iobuf.c (direct_open): Add arg MODE700.
26910         (iobuf_create): Ditto.
26911         * g10/openfile.c (open_outfile): Add arg RESTRICTEDPERM.  Change call
26912         callers to pass 0 for it.
26913         * g10/revoke.c (gen_desig_revoke, gen_revoke): Here pass true for new
26914         arg.
26915         * g10/export.c (do_export): Pass true for new arg if SECRET is true.
26916
26917         common: Minor code cleanup for a legacy OS.
26918         + commit 35fdfaa0b94342c53eb82eea155a37ad4009fa9f
26919         * common/iobuf.c (direct_open) [__riscos__]: Simply cpp conditionals.
26920
26921 2014-06-27  Werner Koch  <wk@gnupg.org>
26922
26923         speedo: Fix the w32 installer name.
26924         + commit adad1872b448593275d8cae06dffe376bee067b5
26925
26926
26927         po: Update some strings of the French (fr) translation.
26928         + commit 1ef7870fc96f6dd8137e9bfabf9b06787f75dffd
26929
26930
26931         po: Update the German (de) translation.
26932         + commit c2e3eb98884785e6794dc79c1a53d75945f4c1ab
26933
26934
26935         agent: Adjust for changed npth_eselect under W32.
26936         + commit a1dff86da8ebaab6e154360f538ca9d43a6c4934
26937         * agent/gpg-agent.c (handle_connections) [W32]: Make events_set an
26938         unsigned int to match the changed prototype.
26939
26940         dirmngr: Use the homedir based socket also under W32.
26941         + commit 5e1f9b5e1427688ac340f0829e02bece7f0caf9c
26942         * common/homedir.c (dirmngr_user_socket_name): Use same code for all
26943         platforms.
26944
26945 2014-06-27  Yuri Chornoivan  <yurchor@ukr.net>
26946
26947         po: Update and enable Ukrainian (uk) translation.
26948         + commit 2c4025576105a9deb78e1cfb22c11af4af09c4fa
26949
26950
26951         Fix typos in messages.
26952         + commit e56a2d6a56d95c0f169506a8dc74a845c22b699d
26953
26954
26955 2014-06-27  Werner Koch  <wk@gnupg.org>
26956
26957         build: Remove unused options.
26958         + commit 2540a4b674a17b45ec33f43f26e830e74ff0afed
26959         * configure.ac: Remove option --build-agent-only.
26960         (FAKE_CURL, GPGKEYS_CURL): Remove check for cURL
26961         (GPGKEYS_MAILTO): Remove ac_subst but keep the currently unused
26962         SENDMAIL check.
26963         (GPGKEYS_KDNS): Remove ac_subst.
26964         * autogen.rc (final_info): Remove suggestion to use the removed option
26965         --enable-mailto.
26966
26967 2014-06-27  NIIBE Yutaka  <gniibe@fsij.org>
26968
26969         scd: Add pinpad support for REINER SCT cyberJack go.
26970         + commit 73ba75ad8b933beddd2c3f4b66937b56faa0a2d8
26971         * scd/ccid-driver.h (VENDOR_REINER, CYBERJACK_GO): New.
26972         * scd/ccid-driver.c (ccid_transceive_secure): Handle the case for
26973         VENDOR_REINER. Original work was by Alina Friedrichsen (tiny change).
26974
26975 2014-06-27  Werner Koch  <wk@gnupg.org>
26976
26977         scd: Support reader Gemalto IDBridge CT30.
26978         + commit 24be0f24d3a9325a04de10ae0e5e277bf28a74fe
26979         * scd/ccid-driver.h (GEMPC_CT30): New product id.
26980         * scd/ccid-driver.c (parse_ccid_descriptor): Add quirk for that
26981         reader.
26982
26983 2014-06-26  Werner Koch  <wk@gnupg.org>
26984
26985         gpg: Limit keysize for unattended key generation to useful values.
26986         + commit 03f0b51fe454f8dbe77c302897f7a5899c4c5380
26987         * g10/keygen.c (gen_elg): Enforce keysize 1024 to 4096.
26988         (gen_rsa): Enforce keysize 1024 to 4096.
26989         (gen_dsa): Enforce keysize 768 to 3072.
26990
26991         Enable DNS SRV records again.
26992         + commit c0d1e7fca95629e1cddd7d129fa51b9a6556cb70
26993         * configure.ac (GPGKEYS_HKP, GPGKEYS_FINGER): Remove ac_subst.
26994         (use_dns_srv): Make test work.
26995
26996         agent: Fix export of RSA keys to OpenPGP.
26997         + commit 9a034acf8ab6f85c65ccc75a4fd7b8dd47b73e3a
26998         * agent/cvt-openpgp.c (convert_transfer_key): Fix sexp build format
26999         string.
27000
27001         gpg,gpgsm: Simplify wrong_args function.
27002         + commit 572502bd2c0637429bca547ba882629640477495
27003
27004
27005         speedo: "make clean-gnupg" may not remove the source.
27006         + commit c029a184d6a1a96c6de234835fff97d4e946b19c
27007         * build-aux/speedo.mk (clean-$(1)): Take care of gnupg.
27008
27009         gpgsm: Fix default config name.
27010         + commit 2480b0253166712a2f20b92f34c8e4c2db0fc26f
27011
27012
27013 2014-06-25  Werner Koch  <wk@gnupg.org>
27014
27015         doc: Improve the rendering of the manual.
27016         + commit b5f95c1b566f9530127f3f34e10d120a951cf428
27017
27018
27019         doc: Update for modern makeinfo.
27020         + commit f149e05427a370f5985bc3fb142370b043f19924
27021         * doc/texi.css: Remove.
27022         * doc/Makefile.am (AM_MAKEINFOFLAGS): Use --css-ref.
27023
27024         gpg: Allow key-to-card upload for cert-only keys.
27025         + commit f171fd226e84311f92545ca0494771db07ba777d
27026         * g10/card-util.c (card_store_subkey): Allo CERT usage for key 0.
27027
27028 2014-06-24  Werner Koch  <wk@gnupg.org>
27029
27030         doc: Add conditionals for GnuPG-1.
27031         + commit 2c8e00137a340d04f0836f75e138dd85f8c9eff7
27032
27033
27034 2014-06-20  Werner Koch  <wk@gnupg.org>
27035
27036         gpg: Make export of ECC keys work again.
27037         + commit f4fcaa29367daacfe0ca209fa83dfa8640ace276
27038         * agent/cvt-openpgp.c (convert_to_openpgp): Use the curve name instead
27039         of the curve parameters.
27040         * g10/export.c (canon_pubkey_algo): Rename to ...
27041         (canon_pk_algo): this.  Support ECC.
27042         (transfer_format_to_openpgp): Expect curve name.
27043
27044         gpg: Avoid infinite loop in uncompressing garbled packets.
27045         + commit d6ca407a27877174c10adfae9dc601bea996cf27
27046         * g10/compress.c (do_uncompress): Limit the number of extra FF bytes.
27047
27048 2014-06-17  Kristian Fiskerstrand  <kf@sumptuouscapital.com>
27049
27050         gpg: Fix a couple of spelling errors.
27051         + commit 3f17b74aa57ac1ea2f3aa93dec4889778a21afeb
27052
27053
27054 2014-06-17  Werner Koch  <wk@gnupg.org>
27055
27056         speedo: Support building from dist-source generated tarball.
27057         + commit 47e63dc00169030b6ff01ab67e73e52aec1395db
27058
27059
27060 2014-06-13  Werner Koch  <wk@gnupg.org>
27061
27062         http: Print human readable GNUTLS status.
27063         + commit 5bf04522e353675e4c3eda118fee2580756704a2
27064         * common/http.c (send_gnutls_bye): Take care of EAGAIN et al.
27065         (http_verify_server_credentials): Print a human readable status.
27066
27067 2014-06-12  Werner Koch  <wk@gnupg.org>
27068
27069         gpg: Improve the output of --list-packets.
27070         + commit d8314e31c58ea0827d0e2361dabcdf869ab08fce
27071         * g10/parse-packet.c (parse): Print packet meta info in list mode.
27072
27073 2014-06-11  Werner Koch  <wk@gnupg.org>
27074
27075         speedo: Improve building of the w32 installer.
27076         + commit 6eeb31abee82cb2016bf054cd302af64f6dfdc2e
27077         * build-aux/speedo.mk: Change name of build directory to PLAY.
27078         Improve the dist-source target.
27079         * build-aux/speedo/w32/gdk-pixbuf-loaders.cache: Add a blank
27080         line (plus comment).
27081         * build-aux/speedo/w32/inst.nsi: Change name of file to gnupg-w32-*.
27082         Install more tools.
27083
27084 2014-06-10  Werner Koch  <wk@gnupg.org>
27085
27086         speedo: Revamped speedo and include a w32 installer.
27087         + commit e06d5d1a3b4a5c446a27d64cd2da0e48ccec5601
27088         * build-aux/speedo/: New.
27089         * build-aux/speedo/w32/: New.
27090
27091         build: Add more options to autogen.sh.
27092         + commit 0399d87f7aaf2f2126a63899004c5c7bffd4346b
27093         * autogen.sh: Add options --print-host and --print-build.
27094
27095         w32: Fix build problem with dirmngr.
27096         + commit 141d69cb2a94a752244e89f49611923a2f184dfd
27097         * dirmngr/ks-engine-hkp.c (EAI_SYSTEM) [W32]: Add replacement
27098         constant.
27099
27100         gpg: Use more specific reason codes for INV_RECP.
27101         + commit 45ed901c466bd72118c2844069f566e190d847d6
27102         * g10/pkclist.c (find_and_check_key, build_pk_list): Use more specific
27103         reasons codes for INV_RECP.
27104
27105 2014-06-06  Werner Koch  <wk@gnupg.org>
27106
27107         Improve the beta number generation.
27108         + commit b67e4e523e6d19d384e23c5bb03010caebd150e7
27109         * autogen.sh: Add option --find-version
27110         * configure.ac: Rework the setting of the mym4_ variables.
27111
27112 2014-06-05  Werner Koch  <wk@gnupg.org>
27113
27114         Remove keyserver helper code.
27115         + commit 23712e69d3f97df9d789325f1a2f2f61e7d5bbb4
27116         * configure.ac: Remove keyserver helper related stuff.
27117         * Makefile.am (SUBDIRS): Remove keyserver.
27118         * keyserver/Makefile.am: Remove.
27119
27120         gpg: Require confirmation for --gen-key with experimental curves.
27121         + commit 9c9e26d41e7d65711da8dbf1afa452254749621c
27122         * g10/keygen.c (ask_curve): Add arg both.  Require confirmation for
27123         Curve25519.
27124
27125         gpg: Auto-migrate existing secring.gpg.
27126         + commit 4f0625889b768eabdec52696bf15059a9e8d9c02
27127         * g10/migrate.c: New.
27128         * g10/import.c (import_old_secring): New.
27129         (import_one): Add arg silent.
27130         (transfer_secret_keys): Add arg batch.
27131         (import_secret_one): Add args batch and for_migration.
27132         * g10/gpg.c (main): Call migration function.
27133
27134 2014-06-04  Werner Koch  <wk@gnupg.org>
27135
27136         gpgsm: Fix commit be07ed65.
27137         + commit 09a2d4ec74d352dcb4f006aab60b07bc4f5f1a37
27138         * sm/server.c (option_handler): Use "with-secret".
27139
27140 2014-06-03  Werner Koch  <wk@gnupg.org>
27141
27142         Add new option --with-secret.
27143         + commit be07ed65e169a7ec3fbecdb1abf988fc0245d9ff
27144         * g10/gpg.c: Add option --with-secret.
27145         * g10/options.h (struct opt): Add field with_secret.
27146         * g10/keylist.c (public_key_list): Pass opt.with_secret to list_all
27147         and list_one.
27148         (list_all, list_one): Add arg mark_secret.
27149         (list_keyblock_colon): Add arg has_secret.
27150         * sm/gpgsm.c: Add option --with-secret.
27151         * sm/server.c (option_handler): Add option "with-secret".
27152         * sm/gpgsm.h (server_control_s): Add field with_secret.
27153         * sm/keylist.c (list_cert_colon): Take care of with_secret.  Also move
27154         the token string from the wrong field 14 to 15.
27155
27156         gpgsm: New commands --export-secret-key-{p8,raw}
27157         + commit 0beec2f0f255a71f9d5a4a0729d0259f673e8838
27158         * sm/gpgsm.c: Add new commands.
27159         * sm/minip12.c (build_key_sequence): Add arg mode.
27160         (p12_raw_build): New.
27161         * sm/export.c (export_p12): Add arg rawmode.  Call p12_raw_build.
27162         (gpgsm_p12_export): Ditto.
27163         (print_short_info): Print the keygrip.
27164
27165 2014-06-02  Werner Koch  <wk@gnupg.org>
27166
27167         gpg: Avoid NULL-deref in default key listing.
27168         + commit 958e5f292fa3f8e127f54bc088c56780c564dcae
27169         * g10/keyid.c (hash_public_key): Take care of NULL keys.
27170         * g10/misc.c (pubkey_nbits): Ditto.
27171
27172         gpg: Simplify default key listing.
27173         + commit f3249b1c4d0f2e9e0e8956042677e47fc9c6f6c0
27174         * g10/mainproc.c (list_node): Rework.
27175
27176         gpg: Graceful skip reading of corrupt MPIs.
27177         + commit d9cde7ba7d4556b216f062d0cf92d60cbb204b00
27178         * g10/parse-packet.c (mpi_read): Change error message on overflow.
27179
27180         gpgsm: Handle re-issued CA certificates in a better way.
27181         + commit 715285bcbc12c024dbd9b633805189c09173e317
27182         * sm/certchain.c (find_up_search_by_keyid): Consider all matching
27183         certificates.
27184         (find_up): Add some debug messages.
27185
27186         gpgsm: Add a way to save a found state.
27187         + commit 42c043a8ad542c131917879c9b458f234b4bb645
27188         * kbx/keybox-defs.h (keybox_found_s): New.
27189         (keybox_handle): Factor FOUND out to above.  Add saved_found.
27190         * kbx/keybox-init.c (keybox_release): Release saved_found.
27191         (keybox_push_found_state, keybox_pop_found_state): New.
27192
27193         * sm/keydb.c (keydb_handle): Add field saved_found.
27194         (keydb_new): Init it.
27195         (keydb_push_found_state, keydb_pop_found_state): New.
27196
27197         gpg: Fix bug parsing a zero length user id.
27198         + commit 99972bd6e9abea71f270284f49997de5f00208af
27199         * g10/getkey.c (get_user_id): Do not call xmalloc with 0.
27200
27201         * common/xmalloc.c (xmalloc, xcalloc): Take extra precaution not to
27202         pass 0 to the arguments.
27203
27204 2014-05-19  Werner Koch  <wk@gnupg.org>
27205
27206         dirmngr: Print certificates on failed TLS verification.
27207         + commit 9e1c99f8009f056c39a7465b91912c136b248e8f
27208         * dirmngr/ks-engine-hkp.c (cert_log_cb): New.
27209         (send_request): Set callback.
27210
27211         http: Add callback to help logging of server certificates.
27212         + commit 45f15b2d767d4068f79fd5b123e9eeae08a0616d
27213         * common/http.c (http_session_s): Add field cert_log_cb.
27214         (http_session_set_log_cb): New.
27215         (http_verify_server_credentials): Call callback.
27216
27217 2014-05-16  Werner Koch  <wk@gnupg.org>
27218
27219         keyserver: Improve support for hkps pools.
27220         + commit d2d9d4fb60e3f2160af6252335364d3aac4b7d17
27221         * dirmngr/ks-engine-hkp.c (hostinfo_s): Add fields cname, v4addr, and
27222         v6addr.
27223         (create_new_hostinfo): Clear them.
27224         (my_getnameinfo): Add args numeric and r_isnumeric.
27225         (is_ip_address): New.
27226         (map_host): Add arg r_host.  Rewrite the code to handle pools in a
27227         special way.
27228         (ks_hkp_print_hosttable): Change format of help info output.
27229         (make_host_part): Add arg optional r_httphost.
27230         (send_request): Add arg httphost.
27231         (ks_hkp_search, ks_hkp_get, ks_hkp_put): Get httphost and pass it to
27232         send_request.
27233
27234         http: Allow overriding of the Host header.
27235         + commit 8b90d79818355b81ce223e1cb96cd0c939096fe2
27236         * common/http.c (http_open): Add arg httphost.
27237         (http_open_document): Pass NULL for httphost.
27238         (send_request): Add arg httphost.  If given, use HTTPHOST instead of
27239         SERVER.  Use https with a proxy if requested.
27240         (http_verify_server_credentials): Do not stop at the first error
27241         message.
27242         * dirmngr/ocsp.c (do_ocsp_request): Adjust call to http_open.
27243         * keyserver/curl-shim.c (curl_easy_perform): Ditto.
27244         * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
27245         * dirmngr/ks-engine-hkp.c (ks_hkp_help): Ditto.
27246
27247 2014-05-14  Werner Koch  <wk@gnupg.org>
27248
27249         gpg: Fix uninitialized access to search descindex with gpg keyboxes.
27250         + commit 25036ec6abbc0c9d0003dcfe227724038c35a304
27251         * kbx/keybox-search.c (keybox_search): Add arg  R_DESCINDEX.  Chnage
27252         both callers.
27253         * g10/keydb.c (keydb_search): Always set DESCINDEX.
27254
27255         w32: Make make_absfilename work with drive letters.
27256         + commit 71fa6a35107d4d4547eb9155d7c2612b6a6a16fb
27257         * common/stringhelp.c (do_make_filename) [HAVE_DRIVE_LETTERS]: Fix.
27258
27259         gpg: Remove useless diagnostic in MDC verification.
27260         + commit 455a4a2212302c05095e736b127f647e95714fe7
27261         * g10/decrypt-data.c (decrypt_data): Do not distinguish between a bad
27262         MDC packer header and a bad MDC.
27263
27264         gpg: Fix glitch entering a full expiration time.
27265         + commit b2945c451d3d3f25ba11a9fe88c6cbf3f88c2fb5
27266         * g10/keygen.c (ask_expire_interval): Get the current time after the
27267         prompt.
27268
27269 2014-05-08  Werner Koch  <wk@gnupg.org>
27270
27271         agent: Fix import of non-protected gpg keys.
27272         + commit 4aeb02562c9db4b96366220b781e2b4fa2d6fd3b
27273         * agent/cvt-openpgp.c (do_unprotect): Return an s-exp also for
27274         non-protected keys.
27275         (convert_from_openpgp_main): Do not call agent_askpin for a
27276         non-protected key.
27277
27278         Make more use of *_NAME macros.
27279         + commit cb2aeb4e1157fc0d7dc25d94115973422dc1a800
27280         * configure.ac (GPG_DISP_NAME, GPGSM_DISP_NAME): New.
27281         (GPG_AGENT_DISP_NAME, SCDAEMON_DISP_NAME): New.
27282         (DIRMNGR_DISP_NAME, G13_DISP_NAME): New.
27283         (GPGCONF_DISP_NAME): New.
27284         (SCDAEMON_SOCK_NAME): New.
27285         * common/argparse.c (show_help): Map description string.
27286
27287 2014-05-08  NIIBE Yutaka  <gniibe@fsij.org>
27288
27289         agent: Fix auth key comment handling.
27290         + commit fb24808db9af9dfe36f9f6d7fc24e0b903ecc12c
27291         * agent/command-ssh.c (ssh_send_key_public): Handle the case with no
27292         comment.
27293
27294 2014-05-07  Werner Koch  <wk@gnupg.org>
27295
27296         Make -jN work again.
27297         + commit 57011da53e43f9c8a6c7e7314166c3e17ff8627a
27298         * common/Makefile.am ($(PROGRAMS)): New rule
27299         (t_http_LDADD): Use libcommontls.a without directory prefix.
27300         * dirmngr/Makefile.am ($(PROGRAMS)): New rule.
27301
27302         gpg: Print the key algorithm/curve with signature info.
27303         + commit 359c643d747c890f73f68b42e0aeb896016f05fd
27304         * g10/mainproc.c (check_sig_and_print): Print the name and curve.
27305
27306         gpg: Fix memleak in signature verification of bogus keys.
27307         + commit e73edfb1759d05121ea66f67c775e763bf47d737
27308         * g10/mainproc.c (check_sig_and_print): Factor common code out to ...
27309         (print_good_bad_signature): here.
27310
27311         gpg: Mark experimental algorithms in the key listing.
27312         + commit 09055aa0f7993aaf4dcffdd80d8192945ae6080a
27313         * g10/keylist.c (list_keyblock_print): Remove duplicate curve name.
27314         Print a note for experimental algorithms.
27315         * g10/misc.c (print_pubkey_algo_note): Fix warning message.
27316
27317         gpg: Finish experimental support for Ed25519.
27318         + commit 8fee6c1ce6d116fe7909dbe1184d95bc91305484
27319         * agent/cvt-openpgp.c (try_do_unprotect_arg_s): Add field "curve".
27320         (get_keygrip): Add and use arg CURVE.
27321         (convert_secret_key): Ditto.
27322         (convert_transfer_key): Ditto.
27323         (get_npkey_nskey): New.
27324         (prepare_unprotect): Replace gcrypt functions by
27325         get_npkey_nskey.  Allow opaque MPIs.
27326         (do_unprotect): Use CURVE instead of parameters.
27327         (convert_from_openpgp_main): Ditto.
27328         (convert_to_openpgp):  Simplify.
27329         * g10/import.c (one_mpi_from_pkey): Remove.
27330         (transfer_secret_keys): Rewrite to use the curve instead of the
27331         parameters.
27332         * g10/parse-packet.c (parse_key): Mark protected MPIs with USER1 flag.
27333
27334         * common/openpgp-oid.c (openpgp_curve_to_oid): Allow the use of
27335          "NIST P-256" et al.
27336         * g10/keygen.c (ask_curve): Add arg ALGO.
27337         (generate_keypair): Rewrite the ECC key logic.
27338
27339         * tests/openpgp/ecc.test: Provide the "ecc" passphrase.
27340
27341         kbx: Add experimental support for EDDSA.
27342         + commit bdb9c2b314400da9155b8a924e22e486793dda89
27343         * kbx/keybox-openpgp.c (parse_key): Use algo constants and add
27344         experimental support for EdDSA.
27345
27346         agent: Remove greeting message.
27347         + commit a63ed9875830e5b3b4d48b7d97d24c18de36b326
27348         * agent/gpg-agent.c (main): Remove greeting.  Make --no-greeting a
27349         dummy.
27350
27351 2014-05-06  Werner Koch  <wk@gnupg.org>
27352
27353         Use "samethread" mode keyword for some es_fopenmem.
27354         + commit 6477e51919ef97f0f9cc05d10cdc7aa2b89faafe
27355         * dirmngr/ks-engine-hkp.c (armor_data): Add mode keyword.
27356         * g10/call-dirmngr.c (ks_put_inq_cb): Ditto.
27357         * scd/atr.c (atr_dump): Ditto.
27358
27359 2014-05-05  Werner Koch  <wk@gnupg.org>
27360
27361         dirmngr: Add support for hkps keyservers.
27362         + commit 60e2fc7d38d8b37d1de944cf230e410c2ce37d5e
27363         * dirmngr/dirmngr.c: Include gnutls.h.
27364         (opts): Add --gnutls-debug and --hkp-cacert.
27365         (opt_gnutls_debug, my_gnutls_log): New.
27366         (set_debug): Set gnutls log level.
27367         (parse_rereadable_options): Register a CA file.
27368         (main): Init GNUTLS.
27369         * dirmngr/ks-engine-hkp.c (ks_hkp_help): Support hkps.
27370         (send_request): Ditto.
27371
27372         http: Add reference counting to the session object.
27373         + commit ea0f5481f01eacedff264bf08144164aa989ec4d
27374         * common/http.c (http_session_t): Add field "refcount".
27375         (_my_socket_new, _my_socket_ref, _my_socket_unref): Add debug code.
27376         (send_request, my_npth_read, my_npth_write): Use SOCK object for the
27377         transport ptr.
27378         (http_session_release): Factor all code out to ...
27379         (session_unref): here.  Deref SOCK.
27380         (http_session_new): Init refcount and transport ptr.
27381         (http_session_ref): New.  Ref and unref all assignments.
27382
27383 2014-05-02  Werner Koch  <wk@gnupg.org>
27384
27385         http: Add HTTP_FLAG_FORCE_TLS and http_get_tls_info.
27386         + commit 0e59195642eb26263b8e0b9200290538631d35cd
27387         * common/http.c (http_parse_uri): Factor code out to ...
27388         (parse_uri): here.  Add arg FORCE_TLS.
27389         (do_parse_uri): Ditto.  Implement flag.
27390         (http_get_tls_info): New.
27391         (http_register_tls_ca): Allow clearing of the list.
27392         (send_request): Use a default verification function.
27393         * common/http.h (HTTP_FLAG_FORCE_TLS): New.
27394         * common/t-http.c (main): Add several command line options.
27395
27396         common: Fix test for openpgp_oid_is_ed25519.
27397         + commit 2def230231abd34f6012df284ab468321ffedc10
27398         * common/t-openpgp-oid.c (test_openpgp_oid_is_ed25519): Add correct
27399         value.
27400
27401         http: Revamp TLS API.
27402         + commit 8412a5825c225c8ff14de3ffaad2e55e040b2eca
27403         * configure.ac (NEED_GNUTLS_VERSION): New.
27404         (HTTP_USE_GNUTLS, LIBGNUTLS_CFLAGS, LIBGNUTLS_LIBS): New ac_subst.
27405
27406         * common/http.h (http_session_t): New.
27407         * common/http.c: Remove compatibility for gnutls < 3.0.
27408         (http_session_s): New.
27409         (cookie_s): Replace gnutls_session_t by http_session_t.
27410         (tls_callback, tls_ca_certlist): New variables.
27411         (my_socket_unref): Add preclose args.
27412         (my_npth_read, my_npth_write): New.
27413         (make_header_line): Fix bug using int* instead of char*.
27414         (http_register_tls_callback): New.
27415         (http_register_tls_ca): New.
27416         (http_session_new): New.
27417         (http_session_release): New.
27418         (http_get_header_names): New.
27419         (escape_data): Add hack to escape in forms mode.
27420         (send_request) [HTTP_USE_GNUTLS]: Support SNI.
27421         (send_request) [HTTP_USE_GNUTLS]: Fix use of make_header_line.
27422         (send_gnutls_bye): New.
27423         (cookie_close): Make use of preclose feature.
27424         (http_verify_server_credentials): New.
27425         (main) [TEST]: Remove test code.
27426         * common/t-http.c: New.
27427         * common/tls-ca.pem: New.
27428         * common/Makefile.am (tls_sources): New. Move http code to here.
27429         (libcommontls_a_SOURCES): New.
27430         (libcommontlsnpth_a_SOURCES): New.
27431         (EXTRA_DIST): Add tls-ca.pem
27432         (module_maint_tests): Add t-http.
27433         (t_http_SOURCES, t_http_CFLAGS, t_http_LDADD): New.
27434
27435         * dirmngr/Makefile.am (dirmngr_LDADD): Add libcommontlsnpth.
27436
27437         common: Cleanup the use of USE_NPTH and HAVE_NPTH macros.
27438         + commit 84289e85c72ae58c321dfdb96816700a6b7f7122
27439         * configure.ac (HAVE_NPTH): New ac_define.
27440         * common/estream.c: Use USE_NPTH instead of HAVE_NPTH.
27441         * common/http.c: Ditto.  Replace remaining calls to pth by npth calls.
27442         (connect_server): Remove useless _().
27443         * common/exechelp-posix.c, common/exechelp-w32.c
27444         * common/exechelp-w32ce.c: Use HAVE_PTH to include npth.h.
27445         * common/init.c (_init_common_subsystems): Remove call to pth_init.
27446         * common/sysutils.c (gnupg_sleep): Use npth_sleep.
27447         * scd/ccid-driver.c (my_sleep): Ditto.
27448
27449 2014-04-30  Werner Koch  <wk@gnupg.org>
27450
27451         estream: Implement "samethread" mode keyword.
27452         + commit 8416c875a729426eae05ed1ca9f1ebcb933c246a
27453         * src/estream.c (estream_internal): Add field SAMETHREAD.
27454         (init_stream_lock, lock_stream, trylock_stream, unlock_stream): Use it.
27455         (parse_mode): Add arg SAMETHREAD and parse that keyword.
27456         (es_initialize): Rename to ...
27457         (init_stream_obj): this.  Add arg SAMETHREAD.
27458         (es_create): Add arg SAMETHREAD.  Call init_stream_lock after
27459         init_stream_obj.
27460         (doreadline): Call es_create with samethread flag.
27461         (es_fopen, es_mopen, es_fopenmem, es_fopencookie, do_fdopen)
27462         (do_fpopen, do_w32open): Implement "samethread" keyword.
27463         (es_freopen): Take samthread flag from old stream.
27464         (es_tmpfile): Call es)_create w/o samethread.
27465
27466         estream: Fix deadlock in es_fileno.
27467         + commit ecea94461ed40f3f6ef662c2501e1d56ec284022
27468         * src/estream.c (es_fileno_unlocked): Call the unlocked functions.
27469
27470         estream: Add debug code to the lock functions.
27471         + commit aeb81727c77dfea3bf5d2d689ffbdc897f2938a7
27472         * common/estream.c (dbg_lock_0, dbg_lock_1, dbg_lock_1): New.
27473
27474         estream: Replace locking macros by functions.
27475         + commit 39e91a5f0a666aad2fef7a840b2cd03949bb1be4
27476         * common/estream.c: Replace most macros.
27477
27478 2014-04-28  NIIBE Yutaka  <gniibe@fsij.org>
27479
27480         ECC Fixes.
27481         + commit 21dab64030c95a909767bf6d8f99e8476f9df8a2
27482         * agent/cvt-openpgp.c (get_keygrip, convert_secret_key)
27483         (convert_transfer_key): Follow newer (>= 1.6) libgcrypt API, which
27484         does not distinguish the detail.
27485         (do_unprotect, convert_from_openpgp_main): Don't call
27486         map_pk_openpgp_to_gcry, as it's the value of libgcrypt API already and
27487         not the value defined by OpenPGP.
27488         (convert_to_openpgp): It's "ecc".
27489         * agent/gpg-agent.c (map_pk_openpgp_to_gcry): Remove.
27490         * g10/call-agent.c (agent_pkdecrypt): Fix off-by-one error.
27491         * g10/pubkey-enc.c (get_it): Fix swapping the fields error.
27492
27493 2014-04-22  Werner Koch  <wk@gnupg.org>
27494
27495         gpg: Pass --homedir to gpg-agent.
27496         + commit fdd938a5bbecb5b70f564ae3afb4e17905404bb2
27497         * agent/gpg-agent.c (main): Make sure homedir is absolute.
27498         * common/asshelp.c (lock_spawning): Create lock file with an absolute
27499         name.
27500         (start_new_gpg_agent): Use an absolute name for the socket and pass
27501         option --homedir to the agent.
27502         (start_new_dirmngr): Use an absolute name for the --homedir.
27503
27504         common: Add functions make_absfilename and make_absfilename_try.
27505         + commit 71a54313adf7b57b7b27bb9ad07b142a34306260
27506         * common/stringhelp.c (do_make_filename): Add modes 2 and 3.
27507         (make_absfilename): New.
27508         (make_absfilename_try): New.
27509
27510         common: Add function gnupg_getcwd.
27511         + commit 1a87edab6657a257876ab2f8790f2937feba7066
27512         * tools/gpg-connect-agent.c (gnu_getcwd): Move to ...
27513         * common/sysutils.c (gnupg_getcwd): .. here.
27514         * tools/gpg-connect-agent.c (get_var_ext): Use gnupg_getcwd.
27515
27516         gpg: Print a warning if GKR has hijacked gpg-agent.
27517         + commit ffa39be5ebfc1059a737905ee317c9b6f3d2a77e
27518         * g10/call-agent.c (check_hijacking): New.
27519         (start_agent): Call it.
27520         (membuf_data_cb, default_inq_cb): Move more to the top.
27521
27522 2014-04-17  Werner Koch  <wk@gnupg.org>
27523
27524         gpg: New %U expando for the photo viewer.
27525         + commit e184a11f94e2d41cd9266484542631bec23628b5
27526         * g10/photoid.c (show_photos): Set namehash.
27527         * g10/misc.c (pct_expando): Add "%U" expando.
27528
27529         common: Add z-base-32 encoder.
27530         + commit b8a91ebf46a927801866e99bb5a66ab00651424e
27531         * common/zb32.c: New.
27532         * common/t-zb32.c: New.
27533         * common/Makefile.am (common_sources): Add zb82.c
27534         (module_tests): Add t-zb32.
27535
27536 2014-04-16  Werner Koch  <wk@gnupg.org>
27537
27538         Two minor code cleanups and one NULL deref on error fix.
27539         + commit a34afa8f2053d75f276d6d28dbf1a43db0fd9768
27540         * common/estream.c (es_freopen): Remove useless check for STREAM.
27541         * kbx/keybox-blob.c (_keybox_create_x509_blob): Remove useless check
27542         for BLOB.
27543         * tools/sockprox.c (run_proxy): Do not fclose(NULL).
27544
27545 2014-04-15  Werner Koch  <wk@gnupg.org>
27546
27547         gpg: Re-enable secret key deletion.
27548         + commit db3b528239c9d56bc71fd2283e07a3f1d91e4fd0
27549         * g10/call-agent.c (agent_delete_key): New.
27550         * g10/keydb.h (FORMAT_KEYDESC_DELKEY): New.
27551         * g10/passphrase.c (gpg_format_keydesc): Support new format.
27552         * g10/delkey.c (do_delete_key): Add secret key deletion.
27553
27554         gpg: Re-indent a file.
27555         + commit d25d00b89efed461d344028d0e2e2be38cc77628
27556         * g10/delkey.c: Re-indent.
27557         (do_delete_key, delete_keys): Change return type top gpg_error_t.
27558
27559         gpg: Fix regression in secret key export.
27560         + commit c4d983239a3f0a18c77f0a5aeba520a81a1b86e8
27561         * agent/cvt-openpgp.c (convert_to_openpgp): Fix use
27562         gcry_sexp_extract_param.
27563         * g10/export.c (do_export_stream): Provide a proper prompt to the
27564         agent.
27565
27566         gpg: Change pinentry prompt to talk about "secret key".
27567         + commit e549799db66be30cdd68a3e6cdca9c6a050466d1
27568         * g10/passphrase.c (gpg_format_keydesc): Add mode 2.  Change strings.
27569         * g10/keydb.h (FORMAT_KEYDESC_NORMAL, FORMAT_KEYDESC_IMPORT)
27570         (FORMAT_KEYDESC_EXPORT): New.  Use them for clarity.
27571
27572         agent: Add command DELETE_KEY.
27573         + commit e3a4ff89a0b106e678bf9d0a4d47917123071140
27574         * agent/command.c (cmd_delete_key): New.
27575         * agent/findkey.c (modify_description): Add '%C' feature.
27576         (remove_key_file): New.
27577         (agent_delete_key): New.
27578         * agent/command-ssh.c (search_control_file): Make arg R_DISABLE
27579         optional.
27580
27581         * configure.ac: Require libgpg-error 1.13.
27582
27583 2014-04-09  NIIBE Yutaka  <gniibe@fsij.org>
27584
27585         scd: EdDSA support.
27586         + commit 3132bd90dc8db9c7fd19ba201918e95891306dc5
27587         * scd/app-openpgp.c (KEY_TYPE_EDDSA, CURVE_ED25519): New.
27588         (struct app_local_s): Add eddsa.
27589         (get_algo_byte, store_fpr): Support KEY_TYPE_EDDSA.
27590         (get_ecc_key_parameters, get_curve_name): Support CURVE_ED25519.
27591         (send_key_attr, get_public_key): Support KEY_TYPE_EDDSA.
27592         (build_ecc_privkey_template): Rename as it supports both of
27593         ECDSA and EdDSA.
27594         (ecc_writekey): Rename.  Support CURVE_ED25519, too.
27595         (do_writekey): Follow the change of ecc_writekey.
27596         (do_auth): Support KEY_TYPE_EDDSA.
27597         (parse_ecc_curve): Support CURVE_ED25519.  Bug fix for other curves.
27598         (parse_algorithm_attribute): Bug fix for ECDH.  Support EdDSA.
27599
27600 2014-04-08  Werner Koch  <wk@gnupg.org>
27601
27602         dirmngr: Fix compiler warning.
27603         + commit db85feceaf43ebd6d44421bb14fcb60495804ae0
27604         * common/mischelp.h (JNLIB_GCC_HAVE_PUSH_PRAGMA): New.
27605         * dirmngr/dirmngr.c (handle_tick): Factor time check out to ...
27606         (time_for_housekeeping_p): new.
27607
27608         gpgconf: Add command --launch.
27609         + commit b4cf4686f7349be9558217f20e51157398cd88a0
27610         * tools/gpgconf.c: Add command --launch.
27611         * tools/gpgconf-comp.c (gc_component_launch): New.
27612
27613         scd: Silent compiler warnings about unused variables.
27614         + commit 36dfc37e438660632d3a2bf5d5526be9005fa8c5
27615         * scd/app-openpgp.c (build_ecdsa_privkey_template): Mark unused arg.
27616         (ecdh_writekey): Mark unused args.
27617
27618 2014-04-08  NIIBE Yutaka  <gniibe@fsij.org>
27619
27620         agent: Support EdDSA.
27621         + commit 5ff6d0c25e6d0f422b17809b954e9e87cb137347
27622         * agent/pksign.c (agent_pksign_do): Handle EdDSA signature.
27623
27624         g10: EdDSA support.
27625         + commit 40c3b0741e593d0658dda0c707c4f32e80648dd1
27626         * g10/keyid.c (keygrip_from_pk): Compute keygrip of EdDSA key.
27627         * g10/keygen.c (generate_subkeypair): Ed25519 is for EdDSA.
27628         * common/openpgp-oid.c (oid_ed25519): Update.
27629
27630 2014-04-04  NIIBE Yutaka  <gniibe@fsij.org>
27631
27632         agent: EdDSA support for SSH.
27633         + commit 513c67b7461a2451247ef2b2fc64e0470a16edf1
27634         * agent/command-ssh.c (ssh_signature_encoder_eddsa): Signature is
27635         two 32-byte opaque data which should not be interpreted as number.
27636
27637 2014-03-27  Werner Koch  <wk@gnupg.org>
27638
27639         gpg: Add commands --quick-sign-key and --quick-lsign-key.
27640         + commit b6786cc3ec0bb582323adf94c2ee624bcfbeb466
27641         * g10/gpg.c (main): Add commands --quick-sign-key and
27642         --quick-lsign-key.
27643         * g10/keyedit.c (sign_uids): Add args FP and QUICK.
27644         (keyedit_quick_sign): New.
27645         (show_key_with_all_names): Add arg NOWARN.
27646
27647         Change some keyedit functions to allow printing to arbitrary streams.
27648         + commit 4f50ec98ddd57253cae66e2321f0cc98ee189a09
27649         * common/ttyio.c (tty_print_string): Add optional arg FP. Change all
27650         callers.
27651         (tty_print_utf8_string2): Ditto.
27652         * g10/keyedit.c (show_prefs):  Ditto.
27653         (show_key_with_all_names_colon): Ditto.
27654         (show_names): Ditto.
27655         * g10/keylist.c (print_revokers): Ditto.
27656         (print_fingerprint): Ditto.
27657
27658 2014-03-23  Werner Koch  <wk@gnupg.org>
27659
27660         agent: Replace es_mopen by es_fopenmem for ssh.
27661         + commit 5c2a50cdc90e85b1fc380851ccfbe9186969b658
27662         * agent/command-ssh.c (ssh_read_key_public_from_blob): Use
27663         es_fopenmem.
27664         (ssh_handler_request_identities): Ditto.
27665         (ssh_request_process): Ditto.
27666
27667 2014-03-22  Werner Koch  <wk@gnupg.org>
27668
27669         agent: Put ssh key type as comment into sshcontrol.
27670         + commit fc3e70c11342267c1062e4244955d19ecd72e0f6
27671         * agent/command-ssh.c (ssh_key_type_spec): Add field name.
27672         (ssh_key_types): Add human readable names.
27673         (add_control_entry): Add arg SPEC and print key type as comment.
27674         (ssh_identity_register): Add arg SPEC.
27675         (ssh_handler_add_identity): Add var SPEC and pass ssh_receive_key.
27676
27677         agent: Support the Ed25519 signature algorithm for ssh.
27678         + commit 072432883ededa15bf35f80102e0572746ba4af1
27679         * agent/command-ssh.c (SPEC_FLAG_IS_EdDSA): New.
27680         (ssh_key_types): Add entry for ssh-ed25519.
27681         (ssh_identifier_from_curve_name): Move to the top.
27682         (stream_read_skip): New.
27683         (stream_read_blob): New.
27684         (ssh_signature_encoder_rsa): Replace MPIS array by an s-exp and move
27685         the s-exp parsing to here.
27686         (ssh_signature_encoder_dsa): Ditto.
27687         (ssh_signature_encoder_ecdsa): Ditto.
27688         (ssh_signature_encoder_eddsa): New.
27689         (sexp_key_construct): Rewrite.
27690         (ssh_key_extract): Rename to ...
27691         (ssh_key_to_blob): .. this and rewrite most of it.
27692         (ssh_receive_key): Add case for EdDSA.
27693         (ssh_convert_key_to_blob, key_secret_to_public): Remove.
27694         (ssh_send_key_public): Rewrite.
27695         (ssh_handler_request_identities): Simplify.
27696         (data_sign): Add rename args.  Add new args HASH and HASHLEN.  Make
27697         use of es_fopenmen and es_fclose_snatch.  Remove parsing into MPIs
27698         which is now doe in the sgnature encoder functions.
27699         (ssh_handler_sign_request): Take care of Ed25519.
27700         (ssh_key_extract_comment): Rewrite using gcry_sexp_nth_string.
27701
27702         agent: Cleanups to prepare implementation of Ed25519.
27703         + commit a77ed0f266d03e234027dda4de5a7f3dd6787b1e
27704         * agent/cvt-openpgp.c: Remove.
27705         (convert_to_openpgp): Use gcry_sexp_extract_param.
27706         * agent/findkey.c (is_eddsa): New.
27707         (agent_is_dsa_key, agent_is_eddsa_key): Check whether ecc means EdDSA.
27708         * agent/pksign.c (agent_pksign_do): Add args OVERRIDEDATA and
27709         OVERRIDEDATALEN.
27710
27711         * common/ssh-utils.c (is_eddsa): New.
27712         (get_fingerprint): Take care or EdDSA.
27713
27714 2014-03-18  Werner Koch  <wk@gnupg.org>
27715
27716         tools: Fix NULL deref in gpg-connect-agent.
27717         + commit 6376227a31b3076321ce16ad626b333057bda53d
27718         * tools/gpg-connect-agent.c (handle_inquire): Do not pass NULL to
27719         strlen.
27720
27721         dirmngr: Resurrect hosts in the HKP hosttable.
27722         + commit 6c058fac65c7e9d1ffb72686f0f02644f172da22
27723         * dirmngr/dirmngr.c (HOUSEKEEPING_INTERVAL): New.
27724         (housekeeping_thread): New.
27725         (handle_tick): Call new function.
27726         * dirmngr/ks-engine-hkp.c (RESURRECT_INTERVAL): New.
27727         (struct hostinfo_s): Add field died_at and set it along with the dead
27728         flag.
27729         (ks_hkp_print_hosttable): Print that info.
27730         (ks_hkp_housekeeping): New.
27731
27732         common: New function elapsed_time_string.
27733         + commit 04e304278c9302831bc81e7fe9049c588ead029a
27734         * common/gettime.c (elapsed_time_string): New.
27735
27736 2014-03-17  Werner Koch  <wk@gnupg.org>
27737
27738         gpg: Reject signatures made with MD5.
27739         + commit f90cfe6b66269de0154d810c5cee1fe9a5af475c
27740         * g10/gpg.c: Add option --allow-weak-digest-algos.
27741         (main): Set option also in PGP2 mode.
27742         * g10/options.h (struct opt): Add flags.allow_weak_digest_algos.
27743         * g10/sig-check.c (do_check): Reject MD5 signatures.
27744         * tests/openpgp/defs.inc: Add allow_weak_digest_algos to gpg.conf.
27745
27746         gpg: Make --auto-key-locate work again with keyservers.
27747         + commit 1e2e39c5758ffaf62f8bb85b4a86dc49c41f3a68
27748         * dirmngr/ks-engine-hkp.c (ks_hkp_get): Allow exact search mode.
27749         * g10/keyserver.c (keyserver_import_name): Implement.
27750         (keyserver_get): Use exact mode for name based import.
27751         (keyserver_get): Add args R_FPR and R_FPRLEN.  Change all callers.
27752
27753         gpg: New mechanism "clear" for --auto-key-locate.
27754         + commit 1d642d3ca890daa65ee5dd949a00747da6b49015
27755         * g10/getkey.c (parse_auto_key_locate): Implement "clear".
27756
27757 2014-03-14  Werner Koch  <wk@gnupg.org>
27758
27759         gpg-connect-agent: Make it easier to connect to the dirmngr.
27760         + commit 2223eaefaf53aa7217ac593b83e4294148a4db5d
27761         * tools/gpg-connect-agent.c: Add options --dirmngr and
27762         --dirmngr-program.
27763
27764         dirmngr: Make use of IPv4 and IPV6 more explicit.
27765         + commit 59b4fb5f4927908af06bb80ecd86adbf6e54ba14
27766         * common/http.c (connect_server): Handle the new flags.
27767         * common/http.h (HTTP_FLAG_IGNORE_IPv4, HTTP_FLAG_IGNORE_IPv4): New.
27768         * dirmngr/ks-engine-hkp.c (map_host): Add arg r_httpflags.
27769         (make_host_part): Ditto.
27770         (send_request): Add arg httpflags.
27771         (ks_hkp_search, ks_hkp_get, ks_hkp_put): Handle httpflags.
27772
27773         dirmngr: Do not use brackets around legacy IP addresses.
27774         + commit d7fbefeb82833db9eea8b15dc7889ecf0b7ffab4
27775         * dirmngr/ks-engine-hkp.c (my_getnameinfo): Change args to take a
27776         complete addrinfo.  Bracket only v6 addresses.  Change caller.
27777
27778         gpg: Print the actual used keyserver address.
27779         + commit a401f768ca8e218eef7a5c87a8f99cb1d6b4aaeb
27780         * dirmngr/ks-engine-hkp.c (ks_hkp_search, ks_hkp_get): Print SOURCE
27781         status lines.
27782         * g10/call-dirmngr.c (ks_status_parm_s): New.
27783         (ks_search_parm_s): Add field stparm.
27784         (ks_status_cb): New.
27785         (ks_search_data_cb): Send source to the data callback.
27786         (gpg_dirmngr_ks_search): Change callback prototope to include the
27787         SPECIAL arg.  Adjust all users.  Use ks_status_cb.
27788         (gpg_dirmngr_ks_get): Add arg r_source and use ks_status_cb.
27789         * g10/keyserver.c (search_line_handler): Adjust callback and print
27790         "data source" disgnostic.
27791         (keyserver_get): Print data source diagnostic.
27792
27793         dirmngr: Default to a user socket name and enable autostart.
27794         + commit 5d321eb00be0774418de1a05678ac0ec44d7193b
27795         * common/homedir.c (dirmngr_socket_name): Rename to
27796         dirmngr_sys_socket_name.
27797         (dirmngr_user_socket_name): New.
27798         * common/asshelp.c (start_new_dirmngr): Handle sys and user dirmngr
27799         socket.
27800         * dirmngr/dirmngr.c (main): Ditto.
27801         * dirmngr/server.c (cmd_getinfo): Ditto.
27802         * sm/server.c (gpgsm_server): Ditto.
27803         * dirmngr/dirmngr-client.c (start_dirmngr): Likewise.
27804         * tools/gpgconf.c (main): Print "dirmngr-sys-socket" with --list-dirs.
27805
27806         * configure.ac (USE_DIRMNGR_AUTO_START): Set by default.
27807
27808 2014-03-12  Werner Koch  <wk@gnupg.org>
27809
27810         gpg: Add option --dirmngr-program.
27811         + commit 6dd5d99a61f24aff862ccba9f7410d7f1af87c05
27812         * g10/gpg.c: Add option --dirmngr-program.
27813         * g10/options.h (struct opt): Add field dirmngr_program.
27814         * g10/call-dirmngr.c (create_context): Use new var.
27815
27816         * dirmngr/dirmngr.c: Include gc-opt-flags.h.
27817         (main): Remove GC_OPT_FLAG_*.
27818         * tools/gpgconf-comp.c (GC_OPT_FLAG_NO_CHANGE): Move macro to ...
27819         * common/gc-opt-flags.h: here.
27820
27821         dirmngr: Detect dead keyservers and try another one.
27822         + commit fb56a273b1f2b3a99dc1d1a0850378ab7625e6b9
27823         * dirmngr/ks-action.c (ks_action_resolve): Rename var for clarity.
27824         (ks_action_search, ks_action_put): Ditto.
27825         (ks_action_get): Consult only the first server which retruned some
27826         data.
27827
27828         * dirmngr/ks-engine-hkp.c (SEND_REQUEST_RETRIES): New.
27829         (map_host): Add arg CTRL and call dirmngr_tick.
27830         (make_host_part): Add arg CTRL.
27831         (mark_host_dead): Allow the use of an URL.
27832         (handle_send_request_error): New.
27833         (ks_hkp_search, ks_hkp_get, ks_hkp_put): Mark host dead and retry on
27834         error.
27835
27836         http: Add a flag to the URL parser indicating a literal v6 address.
27837         + commit 3d9e0eb02ce2b2e153e25deb0fc4b27b45f5026a
27838         * common/http.h (struct parsed_uri_t): Add field v6lit.
27839         * common/http.c (do_parse_uri): Set v6lit.
27840
27841 2014-03-12  NIIBE Yutaka  <gniibe@fsij.org>
27842
27843         scd: writekey support of ECC.
27844         + commit 781b94174310dceffa075719420b74b29fe41764
27845         * scd/app-openpgp.c (CURVE_SEC_P256K1, get_algo_byte): New.
27846         (store_fpr): Support ECC keys with varargs.
27847         (get_ecc_key_parameters, get_curve_name): Support secp256k1.
27848         (parse_ecc_curve): Likewise.
27849         (build_ecdsa_privkey_template, rsa_writekey, ecdsa_writekey): New.
27850         (ecdh_writekey): New.  Not implemented yet.
27851         (do_writekey): Call rsa_writekey, ecdsa_writekey, or ecdh_writekey.
27852         (do_genkey): Follow the change of store_fpr.
27853
27854 2014-03-11  Werner Koch  <wk@gnupg.org>
27855
27856         dirmngr: Put brackets around IP addresses in the hosttable.
27857         + commit 0b2cca807d5a4a3664145032271141da853e7bac
27858         * dirmngr/ks-engine-hkp.c (EAI_OVERFLOW): Provide a substitute.
27859         (my_getnameinfo): New.
27860         (map_host): Use it.
27861
27862         dirmngr: Add command option to mark hosts as dead or alive.
27863         + commit a3dee2889106fcab112c1c96b32e04d8154875e7
27864         * dirmngr/server.c (cmd_killdirmngr): Factor some code out to ...
27865         (check_owner_permission): here.
27866         (cmd_keyserver): Add options --dead and --alive.
27867         * dirmngr/ks-engine-hkp.c (host_in_pool_p): New.
27868         (ks_hkp_mark_host): New.
27869
27870         dirmngr: Make Assuan output of keyblocks easier readable.
27871         + commit 71b55c945542e695161ddbd783f87c5f534012a5
27872         * dirmngr/server.c (data_line_cookie_write): Print shorter data lines
27873         in verbose mode.
27874
27875         dirmngr: Fix HKP host selection code.
27876         + commit 3c35b46a32ac7584f3807b611cde78b199c527d6
27877         * dirmngr/server.c (cmd_keyserver): Add option --resolve and change
27878         --print-hosttable to --hosttable.
27879         * dirmngr/ks-action.c (ks_printf_help): New.
27880         (ks_action_resolve): New.
27881         * dirmngr/ks-engine-hkp.c (select_random_host): Fix selection.
27882         (ks_hkp_print_hosttable): Print to assuan stream.
27883         (map_host): Remove debug code.  Add arg FORCE_SELECT.  Return numeric
27884         IP addr if it can't be resolved.
27885         (make_host_part): Add arg FORCE_SELECT; change callers to pass false.
27886         (ks_hkp_resolve): New.
27887
27888         List readline support in configure summary.
27889         + commit f30d8b018871495327cbf711b73b04278a34f3e1
27890         * m4/readline.m4: Set gnupg_cv_have_readline.
27891         * configure.ac: Add readline support to summary output.
27892
27893 2014-03-11  NIIBE Yutaka  <gniibe@fsij.org>
27894
27895         agent: API change of agent_key_from_file.
27896         + commit ac5a1a3ccb7c3e6393bc83d73b545dec9b70e7d1
27897         * agent/findkey.c (agent_key_from_file): Always return S-expression.
27898         * agent/command.c (cmd_passwd): Distinguish by SHADOW_INFO.
27899         (cmd_export_key): Likewise.  Free SHADOW_INFO.
27900         (cmd_keytocard): Likewise.  Release S_SKEY.
27901         * agent/pkdecrypt.c (agent_pkdecrypt): Likewise.
27902         * agent/pksign.c (agent_pksign_do): Likewise.  Use the S-expression to
27903         know the key type.
27904
27905 2014-03-10  Werner Koch  <wk@gnupg.org>
27906
27907         Backport useful code from fixes for bug 1447.
27908         + commit 57d26f39afb3c75e24a8d240d7af32b9d2b9775a
27909         * configure.ac: Cehck for inet_ntop.
27910         * m4/libcurl.m4: Provide a #define for the version of the curl
27911         library.
27912
27913         scd: acquire lock in new_reader_slot.
27914         + commit 9ab9f414fb919f0bc87c301c3e36180715d0aa4e
27915         * scd/apdu.c (new_reader_slot): Acquire lock.
27916         (open_ct_reader, open_pcsc_reader_direct, open_pcsc_reader_wrapped)
27917         (open_ccid_reader, open_rapdu_reader): Release lock.
27918         (lock_slot, trylock_slot, unlock_slot): Move more to the top.
27919
27920         Do not require libiconv for Android.
27921         + commit b278043a8f38e2706ccf617d2ac5661b33791d6b
27922         * configure.ac (require_iconv): New.  Set to false for android.
27923         (AM_ICONV): Run only if required.
27924
27925 2014-03-07  Werner Koch  <wk@gnupg.org>
27926
27927         dirmmgr: Use a portability wrapper for struct timeval.
27928         + commit feda379595e06583bc5b3610dec74890de29cb8e
27929         * dirmngr/dirmngr_ldap.c [W32]: Include winber.h.
27930         (my_ldap_timeval_t): New.
27931
27932         Silence more warnings about unused vars and args.
27933         + commit 4387ecb11cdb2addf738eb922c1b9f14c6c76efc
27934         * dirmngr/cdblib.c (cdb_init) [W32]: Remove unused var.
27935         * dirmngr/dirmngr-client.c (start_dirmngr): s/int/assuan_fd_t/.
27936         * dirmngr/dirmngr.c (w32_service_control): Mark unused args.
27937         (call_real_main): New.
27938         (main) [W32]: Use new function to match prototype.
27939         (real_main) [W32]: Mark unused vars.
27940         (handle_signal) [W32]: Do not build the function at all.
27941         (handle_connections) [W32]: Do not define signo.
27942         * dirmngr/ldap-wrapper-ce.c (outstream_reader_cb): Remove used vars.
27943         * g10/tdbio.c (ftruncate) [DOSISH]: Define only if not yet defined.
27944
27945         dirmngr: Simplify strtok macro.
27946         + commit 35266076e3452590931e58f188815859dff6de3c
27947         * dirmngr/ldap-url.c (ldap_utf8_strtok): Remove unused r3d arg.
27948         (ldap_str2charray): Remove lasts.
27949
27950         Use attribute __gnu_printf__ also in estream header files.
27951         + commit 72133b54de89e593d8193b106e9369cf90d2e1c0
27952         * common/estream-printf.h: Use attribute gnu_printf.
27953         * common/estream.h: Ditto.
27954
27955         Use attribute __gnu_printf__ with our estream-printf functions.
27956         + commit 36372dcb2f75a659b7ace0e9c46f07bb431d009c
27957         * common/mischelp.h (JNLIB_GCC_A_PRINTF): Use __gnu_printf__
27958         (JNLIB_GCC_A_NR_PRINTF): Ditto.
27959
27960         w32: Silence warnings about unused vars.
27961         + commit 094aa2589e3920d400be93ae2823a6c4b23db623
27962         * agent/gpg-agent.c (main) [W32]: Mark unused vars.
27963         * sm/gpgsm.c (run_protect_tool) [W32]: Ditto.
27964         * g10/trustdb.c (check_regexp) [DISABLE_REGEX]: Ditto.
27965         * scd/scdaemon.c (main) [W32]: Ditto.
27966         (handle_connections) [W32]: Ditto.
27967         (handle_signal) [W32]: Do not build the function at all.
27968         * scd/apdu.c (pcsc_send_apdu_direct): Ditto.
27969         (connect_pcsc_card): s/long/pcsc_dword_t/.
27970         (open_pcsc_reader_direct): Remove var listlen.
27971
27972         w32: Fix a potential problem in gpgconf's gettext.
27973         + commit a0fc42598f51ef4a958fc3c2fed7f4b8df2da3fd
27974         * tools/gpgconf-comp.c (my_dgettext) [USE_SIMPLE_GETTEXT]: Make sure
27975         to return something even DOMAIN is not given.
27976
27977         Silence several warnings when building under Windows.
27978         + commit 3032fc3ad78ac9ed857570844547afed520d635a
27979         * agent/call-scd.c (start_scd): Replace int by assuan_fd_t.
27980         (start_pinentry): Ditto.
27981         * common/asshelp.c (start_new_gpg_agent): Replace int by assuan_fd_t.
27982         * common/dotlock.c (GNUPG_MAJOR_VERSION): Include stringhelp.h for
27983         prototypes on Windows and some other platforms.
27984         * common/logging.c (fun_writer): Declare addrbuf only if needed.
27985         * g10/decrypt.c (decrypt_message_fd) [W32]: Return not_implemented.
27986         * g10/encrypt.c (encrypt_crypt) [W32]: Return error if used in server
27987         mode.
27988         * g10/dearmor.c (dearmor_file, enarmor_file): Replace GNUPG_INVALID_FD
27989         by -1 as temporary hack for Windows.
27990         * g10/export.c (do_export): Ditto.
27991         * g10/revoke.c (gen_desig_revoke, gen_revoke): Ditto.
27992         * g10/sign.c (sign_file, clearsign_file, sign_symencrypt_file): Ditto.
27993         * g10/server.c (cmd_verify, gpg_server) [W32]: Return an error.
27994
27995         w32: Include winsock2.h to silence warnings.
27996         + commit cb0dcc340836a64e2d33b27f1be7bc888c084f12
27997
27998
27999         gl: Avoid warning about shadowing an arg.
28000         + commit 84fd36f8baa2b800ea47ff74935f5aaf0e55c299
28001         * gl/setenv.c (KNOWN_VALUE): s/value/_v/.
28002
28003         common: Fix build problem with Sun Studio compiler.
28004         + commit 0fc71f7277c6f833f838bbd384f1a22d0c333e8e
28005         * common/estream.c (ESTREAM_MUTEX_UNLOCK): Use int dummy dummy
28006         functions.
28007         (ESTREAM_MUTEX_INITIALIZE): Ditto.
28008
28009         gpg: Do not require a trustdb with --always-trust.
28010         + commit d8f0b83e4f04641e5e9adbdd8abada15380f981c
28011         * g10/tdbio.c (tdbio_set_dbname): Add arg R_NOFILE.
28012         * g10/trustdb.c (trustdb_args): Add field no_trustdb.
28013         (init_trustdb): Set that field.
28014         (revalidation_mark):  Take care of a nonexistent trustdb file.
28015         (read_trust_options): Ditto.
28016         (tdb_get_ownertrust): Ditto.
28017         (tdb_get_min_ownertrust): Ditto.
28018         (tdb_update_ownertrust): Ditto.
28019         (update_min_ownertrust): Ditto.
28020         (tdb_clear_ownertrusts): Ditto.
28021         (tdb_cache_disabled_value): Ditto.
28022         (tdb_check_trustdb_stale): Ditto.
28023         (tdb_get_validity_core): Ditto.
28024         * g10/gpg.c (main): Do not create a trustdb with most commands for
28025         trust-model always.
28026
28027         gpg: Print a "not found" message for an unknown key in --key-edit.
28028         + commit dfb25d47a9fcfd7c7c084ea58744724cd5315086
28029         * g10/keyedit.c (keyedit_menu): Print message.
28030
28031         gpg: Protect against rogue keyservers sending secret keys.
28032         + commit db1f74ba5338f624f146a3cb41a346e46b15c8f9
28033         * g10/options.h (IMPORT_NO_SECKEY): New.
28034         * g10/keyserver.c (keyserver_spawn, keyserver_import_cert): Set new
28035         flag.
28036         * g10/import.c (import_secret_one): Deny import if flag is set.
28037
28038         agent: Fix UPDATESTARTUPTTY for ssh.
28039         + commit 90688b29f3701f4d3e2a5a49c5544fe8d2a84b2d
28040         * agent/command-ssh.c (setup_ssh_env): Fix env setting.
28041
28042         gpgv: Init Libgcrypt to avoid syslog warning.
28043         + commit 7c4bfa599fa69c3a942c8deea83737a4c5a0806e
28044         * g10/gpgv.c (main): Check libgcrypt version and disable secure
28045         memory.
28046
28047         Improve libcurl detection.
28048         + commit 5ca482d5f949444ffd453de158ee186ab07fc9b6
28049         * m4/libcurl.m4: Do not use AC_PATH_PROG if --with-libcurl as been
28050         given.  Suggested by John Marshall.
28051
28052         gpg: Remove legacy keyserver examples from the template conf file.
28053         + commit 0ab752cc2d46bbd0077bed889676169b7aeb1eb6
28054         * g10/options.skel: Update.
28055
28056         (cherry picked from commit f3c5cc8bcd37e38b5d65db6a50466e22d03d1f0c)
28057
28058         w32: Define WINVER only if needed.
28059         + commit 76b1940ad6f5f058c4a6bec35902da9f6d4e27b0
28060         * common/sysutils.c (WINVER): Define only if less that 5.0.
28061
28062         w32: Remove unused code.
28063         + commit 63b7658a29809249d7aeb0423bf8c5a693eee0c7
28064         * jnlib/w32-reg.c (write_w32_registry_string): Remove.
28065
28066         agent: Make --allow-mark-trusted the default.
28067         + commit 9942a149ff2ab919c1b2916c7bc347e578a56b14
28068         * agent/gpg-agent.c (opts, main): Add option --no-allow-mark-trusted.
28069         Put this option into the gpgconf-list.
28070         (main): Enable opt.allow_mark_trusted by default.
28071         * tools/gpgconf-comp.c (gc_options_gpg_agent): Replace
28072         allow-mark-trusted by no-allow-mark-trusted.
28073
28074         * agent/trustlist.c (agent_marktrusted): Always set the "relax" flag.
28075
28076         ssh: Add support for Putty.
28077         + commit 5105c8d2d344fd7301d456d8c13c7e90a54f7e98
28078         * agent/gpg-agent.c [W32]: Include Several Windows header.
28079         (opts): Change help text for enable-ssh-support.
28080         (opts, main): Add option --enable-putty-support
28081         (putty_support, PUTTY_IPC_MAGIC, PUTTY_IPC_MAXLEN): New for W32.
28082         (agent_init_default_ctrl): Add and asssert call.
28083         (putty_message_proc, putty_message_thread): New.
28084         (handle_connections) [W32]: Start putty message thread.
28085         * common/sysutils.c (w32_get_user_sid): New for W32 only
28086         * tools/gpgconf-comp.c (gc_options_gpg_agent): Add
28087         --enable-ssh-support and --enable-putty-support.  Make the
28088         configuration group visible at basic level.
28089         * agent/command-ssh.c (serve_mmapped_ssh_request): New for W32 only.
28090
28091         agent: Fix binary vs. text mode problem in ssh.
28092         + commit 179012ddd48e63ca83e8f5c24537a2db45c3e122
28093         * agent/command-ssh.c (file_to_buffer)
28094         (ssh_handler_request_identities): Open streams in binary mode.
28095         (start_command_handler_ssh): Factor some code out to ..
28096         (setup_ssh_env): new function.
28097
28098         Fix syntax error for building on APPLE.
28099         + commit 4ad123d6fe341da7768e43360375e17fa89e8e0d
28100         * scd/pcsc-wrapper.c [__APPLE__]: Fix syntax error.
28101
28102         Ignore obsolete option --disable-keypad.
28103         + commit d2a6be24af0bf220bb448fdd50c0196faddee0f4
28104         * scd/scdaemon.c (opts): Ignore --disable-keypad.
28105
28106         Allow marking options as ignored.
28107         + commit 8fc9de8d6bf663f7c8419b42dab01f590a694d59
28108         * jnlib/argparse.h (ARGPARSE_OPT_IGNORE): New.
28109         (ARGPARSE_TYPE_MASK): New, for internal use.
28110         (ARGPARSE_ignore): New.
28111         * jnlib/argparse.c (optfile_parse, arg_parse): Replace remaining
28112         constants by macros.
28113         (optfile_parse): Implement ARGPARSE_OPT_IGNORE.
28114         (arg_parse): Exclide ignore options from --dump-options.
28115
28116 2014-03-06  Werner Koch  <wk@gnupg.org>
28117
28118         common: Fix recent commit 55656208.
28119         + commit 191e32026f02054b1edb4f02536875462fd0b6b3
28120         * common/membuf.c (get_membuf_shrink): Fix use of LEN.
28121
28122 2014-03-06  NIIBE Yutaka  <gniibe@fsij.org>
28123
28124         Fix g10/trust.c.
28125         + commit 5ed8e9335fb886d7ddc86728d8481e5e47485531
28126         * g10/trust.c (register_trusted_keyid, register_trusted_key)
28127         (update_ownertrust): Call functions with tdb_.
28128
28129 2014-02-26  Werner Koch  <wk@gnupg.org>
28130
28131         common: Replace all macros in strusage() returned strings.
28132         + commit 0f38c87f427a155ab5684e18e3b73956f81edfab
28133         * common/argparse.c (writechar): Remove.
28134         (writestrings): Simplify.
28135         (strusage): Use map_static_macro_string.
28136
28137         common: New function map_static_macro_string.
28138         + commit c72762f9acf3eef5c466ba76e895d7654df12ff7
28139         * common/mapstrings.c: New.
28140         * common/t-mapstrings.c: New.
28141         * common/t-support.h (DIM, DIMof): Define if not defined.
28142         * common/Makefile.am: Add new files.
28143
28144         common: New function get_membuf_shrink.
28145         + commit 556562086acd2bc2f8e3aa3126ebf155715e042b
28146         * common/membuf.c (get_membuf_shrink): New.
28147
28148         agent: Fixed unresolved symbol under Windows.
28149         + commit 55c3e5f448c26360eda31e05b1f62249119f73d9
28150         * agent/gpg-agent.c (main): s/ttyname/gnupg_ttyname/.
28151
28152         common: Require an installed libiconv.
28153         + commit 380a2aa18e0c048cfefa1cb4102dfbf902a1962b
28154         * common/utf8conv.c: Remove dynload.h.
28155         (load_libiconv): Remove.  Remove all calls to it.
28156
28157 2014-02-10  Werner Koch  <wk@gnupg.org>
28158
28159         gpg: Silent more compiler warnings due to some configure options.
28160         + commit 47e6b6bad1dff493f4102a5549a7bb54466684c2
28161         * g10/keygen.c (generate_keypair, gen_card_key)
28162         (gen_card_key_with_backup) [!ENABLE_CARD_SUPPORT]: Mark unused args.
28163
28164         tests: Avoid segv if dns cert lookup is not configured.
28165         + commit 672f4aeba8bf55839911e1fe805af6b2873853f7
28166         * common/dns-cert.c (get_dns_cert) [!USE_DNS_CERT]: Reset return args.
28167
28168         gpg: Cleanup compiler warnings due to some configure options.
28169         + commit 7901c5c2a3b7b24e9a4eaab590b0a54e9695c3e4
28170         * g10/photoid.c (show_photos) [DISABLE_PHOTO_VIEWER]: Mark args as
28171         unused.
28172         * tools/gpgconf-comp.c (my_dgettext): Mark DOMAIN as unused if NLS is
28173         not configured.
28174
28175         gpg: Allow building without any trust model support.
28176         + commit 62fb86c6589f7f74dad4741db31b3aefa0848420
28177         * configure.ac: Add option --disable-trust-models
28178         (NO_TRUST_MODELS): New ac_define and am_conditional.
28179         * g10/Makefile.am (trust_source): New.
28180         (gpg2_SOURCES): Factor some files out to above.  Add trust.c.
28181         * g10/gpg.c [NO_TRUST_MODELS]: Disable options --export-ownertrust,
28182         --import-ownertrust, --update-trustdb, --check-trustdb, --fix-trustdb,
28183         --list-trustdb, --trustdb-name, --auto-check-trustdb,
28184         --no-auto-check-trustdb, and --force-ownertrust.
28185         (parse_trust_model) [NO_TRUST_MODELS]: Do not build.
28186         (main) [NO_TRUST_MODELS]: Set trust_model to always and exclude all
28187         trustdb related option code.
28188         * g10/keyedit.c (cmds) [NO_TRUST_MODELS]: Remove menu items "trust",
28189         "enable", and "disable".
28190         * g10/keylist.c (public_key_list) [NO_TRUST_MODELS]: Do not print
28191         "tru" record.
28192
28193         * g10/trust.c: New.
28194         * g10/trustdb.c (struct key_item): Move to trustdb.h.
28195         (register_trusted_keyid): Rename to tdb_register_trusted_keyid.
28196         (register_trusted_key): Rename to tdb_register_trusted_key.
28197         (trust_letter, uid_trust_string_fixed, trust_value_to_string)
28198         (string_to_trust_value, get_ownertrust_with_min, get_ownertrust_info)
28199         (get_ownertrust_string, get_validity_info, get_validity_string)
28200         (clean_sigs_from_uid, clean_uid_from_key, clean_key): Move to trust.c.
28201         (mark_usable_uid_certs): Move to trust.c and make global.
28202         (is_in_klist): Move as inline to trustdb.h.
28203         (trustdb_check_or_update): Rename to tdb_check_or_update
28204         (revalidation_mark): Rename to tdb_revalidation_mark.
28205         (get_ownertrust): Rename to tdb_get_ownertrust.
28206         (get_min_ownertrust): Rename to tdb_get_min_ownertrust.
28207         (update_ownertrust): Rename to tdb_update_ownertrust.
28208         (clear_ownertrusts): Rename to tdb_clear_ownertrusts.
28209         (cache_disabled_value): Rename to tdb_cache_disabled_value.
28210         (check_trustdb_stale): Rename to tdb_check_trustdb_stale.
28211         (get_validity): Rename to tdb_get_validity_core, add arg MAIN_PK and
28212         factor some code out to ...
28213         * trust.c (get_validity): ...new.
28214         (check_or_update_trustdb): New wrapper.
28215         (revalidation_mark): New wrapper.
28216         (get_ownertrust): New wrapper.
28217         (get_ownertrust_with_min): New wrapper.
28218         (update_ownertrust): New wrapper.
28219         (clear_ownertrusts): New wrapper.
28220         (cache_disabled_value): New wrapper.
28221         (check_trustdb_stale): New wrapper.
28222
28223         * tests/openpgp/defs.inc (opt_always): New.  Use in all tests instead
28224         of --always-trust.
28225
28226         tests: Handle disabled algorithms.
28227         + commit ea7f895319e89150e5613b6d20f21410f99d6f22
28228         * tests/openpgp/mds.test: Skip disabled algorithms.
28229         * tests/openpgp/signencrypt-dsa.test: Ditto.
28230         * tests/openpgp/sigs-dsa.test: Ditto.
28231
28232 2014-02-07  Werner Koch  <wk@gnupg.org>
28233
28234         Silence annoying ABI change warning.
28235         + commit 111f082487dc7a2a50375e24203de31b000e0dea
28236         * configure.ac [GCC]: Pass -Wno-psabi for gcc >= 4.6.  Avoid some gcc
28237         option tests for gcc >= 4.6
28238
28239         Allow disabling of card support.
28240         + commit 8e0ba4ecd3897c748ac2f06028406604ae7baced
28241         * configure.ac: Add option --disable-card-support.  Also add
28242         am_conditional and do not build scd if card support is enabled.
28243
28244         gpg: List only available algos in --gen-key.
28245         + commit 357b142e7225e5c7f1e0f9768f48e833d5804b6a
28246         * g10/keygen.c (ask_algo, ask_curve): Take care of GPG_USE_<algo>.
28247
28248         gpg: Change --print-mds to output enabled OpenPGP algos.
28249         + commit 54a11729fb71ba06e318fe229d0a230686ed4dc8
28250         * g10/gpg.c (print_mds): Use opengpg_md_test_algo.  Test also for MD5
28251         availibility.
28252
28253         gpg: Avoid compiler warnings for disabled algos.
28254         + commit aa76a1660613ece3fc0d774856abcbe0bb158300
28255         * g10/misc.c (map_cipher_openpgp_to_gcry): Add case for disabled algo.
28256         (openpgp_pk_test_algo2): Ditto.
28257         (map_md_openpgp_to_gcry): Ditto.
28258
28259 2014-02-05  Werner Koch  <wk@gnupg.org>
28260
28261         gpg: Change format for the key size in --list-key and --edit-key.
28262         + commit 2c814806d759e5cf611200e8210137cf8502a672
28263         * g10/gpg.c (oLegacyListMode, opts, main): Add --legacy-list-mode.
28264         * g10/options.h (struct opt): Add field legacy_list_mode.
28265         * g10/keydb.h (PUBKEY_STRING_SIZE): New.
28266         * g10/keyid.c (pubkey_string): New.
28267         * g10/import.c (import_one, import_secret_one): Use pubkey_string.
28268         * g10/keylist.c (print_seckey_info): Ditto.
28269         (print_pubkey_info, print_card_key_info): Ditto.
28270         (list_keyblock_print): Ditto.
28271         * g10/mainproc.c (list_node): Ditto.
28272         * g10/pkclist.c (do_edit_ownertrust, build_pk_list): Ditto.
28273         * g10/keyedit.c (show_key_with_all_names): Ditto.  Also change the
28274         format.
28275         (show_basic_key_info): Ditto.
28276         * common/openpgp-oid.c (openpgp_curve_to_oid): Also allow "ed25519".
28277         (openpgp_oid_to_curve): Downcase "ed25519"
28278
28279 2014-01-31  Werner Koch  <wk@gnupg.org>
28280
28281         gpg: Add configure options to disable algorithms.
28282         + commit 2ba818de1aa311ba8eb27012d69e93dd16e7d4ed
28283         * acinclude.m4 (GNUPG_GPG_DISABLE_ALGO): New.
28284         * configure.ac: Add --enable-gpg-* options to disable non MUS
28285         algorithms.
28286         * g10/misc.c (map_cipher_openpgp_to_gcry): Implement these options.
28287         (openpgp_pk_test_algo2): Ditto.
28288         (map_md_openpgp_to_gcry): Ditto.
28289         (openpgp_cipher_test_algo, openpgp_md_test_algo): Simplify.
28290
28291         gpg: Improve --version algo info output.
28292         + commit 71540d40414dc8b304b45dc476e5e5650a2db20a
28293         * g10/misc.c (openpgp_pk_algo_name): Return a different string for
28294         each ECC algorithm.
28295         * g10/gpg.c (build_list_pk_test_algo): New wrapper to cope with the
28296         different algo type enums.
28297         (build_list_pk_algo_name): Ditto.
28298         (build_list_cipher_test_algo): Ditto.
28299         (build_list_cipher_algo_name): Ditto.
28300         (build_list_md_test_algo): Ditto.
28301         (build_list_md_algo_name): Ditto.
28302         (my_strusage): Use them.
28303         (list_config): Ditto. Add "pubkeyname".
28304         (build_list): Add letter==1 hack.
28305
28306         gpg: Start using OpenPGP digest algo ids.
28307         + commit bf50604a0d50b974c1d4b8ccf5d774489f996cae
28308         * g10/misc.c (print_pubkey_algo_note): Use enum typedef for the arg.
28309         (print_cipher_algo_note): Ditto.
28310         (print_digest_algo_note): Ditto.
28311         (map_md_openpgp_to_gcry): New.
28312         (openpgp_md_test_algo): Rewrite.
28313         (openpgp_md_algo_name): Rewrite to do without Libgcrypt.
28314         * g10/cpr.c (write_status_begin_signing): Remove hardwired list of
28315         algo ranges.
28316
28317         gpg: Use only OpenPGP cipher algo ids.
28318         + commit 16a6311adefff0139056714521214f845315b7f8
28319         * g10/misc.c (map_cipher_openpgp_to_gcry): Use explicit mapping and
28320         use enums for the arg and return value.
28321         (map_cipher_gcry_to_openpgp): Ditto.
28322         (openpgp_cipher_blocklen): Use constant macros.
28323         (openpgp_cipher_test_algo): Use mapping function and prepare to
28324         disable algorithms.
28325         (openpgp_cipher_algo_name): Do not use Libgcrypt.
28326
28327         * g10/ecdh.c (pk_ecdh_encrypt_with_shared_point): Replace
28328         CGRY_CIPHER_* by CIPHER_ALGO_*.
28329
28330         * common/openpgpdefs.h (cipher_algo_t): Remove unused
28331         CIPHER_ALGO_DUMMY.
28332
28333 2014-01-30  Werner Koch  <wk@gnupg.org>
28334
28335         gpg: Use only OpenPGP public key algo ids and add the EdDSA algo id.
28336         + commit b7f8dec6325f1c80640f878ed3080bbc194fbc78
28337         * common/sexputil.c (get_pk_algo_from_canon_sexp): Change to return a
28338         string.
28339         * g10/keygen.c (check_keygrip): Adjust for change.
28340         * sm/certreqgen-ui.c (check_keygrip): Likewise.
28341
28342         * agent/pksign.c (do_encode_dsa): Remove bogus map_pk_openpgp_to_gcry.
28343
28344         * g10/misc.c (map_pk_openpgp_to_gcry): Remove.
28345         (openpgp_pk_test_algo): Change to a wrapper for openpgp_pk_test_algo2.
28346         (openpgp_pk_test_algo2): Rewrite.
28347         (openpgp_pk_algo_usage, pubkey_nbits): Add support for EdDSA.
28348         (openpgp_pk_algo_name): Rewrite to remove need for gcry calls.
28349         (pubkey_get_npkey, pubkey_get_nskey): Ditto.
28350         (pubkey_get_nsig, pubkey_get_nenc): Ditto.
28351         * g10/keygen.c(do_create_from_keygrip):  Support EdDSA.
28352         (common_gen, gen_ecc, ask_keysize, generate_keypair): Ditto.
28353         * g10/build-packet.c (do_key): Ditto.
28354         * g10/export.c (transfer_format_to_openpgp): Ditto.
28355         * g10/getkey.c (cache_public_key): Ditto.
28356         * g10/import.c (transfer_secret_keys): Ditto.
28357         * g10/keylist.c (list_keyblock_print, list_keyblock_colon): Ditto.
28358         * g10/mainproc.c (proc_pubkey_enc): Ditto.
28359         * g10/parse-packet.c (parse_key): Ditto,
28360         * g10/sign.c (hash_for, sign_file, make_keysig_packet): Ditto.
28361         * g10/keyserver.c (print_keyrec): Use openpgp_pk_algo_name.
28362         * g10/pkglue.c (pk_verify, pk_encrypt, pk_check_secret_key): Use only
28363         OpenPGP algo ids and support EdDSA.
28364         * g10/pubkey-enc.c (get_it): Use only OpenPGP algo ids.
28365         * g10/seskey.c (encode_md_value): Ditto.
28366
28367 2014-01-29  Werner Koch  <wk@gnupg.org>
28368
28369         gpg: Remove cipher.h and put algo ids into a common file.
28370         + commit ea8a1685f75d27f5277d42ea7390ad5aeaf51b1f
28371         * common/openpgpdefs.h (cipher_algo_t, pubkey_algo_t, digest_algo_t)
28372         (compress_algo_t): New.
28373         * agent/gpg-agent.c: Remove ../g10/cipher.h. Add openpgpdefs.h.
28374         * g10/cipher.h (DEK): Move to ...
28375         * g10/dek.h: new file.
28376         * g10/cipher.h (is_RSA, is_ELGAMAL, is_DSA)
28377         (PUBKEY_MAX_NPKEY, PUBKEY_MAX_NSKEY, PUBKEY_MAX_NSIG, PUBKEY_MAX_NENC)
28378         (PUBKEY_USAGE_SIG, PUBKEY_USAGE_ENC, PUBKEY_USAGE_CERT)
28379         (PUBKEY_USAGE_AUTH, PUBKEY_USAGE_NONE): Move to
28380         * g10/packet.h: here.
28381         * g10/cipher.h: Remove.  Remove from all files.
28382         * g10/filter.h, g10/packet.h:  Include dek.h.
28383         * g10/Makefile.am (common_source): Remove cipher.h.  Add dek.h.
28384
28385         include: Remove this directory.
28386         + commit 25b4c2acbd01f9b4c2c364f44c53b73498ed8469
28387         * include/cipher.h: Move to ...
28388         * g10/cipher.h: here.
28389         * agent/gpg-agent.c: Adjust header file name.
28390
28391         * include/host2net.h: Move to ...
28392         * common/host2net.h: here.  Change license to LGPLv3/GPLv2.  Adjust
28393         notices to reflect that only me worked on that file.
28394
28395         * include/types.h: Remove.
28396         * common/types.h: Include inttypes.h.  Add byte typedef and comments
28397         for __riscos__.
28398         * common/iobuf.h: Adjust header file name.
28399
28400         * include/_regex.h: Remove this unused file.
28401
28402         * include/Makefile.am: Remove.
28403         * Makefile.am (SUBDIRS): Remove "include".
28404         * configure.ac (AC_CONFIG_FILES): Remove include/Makefile.
28405         * include/ChangeLog-2011: Move to ...
28406         * common/ChangeLog-2011.include: here.
28407         * common/Makefile.am (EXTRA_DIST): Add file.
28408
28409         * include/zlib-riscos.h: Move this repo only file to ...
28410         * g10/zlib-riscos.h: here.
28411
28412         * include/: Remove.
28413
28414 2014-01-17  Werner Koch  <wk@gnupg.org>
28415
28416         Remove unused u64 type definitions.
28417         + commit 362a30d8c2f529cd44687066f9c33cab7b43bedc
28418         * configure.ac: Remove check for uint64 and UINT64_C.
28419         * include/types.h: Remove u64 stuff.
28420         * common/types.h: Ditto.
28421
28422 2014-01-16  NIIBE Yutaka  <gniibe@fsij.org>
28423
28424         agent: Not remove SSH socket when already running.
28425         + commit 0ee66a6f66d7389e381fffa5f9eedbc8de9add10
28426         * agent/gpg-agent.c (main): Defer setting of socket_name_ssh to avoid
28427         removal of the socket when it will die in create_server_socket for
28428         socket_name.
28429
28430         agent: Fix agent_is_eddsa_key.
28431         + commit 9c731bbedfd8bded5efd886304c5ca6655768c45
28432         * agent/findkey.c (agent_is_eddsa_key): Implemented.
28433
28434 2014-01-15  NIIBE Yutaka  <gniibe@fsij.org>
28435
28436         Add secp256k1.
28437         + commit c5e41f539b9a21cbad10c7dae95572a4445d31c3
28438         * common/openpgp-oid.c (openpgp_curve_to_oid): Add secp256k1.
28439         (openpgp_oid_to_curve): Likewise.
28440
28441         * g10/keygen.c (ask_curve): Add secp256k1.
28442
28443 2014-01-10  Werner Koch  <wk@gnupg.org>
28444
28445         autogen.sh: Add rule for 64 bit windows.
28446         + commit aedfa95bcc49156f2bc6ae5d0f385705d4fbdd32
28447
28448
28449         Turn autogen.sh into a generic script.
28450         + commit e7973d36d88178b4b0a977e3fcc0d62600777618
28451         * autogen.sh: Revamp.
28452         * autogen.rc: New.
28453         * Makefile.am (EXTRA_DIST): Add autogen.rc.
28454
28455         Rename scripts/ to build-aux/
28456         + commit 99a48b2fcdf7c33fe553511c12f2ebb8eea5c634
28457         * scripts/: Rename to build-aux/
28458         * Makefile.am: Adjust accordingly.
28459         * configure.ac (AC_CONFIG_AUX_DIR): Change to build-aux.
28460
28461 2014-01-09  Werner Koch  <wk@gnupg.org>
28462
28463         Improve the speedo make script.
28464         + commit a55ffb9da9a844bd2bd73a4a2ea65bf18b21c57f
28465         * scripts/gpg-w32-dev/README: Remove
28466         * scripts/gpg-w32-dev/GNUmakefile, scripts/gpg-w32-dev/speedo.mk:
28467         Merge into ..
28468         * scripts/speedo.mk: this.
28469
28470         gpgsplit: Allow building without zlib support.
28471         + commit 00d5d2204cefb0f4b953e0c00448f16aab2d39c7
28472         * tools/gpgsplit.c [!HAVE_ZLIB]: Do not include zlib.h.
28473         (handle_zlib): Build only if HAVE_ZLIB is defined.
28474         (write_part): Support zlib and zip only if HAVE_ZLIB is defined.
28475
28476         w32: Fix backslash quoting in registry name.
28477         + commit fa318406c9bdb60aee1e1b410e4c9e0b3eb1392e
28478         * configure.ac (GNUPG_REGISTRY_DIR): Double backslashes.
28479
28480         Fix test for zlib.
28481         + commit 477aabaf753f987987f7a2e1f999a499ea3bd103
28482         * configure.ac (HAVE_ZLIB): Define only if found.
28483
28484         Add --enable-silent-rules stuff.
28485         + commit aba53e9f96d0c9b270edef0806976a56326249c4
28486         * configure.ac: Add AM_SILENT_RULES.
28487
28488 2014-01-08  Werner Koch  <wk@gnupg.org>
28489
28490         w32: Add macro for the registry key.
28491         + commit 75ba215ebd8be7e14b26bb53ef3c7d41e4ce1e02
28492         * configure.ac (GNUPG_REGISTRY_DIR) [W32]: New ac-define.
28493         * common/homedir.c (default_homedir): Use it.
28494         * common/logging.c (do_logv): Use it.
28495
28496 2013-12-11  Werner Koch  <wk@gnupg.org>
28497
28498         gpg: Change --show-session-key to print the session key earlier.
28499         + commit 101a54add351ff62793cbfbf3877787c4791f833
28500         * g10/cpr.c (write_status_strings): New.
28501         (write_status_text): Replace code by a call to write_status_strings.
28502         * g10/mainproc.c (proc_encrypted): Remove show_session_key code.
28503         * g10/decrypt-data.c (decrypt_data): Add new show_session_key code.
28504
28505 2013-12-05  Werner Koch  <wk@gnupg.org>
28506
28507         gpg: Change OID of Ed25519 and add Brainpool oids.
28508         + commit 59207a86e5f40c77fed296b642bf76692e8eef65
28509         * common/openpgp-oid.c (openpgp_curve_to_oid): Change OID for
28510         Ed25519.  Add brainpool OIDs.
28511         (openpgp_oid_to_curve): Ditto.
28512
28513 2013-11-29  Werner Koch  <wk@gnupg.org>
28514
28515         common: Add put_membuf_printf.
28516         + commit 159d42ee6ab21d97f40ee129445f37209b875739
28517         * common/membuf.c (put_membuf_printf): New.
28518
28519 2013-11-27  Werner Koch  <wk@gnupg.org>
28520
28521         gpg: Change armor Version header to emit only the major version.
28522         + commit e951782e937ce290be0d89d83e84b3daea997587
28523         * g10/options.h (opt): Rename field no_version to emit_version.
28524         * g10/gpg.c (main): Init opt.emit_vesion to 1.  Change --emit-version
28525         to bump up opt.emit_version.
28526         * g10/armor.c (armor_filter): Implement different --emit-version
28527         values.
28528
28529 2013-11-18  Werner Koch  <wk@gnupg.org>
28530
28531         Make use of the *_NAME etc macros.
28532         + commit cc9a0b69b698ba436eaf777e5020532845b56236
28533         Replace hardwired strings at many places with new macros from config.h
28534         and use the new strusage macro replacement feature.
28535
28536         * common/asshelp.c (lock_spawning) [W32]: Change the names of the spawn
28537         sentinels.
28538         * agent/command.c (cmd_import_key): Use asprintf to create the prompt.
28539
28540         Add strusage macro replacement feature.
28541         + commit 798daaa1ddf73f64cf840fbdc1f4c5b9c4b4ec13
28542         * common/argparse.c (writechar): New.
28543         (writestrings): Add macro replacement feature.
28544         (show_help): Remove specialized @EMAIL@ replacement.
28545         * configure.ac (GNUPG_NAME, GPG_NAME, GPGSM_NAME): Define.
28546         (GPG_AGENT_NAME, DIRMNGR_NAME, G13_NAME, GPGCONF_NAME): Define.
28547         (GPGTAR_NAME, GPG_AGENT_INFO_NAME, GPG_AGENT_SOCK_NAME): Define.
28548         (GPG_AGENT_SSH_SOCK_NAME, DIRMNGR_INFO_NAME): Define.
28549         (DIRMNGR_SOCK_NAME): Define.
28550
28551 2013-11-15  Werner Koch  <wk@gnupg.org>
28552
28553         kbx: Implement update operation for OpenPGP keyblocks.
28554         + commit 5499942571a88a1223a7318992605c6d29858866
28555         * kbx/keybox-update.c (keybox_update_keyblock): Implement.
28556         * kbx/keybox-search.c (get_blob_flags): Move to ...
28557         * kbx/keybox-defs.h (blob_get_type): here.
28558         * kbx/keybox-file.c (_keybox_read_blob2): Fix calling without R_BLOB.
28559         * g10/keydb.c (build_keyblock_image): Allow calling without
28560         R_SIGSTATUS.
28561         (keydb_update_keyblock): Implement for keybox.
28562
28563         * kbx/keybox-dump.c (_keybox_dump_blob): Fix printing of the unhashed
28564         size.  Print "does not expire" also on 64 bit platforms.
28565
28566         gpg: Rework ECC support and add experimental support for Ed25519.
28567         + commit 402aa0f94854bb00475c934be5ca6043a4632126
28568         * agent/findkey.c (key_parms_from_sexp): Add algo name "ecc".
28569         (agent_is_dsa_key): Ditto.
28570         (agent_is_eddsa_key): New.  Not finished, though.
28571         * agent/pksign.c (do_encode_eddsa): New.
28572         (agent_pksign_do): Use gcry_log_debug functions.
28573         * agent/protect.c (agent_protect): Parse a flags parameter.
28574         * g10/keygen.c (gpg_curve_to_oid): Move to ...
28575         * common/openpgp-oid.c (openpgp_curve_to_oid): here and rename.
28576         (oid_ed25519): New.
28577         (openpgp_oid_is_ed25519): New.
28578         (openpgp_oid_to_curve): New.
28579         * common/t-openpgp-oid.c (test_openpgp_oid_is_ed25519): New.
28580         * g10/build-packet.c (gpg_mpi_write): Write the length header also for
28581         opaque MPIs.
28582         (gpg_mpi_write_nohdr): New.
28583         (do_key): Use gpg_mpi_write_nohdr depending on algorithm.
28584         (do_pubkey_enc): Ditto.
28585         * g10/ecdh.c (pk_ecdh_encrypt_with_shared_point): Use
28586         gpg_mpi_write_nohdr.
28587         * g10/export.c (transfer_format_to_openpgp):
28588         * g10/keygen.c (ecckey_from_sexp): Return the error.
28589         (gen_ecc): Repalce arg NBITS by CURVE.
28590         (read_parameter_file): Add keywords "Key-Curve" and "Subkey-Curve".
28591         (ask_curve): New.
28592         (generate_keypair, generate_subkeypair): Use ask_curve.
28593         (do_generate_keypair): Also pass curve name.
28594         * g10/keylist.c (list_keyblock_print, list_keyblock_colon): Print
28595         curve name.
28596         * g10/parse-packet.c (mpi_read): Remove workaround for
28597         Libcgrypt < 1.5.
28598         (parse_key): Fix ECC case.  Print the curve name.
28599         * g10/pkglue.c (mpi_from_sexp): Rename to get_mpi_from_sexp.
28600         (pk_verify, pk_check_secret_key): Add special case for Ed25519.
28601         * g10/seskey.c (encode_md_value): Ditto.
28602         * g10/sign.c (do_sign, hash_for, sign_file): Ditto.
28603
28604         kbx: Fix possible segv in kbxdump.
28605         + commit 9ae48b173c93f4747a9826beb1fbd023c4362c22
28606         * kbx/keybox-dump.c (_keybox_dump_blob): Check length before get32.
28607
28608         Require Libgcrypt 1.6.
28609         + commit b27161cd0c76ae6e2381f60c3a502cde3a2aaa21
28610         * agent/pksign.c (do_encode_dsa): Remove Libgcrypt version check
28611
28612 2013-11-13  NIIBE Yutaka  <gniibe@fsij.org>
28613
28614         scd: more pinpad input fix for PC/SC.
28615         + commit abd922e79b2ff63a5a763a30d4a06a91f93d0b12
28616         * scd/apdu.c (check_pcsc_pinpad): Set default values here.
28617         (pcsc_pinpad_verify, pcsc_pinpad_modify): Remove setting default
28618         values, as it's too late.
28619
28620 2013-11-11  NIIBE Yutaka  <gniibe@fsij.org>
28621
28622         scd: more pinpad fix.
28623         + commit 037dea9dd5eac7a74df0e12cb437e71fb0732afa
28624         * scd/apdu.c (check_pcsc_pinpad): Set ->minlen and ->maxlen only when
28625         those are specified.
28626         (pcsc_pinpad_modify): Remove old check code.
28627
28628 2013-10-29  NIIBE Yutaka  <gniibe@fsij.org>
28629
28630         scd: pinpad fix for PC/SC on Windows.
28631         + commit 32989ad2b152d18198d718bc2c7232ce3e79c72f
28632         * scd/apdu.c (SCARD_CTL_CODE): Fix for Windows.
28633
28634 2013-10-28  Werner Koch  <wk@gnupg.org>
28635
28636         doc: Change yat2m to allow arbitrary condition names.
28637         + commit a15c35f37ed2b58805adc213029998aa3e52f038
28638         * doc/yat2m.c (MAX_CONDITION_NESTING): New.
28639         (gpgone_defined): Remove.
28640         (condition_s, condition_stack, condition_stack_idx): New.
28641         (cond_is_active, cond_in_verbatim): New.
28642         (add_predefined_macro, set_macro, macro_set_p): New.
28643         (evaluate_conditions, push_condition, pop_condition): New.
28644         (parse_file): Rewrite to use the condition stack.
28645         (top_parse_file): Set prefined macros.
28646         (main): Change -D to define arbitrary macros.
28647
28648 2013-10-25  NIIBE Yutaka  <gniibe@fsij.org>
28649
28650         scd: fix pinpad input on Windows.
28651         + commit de7e15c6b80164a351586e9087aad86420c8b89e
28652         * scd/apdu.c (open_pcsc_reader_direct): Don't call
28653         pcsc_vendor_specific_init here, but...
28654         (connect_pcsc_card): Call it here.
28655
28656 2013-10-23  NIIBE Yutaka  <gniibe@fsij.org>
28657
28658         po: Update Japanese translation.
28659         + commit b66158cac7347e4c56c79ab7b5416ae5b3f4a0a2
28660
28661
28662 2013-10-16  NIIBE Yutaka  <gniibe@fsij.org>
28663
28664         scd: add pinpad readers information for PC/SC service.
28665         + commit 5efcc2b8fee8de31d255d09037f0a1e6209eab32
28666         * scd/apdu.c (pcsc_vendor_specific_init): Add information for Cherry
28667         ST-2xxx, Reiner cyberJack, Vasco DIGIPASS, FSIJ Gnuk Token, and KAAN
28668         Advance.
28669
28670 2013-10-15  NIIBE Yutaka  <gniibe@fsij.org>
28671
28672         scd: remove pin length check.
28673         + commit e0ab665a792ada6470cb8885b8427acc3c960998
28674         * scd/apdu.c (pcsc_pinpad_verify): Remove old check code for pin
28675         length.
28676
28677 2013-10-04  Werner Koch  <wk@gnupg.org>
28678
28679         gpg: Limit the nesting level of I/O filters.
28680         + commit e6175055fbca958b7fa43aaf84359574ca7f3ebb
28681         * common/iobuf.c (MAX_NESTING_FILTER): New.
28682         (iobuf_push_filter2): Limit the nesting level.
28683
28684         * g10/mainproc.c (mainproc_context): New field ANY.  Change HAVE_DATA
28685         and ANY_SIG_SIGN to bit fields of ANY.  Add bit field
28686         UNCOMPRESS_FAILED.
28687         (proc_compressed): Avoid printing multiple Bad Data messages.
28688         (check_nesting): Return GPG_ERR_BAD_DATA instead of UNEXPECTED_DATA.
28689
28690 2013-10-02  Werner Koch  <wk@gnupg.org>
28691
28692         gpg: Fix bug with deeply nested compressed packets.
28693         + commit 0899f6d4be0406c9efbf9c3f342825804f359b5a
28694         * g10/mainproc.c (MAX_NESTING_DEPTH): New.
28695         (proc_compressed): Return an error code.
28696         (check_nesting): New.
28697         (do_proc_packets): Check packet nesting depth.  Handle errors from
28698         check_compressed.
28699
28700 2013-09-08  Werner Koch  <wk@gnupg.org>
28701
28702         Switch to deterministic DSA.
28703         + commit 6466db10fb22a4f24df4edad9c5cb33ec67321bd
28704         * agent/pksign.c (rfc6979_hash_algo_string): New.
28705         (do_encode_dsa) [Libgcrypt >= 1.6]: Make use of RFC-6979.
28706
28707 2013-08-30  Werner Koch  <wk@gnupg.org>
28708
28709         scd: Suppress gcc warning about possible uninitialized use.
28710         + commit 244587ea41d4c75cb5570356f09a6705864a7e8d
28711         * scd/app-nks.c (parse_pwidstr): Always init r_pwid.
28712
28713         gpg: Use 2048 as the default keysize in batch mode.
28714         + commit 4c3b35b067a4e7002bb6473b879b551014bb7857
28715         * g10/keygen.c (gen_elg, gen_dsa, gen_rsa): Set default keysize to
28716         2048.
28717
28718         gpgtar: Fix building for systems with a separate libintl.
28719         + commit 12990efb45ee7c425167aad19fe759d5609c5182
28720         * tools/Makefile.am (gpgtar_LDADD): Add LIBINTL and LIBICONV.
28721
28722         scd: Use vendor and product id macros also in apdu.c.
28723         + commit fc31d730d8506b069de1d3529ed26660856bf07f
28724         * scd/ccid-driver.c: Move vendor and product ids to ...
28725         * scd/ccid-driver.h: here.
28726         * scd/apdu.c (CCID_DRIVER_INCLUDE_USB_IDS): Define to include ids.
28727         (pcsc_vendor_specific_init): Use vendor and product id macros.
28728
28729 2013-08-30  NIIBE Yutaka  <gniibe@fsij.org>
28730
28731         scd: PC/SC pinpad input improvement.
28732         + commit 95a3bffeaf07e8bf9487d4b165c336d166236fc1
28733         * scd/apdu.c (struct reader_table_s): Add members: PINMIN, PINMAX, and
28734         PINPAD_VERLEN_SUPPORTED.
28735         (CM_IOCTL_VENDOR_IFD_EXCHANGE, FEATURE_GET_TLV_PROPERTIES,
28736         PCSCv2_PART10_PROPERTY_*): New.
28737         (new_reader_slot): Initialize pinpad_varlen_supported, pinmin, pinmax.
28738         (pcsc_vendor_specific_init): New.
28739         (open_pcsc_reader_direct, open_pcsc_reader_wrapped): Call
28740         pcsc_vendor_specific_init.
28741         (check_pcsc_pinpad): Not detect here but use the result of
28742         pcsc_vendor_specific_init.
28743         (pcsc_pinpad_verify, pcsc_pinpad_modify): Specify bNumberMessage.
28744
28745 2013-08-29  Jonas Borgström  <jonas@borgstrom.se>
28746
28747         scd: add support for RSA_CRT and RSA_CRT_N key import.
28748         + commit cc67918c088e90c1d9a507af5f6288e8faa93d87
28749         * scd/app-openpgp.c (do_writekey): Added RSA_CRT and RSA_CRT_N support.
28750
28751 2013-08-29  Werner Koch  <wk@gnupg.org>
28752
28753         kbx: Add a few macros for easier readability.
28754         + commit 3adfaa9beee4502479b5673c7dfd386680a920c5
28755         * kbx/keybox-update.c (FILECOPY_INSERT)
28756         (FILECOPY_DELETE, FILECOPY_UPDATE): New macros.  Replace numbers by
28757         them.
28758
28759 2013-08-28  Werner Koch  <wk@gnupg.org>
28760
28761         Fix commit 04e2c83f.
28762         + commit fdbf76eee6a4e81b040d423926b71af7b491fb4a
28763         * agent/command-ssh.c (stream_read_string): Do not assign to a NULL
28764         ptr.
28765
28766         gpg: Make decryption with the OpenPGP card work.
28767         + commit 780ba3233618393835970bac4cf8aab713f4d7fa
28768         * scd/app-common.h (APP_DECIPHER_INFO_NOPAD): New.
28769         * scd/app-openpgp.c (do_decipher): Add arg R_INFO.
28770         * scd/app-nks.c (do_decipher): Add arg R_INFO as a dummy.
28771         * scd/app.c (app_decipher): Add arg R_INFO.
28772         * scd/command.c (cmd_pkdecrypt): Print status line "PADDING".
28773         * agent/call-scd.c (padding_info_cb): New.
28774         (agent_card_pkdecrypt): Add arg R_PADDING.
28775         * agent/divert-scd.c (divert_pkdecrypt): Ditto.
28776         * agent/pkdecrypt.c (agent_pkdecrypt): Ditto.
28777         * agent/command.c (cmd_pkdecrypt):  Print status line "PADDING".
28778         * g10/call-agent.c (padding_info_cb): New.
28779         (agent_pkdecrypt): Add arg R_PADDING.
28780         * g10/pubkey-enc.c (get_it): Use padding info.
28781
28782         agent: Fix two compiler warnings.
28783         + commit 04e2c83f189cc56342e1be784bdc63761ccdb5bb
28784         * agent/command.c (cmd_preset_passphrase, pinentry_loopback): Use %zu
28785         in format string.
28786         * scd/ccid-driver.c (ccid_get_atr): Ditto.
28787         * agent/command-ssh.c (stream_read_string): Init arg STRING_SIZE to
28788         avoid maybe_unitialized warning.
28789
28790 2013-08-27  NIIBE Yutaka  <gniibe@fsij.org>
28791
28792         scd: fix parsing login-data DO.
28793         + commit b6d54f1196d5f110fd94dfd661e74dbc60ca9811
28794         * scd/app-openpgp.c (parse_login_data): Release RELPTR.  Fix parsing.
28795
28796         scd: fix Vega for Alpha reader.
28797         + commit 54cbab29c700db2df74e808f16db49170e6c42f1
28798         * scd/ccid-driver.c (ccid_vendor_specific_init): Fix error handling
28799         and size of command.
28800
28801 2013-08-21  Werner Koch  <wk@gnupg.org>
28802
28803         scd: Make SPRx32 pinpad work with PC/SC on Windows.
28804         + commit 5c5e52df4b92e23045ac87abac09357de58920d4
28805         * scd/apdu.c (CM_IOCTL_GET_FEATURE_REQUEST): Use SCARD_CTL_CODE.
28806         (SCARD_CTL_CODE): Define if not defined.
28807         (reader_table_s): Add is_spr532.
28808         (new_reader_slot): Clear it.
28809         (check_pcsc_pinpad): Set it.
28810         (pcsc_pinpad_verify, pcsc_pinpad_modify): Add fix for SPR532.
28811
28812         scd: Improve --enable-pinpad-varlen.
28813         + commit 7bde2bf3b0ddb5d3515a44879e1a7ddb581a5c0b
28814         * tools/gpgconf-comp.c (gc_options_scdaemon): Add
28815         enable-pinpad-varlen.
28816         * scd/apdu.c (check_pcsc_pinpad): Detect SPRx32 reader.
28817
28818 2013-08-08  Werner Koch  <wk@gnupg.org>
28819
28820         agent: Extend cmd KEYINFO to return data from sshcontrol.
28821         + commit 50c98c7ed6b542857ee2f902eca36cda37407737
28822         * agent/command-ssh.c (struct control_file_s): Rename to
28823         ssh_control_file_s.
28824         (ssh_open_control_file, ssh_close_control_file)
28825         (ssh_read_control_file, ssh_search_control_file): New.
28826         (control_file_t):  Rename and move to ...
28827         * agent/agent.h (ssh_control_file_t): here.
28828         * agent/command.c (do_one_keyinfo): Add args is_ssh, ttl, disabled,
28829         and confirm. Rename unknown keytype indicator from '-' to 'X'.  Extend
28830         output.
28831         (cmd_keyinfo): Add options --ssh-list and --with-ssh.
28832
28833 2013-08-02  Werner Koch  <wk@gnupg.org>
28834
28835         gpg: No need to create a trustdb when encrypting with --always-trust.
28836         + commit 498b9a95dc65c43240835d64cc92d8fb43014d53
28837         * g10/gpg.c (main): Special case setup_trustdb for --encrypt.
28838
28839 2013-08-01  Werner Koch  <wk@gnupg.org>
28840
28841         w32: Fix recent patch 9ff72e4.
28842         + commit ca6fe88c0068f8d45ef39df0fc7b161998a91fe9
28843         * common/homedir.c (check_portable_app): Fix the name of the control
28844         file.
28845
28846         agent: Include missing prototype.
28847         + commit ef6a6d973c2bcc54006c04dc41f978ff01005c97
28848         * agent/protect.c: Include cvt-openpgp.h.
28849
28850         w32: Add code to support a portable use of GnuPG.
28851         + commit 9ff72e4e7e4f56c241a525479a94ed4c95efc23f
28852         * common/homedir.c (w32_bin_is_bin, w32_portable_app) [W32]: New.
28853         (check_portable_app) [W32]: New.
28854         (standard_homedir, default_homedir) [W32]: Support the portable flag.
28855         (w32_rootdir, w32_commondir) [W32]: Ditto.
28856         (gnupg_bindir, gnupg_cachedir, dirmngr_socket_name) [W32]: Ditto.
28857         * common/logging.h (JNLIB_LOG_NO_REGISTRY): New.
28858         * common/logging.c (no_registry): New variable.
28859         (log_set_prefix, log_get_prefix): Set/get that variable.
28860         (do_logv): Do not check the registry if that variable is set.
28861
28862         Silence compiler warning about deprecated Libgcrypt symbols.
28863         + commit db4651734fe91935b17876dc9194329b00066eff
28864         * configure.ac (AH_BOTTOM): Define GCRYPT_NO_DEPRECATED.
28865
28866         dirmngr: Define missing LDAP constant.
28867         + commit ef2e2e54020c3475bf2129c3ec8360c7bad3a6c9
28868         * dirmngr/ldap-url.c (LDAP_SCOPE_DEFAULT): Define if missing.
28869
28870         scd: Fix a syntax error for Apple and Windows.
28871         + commit 25b0357bf0a4861a751cfbc3e0335ae05c8b2b1b
28872         * scd/apdu.c (pcsc_dword_t) [W32]: Fix syntax error.
28873
28874         common: Fix a build error when using adns.
28875         + commit ffa7472db551f12f66b9789c31fabb5fc80cc13a
28876         * common/dns-cert.c (get_dns_cert) [USE_ADNS]: Fix synatx error.
28877
28878 2013-07-31  Werner Koch  <wk@gnupg.org>
28879
28880         common: Comment out unused code.
28881         + commit f101f34fffee4a02e7a5f62b59667e45e50e8325
28882         * common/w32-reg.c (write_w32_registry_string): Comment out.
28883
28884         dirmngr: Remove unused file.
28885         + commit 2830fcb83c99289a49da0e111766daf2d9a1fa3b
28886         * dirmngr/get-path.c: Remove.
28887
28888 2013-06-27  Werner Koch  <wk@gnupg.org>
28889
28890         sm: Remove cruft from source files.
28891         + commit f254497e09fa4e0e24e63d14f7316fc31c938844
28892         * sm/keydb.c, sm/keydb.h: Remove disabled code parts.
28893
28894         Prepare for newer automake versions.
28895         + commit 043e2728c813299fafcf62cd125ecf872b26179e
28896         * configure.ac (AM_INIT_AUTOMAKE): Replace 2 argument form by the
28897         option form.  Add options from the top Makefile.
28898         (AM_CONFIG_HEADER): Rename to AC_CONFIG_HEADER.
28899         * Makefile.am (AUTOMAKE_OPTIONS): Remove.
28900
28901         * kbx/Makefile.am: Remove INCLUDES.  Include cmacros.am.  FActor some
28902         AM_CPPFLAGS options to  AM_CFLAGS.
28903
28904 2013-06-26  Werner Koch  <wk@gnupg.org>
28905
28906         Fix Makefile regression.
28907         + commit 136f190a2f20c6ec4d5c3ca3ac7f0440c14e4dc2
28908         * agent/Makefile.am (gpg_agent_DEPENDENCIES): Remove cruft from wrong
28909         resolve conflict 2013-04-25.
28910         (gpg_agent_DEPENDENCIES): Remove obsolete gpg_agent_res_deps
28911         (gpg_agent_LDFLAGS): Remove obsolete gpg_agent_res_ldflags.
28912
28913 2013-05-22  Werner Koch  <wk@gnupg.org>
28914
28915         Implement unattended OpenPGP secret key import.
28916         + commit 7777e68d0482c942f527e91c04adbcfb40bc8bef
28917         * agent/command.c (cmd_import_key): Add option --unattended.
28918         * agent/cvt-openpgp.c (convert_transfer_key): New.
28919         (do_unprotect): Factor some code out to ...
28920         (prepare_unprotect): new function.
28921         (convert_from_openpgp): Factor all code out to ...
28922         (convert_from_openpgp_main): this.  Add arg 'passphrase'.  Implement
28923         openpgp-native protection modes.
28924         (convert_from_openpgp_native): New.
28925         * agent/t-protect.c (convert_from_openpgp_native): New dummy fucntion
28926         * agent/protect-tool.c (convert_from_openpgp_native): Ditto.
28927         * agent/protect.c (agent_unprotect): Add arg CTRL.  Adjust all
28928         callers.  Support openpgp-native protection.
28929         * g10/call-agent.c (agent_import_key): Add arg 'unattended'.
28930         * g10/import.c (transfer_secret_keys): Use unattended in batch mode.
28931
28932         New debug functions log_printcanon and log_printsexp.
28933         + commit cb6a64bb78296c8e9f72df0c482ff847e89a1541
28934         * common/sexputil.c (sexp_to_string, canon_sexp_to_string): New.
28935         (log_printcanon, log_printsexp): New.
28936
28937         agent: Fix length detection of canonical formatted openpgp keys.
28938         + commit 0f0e0559f9b160824f10dc17b389268cdb53aea4
28939         * agent/command.c (cmd_import_key): Pass 0 instead of KEYLEN to
28940         gcry_sexp_canon_len.
28941
28942         agent: New option --disable-check-own-socket.
28943         + commit f2d8a14e1b12534eba69d595a62c78f92331e11b
28944         * agent/gpg-agent.c (oDisableCheckOwnSocket): New.
28945         (disable_check_own_socket): New.
28946         (parse_rereadable_options): Set new option.
28947         (check_own_socket): Implement new option.
28948
28949 2013-05-07  Werner Koch  <wk@gnupg.org>
28950
28951         w32: Add icons and version information.
28952         + commit 88e24341e57c96e31a25e92e09d67989e64cc1c1
28953         * common/gnupg.ico: New.  Take from artwork/gnupg-favicon-1.ico.
28954         * agent/gpg-agent-w32info.rc: New.
28955         * g10/gpg-w32info.rc: New.
28956         * scd/scdaemon-w32info.rc: New.
28957         * sm/gpgsm-w32info.rc: New.
28958         * tools/gpg-connect-agent-w32info.rc: New.
28959         * common/w32info-rc.h.in: New.
28960         * configure.ac (BUILD_REVISION, BUILD_FILEVERSION, BUILD_TIMESTAMP)
28961         (BUILD_HOSTNAME): New.
28962         (AC_CONFIG_FILES): Add w32info-rc.h.
28963         * am/cmacros.am (.rc.o): New rule.
28964         * agent/Makefile.am, common/Makefile.am, g10/Makefile.am
28965         * scd/Makefile.am, sm/Makefile.am, tools/Makefile.am: Add stuff to
28966         build resource files.
28967
28968 2013-05-07  Ian Abbott  <abbotti@mev.co.uk>
28969
28970         doc: fix some Texinfo warnings.
28971         + commit 2c3fc4719b92d9e3ac32efd134a930e1cc126032
28972         * doc/gpg.texi: Fix syntax and add missing menu entries.
28973         * doc/gpgsm.texi: Fix subsectioning.
28974
28975 2013-04-22  Werner Koch  <wk@gnupg.org>
28976
28977         Fix potential heap corruption in "gpg -v --version".
28978         + commit 151b78cc26d728e9eb42620e0caf8c6f4bd7f839
28979         * g10/gpg.c (build_list): Rewrite to cope with buffer overflow in
28980         certain locales.
28981
28982 2013-04-19  Werner Koch  <wk@gnupg.org>
28983
28984         gpgsm: Remove non-implemented commands from --help.
28985         + commit d6798d261cbe6519ef5b3ebb474e2ad348442c0c
28986         * sm/gpgsm.c (opts): Removed commands --clearsign, --symmetric,
28987         --send-keys, and --recv-keys.
28988
28989 2013-04-19  Daiki Ueno  <ueno@gnu.org>
28990
28991         Make sure to call fflush if estream_t is backed with stdio.
28992         + commit e498180d5647d3427a7d7e6c82a9f09cf1ba439d
28993         * common/estream.c (es_func_fp_write): Call fflush after fwrite.
28994
28995 2013-04-19  Werner Koch  <wk@gnupg.org>
28996
28997         doc: Formatting fixes.
28998         + commit ff6115227a1ced14e2fb3d160a12181b9dfbc502
28999         * doc/Makefile.am (.fig.jpg): Correct to use -L jpeg.
29000         * doc/gpg.texi: Fix cross reference for --options.
29001         * doc/gpgsm.texi: Likewise.
29002         * doc/gpl.texi: Fix enumerate and re-indent examples.
29003
29004 2013-04-01  NIIBE Yutaka  <gniibe@fsij.org>
29005
29006         scd: move SCDaemon to libexecdir.
29007         + commit 021767d8aa11aac8ac87dc3a31969ee6cfa65966
29008         * common/homedir.c (gnupg_module_name): It's now libexecdir.
29009         * scd/Makefile.am (libexec_PROGRAMS): Add scdaemon
29010         (bin_PROGRAMS): Remove scdaemon.
29011
29012 2013-03-29  Werner Koch  <wk@gnupg.org>
29013
29014         copyright assignments are not anymore required.
29015         + commit 07227279c44e3af0939f90025a0d22b782d0f185
29016
29017
29018 2013-03-26  NIIBE Yutaka  <gniibe@fsij.org>
29019
29020         scd: PC/SC status fix.
29021         + commit 64b1a2cf6f18348544a2d2cd4d49fd27bf01c150
29022         * scd/apdu.c (pcsc_get_status_direct): Check PCSC_STATE_MUTE only when
29023         PCSC_STATE_PRESENT.
29024
29025         * scd/pcsc-wrapper.c (handle_status): Ditto.
29026
29027         scd: PC/SC cleanup (more).
29028         + commit b9aceaa442914beb4f5359283053b43ba5a46b4c
29029         * scd/apdu.c (control_pcsc_direct, control_pcsc_wrapped, control_pcsc)
29030         (check_pcsc_pinpad, pcsc_pinpad_verify, pcsc_pinpad_modify): Use
29031         pcsc_dword_t.
29032
29033         scd: call update_card_removed only when detecting removal.
29034         + commit 1062893832bb15eaac853f52e1cb673e5e03790a
29035         * scd/command.c (update_reader_status_file): Add condition
29036         vr->status == 0.
29037
29038 2013-03-22  NIIBE Yutaka  <gniibe@fsij.org>
29039
29040         scd: PC/SC cleanup.
29041         + commit ee95c23fcdc6673db0fc7287ab2197915d9b55b3
29042         * scd/apdu.c (pcsc_dword_t): New.  It was named as DWORD (double-word)
29043         when a word was 16-bit.
29044         (struct reader_table_s): Fixes for types.
29045         (struct pcsc_readerstate_s) [__APPLE__]: Enable #pragma pack(1).
29046         Throughout: Fixes for types.
29047
29048         * scd/pcsc-wrapper.c: Likewise.
29049
29050 2013-03-21  NIIBE Yutaka  <gniibe@fsij.org>
29051
29052         po: Enable ja.po.
29053         + commit a75a08d6e30e93e1793aa78a15d473a3ea7623cb
29054         * po/LINGUAS: Enable ja.po.
29055
29056         scd: change default value of pinpad maxlen.
29057         + commit ca66f5c779af74d0eb7221afd7a9707201931e50
29058         * scd/apdu.c (pcsc_pinpad_verify, pcsc_pinpad_modify): Default value
29059         of maxlen for pinpad input is now 15 (was: 25).
29060
29061         * scd/ccid-driver.c (ccid_transceive_secure): Likewise.
29062
29063 2013-03-20  Werner Koch  <wk@gnupg.org>
29064
29065         Add code to allow for late memory cleanup.
29066         + commit 2739834206f23833161898a73427b8a9c6d5d26d
29067         * common/init.c (mem_cleanup_item_t): New.
29068         (run_mem_cleanup): New.
29069         (_init_common_subsystems): Add an atexit for it.
29070         (register_mem_cleanup_func): New.
29071
29072         * g10/kbnode.c (cleanup_registered): New.
29073         (release_unused_nodes): New.
29074         (alloc_node): Call register_mem_cleanup_func.
29075
29076         kbx: Remove unused macro.
29077         + commit 44159b681f8f09000fabfc3ee294d5821578d3a6
29078         * kbx/keybox.h (KEYBOX_WITH_OPENPGP): Remove unused macro.
29079
29080 2013-03-19  Werner Koch  <wk@gnupg.org>
29081
29082         gpg: Print indicator for unknown key capability.
29083         + commit c4dbd1b2de8ae3847a040444e86500848868bcf4
29084         * g10/keylist.c (print_capabilities): Print '?' for unknown usage.
29085
29086 2013-03-19  Daniel Kahn Gillmor  <dkg@fifthhorseman.net>
29087
29088         gpg: Allow setting of all zero key flags.
29089         + commit b693ec02c467696bf9d7324dd081e279f9965151
29090         * g10/keygen.c (do_add_key_flags): Do not check for empty key flags.
29091
29092 2013-03-19  Werner Koch  <wk@gnupg.org>
29093
29094         gpg: Distinguish between missing and cleared key flags.
29095         + commit 4bde12206c5bf199dc6e12a74af8da4558ba41bf
29096         * include/cipher.h (PUBKEY_USAGE_NONE): New.
29097         * g10/getkey.c (parse_key_usage): Set new flag.
29098
29099 2013-03-15  NIIBE Yutaka  <gniibe@fsij.org>
29100
29101         scd: ccid-driver supporting larger APDU.
29102         + commit 76dc5c08dc2686eef32e1bd221c60fe91201246f
29103         * scd/ccid-driver.c (ccid_transceive_apdu_level): Support larger
29104         APDU.
29105
29106         scd: fix missing close paren.
29107         + commit 006782068e4d2a9413770400494421a2e9726ee7
29108         * scd/app-openpgp.c (du_auth): Fix.
29109
29110 2013-03-09  NIIBE Yutaka  <gniibe@fsij.org>
29111
29112         scd: support ECDSA signing.
29113         + commit 73ad742deacfe2bf7d6efc7cc30f9ced2d83521a
29114         * scd/app-openpgp.c (do_sign): Only prepend message digest block
29115         for RSA or do_auth.
29116         (do_auth): Remove message digest block for ECDSA.
29117
29118 2013-03-08  NIIBE Yutaka  <gniibe@fsij.org>
29119
29120         scd: support ECDSA public key.
29121         + commit 010bc7f4f06d8affb98950e1adc76c68bfcc9abb
29122         * scd/app-openpgp.c (key_type_t): New.
29123         (CURVE_NIST_P256, CURVE_NIST_P384, CURVE_NIST_P521): New.
29124         (struct app_local_s): Change keyattr to have key_type and union.
29125         (get_ecc_key_parameters, get_curve_name): New.
29126         (send_key_attr, get_public_key): Support ECDSA.
29127         (build_privkey_template, do_writekey, do_genkey): Follow the change
29128         of the member KEY_ATTR.
29129         (parse_historical): New.
29130         (parse_algorithm_attribute): Support ECDSA.
29131
29132 2013-03-05  Werner Koch  <wk@gnupg.org>
29133
29134         Require libgpg-error 1.11.
29135         + commit 5bac5040dc93343e1e89916b263390b0e52040bf
29136         * configure.ac: Require libgpg-error 1.11.
29137         * common/util.h (GPG_ERR_NO_KEYSERVER, GPG_ERR_INV_CURVE)
29138         (GPG_ERR_UNKNOWN_CURVE): Remove fallback definitions.
29139
29140 2013-02-28  NIIBE Yutaka  <gniibe@fsij.org>
29141
29142         agent: pksign result conversion to sexp to upper layer.
29143         + commit ef1983d58b913306e9bf02a7189e530123839c59
29144         * agent/agent.h (divert_pksign): Add R_SIGLEN argument.
29145         * agent/divert-scd.c (divert_pksign): Return length at R_SIGLEN.
29146         * agent/call-scd.c (agent_card_pksign): Move composition of
29147         S-expression to...
29148         * agent/pksign.c (agent_pksign_do): ... here.
29149
29150 2013-02-22  Werner Koch  <wk@gnupg.org>
29151
29152         Use has_leading_keyword in the assuan callbacks.
29153         + commit 585d5c62eece23911a768d97d11f159be138b13d
29154         * agent/call-pinentry.c (inq_quality): Use has_leading_keyword.
29155         * agent/call-scd.c (inq_needpin, inq_writekey_parms): Ditto.
29156         * g10/call-agent.c (inq_writecert_parms, keyinfo_status_cb): Ditto.
29157         (inq_genkey_parms, inq_ciphertext_cb, inq_import_key_parms): Ditto.
29158         * g10/call-dirmngr.c (ks_put_inq_cb): Ditto.
29159         * sm/call-agent.c (default_inq_cb, inq_ciphertext_cb): Ditto.
29160         (inq_genkey_parms, istrusted_status_cb, learn_status_cb): Ditto.
29161         (keyinfo_status_cb, inq_import_key_parms): Ditto.
29162         * sm/call-dirmngr.c (inq_certificate, isvalid_status_cb): Ditto.
29163         (lookup_status_cb, run_command_inq_cb, run_command_status_cb): Ditto.
29164
29165         Remove some unused variables.
29166         + commit c6b8f05517228c6aeab28d2bf5da7724c059bb1a
29167         * tools/gpgconf-comp.c (gc_process_gpgconf_conf): Remove unused
29168         used_components.
29169         * agent/command-ssh.c (ssh_signature_encoder_ecdsa): Mark unused arg.
29170         * g13/g13.c (main): Comment variable of yet unimplemented options.
29171
29172         gpg: Fix a memory leak in batch key generation.
29173         + commit 161674118d568025896026ede5e03d26bdfdfa68
29174         * g10/keygen.c (append_to_parameter): New.
29175         (proc_parameter_file): Use new func to extend the parameter list.
29176
29177         * g10/passphrase.c (passphrase_to_dek_ext): Print a diagnostic of
29178         gcry_kdf_derive failed.
29179         * g10/keygen.c (proc_parameter_file): Print a diagnostic if
29180         passphrase_to_dek failed.
29181
29182         gpg: Handle the agent's NEW_PASSPHRASE inquiry.
29183         + commit baee681d2406530c45fd6d4bde77193ba23ac263
29184         * g10/call-agent.c (default_inq_cb): Take care of NEW_PASSPHRASE.
29185
29186         common: Add func has_leading_keyword.
29187         + commit 2838385e76c8c7108bc949d5a1d1c947051bd5be
29188         * common/stringhelp.c (has_leading_keyword): New.
29189
29190         Remove build hacks for FreeBSD.
29191         + commit 21f5a9ec27c0794141a835a5bb3c69495ee554a6
29192         * configure.ac [freebsd]: Do not add /usr/local to CPPFLAGS and
29193         LDFLAGS.
29194
29195 2013-02-22  NIIBE Yutaka  <gniibe@fsij.org>
29196
29197         agent: fix two bugs.
29198         + commit 3c3648e720b8014828573bd708c88ba4775014e3
29199         * agent/command.c (cmd_keytocard): Decrement KEYDATALEN.
29200         * agent/findkey.c (agent_public_key_from_file): Increment for ELEMS.
29201
29202         gpg: fix keytocard and support ECC card for key attribute.
29203         + commit 7d376ffa321d4af6e62a2bc64ef2b8574b122b1a
29204         * g10/call-agent.c (agent_keytocard): Supply PARM arg.
29205         * g10/card-util.c (card_status): Support ECC.
29206         (card_store_subkey): Don't assume RSA.
29207
29208 2013-02-21  Werner Koch  <wk@gnupg.org>
29209
29210         gpg: Fix a memory leak in batch key generation.
29211         + commit 273bb38cd7b517460cb3de67662e96e910104675
29212         * g10/keygen.c (append_to_parameter): New.
29213         (proc_parameter_file): Use new func to extend the parameter list.
29214
29215         * g10/passphrase.c (passphrase_to_dek_ext): Print a diagnostic of
29216         gcry_kdf_derive failed.
29217         * g10/keygen.c (proc_parameter_file): Print a diagnostic if
29218         passphrase_to_dek failed.
29219
29220         gpg: Handle the agent's NEW_PASSPHRASE inquiry.
29221         + commit 18a261b65fd77a9e434b13483ceaaaf2176f1197
29222         * g10/call-agent.c (default_inq_cb): Take care of NEW_PASSPHRASE.
29223
29224         common: Add func has_leading_keyword.
29225         + commit 4af0c62b15c51056dc293c8e3b907e7c41fbf08c
29226         * common/stringhelp.c (has_leading_keyword): New.
29227
29228 2013-02-20  Werner Koch  <wk@gnupg.org>
29229
29230         Remove build hacks for FreeBSD.
29231         + commit 8e5766c38f3ac376fb8e7c7f2b0f65de23d84cbe
29232         * configure.ac [freebsd]: Do not add /usr/local to CPPFLAGS and
29233         LDFLAGS.
29234
29235 2013-02-12  NIIBE Yutaka  <gniibe@fsij.org>
29236
29237         gpg: Implement card_store_subkey again.
29238         + commit b90506ea220860c89128f002bd593d0462a08d73
29239         * g10/call-agent.h (agent_keytocard): New.
29240         * g10/call-agent.c (agent_keytocard): New.
29241         * g10/card-util.c (replace_existing_key_p): Returns 1 when replace.
29242         (card_generate_subkey): Check return value of replace_existing_key_p.
29243         (card_store_subkey): Implement again using agent_keytocard.
29244
29245         agent: Add KEYTOCARD command.
29246         + commit 30f8a3c8736451d8c06ef72521a8da5eabf23016
29247         * agent/agent.h (divert_writekey, agent_card_writekey): New.
29248         * agent/call-scd.c (inq_writekey_parms, agent_card_writekey): New.
29249         * agent/command.c (cmd_keytocard, hlp_keytocard): New.
29250         (register_commands): Add cmd_keytocard.
29251         * agent/divert-scd.c (divert_writekey): New.
29252
29253         Japanese: update po and doc.
29254         + commit 595ab0da666c43a1315a72a1346ee149998d8771
29255         * doc/help.ja.txt, po/ja.po: Updated.
29256
29257 2013-02-08  NIIBE Yutaka  <gniibe@fsij.org>
29258
29259         scd: Rename 'keypad' to 'pinpad'.
29260         + commit 7253093addfd82a8dd25cd80e3ba820a85e3c9a7
29261         * NEWS: Mention scd changes.
29262
29263         * agent/divert-scd.c (getpin_cb): Change message.
29264
29265         * agent/call-scd.c (inq_needpin): Change the protocol to
29266         POPUPPINPADPROMPT and DISMISSPINPADPROMPT.
29267         * scd/command.c (pin_cb): Likewise.
29268
29269         * scd/apdu.c (struct reader_table_s): Rename member functions.
29270         (check_pcsc_pinpad, pcsc_pinpad_verify, pcsc_pinpad_modify,
29271         check_ccid_pinpad, ccid_pinpad_operation, apdu_check_pinpad
29272         apdu_pinpad_verify, apdu_pinpad_modify): Rename.
29273
29274         * scd/apdu.h (SW_HOST_NO_PINPAD, apdu_check_pinpad)
29275         (apdu_pinpad_verify, apdu_pinpad_modify): Rename.
29276
29277         * scd/iso7816.h (iso7816_check_pinpad): Rename.
29278
29279         * scd/iso7816.c (map_sw): Use SW_HOST_NO_PINPAD.
29280         (iso7816_check_pinpad): Rename.
29281         (iso7816_verify_kp, iso7816_change_reference_data_kp): Follow
29282         the change.
29283
29284         * scd/ccid-driver.h (CCID_DRIVER_ERR_NO_PINPAD): Rename.
29285         * scd/ccid-driver.c (ccid_transceive_secure): Use it.
29286
29287         * scd/app-dinsig.c (verify_pin): Follow the change.
29288         * scd/app-nks.c (verify_pin): Follow the change.
29289
29290         * scd/app-openpgp.c (check_pinpad_request): Rename.
29291         (parse_login_data, verify_a_chv, verify_chv3, do_change_pin): Follow
29292         the change.
29293
29294         * scd/scdaemon.c (oDisablePinpad, oEnablePinpadVarlen): Rename.
29295
29296         * scd/scdaemon.h (opt): Rename to disable_pinpad,
29297         enable_pinpad_varlen.
29298
29299         * tools/gpgconf-comp.c (gc_options_scdaemon): Rename to
29300         disable-pinpad.
29301
29302 2013-02-07  Werner Koch  <wk@gnupg.org>
29303
29304         gpg: Add pinentry-mode feature.
29305         + commit 21feecd48f990b2569cb4b385dea3e57b9501525
29306         * g10/gpg.c: Include shareddefs.h.
29307         (main): Add option --pinentry-mode.
29308         * g10/options.h (struct opt): Add field pinentry_mode.
29309         * g10/passphrase.c: Include shareddefs.h.
29310         (have_static_passphrase): Take care of loopback pinentry_mode.
29311         (read_passphrase_from_fd): Ditto.
29312         (get_static_passphrase): New.
29313         (passphrase_to_dek_ext): Factor some code out to ...
29314         (emit_status_need_passphrase): new.
29315         * g10/call-agent.c (start_agent): Send the pinentry mode.
29316         (default_inq_cb): Take care of the PASSPHRASE inquiry.  Return a
29317         proper error code.
29318         (agent_pksign): Add args keyid, mainkeyid and pubkey_algo.
29319         (agent_pkdecrypt): Ditto.
29320         * g10/pubkey-enc.c (get_it): Pass new args.
29321         * g10/sign.c (do_sign): Pass new args.
29322
29323         * g10/call-agent.c (struct default_inq_parm_s): New.  Change all
29324         similar structs to reference this one.  Change all users and inquire
29325         callback to use this struct, instead of NULL or some undefined but not
29326         used structs.  This change will help to eventually get rid of global
29327         variables.
29328
29329 2013-02-06  Werner Koch  <wk@gnupg.org>
29330
29331         agent: Move a typedef to common and provide parse_pinentry_mode.
29332         + commit 8b2b8dfe5c4cd346bbea2c228e75737bbeeca4c4
29333         * common/agent-opt.c: New.
29334         * common/shareddefs.h: New.
29335         * common/Makefile.am: Add new files.
29336         * agent/agent.h: Include shareddefs.h.
29337         (pinentry_mode_t): Factor out to shareddefs.h.
29338         * agent/command.c (option_handler): Use parse_pinentry_mode.
29339
29340         agent: Return a better error code if no passphrase was given.
29341         + commit 4483a4f0ea030046137ba04905eb5220c14a2161
29342         * agent/protect.c (hash_passphrase): Handle an empty passphrase.
29343
29344 2013-02-05  NIIBE Yutaka  <gniibe@fsij.org>
29345
29346         scd: Fix check_keypad_request.
29347         + commit c27315fc6466cceb862c9e67755a8e044e9b7688
29348         * scd/app-openpgp.c (check_keypad_request): 0 means not to use pinpad.
29349
29350         SCD: Add vendor specific initalization.
29351         + commit e791ac6683bfb90d5e40c0103324784bd58535c9
29352         * scd/ccid-driver.c (ccid_vendor_specific_init): New.
29353         (ccid_open_reader): Call ccid_vendor_specific_init.
29354
29355         SCD: Support P=N format for login data.
29356         + commit 0407e642f796fb2780a77b7a1a86731d0de27e5d
29357         * scd/app-openpgp.c (parse_login_data): Support P=N format.
29358
29359         SCD: Better interoperability.
29360         + commit bd5eded73a1268afdf81482f8408e5f640abf9c4
29361         * scd/apdu.c: Fill bTeoPrologue[2] field.
29362
29363         SCD: Defaults to use pinpad if the reader has the capability.
29364         + commit a9ff97a10f7ae5a703ed1bccba294473ecc88d5d
29365         * scd/app-openpgp.c (struct app_local_s): Remove VARLEN.
29366         (parse_login_data): "P=0" means to disable pinpad.
29367         (check_keypad_request): Default is to use pinpad if available.
29368
29369         SCD: handle keypad request on the card.
29370         + commit 334ba6efa5a05d8849fae213128a0505e7615e13
29371         * scd/app-openpgp.c: Add 2013.
29372         (struct app_local_s): Add keypad structure.
29373         (parse_login_data): Add parsing keypad request on the card.
29374         (check_keypad_request): New.
29375         (verify_a_chv, verify_chv3, do_change_pin): Call check_keypad_request
29376         to determine use of keypad.
29377
29378         SCD: Minor fix of ccid-driver.
29379         + commit d5bf83a24cf3871b7d8cfe61049f70e1e206d09a
29380         * scd/ccid-driver.c (VENDOR_VEGA): Fix typo.
29381
29382         SCD: Add support of Covadis VEGA_ALPHA reader.
29383         + commit 82e1e837c29225cd55642b193cc04ce6191d19bb
29384         * scd/ccid-driver.c: Add 2013.
29385         (VENDER_VEGA, VEGA_ALPHA):New.
29386         (ccid_transceive_secure): VEGA_ALPHA is same firmware as GEMPC_PINPAD.
29387         Change bNumberMessage to 0x01, as it works better (was: 0xff).
29388
29389         SCD: Support fixed length PIN input for keypad (PC/SC).
29390         + commit 3aae780f9debaeb3560ff866b7e09d0923481c57
29391         * scd/apdu.c (pcsc_keypad_verify): SUpport fixed length PIN input for
29392         keypad.
29393         (pcsc_keypad_modify): Likewise.
29394         * scd/ccid-driver.c (ccid_transceive_secure): Clean up.
29395
29396         SCD: Support fixed length PIN input for keypad.
29397         + commit 40a914a2e3052847b49c4b5e8ac8538e97efd18a
29398         * scd/iso7816.h (struct pininfo_s): Remove MODE and add FIXEDLEN.
29399         * scd/app-dinsig.c (verify_pin): Initialize FIXEDLEN to unknown.
29400         * scd/app-nks.c (verify_pin): Likewise.
29401         * scd/app-openpgp.c (verify_a_chv, verify_chv3, do_change_pin):
29402         Likewise.
29403         * scd/apdu.c (check_pcsc_keypad): Add comment.
29404         (pcsc_keypad_verify, pcsc_keypad_modify): PC/SC driver only support
29405         readers with the feature of variable length input (yet).
29406         (apdu_check_keypad): Set FIXEDLEN.
29407         * scd/ccid-driver.c (ccid_transceive_secure): Add GEMPC_PINPAD
29408         specific settings.
29409         Support fixed length PIN input for keypad.
29410
29411         SCD: API cleanup for keypad handling.
29412         + commit b526f6e223604b7c1852ef2aab9fc1ea691b1181
29413         * scd/iso7816.h (struct pininfo_s): Rename from iso7816_pininfo_s.
29414         Change meaning of MODE.
29415         (pininfo_t): Rename from iso7816_pininfo_t.
29416         * scd/sc-copykeys.c: Include "iso7816.h".
29417         * scd/scdaemon.c, scd/command.c: Likewise.
29418         * scd/ccid-driver.c: Include "scdaemon.h" and "iso7816.h".
29419         (ccid_transceive_secure): Follow the change of PININFO_T.
29420         * scd/app.c: Include "apdu.h" after "iso7816.h".
29421         * scd/iso7816.c (iso7816_check_keypad, iso7816_verify_kp)
29422         (iso7816_change_reference_data_kp): Follow the change of API.
29423         * scd/apdu.c (struct reader_table_s): Change API of CHECK_KEYPAD,
29424         KEYPAD_VERIFY, KEYPAD_MODIFY to have arg of PININFO_T.
29425         (check_pcsc_keypad, check_ccid_keypad): Likewise.
29426         (apdu_check_keypad, apdu_keypad_verify, apdu_keypad_modify): Likewise.
29427         (pcsc_keypad_verify, pcsc_keypad_modify, ct_send_apdu)
29428         (pcsc_send_apdu_direct,  pcsc_send_apdu_wrapped, pcsc_send_apdu)
29429         (send_apdu_ccid, ccid_keypad_operation, my_rapdu_send_apdu, send_apdu)
29430         (send_le): Follow the change of API.
29431         * scd/apdu.h (apdu_check_keypad, apdu_keypad_verify)
29432         (apdu_keypad_modify): Change the API.
29433         * scd/app-dinsig.c, scd/app-nks.c, scd/app-openpgp.c: Follow the
29434         change.
29435
29436         SCD: Clean up.  Remove PADLEN for keypad input.
29437         + commit ca89277cb4cb9558da97a71a4cb070cb77c9b536
29438         * scd/apdu.c (struct pininfo_s): Use iso7816_pininfo_s.
29439         (struct reader_table_s): Remove last arg from check_keypad method.
29440         (check_pcsc_keypad, check_pcsc_keypad): Remove PIN_PADLEN.
29441         (pcsc_keypad_verify, pcsc_keypad_modify): Don't check PIN_PADLEN.
29442         (send_apdu_ccid, ccid_keypad_operation): Remove PIN_PADLEN.
29443         (apdu_check_keypad, apdu_keypad_verify, apdu_keypad_modify):
29444         Likewise.
29445
29446         * scd/apdu.h (apdu_check_keypad, apdu_keypad_verify)
29447         (apdu_keypad_modify): Remove PIN_PADLEN.
29448
29449         * scd/ccid-driver.c (ccid_transceive_secure): Remove PIN_PADLEN.
29450
29451         * scd/ccid-driver.h (ccid_transceive_secure): Remove PIN_PADLEN.
29452
29453         * scd/iso7816.c (iso7816_check_keypad, iso7816_verify_kp)
29454         (iso7816_change_reference_data_kp): Remove PADLEN.
29455
29456         * scd/iso7816.h (struct iso7816_pininfo_s): Remove PADLEN, PADCHAR.
29457
29458         SCD: Add option enable-keypad-varlen and support for GEMPC_PINPAD.
29459         + commit d9f6cc7502793ed41928042cc2f968c8c7effc22
29460         * scd/scdaemon.h (opt): Add enable_keypad_varlen.
29461         * scd/scdaemon.c (cmd_and_opt_values): Add oEnableKeypadVarlen.
29462         (opts, main): Add oEnableKeypadVarlen.
29463         * scd/ccid-driver.c (GEMPC_PINPAD): New.
29464         (ccid_transceive_secure): Add enable_varlen handling.
29465         Enable GEMPC_PINPAD.
29466
29467 2013-01-30  Werner Koch  <wk@gnupg.org>
29468
29469         Remove unused status codes.
29470         + commit 50a7badbdacac8ba472b35090c1aab4568434d04
29471         * common/status.h (STATUS_BEGIN_STREAM, STATUS_END_STREAM)
29472         (STATUS_SIEXPIRED): Remove unused codes.
29473
29474         gpg: Add status line PINENTRY_LAUNCHED.
29475         + commit 1cd6445eec4c3642ad92afb02f3563a01cc10c10
29476         * common/status.h (STATUS_PINENTRY_LAUNCHED): New.
29477         * g10/server.c (server_local_s): Add field allow_pinentry_notify.
29478         (option_handler): Add option "allow-pinentry-notify".
29479         (gpg_proxy_pinentry_notify): New.
29480         * g10/call-agent.c (default_inq_cb): Factor code out to the new
29481         function.
29482
29483 2013-01-25  NIIBE Yutaka  <gniibe@fsij.org>
29484
29485         agent: Fix a bug of handling return code from npth_join.
29486         + commit 19994466449a93704d38d429ca1ea36f63da0bf0
29487         * agent/call-pinentry.c (agent_popup_message_stop): Fix npth_join
29488         return code.
29489
29490 2013-01-11  Christian Aistleitner  <christian@quelltextlich.at>
29491
29492         gpg: Fix honoring --cert-digest-algo when recreating a cert.
29493         + commit 60c58766aeb847b769372fa981f79abac6014500
29494         * g10/sign.c (update_keysig_packet): Override original signature's
29495         digest algo in hashed data and for hash computation.
29496
29497 2013-01-11  Werner Koch  <wk@gnupg.org>
29498
29499         Fix spurious cruft from configure summary output.
29500         + commit 7a638c094fa1aa7ed1d9caf085af9980a2664d64
29501         * configure.ac (build_scdaemon_extra): Remove $tmp cruft.
29502
29503 2013-01-11  NIIBE Yutaka  <gniibe@fsij.org>
29504
29505         SCD: Hold lock for pinpad input.
29506         + commit 4dddf32c83f52483d95d7770232e9e808558e702
29507         * scd/apdu.c (apdu_check_keypad, apdu_keypad_verify)
29508         (apdu_keypad_modify): Hold lock to serialize communication.
29509
29510 2013-01-08  Werner Koch  <wk@gnupg.org>
29511
29512         kbx: Switch from MD5 to SHA-1 for the checksum.
29513         + commit b11f84b858bad867f1062977a7aba30299157e90
29514         * kbx/keybox-blob.c (put_membuf): Use a NULL buf to store zero bytes.
29515         (create_blob_finish): Write just the needed space.
29516         (create_blob_finish): Switch to SHA-1.
29517         * kbx/keybox-dump.c (print_checksum): New.
29518         (_keybox_dump_blob): Print the checksum and the verification status.
29519
29520         gpg: Cache keybox searches.
29521         + commit 492792378dc7a79316ef742b2ffaa46c6cda282a
29522         * common/iobuf.c (iobuf_seek): Fix for temp streams.
29523         * g10/pubkey-enc.c (get_session_key, get_it): Add some log_clock calls.
29524         * g10/keydb.c (dump_search_desc): New.
29525         (enum_keyblock_states, struct keyblock_cache): New.
29526         (keyblock_cache_clear): New.
29527         (keydb_get_keyblock, keydb_search): Implement a keyblock cache.
29528         (keydb_update_keyblock, keydb_insert_keyblock, keydb_delete_keyblock)
29529         (keydb_rebuild_caches, keydb_search_reset): Clear the cache.
29530
29531         Make log_clock easier to read.
29532         + commit 5c565512b8af73bee2a176530663154b9277ef1c
29533         * common/logging.c (log_clock): Print in microseconds.
29534
29535         gpg: Remove a function wrapper.
29536         + commit f3f5721e6843a08d1011875400f385b8cd5fe226
29537         * g10/keydb.h (keydb_search): Remove macro.
29538         * g10/keydb.c (keydb_search2): Rename to keydb_search.  Change all
29539         callers.
29540
29541 2013-01-08  NIIBE Yutaka  <gniibe@fsij.org>
29542
29543         SCD: Support not-so-smart card readers.
29544         + commit a776f660363d20b6cc023609c4547e0aa8825d97
29545         * scd/ccid-driver.c (struct ccid_driver_s): Add auto_voltage,
29546         auto_param, and auto_pps.
29547         (parse_ccid_descriptor): Set auto_voltage, auto_param, and auto_pps.
29548         Support non-autoconf readers.
29549         (update_param_by_atr): New.
29550         (ccid_get_atr): Use 5V for PowerOn when auto_voltage is not supported.
29551         Use 0x10 when nonnull_nad for SetParameters.
29552         Call update_param_by_atr for parsing ATR, and use param for
29553         SetParameters.
29554         Send PPS if reader requires it and card is negotiable.
29555         When bNadValue in the return values of SetParameters == 0,
29556         clear handle->nonnull_nad flag.
29557
29558 2013-01-07  Werner Koch  <wk@gnupg.org>
29559
29560         gpg: Set the node flags while retrieving a keyblock.
29561         + commit f6d7b3f1ee5eed32bc3257c99cb878091d26c482
29562         * g10/keydb.c (parse_keyblock_image): Add args PK_NO and UID_NO and
29563         set the note flags accordingly.
29564         (keydb_get_keyblock): Transfer PK_NO and UID_NO to parse_keyblock_image.
29565         * kbx/keybox-search.c (blob_cmp_fpr, blob_cmp_fpr_part)
29566         (blob_cmp_name, blob_cmp_mail): Return the key/user number.
29567         (keybox_search): Set the key and user number into the found struct.
29568         (keybox_get_keyblock): Add args R_PK_NO and R_UID_NO and set them from
29569         the found struct.
29570
29571         New function log_clock.
29572         + commit 0baedfd25a4bdc6c8e7aefbd67006b063e2dc33f
29573         * common/logging.c (log_clock): New.
29574         * g10/gpg.c (set_debug): Print clock debug flag.
29575         * g10/options.h (DBG_CLOCK_VALUE, DBG_CLOCK): New.
29576
29577         gpg: Allow searching for user ids in a keybox.
29578         + commit fb31462e7e92d4b19256e6fd40b1b6ffcef2676c
29579         * kbx/keybox-search.c (blob_cmp_name): Add arg X509 and adjust for PGP
29580         use.  Change callers.
29581         (blob_cmp_mail): Add arg X509 and find the mailbox offset for PGP.
29582         Chnage callers.
29583         (has_subject_or_alt): Rename to has_username.
29584         (has_username): Allow blobtype PGP.
29585         (has_mail): Ditto.
29586
29587         gpg: Allow generation of more than 4096 keys in one run.
29588         + commit 7d00e52bd58d9e40c18dcc0122b2c236ef3318f5
29589         * g10/getkey.c (cache_public_key): Make room in the cache if needed.
29590
29591 2013-01-07  NIIBE Yutaka  <gniibe@fsij.org>
29592
29593         Update Japanese Translation.
29594         + commit bb51edc31e6595e38fcbd91d470de57d3a1a7150
29595         * po/ja.po: Fix wrong translations for designated revocation.
29596         Reported by Hideki Saito.
29597
29598         Conflicts:
29599                 po/ja.po
29600
29601 2013-01-05  NIIBE Yutaka  <gniibe@fsij.org>
29602
29603         Update Japanese Translation.
29604         + commit 05a4458e5721a0afd600f0ec908e739fa83d58f2
29605         * po/ja.po: Fix fuzzy translations.
29606
29607 2013-01-03  NIIBE Yutaka  <gniibe@fsij.org>
29608
29609         Update Japanese Translation.
29610         + commit 709a8f8125b9ba5e1ad1e6268cca5ac96d478f63
29611         * po/ja.po: Update with POT.
29612
29613         Update Japanese Translation.
29614         + commit 0fae789c4125dd8492ed25bd6728b5ac98f19729
29615         * po/ja.po: Start from the new one of 2.0.
29616
29617 2012-12-28  Werner Koch  <wk@gnupg.org>
29618
29619         gpg: Add signature cache support to the keybox.
29620         + commit 79f08fb0699f4a065e3a29bc7676a90534d7ba60
29621         * g10/keydb.c (parse_keyblock_image): Add arg SIGSTATUS.
29622         (keydb_get_keyblock): Handle it.
29623         (build_keyblock_image): Add arg SIGSTATUS.
29624         (keydb_insert_keyblock): Handle it.
29625         * kbx/keybox-blob.c (pgp_create_sig_part): Add arg SIGSTATUS.
29626         (_keybox_create_openpgp_blob): Ditto.
29627         * kbx/kbxutil.c (import_openpgp): Adjust for above change.
29628         * kbx/keybox.h (KEYBOX_FLAG_SIG_INFO): New.
29629         * kbx/keybox-search.c (_keybox_get_flag_location): Handle new flag.
29630         (keybox_get_keyblock): Add arg R_SIGSTATUS.
29631         * kbx/keybox-update.c (keybox_insert_keyblock): Add arg SIGSTATUS.
29632
29633         kbxutil: Improve format of the Sig-Expire lines.
29634         + commit 564d10ea5cd29685a00a4096d69ae2476b60506f
29635         * kbx/keybox-dump.c (_keybox_dump_blob): Print the expirate timestamp.
29636
29637         gpg: First working support for keyboxes.
29638         + commit a9863834244fc2a58d8950977243702d12e420a1
29639         * g10/getkey.c (get_pubkey_fast): Improve the assertion.
29640         * kbx/keybox.h: Include iobuf.h.
29641         * kbx/keybox-blob.c (keyboxblob_uid): Add field OFF.
29642         (KEYBOX_WITH_OPENPGP): Remove use of this macro.
29643         (pgp_create_key_part_single): New.
29644         (pgp_temp_store_kid): Change to use the keybox-openpgp parser.
29645         (pgp_create_key_part): Ditto.
29646         (pgp_create_uid_part): Ditto.
29647         (pgp_create_sig_part): Ditto.
29648         (pgp_create_blob_keyblock): Ditto.
29649         (_keybox_create_openpgp_blob): Ditto.
29650         * kbx/keybox-search.c (keybox_get_keyblock): New.
29651         * kbx/keybox-update.c (keybox_insert_keyblock): New.
29652         * g10/keydb.c (parse_keyblock_image):
29653         (keydb_get_keyblock): Support keybox.
29654         (build_keyblock_image): New.
29655         (keydb_insert_keyblock): Support keybox.
29656
29657         * kbx/kbxutil.c (import_openpgp, main): Add option --dry-run and print
29658         a kbx file to stdout.
29659
29660         * kbx/keybox-file.c (_keybox_read_blob2): Allow keyblocks up to 10^6
29661         bytes.
29662
29663         kbxutil: Print algo number and fold similar lines.
29664         + commit f7495f1004071a0ceac394007bb37f88d7a3467f
29665         * kbx/keybox-defs.h (_keybox_openpgp_key_info): Add field ALGO.
29666         * kbx/keybox-openpgp.c (parse_key): Store algo.
29667         * kbx/kbxutil.c (dump_openpgp_key): Print algo number.
29668         * kbx/keybox-dump.c (_keybox_dump_blob): Print identical Sig-Expire
29669         value lines with a range of indices.
29670
29671 2012-12-27  Werner Koch  <wk@gnupg.org>
29672
29673         gpg: First patches to support a keybox storage backend.
29674         + commit 91e61d52539b1808e209c43e51465c76cebb06f9
29675         * kbx/keybox-defs.h (_keybox_write_header_blob): Move prototype to ..
29676         * kbx/keybox.h: here.
29677         * kbx/keybox-init.c (keybox_lock): Add dummy function
29678         * g10/keydb.c: Include keybox.h.
29679         (KeydbResourceType): Add KEYDB_RESOURCE_TYPE_KEYBOX.
29680         (struct resource_item): Add field kb.
29681         (maybe_create_keyring_or_box): Add error descriptions to diagnostics.
29682         Add arg IS_BOX.  Write a header for a new keybox file.
29683         (keydb_add_resource): No more need for the force flag.  Rename the
29684         local variable "force" to "create".  Add URL scheme "gnupg-kbx".  Add
29685         magic test to detect a keybox file.  Add basic support for keybox.
29686         (keydb_new, keydb_get_resource_name, keydb_delete_keyblock)
29687         (keydb_locate_writable, keydb_search_reset, keydb_search2): Add
29688         support for keybox.
29689         (lock_all, unlock_all): Ditto.
29690         * g10/Makefile.am (needed_libs): Add libkeybox.a.
29691         (gpg2_LDADD, gpgv2_LDADD): Add KSBA_LIBS as a workaround.
29692
29693         * g10/keydb.h (KEYDB_RESOURCE_FLAG_PRIMARY)
29694         KEYDB_RESOURCE_FLAG_DEFAULT, KEYDB_RESOURCE_FLAG_READONLY): New.
29695         * g10/gpg.c, g10/gpgv.c (main): Use new constants.
29696
29697 2012-12-20  Werner Koch  <wk@gnupg.org>
29698
29699         gpg: Import only packets which are allowed in a keyblock.
29700         + commit f0b33b6fb8e0586e9584a7a409dcc31263776a67
29701         * g10/import.c (valid_keyblock_packet): New.
29702         (read_block): Store only valid packets.
29703
29704 2012-12-19  Werner Koch  <wk@gnupg.org>
29705
29706         gpg: Make commit 2b3cb2ee actually work.
29707         + commit d61f7402f2b0f6dd288e403ed9408fd65e617f85
29708         * g10/sign.c (update_keysig_packet): Use digest_algo.
29709
29710         (cherry-picked from commit d23ec86095714d388acac14b515445fe69f019e9)
29711
29712         gpg: Suppress "public key already present" in quiet mode.
29713         + commit 8325d616593187ff227853de0295e3269b96edcb
29714         * g10/pkclist.c (find_and_check_key, build_pk_list): Print a
29715         diagnostic only in non-quiet mode.
29716
29717 2012-12-18  Werner Koch  <wk@gnupg.org>
29718
29719         common: Add meta option ignore-invalid-option.
29720         + commit 41d564333d35c923f473aa90625d91f8fe18cd0b
29721         * common/argparse.c (iio_item_def_s, IIO_ITEM_DEF): New.
29722         (initialize): Init field IIO_LIST.
29723         (ignore_invalid_option_p): New.
29724         (ignore_invalid_option_add): New.
29725         (ignore_invalid_option_clear): New.
29726         (optfile_parse): Implement meta option.
29727
29728 2012-12-13  Werner Koch  <wk@gnupg.org>
29729             Hans of Guardian  <hans@guardianproject.info>
29730
29731         utf8conv.c: Add hacks for Android.
29732         + commit 6177fb3c87f485fb654bbba492d04508755718b3
29733         * common/utf8conv.c [HAVE_ANDROID_SYSTEM]: Do not include iconv.h.
29734         (iconv_open, iconv_close, load_libiconv) [HAVE_ANDROID_SYSTEM]: New
29735         dummy functions.
29736         (set_native_charset) [HAVE_ANDROID_SYSTEM]: Force use of "utf-8".
29737         (jnlib_iconv_open) [HAVE_ANDROID_SYSTEM]: Act the same as under W32.
29738         (jnlib_iconv) [HAVE_ANDROID_SYSTEM]: Ditto.
29739         (jnlib_iconv_close) [HAVE_ANDROID_SYSTEM]: Ditto.
29740
29741 2012-12-13  NIIBE Yutaka  <gniibe@fsij.org>
29742
29743         SCD: Fix the process of writing key or generating key.
29744         + commit e7dca3e83ebd6df0a7ea55e97c3cd6e91be90af5
29745         * scd/app-openpgp.c (store_fpr): Flush KEY-FPR and KEY-TIME.
29746
29747 2012-12-12  Werner Koch  <wk@gnupg.org>
29748
29749         ssh: Support ECDSA keys.
29750         + commit 649b31c663b8674bc874b4ef283d714a13dc8cfe
29751         * agent/command-ssh.c (SPEC_FLAG_IS_ECDSA): New.
29752         (struct ssh_key_type_spec): Add fields CURVE_NAME and HASH_ALGO.
29753         (ssh_key_types): Add types ecdsa-sha2-nistp{256,384,521}.
29754         (ssh_signature_encoder_t): Add arg spec and adjust all callers.
29755         (ssh_signature_encoder_ecdsa): New.
29756         (sexp_key_construct, sexp_key_extract, ssh_receive_key)
29757         (ssh_convert_key_to_blob): Support ecdsa.
29758         (ssh_identifier_from_curve_name): New.
29759         (ssh_send_key_public): Retrieve and pass the curve_name.
29760         (key_secret_to_public): Ditto.
29761         (data_sign): Add arg SPEC and change callers to pass it.
29762         (ssh_handler_sign_request): Get the hash algo from SPEC.
29763         * common/ssh-utils.c (get_fingerprint): Support ecdsa.
29764
29765         * agent/protect.c (protect_info): Add flag ECC_HACK.
29766         (agent_protect): Allow the use of the "curve" parameter.
29767         * agent/t-protect.c (test_agent_protect): Add a test case for ecdsa.
29768
29769         * agent/command-ssh.c (ssh_key_grip): Print a better error code.
29770
29771 2012-12-11  Werner Koch  <wk@gnupg.org>
29772
29773         ssh: Rewrite a function for better maintainability.
29774         + commit f76a0312c3794afd81fe1e172df15eb0612deae0
29775         * agent/command-ssh.c (ssh_signature_encoder_dsa): Rewrite.
29776
29777 2012-12-10  Werner Koch  <wk@gnupg.org>
29778
29779         ssh: Improve key lookup for many keys.
29780         + commit d2777f84be0ded5906a9bec3bc23cfed0a9be02f
29781         * agent/command-ssh.c: Remove dirent.h.
29782         (control_file_s): Add struct item.
29783         (rewind_control_file): New.
29784         (search_control_file): Factor code out to ...
29785         (read_control_file_item): New.
29786         (ssh_handler_request_identities): Change to iterate over entries in
29787         sshcontrol.
29788
29789         ssh: Cleanup sshcontrol file access code.
29790         + commit 25fb53ab4ae7e1c098500229c776d29b82713a20
29791         * agent/command-ssh.c (SSH_CONTROL_FILE_NAME): New macro to replace
29792         the direct use of the string.
29793         (struct control_file_s, control_file_t): New.
29794         (open_control_file, close_control_file): New.  Use them instead of
29795         using fopen/fclose directly.
29796
29797         agent: Add envvar "gnupg_SSH_AUTH_SOCK_by"
29798         + commit 36ba7845995dd3caf8faeec3e09b3ffb879fc29b
29799         * agent/gpg-agent.c (main): Pass new envar gnupg_SSH_AUTH_SOCK_by to
29800         an invoked process.
29801
29802         config: Update npth.m4.
29803         + commit ceab60b59d907354d323ace09d7b3f2d36d330fb
29804         * m4/npth.m4: Take from current npth master.
29805
29806 2012-12-04  NIIBE Yutaka  <gniibe@fsij.org>
29807
29808         Revert SCD changes of 2010-05-03.
29809         + commit 1e1326aeb8923782138e133f091afec41d969c40
29810         * scd/apdu.c (pcsc_no_service): Remove.
29811         (open_pcsc_reader_direct, open_pcsc_reader_wrapped): Remove
29812         pcsc_no_service support.
29813         (apdu_open_reader): Remove R_NO_SERVICE.
29814         * scd/apdu.h (apdu_open_reader): Remove R_NO_SERVICE.
29815         * scd/command.c (reader_disabled): Remove.
29816         (get_current_reader): Follow the change of R_NO_SERVICE.
29817         (open_card, cmd_serialno, scd_command_handler): Remove reader_disabled
29818         support.
29819         * scd/sc-copykeys.c (main): Follow the change of R_NO_SERVICE.
29820
29821         Don't keep opening unavailable card reader.
29822         + commit baf7b09e124f9eb4ca4b8ee02474ee7710a95a40
29823         * scd/command.c (update_reader_status_file): Don't call
29824         get_current_reader.
29825
29826 2012-11-30  David Shaw  <dshaw@jabberwocky.com>
29827
29828         Refresh sample keys.
29829         + commit b8eb2ab56971a309353ae2682bc6ef1357e9ac53
29830
29831
29832         Adjust awk to not add trailing whitespace.
29833         + commit 3f8ad564674431b4c0c6cff259f02248c80a6ef9
29834         * mksamplekeys: Tweak awk script to not add trailing whitespace to
29835           blank lines (makes git pre-commit hook unhappy)
29836
29837 2012-11-29  David Shaw  <dshaw@jabberwocky.com>
29838
29839         The keyserver search menu should honor --keyid-format.
29840         + commit 7602d9e3edda99b0b65ba928eef435dab04ecd09
29841         * keyserver.c (print_keyrec): Honor --keyid-format when getting back
29842           full fingerprints from the keyserver (the comment in the code was
29843           correct, the code was not).
29844
29845 2012-11-27  Werner Koch  <wk@gnupg.org>
29846
29847         Fix printing of ECC algo names in hkp keyserver listings.
29848         + commit 3d2da6c82163ffbc2e827abc4144dc3197ed53db
29849         * g10/keyserver.c (print_keyrec): Map OpenPGP algorithm ids.
29850
29851 2012-11-26  Ben Kibbey  <bjk@luxsci.net>
29852
29853         Check for inet_addr() in -lnsl.
29854         + commit 66331e138ec17e176cc3f45bb095820866d5358c
29855         * configure.ac: Check for inet_addr() in libnsl.
29856
29857 2012-11-20  Werner Koch  <wk@gnupg.org>
29858
29859         Do not use a broken ttyname.
29860         + commit 835698b72bc509565aad52b0753f1c56c1a8f062
29861         * configure.ac (HAVE_BROKEN_TTYNAME): New ac_define set for Android
29862         systems.
29863         * common/util.h (gnupg_ttyname): New macro.  Change all callers of
29864         ttyname to use this macro instead.
29865         (ttyname) [W32]: Rename to _gnupg_ttyname and use also if
29866         HAVE_BROKEN_TTYNAME is defined.
29867         * common/simple-pwquery.c (agent_send_all_options): Keep on using
29868         ttyname unless HAVE_BROKEN_TTYNAME is set.  This is because this file
29869         may be used standalone.
29870
29871 2012-11-16  Werner Koch  <wk@gnupg.org>
29872
29873         Fix non-portable use of chmod in autogen.sh.
29874         + commit e7bc5012c568da9ceb0a80a8f3fe3edf3dac9564
29875         * autogen.sh: Remove option -c from chmod.
29876
29877         Improve parsing of the GIT revision number.
29878         + commit 011faa0c68cf0c628ef581193166e9ac9bf22b71
29879         * configure.ac (mmm4_revision): Use git rev-parse.
29880
29881         Add an OpenPGP card vendor.
29882         + commit ac775780fef3ef63f896e822add9ff6ea7e5119c
29883         * g10/card-util.c (get_manufacturer): Add Yubico.
29884
29885 2012-11-06  Werner Koch  <wk@gnupg.org>
29886
29887         agent: Use wipememory instead of memset in one place.
29888         + commit 9f0e9ea80ca30269770eb955e33b54401bff917f
29889         * agent/command.c (clear_outbuf): Use wipememory.  Suggested by Ben
29890         Kibbey.
29891
29892         Allow decryption with card keys > 3072 bits.
29893         + commit 905b6a36d3ca21b2f619721e1de892398e5eb759
29894         * scd/command.c (MAXLEN_SETDATA): New.
29895         (cmd_setdata): Add option --append.
29896         * agent/call-scd.c (agent_card_pkdecrypt): Use new option for long
29897         data.
29898
29899         * scd/app-openpgp.c (struct app_local_s): Add field manufacturer.
29900         (app_select_openpgp): Store manufacturer.
29901         (do_decipher): Print a note for broken cards.
29902
29903 2012-11-02  NIIBE Yutaka  <gniibe@fsij.org>
29904
29905         agent: Fix wrong use of gcry_sexp_build_array.
29906         + commit 8f8c29d24ca13f987e6c118702b428a2051b7072
29907         * findkey.c (agent_public_key_from_file): Fix use of
29908         gcry_sexp_build_array.
29909
29910 2012-10-31  NIIBE Yutaka  <gniibe@fsij.org>
29911
29912         SCD: Upon error, open_pcsc_reader_wrapped does same as _direct.
29913         + commit 8df89f3e9cf0255f11011c2f1df0d419a5c23a8c
29914         * scd/apdu.c (PCSC_E_NO_SERVICE): New.
29915         (open_pcsc_reader_direct): Use PCSC_E_NO_SERVICE.
29916         (open_pcsc_reader_wrapped): Set pcsc_no_service.
29917
29918 2012-08-24  Werner Koch  <wk@gnupg.org>
29919
29920         Update and enable French translation.
29921         + commit 76055d49d1c8b8e4f6245e6729cae81b1eaecbf6
29922         * po/fr.po: Update.
29923         * po/LINGUAS: Enable fr.
29924
29925 2012-08-24  David Prévot  <taffit@debian.org>
29926
29927         Fix typos spotted during translations.
29928         + commit ba591e2f14c0d85ba15346ffd04b9e7d72ec89dc
29929         * agent/genkey.c: s/to to/to/
29930         * sm/*.c: s/failed to allocated/failed to allocate/
29931         * sm/certlist.c, ./dirmngr/validate.c: s/should have not/should not have/
29932         * g10/seskey.c: missing closing parenthesis
29933         * dirmngr/crlcache.c: s/may has/may have/
29934
29935         Consistency fix:
29936
29937         * g10/gpg.c, kbx/kbxutil.c, sm/gpgsm.c: uppercase after Syntax
29938         * dirmngr/dirmngr_ldap: no period in Syntax
29939         * dirmngr/dirmngr-client.c: infinitive for option description:
29940                 s/certificates are expected/expect certificates/
29941
29942         Keep previous msgids of translated messages.
29943         + commit bf95408fc33709d154cd41566d33af3ec3c48886
29944         * po/Makefile.in.in: Use --previous with msgmerge.
29945
29946 2012-08-24  Hans-Christoph Steiner  <hans@eds.org>
29947
29948         Fix build system for Android by disabling tests since its x-compiled.
29949         + commit 1da04bfb3f5714a0fa6d0b779d0d2ae4e9544b8f
29950         * configure.ac (HAVE_ANDROID_SYSTEM, RUN_TESTS): New.
29951         (AH_BOTTOM) [__ANDROID__]: Do not re-define ttyname.
29952         * Makefile.am: Depend tests on new RUN_TESTS conditional.
29953
29954 2012-08-24  Werner Koch  <wk@gnupg.org>
29955
29956         Fix left over use of jnlib on some platforms.
29957         + commit 8156a38674421deef6c2eb3e91e0186fe7fe4b26
29958         * tools/watchgnupg.c: Take mischelp.h from common/ and not jnlib/.
29959
29960 2012-06-25  NIIBE Yutaka  <gniibe@fsij.org>
29961
29962         scd: handle reader/token removal.
29963         + commit ca8eec8e28abb8473d02dbaf8d61cfb1094c5c50
29964         * scd/apdu.c (pcsc_error_to_sw): PCSC_E_UNKNOWN_READER means
29965         SW_HOST_NO_READER.
29966
29967 2012-06-05  Werner Koch  <wk@gnupg.org>
29968
29969         Change all quotes in strings and comments to the new GNU standard.
29970         + commit 096e7457ec636bcfcf128678660eb2f2e19f113a
29971         The asymmetric quotes used by GNU in the past (`...') don't render
29972         nicely on modern systems.  We now use two \x27 characters ('...').
29973
29974         The proper solution would be to use the correct Unicode symmetric
29975         quotes here.  However this has the disadvantage that the system
29976         requires Unicode support.  We don't want that today.  If Unicode is
29977         available a generated po file can be used to output proper quotes.  A
29978         simple sed script like the one used for en@quote is sufficient to
29979         change them.
29980
29981         The changes have been done by applying
29982
29983           sed -i "s/\`\([^'\`]*\)'/'\1'/g"
29984
29985         to most files and fixing obvious problems by hand.  The msgid strings in
29986         the po files were fixed with a similar command.
29987
29988 2012-05-24  Werner Koch  <wk@gnupg.org>
29989
29990         Print the hash algorithm in colon mode key listing.
29991         + commit fc00d3fcb201476b3495f47138fa35b71c52f403
29992         * g10/keylist.c (list_keyblock_colon): Print digest_algo.
29993
29994         Fix type conflict warning.
29995         + commit f8a8c71c41bc1893df8af6ce522876ccbf6240a9
29996         * g10/keylist.c: Change min_cert_level to a byte.
29997
29998 2012-05-11  Werner Koch  <wk@gnupg.org>
29999
30000         Switch to the new automagic beta numbering scheme.
30001         + commit 68777b40dcf215305a325185f6bd9cfd6dcc0542
30002         * configure.ac: Add all the require m4 magic.
30003
30004 2012-05-08  Werner Koch  <wk@gnupg.org>
30005
30006         Add tweaks for the not anymore patented IDEA algorithm.
30007         + commit b4d9f8dbc8e074cd91bbd3e2e54e2b77c9268d1a
30008         * g10/keygen.c (keygen_set_std_prefs): Include IDEA only in PGP2
30009         compatibility mode.
30010         * g10/misc.c (idea_cipher_warn): Remove.  Also remove all callers.
30011         * common/status.h (STATUS_RSA_OR_IDEA): Remove.  Do not emit this
30012         status anymore.
30013
30014         po: Update de.po.
30015         + commit 59b77f9ea7dfa4d5c74573d2186c9a3e129ab3bf
30016         * po/de.po: Update.
30017
30018         common: Remove generated files only during maintainer-clean.
30019         + commit d800fa5ce6102e069305f8e1a5d55d18ac3a1993
30020         * common/Makefile.am (CLEANFILES): Rename to MAINTAINERCLEANFILES.
30021
30022 2012-04-30  Werner Koch  <wk@gnupg.org>
30023
30024         agent: Fix deadlock in trustlist due to the switch to npth.
30025         + commit 0f02fba19df16c82ca1ad44a8cb09f952d755598
30026         * agent/trustlist.c (clear_trusttable): New.
30027         (agent_reload_trustlist): Use new function.
30028         (read_trustfiles): Require to be called with lock held.
30029         (agent_istrusted): Factor all code out to ...
30030         (istrusted_internal): new.  Add ALREADY_LOCKED arg.  Make sure the
30031         table islocked.  Do not print TRUSTLISTFLAG stati if called internally.
30032         (agent_marktrusted): Replace calls to agent_reload_trustlist by
30033         explicit code.
30034
30035 2012-04-26  NIIBE Yutaka  <gniibe@fsij.org>
30036
30037         make DNS and URI fields work in gpgsm --gen-key.
30038         + commit 8d7522837c6dba3065d24594bcdbe7b99a702cde
30039         * sm/certreqgen-ui.c (gpgsm_gencertreq_tty): Actually set mb_uri and
30040         mb_dns.avoid buffer strncpy-induced buffer overrun
30041
30042 2012-04-26  Jim Meyering  <jim@meyering.net>
30043
30044         avoid buffer strncpy-induced buffer overrun.
30045         + commit 20c9ac4df34e25f7085bb4e4ab5ea7223932f5c4
30046         * dirmngr/crlcache.c (open_dir): Ensure that both this_update
30047         and next_update member strings are NUL-terminated.
30048
30049         remove doubled words in a comment.
30050         + commit 6e3882785a629b361c57c8b9d5cad51fb234ac23
30051
30052
30053 2012-04-20  Werner Koch  <wk@gnupg.org>
30054
30055         Change license for some files in common to LGPLv3+/GPLv2+.
30056         + commit 37df3d5f593f76ddbf1b9dc6de0173b7bb85c0ad
30057         Having the LGPL on the common GnuPG code helps to share code
30058         between GnuPG and related projects (like GPGME and Libassuan).  This
30059         is good for interoperability and to reduces bugs.
30060
30061         * common/asshelp.c, common/asshelp.h, common/asshelp2.c, common/b64dec.c
30062         * common/b64enc.c, common/convert.c, common/dns-cert.c
30063         * common/dns-cert.h common/exechelp-posix.c, common/exechelp-w32.c
30064         * common/exechelp-w32ce.c, common/exechelp.h, common/get-passphrase.c
30065         * common/get-passphrase.h, common/gettime.c, common/gpgrlhelp.c
30066         * common/helpfile.c, common/homedir.c, common/http.c, common/http.h
30067         * common/i18n.c, common/init.c, common/init.h, common/iobuf.c
30068         * common/iobuf.h, common/localename.c, common/membuf.c, common/membuf.h
30069         * common/miscellaneous.c, common/openpgp-oid.c, common/openpgpdefs.h
30070         * common/percent.c, common/pka.c, common/pka.h, common/session-env.c
30071         * common/session-env.h, common/sexp-parse.h, common/sexputil.c
30072         * common/signal.c, common/srv.c, common/srv.h, common/ssh-utils.c
30073         * common/ssh-utils.h, common/sysutils.c, common/sysutils.h
30074         * common/tlv.c, common/tlv.h, common/ttyio.c, common/ttyio.h
30075         * common/userids.c, common/userids.h, common/xasprintf.c: Change
30076         license to LGPLv3+/GPLv2+/
30077
30078 2012-04-10  Ben Kibbey  <bjk@luxsci.net>
30079
30080         Fix killing PID -1.
30081         + commit bee0ac28c9c8027540ae56900b9f85e0bd555f1d
30082         When the KILLSCD command had been sent a race condition would occur
30083         causing PID -1 getting killed, which on Linux seems to terminate all
30084         applications for the current user.
30085
30086 2012-04-05  Werner Koch  <wk@gnupg.org>
30087
30088         Do not mix test result with progress lines.
30089         + commit f1e1387bee286c7434f0462185048872bcdb4484
30090         This makes parsing of the results easier.  Fixes bug#1400.
30091
30092         * tests/openpgp/defs.inc (progress_cancel, progress_end)
30093         (progress_new): New.
30094         * tests/openpgp/conventional-mdc.test: Use progress functions
30095         * tests/openpgp/conventional.test: Ditto.
30096         * tests/openpgp/encrypt-dsa.test: Ditto.
30097         * tests/openpgp/encrypt.test: Ditto.
30098         * tests/openpgp/sigs.test: Ditto.
30099
30100 2012-04-04  Ben Kibbey  <bjk@luxsci.net>
30101
30102         Mention status messages in the documentation.
30103         + commit 99fc61f1cf09c7f72a9037d91d3cf0cd2e035ae6
30104         Note INQUIRE_MAXLEN.
30105
30106         Document PASSWD --preset.
30107         + commit a577f06c4aecc0af5b492e15812e9150c747cbe4
30108
30109
30110         Document GENKEY options.
30111         + commit 108e8f622ef9cfa256707debec1d379ce3cf21ca
30112
30113
30114         Document PRESET_PASSPHRASE.
30115         + commit 96e107fc29db625b247022ae1bf2cbe90b939c5d
30116
30117
30118         Document CLEAR_PASSPHRASE.
30119         + commit 26b59d78c43d72fa28609fb2c0d80fb377393127
30120         And describe the --mode=normal option.
30121
30122 2012-03-27  Werner Koch  <wk@gnupg.org>
30123
30124         Fix timegm regression test.
30125         + commit 17499e761e8cd0fe867b5b5f3e42a71b6d45f954
30126         * common/t-timestuff.c (test_timegm): Change test to use January and
30127         not February or December+1.  Bug spotted by Daniel Kahn Gillmor.
30128
30129         Print warning for arguments not considered an option.
30130         + commit de01c51ecb3918f427aa76281351749c8ad07ed6
30131         GnuPG requires that options are given before other arguments.  This
30132         can sometimes be confusing.  We now print a warning if we found an
30133         argument looking alike a long option without being preceded by the
30134         stop option.  This is bug#1343.
30135
30136         * common/argparse.h (ARGPARSE_FLAG_STOP_SEEN): New.
30137         * common/argparse.c (arg_parse): Set new flag.
30138         * g10/gpg.c (main): Print the warning.
30139         * agent/gpg-agent.c (main): Ditto.
30140         * dirmngr/dirmngr.c (main): Ditto.
30141         * g13/g13.c (main): Ditto.
30142         * scd/scdaemon.c (main): Ditto.
30143         * sm/gpgsm.c (main): Ditto.
30144         * tools/gpg-connect-agent.c (main): Ditto.
30145         * tools/gpgconf.c (main): Ditto.
30146
30147 2012-03-26  Werner Koch  <wk@gnupg.org>
30148
30149         Allow compress algorithm 0.
30150         + commit 7ddbcb6b6ab8b26c8e609fcd95c2c8a89bc20a7d
30151         * g10/mainproc.c (proc_compressed): Remove superfluous check for
30152         compress algorithm 0.  Reported by pfandrade.  This is bug#1326.
30153
30154         Add mksamplekeys script.
30155         + commit 7441e622ffb3296686bd0d7f04b4051466aaad38
30156         * doc/mksamplekeys: New.
30157
30158 2012-02-28  Marcus Brinkmann  <mb@g10code.com>
30159
30160         Replace npth_yield in busy wait by npth_usleep.
30161         + commit 8f8c6594147608b1021c16fc3561feb96da5d55a
30162         * dirmngr/ldap-wrapper.c (ldap_wrapper_wait_connections): Call
30163         npth_usleep instead of npth_yield.
30164
30165 2012-02-16  Marcus Brinkmann  <mb@g10code.com>
30166
30167         Check for lber and link dirmngr_ldap to it.
30168         + commit 76ff42ef8d1232dd36bf48c1020b0b9b2afb1c7d
30169         * configure.ac (LBER_LIBS, HAVE_LBER): New variables, check for lber.
30170         * dirmngr/Makefile.am (dirmngr_lda_LDADD): Add $(LBER_LIBS).
30171
30172 2012-02-07  Werner Koch  <wk@gnupg.org>
30173
30174         agent: Add pin length field to the shadowed private key format.
30175         + commit b817ae7df947093384a25797999a9aa187e20f9c
30176         This is not yet fully implemented.  It will eventually allow to
30177         support pinpad equipped readers which do not support variable length
30178         pin lengths.
30179         * agent/protect.c (parse_shadow_info): Add optional arg R_PINLEN and
30180         parse pinlen info.  Change all callers to pass NULL for it.
30181
30182         Use new status printing functions.
30183         + commit 12ea5c904c0008a2adec2e8bbe45dac629548e7d
30184         * agent/command.c (cmd_geteventcounter): Get rid of static buffers.
30185         * scd/command.c (cmd_serialno, cmd_learn): Simplify by using
30186         print_assuan_status.
30187
30188         agent: New function agent_print_status.
30189         + commit e78585cd0f553d92f332e33810ab636758bc88a2
30190         * common/asshelp2.c (vprint_assuan_status): New.
30191         (print_assuan_status): Re-implement using above func.
30192         * agent/command.c (agent_print_status): New.
30193
30194         po: Add Ukrainian translation.
30195         + commit 8d8d740bfd73d8764a03220c0b0c949e03fea351
30196         * po/uk.po: New.
30197
30198         common: Replace macro based function calls by using DEFAULT_ERRSOURCE.
30199         + commit 13ec74481ce0137f7a60b3256cc4840073c77efa
30200         * common/dns-cert.h (get_dns_cert): Remove macro.
30201         * common/dns-cert.c (_get_dns_cert): Rename to get_dns_cert.  Replace
30202         arg ERRSOURCE by global DEFAULT_ERRSOURCE.
30203         * common/http.h (http_parse_uri, http_raw_connect, http_open)
30204         (http_open_document, http_wait_response): Remove macros.
30205         * common/http.c (_http_parse_uri, _http_raw_connect, _http_open)
30206         (_http_open_document, _http_wait_response): Remove underscore from
30207         symbols.  Replace args ERRSOURCE by global DEFAULT_ERRSOURCE.
30208         * common/ssh-utils.h (ssh_get_fingerprint)
30209         (ssh_get_fingerprint_string): Remove macros.
30210         * common/ssh-utils.h (_ssh_get_fingerprint)
30211         (_ssh_get_fingerprint_string): Remove underscore from symbols.
30212         Replace args ERRSOURCE by global DEFAULT_ERRSOURCE.
30213         * common/tlv.h (parse_ber_header, parse_sexp): Remove macros.
30214         * common/tlv.c: Include util.h.
30215         (_parse_ber_header, _parse_sexp): Remove underscore from symbols.
30216         Replace args ERRSOURCE by global DEFAULT_ERRSOURCE.
30217
30218 2012-02-06  Werner Koch  <wk@gnupg.org>
30219
30220         Add replacement hack for Android's broken ttyname.
30221         + commit 115a6ed55d1f6be33f66de6734359fa590ca3749
30222         * configure.ac (HAVE_TTYNAME) [__ANDROID__]: Add hack.
30223
30224         agent: Simplify printing of INQUIRE_MAXLEN.
30225         + commit 7981cdd1345d51fd917b2375691ead60c24db2cd
30226         * agent/command.c: Include asshelp.h.
30227         (cmd_pkdecrypt, cmd_genkey, cmd_preset_passphrase)
30228         (pinentry_loopback): Use print_assuan_status for INQUIRE_MAXLEN.
30229
30230         common: Add function print_assuan_status.
30231         + commit 1a0df8506050448f16c63666850e3ae6d94a971b
30232         * common/asshelp2.c: New.
30233         (print_assuan_status): New function.
30234         * common/Makefile.am (common_sources): Add asshelp2.c.
30235
30236         common: Add a global variable to for the default error source.
30237         + commit eb0faef81dae2cba1f62056fdc4dc2a7d58ac86a
30238         For the shared code parts it is cumbersome to pass an error sourse
30239         variable to each function.  Its value is always a constant for a given
30240         binary and thus a global variable makes things a lot easier than the
30241         former macro stuff.
30242         * common/init.c (default_errsource): New global var.
30243         (init_common_subsystems): Rename to _init_common_subsystems.  Set
30244         DEFAULT_ERRSOURCE.
30245         * common/init.h: Assert value of GPG_ERR_SOURCE_DEFAULT.
30246         (init_common_subsystems): New macro.
30247         * common/util.h (default_errsource): Add declaration.
30248         * kbx/keybox-defs.h: Add some GPG_ERR_SOURCE_DEFAULT trickery.
30249
30250 2012-02-03  Ben Kibbey  <bjk@luxsci.net>
30251
30252         Also let GENKEY and PKDECRYPT send the INQUIRE_MAXLEN status message.
30253         + commit ecda65498ac60dfde50fbbc71cd0cc321d7175a9
30254         * agent/command.c (cmd_pkdecrypt): Send the INQUIRE_MAXLEN status
30255         message before doing the inquire.
30256         (cmd_genkey): Ditto.
30257
30258 2012-02-02  Ben Kibbey  <bjk@luxsci.net>
30259
30260         Inform the client of the preset passphrase length.
30261         + commit 3f7788f2e035eb939abb27b3a53854ec0fc6178c
30262         * agent/command.c (cmd_preset_passphrase): Send the INQUIRE_MAXLEN
30263         status message before inquiring the passphrase.
30264
30265 2012-02-01  David Shaw  <dshaw@jabberwocky.com>
30266
30267         Honor --cert-digest-algo when recreating a cert.
30268         + commit 2b3cb2ee94625498e7a7f939216c9bcddef6ec20
30269         * g10/sign.c (update_keysig_packet): Honor --cert-digest-algo when
30270           recreating a cert.
30271
30272         This is used by various things in --edit-key like setpref, primary,
30273         etc.  Suggested by Christian Aistleitner.
30274
30275 2012-01-27  Werner Koch  <wk@gnupg.org>
30276
30277         gl: Add support for Android to stdint.h replacement.
30278         + commit bdde44ae8d4709e33c09781c3d37a5da2c7a5e0d
30279         * gl/stdint_.h: When included from Bionic <sys/types.h>, just include
30280         the system's <stdint.h>.
30281
30282         gpg-connect-tool: Take the string "true" as a true condition.
30283         + commit 2871422d9a889cb632f59efda4d9cd170fc9fca7
30284         * tools/gpg-connect-agent.c (main): Handle strings "true" and "yes" in
30285         conditions as expected.
30286
30287 2012-01-26  Ben Kibbey  <bjk@luxsci.net>
30288
30289         Return GPG_ERR_CARD_NOT_PRESENT when pinentry-mode=loopback.
30290         + commit cf748e8736b984194345bfd74887b35d3d23fa37
30291         Since there isn't a way to prompt the user to insert the smartcard when
30292         pinentry-mode=loopback, return GPG_ERR_CARD_NOT_PRESENT instead of
30293         GPG_ERR_NO_PIN_ENTRY.
30294
30295         * agent/divert-scd.c (ask_for_card): Return GPG_ERR_CARD_NOT_PRESENT
30296         when pinentry-mode=loopback.
30297
30298         Also check for GPG_ERR_ASS_CANCELED during an inquire.
30299         + commit 3da10eefcb09a520f11e4fae7f59a33f80ffba69
30300         Fix pinentry-mode=loopback when cancelling an inquire from scdaemon.
30301         This is similar to commit 4f21f8d but for both protocol command
30302         cancellation and pinentry cancellation.
30303
30304         * agent/call-scd.c (agent_card_pkdecrypt): Check for
30305         GPG_ERR_ASS_CANCELED.
30306         (agent_card_pksign): Ditto.
30307
30308 2012-01-25  Werner Koch  <wk@gnupg.org>
30309
30310         nPth is now a hard requirement for GnuPG.
30311         + commit 001352077cdc7e402421c77328bea1a052005673
30312         * configure.ac: Remove cruft to allow building without npth.
30313
30314         Require libassuan 2.1.0.
30315         + commit c254d0f0d13a54777a62dad8f78a8f287d6ae565
30316         * configure.ac (NEED_LIBASSUAN_VERSION): Set to 2.1.0.  This is due to
30317         the npth changes.
30318
30319         Fix strerror vs. gpg_strerror usage.
30320         + commit 2be7818c6d916a69ffdf88cce32960949a56e893
30321         This bug was introduced by the migration to npth.
30322         * agent/gpg-agent.c (handle_connections): Use strerror.
30323
30324         Add missing variable.
30325         + commit a55d2e16f1090264338dc3ad0b2afca28db27c09
30326         * agent/gpg-agent.c (handle_connections) [!W32]: Add missing variable.
30327
30328 2012-01-25  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
30329
30330         Port LDAP wrapper to NPTH.
30331         + commit 4074f966276be10a794fd63a7f443b9d974d3982
30332         * agent/gpg-agent.c (handle_connections): Handle error.
30333         * dirmngr/dirmngr_ldap.c, dirmngr/ldap-wrapper-ce.c: Port to NPTH.
30334
30335         Port Windows code to NPTH.
30336         + commit ccbb4c3652ee72386b8889358b829e256e1ebcda
30337         * agent/gpg-agent.c (get_agent_ssh_socket_name): Use
30338         INVALID_HANDLE_VALUE instead of 0.
30339         (handle_signal) [!HAVE_W32_SYSTEM]: Don't define.
30340         (handle_connections): Port Windows code to NPTH.
30341         * dirmngr/dirmngr.c (handle_connections): Port Windows code to NPTH.
30342         * g13/g13.c (handle_connections): Port Windows code to NPTH.
30343         * scd/scdaemon.c (handle_connections): Port Windows code to NPTH.
30344
30345         Port to npth.
30346         + commit 7a7a59782766a8bde0c3e7156d14bb2b0e4a3951
30347         * configure.ac: Don't check for PTH but for NPTH.
30348         (AH_BOTTOM): Remove PTH_SYSCALL_SOFT.
30349         (have_pth): Rename to ...
30350         (have_npth): ... this.
30351         (USE_GNU_NPTH): Rename to ...
30352         (USE_GNU_PTH): ... this.
30353         * m4/npth.m4: New file.
30354         * agent/Makefile.am, agent/cache.c, agent/call-pinentry.c,
30355         agent/call-scd.c, agent/findkey.c, agent/gpg-agent.c,
30356         agent/trustlist.c, common/Makefile.am, common/estream.c,
30357         common/exechelp-posix.c, common/exechelp-w32.c,
30358         common/exechelp-w32ce.c, common/http.c, common/init.c,
30359         common/sysutils.c, dirmngr/Makefile.am, dirmngr/crlfetch.c,
30360         dirmngr/dirmngr.c, dirmngr/dirmngr_ldap.c, dirmngr/ldap-wrapper-ce.c,
30361         dirmngr/ldap-wrapper.c, dirmngr/ldap.c, g13/Makefile.am,
30362         g13/call-gpg.c, g13/g13.c, g13/runner.c, scd/Makefile.am,
30363         scd/apdu.c, scd/app.c, scd/ccid-driver.c, scd/command.c,
30364         scd/scdaemon.c, tools/Makefile.am: Port to npth.
30365
30366 2012-01-25  Werner Koch  <wk@gnupg.org>
30367
30368         Require gitlog-to-changelog to be installed.
30369         + commit 495dc68586356891b82a2d2b6367c4131fd17f08
30370         * Makefile.am (GITLOG_TO_CHANGELOG): New.
30371         (gen-ChangeLog): Use installed version of gitlog-to-changelog.
30372
30373 2012-01-20  David Shaw  <dshaw@jabberwocky.com>
30374
30375         Changes to --min-cert-level should cause a trustdb rebuild (issue 1366)
30376         + commit deee8147aab086161c91e6aa6fb41d7148a630f6
30377         * g10/gpgv.c, g10/trustdb.c (read_trust_options): Add min_cert_level
30378
30379         * g10/trustdb.c (check_trustdb_stale): Request a rebuild if
30380           pending_check_trustdb is true (set when we detect a trustdb
30381           parameter has changed).
30382
30383         * g10/keylist.c (public_key_list): Use 'l' in the "tru" with-colons
30384           listing for min_cert_level not matching.
30385
30386         * g10/tdbio.c (tdbio_update_version_record, create_version_record,
30387           tdbio_db_matches_options, tdbio_dump_record, tdbio_read_record,
30388           tdbio_write_record): Add a byte for min_cert_level in the tdbio
30389           version record.
30390
30391 2012-01-20  Werner Koch  <wk@gnupg.org>
30392
30393         estream: Fix unclean usage of realloc.
30394         + commit e97e2ced6cf3ee295a3cc9f8968969a1910380ea
30395         * common/estream-printf.c (_ESTREAM_PRINTF_MALLOC): Remove.
30396         (_ESTREAM_PRINTF_FREE): Remove.
30397         (_ESTREAM_PRINTF_REALLOC): New.
30398         (fixed_realloc) [!_ESTREAM_PRINTF_REALLOC]): New.
30399         (estream_vasprintf): Use my_printf_realloc instead of my_printf_malloc
30400         and my_printf_free.
30401         (dynamic_buffer_out): Use my_printf_realloc instead of realloc.
30402
30403         Do not copy default merge commit log entries into the ChangeLog.
30404         + commit 7589e43b21c8d80c5a57ecb6eb78dfcd0b5dac46
30405         * scripts/gitlog-to-changelog: Skip merge commits.
30406
30407 2012-01-18  Ben Kibbey  <bjk@luxsci.net>
30408
30409         Add the INQUIRE_MAXLEN status message.
30410         + commit ae981dd8f454e2a8bbc6429bed5abc5e87cc83d5
30411         This status message is used to inform the client of the maximum length
30412         of an inquired passphrase and is used in pinentry-mode=loopback.
30413
30414         * agent/command.c (pinentry_loopback): Send the INQUIRE_MAXLEN status
30415         message before doing the inquire.
30416
30417 2012-01-16  Jim Meyering  <meyering@redhat.com>
30418
30419         yat2m: don't dereference pointer to freed memory.
30420         + commit 4402dc3f0a5c5d0f26ed2ae97f9cda9cf4e695fa
30421         * doc/yat2m.c (top_parse_file): Correct macrolist-freeing loop.
30422
30423         gpg-agent: fix lc-messages handling not to change Xauthority setting.
30424         + commit 37801918cb916ae8c641e003f204dcc70cccb29c
30425         * agent/gpg-agent.c (main): Supply omitted "break" statement for
30426         lc-messages option.  Otherwise, control would fall through to the
30427         following oXauthority case and use the same value there.
30428
30429 2012-01-15  Werner Koch  <wk@gnupg.org>
30430
30431         Fix indentation.
30432         + commit 75a402fc25e4ec9659723dd58306aff3415736f4
30433
30434
30435 2012-01-14  Ben Kibbey  <bjk@luxsci.net>
30436
30437         Fix scdaemon pinentry inquire cancelation.
30438         + commit 4f21f8d6e109eae111d2da91f4c946afda4174e4
30439         Similar to commit 29af488 but also fixes PKDECRYPT and PKSIGN.
30440
30441         * agent/call-scd.c (agent_card_pkdecrypt): Check for GPG_ERR_CANCELED
30442         when returning from the PKDECRYPT operation of scdaemon and cancel the
30443         inquire.
30444         (agent_card_pksign): Ditto.
30445         (cancel_inquire): New.
30446
30447 2012-01-11  Werner Koch  <wk@gnupg.org>
30448
30449         gpg: Fix segv with RSA_S keys.
30450         + commit 30ec869b8c63f1edcc58110ed20b83b0e77248f8
30451         * g10/misc.c (pubkey_get_npkey, pubkey_get_nskey)
30452         (pubkey_get_nsig, pubkey_get_nenc): Map all RSA algo ids to
30453         GCRY_PK_RSA.
30454
30455         estream: Avoid printing leading zeroes by %p on 32 bit systems.
30456         + commit b42bc48dfb4b6d4f745eb02d8de4f4dcffdacf48
30457         * common/estream-printf.c (pr_pointer): Synchronize definition of
30458         AULONG with its use.
30459
30460 2012-01-11  David Shaw  <dshaw@jabberwocky.com>
30461
30462         Refresh sample keys.
30463         + commit 860861279bc17dd80eecc9631c4ae5d161a335fd
30464
30465
30466 2012-01-10  David Shaw  <dshaw@jabberwocky.com>
30467
30468         Adapt HKP fix for fingerprint/long keyid retrievals for dirmngr.
30469         + commit 3f59561cee635c6801e0a59d3abff1c064fcbdbe
30470         * dirmngr/ks-engine-hkp.c (ks_hkp_get): Use the longest valid keyid form
30471
30472 2012-01-06  Werner Koch  <wk@gnupg.org>
30473
30474         gpg: Make the double space in the middle of a fingerprint optional.
30475         + commit 957fe728466893bc63f5ccad197d3e245dca4bf3
30476         This change might help to c+p a fingerprint from an HTML page without
30477         being enclosed in a "pre" tag.
30478         * common/userids.c (classify_user_id): Skip a second blank in the
30479         middle of a fingerprint.
30480
30481         gpg: Allow use of a standard space separated fingerprint.
30482         + commit 372fb4fc0661014ccd9275c89e6da2208f87155f
30483         * common/userids.c (classify_user_id): Check for space separated GPG
30484         fingerprint.
30485
30486 2012-01-06  NIIBE Yutaka  <gniibe@fsij.org>
30487
30488         Merge ccid_driver_improvement branch.
30489         + commit 5988c8bfb7eafaca53c8abeb793f189acd3177c6
30490         * scd/apdu.c (ccid_keypad_operation): Rename from ccid_keypad_verify.
30491         (open_ccid_reader): Use ccid_keypad_operation for verify and modify.
30492
30493         * scd/ccid-driver.c (VENDOR_VASCO, VASCO_920): New.
30494         (ccid_transceive_apdu_level): Permit sending packet where
30495         apdulen <= 289.  Support receiving packets in a chain.
30496         (ccid_transceive_secure): Maximum is 15 for VASCO DIGIPASS 920.
30497         Support keypad_modify method such as CHANGE_REFERENCE_DATA: 0x24.
30498
30499 2012-01-03  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
30500
30501         Silence gcc warning.
30502         + commit ed432f030e604f7b2fd4a79c2110d92b9cde7501
30503         * sm/call-dirmngr.c (get_cached_cert): Make sure buflen is initialized.
30504
30505         Revert last change, add comment about link() return values.
30506         + commit ff2095ad7b4be7eaf9468b6ef39fd979527ecc4f
30507         * common/dotlock.c (use_hardlinks_p, dotlock_take_unix): Do not check
30508         return value of link().
30509
30510         Fix compiler warnings.
30511         + commit 0dce26778ef8abd4fc40de689d7ec9b720d26430
30512         * common/dotlock.c (use_hardlinks_p, dotlock_take_unix): Check return
30513         value of link().
30514         * g13/g13.c: Make sure err is initialized.
30515         * scd/scdaemon.c (main) [!USE_GCRY_THREAD_CBS]: Do not define ERR.
30516
30517         Fix last change: Only set gcrypt thread callback for older versions.
30518         + commit 61ccd8d92d9d3b8ba0eca3c2969d7f6f37e16405
30519         * dirmngr/dirmngr.c, g13/g13.c: Rename FIX_GCRY_PTH_INIT to
30520         USE_GCRY_THREAD_CBS.
30521
30522 2012-01-03  Werner Koch  <wk@gnupg.org>
30523
30524         Terminate csh commands with a semicolon also for dirmngr.
30525         + commit 682df45d15661ed3544e2ed34bcb636200cc40f9
30526         * dirmngr/dirmngr.c (main): Terminate csh style output with a semicolon.
30527
30528         Terminate csh commands with a semicolon.
30529         + commit d01d9ff11f46cbd61b7b8c0e04431e4f0c4a8580
30530         Fixes bug#1386.
30531
30532         * agent/gpg-agent.c (main): Terminate csh style output with a semicolon.
30533         * scd/scdaemon.c: Ditto.
30534
30535 2012-01-02  Marcus Brinkmann  <marcus.brinkmann@ruhr-uni-bochum.de>
30536
30537         Only set gcrypt thread callback for older version of gcrypt.
30538         + commit a2d9e48fcca6cfc2dfadef6dbd3579a30314676b
30539         * agent/gpg-agent.c, dirmngr/dirmngr.c, g13/g13.c, scd/scdaemon.c
30540         (USE_GCRY_THREAD_CBS): New macro, defined if
30541         GCRY_THREAD_OPTION_VERSION is 0.
30542         (fixed_gcry_pth_init) [!USE_GCRY_THREAD_CBS]: Don't define.
30543         (main) [!USE_GCRY_THREAD_CBS]: Do not install thread callbacks.
30544
30545 2011-12-28  David Shaw  <dshaw@jabberwocky.com>
30546
30547         Use the longest key ID available when talking to a HKP server.
30548         + commit c6aaf024651c7d55ac9fb77a53c084efb3adc1a9
30549         This is issue 1340.  Now that PKSD is dead, and SKS supports long key
30550         IDs, this is safe to do.  Patch from Daniel Kahn Gillmor
30551         <dkg@fifthhorseman.net>.
30552
30553 2011-12-20  Werner Koch  <wk@gnupg.org>
30554
30555         Post-release version number update.
30556         + commit 97d1c884e62bba94e42bb5b2bb13cd3880334c31
30557
30558
30559         Release 2.1.0beta3.
30560         + commit 604c130a85d4203b9d84137a42673aeaff1c0bd1
30561
30562
30563         Prepare for the beta3 release.
30564         + commit 8e47f1e576f70d4dbe966523057fe3078006ae8b
30565
30566
30567         po: Update the German translation.
30568         + commit 6f02c143440865781b4e3c1753e24e55a0de40e4
30569
30570
30571         Add the STEED Self-Signing Nonthority certificate.
30572         + commit fe2f1826991e8130f727ee15df1a4651f679752f
30573         * doc/com-certs.pem: Install it when creating a keybox.
30574
30575         faq: Add section on US export restrictions.
30576         + commit 779611494dbd187d09b05d2eb10faabd31a70156
30577
30578
30579         Require Libassuan 2.0.3.
30580         + commit 366512abe44d9e71bb2c699c29477afa6ac71cdd
30581         * configure.ac: Require Libassuan 2.0.3.
30582         * agent/call-scd.c (ASSUAN_CONVEY_COMMENTS): Remove macro replacement.
30583         * agent/command.c (cmd_killagent) [ASSUAN_FORCE_CLOSE]: Remove
30584         dependency.
30585         (cmd_killagent) [ASSUAN_FORCE_CLOSE]: Ditto.
30586         * scd/command.c (cmd_killscd) [ASSUAN_FORCE_CLOSE]: Ditto.
30587
30588 2011-12-20  NIIBE Yutaka  <gniibe@fsij.org>
30589
30590         Add error log and debug log for pcsc_keypad_verify and pcsc_keypad_modify.
30591         + commit 07f20f313a0b13e5c93168a8a62ff1cbb94a4514
30592         * scd/apdu.c (pcsc_keypad_verify): Add debug log and error log.
30593         (pcsc_keypad_modify): Likewise.
30594
30595 2011-12-19  Werner Koch  <wk@gnupg.org>
30596             Ben Kibbey  <bjk@luxsci.net>
30597
30598         scd: Fix for card change returning GPG_ERR_CARD_RESET.
30599         + commit f4b7f7146349c388a2f3ce224ff2006606c66232
30600         * scd/apdu.c (apdu_connect): Do not test for zero atrlen.
30601
30602 2011-12-16  NIIBE Yutaka  <gniibe@fsij.org>
30603
30604         Don't kill pinentry by SIGKILL but let it quit by SIGINT.
30605         + commit f6251c0d0af92331388f5e9bcd1750cbadcaca8f
30606         * agent/call-pinentry.c (agent_popup_message_stop): To pinentry, send
30607         SIGINT (was: SIGKILL).
30608
30609 2011-12-15  David Shaw  <dshaw@jabberwocky.com>
30610
30611         Merge fix for issue 1331 from 1.4.
30612         + commit a98260c39f1c0ccdad004784cbc9440376766082
30613         * photoid.c (generate_photo_id): Check for the JPEG magic numbers
30614         instead of JFIF since some programs generate an EXIF header first.
30615
30616 2011-12-15  Werner Koch  <wk@gnupg.org>
30617
30618         scd: Prefer application Geldkarte over DINSIG.
30619         + commit 27089564b6453deaf7b4ffe7cc5f5f290b6d892b
30620         * scd/app.c (select_application): Reorder application tests.
30621
30622         scd: Add option --dump-atr to command APDU.
30623         + commit b22d62bd1481dfe13d60a6d16b09b9297944f063
30624         * scd/atr.c: Rewrite.
30625         * scd/Makefile.am (scdaemon_SOURCES): Add atr.c and atr.h.
30626         * scd/command.c (cmd_apdu): Add option --dump-atr.
30627
30628         estream: New function es_fclose_snatch.
30629         + commit 7737a2c269657189a583cde7f214f20871d264f8
30630         * common/estream.c (cookie_ioctl_function_t): New type.
30631         (es_fclose_snatch): New function.
30632         (COOKIE_IOCTL_SNATCH_BUFFER): New constant.
30633         (struct estream_internal): Add field FUNC_IOCTL.
30634         (es_initialize): Clear FUNC_IOCTL.
30635         (es_func_mem_ioctl): New function.
30636         (es_fopenmem, es_fopenmem_init): Init FUNC_IOCTL.
30637
30638 2011-12-14  Werner Koch  <wk@gnupg.org>
30639
30640         scd: Skip S/N reading for the "undefined" application.
30641         + commit 792e137ec7997a0ff5c54ff970611238d28d4ba8
30642         * scd/app.c (select_application): Skip serial number reading.
30643
30644         scd: Add more status word values for documentation.
30645         + commit 0bac31ee9f74a25d76b08c3e0355a338908f083a
30646
30647
30648         scd: Add the "undefined" stub application.
30649         + commit dcd64131c60efd0189aa05d5dbce6b93547b04e3
30650         * scd/app.c (select_application): Implement the "undefined"
30651         application.
30652
30653         agent: Pass comment lines from scd verbatim thru gpg-agent.
30654         + commit 45cf9de341405a228e331bd3893cbcd6b72306be
30655         * agent/call-scd.c (pass_status_thru): Pass comment lines verbatim.
30656         * tools/gpg-connect-agent.c (help_cmd_p): New.
30657         (main): Treat an "SCD HELP" the same as "HELP".
30658
30659         scd: Fix resetting and closing of the reader.
30660         + commit 2d91febbd8d30beb7eb33f7aa80ffd5691d1d3cc
30661         * scd/command.c (update_card_removed): Do no act on an invalid VRDR.
30662         (do_reset): Ignore apdu_reset error codes for no and inactive card.
30663         Close the reader before setting the slot to -1.
30664         (update_reader_status_file): Notify the application before closing the
30665         reader.
30666
30667         scd: Add debug option for reader function calls.
30668         + commit 07ea8c56b507b06d4bd70e94fa51914659afac4b
30669         * scd/scdaemon.h (DBG_READER_VALUE, DBG_READER): New.
30670         * scd/apdu.c (apdu_open_reader, apdu_close_reader)
30671         (apdu_shutdown_reader, apdu_connect, apdu_disconnect)
30672         (apdu_reset, apdu_get_atr, apdu_get_status): Add debug code.
30673         (apdu_activate): Remove this unused function.
30674
30675 2011-12-13  Werner Koch  <wk@gnupg.org>
30676
30677         scd: New option --debug-assuan-log-cats.
30678         + commit 00c760f628f4cf0fc11e79d305c172f98123f815
30679         * scd/scdaemon.c (oDebugAssuanLogCats): New.
30680         (opts): Add option --debug-assuan-log-cats.
30681         (main): Implement option.
30682         * common/asshelp.c (set_libassuan_log_cats): New.
30683
30684         scd: Introduce a virtual reader table.
30685         + commit 24e121ef261731069868ca403b818f1168237f53
30686         The vreader table makes the code more clear by explicitly talking
30687         about APDU slots and reader indices.  It also accommodates for future
30688         extensions.
30689
30690         * scd/scdaemon.h (server_control_s): Remove READER_SLOT.
30691         * scd/scdaemon.c (scd_init_default_ctrl): Do not init READER_SLOT.
30692         * scd/app.c (check_application_conflict): Add arg SLOT.
30693         * scd/command.c (slot_status_s): Rename to vreader_s.
30694         (server_local_s): Add field VREADER_IDX as replacement for
30695         the READER_SLOT in server_control_s.  Change all users.
30696         (slot_table): Rename to vreader_table.  Change all users.
30697         (vreader_slot): New.
30698         (do_reset, cmd_apdu): Map vreader to apdu slot.
30699         (get_reader_slot): Rename to get_current_reader.  Return -1 on error.
30700         (open_card): Map vreader toapdu slot.  Pass slot to
30701         check_application_conflict.
30702         (scd_command_handler): Init VREADER_IDX.
30703         (update_reader_status_file): Reset SLOT field on error.
30704
30705 2011-12-12  Werner Koch  <wk@gnupg.org>
30706
30707         scd: Retry command SERIALNO for an inactive card.
30708         + commit 11164662788036c4b15d30555ea33ec0b6f5a670
30709         * scd/command.c (cmd_serialno): Retry once for an inactive card.
30710
30711         Fix detection of card removal and insertion.
30712         + commit cd29dc0f1cf7f3bd7938ffa65bf13f9a75d8c156
30713         * scd/apdu.c (apdu_connect): Return status codes for no card available
30714         and inactive card.
30715         * scd/command.c (TEST_CARD_REMOVAL): Also test for GPG_ERR_CARD_RESET.
30716         (open_card): Map apdu_connect status to GPG_ERR_CARD_RESET.
30717
30718         gitlog-to-changelog: New option --tear-off.
30719         + commit ea0a21410b8fa460882c0f8de90b9291345fd4fc
30720         * scripts/gitlog-to-changelog: Add option --tear-off.
30721         * Makefile.am (gen-ChangeLog): Use that option.
30722
30723 2011-12-07  Werner Koch  <wk@gnupg.org>
30724
30725         gpgsm: Add new validation model "steed".
30726         + commit 8a12a2000d82acfa881e8c18d028290100bf5e43
30727         * sm/gpgsm.h (VALIDATE_FLAG_STEED): New.
30728         * sm/gpgsm.c (gpgsm_parse_validation_model): Add model "steed".
30729         * sm/server.c (option_handler): Allow validation model "steed".
30730         * sm/certlist.c (gpgsm_cert_has_well_known_private_key): New.
30731         * sm/certchain.c (do_validate_chain): Handle the
30732         well-known-private-key attribute.  Support the "steed" model.
30733         (gpgsm_validate_chain): Ditto.
30734         * sm/verify.c (gpgsm_verify): Return "steed" in the trust status line.
30735         * sm/keylist.c (list_cert_colon): Print the new 'w' flag.
30736
30737         Correct punctuation in the ChangeLog summary line.
30738         + commit 14e4fdc9f97d6f12bf563adfff1e3157305d7795
30739         * Makefile.am (gen-ChangeLog): Supply --append-dot.
30740
30741         Allow comments which will not show up in the ChangeLog.
30742         + commit cd3732841de32ce5c7841e6e158df3a5f1102f86
30743         * scripts/gitlog-to-changelog: Ignore lines after a "--" line.
30744
30745 2011-12-06  Werner Koch  <wk@gnupg.org>
30746
30747         gpgsm: Allow specification of an AuthorityKeyIdentifier.
30748         + commit 596b84a4de58def2155d3fe56462f6607f135b69
30749         * sm/certreqgen.c (pAUTHKEYID): New.
30750         (read_parameters): Add keyword Authority-Key-Id.
30751         (proc_parameters): Check its value.
30752         (create_request): Insert an Authority-Key-Id.
30753
30754         gpgsm: Allow arbitrary extensions for cert creation.
30755         + commit 5cdad8ff000152b4bd01953646bb87fe8703c70d
30756         * sm/certreqgen.c (pSUBJKEYID, pEXTENSION): New.
30757         (read_parameters): Add new keywords.
30758         (proc_parameters): Check values of new keywords.
30759         (create_request): Add SubjectKeyId and extensions.
30760         (parse_parameter_usage): Support "cert" and the encrypt alias "encr".
30761
30762         gpgsm: Fix storing of the serial number.
30763         + commit 3f284e40502d8181b0b3ea66c77cd7c1252ea781
30764         * sm/certreqgen.c (create_request): Fix hex-bin conversion.
30765
30766 2011-12-05  Werner Koch  <wk@gnupg.org>
30767
30768         Fix last change.
30769         + commit 9274d4d18281b3364fa8abaa821dddf124b105d7
30770         * agent/command.c (start_command_handler): Remove use of removed var.
30771
30772         Amend the agent code with more comments.
30773         + commit 477360e8cdc458b0a36e9c7fb52a35f27766255d
30774         * agent/command.c (server_local_s): Remove unused field MESSAGE_FD.
30775
30776 2011-12-02  Werner Koch  <wk@gnupg.org>
30777
30778         Support the Cherry ST-2000 card reader.
30779         + commit 239659d3a0b8c0c378734ca3d1e9210a02e24da7
30780         * scd/ccid-driver.c (SCM_SCR331, SCM_SCR331DI, SCM_SCR335)
30781         (SCM_SCR3320, SCM_SPR532, CHERRY_ST2000): New constants.
30782         (parse_ccid_descriptor): Use them.
30783         (scan_or_find_usb_device, ccid_transceive_secure): Handle Cherry
30784         ST-2000.  Suggested by Matthias-Christian Ott.
30785
30786         Avoid possible double free in export.c.
30787         + commit 96dc146fa17a7853277dbf3dc771c585a815c247
30788         * g10/export.c (transfer_format_to_openpgp): Avoid possible double
30789           free of LIST.  Reported by NIIBE Yutaka.
30790
30791 2011-12-02  NIIBE Yutaka  <gniibe@fsij.org>
30792
30793         Fix pinpad input support for passphrase modification.
30794         + commit bf37c32367ba149559385ee90b6435cef8bd6412
30795         * apdu.c (pcsc_keypad_verify): Have dummy Lc field with value 0.
30796         (pcsc_keypad_modify): Likewise.
30797         (pcsc_keypad_modify): It's only for ISO7816_CHANGE_REFERENCE_DATA.
30798         bConfirmPIN value is determined by the parameter p0.
30799
30800         * app-openpgp.c (do_change_pin): The flag use_keypad should be 0 when
30801         reset_mode is on, or resetcode is on.  use_keypad only makes sense for
30802         iso7816_change_reference_data_kp.
30803
30804         * iso7816.h (iso7816_put_data_kp): Remove.
30805         (iso7816_reset_retry_counter_kp): Remove.
30806         (iso7816_reset_retry_counter_with_rc_kp): Remove.
30807         (iso7816_change_reference_data_kp): Add an argument: IS_EXCHANGE.
30808
30809         * iso7816.c (iso7816_put_data_kp): Remove.
30810         (iso7816_reset_retry_counter_kp): Remove.
30811         (iso7816_reset_retry_counter_with_rc_kp): Remove.
30812         (iso7816_change_reference_data_kp): Add an argument: IS_EXCHANGE.
30813
30814 2011-12-01  Werner Koch  <wk@gnupg.org>
30815
30816         Add hook to check the commit log syntax.
30817         + commit 29e96e6b9a8e68e6554dd48bc2ce68ae9525d29f
30818         * autogen.sh: Install commit-msg hook for git.
30819
30820         Generate the ChangeLog from commit logs.
30821         + commit 2336b09779d313c1594acf6df3bd8a8486e90458
30822         * scripts/gitlog-to-changelog: New script.  Taken from gnulib.
30823         * scripts/git-log-fix: New file.
30824         * scripts/git-log-footer: New file.
30825         * doc/HACKING: Describe the ChangeLog policy
30826         * ChangeLog: New file.
30827         * Makefile.am (EXTRA_DIST): Add new files.
30828         (gen-ChangeLog): New.
30829         (dist-hook): Run gen-ChangeLog.
30830
30831         Rename all ChangeLog files to ChangeLog-2011.
30832
30833 2011-12-01  Werner Koch  <wk@gnupg.org>
30834
30835         NB: Changes done before December 1st, 2011 are described in
30836         per directory files named ChangeLog-2011.  See doc/HACKING for
30837         details.
30838
30839         -----
30840         Copyright (C) 2011 Free Software Foundation, Inc.
30841
30842         Copying and distribution of this file and/or the original GIT
30843         commit log messages, with or without modification, are
30844         permitted provided the copyright notice and this notice are
30845         preserved.