aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* doc: Document the Assuan protocol.Justus Winter2016-08-021-1/+97
| | | | | | | * doc/gpgme.texi: Document the Assuan protocol. GnuPG-bug-id: 2407 Signed-off-by: Justus Winter <[email protected]>
* doc: Fix formatting.Justus Winter2016-08-021-2/+2
| | | | | -- Signed-off-by: Justus Winter <[email protected]>
* python: Fix out-of-tree build.Justus Winter2016-07-281-1/+1
| | | | | | | * lang/python/MANIFEST.in: Add 'private.h'. Fixes-commit: 3d4dc3f0 Signed-off-by: Justus Winter <[email protected]>
* python: Improve error handling.Justus Winter2016-07-281-8/+18
| | | | | | | | * lang/python/pyme/core.py (Context.protocol): Check that the engine is usable before setting the protocol. (Context._errorcheck): Add missing functions. Signed-off-by: Justus Winter <[email protected]>
* src: Fix dummy engine versions.Justus Winter2016-07-283-6/+6
| | | | | | | | | | | | | | | Previously, 'gpgme_engine_check_version' failed for these protocols because the version parser failed to parse the dummy versions. * src/engine-assuan.c (llass_get_version): Use a version triple that the parser can understand. (llass_get_req_version): Likewise. * src/engine-spawn.c (engspawn_get_version): Likewise. (engspawn_get_req_version): Likewise. * src/engine-uiserver.c (uiserver_get_version): Likewise. (uiserver_get_req_version): Likewise. Signed-off-by: Justus Winter <[email protected]>
* python: Drop superfluous imports and trim public interface.Justus Winter2016-07-288-9/+27
| | | | | | | | | | | | | | | * lang/python/pyme/__init__.py: Avoid leaking low-level 'gpgme', make sure the main module looks nice and tidy, appease pyflakes. * lang/python/pyme/errors.py: Appease pyflakes. * lang/python/pyme/util.py: Avoid leaking low-level 'gpgme' into the module namespace. * lang/python/pyme/version.py.in: Likewise. * lang/python/tests/t-keylist.py: Drop superfluous imports. * lang/python/tests/t-sig-notation.py: Likewise. * lang/python/tests/t-sign.py: Likewise. * lang/python/tests/t-signers.py: Likewise. Signed-off-by: Justus Winter <[email protected]>
* python: Rename compiled SWIG module.Justus Winter2016-07-287-115/+115
| | | | | | | | | | | | | | | | | Avoid the name pygpgme, as this is the name of another popular Python binding for GPGME. This commit renames the compiled Python module produced by SWIG. * lang/python/Makefile.am: Rename the compiled Python module. * lang/python/gpgme.i: Likewise. * lang/python/pyme/core.py: Likewise. * lang/python/pyme/errors.py: Likewise. * lang/python/pyme/util.py: Likewise. * lang/python/pyme/version.py.in: Likewise. * lang/python/setup.py.in: Likewise. Signed-off-by: Justus Winter <[email protected]>
* python: Rename exported functions.Justus Winter2016-07-283-28/+28
| | | | | | | | | | | | | | Avoid the name pygpgme, as this is the name of another popular Python binding for GPGME. This commit renames all functions that are exported to the Python world. * lang/python/helpers.c: Rename all exported functions. * lang/python/helpers.h: Likewise. * lang/python/pyme/core.py: Likewise. Signed-off-by: Justus Winter <[email protected]>
* python: Rename private functions.Justus Winter2016-07-284-72/+77
| | | | | | | | | | | | | | | | Avoid the name pygpgme, as this is the name of another popular Python binding for GPGME. This commit renames all functions that are not exported to the Python world. * lang/python/gpgme.i: Rename all private functions. * lang/python/helpers.c: Likewise. * lang/python/helpers.h: Likewise. * lang/python/private.h: Likewise. Also move the SWIG runtime helper prototypes here. Signed-off-by: Justus Winter <[email protected]>
* python: Support the Assuan engine.Justus Winter2016-07-287-1/+302
| | | | | | | | | | | | | | * lang/python/gpgme.i: Add typemaps for the Assuan protocol callbacks. * lang/python/helpers.c (_pyme_assuan_{data,inquire,status}_cb): New functions. * lang/python/private.h (_pyme_assuan_{data,inquire,status}_cb): New prototypes. * lang/python/pyme/core.py (Context.assuan_transact): New method. * lang/python/pyme/util.py (percent_escape): New function. * lang/python/tests/Makefile.am (py_tests): Add new test. * lang/python/tests/t-protocol-assuan.py: New file. Signed-off-by: Justus Winter <[email protected]>
* python: Improve engine information handling.Justus Winter2016-07-283-9/+54
| | | | | | | | | * lang/python/gpgme.i (gpgme_engine_info_t): Wrap engine infos. * lang/python/pyme/core.py (Context.engine_info): New property. (Context.{g,s}et_engine_info): Improve docstrings. * lang/python/pyme/results.py (EngineInfo): New class. Signed-off-by: Justus Winter <[email protected]>
* python: Add accessors for the protocol.Justus Winter2016-07-281-0/+11
| | | | | | | | * lang/python/pyme/core.py (Context.__init__): Add 'protocol' parameter. (Context.protocol): New accessors. Signed-off-by: Justus Winter <[email protected]>
* python: Expose less functions to the Python world.Justus Winter2016-07-285-15/+46
| | | | | | | | | | * lang/python/Makefile.am (EXTRA_DIST, COPY_FILES): Add new file. * lang/python/gpgme.i: Include new file and add comments. * lang/python/helpers.c: Include new file. * lang/python/helpers.h: Move functions we do not need to expose... * lang/python/private.h: ... here. Signed-off-by: Justus Winter <[email protected]>
* Fix including nil bytes in keylist output.Ben Kibbey2016-07-191-6/+6
| | | | | | * src/gpgme-tool.c (cmd_keylist,gt_result): use strlen(). Signed-off-by: Ben Kibbey <[email protected]>
* python: Make GPGME's version easily accessible.Justus Winter2016-07-151-4/+3
| | | | | | * lang/python/pyme/version.py.in (gpgme_versionstr): New variable. Signed-off-by: Justus Winter <[email protected]>
* python: Add an idiomatic interface.Justus Winter2016-07-1520-132/+774
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * configure.ac: Bump required Python version. * lang/python/pyme/__init__.py: Update docstring. Import Context and Data. * lang/python/pyme/core.py (Context.encrypt): New function. (Context.decrypt): Likewise. (Context.sign): Likewise. (Context.verify): Likewise. * lang/python/pyme/errors.py: Add new errors. * lang/python/pyme/util.py (process_constants): Rework and return the inserted keys. * lang/python/tests/Makefile.am (EXTRA_DIST): Add new keys. * lang/python/tests/encrypt-only.asc: New file. * lang/python/tests/sign-only.asc: Likewise. * lang/python/tests/initial.py: Mark key 'Alpha' as trusted, import new keys. * lang/python/tests/support.py: Add fingerprints of known keys. (in_srcdir): New function. (print_data): Handle bytes too. (mark_key_trusted): New function. * lang/python/tests/t-decrypt-verify.py: Adjust test. Test idiomatic interface. * lang/python/tests/t-decrypt.py: Test idiomatic interface. * lang/python/tests/t-encrypt-sign.py: Likewise. * lang/python/tests/t-encrypt-sym.py: Likewise. * lang/python/tests/t-encrypt.py: Likewise. * lang/python/tests/t-idiomatic.py: Simplify. * lang/python/tests/t-keylist.py: Adjust to newly trusted key. * lang/python/tests/t-sign.py: Likewise. Test idiomatic interface. * lang/python/tests/t-signers.py: Likewise. * lang/python/tests/t-verify.py: Likewise. Signed-off-by: Justus Winter <[email protected]>
* Qt: Disable keylocate test for gnupg < 2.0.10Andre Heinecke2016-07-141-0/+4
| | | | * lang/qt/tests/t-keylocate.cpp: Disable test for gnupg < 2.0.10
* Cpp: Add EngineInfo::Version classAndre Heinecke2016-07-142-0/+61
| | | | | | * lang/cpp/src/engineinfo.cpp (EngineInfo::engineVersion): New. * lang/cpp/src/engineinfo.h (EngineInfo::engineVersion): Declare. (EngineInfo::Version): Small helper to work with versions.
* Qt: Fix usage of ignore-invalid-option in testsAndre Heinecke2016-07-141-4/+4
| | | | * Makefile.am (pubring-stamp): Fix config.
* Qt: Fix tests if gpg2 is gpgAndre Heinecke2016-07-141-1/+7
| | | | | * lang/qt/tests/Makefile.am (pubring-stamp): Loopback and provide passphrase on command line when importing.
* python: Fix test.Justus Winter2016-07-141-13/+5
| | | | | | | * lang/python/tests/t-keylist.py: Do not assume key alpha is trusted yet. Signed-off-by: Justus Winter <[email protected]>
* python: Drop bad category.Justus Winter2016-07-141-1/+0
| | | | | -- Signed-off-by: Justus Winter <[email protected]>
* build: Update config.{guess,sub} to {2016-05-15,2016-06-20}.Werner Koch2016-07-132-77/+128
| | | | | | | * build-aux/config.guess: Update. * build-aux/config.sub: Update. Signed-off-by: Werner Koch <[email protected]>
* core: New GPGME_DATA_ENCODING_MIME.Werner Koch2016-07-138-5/+38
| | | | | | | | | | | | | | | | | | | | | | | | * src/gpgme.h.in (GPGME_DATA_ENCODING_MIME): New. * src/data.c (gpgme_data_set_encoding): Adjust check. * src/engine-gpg.c (have_gpg_version): New. (gpg_encrypt, gpg_encrypt_sign): Pass flag '--mimemode'. (gpg_sign): Ditto. * lang/cpp/src/data.h (GpgME): Add MimeEncoding. * lang/cpp/src/data.cpp (encoding, setEncoding): Support MimeEncoding. * src/gpgme-tool.c (server_data_encoding): Add flag --mime. -- This feature allows an application to declare that the encrypted or signed data is a valid MIME part. What is missing is a way to return that information to the application after decryption/verification. This can be done by setting the encoding of the output data object; however this requires some internal additions to our processing model. Signed-off-by: Werner Koch <[email protected]>
* core: Pass the engine's version string to the engine's new function.Werner Koch2016-07-139-9/+42
| | | | | | | | | | | | | | | | | * src/engine-backend.h (engine_ops): Add arg 'version' to NEW. * src/engine-assuan.c (llass_new): Add dummy arg 'version'. * src/engine-g13.c (g13_new): Ditto. * src/engine-gpgconf.c (gpgconf_new): Ditto. * src/engine-gpgsm.c (gpgsm_new): Ditto. * src/engine-spawn.c (engspawn_new): Ditto. * src/engine-uiserver.c (uiserver_new): Ditto. * src/engine.c (_gpgme_engine_new): Pass version string to the new function. * src/engine-gpg.c (struct engine_gpg): Add field 'version'. (gpg_new): Add arg 'version'. (gpg_release): Free VERSION. Signed-off-by: Werner Koch <[email protected]>
* Cpp: Add feature enum for new identifyAndre Heinecke2016-07-132-0/+3
| | | | | | | | | | | * lang/cpp/src/context.cpp (supported_features2): Add BinaryAndFineGrainedIdentify * lang/cpp/src/global.h (Feature2): ditto. -- This is mostly for compatible code with KF5::Gpgmepp where there is no hard requirement against gpgme 1.7. With 1.7 a version check would also suffice.
* python: Port more tests.Justus Winter2016-07-125-6/+335
| | | | | | | | | | | | | * lang/python/pyme/core.py (Context.op_keylist_all): Add missing 'op_keylist_end'. (Context.op_trustlist_all): Fix function. Add missing 'op_trustlist_end'. * lang/python/tests/Makefile.am (pytests): Add new files. * lang/python/tests/t-import.py: New file. * lang/python/tests/t-keylist.py: Likewise. * lang/python/tests/t-trustlist.py: Check alternate interface. Signed-off-by: Justus Winter <[email protected]>
* python: Improve python packaging.Justus Winter2016-07-122-3/+26
| | | | | | | * lang/python/Makefile.am: Sign source releases, and upload them. * lang/python/setup.py.in: Add categories. Signed-off-by: Justus Winter <[email protected]>
* m4: Don't set fpic for qt on windowsAndre Heinecke2016-07-121-2/+4
| | | | | | | | * m4/qt.m4 (FIND_QT): Do not set fpic for windows. -- Otherwise each compile call will result in a warning that fpic is ignored for windows.
* m4: Use LIBS instead of LDFLAGS for Qt libsAndre Heinecke2016-07-121-3/+3
| | | | | | | | * m4/qt.m4: Modify LIBS instead of LDFLAGS for link test. -- The test would otherwise fail when building for windows because the link order was wrong.
* Bump version to 1.7.0Andre Heinecke2016-07-121-2/+2
| | | | | | | | | * configure.ac(mym4_version_minor), (mym4_version_micro): Next release will be 1.7.0 -- This was already mentioned in NEWS but acidentally not changed in configure.ac
* Qt: Install CamelCase forward includesAndre Heinecke2016-07-121-2/+40
| | | | | | | | | | | | * lang/qt/src/Makefile.am (camelcase_headers): New. Create and install CamelCase headers. -- For Qt Libraries it is a common pattern that headers are installed additionally under their Namespace / Class Name so that automated inclusion works once a class is used in code. This was also done for QGpgME headers when they lived in Libkleo so this increases compatibility.
* Qt: Export VerifyDetachedJobAndre Heinecke2016-07-121-1/+1
| | | | * lang/qt/src/verifydetachedjob.h (VerifyDetachedJob): Export it.
* Qt/Cpp: Add version headersAndre Heinecke2016-07-125-2/+71
| | | | | | | | | | | * lang/cpp/src/gpgmepp_version.h.in, lang/qt/src/qgpgme_version.h.in: New. Version information. * lang/qt/src/Makefile.am, lang/cpp/src/Makefile.am: Add them. * configure.ac: Configure them. -- The version headers are common practice in KDE Frameworks and were installed for KF5Gpgmepp and Libkleo respectively.
* Qt/Cpp: Add license blurb to export headersAndre Heinecke2016-07-122-0/+40
| | | | | * lang/cpp/src/gpgmepp_export.h, lang/qt/src/qgpgme_export.h: Add license blurb.
* python: Fix distcheck.Justus Winter2016-07-111-0/+2
| | | | | | * lang/python/Makefile.am (EXTRA_DIST): Add missing files. Signed-off-by: Justus Winter <[email protected]>
* m4: Add compile / link check for qtAndre Heinecke2016-07-111-0/+22
| | | | | | | | | | * m4/qt.m4 (FIND_QT): Check if a qt application can be compiled and linked. -- In case gpgme is cross compiled pkg-config may pick up qt for the build system and not for the host system. To avoid that we check that we can compile a qt program for host.
* python: Enable out-of-tree build of pyme bindings.Justus Winter2016-07-114-29/+99
| | | | | | | | | | | * lang/python/MANIFEST.in: Update manifest template. * lang/python/Makefile.am: Copy more files, move generation of files to Python build script, add 'sdist' target to build a Python source distribution. * lang/python/gpgme-h-clean.py: Add code to build 'errors.i'. * lang/python/setup.py.in: Generate files, enable out-of-tree builds. Signed-off-by: Justus Winter <[email protected]>
* python: Do not depend on access to internal data structures.Justus Winter2016-07-112-45/+76
| | | | | | | | * lang/python/gpgme.i (gpgme_data_t): Rework so that it works without access to the definition of 'struct gpgme_data'. * lang/python/helpers.c (object_to_gpgme_data_t): Add assertion. Signed-off-by: Justus Winter <[email protected]>
* python: Make result wrapping backwards compatible.Justus Winter2016-07-111-5/+4
| | | | | | * lang/python/pyme/results.py (Result.__init__): Skip missing fields. Signed-off-by: Justus Winter <[email protected]>
* Qt: Fix memleaks in testsAndre Heinecke2016-07-113-0/+20
| | | | | | | | | | * lang/qt/tests/t-keylist.cpp(cleanupTestCase): Ensure that posted events are handled for autodeletion. (testSingleKeylistSync): delete job. * lang/qt/tests/t-ownertrust.cpp(cleanupTestCase): Ditto * lang/qt/tests/t-ownertrust.cpp(testChangeOwnerTrust): Delete keylistjobs. * lang/qt/tests/t-keylocate.cpp(cleanupTestCase): Ditto
* Qt: Add some general Protocol documentationAndre Heinecke2016-07-111-0/+35
| | | | | | | * lang/qt/src/protocol.h (Protocol): Add doc. -- This explicitly documents that syncs run with exec need deletion.
* Qt: Disable t-tofuinfo testsAndre Heinecke2016-07-111-5/+1
| | | | | | | | | * lang/qt/tests/t-tofuinfo.cpp: Disable tests. -- Even with the wait this test could fail and anyway the delay was not nice. So we remove the wait hack and just wait for the bug (2405) to be fixed in GnuPG or GpgME core.
* src: Fix error handling.Justus Winter2016-07-081-2/+7
| | | | | | | * src/encrypt.c (encrypt_status_handler): Fix error handling, || conflates errors. Signed-off-by: Justus Winter <[email protected]>
* python: Fix raising stashed exceptions.Justus Winter2016-07-081-1/+7
| | | | | | | | | Fixes an issue with newer versions of Python. * lang/python/helpers.c (pygpgme_raise_callback_exception): Be more careful when restoring the exception. Signed-off-by: Justus Winter <[email protected]>
* python: Fix distcheck.Justus Winter2016-07-075-23/+68
| | | | | | | | | | | | | | * lang/python/INSTALL: Drop obsolete file. * lang/python/Makefile.am (EXTRA_DIST): Add missing files. (CLEANFILES): Remove generated files. (clean-local): Fix permissions of copied files. * lang/python/tests/Makefile.am (TESTS): Use our own setup and teardown scripts. (EXTRA_DIST): Add missing files. * lang/python/tests/final.py: New file. * lang/python/tests/initial.py: Likewise. Signed-off-by: Justus Winter <[email protected]>
* qt: Fix distcheck.Justus Winter2016-07-072-2/+6
| | | | | | | | * lang/qt/src/Makefile.am (qgpgme_headers): Add missing file. (CLEANFILES): Add generated file. * lang/qt/tests/Makefile.am (clean-local): Remove private keys. Signed-off-by: Justus Winter <[email protected]>
* cpp: Fix distcheck.Justus Winter2016-07-071-0/+2
| | | | | | * lang/cpp/src/Makefile.am (CLEANFILES): Remove generated file. Signed-off-by: Justus Winter <[email protected]>
* Qt: Add test for publicKeyAlgorithmAsStringAndre Heinecke2016-07-061-0/+22
| | | | * lang/qt/tests/t-keylist.cpp (testPubkeyAlgoAsString): New.
* Cpp: Expose gpgme_pubkey_algo_nameAndre Heinecke2016-07-062-1/+15
| | | | | | | * lang/cpp/src/key.cpp (Subkey::publicKeyAlgorithmAsString): New static variant. * lang/cpp/src/key.h: Declare function. Clarify comment about name mismatch.