Skip to content

Commit

Permalink
Merge branch 'release/3.0.2'
Browse files Browse the repository at this point in the history
  • Loading branch information
isislovecruft committed Jul 25, 2018
2 parents ff1a802 + 6182885 commit ada4932
Show file tree
Hide file tree
Showing 9 changed files with 196 additions and 149 deletions.
12 changes: 8 additions & 4 deletions README
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
pretty-bad-protocol (a.k.a. python-gnupg) |On PyPI|
*******************************************************

Complete rewrite of `Vinay Sajip's python-gnupg <https://code.google.com/p/python-gnupg/>`__,
Complete rewrite of `Vinay Sajip's python-gnupg <https://bitbucket.org/vinay.sajip/python-gnupg>`__,
including patches to fix a shell injection vulnerability due to unsanitised
inputs being passed to ``subprocess.Popen([...], shell=True)``.

Expand All @@ -21,7 +21,7 @@ From `PyPI <https://pypi.python.org>`__

It's simple. Just do::

[sudo] pip install pretty-bad-security
[sudo] pip install pretty-bad-protocol

Additionally, the legacy way to install versions of this library <
3.0.0 is::
Expand All @@ -47,9 +47,13 @@ Optionally, to build the Sphinx documentation_, do::
To get started using python-gnupg's API, see the documentation_,
and import the module like so::

.. code-block:: python
>>> from pretty_bad_protocol import gnupg
The primary interface class you'll likely want to interact with is ``gnupg.GPG``::
The primary interface class you'll likely want to interact with is ``gnupg.GPG``:

