Compare commits
No commits in common. "c9s" and "c8" have entirely different histories.
21
.gitignore
vendored
21
.gitignore
vendored
@ -1,20 +1 @@
|
||||
# ignore sources
|
||||
/gpgme-[0-9].[0-9].[0-9].tar.bz2
|
||||
/gpgme-[0-9].[0-9].[0-9].tar.bz2.sig
|
||||
# ignore fedpkg local build artifacts
|
||||
/.build-*.log
|
||||
/gpgme-[0-9].[0-9].[0-9]/
|
||||
/gpgme-[0-9].[0-9].[0-9]-*.src.rpm
|
||||
/i686/
|
||||
/x86_64/
|
||||
# ignore emacs cruft
|
||||
/.#*
|
||||
/#*
|
||||
/gpgme-1.10.0.tar.bz2
|
||||
/gpgme-1.11.0.tar.bz2
|
||||
/gpgme-1.11.1.tar.bz2
|
||||
/gpgme-1.12.0.tar.bz2
|
||||
/gpgme-1.13.1.tar.bz2
|
||||
/gpgme-1.14.0.tar.bz2
|
||||
/gpgme-1.15.1.tar.bz2
|
||||
/gpgme-1.15.1.licenses.tar.bz2
|
||||
SOURCES/gpgme-1.13.1.licenses.tar.bz2
|
||||
|
1
.gpgme.metadata
Normal file
1
.gpgme.metadata
Normal file
@ -0,0 +1 @@
|
||||
a33a6121d761d499716eec342fc99bcc57f6a693 SOURCES/gpgme-1.13.1.licenses.tar.bz2
|
26
SOURCES/gpgme-1.13.1-fix-null-deref.patch
Normal file
26
SOURCES/gpgme-1.13.1-fix-null-deref.patch
Normal file
@ -0,0 +1,26 @@
|
||||
diff --git a/src/data-mem.c b/src/data-mem.c
|
||||
index 539b453..ae16bab 100644
|
||||
--- a/src/data-mem.c
|
||||
+++ b/src/data-mem.c
|
||||
@@ -271,7 +271,7 @@ gpgme_data_release_and_get_mem (gpgme_data_t dh, size_t *r_len)
|
||||
}
|
||||
else
|
||||
{
|
||||
- if (blankout && len)
|
||||
+ if (str && blankout && len)
|
||||
*str = 0;
|
||||
/* Prevent mem_release from releasing the buffer memory. We
|
||||
* must not fail from this point. */
|
||||
diff --git a/src/vfs-create.c b/src/vfs-create.c
|
||||
index 51b8307..445cd05 100644
|
||||
--- a/src/vfs-create.c
|
||||
+++ b/src/vfs-create.c
|
||||
@@ -130,7 +130,7 @@ _gpgme_op_vfs_create (gpgme_ctx_t ctx, gpgme_key_t recp[],
|
||||
return err;
|
||||
|
||||
i = 0;
|
||||
- while (!err && recp[i])
|
||||
+ while (!err && recp && recp[i])
|
||||
{
|
||||
if (!recp[i]->subkeys || !recp[i]->subkeys->fpr)
|
||||
{
|
@ -1,14 +1,37 @@
|
||||
From 3101e381eb7ff31138aa20438ae757365e390d2c Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Kucera <sanczes@gmail.com>
|
||||
Date: Thu, 15 Jul 2021 22:41:37 +0200
|
||||
Subject: [PATCH] lang/python/gpgme.i: Fix memleaks
|
||||
|
||||
---
|
||||
lang/python/gpgme.i | 85 +++++++++++++++++++++++++++------------------
|
||||
1 file changed, 52 insertions(+), 33 deletions(-)
|
||||
|
||||
diff --git a/lang/cpp/src/context.cpp b/lang/cpp/src/context.cpp
|
||||
index c0a1dc21..e991dbc8 100644
|
||||
--- a/lang/cpp/src/context.cpp
|
||||
+++ b/lang/cpp/src/context.cpp
|
||||
@@ -223,6 +223,7 @@ Context *Context::createForProtocol(Protocol proto)
|
||||
}
|
||||
break;
|
||||
default:
|
||||
+ gpgme_release(ctx);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@@ -273,6 +274,7 @@ std::unique_ptr<Context> Context::createForEngine(Engine eng, Error *error)
|
||||
}
|
||||
break;
|
||||
default:
|
||||
+ gpgme_release(ctx);
|
||||
if (error) {
|
||||
*error = Error::fromCode(GPG_ERR_INV_ARG);
|
||||
}
|
||||
diff --git a/lang/cpp/src/data.cpp b/lang/cpp/src/data.cpp
|
||||
index 7a93cbc2..d08a29db 100644
|
||||
--- a/lang/cpp/src/data.cpp
|
||||
+++ b/lang/cpp/src/data.cpp
|
||||
@@ -249,6 +249,7 @@ std::vector<GpgME::Key> GpgME::Data::toKeys(Protocol proto) const
|
||||
}
|
||||
|
||||
if (gpgme_op_keylist_from_data_start (ctx->impl()->ctx, d->data, 0)) {
|
||||
+ delete ctx;
|
||||
return ret;
|
||||
}
|
||||
|
||||
diff --git a/lang/python/gpgme.i b/lang/python/gpgme.i
|
||||
index 87371af8..fabf9e2c 100644
|
||||
index 87371af8..64b88d54 100644
|
||||
--- a/lang/python/gpgme.i
|
||||
+++ b/lang/python/gpgme.i
|
||||
@@ -53,7 +53,7 @@
|
||||
@ -20,7 +43,7 @@ index 87371af8..fabf9e2c 100644
|
||||
$1 = PyBytes_AsString(encodedInput);
|
||||
}
|
||||
else if (PyBytes_Check($input))
|
||||
@@ -62,7 +62,7 @@
|
||||
@@ -62,22 +62,25 @@
|
||||
PyErr_Format(PyExc_TypeError,
|
||||
"arg %d: expected str, bytes, or None, got %s",
|
||||
$argnum, $input->ob_type->tp_name);
|
||||
@ -29,15 +52,16 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
}
|
||||
%typemap(freearg) const char * {
|
||||
@@ -70,14 +70,16 @@
|
||||
Py_XDECREF(encodedInput$argnum);
|
||||
}
|
||||
|
||||
/* Likewise for a list of strings. */
|
||||
-%typemap(in) const char *[] (void *vector = NULL,
|
||||
- size_t size,
|
||||
+%typemap(arginit) const char *[] {
|
||||
+ $1 = NULL;
|
||||
+}
|
||||
+
|
||||
/* Likewise for a list of strings. */
|
||||
-%typemap(in) const char *[] (void *vector = NULL,
|
||||
- size_t size,
|
||||
+%typemap(in) const char *[] (size_t size,
|
||||
PyObject **pyVector = NULL) {
|
||||
/* Check if is a list */
|
||||
@ -49,7 +73,7 @@ index 87371af8..fabf9e2c 100644
|
||||
pyVector = calloc(sizeof *pyVector, size);
|
||||
|
||||
for (i = 0; i < size; i++) {
|
||||
@@ -86,12 +88,7 @@
|
||||
@@ -86,12 +89,7 @@
|
||||
{
|
||||
pyVector[i] = PyUnicode_AsUTF8String(o);
|
||||
if (pyVector[i] == NULL)
|
||||
@ -63,7 +87,7 @@ index 87371af8..fabf9e2c 100644
|
||||
$1[i] = PyBytes_AsString(pyVector[i]);
|
||||
}
|
||||
else if (PyString_Check(o))
|
||||
@@ -101,8 +98,7 @@
|
||||
@@ -101,8 +99,7 @@
|
||||
"arg %d: list must contain only str or bytes, got %s "
|
||||
"at position %d",
|
||||
$argnum, o->ob_type->tp_name, i);
|
||||
@ -73,7 +97,7 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
}
|
||||
$1[i] = NULL;
|
||||
@@ -110,14 +106,17 @@
|
||||
@@ -110,14 +107,17 @@
|
||||
PyErr_Format(PyExc_TypeError,
|
||||
"arg %d: expected a list of str or bytes, got %s",
|
||||
$argnum, $input->ob_type->tp_name);
|
||||
@ -96,7 +120,7 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
|
||||
/* Release returned buffers as necessary. */
|
||||
@@ -135,7 +134,7 @@
|
||||
@@ -135,7 +135,7 @@
|
||||
if (!PySequence_Check($input)) {
|
||||
PyErr_Format(PyExc_ValueError, "arg %d: Expected a list of gpgme_key_t",
|
||||
$argnum);
|
||||
@ -105,7 +129,7 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
if((numb = PySequence_Length($input)) != 0) {
|
||||
$1 = (gpgme_key_t*)malloc((numb+1)*sizeof(gpgme_key_t));
|
||||
@@ -152,8 +151,7 @@
|
||||
@@ -152,8 +152,7 @@
|
||||
"arg %d: list must contain only gpgme_key_ts, got %s "
|
||||
"at position %d",
|
||||
$argnum, pypointer->ob_type->tp_name, i);
|
||||
@ -115,7 +139,7 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
Py_DECREF(pypointer);
|
||||
}
|
||||
@@ -179,7 +177,7 @@
|
||||
@@ -179,7 +178,7 @@
|
||||
pypointer = _gpg_obj2gpgme_data_t($input, $argnum, &wrapper,
|
||||
&bytesio, &view);
|
||||
if (pypointer == NULL)
|
||||
@ -124,7 +148,7 @@ index 87371af8..fabf9e2c 100644
|
||||
have_view = !! view.obj;
|
||||
|
||||
/* input = $input, 1 = $1, 1_descriptor = $1_descriptor */
|
||||
@@ -189,7 +187,7 @@
|
||||
@@ -189,7 +188,7 @@
|
||||
if ((SWIG_ConvertPtr(pypointer,(void **) &$1, $1_descriptor,
|
||||
SWIG_POINTER_EXCEPTION | $disown )) == -1) {
|
||||
Py_DECREF(pypointer);
|
||||
@ -133,18 +157,19 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
Py_DECREF(pypointer);
|
||||
}
|
||||
@@ -347,6 +345,10 @@
|
||||
@@ -346,6 +345,11 @@
|
||||
PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
|
||||
}
|
||||
|
||||
/* Those are for gpgme_data_read() and gpgme_strerror_r(). */
|
||||
+%typemap(arginit) (void *buffer, size_t size), (char *buf, size_t buflen) {
|
||||
+ $1 = NULL;
|
||||
+ $2 = 0;
|
||||
+}
|
||||
+
|
||||
/* Those are for gpgme_data_read() and gpgme_strerror_r(). */
|
||||
%typemap(in) (void *buffer, size_t size), (char *buf, size_t buflen) {
|
||||
{
|
||||
long tmp$argnum;
|
||||
@@ -359,12 +361,12 @@
|
||||
@@ -359,12 +363,12 @@
|
||||
else
|
||||
{
|
||||
PyErr_SetString(PyExc_TypeError, "Numeric argument expected");
|
||||
@ -159,7 +184,7 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
$2 = (size_t) tmp$argnum;
|
||||
$1 = ($1_ltype) malloc($2+1);
|
||||
@@ -373,11 +375,11 @@
|
||||
@@ -373,11 +377,11 @@
|
||||
%typemap(argout) (void *buffer, size_t size), (char *buf, size_t buflen) {
|
||||
Py_XDECREF($result); /* Blow away any previous result */
|
||||
if (result < 0) { /* Check for I/O error */
|
||||
@ -173,7 +198,7 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
|
||||
/* For gpgme_data_write, but should be universal. */
|
||||
@@ -390,11 +392,11 @@
|
||||
@@ -390,11 +394,11 @@
|
||||
{
|
||||
encodedInput = PyUnicode_AsUTF8String($input);
|
||||
if (encodedInput == NULL)
|
||||
@ -187,7 +212,7 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
}
|
||||
else if (PyBytes_Check($input))
|
||||
@@ -403,7 +405,7 @@
|
||||
@@ -403,7 +407,7 @@
|
||||
PyErr_Format(PyExc_TypeError,
|
||||
"arg %d: expected str, bytes, or None, got %s",
|
||||
$argnum, $input->ob_type->tp_name);
|
||||
@ -196,7 +221,7 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
|
||||
if (! $1)
|
||||
@@ -432,8 +434,17 @@
|
||||
@@ -432,8 +436,17 @@
|
||||
size++;
|
||||
}
|
||||
$result = PyList_New(size);
|
||||
@ -214,7 +239,7 @@ index 87371af8..fabf9e2c 100644
|
||||
PyList_SetItem($result, i, o);
|
||||
}
|
||||
}
|
||||
@@ -446,6 +457,8 @@
|
||||
@@ -446,6 +459,8 @@
|
||||
PyObject *fragile;
|
||||
fragile = SWIG_NewPointerObj(SWIG_as_voidptr($1), $1_descriptor,
|
||||
%newpointer_flags);
|
||||
@ -223,7 +248,7 @@ index 87371af8..fabf9e2c 100644
|
||||
$result = _gpg_wrap_result(fragile, name);
|
||||
Py_DECREF(fragile);
|
||||
}
|
||||
@@ -469,22 +482,28 @@ wrapresult(gpgme_vfs_mount_result_t, "VFSMountResult")
|
||||
@@ -469,22 +484,28 @@ wrapresult(gpgme_vfs_mount_result_t, "VFSMountResult")
|
||||
}
|
||||
$result = PyList_New(size);
|
||||
if ($result == NULL)
|
||||
@ -255,43 +280,11 @@ index 87371af8..fabf9e2c 100644
|
||||
}
|
||||
PyList_SetItem($result, i, o);
|
||||
}
|
||||
|
||||
From b2815dcba2e75f79a6349191b3744952a9bd3311 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Kucera <sanczes@gmail.com>
|
||||
Date: Sat, 17 Jul 2021 01:12:08 +0200
|
||||
Subject: [PATCH] lang/cpp/src/data.cpp: Fix memleaks
|
||||
|
||||
---
|
||||
lang/cpp/src/data.cpp | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/lang/cpp/src/data.cpp b/lang/cpp/src/data.cpp
|
||||
index 7a93cbc2..d08a29db 100644
|
||||
--- a/lang/cpp/src/data.cpp
|
||||
+++ b/lang/cpp/src/data.cpp
|
||||
@@ -249,6 +249,7 @@ std::vector<GpgME::Key> GpgME::Data::toKeys(Protocol proto) const
|
||||
}
|
||||
|
||||
if (gpgme_op_keylist_from_data_start (ctx->impl()->ctx, d->data, 0)) {
|
||||
+ delete ctx;
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
From eb3bf52fcb437b0508b2912f648ac25799daef55 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Kucera <sanczes@gmail.com>
|
||||
Date: Sat, 17 Jul 2021 01:12:45 +0200
|
||||
Subject: [PATCH] src/engine-gpg.c: Fix memleaks
|
||||
|
||||
---
|
||||
src/engine-gpg.c | 11 +++++++----
|
||||
1 file changed, 7 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/engine-gpg.c b/src/engine-gpg.c
|
||||
index b51ea173..af74714c 100644
|
||||
index dc2d9455..a1e40fe2 100644
|
||||
--- a/src/engine-gpg.c
|
||||
+++ b/src/engine-gpg.c
|
||||
@@ -1148,6 +1148,7 @@ build_argv (engine_gpg_t gpg, const char *pgmname)
|
||||
@@ -1122,6 +1122,7 @@ build_argv (engine_gpg_t gpg, const char *pgmname)
|
||||
to avoid and given that we reach this here only
|
||||
after a malloc failure for a small object, it is
|
||||
probably better not to do anything. */
|
||||
@ -299,7 +292,7 @@ index b51ea173..af74714c 100644
|
||||
return gpg_error (GPG_ERR_GENERAL);
|
||||
}
|
||||
/* If the data_type is FD, we have to do a dup2 here. */
|
||||
@@ -1270,6 +1271,9 @@ read_status (engine_gpg_t gpg)
|
||||
@@ -1239,6 +1240,9 @@ read_status (engine_gpg_t gpg)
|
||||
buffer = realloc (buffer, bufsize);
|
||||
if (!buffer)
|
||||
return gpg_error_from_syserror ();
|
||||
@ -309,7 +302,7 @@ index b51ea173..af74714c 100644
|
||||
}
|
||||
|
||||
nread = _gpgme_io_read (gpg->status.fd[0],
|
||||
@@ -1382,8 +1386,6 @@ read_status (engine_gpg_t gpg)
|
||||
@@ -1351,8 +1355,6 @@ read_status (engine_gpg_t gpg)
|
||||
}
|
||||
|
||||
/* Update the gpg object. */
|
||||
@ -318,7 +311,7 @@ index b51ea173..af74714c 100644
|
||||
gpg->status.readpos = readpos;
|
||||
return 0;
|
||||
}
|
||||
@@ -1423,6 +1425,9 @@ read_colon_line (engine_gpg_t gpg)
|
||||
@@ -1392,6 +1394,9 @@ read_colon_line (engine_gpg_t gpg)
|
||||
buffer = realloc (buffer, bufsize);
|
||||
if (!buffer)
|
||||
return gpg_error_from_syserror ();
|
||||
@ -328,7 +321,7 @@ index b51ea173..af74714c 100644
|
||||
}
|
||||
|
||||
nread = _gpgme_io_read (gpg->colon.fd[0], buffer+readpos, bufsize-readpos);
|
||||
@@ -1502,8 +1507,6 @@ read_colon_line (engine_gpg_t gpg)
|
||||
@@ -1471,8 +1476,6 @@ read_colon_line (engine_gpg_t gpg)
|
||||
}
|
||||
|
||||
/* Update the gpg object. */
|
||||
@ -337,18 +330,8 @@ index b51ea173..af74714c 100644
|
||||
gpg->colon.readpos = readpos;
|
||||
return 0;
|
||||
}
|
||||
|
||||
From e94363045f104fe57188bd014c91462e3693ec24 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Kucera <sanczes@gmail.com>
|
||||
Date: Sat, 17 Jul 2021 01:14:14 +0200
|
||||
Subject: [PATCH] src/engine-gpgsm.c: Fix memleaks
|
||||
|
||||
---
|
||||
src/engine-gpgsm.c | 8 ++++++--
|
||||
1 file changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/engine-gpgsm.c b/src/engine-gpgsm.c
|
||||
index d5f0d7a9..7a8a049b 100644
|
||||
index ae5d8ef1..1f603f19 100644
|
||||
--- a/src/engine-gpgsm.c
|
||||
+++ b/src/engine-gpgsm.c
|
||||
@@ -1533,8 +1533,10 @@ gpgsm_export (void *engine, const char *pattern, gpgme_export_mode_t mode,
|
||||
@ -375,3 +358,41 @@ index d5f0d7a9..7a8a049b 100644
|
||||
gpgsm_clear_fd (gpgsm, INPUT_FD);
|
||||
gpgsm_clear_fd (gpgsm, MESSAGE_FD);
|
||||
gpgsm->inline_data = NULL;
|
||||
diff --git a/src/engine.c b/src/engine.c
|
||||
index 05979c15..7e2e3800 100644
|
||||
--- a/src/engine.c
|
||||
+++ b/src/engine.c
|
||||
@@ -460,7 +460,8 @@ _gpgme_set_engine_info (gpgme_engine_info_t info, gpgme_protocol_t proto,
|
||||
if (!new_version)
|
||||
{
|
||||
free (new_file_name);
|
||||
- free (new_home_dir);
|
||||
+ if (new_home_dir)
|
||||
+ free (new_home_dir);
|
||||
return gpg_error_from_syserror ();
|
||||
}
|
||||
}
|
||||
diff --git a/src/gpgme-tool.c b/src/gpgme-tool.c
|
||||
index 7a0bfcb3..f4ddd83b 100644
|
||||
--- a/src/gpgme-tool.c
|
||||
+++ b/src/gpgme-tool.c
|
||||
@@ -1189,6 +1189,7 @@ gt_get_key (gpgme_tool_t gt, const char *pattern, gpgme_key_t *r_key)
|
||||
similar hack to sort out such duplicates but it can't
|
||||
do that while listing keys. */
|
||||
gpgme_key_unref (key);
|
||||
+ key = NULL;
|
||||
goto try_next_key;
|
||||
}
|
||||
if (!err)
|
||||
diff --git a/src/keylist.c b/src/keylist.c
|
||||
index cdb115fd..b7cbf3c3 100644
|
||||
--- a/src/keylist.c
|
||||
+++ b/src/keylist.c
|
||||
@@ -1321,6 +1321,7 @@ gpgme_get_key (gpgme_ctx_t ctx, const char *fpr, gpgme_key_t *r_key,
|
||||
similar hack to sort out such duplicates but it can't
|
||||
do that while listing keys. */
|
||||
gpgme_key_unref (key);
|
||||
+ key = NULL;
|
||||
goto try_next_key;
|
||||
}
|
||||
if (!err)
|
31
SOURCES/gpgme-1.13.1-pkgconfig.patch
Normal file
31
SOURCES/gpgme-1.13.1-pkgconfig.patch
Normal file
@ -0,0 +1,31 @@
|
||||
diff --git a/src/gpgme-glib.pc.in b/src/gpgme-glib.pc.in
|
||||
index bd42a31..781a463 100644
|
||||
--- a/src/gpgme-glib.pc.in
|
||||
+++ b/src/gpgme-glib.pc.in
|
||||
@@ -7,8 +7,8 @@ api_version=@GPGME_CONFIG_API_VERSION@
|
||||
|
||||
Name: gpgme-glib
|
||||
Description: GnuPG Made Easy to access GnuPG with Glib
|
||||
-Requires: gpg-error, libassuan, glib-2.0
|
||||
+Requires: glib-2.0
|
||||
Version: @PACKAGE_VERSION@
|
||||
-Cflags: @GPGME_CONFIG_CFLAGS@
|
||||
-Libs: @GPGME_CONFIG_LIBS@
|
||||
+Cflags: @GPGME_CONFIG_CFLAGS@ -I/usr/include/libassuan2
|
||||
+Libs: @GPGME_CONFIG_LIBS@ -lgpg-error -lassuan
|
||||
URL: https://www.gnupg.org/software/gpgme/index.html
|
||||
diff --git a/src/gpgme.pc.in b/src/gpgme.pc.in
|
||||
index be288b8..a71bcf7 100644
|
||||
--- a/src/gpgme.pc.in
|
||||
+++ b/src/gpgme.pc.in
|
||||
@@ -7,8 +7,7 @@ api_version=@GPGME_CONFIG_API_VERSION@
|
||||
|
||||
Name: gpgme
|
||||
Description: GnuPG Made Easy to access GnuPG
|
||||
-Requires: gpg-error, libassuan
|
||||
Version: @PACKAGE_VERSION@
|
||||
-Cflags: @GPGME_CONFIG_CFLAGS@
|
||||
-Libs: @GPGME_CONFIG_LIBS@
|
||||
+Cflags: @GPGME_CONFIG_CFLAGS@ -I/usr/include/libassuan2
|
||||
+Libs: @GPGME_CONFIG_LIBS@ -lgpg-error -lassuan
|
||||
URL: https://www.gnupg.org/software/gpgme/index.html
|
27
SOURCES/gpgme-build-with-gnupg-2.2.19.patch
Normal file
27
SOURCES/gpgme-build-with-gnupg-2.2.19.patch
Normal file
@ -0,0 +1,27 @@
|
||||
diff -up gpgme-1.13.1/src/engine-gpg.c.build gpgme-1.13.1/src/engine-gpg.c
|
||||
--- gpgme-1.13.1/src/engine-gpg.c.build 2019-06-13 08:45:22.000000000 +0200
|
||||
+++ gpgme-1.13.1/src/engine-gpg.c 2020-04-30 14:30:35.550253558 +0200
|
||||
@@ -2920,6 +2920,12 @@ gpg_keylist_build_options (engine_gpg_t
|
||||
|
||||
err = add_arg (gpg, "--with-colons");
|
||||
|
||||
+ if (have_gpg_version (gpg, "2.2.19"))
|
||||
+ {
|
||||
+ if (!err)
|
||||
+ err = add_arg (gpg, "--with-keygrip");
|
||||
+ }
|
||||
+
|
||||
/* Since gpg 2.1.15 fingerprints are always printed, thus there is
|
||||
* no more need to explicitly request them. */
|
||||
if (!have_gpg_version (gpg, "2.1.15"))
|
||||
diff -up gpgme-1.13.1/tests/json/t-keylist-secret.out.json.build gpgme-1.13.1/tests/json/t-keylist-secret.out.json
|
||||
--- gpgme-1.13.1/tests/json/t-keylist-secret.out.json.build 2018-12-03 10:37:25.000000000 +0100
|
||||
+++ gpgme-1.13.1/tests/json/t-keylist-secret.out.json 2020-04-30 14:24:40.904707411 +0200
|
||||
@@ -91,7 +91,6 @@
|
||||
"can_sign": true,
|
||||
"can_certify": true,
|
||||
"can_authenticate": true,
|
||||
- "secret": true,
|
||||
"is_qualified": false,
|
||||
"protocol": "OpenPGP",
|
||||
"fingerprint": "D695676BDCEDCC2CDD6152BCFE180B1DA9E3B0B2",
|
@ -1,15 +1,23 @@
|
||||
%bcond_without check
|
||||
|
||||
%if 0%{?rhel} > 7
|
||||
# Disable python2 build by default
|
||||
%bcond_with python2
|
||||
%else
|
||||
%bcond_without python2
|
||||
%endif
|
||||
|
||||
# trim changelog included in binary rpms
|
||||
%global _changelog_trimtime %(date +%s -d "1 year ago")
|
||||
|
||||
%global gnupg2_min_ver 2.2.24
|
||||
%global libgpg_error_min_ver 1.36
|
||||
# STATUS_KEY_CONSIDERED has been added in 2.1.13
|
||||
%global gnupg2_min_ver 2.1.13
|
||||
%global libgpg_error_min_ver 1.24
|
||||
|
||||
Name: gpgme
|
||||
Summary: GnuPG Made Easy - high level crypto API
|
||||
Version: 1.15.1
|
||||
Release: 6%{?dist}
|
||||
Version: 1.13.1
|
||||
Release: 12%{?dist}
|
||||
|
||||
# /usr/bin/gpgme-tool is licensed under GPLv3+
|
||||
# the rest is licensed under LGPLv2+
|
||||
@ -29,14 +37,19 @@ Patch1001: 0001-don-t-add-extra-libraries-for-linking.patch
|
||||
Patch1002: gpgme-1.3.2-largefile.patch
|
||||
# Let's fix stupid AX_PYTHON_DEVEL
|
||||
Patch1003: 0001-fix-stupid-ax_python_devel.patch
|
||||
# Fix static analysis issues
|
||||
Patch1004: gpgme-1.15.1-covscan.patch
|
||||
# glibc 2.34 introduces closefrom()
|
||||
Patch1005: gpgme-1.15.1-glibc-closefrom.patch
|
||||
# Fix resource leaks discovered by static code analyzer
|
||||
Patch1004: gpgme-1.13.1-fix-resource-leaks.patch
|
||||
# Make the make check work with gnupg-2.2.19 and above
|
||||
Patch1005: gpgme-build-with-gnupg-2.2.19.patch
|
||||
# Fix NULL dereference
|
||||
Patch1006: gpgme-1.13.1-fix-null-deref.patch
|
||||
# Remove Requires: from pkgconfigs (rely only on rpm deps
|
||||
# since both libgpg-error and libassuan have no pkgconfigs
|
||||
# packaged)
|
||||
Patch1007: gpgme-1.13.1-pkgconfig.patch
|
||||
|
||||
#BuildRequires: autoconf
|
||||
#BuildRequires: automake
|
||||
BuildRequires: make
|
||||
BuildRequires: gcc
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: gawk
|
||||
@ -69,6 +82,9 @@ management.
|
||||
Summary: Development headers and libraries for %{name}
|
||||
Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
Requires: libgpg-error-devel%{?_isa} >= %{libgpg_error_min_ver}
|
||||
Requires: libassuan-devel
|
||||
Requires(post): /sbin/install-info
|
||||
Requires(postun): /sbin/install-info
|
||||
|
||||
%description devel
|
||||
%{summary}.
|
||||
@ -99,6 +115,7 @@ BuildRequires: cmake
|
||||
%package -n q%{name}
|
||||
Summary: Qt API bindings/wrapper for GPGME
|
||||
Requires: %{name}pp%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
# This is probably redundant, but it satisfies RPMDIFF:
|
||||
Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
BuildRequires: pkgconfig(Qt5Core)
|
||||
BuildRequires: pkgconfig(Qt5Test)
|
||||
@ -118,12 +135,22 @@ BuildRequires: cmake
|
||||
%description -n q%{name}-devel
|
||||
%{summary}.
|
||||
|
||||
%if %{with python2}
|
||||
%package -n python2-gpg
|
||||
Summary: %{name} bindings for Python 2
|
||||
%{?python_provide:%python_provide python2-gpg}
|
||||
BuildRequires: python2-devel
|
||||
Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
|
||||
%description -n python2-gpg
|
||||
%{summary}.
|
||||
%endif
|
||||
|
||||
%package -n python3-gpg
|
||||
Summary: %{name} bindings for Python 3
|
||||
%{?python_provide:%python_provide python3-gpg}
|
||||
BuildRequires: python3-devel
|
||||
Requires: %{name}%{?_isa} = %{?epoch:%{epoch}:}%{version}-%{release}
|
||||
Obsoletes: platform-python-gpg < %{version}-%{release}
|
||||
|
||||
%description -n python3-gpg
|
||||
%{summary}.
|
||||
@ -136,14 +163,11 @@ Obsoletes: platform-python-gpg < %{version}-%{release}
|
||||
# set it to a value which we know will be suppressed.
|
||||
sed -i -e 's|^libdir=@libdir@$|libdir=@exec_prefix@/lib|g' src/gpgme-config.in
|
||||
|
||||
# The build machinery does not support Python 3.9+ yet
|
||||
# https://github.com/gpg/gpgme/pull/4
|
||||
sed -i 's/3.8/%{python3_version}/g' configure
|
||||
|
||||
%build
|
||||
# People neeed to learn that you can't run autogen.sh anymore
|
||||
#./autogen.sh
|
||||
%configure --disable-static --disable-silent-rules --enable-languages=cpp,qt,python
|
||||
%configure --disable-static --disable-silent-rules \
|
||||
--enable-languages=cpp,qt,python
|
||||
|
||||
%make_build
|
||||
|
||||
%install
|
||||
@ -166,12 +190,13 @@ mv %{buildroot}%{_includedir}/gpgme.h \
|
||||
install -m644 -p -D %{SOURCE2} %{buildroot}%{_includedir}/gpgme.h
|
||||
%endif
|
||||
chrpath -d %{buildroot}%{_bindir}/%{name}-tool
|
||||
chrpath -d %{buildroot}%{_bindir}/%{name}-json
|
||||
chrpath -d %{buildroot}%{_libdir}/lib%{name}pp.so*
|
||||
chrpath -d %{buildroot}%{_libdir}/libq%{name}.so*
|
||||
|
||||
# autofoo installs useless stuff for uninstall
|
||||
%if %{with python2}
|
||||
rm -vf %{buildroot}%{python2_sitelib}/gpg/install_files.txt
|
||||
%endif
|
||||
rm -vf %{buildroot}%{python3_sitelib}/gpg/install_files.txt
|
||||
|
||||
%if %{with check}
|
||||
@ -179,11 +204,21 @@ rm -vf %{buildroot}%{python3_sitelib}/gpg/install_files.txt
|
||||
make check
|
||||
%endif
|
||||
|
||||
%ldconfig_scriptlets
|
||||
|
||||
%files
|
||||
%license COPYING* LICENSES
|
||||
%doc AUTHORS NEWS README*
|
||||
%{_bindir}/%{name}-json
|
||||
%doc AUTHORS ChangeLog NEWS README* THANKS TODO VERSION
|
||||
%{_libdir}/lib%{name}.so.11*
|
||||
%{_bindir}/%{name}-json
|
||||
|
||||
%post devel
|
||||
/sbin/install-info %{_infodir}/%{name}.info %{_infodir}/dir 2>/dev/null || :
|
||||
|
||||
%preun devel
|
||||
if [ $1 -eq 0 ] ; then
|
||||
/sbin/install-info --delete %{_infodir}/%{name}.info %{_infodir}/dir 2>/dev/null || :
|
||||
fi
|
||||
|
||||
%files devel
|
||||
%{_bindir}/%{name}-config
|
||||
@ -200,7 +235,7 @@ make check
|
||||
|
||||
%files -n %{name}pp
|
||||
%doc lang/cpp/README
|
||||
%{_libdir}/lib%{name}pp.so.6*
|
||||
%{_libdir}/lib%{name}pp.so.*
|
||||
|
||||
%files -n %{name}pp-devel
|
||||
%{_includedir}/%{name}++/
|
||||
@ -209,7 +244,7 @@ make check
|
||||
|
||||
%files -n q%{name}
|
||||
%doc lang/qt/README
|
||||
%{_libdir}/libq%{name}.so.7*
|
||||
%{_libdir}/libq%{name}.so.*
|
||||
|
||||
%files -n q%{name}-devel
|
||||
%{_includedir}/q%{name}/
|
||||
@ -217,87 +252,77 @@ make check
|
||||
%{_libdir}/libq%{name}.so
|
||||
%{_libdir}/cmake/QGpgme/
|
||||
|
||||
%if %{with python2}
|
||||
%files -n python2-gpg
|
||||
%doc lang/python/README
|
||||
%{python2_sitearch}/gpg-*.egg-info
|
||||
%{python2_sitearch}/gpg/
|
||||
%endif
|
||||
|
||||
%files -n python3-gpg
|
||||
%doc lang/python/README
|
||||
%{python3_sitearch}/gpg-*.egg-info
|
||||
%{python3_sitearch}/gpg/
|
||||
|
||||
%changelog
|
||||
* Thu Feb 17 2022 Jiri Kucera <jkucera@redhat.com> - 1.15.1-6
|
||||
* Tue Jan 16 2024 Michal Hlavinka <mhlavink@redhat.com> - 1.13.1-12
|
||||
- add libassuan-devel to devel pkg requirements (#RHEL-6920)
|
||||
|
||||
* Thu Feb 10 2022 Jiri Kucera <jkucera@redhat.com> - 1.13.1-11
|
||||
- Update pkgconfig files
|
||||
Related: #1953905
|
||||
|
||||
* Wed Feb 09 2022 Jiri Kucera <jkucera@redhat.com> - 1.13.1-10
|
||||
- Add fixed pkgconfig files
|
||||
Resolves: #1953905
|
||||
|
||||
* Fri Jun 11 2021 Jiri Kucera <jkucera@redhat.com> - 1.13.1-9
|
||||
- Remove pkgconfig files
|
||||
Needs libgpg-error and libassuan rebase
|
||||
Related: #1882423
|
||||
|
||||
* Tue Jun 08 2021 Jiri Kucera <jkucera@redhat.com> - 1.13.1-8
|
||||
- Add LICENSES file into the tarball, update License field
|
||||
Add pkgconfig files to gpgme-devel
|
||||
Resolves: #1882423, #1953905
|
||||
|
||||
* Wed Nov 18 2020 Jiri Kucera <jkucera@redhat.com> - 1.13.1-7
|
||||
- Fix null dereference
|
||||
Fix licence tag
|
||||
Related: #1726861
|
||||
|
||||
* Fri Nov 06 2020 Jiri Kucera <jkucera@redhat.com> - 1.13.1-6
|
||||
- Try to fix RPMDIFF issues
|
||||
Related: #1726861
|
||||
|
||||
* Tue Nov 03 2020 Jiri Kucera <jkucera@redhat.com> - 1.13.1-5
|
||||
- Rebuild
|
||||
Resolves: #2035319
|
||||
Related: #1726861
|
||||
|
||||
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 1.15.1-5
|
||||
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
||||
Related: rhbz#1991688
|
||||
* Tue Sep 29 2020 Jiri Kucera <jkucera@redhat.com> - 1.13.1-4
|
||||
- Rebuild
|
||||
Resolves: #1726861
|
||||
|
||||
* Fri Jul 16 2021 Jiri Kucera <jkucera@redhat.com> - 1.15.1-4
|
||||
- Fix license and covscan issues
|
||||
Resolves: #1938732
|
||||
* Tue Jun 02 2020 Jiri Kucera <jkucera@redhat.com> - 1.13.1-3
|
||||
- Fix resource leaks found by static code analysis
|
||||
Related: #1829822
|
||||
|
||||
* Thu Apr 15 2021 Mohan Boddu <mboddu@redhat.com> - 1.15.1-3
|
||||
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
||||
* Mon Jun 01 2020 Jiri Kucera <jkucera@redhat.com> - 1.13.1-2
|
||||
- Remove *.pc files due to 'nothing provides pkgconfig(gpg-error)'
|
||||
and 'nothing provides pkgconfig(libassuan)' dnf errors
|
||||
Related: #1829822
|
||||
|
||||
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.15.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
* Mon Jun 01 2020 Jiri Kucera <jkucera@redhat.com> - 1.13.1-1
|
||||
- Update to gpgme 1.13.1
|
||||
Resolves: #1829822
|
||||
|
||||
* Sun Jan 24 2021 Igor Raits <ignatenkobrain@fedoraproject.org> - 1.15.1-1
|
||||
- Update to 1.15.1
|
||||
* Mon Nov 12 2018 Jiri Kucera <jkucera@redhat.com> - 1.10.0-6
|
||||
- Fix important static scanner issues
|
||||
Resolves: #1602526
|
||||
|
||||
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.14.0-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||
|
||||
* Sat Jul 18 2020 Igor Raits <ignatenkobrain@fedoraproject.org> - 1.14.0-1
|
||||
- Update to 1.14.0
|
||||
|
||||
* Fri May 22 2020 Miro Hrončok <mhroncok@redhat.com> - 1.13.1-8
|
||||
- Rebuilt for Python 3.9
|
||||
|
||||
* Thu Apr 30 2020 Tomáš Mráz <tmraz@redhat.com> - 1.13.1-7
|
||||
- Fix FTBFS with gnupg-2.2.19 and above
|
||||
|
||||
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.13.1-6
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 1.13.1-5
|
||||
- Rebuilt for Python 3.8.0rc1 (#1748018)
|
||||
|
||||
* Thu Aug 15 2019 Miro Hrončok <mhroncok@redhat.com> - 1.13.1-4
|
||||
- Rebuilt for Python 3.8
|
||||
|
||||
* Sat Aug 10 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.13.1-3
|
||||
- Set real VERSION
|
||||
|
||||
* Sat Aug 3 2019 Peter Robinson <pbrobinson@fedoraproject.org> 1.13.1-2
|
||||
- Move .pc files to devel so the base library doesn't pull in devel packages
|
||||
|
||||
* Mon Jul 29 18:46:42 CEST 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.13.1-1
|
||||
- Update to 1.13.1
|
||||
|
||||
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.12.0-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Wed Jun 05 2019 Miro Hrončok <mhroncok@redhat.com> - 1.12.0-2
|
||||
- Subpackage python2-gpg has been removed
|
||||
See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
|
||||
|
||||
* Sat Feb 16 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.12.0-1
|
||||
- Update to 1.12.0
|
||||
|
||||
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.11.1-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.11.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||
|
||||
* Fri Jun 15 2018 Miro Hrončok <mhroncok@redhat.com> - 1.11.1-2
|
||||
- Rebuilt for Python 3.7
|
||||
|
||||
* Fri Apr 20 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.11.1-1
|
||||
- Update to 1.11.1
|
||||
|
||||
* Thu Apr 19 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1.11.0-1
|
||||
- Update to 1.11.0
|
||||
* Mon May 28 2018 Charalampos Stratakis <cstratak@redhat.com> - 1.10.0-5
|
||||
- Conditionalize the python2 subpackage
|
||||
- Build only the python3 bindings
|
||||
|
||||
* Tue Apr 17 2018 Jonathan Lebon <jonathan@jlebon.com> - 1.10.0-4
|
||||
- Backport patch to tweak STATUS_FAILURE handling
|
@ -1,6 +0,0 @@
|
||||
--- !Policy
|
||||
product_versions:
|
||||
- rhel-9
|
||||
decision_context: osci_compose_gate
|
||||
rules:
|
||||
- !PassingTestCaseRule {test_case_name: baseos-ci.brew-build.tier1.functional}
|
@ -1,13 +0,0 @@
|
||||
diff --git a/src/posix-io.c b/src/posix-io.c
|
||||
index e712ef2..2a3a81f 100644
|
||||
--- a/src/posix-io.c
|
||||
+++ b/src/posix-io.c
|
||||
@@ -570,7 +570,7 @@ _gpgme_io_spawn (const char *path, char *const argv[], unsigned int flags,
|
||||
if (fd_list[i].fd > fd)
|
||||
fd = fd_list[i].fd;
|
||||
fd++;
|
||||
-#if defined(__sun) || defined(__FreeBSD__)
|
||||
+#if defined(__sun) || defined(__FreeBSD__) || defined(__GLIBC__)
|
||||
closefrom (fd);
|
||||
max_fds = fd;
|
||||
#else /*!__sun */
|
Loading…
Reference in New Issue
Block a user