ANN: A new version (0.4.0) of python-gnupg has been released.
vinay_sajip at yahoo.co.uk
Sun Jan 29 13:53:44 EST 2017
A new version of the Python module which wraps GnuPG has been released.
This is an enhancement and bug-fix release, and all users are encouraged to upgrade.
See the project website  for more information.
* Added support for ``KEY_CONSIDERED`` in more places - encryption /
decryption, signing, key generation and key import.
* Partial fix for #32 (GPG 2.1 compatibility). Unfortunately, better
support cannot be provided at this point, unless there are certain
changes (relating to pinentry popups) in how GPG 2.1 works.
* Fixed #60: An IndexError was being thrown by ``scan_keys()``.
* Ensured that utf-8 encoding is used when the ``--with-column`` mode is
used. Thanks to Yann Leboulanger for the patch.
* ``list_keys()`` now uses ``--fixed-list-mode``. Thanks to Werner Koch
for the pointer.
This release  has been signed with my code signing key:
Vinay Sajip (CODE SIGNING KEY) <vina... at yahoo.co.uk>
Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86
What Does It Do?
The gnupg module allows Python programs to make use of the
functionality provided by the Gnu Privacy Guard (abbreviated GPG or
GnuPG). Using this module, Python programs can encrypt and decrypt
data, digitally sign documents and verify digital signatures, manage
(generate, list and delete) encryption keys, using proven Public Key
Infrastructure (PKI) encryption technology based on OpenPGP.
This module is expected to be used with Python versions >= 2.4, as it
makes use of the subprocess module which appeared in that version of
Python. This module is a newer version derived from earlier work by
Andrew Kuchling, Richard Jones and Steve Traugott.
A test suite using unittest is included with the source distribution.
>>> import gnupg
>>> gpg = gnupg.GPG(gnupghome='/path/to/keyring/directory')
'uids': ['', 'Gary Gross (A test user) <gary.gr... at gamma.com>']},
'uids': ['', 'Danny Davis (A test user) <danny.da... at delta.com>']}]
>>> encrypted = gpg.encrypt("Hello, world!", ['0C5FEFA7A921FC4A'])
'-----BEGIN PGP MESSAGE-----\nVersion: GnuPG v1.4.9 (GNU/Linux)\n
-----END PGP MESSAGE-----\n'
>>> decrypted = gpg.decrypt(str(encrypted), passphrase='secret')
>>> signed = gpg.sign("Goodbye, world!", passphrase='secret')
>>> verified = gpg.verify(str(signed))
>>> print "Verified" if verified else "Not verified"
As always, your feedback is most welcome (especially bug reports ,
patches and suggestions for improvement, or any other points via the
mailing list/discussion group ).
Red Dove Consultants Ltd.
More information about the Python-announce-list