<feed xmlns='http://www.w3.org/2005/Atom'>
<title>gpgme/tests, branch gpgme-1.8.0</title>
<subtitle>GnuPG Made Easy.</subtitle>
<id>http://git.bktus.com/gpgfrontend/gpgme/atom?h=gpgme-1.8.0</id>
<link rel='self' href='http://git.bktus.com/gpgfrontend/gpgme/atom?h=gpgme-1.8.0'/>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/'/>
<updated>2016-11-16T12:27:00Z</updated>
<entry>
<title>doc: Replace http: by https: in core source files.</title>
<updated>2016-11-16T12:27:00Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2016-11-16T12:27:00Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=7f5f26fd66e60e60de875c70b1f93f60c0438780'/>
<id>urn:sha1:7f5f26fd66e60e60de875c70b1f93f60c0438780</id>
<content type='text'>
--

Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>core: Do not leak the override session key to ps(1).</title>
<updated>2016-11-16T09:15:31Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2016-11-16T09:12:19Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=9fc92a15bd0a30437a39d0eb28b6f40edc22e6e8'/>
<id>urn:sha1:9fc92a15bd0a30437a39d0eb28b6f40edc22e6e8</id>
<content type='text'>
* src/engine-gpg.c (struct engine_gpg): New field
override_session_key.
(gpg_release): Free that field.
(gpg_decrypt): With gnupg 2.1.16 use --override-session-key-fd.

* tests/run-decrypt.c (main): Fix setting over the override key.
--

Note that this works only with gnupg 2.1.16 and later.

Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>doc,tests: Require use of ctx_flag before use of session_key.</title>
<updated>2016-11-16T09:15:31Z</updated>
<author>
<name>Daniel Kahn Gillmor</name>
<email>dkg@fifthhorseman.net</email>
</author>
<published>2016-11-16T05:10:22Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=573064742145aa5f9bf04baa88af918c0c4d5e12'/>
<id>urn:sha1:573064742145aa5f9bf04baa88af918c0c4d5e12</id>
<content type='text'>
* doc/gpgme.texi: Document requirements of verifying that it is OK to
use session_key.
* tests/run-decrypt.c: Ensure that we fail if we're unable to access
the session key, so that we do not violate the guidance above.

Signed-off-by: Daniel Kahn Gillmor &lt;dkg@fifthhorseman.net&gt;

Changed the description

 -@code{gpgme_set_ctx_flag (ctx, "export-session-key")} returns
 -@code{GPG_ERR_NO_ERROR} or @code{gpgme_get_ctx_flag (ctx,
 -"export-session-key")} returns @code{"1"}.
 +@code{gpgme_set_ctx_flag (ctx, "export-session-key")} returns success
 +or @code{gpgme_get_ctx_flag (ctx, "export-session-key")} returns true
 +(non-empty string).

to get gpgme_get_ctx_flag for boolean values in sync with its own
description.

Note that I don't agree with the above suggestion but it does not
really harm to have it in the man page.

Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>core: Implement context flag "override-session-key".</title>
<updated>2016-11-15T09:34:13Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2016-11-15T09:29:48Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=7659d42468b604db2936b021425683f407eba4a7'/>
<id>urn:sha1:7659d42468b604db2936b021425683f407eba4a7</id>
<content type='text'>
* src/gpgme.c (gpgme_set_ctx_flag): Add flags "export-session-key" and
"override-session-key".
(gpgme_get_ctx_flag): Ditto.
(gpgme_set_export_session_keys): Remove.
(gpgme_get_export_session_keys): Remove.
* src/gpgme.def, src/libgpgme.vers: Remove them.
* src/context.h (struct gpgme_context): Add field
override_session_key.
* src/decrypt-verify.c (decrypt_verify_start): Pass
override_session_key value to the engine.
* src/decrypt.c (decrypt_start): Ditto.
* src/engine.c (_gpgme_engine_op_decrypt): Ditto.
(_gpgme_engine_op_decrypt_verify): Ditto.
* src/engine-backend.h (struct engine_ops): Extend DECRYPT and
DECRYPT_VERIFY_START with override_session_key.
* src/engine-uiserver.c (_uiserver_decrypt): Add stub arg
override_session_key.
(uiserver_decrypt): Ditto.
(uiserver_decrypt_verify): Ditto.
* src/engine-gpgsm.c (gpgsm_decrypt): Ditto.
* src/engine-gpg.c (gpg_decrypt): Add arg override_session_key and set
corresponding gpg option.

* tests/run-decrypt.c (print_result): Print the session key if
available.
(main): Add options --export-session-key and --override-session-key.

--

To keep the number of context manipulation functions at bay, this
patches removes the just added gpgme_set_export_session_keys and
gpgme_get_export_session_keys by flags for the generic context
function.

The patch also implements the --override-session-key feature.

GnuPG-bug-id: 2754
Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>core: Add public function gpgme_get_ctx_flag.</title>
<updated>2016-11-15T08:24:17Z</updated>
<author>
<name>Werner Koch</name>
<email>wk@gnupg.org</email>
</author>
<published>2016-11-15T08:24:17Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=3234b1bf1d6939772677d64f6c1e1820ec98e3cd'/>
<id>urn:sha1:3234b1bf1d6939772677d64f6c1e1820ec98e3cd</id>
<content type='text'>
* src/gpgme.h.in (gpgme_get_ctx_flag): New.
* src/gpgme.c (gpgme_set_ctx_flag): Move down the file and add a trace
statement.
(gpgme_get_ctx_flag): New.
* src/gpgme.def, src/libgpgme.vers: Add new interface.

Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>tests,python: Atomic directory creation</title>
<updated>2016-11-11T08:09:40Z</updated>
<author>
<name>Alon Bar-Lev</name>
<email>alon.barlev@gmail.com</email>
</author>
<published>2016-10-19T09:04:07Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=41d8c7e51a8989be633b9ada124c58a01fae7d54'/>
<id>urn:sha1:41d8c7e51a8989be633b9ada124c58a01fae7d54</id>
<content type='text'>
* lang/python/tests/Makefile.am:  Use MIDIR_P.
* tests/gpg/Makefile.am: Ditto.
* tests/gpgsm/Makefile.am: Ditto.

