Isis Lovecruft
0785d7dd3b
Various docstring and whitespace fixes in parsers.py.
2013-05-11 18:28:04 +00:00
Isis Lovecruft
cc7beb7185
Rewrite GPG.decrypt_file().
2013-05-11 18:26:14 +00:00
Isis Lovecruft
cfd7b38242
Add option to delete subkeys with GPG.delete_keys().
...
* TODO this needs unittests.
2013-05-11 18:25:17 +00:00
Isis Lovecruft
ae0ab0a7c7
WHO PUTS UNITTESTS IN A TRY/EXCEPT BLOCK WHICH CATCHES ALL EXCEPTIONS?!
...
* WHAT WAS THE POINT OF WRITING THE UNITTEST IF IT ALWAYS PASSES?
2013-05-11 18:22:50 +00:00
Isis Lovecruft
347cecb9f2
Add unittests for multiparty file en/decryption and symmetric en/decryption.
2013-05-11 18:22:07 +00:00
Isis Lovecruft
23b3315c45
Remove old logger statements and comments.
2013-05-11 18:20:49 +00:00
Isis Lovecruft
b76bf502c9
Add better unittests for homedir and keyring creation.
2013-05-11 18:19:59 +00:00
Isis Lovecruft
f06c2d7396
Cleanup docstring for GPGTestCase.setUpClass().
2013-05-11 18:19:04 +00:00
Isis Lovecruft
2a92e3f10b
Since we use '--no-emit-version', we don't need this anymore.
2013-05-11 18:18:18 +00:00
Isis Lovecruft
d38efaffbc
Use proper tempfile isolation of GnuPG homedirs in unittests.
2013-05-11 18:17:22 +00:00
Isis Lovecruft
14ffe14569
Add a unittest and a fix for hexidecimal inputs with lowercase.
2013-05-11 18:16:18 +00:00
Isis Lovecruft
dce4b4a226
Rename handle_status() parser methods to be private to cleanup the API.
2013-05-11 18:10:41 +00:00
Isis Lovecruft
38057cfe1c
Add various new options and assign input parsers to them.
2013-05-11 18:09:33 +00:00
Isis Lovecruft
e4f2d533b1
Add cipher, compress, and digest preferences and rename parameters.
...
* Rename gpghome to homedir.
* Rename gpgbinary to binary.
* Add setting to append '--no-use-agent' to the command string in an attempt
to overcome bugs resulting on systems where the user has gpg-agent running
in the background (with some configurations, this is run before X is
started, and killing the agent can result in X dying) and GnuPG tries to
call the program specified by the symlink at /usr/bin/pinentry, result in
encryption and decryption failing due to the '--batch' option blasting
through pinentry without input. This results in a complaint from GnuPG:
gpg: Sorry, no terminal at all requested - can't get input
This bug also prevents symmetric encryption/decryption from working in a
similar manner.
Daniel Kahn Gilmor's monkeysphere, if I am recalling correctly, has a
hack to remove the $DISPLAY variable from the users environment, and then
add it back in, but frankly this option frightens me, as unsetting the
display could result in all X applications failing.
Werner Koch's suggestions, from the gnupg-devel mailing list are:
http://lists.gnupg.org/pipermail/gnupg-users/2007-April/030927.html
And, for the record, '--no-use-agent' doesn't disable pinentry.
2013-05-11 18:03:41 +00:00
Isis Lovecruft
7779a87fac
Ignore socket configuration files for emacs.
2013-05-11 17:33:09 +00:00
Isis Lovecruft
458b8a4c2c
Remove unused logger statement.
2013-05-11 14:48:45 +00:00
Isis Lovecruft
adaf53c256
Fix a call in a unittest to _make_binary_stream() to call the correct module.
2013-05-11 08:55:47 +00:00
Isis Lovecruft
79bf77a185
Update test_import_and_export() unittest with newer key generation utility.
2013-05-11 08:54:17 +00:00
Isis Lovecruft
6c87679e7e
Fix a bug in two unittests caused by a method not having been renamed.
2013-05-11 08:53:12 +00:00
Isis Lovecruft
ed2bc4d882
Split the old test_encryption_and_decryption() up into several smaller tests.
2013-05-11 08:51:48 +00:00
Isis Lovecruft
228cec9533
Add all available key fields for GPG.gen_key_input to the docstring.
2013-05-11 08:49:37 +00:00
Isis Lovecruft
863ad194a5
Cleanup indentation style a bit.
2013-05-11 08:48:39 +00:00
Isis Lovecruft
b562a346ff
Fix typo in docstring.
2013-05-11 08:48:12 +00:00
Isis Lovecruft
a7afce0394
Add a testing mode to GPG.gen_key_input() which uses insecure PRNG.
...
* This should only be used in the unittests, as the PRNG it uses in GnuPG does
not create strong keypairs (though it's faster, thus why we're using it for
testing).
2013-05-11 08:43:33 +00:00
Isis Lovecruft
f95c3c7c1e
Remove old TODO comment.
2013-05-10 09:50:56 +00:00
Isis Lovecruft
d392265101
Fix two bugs, one due to an extra pair of quotes, the other due to strformat.
2013-05-10 09:45:39 +00:00
Isis Lovecruft
b66fc4ca82
Add subkey support and a docstring to GPG.export_keys().
2013-05-10 09:44:07 +00:00
Isis Lovecruft
55185d528b
Separate options into tidy groups so that the parser handles them efficiently.
2013-05-10 09:42:30 +00:00
Isis Lovecruft
fdaadcbd20
Fix a bug due to calling a GnuPG option which was removed several versions ago.
2013-05-10 09:40:36 +00:00
Isis Lovecruft
5d0e45170f
Add a docsting for GPG.delete_keys().
2013-05-10 09:39:40 +00:00
Isis Lovecruft
58300c3149
Enable all tests in the Makefile.
...
* To run tests, it is necessary -- due to the module structure -- to do:
$ make uninstall && make install && make test
which is recommended to do in a virtualenv, or similar such isolated testing
environment.
2013-05-10 09:34:46 +00:00
Isis Lovecruft
04a79a2802
Remove the version string from generated keys, encrypted files, and sigs.
2013-05-10 09:33:07 +00:00
Isis Lovecruft
ce323251ed
Fix a bug due to the _py3k check being moved to the utils module.
2013-05-09 19:14:52 +00:00
Isis Lovecruft
2114033c3a
Add distribute_setup.py script.
2013-05-07 15:01:22 +00:00
Isis Lovecruft
df0b4c7a34
Add pip installation update script to make sure we use SSL for downloads.
2013-05-07 14:23:34 +00:00
Isis Lovecruft
0462e8509c
Move TODO file to docs/ subfolder.
2013-05-14 11:10:45 +00:00
Isis Lovecruft
0c0f0c069a
Move LICENSE file to docs/ subfolder.
2013-05-14 11:08:18 +00:00
Isis Lovecruft
158499da35
Add setuptools-git as a dependency.
...
* TODO find a way to only require setuptools-git if python-gnupg was checked
out from a git repo.
2013-05-28 11:04:52 +00:00
Isis Lovecruft
a5c0f8f1cf
Add setuptools directive to include PKG-INFO.
2013-05-28 11:01:13 +00:00
Isis Lovecruft
694ae87410
sign_with → default_key. Also, deduplicate code.
2013-05-28 11:00:13 +00:00
Isis Lovecruft
4bd45d06cd
Update docstring for GPGBase._homedir_getter() property.
2013-05-28 10:18:43 +00:00
Isis Lovecruft
15d4bc0eb4
Fix a bug resulting from a typo in the @atexit.register'd function.
2013-05-28 10:17:43 +00:00
Isis Lovecruft
b7ba572aa1
Update docstring for GPGBase.__remove_path__().
2013-05-28 10:17:08 +00:00
Isis Lovecruft
7129a4c85f
Update docstring for GPGBase._find_agent().
2013-05-28 10:15:51 +00:00
Isis Lovecruft
6a47c3cd77
Move several methods and attributes from GPG to GPGBase.
...
* Move _decode_errors
* Move _result_map
* Move _copy_data()
* Move _read_data()
* Move _read_response()
* Move _make_args()
* Move _open_subprocess()
* Move _collect_output()
* Move _handle_io()
2013-05-28 10:12:01 +00:00
Isis Lovecruft
8e2f905859
handle_status() → _handle_status() in _parsers.py and gnupg.py.
2013-05-28 09:24:06 +00:00
Isis Lovecruft
cacedc6242
self.gpg → self._gpg in _parsers.py.
2013-05-28 09:18:58 +00:00
Isis Lovecruft
d910a48660
GPG.filesystemencoding → GPG._filesystemencoding
2013-05-28 08:52:49 +00:00
Isis Lovecruft
87ced52f85
GPG.encoding → GPG._encoding
2013-05-28 08:48:36 +00:00
Isis Lovecruft
5b731736fe
Remove duplicate attribute primary_key_created from GenKey.
2013-05-28 08:42:03 +00:00