Dear maintainer,

Attached is a debdiff containing the fix from upstream.

Sincerely

Andreas Noteng
Debian-maintainer of Pyspread
diff -Nru python-gnupg-0.3.8/debian/changelog 
python-gnupg-0.3.8/debian/changelog
--- python-gnupg-0.3.8/debian/changelog 2015-10-13 10:37:50.000000000 +0200
+++ python-gnupg-0.3.8/debian/changelog 2015-11-15 21:37:40.000000000 +0100
@@ -1,3 +1,10 @@
+python-gnupg (0.3.8-1.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Subkey fingerprints are no longer incorrectly captured (Closes: #802967)
+
+ -- Andreas Noteng <andr...@noteng.no>  Sun, 15 Nov 2015 21:37:33 +0100
+
 python-gnupg (0.3.8-1) unstable; urgency=medium
 
   [ Elena Grandi ]
diff -Nru python-gnupg-0.3.8/debian/patches/fingerprints.patch 
python-gnupg-0.3.8/debian/patches/fingerprints.patch
--- python-gnupg-0.3.8/debian/patches/fingerprints.patch        1970-01-01 
01:00:00.000000000 +0100
+++ python-gnupg-0.3.8/debian/patches/fingerprints.patch        2015-11-15 
14:48:20.000000000 +0100
@@ -0,0 +1,62 @@
+Description: Subkey fingerprints are no longer incorrectly captured.
+Author: Vinay Sajip
+Origin: upstream
+Bug: 
https://bitbucket.org/vinay.sajip/python-gnupg/issues/44/possible-undocumented-api-change-when
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=802967
+Applied-Upstream: 
https://bitbucket.org/vinay.sajip/python-gnupg/commits/e3cb134162a5
+Last-Update: 2015-11-15
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+Index: python-gnupg-0.3.8/gnupg.py
+===================================================================
+--- python-gnupg-0.3.8.orig/gnupg.py
++++ python-gnupg-0.3.8/gnupg.py
+@@ -455,7 +455,6 @@ class ListKeys(SearchKeys):
+ 
+         crt = X.509 certificate
+         crs = X.509 certificate and private key available
+-        ssb = secret subkey (secondary key)
+         uat = user attribute (same as user id except for field 10).
+         sig = signature
+         rev = revocation signature
+@@ -500,6 +499,10 @@ class ListKeys(SearchKeys):
+         self.curkey['subkeys'].append(subkey)
+         self.in_subkey = True
+ 
++    def ssb(self, args):
++        subkey = [args[4], None]    # keyid, type
++        self.curkey['subkeys'].append(subkey)
++        self.in_subkey = True
+ 
+ class ScanKeys(ListKeys):
+     ''' Handle status messages for --with-fingerprint.'''
+@@ -1121,7 +1124,7 @@ class GPG(object):
+         self._collect_output(p, result, stdin=p.stdin)
+         lines = result.data.decode(self.encoding,
+                                    self.decode_errors).splitlines()
+-        valid_keywords = 'pub uid sec fpr sub'.split()
++        valid_keywords = 'pub uid sec fpr sub ssb'.split()
+         for line in lines:
+             if self.verbose:
+                 print(line)
+Index: python-gnupg-0.3.8/test_gnupg.py
+===================================================================
+--- python-gnupg-0.3.8.orig/test_gnupg.py
++++ python-gnupg-0.3.8/test_gnupg.py
+@@ -240,6 +240,7 @@ class GPGTestCase(unittest.TestCase):
+         private_keys = self.gpg.list_keys(secret=True)
+         self.assertTrue(is_list_with_len(private_keys, 1),
+                         "1-element list expected")
++        self.assertEqual(len(private_keys.fingerprints), 1)
+         # Now do the same test, but using keyring and secret_keyring arguments
+         hd = os.path.join(os.getcwd(), 'keys')
+         gpg = gnupg.GPG(gnupghome=hd, gpgbinary=GPGBINARY,
+@@ -689,7 +690,7 @@ def suite(args=None):
+ 
+ def init_logging():
+     logging.basicConfig(level=logging.DEBUG, filename="test_gnupg.log",
+-                        filemode="w", format="%(asctime)s %(levelname)-5s 
%(name)-10s %(threadName)-10s %(message)s")
++                        filemode="w", format="%(asctime)s %(levelname)-5s 
%(name)-10s %(threadName)-10s %(lineno)4d %(message)s")
+ 
+ def main():
+     init_logging()
diff -Nru python-gnupg-0.3.8/debian/patches/series 
python-gnupg-0.3.8/debian/patches/series
--- python-gnupg-0.3.8/debian/patches/series    2015-10-13 10:27:51.000000000 
+0200
+++ python-gnupg-0.3.8/debian/patches/series    2015-11-15 14:37:15.000000000 
+0100
@@ -1 +1,2 @@
 skip_network_needing_test.patch
+fingerprints.patch

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to