* doc/yat2m.c (ATTR_PRINTF, ATTR_NR_PRINTF, ATTR_MALLOC): New.
(die, err, inf, xmalloc, xcalloc): New prototypes with attributes.
(get_section_buffer): Take care of !N_SECTIONS.
(proc_texi_cmd): Cast precision format arg.
(proc_texi_buffer): Do not set IN_CMD when not used afterwards.
--
Signed-off-by: Werner Koch <wk@gnupg.org>
* g10/import.c (parse_import_options): Add option "import-export".
(write_keyblock_to_output): New.
(import_one): Implement option.
--
We are now in the import export business.
Signed-off-by: Werner Koch <wk@gnupg.org>
* g10/keylist.c (struct keylist_context): Add field NO_VALIDITY.
(list_keyblock_print): Take care of it.
(list_keyblock_direct): Add arg NO_VALIDITY.
* g10/keygen.c (do_generate_keypair): Merge keyblock and print w/o
validity.
--
It will always be ultimate and by not printing it we avoid a lot of
garbage output due to the trustdb re-calculation.
Signed-off-by: Werner Koch <wk@gnupg.org>
The keys in the tofu test are set to expire on 2016-09-17. Fake the
system time for this test.
This commit includes changes to the old test as well, for those who
need to backport it.
* tests/openpgp/gpg-agent.conf.tmpl: Drop trailing newlines.
* tests/openpgp/tofu.scm: Fake system time.
* tests/openpgp/tofu.test: Likewise.
GnuPG-bug-id: 2393
Signed-off-by: Justus Winter <justus@g10code.com>
* tests/gpgscm/scheme.c (enum scheme_types): Add types for boolean,
nil, eof, and the sink object.
(type_to_string): Handle new types.
(scheme_init_custom_alloc): Give special objects a type.
Signed-off-by: Justus Winter <justus@g10code.com>
This potentially causes a crash if the garbage collector marks an eof
object.
* tests/gpgscm/scheme.c (scheme_init_custom_alloc): Initialize
'EOF_OBJ'.
Signed-off-by: Justus Winter <justus@g10code.com>
* common/name-value.c (struct name_value_container): Add field
'private_key_mode'.
(my_error): New. Use instead of gpg_error.
(nvc_new_private_key): New.
(nve_release): Add arg 'private_key_mode'.
(nvc_release): Call nve_release with private_key_mode flag.
(nvc_delete): Ditto.
(_nvc_add): Do no special case "Key:" in non-private_key_mode.
(nvc_get_private_key): Return error in non-private_key_mode.
(nvc_set_private_key): Ditto.
(nvc_parse): Factor all code out to ...
(do_nvc_parse): new. Add arg 'for_private_key'.
(nvc_parse_private_key): New.
* agent/findkey.c (write_extended_private_key): Replace nvc_parse by
nvc_parse_private_key.
(read_key_file): Ditto.
* common/t-name-value.c (private_key_mode): New variable.
(my_nvc_new): New. Replace all callers.
(test_key_extraction): Take mode in account.
(run_tests): Ditto.
(run_modification_tests): Ditto.
(parse): Ditto.
(main): Add option --parse and rename --parse to --parse-key.
--
Signed-off-by: Werner Koch <wk@gnupg.org>
* common/name-value.c, common/name-value.h: Rename symbol prefixes
from "pkc_" to "nvc_" and from "pke_" to "nve_". Change all callers.
Signed-off-by: Werner Koch <wk@gnupg.org>
* common/private-keys.c: Rename to name-value.c.
* common/private-keys.h: Rename to name-value.h. Chage all users.
* common/t-private-keys.c: Rename to t-name-value.c.
* common/Makefile.am: Adjust accordingly.
--
The module is cool enough to be used for other purposes as well. Thus
we better change the name.
Signed-off-by: Werner Koch <wk@gnupg.org>
* tests/gpgscm/lib.scm (echo): Move...
* tests/gpgscm/tests.scm (echo): ... here.
(info, error, skip): And use echo here.
(file-exists?): New function.
(tr:spawn): Check that source exists and if the sink has been created.
(tr:call-with-content): Hand in optional arguments.
Signed-off-by: Justus Winter <justus@g10code.com>
* tests/gpgscm/ffi-private.h: Handle character arguments.
* tests/gpgscm/ffi.c (do_string_index): New function.
(do_string_rindex): Likewise.
(do_string_contains): Likewise.
(ffi_init): Define new functions.
* tests/gpgscm/ffi.scm (ffi-define): New macro.
* tests/gpgscm/lib.scm (string-index): Use native function,
demonstrate behavior.
(string-rindex): Likewise.
(string-contains?): Likewise.
Demonstrate behavior of various other functions.
(read-all): Rework so that it can handle large files.
Signed-off-by: Justus Winter <justus@g10code.com>
* tests/gpgscm/scheme.c (type_to_string): New function.
(Eval_Cycle): Include actual type in error message.
Signed-off-by: Justus Winter <justus@g10code.com>
* doc/Makefile.am (dist_pkgdata_DATA): Move qualified.txt and
com-certs.pem to ...
(EXTRA_DIST): here.
--
With Let's Encrypt there is no more need to push CA Cert.
Signed-off-by: Werner Koch <wk@gnupg.org>
* common/openpgpdefs.h (SIGSUBPKT_ISSUER_FPR): New.
* g10/build-packet.c (build_sig_subpkt_from_sig): Add arg PKSK and
insert the issuer fpr if needed.
* g10/sign.c (write_signature_packets): Pass signing key.
(make_keysig_packet): Ditto.
(update_keysig_packet): Ditto.
* g10/parse-packet.c (dump_sig_subpkt): Print issuer fpr.
(parse_one_sig_subpkt): Detect issuer fpr.
(can_handle_critical): Add issuer fpr.
* g10/mainproc.c (check_sig_and_print): Try to get key via fingerprint.
* g10/gpgv.c (keyserver_import_fprint): New stub.
* g10/test-stubs.c (keyserver_import_fprint): New stub.
--
This support is enabled with the --rfc4880bis option and intended to
test to recently proposed issuer fpr.
Signed-off-by: Werner Koch <wk@gnupg.org>
* g10/options.h (struct opt): Add field flags.rfc4880bis.
* g10/gpg.c (oRFC4880bis): new.
(opts): add --rfc4880bis.
(main): Implement that and print a warning.
--
This is option enables experimental features which may be dropped or
changed with the next release.
Signed-off-by: Werner Koch <wk@gnupg.org>
* (parse_ccid_descriptor): nonnull_nad = 0 for all GEMPC device.
--
We can't use the driver for 08E6:3438, while it works well under PC/SC
service. I found that the library of ccid always uses the node
address = ZERO for all transactions. So, we extend the same handling
for not only GEMPC_CT30, but also for all its devices.
Debian-bug-id: 814584
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
* Makefile.am (tests): Remove test code which would led to doubling
calls to for e.g. "make distclean".
* tests/Makefile.am: Typo fixes.
* tests/gpgscm/Makefile.am (EXTRA_DIST): Fix name of License file.
Add repl.scm.
(check): Replace by check-local because check is a standard automake
target.
* tests/openpgp/Makefile.am (TESTS_ENVIRONMENT): Replace gmake0sim by
automake generated macro.
(EXTRA_DIST): Add defs.scm
Signed-off-by: Werner Koch <wk@gnupg.org>
* tests/gpgscm/scheme.c (mk_integer): Rename arg NUM to N.
(fill_vector): Ditto.
(mark): Rename var NUM to N.
(set_slot_in_env): Mark SC as unused.
(is_any): Mark P as unused.
--
Signed-off-by: Werner Koch <wk@gnupg.org>
* tests/gpgscm/COPYING: Rename to ...
* tests/gpgscm/LICENSE.TinySCHEME: this.
* AUTHORS: Add a note about TinySCHEME.
* build-aux/speedo/w32/pkg-copyright.txt: Add TinySCHEME notice.
--
I renamed the file with the license terms to avoid confusion with the
standard name for the GPL.
Signed-off-by: Werner Koch <wk@gnupg.org>
* tests/gpgscm/scheme.c (vtbl): Add 'port_from_file' to the vtable.
* tests/gpgscm/scheme.h (struct scheme_interface): New field
'mk_port_from_file'.
Signed-off-by: Justus Winter <justus@g10code.com>
* tests/gpgscm/scheme.c (opexe_0): Include the value that we tried to
evaluate as function-like in the error message.
Signed-off-by: Justus Winter <justus@g10code.com>
* scd/scdaemon.c (opts): Add --homedir.
--
Without that entry the homedir setting won't work.
GnuPG-bug-id: 2386
Signed-off-by: Werner Koch <wk@gnupg.org>
--
As long as a current swdb.lst is available and all directories below
~/b carry the appropriate tarballs this target can be used to build a
w32-installer w/0 any network access.