<feed xmlns='http://www.w3.org/2005/Atom'>
<title>gpgme/src/engine-gpg.c, branch gpgme-1.23.1</title>
<subtitle>GnuPG Made Easy.</subtitle>
<id>http://git.bktus.com/gpgfrontend/gpgme/atom?h=gpgme-1.23.1</id>
<link rel='self' href='http://git.bktus.com/gpgfrontend/gpgme/atom?h=gpgme-1.23.1'/>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/'/>
<updated>2023-09-04T15:03:52Z</updated>
<entry>
<title>New mode to list a v5 fingerprint for v4 packets.</title>
<updated>2023-09-04T15:03:52Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2023-09-04T15:03:01Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=e36b2d1bce4bb6281e18f53d06d7831e6d6f5a09'/>
<id>urn:sha1:e36b2d1bce4bb6281e18f53d06d7831e6d6f5a09</id>
<content type='text'>
* src/gpgme.h.in (GPGME_KEYLIST_MODE_WITH_V5FPR): New.
(struct _gpgme_subkey): Add field v5fpr.
* src/engine-gpg.c (gpg_keylist_build_options): Pass new option to
gpg.
* src/key.c (gpgme_key_unref): Free new field.
* src/keylist.c (op_data_t): Parse and add "fp2" line.

* tests/run-keylist.c (show_usage): Add option --v5fpr.

* src/keylist.c (op_data_t): Add field failure_code.
(keylist_status_handler): Handle special value.
(gpgme_op_keylist_end): Return an error if a FAILURE line has been
seen.
--

Note that the failure code part has been added to better diagnose
problems if a wrong gpg version is used.  If verything works right we
should not get this because we check that the gnupg version sis either
&gt;= 2.4.4 or less than 2.3 and &gt;= 2.2.42.

Note further that the v5fpr field may also be used to get the SHA-256
fingerprint of X.509 certificates (even without passing the new mode
flag).

GnuPG-bug-id: 6705
</content>
</entry>
<entry>
<title>core: Use offline mode for all operations of gpgsm engine</title>
<updated>2023-08-14T10:24:00Z</updated>
<author>
<name>Ingo Klöcker</name>
<email>dev@ingo-kloecker.de</email>
</author>
<published>2023-08-14T10:23:07Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=bc98f01c8599f612dd1035b08f827b0657d94984'/>
<id>urn:sha1:bc98f01c8599f612dd1035b08f827b0657d94984</id>
<content type='text'>
* src/engine-backend.h (keylist, keylist_ext): Remove engine_flags.
* src/engine-gpg.c (gpg_keylist, gpg_keylist_ext): Ditto.
* src/engine.c, src/engine.h (_gpgme_engine_op_keylist): Ditto.
(_gpgme_engine_op_keylist_ext): Ditto.
* src/engine.h (GPGME_ENGINE_FLAG_OFFLINE): Remove.
* src/engine-gpgsm.c (struct engine_gpgsm): New field flags with offline
flag.
(have_gpgsm_version): New.
(gpg_set_engine_flags): Set the offline flag.
(start): Send OPTION "offline".
(gpgsm_keylist, gpgsm_keylist_ext): Remove engine_flags.  Remove
sending of OPTION "offline".
* src/keylist.c (gpgme_op_keylist_start, gpgme_op_keylist_ext_start):
Remove setting of offline flag.
--

GnuPG-bug-id: 6648
</content>
</entry>
<entry>
<title>core: Prevent wrong plaintext when verifying clearsigned signature</title>
<updated>2023-07-28T14:15:12Z</updated>
<author>
<name>Ingo Klöcker</name>
<email>dev@ingo-kloecker.de</email>
</author>
<published>2023-07-28T14:15:12Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=a9b28c79e92f6194ea52c7d33213f2a0dc9bd013'/>
<id>urn:sha1:a9b28c79e92f6194ea52c7d33213f2a0dc9bd013</id>
<content type='text'>
* src/engine-gpg.c (gpg_verify): Use a separate pipe instead of stdout
for reading the plaintext.

* tests/gpg/t-support.h (PGM): Define if undefined.
(print_data): Undefine BUF_SIZE.
(check_data): New.
* tests/gpg/t-verify.c (clearsigned_plus_key_block): New.
(main): Add test.
--

Reading the plaintext from stdout is a bad idea because gpg can also
print other stuff on stdout, e.g. the keys contained in a public key
block. This is fixed by reading the plaintext via a special pipe.

GnuPG-bug-id: 6622
</content>
</entry>
<entry>
<title>core: Support reading the archive to decrypt/verify directly from a file</title>
<updated>2023-06-21T12:38:50Z</updated>
<author>
<name>Ingo Klöcker</name>
<email>dev@ingo-kloecker.de</email>
</author>
<published>2023-06-21T12:20:52Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=1a9f192ab450288aea7a889527e78afd2c067b59'/>
<id>urn:sha1:1a9f192ab450288aea7a889527e78afd2c067b59</id>
<content type='text'>
* src/engine-gpg.c (add_file_name_arg_or_data): New.
(gpg_decrypt): Use add_file_name_arg_or_data instead of add_data for the
ciphertext.
(gpg_verify): Use add_file_name_arg_or_data instead of add_data for the
signature and the signed text.

