aboutsummaryrefslogtreecommitdiffstats
path: root/tests (unfollow)
Commit message (Collapse)AuthorFilesLines
2016-10-18Release 1.7.1.gpgme-1.7.1Werner Koch2-18/+22
* configure.ac: Set LT version to C27/A16/R0. Note that the LT versions for cpp and Qt have already been updated. Signed-off-by: Werner Koch <[email protected]>
2016-10-14tests: Make t-cancel more portable.Werner Koch1-1/+7
* tests/gpg/t-cancel.c: Include sys/time.h and protect sys/select.h. Signed-off-by: Werner Koch <[email protected]>
2016-10-14python: Call ln(1) in a portable way.Werner Koch1-2/+2
* lang/python/Makefile.am: Specify target dir for ln. Signed-off-by: Werner Koch <[email protected]>
2016-10-14cpp: Fix init of string from nullAndre Heinecke1-3/+6
* lang/cpp/src/key.cpp (UserID::addrSpecFromString): Check return value before creating the string.
2016-10-13python: Make 'get_key' more idiomatic.Justus Winter4-4/+52
* lang/python/pyme/core.py (Context.get_key): Raise errors.KeyNotFound if the key is not found. This error is both a KeyError for idiomatic error handling as well as a GPGMEError so we don't break existing code. * lang/python/pyme/errors.py (KeyNotFound): New class. * lang/python/tests/support.py (no_such_key): New variable. * lang/python/tests/t-keylist.py: Test the new behavior. Signed-off-by: Justus Winter <[email protected]>
2016-10-13python: Return public keys by default.Justus Winter3-7/+18
* lang/python/pyme/core.py (Core.get_key): Return public keys by default, improve docstring. * lang/python/examples/testCMSgetkey.py: Update example. * lang/python/examples/verifydetails.py: Likewise. GnuPG-bug-id: 2751 Signed-off-by: Justus Winter <[email protected]>
2016-10-13python: Fix example.Justus Winter1-2/+2
* lang/python/examples/inter-edit.py: Fix example. Fixes-commit: a458e7fe Signed-off-by: Justus Winter <[email protected]>
2016-10-13cpp: Fix version numberAndre Heinecke1-3/+3
* configure.ac (LIBGPGMEPP_LT_CURRENT): Bump. -- Added API so it should have been correct to bump current and age and not to bump age.
2016-10-13qt, cpp: Fix permissions of Config filesAndre Heinecke2-4/+4
* lang/cpp/src/Makefile.am, lang/qt/src/Makefile.am: Do not install config files as executable.
2016-10-13qt: Install SpecialJobAndre Heinecke2-1/+3
* lang/qt/src/Makefile.am: Install SpecialJob * NEWS: mention it. -- SpecialJob was and is public API. So it needs to be installed.
2016-10-13qt, cpp: Fix expected targets in Config filesAndre Heinecke2-2/+2
* lang/cpp/src/GpgmeppConfig.cmake.in.in, lang/qt/src/QGpgmeConfig.cmake.in.in: Remove KF5 variants.
2016-10-11Mention Qt API fixes in newsAndre Heinecke1-0/+7
--
2016-10-11qt: Add missing implementation of MultiDeleteJobDaniel Vrátil3-2/+120
* lang/qt/src/multideletejob.h: Fix include, cryptobackend.h is now called protocol.h * lang/qt/src/multideletejob.cpp: New file. * lang/qt/src/Makefile.am: Add multideletejob.cpp.
2016-10-11qt: Install abstractimportjob.hDaniel Vrátil1-1/+1
* lang/cpp/src/Makefile.am: Install abstractimportjob.h since it's included from importjob.h -- Fixes build when someone inclues importjob.h in their code.
2016-10-11cpp: Add API for gpgme_addrspec_from_uidAndre Heinecke3-1/+34
* lang/cpp/src/key.cpp (UserID::addrSpecFromString): New static function to expose addrspec from uid. (UserID::addrSpec): New. Get addrSpec from Userid. * NEWS: Update accordingly.
2016-10-10Add NEWS for cpp and qt, bump cpp versionAndre Heinecke2-1/+9
* NEWS: Add entries for cpp and qt changes. * configure.ac: Bump cpp version because of added API.
2016-10-10Add convenience function to get key from sigAndre Heinecke2-0/+53
* lang/cpp/src/verificationresult.cpp (Signature::key(bool, bool)): New. Can be used to search / update the key associcated with this signature. -- By using update a caller can ensure that an incomplete key obtainable through the new key() function is fully loaded. With search the key can be looked up in the internal keyring. As the results are cached this can be done in the crypto thread and the result then better used in the UI thread.
2016-10-10cpp: Return null key if the signature had no keyAndre Heinecke1-0/+2
* lang/cpp/src/verificationresult.cpp (Private): Add null key to list when there is no key associated with the signature. -- This fixes an out of bounds read when a verification did not have a key.
2016-10-10qt: Add simple verify testAndre Heinecke2-3/+97
* lang/qt/tests/t-verify.cpp: New. Small test if a signature returns a key with fingerprint. * lang/qt/tests/Makefile.am: Add new test.
2016-10-10core: Fix w32 crash in find_program_in_dirAndre Heinecke1-1/+1
* src/w32-util.c (find_program_in_dir): Fix call to _gpgme_strconcat. -- This fixes a crash introduced by dc39552d0 because it tried to concat a strlen.
2016-10-08core: New helper function gpgme_addrspec_from_uid.Werner Koch6-1/+50
* src/gpgme.h.in: Add gpgme_addrspec_from_uid. * src/gpgme.def, src/libgpgme.vers: Ditto. * src/mbox-util.c (gpgme_addrspec_from_uid): New. Signed-off-by: Werner Koch <[email protected]>
2016-10-06Add missing includes.Justus Winter2-0/+2
* lang/cpp/src/key.cpp: Include <strings.h> for 'strcasecmp'. * tests/gpg/t-cancel.c: Include <sys/select.h> for 'fd_set' and friends. Signed-off-by: Justus Winter <[email protected]>
2016-10-05cpp: Bump RevisionAndre Heinecke1-1/+1
* configure.ac (LIBGPGMEPP_LT_REVISION): Bump revision. -- The Data::Encoding enum now supports more encodings so this should have been done then.
2016-10-05qt: Fix spelling error in WKSPublishJobAndre Heinecke5-9/+9
* src/qgpgmewkspublishjob.cpp, src/qgpgmewkspublishjob.h, src/wkspublishjob.h, tests/t-wkspublish.cpp: Fix spelling of received. * src/configure.ac (LIBQGPGME_LT_CURRENT): Bump accordingly. -- While this is an API break I've decided to fix this now instead of deprecating / keeping it around forever in the API. The only known users of QGpgME are KDE Applications and there it is not yet used.
2016-10-05qt: Disable tests that require a password for 2.0Andre Heinecke1-0/+26
* lang/qt/tests/t-encrypt.cpp: Disable tests that require a password for 2.0. -- The passphrase_cb apparently does not work with 2.0 so we would need a fake pinentry to get this to work. We just disable the test instead as this is a rarely used feature and works with 1.4 and 2.1.
2016-10-05Add warning flags for c++ compiler, tooAndre Heinecke1-0/+1
* configure.ac (CXXFLAGS): Add Wall and Wextra.
2016-10-05qt: Fix unused variable warningsAndre Heinecke5-13/+14
* qt/src/qgpgmenewcryptoconfig.cpp, qt/src/threadedjobmixin.h, qt/tests/t-encrypt.cpp, qt/tests/t-support.h, qt/tests/t-wkspublish.cpp: Mark additional variables as unused.
2016-10-05cpp: Add support for URL Data encodingsAndre Heinecke2-1/+10
* lang/cpp/src/data.h (Data::Encoding): Extend enum. * lang/cpp/src/data.cpp (Data::encoding), Data::setEncoding): Support new values.
2016-10-05cpp: Fix gcc diagnostic push / popAndre Heinecke1-2/+2
* lang/cpp/src/context.cpp: Fix pragmas. -- This fixes an error with -Werror=unknown-pragmas
2016-10-05qt: Disable t-wkspublish testAndre Heinecke1-1/+1
* lang/qt/tests/Makefile.am (TESTS): Remove t-wkspublish. -- Even the only enabled test did a connection to localhost this might fail if it is stalled and is an outside factor. It also might be disturbing other services locally.
2016-09-30python: Link 'data.h' and 'config.h' into the builddir.Alon Bar-Lev3-10/+11
* lang/python/Makefile.am: Link to the files. * lang/python/gpgme.i: Update path. * lang/python/setup.py.in: Do not add the top builddir to the include path. -- To make it easy to build the subpackage using standard tools without altering environment or CFLAGS, symlink the required artifacts from source tree into subpackage directory when preparing sources. Signed-off-by: Alon Bar-Lev <[email protected]>
2016-09-30python: Add 'prepare' target.Alon Bar-Lev1-0/+3
* lang/python/Makefile.am: Add 'prepare' target. -- This enables preparing the package using autoconf then build using distutils as separate stage. Signed-off-by: Alon Bar-Lev <[email protected]>
2016-09-30python: Make generated 'setup.py' executable.Alon Bar-Lev1-1/+1
-- Signed-off-by: Alon Bar-Lev <[email protected]>
2016-09-29cpp, qt: Handle modified includedir installationAndre Heinecke4-26/+8
* lang/cpp/src/Makefile.am, lang/qt/src/Makefile.am: Replace resolved_includedir. * lang/cpp/src/GpgmeppConfig.cmake.in.in, lang/qt/src/QGpgmeConfig.cmake.in.in: Use resolved_includedir instead of relying on a common installation prefix. -- This fixes usage of the config files in case gpgme is configured with a custom --includedir. We have to do the replacement manually like for libdir because configure would include variables in the replacement.
2016-09-27tests: Fix blunder.Justus Winter2-2/+2
-- Fixes-commit: a423603f Signed-off-by: Justus Winter <[email protected]>
2016-09-27Clarify licensingDaniel Kahn Gillmor3-3/+3
* src/b64dec.c, src/mbox-util.c, src/mbox-util.h: These three files are explicitly licensed under LGPL, but their comments suggest that details about the warranty can be found in the GPL. Adjust comments to refer to the correct license. Signed-off-by: Daniel Kahn Gillmor <[email protected]>
2016-09-27tests: Fix check for gpg versions not reporting the critical flag.Justus Winter2-0/+2
* lang/python/tests/t-sig-notation.py: Also blacklist 2.0.x. * tests/gpg/t-sig-notation.c: Likewise. Signed-off-by: Justus Winter <[email protected]>
2016-09-26python: Get rid of the last C++-style comments.Justus Winter1-7/+7
-- Signed-off-by: Justus Winter <[email protected]>
2016-09-26python: Correctly translate to size_t.Justus Winter1-7/+22
* lang/python/gpgme.i: Correctly translate Python number to size_t. Signed-off-by: Justus Winter <[email protected]>
2016-09-26python: Correctly translate off_t.Justus Winter1-5/+34
* lang/python/gpgme.i: Improve int/long translations, correctly handle off_t with large file support. Signed-off-by: Justus Winter <[email protected]>
2016-09-26python: Include 'config.h'.Justus Winter5-1/+23
* lang/python/Makefile.am: Pass 'top_builddir' to 'setup.py'. * lang/python/gpgme.i: Include 'config.h'. * lang/python/helpers.c: Likewise. * lang/python/helpers.h: Likewise. * lang/python/setup.py.in: Make sure that 'config.h' can be found. -- Fixes build on 32 bit platforms with large file support. Signed-off-by: Justus Winter <[email protected]>
2016-09-23Fix spellingDaniel Kahn Gillmor5-8/+8
* lang/cpp/src/context.h, lang/qt/src/protocol.h, lang/qt/src/wkspublishjob.h, src/data-identify.c, src/engine-gpg.c: minor spelling cleanup. -- Signed-off-by: Daniel Kahn Gillmor <[email protected]>
2016-09-23move some file encodings to UTF-8Daniel Kahn Gillmor7-12/+12
* THANKS, doc/ChangeLog-2011, tests/ChangeLog-2011, tests/gpg/geheim.txt: convert from iso 8859-1 to utf-8. * lang/qt/src/dataprovider.cpp, lang/qt/src/qgpgmerefreshkeysjob.cpp, lang/qt/src/qgpgmesecretkeyexportjob.cpp: replace U+FFFD REPLACEMENT CHARACTER with proper U+00E4 LATIN SMALL LETTER A WITH DIAERESIS. -- Note that src/versioninfo.rc.in is still ISO-8859-1. I don't know whether Windows will properly handle UTF-8 in this file or not, so i have not touched it. Signed-off-by: Daniel Kahn Gillmor <[email protected]>
2016-09-23tests: Check data after decryptionAndre Heinecke1-2/+12
* tests/gpgsm/t-decrypt.c (main): Check data matches expected. Only print result if it does not.
2016-09-23cpp, qt: Include config.hAndre Heinecke69-0/+276
lang/cpp/src/callbacks.cpp, lang/cpp/src/configuration.cpp, lang/cpp/src/context.cpp, lang/cpp/src/context_glib.cpp, lang/cpp/src/context_qt.cpp, lang/cpp/src/context_vanilla.cpp, lang/cpp/src/data.cpp, lang/cpp/src/decryptionresult.cpp, lang/cpp/src/defaultassuantransaction.cpp, lang/cpp/src/editinteractor.cpp, lang/cpp/src/encryptionresult.cpp, lang/cpp/src/engineinfo.cpp, lang/cpp/src/eventloopinteractor.cpp, lang/cpp/src/exception.cpp, lang/cpp/src/gpgadduserideditinteractor.cpp, lang/cpp/src/gpgagentgetinfoassuantransaction.cpp, lang/cpp/src/gpgsetexpirytimeeditinteractor.cpp, lang/cpp/src/gpgsetownertrusteditinteractor.cpp, lang/cpp/src/gpgsignkeyeditinteractor.cpp, lang/cpp/src/importresult.cpp, lang/cpp/src/key.cpp, lang/cpp/src/keygenerationresult.cpp, lang/cpp/src/keylistresult.cpp, lang/cpp/src/scdgetinfoassuantransaction.cpp, lang/cpp/src/signingresult.cpp, lang/cpp/src/tofuinfo.cpp, lang/cpp/src/trustitem.cpp, lang/cpp/src/verificationresult.cpp, lang/cpp/src/vfsmountresult.cpp, lang/qt/src/dataprovider.cpp, lang/qt/src/defaultkeygenerationjob.cpp, lang/qt/src/gpgme_backend_debug.cpp, lang/qt/src/job.cpp, lang/qt/src/qgpgmeadduseridjob.cpp, lang/qt/src/qgpgmebackend.cpp, lang/qt/src/qgpgmechangeexpiryjob.cpp, lang/qt/src/qgpgmechangeownertrustjob.cpp, lang/qt/src/qgpgmechangepasswdjob.cpp, lang/qt/src/qgpgmedecryptjob.cpp, lang/qt/src/qgpgmedecryptverifyjob.cpp, lang/qt/src/qgpgmedeletejob.cpp, lang/qt/src/qgpgmedownloadjob.cpp, lang/qt/src/qgpgmeencryptjob.cpp, lang/qt/src/qgpgmeexportjob.cpp, lang/qt/src/qgpgmeimportfromkeyserverjob.cpp, lang/qt/src/qgpgmeimportjob.cpp, lang/qt/src/qgpgmekeyformailboxjob.cpp, lang/qt/src/qgpgmekeygenerationjob.cpp, lang/qt/src/qgpgmekeylistjob.cpp, lang/qt/src/qgpgmelistallkeysjob.cpp, lang/qt/src/qgpgmenewcryptoconfig.cpp, lang/qt/src/qgpgmerefreshkeysjob.cpp, lang/qt/src/qgpgmesecretkeyexportjob.cpp, lang/qt/src/qgpgmesignencryptjob.cpp, lang/qt/src/qgpgmesignjob.cpp, lang/qt/src/qgpgmesignkeyjob.cpp, lang/qt/src/qgpgmetofupolicyjob.cpp, lang/qt/src/qgpgmeverifydetachedjob.cpp, lang/qt/src/qgpgmeverifyopaquejob.cpp, lang/qt/src/qgpgmewkspublishjob.cpp, lang/qt/src/threadedjobmixin.cpp, lang/qt/tests/run-keyformailboxjob.cpp, lang/qt/tests/t-encrypt.cpp, lang/qt/tests/t-keylist.cpp, lang/qt/tests/t-keylocate.cpp, lang/qt/tests/t-ownertrust.cpp, lang/qt/tests/t-support.cpp, lang/qt/tests/t-tofuinfo.cpp, lang/qt/tests/t-wkspublish.cpp: Include config.h -- This fixes problems with mismatching definitions. Most notably _FILE_OFFSET_BITS is now always set correctly.
2016-09-22w32: Silence some warnings about unused parameters.Werner Koch1-0/+14
* src/assuan-support.c (my_recvmsg, my_sendmsg, my_waitpid) (my_socketpair) [W32]: Mark unused parameters. Signed-off-by: Werner Koch <[email protected]>
2016-09-22core: Fix error checking in _gpgme_mkstemp.Werner Koch1-1/+3
* src/w32-util.c (_gpgme_mkstemp): Fix error checking. (dlopen): Mark FLAGS as unused. Signed-off-by: Werner Koch <[email protected]>
2016-09-22core: New helper function _gpgme_strconcat.Werner Koch3-24/+77
* src/conversion.c: Include stdarg.h. (do_strconcat): New. (_gpgme_strconcat): New. * src/util.h: Provide fallback for GPGRT_ATTR_SENTINEL. (_gpgme_strconcat): New with sentinel. * src/w32-util.c (find_program_in_dir): Replace malloc and stpcpy by _gpgme_strconcat. (find_program_at_standard_place): Ditto. (_gpgme_set_default_gpg_name): Ditto. (_gpgme_set_default_gpgconf_name): Ditto. (_gpgme_mkstemp): Ditto. (_gpgme_set_override_inst_dir): Repalce malloc and strcpy by strdup. -- The function has been taken from gnupg/common/stringhelp.c and license changed to LPGLv2.1+. I am the original author of that code. Signed-off-by: Werner Koch <[email protected]>
2016-09-22tests: Add test for cancellationDaiki Ueno3-2/+276
* tests/gpg/t-cancel.c: New file. * tests/gpg/Makefile.am (tests_skipped): New variable, default to t-genkey and t-cancel. (noinst_PROGRAMS): Add $(tests_skipped). * tests/gpg/.gitignore: Add t-cancel. Signed-off-by: Daiki Ueno <[email protected]>
2016-09-22gpg: Add option --exit-on-status-write-errorDaiki Ueno1-0/+2
* src/engine-gpg.c (gpg_new): Add --exit-on-status-write-error if the engine version is latest enough to expect progress output from gpg. -- GnuPG-bug-id: 1415 Signed-off-by: Daiki Ueno <[email protected]> Changed the version test from the patch to use the newer have_gpg_version. Signed-off-by: Werner Koch <[email protected]>