--
Solves race in parallel build when mkdir fails if directory exists.

Signed-off-by: Alon Bar-Lev &lt;alon.barlev@gmail.com&gt;

- Tweaked the ChangeLog

Signed-off-by: Werner Koch &lt;wk@gnupg.org&gt;
</content>
</entry>
<entry>
<title>tests: Reduce thread count in new thread tests</title>
<updated>2016-11-10T17:35:09Z</updated>
<author>
<name>Andre Heinecke</name>
<email>aheinecke@intevation.de</email>
</author>
<published>2016-11-10T17:32:26Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=ddd0a3cf90ac4b0a27ea610ebd7b9b8016ff43c4'/>
<id>urn:sha1:ddd0a3cf90ac4b0a27ea610ebd7b9b8016ff43c4</id>
<content type='text'>
* gpg/t-thread-keylist-verify.c,
gpg/t-thread-keylist.c: Reduce threads to 100

--
Due to the limit of FD_SETSIZE the
number of parallel threads is limited. So some systems
run into this problem when running the testsuite.
</content>
</entry>
<entry>
<title>tests: Fix additional memleaks in thread tests</title>
<updated>2016-11-10T14:04:17Z</updated>
<author>
<name>Andre Heinecke</name>
<email>aheinecke@intevation.de</email>
</author>
<published>2016-11-10T14:04:17Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=d0030efb45ec8436dd84a9623d2f66b80c6b9e10'/>
<id>urn:sha1:d0030efb45ec8436dd84a9623d2f66b80c6b9e10</id>
<content type='text'>
* tests/gpg/t-thread-keylist-verify.c (start_verify): Release
data.
(start_keylist): Unref keys.
* tests/gpg/t-thread-keylist.c (start_keylist): Unref keys.
</content>
</entry>
<entry>
<title>tests: Improve new thread tests</title>
<updated>2016-11-10T13:14:54Z</updated>
<author>
<name>Andre Heinecke</name>
<email>aheinecke@intevation.de</email>
</author>
<published>2016-11-10T13:10:11Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=4d5174e4a83dcd524f8085f6646145f81b50a02a'/>
<id>urn:sha1:4d5174e4a83dcd524f8085f6646145f81b50a02a</id>
<content type='text'>
* tests/gpg/t-thread-keylist-verify.c (start_keylist): Mark
arg as unused. Release context.
(start_verify): Ditto.
(main): Mark args as unused.
* tests/gpg/t-thread-keylist.c (start_keylist):  Mark
arg as unused. Release context.
(main): Mark args as unused.
</content>
</entry>
<entry>
<title>core: Use gpgrt locking for thread safeness</title>
<updated>2016-11-10T12:33:13Z</updated>
<author>
<name>Andre Heinecke</name>
<email>aheinecke@intevation.de</email>
</author>
<published>2016-11-08T14:32:14Z</published>
<link rel='alternate' type='text/html' href='http://git.bktus.com/gpgfrontend/gpgme/commit/?id=09b64554328445e99a8cc78fc34ea49c2ea2e7f9'/>
<id>urn:sha1:09b64554328445e99a8cc78fc34ea49c2ea2e7f9</id>
<content type='text'>
* configure.ac: Require libgpg-error 1.17. No longer
check for pthread.
* doc/gpgme.texi: Document removed neccessity for thread
safe gpgme flavours.
* src/sema.h (DEFINE_GLOBAL_LOCK),
(DEFINE_STATIC_LOCK, INIT_LOCK, DECLARE_LOCK)
(DESTROY_LOCK, LOCK, UNLOCK): Change to gpgrt equivalents.
* src/posix-sema.c, src/w32-sema.c: Removed.
* src/Makefile.am: Remove libpthread and
Update accordingly.
* src/ath.c, src/ath.h (ath_mutex_init)
(ath_mutex_destroy, ath_mutex_lock, ath_mutex_unlock): Removed.
* src/ath.h (ATH_MUTEX_INITIALIZER): Removed.
* src/version.c (do_subsystem_inits): sema_subsystem_init is
no longer required.
* tests/gpg/Makefile.am: Add new threading tests.
(t_thread1_LDADD, t_cancel_LDADD):
Use just gpgme.
* tests/gpg/t-thread-keylist-verify.c,
tests/gpg/t-thread-keylist.c: New.
* src/gpgme-config.in: Use -lgpgme for thread-model pthread.

--
Using gpgrt locks instead of pthread locks removes
the neccessity to link pthread directly to gpgme and
have a different, thread safe flavor of gpgme. Now
gpgme is thread-safe if the conditions mentioned
in the doc are met.

As the cpp bindings linked against libgpgme
and not libgpgme-pthread this fixes threading problems
with them.

libgpgme-pthread is removed but gpgme-config still supports
--thread=pthread for compatibility with find scripts.
</content>
</entry>
</feed>