* tests/run-decrypt.c (show_usage): New option --direct-file-io.
(main): Parse new option. If option is given, then don't open input
file, create simple data object instead of data object from stream and
set input file name on input data.
* tests/run-verify.c (show_usage): New option --direct-file-io.
(main): Parse new option. If option is given, then don't open input
files, create simple data objects instead of data objects from stream
and set input file names on input data objects.
--

This change makes it possible to tell gpg (and gpgtar) to read the
input (i.e. the signed/encrypted data or the signature or the created
archive) directly from the files with given file names instead of from
streams piped through GpgME's Data IO.

GnuPG-bug-id: 6530
</content>
</entry>
<entry>
<title>core: Support writing the sign/encrypt output directly to a file</title>
<updated>2023-06-19T16:08:47Z</updated>
<author>
<name>Ingo Klöcker</name>
<email>dev@ingo-kloecker.de</email>
</author>
<published>2023-06-19T14:31:17Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=c38b6200396f703917e4c66aca068f90cfbad325'/>
<id>urn:sha1:c38b6200396f703917e4c66aca068f90cfbad325</id>
<content type='text'>
* src/engine-gpg.c (gpg_encrypt): Pass output file name to gpg if output
has file name set.
(gpg_encrypt_sign): Ditto.
(gpg_sign): Ditto.

* tests/run-encrypt.c (show_usage): New option --output.
(main): Parse new option. Set file name on output if --output is given.
Do not print output if --output is given.
* tests/run-sign.c (show_usage): New option --output.
(main): Parse new option. Set file name on output if --output is given.
Do not print output if --output is given.
--

This change makes it possible to tell gpg (and gpgtar) to write the
output (i.e. the signed/encrypted data or the signature or the created
archive) directly to a file with given file name instead of piping
the output back to gpgme.

GnuPG-bug-id: 6530
</content>
</entry>
<entry>
<title>core: Use 64 bit instead of gpgme_off_t for some internal functions.</title>
<updated>2023-06-15T09:01:46Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2023-06-15T08:58:57Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=eb68948c438814b99b81adf44b674738d0b1be34'/>
<id>urn:sha1:eb68948c438814b99b81adf44b674738d0b1be34</id>
<content type='text'>
* src/conversion.c (_gpgme_string_to_off): Return an u64 value.
* src/data.c (_gpgme_data_get_size_hint): Ditto.
(gpgme_data_set_flag): Use u64 for io-buffer-size due to string_to_off
change.
* src/data.h (struct gpgme_data): Change size_hint to u64.
* src/engine-gpg.c (add_input_size_hint): Replace gpgme_off_t by u64.
--

GnuPG-bug-id: 6534
</content>
</entry>
<entry>
<title>core: For key signing and uid revoking allow an empty user id.</title>
<updated>2023-05-30T09:20:34Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2023-05-30T09:20:34Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=fbc3963d6229853fe9fb1fd599ef39ed0fe2eae6'/>
<id>urn:sha1:fbc3963d6229853fe9fb1fd599ef39ed0fe2eae6</id>
<content type='text'>
* src/engine-gpg.c (gpg_keysign): Required USERID to be non-empty.
--

For some language bindings it is easier if the engine considers an
empty user id to be equivalent to NULL.
</content>
</entry>
<entry>
<title>core: Minor code cleanup.</title>
<updated>2023-03-27T14:56:29Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2023-03-27T14:56:29Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=34cc7daba12a2a6baa3cfa337762656c210686fa'/>
<id>urn:sha1:34cc7daba12a2a6baa3cfa337762656c210686fa</id>
<content type='text'>
* src/engine-gpg.c (build_argv): Remove superfluous tes.
--

gpg_error_from_syserror is guaranteed not to return 0 even if errno is
not set.
</content>
</entry>
<entry>
<title>core: Initialize error variable</title>
<updated>2023-03-27T14:49:24Z</updated>
<author>
<name>Ingo Klöcker</name>
<email>dev@ingo-kloecker.de</email>
</author>
<published>2023-03-27T14:49:03Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=b608c084b9220d8ed288eb916e88a236abac0707'/>
<id>urn:sha1:b608c084b9220d8ed288eb916e88a236abac0707</id>
<content type='text'>
* src/engine-gpg.c (build_argv): Initialize err.
--

Fixes-commit: fbce7deb3b68af900f692591d5d05fa5c1a83f5f
</content>
</entry>
<entry>
<title>core: Make usage of input size hint compatible with gpgtar</title>
<updated>2023-02-02T08:59:01Z</updated>
<author>
<name>Ingo Klöcker</name>
<email>dev@ingo-kloecker.de</email>
</author>
<published>2023-02-02T08:59:01Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=7ad717f6ba00046a26a99d015d701a178ca30630'/>
<id>urn:sha1:7ad717f6ba00046a26a99d015d701a178ca30630</id>
<content type='text'>
* src/engine-gpg.c (add_input_size_hint): Use add_gpg_arg_with_value
to add the --input-size-hint option.
--

GnuPG-bug-id: 6342
</content>
</entry>
</feed>