.. code-block:: python
>>> gpg = gnupg.GPG(binary='/usr/bin/gpg',
... homedir='./keys',
Expand All @@ -72,7 +76,7 @@ The primary interface class you'll likely want to interact with is ``gnupg.GPG``
>>> message = "The crow flies at midnight."
>>> encrypted = str(gpg.encrypt(message, key.fingerprint))
>>> decrypted = str(gpg.decrypt(encrypted))
>>> assert(decrypted == message)
>>> assert decrypted == message
.. _documentation: https://pythonhosted.org/gnupg/

Expand Down
41 changes: 30 additions & 11 deletions pretty_bad_protocol/_meta.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
import locale
import os
import platform
import re
import shlex
import subprocess
import sys
Expand All @@ -53,6 +54,8 @@
from ._parsers import _sanitise_list
from ._util import log

_VERSION_RE = re.compile('^\d+\.\d+\.\d+$')


class GPGMeta(type):
"""Metaclass for changing the :meth:GPG.__init__ initialiser.
Expand Down Expand Up @@ -521,8 +524,12 @@ def _check_sane_and_get_gpg_version(self):
"Are you sure you specified the corrent (and full) "
"path to the gpg binary?"))

version_line = str(result.data).partition(':version:')[2]
version_line = result.data.partition(b':version:')[2].decode()
if not version_line:
raise RuntimeError("Got invalid version line from gpg: %s\n" % result.data)
self.binary_version = version_line.split('\n')[0]
if not _VERSION_RE.match(self.binary_version):
raise RuntimeError("Got invalid version line from gpg: %s\n" % self.binary_version)
log.debug("Using GnuPG version %s" % self.binary_version)

def _make_args(self, args, passphrase=False):
Expand Down Expand Up @@ -641,7 +648,15 @@ def _read_response(self, stream, result):
the ``handle_status()`` method of that class will be
called in order to parse the output of ``stream``.
"""
# All of the userland messages (i.e. not status-fd lines) we're not
# interested in passing to our logger
userland_messages_to_ignore = []

if self.ignore_homedir_permissions:
userland_messages_to_ignore.append('unsafe ownership on homedir')

lines = []

while True:
line = stream.readline()
if len(line) == 0:
Expand All @@ -657,15 +672,19 @@ def _read_response(self, stream, result):
line = _util._deprefix(line, 'gpg: ')
keyword, value = _util._separate_keyword(line)

# Log gpg's userland messages at our own levels:
if keyword.upper().startswith("WARNING"):
log.warn("%s" % value)
elif keyword.upper().startswith("FATAL"):
log.critical("%s" % value)
# Handle the gpg2 error where a missing trustdb.gpg is,
# for some stupid reason, considered fatal:
if value.find("trustdb.gpg") and value.find("No such file"):
result._handle_status('NEED_TRUSTDB', '')
# Silence warnings from gpg we're supposed to ignore
ignore = any(msg in value for msg in userland_messages_to_ignore)

if not ignore:
# Log gpg's userland messages at our own levels:
if keyword.upper().startswith("WARNING"):
log.warn("%s" % value)
elif keyword.upper().startswith("FATAL"):
log.critical("%s" % value)
# Handle the gpg2 error where a missing trustdb.gpg is,
# for some stupid reason, considered fatal:
if value.find("trustdb.gpg") and value.find("No such file"):
result._handle_status('NEED_TRUSTDB', '')
else:
if self.verbose:
log.info("%s" % line)
Expand Down Expand Up @@ -936,7 +955,7 @@ def _encrypt(self, data, recipients,
>>> encrypted = str(gpg.encrypt(message, key.fingerprint))
>>> assert encrypted != message
>>> assert not encrypted.isspace()
>>> decrypted = str(gpg.decrypt(encrypted))
>>> decrypted = str(gpg.decrypt(encrypted, passphrase='foo'))
>>> assert not decrypted.isspace()
>>> decrypted
'The crow flies at midnight.'
Expand Down
5 changes: 3 additions & 2 deletions pretty_bad_protocol/_parsers.py
Original file line number Diff line number Diff line change
Expand Up @@ -1091,7 +1091,7 @@ def _handle_status(self, key, value):
elif key == "NODATA":
self.status = nodata(value)
elif key == "PROGRESS":
self.status = progress(value.split(" ", 1)[0])
self.status = progress(value.split(' ', 1)[0])
else:
raise ValueError("Unknown status message: %r" % key)

Expand Down Expand Up @@ -1343,13 +1343,14 @@ def _handle_status(self, key, value):
:raises ValueError: if the status message is unknown.
"""
informational_keys = ["KEY_CONSIDERED"]
if key in ("EXPORTED"):
self.fingerprints.append(value)
elif key == "EXPORT_RES":
export_res = value.split()
for x in self.counts.keys():
self.counts[x] += int(export_res.pop(0))
else:
elif key not in informational_keys:
raise ValueError("Unknown status message: %r" % key)

def summary(self):
Expand Down
10 changes: 6 additions & 4 deletions pretty_bad_protocol/gnupg.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ def __init__(self, binary=None, homedir=None, verbose=False,
sufficient permissions.
:param str homedir: Full pathname to directory containing the public
and private keyrings. Default is whatever GnuPG
defaults to.
and private keyrings. Default is
`~/.config/python-gnupg`.
:type ignore_homedir_permissions: :obj:`bool`
:param ignore_homedir_permissions: If true, bypass check that homedir
Expand Down Expand Up @@ -369,7 +369,7 @@ def recv_keys(self, *keyids, **kwargs):
"""Import keys from a keyserver.
>>> gpg = gnupg.GPG(homedir="doctests")
>>> key = gpg.recv_keys('hkp://pgp.mit.edu', '3FF0DB166A7476EA')
>>> key = gpg.recv_keys('3FF0DB166A7476EA', keyserver='hkp://pgp.mit.edu')
>>> assert key
:param str keyids: Each ``keyids`` argument should be a string
Expand Down Expand Up @@ -629,6 +629,8 @@ def expire(self, keyid, expiration_time='1y', passphrase=None, expire_subkeys=Tr
p.stdin.write(expiration_input)

result = self._result_map['expire'](self)
p.stdin.write(expiration_input)

self._collect_output(p, result, stdin=p.stdin)
return result

Expand Down Expand Up @@ -1029,7 +1031,7 @@ def encrypt(self, data, *recipients, **kwargs):
>>> encrypted = str(gpg.encrypt(message, key.fingerprint))
>>> assert encrypted != message
>>> assert not encrypted.isspace()
>>> decrypted = str(gpg.decrypt(encrypted))
>>> decrypted = str(gpg.decrypt(encrypted, passphrase='foo'))
>>> assert not decrypted.isspace()
>>> decrypted
'The crow flies at midnight.'
Expand Down
44 changes: 22 additions & 22 deletions pretty_bad_protocol/test/files/test_key_1.pub
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v2
Version: GnuPG v1

mQENBFPcAbUBCADyAcv3Xb3A+j0ndtFNEw3fxfwcTnMBePTmLGmsz60y+DL8N0mb
U2qpmglb2ONkFJJDa2fhl9XHwalmKCxynNE0kMNvTnTJFhFL3QSS8BPDUYKrCPfH
NcuDtpAwEZJF6PnTy+8eNciT3Ru/NT1cw1K9YkTT5XqKvfgqhaSybHSMrPlx4rAE
Is5oX0MwX3RdEtX+GzvGiz8s8+pPMX2Vh09pj6wsV+zBexXNvQnO0VzP2eteTEwV
5ezgvmh6Ss3OMPJTKxc98jczRMVYtZlv05KdziKK0VWtshp2Xubt2VVRKSCOYk8r
trR75b6yyDeFrGrvl22X2IUdttyb3XlMCJ+rABEBAAG0OXB5dGhvbi1nbnVwZyB0
ZXN0IGtleSAjMSAoRE8gTk9UIFVTRSkgPHRlc3RAcHl0aG9uLWdudXBnPokBPgQT
AQIAKAIbAwYLCQgHAwIGFQgCCQoLBBYCAwECHgECF4AFAlbazHQFCQxkzD8ACgkQ
dMU6jvwynOPnswf+O23ssUsXdjEz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m/DVv
9f3wbNQCpAeO7QXasFa7W4sC5Sx3erD4CP5B4cXbujIjl1q4UA0jMWoJ95DPy22r
LwMygHmXCXj8Ai4YFWupxbM8RePJsjdeCWF7lOpnIajE6Y+GBRbZzB7DObtxcBvM
IAYWxvJ9wA8TPC2r/1Ap2PwZGHsG9ZPNbzECwQyWA5TjIVfZVyniuQGfKFdKtBNP
Uh6hM2yznQg=
=6++F
-----END PGP PUBLIC KEY BLOCK-----
70 changes: 35 additions & 35 deletions pretty_bad_protocol/test/files/test_key_1.sec
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
-----BEGIN PGP PRIVATE KEY BLOCK-----
Version: GnuPG v2
Version: GnuPG v1

lQOYBFPcAbUBCADyAcv3Xb3A+j0ndtFNEw3fxfwcTnMBePTmLGmsz60y+DL8N0mb
U2qpmglb2ONkFJJDa2fhl9XHwalmKCxynNE0kMNvTnTJFhFL3QSS8BPDUYKrCPfH
Expand All @@ -21,38 +21,38 @@ bXmxwiuT+5DMj5nZmfT1Lijwn/KZZHMEAJumBFXr+9pwnr4hsYOutIUnuPo0ikn+
Z1GXDJM8RvHDvm2/nOWBmIbMIiiYUK09SaPNa+gsXWCmpw8geMQr88scx8KsRSAX
wOVyWHaieuvtSOWpTJG8XDZ3wT9bgYEff3dh7Xn+URtPEkcoF/JWQE0aLq8Olnnv
ckI2TSUbjMO+PoO0OXB5dGhvbi1nbnVwZyB0ZXN0IGtleSAjMSAoRE8gTk9UIFVT
RSkgPHRlc3RAcHl0aG9uLWdudXBnPokBPgQTAQIAKAIbAwYLCQgHAwIGFQgCCQoL
BBYCAwECHgECF4AFAlbazHQFCQxkzD8ACgkQdMU6jvwynOPnswf+O23ssUsXdjEz
DWo06m4w2tCxMRaP6gg3JSrHCxDtDBtwnoIzQL4rX+rA4ZGHz6QKsxg1pD+ze/dx
KlyJ9p7qYvN1hln+JX0c72EsmXEbmHITW0qCsUJ+PpuIGO/kN0as++y/T9zmAeTY
krdBiy1ZAw/gNqHkE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z0U
R8C7xhtSgk8gbbkdPL/SgXF0H6+U5zrTPMz8o0S7H9tPTxksER5ohA2pilLFde+7
ioUfBCOTWSaBS4VfDXzVyHYlJZN1rawbB2Lb7KaD9+TzXU1Ur2I/K6/p3gBw5mS3
bzV1UKHc2KmeXJQ7Hy5D7m1bapKMh/8dBACpb/qsyELNu4imgQbOSTeKOicBzVFI
lWSOXPnOYFSfaHEqb2CI5l1/tUmuh5ip/vP8s0CRvJ+xK5LyTeWJU9NF2gbYQuM+
nFodR2qOdj5yDXGwhDDgaQah/rhxPxrRStUc2NZSfhgSuj3+CftcsE6/QE1EbCLD
DZyAjBnOdMWC90FNiQEfBBgBAgAJAhsMBQJbWOOEAAoJEHTFOo78MpzjZPMIAMuU
n9qsK7tKwuxoL/dBWps6dvzupm3sbld3hm5aK04LWOO0yNTT5Lmi77QKposycOxW
KaJpoutRtkWhF5A0gw9tfle1kHFQBISGAns/B73NauXLEEnu0PLoIZCsnvDwm4ye
N/Bm/DVv9f3wbNQCpAeO7QXasFa7W4sC5Sx3erD4CP5B4cXbujIjl1q4UA0jMWoJ
95DPy22rLwMygHmXCXj8Ai4YFWupxbM8RePJsjdeCWF7lOpnIajE6Y+GBRbZzB7D
ObtxcBvMIAYWxvJ9wA8TPC2r/1Ap2PwZGHsG9ZPNbzECwQyWA5TjIVfZVyniuQGf
KFdKtBNPUh6hM2yznQg=
=w7N6
-----END PGP PRIVATE KEY BLOCK-----
44 changes: 22 additions & 22 deletions pretty_bad_protocol/test/files/test_key_2.pub
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v2
Version: GnuPG v1

mQENBFPcAfMBCADbXmLUb4kYJO1DfKLwmPZ7AFHTqYCFABr2QwMP59llR7VyPU8W
7v9pER/D+IGOQ9Hw/vx9YEcb7qvN5kDBAEwUyU0KjJXrIpsPooAj3YcMHGRwiITV
o40+1ZojGOEAb4+Nos8whYFMT0IOlfaRtUkoUw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