Isis Lovecruft
0c5fda7da4
GnuPG wants pubring for its option '--keyring'. Fuck GnuPG.
2013-04-10 17:22:59 +00:00
Isis Lovecruft
af7e952b42
Factor out some unnecessary string parsing code.
2013-04-10 17:22:09 +00:00
Isis Lovecruft
5fd040c793
Remove extraneous logger statement.
2013-04-10 17:21:11 +00:00
Isis Lovecruft
e978f34712
Add '--secret-keyring' as an allowed option.
2013-04-10 17:20:47 +00:00
Isis Lovecruft
9af49dbce5
Add missing option `--batch` to _allowed options set.
...
* Rearranged the other options because their order was nolens volens.
2013-04-09 17:35:10 +00:00
Isis Lovecruft
f9bd8e928e
Updated documentation and .rst files for Sphinx.
2013-04-06 00:35:40 +00:00
Isis Lovecruft
bb65660586
Add missing super() call in ListKeys class.
2013-04-05 21:28:26 +00:00
Isis Lovecruft
1e4fa9e2f4
Refactor old docstrings to have PEP8 conformant three double quotes.
2013-04-05 21:27:21 +00:00
Isis Lovecruft
53c90f4469
Fix a bug where gpg status message handling did not work for signatures.
...
* If an attempt was made to check a signature and none was found, the
status message would not get handled.
2013-04-02 13:06:46 +00:00
Isis Lovecruft
4d28854feb
Add module name in order to register it in test_gnupg.py.
2013-04-02 12:49:25 +00:00
Isis Lovecruft
4aded0141f
Shorten code for setting keyring paths.
2013-04-02 10:36:55 +00:00
Isis Lovecruft
7840360bb4
General code cleanup.
...
* Move exceptions and global parameters to top of file.
* Move global function to top of file before classes and alphabetise them.
2013-04-02 10:27:26 +00:00
Isis Lovecruft
b8fd74dde3
Change keyring file specification options.
...
* Add DeprecationWarning for gnupg.GPG.keyring parameter, and first steps
towards moving to use gnupg.GPG.secring and pubring instead, because
'keyring' seemed unclear as to which keyring it was referring to.
* Add checks for keyring files, and create them if they are not there.
* Update documentation for gnupg.GPG.__init__().
2013-04-02 10:13:59 +00:00
Isis Lovecruft
c5611782a7
Modify logic for creating path to secret keyring.
2013-04-02 09:31:16 +00:00
Isis Lovecruft
931792cd9b
Fix error where unpermitted variables would remain on a heap.
2013-04-02 08:58:03 +00:00
Isis Lovecruft
d8351e52e9
Change assert to check for bytearray stream rather than file handle.
2013-04-02 05:38:32 +00:00
Isis Lovecruft
4a00a56456
Rearrange the assignment of self.gpghome to go before self.gpgbinary.
2013-03-19 07:14:48 +00:00
Isis Lovecruft
629d13c27c
Reorder checks in gnupg.GPG.__init__() in a more sensible way.
2013-03-18 19:36:30 +00:00
Isis Lovecruft
3c6376a598
Add function _sanitise_list() for sanitising lists of options.
2013-03-18 19:36:30 +00:00
Isis Lovecruft
915a74022a
Fix an error where a list filo would raise an IndexError.
2013-03-18 19:36:30 +00:00
Isis Lovecruft
eaeda9d9a8
Update debugging logging strings.
2013-03-18 19:36:30 +00:00
Isis Lovecruft
618567b1d8
Fix a bug where sometimes sanitised options values were not being added.
2013-03-18 19:36:30 +00:00
Isis Lovecruft
b5f687060c
Deduplicate code assertion checks in GPG.__init__().
2013-03-18 19:36:30 +00:00
Isis Lovecruft
225c05bf58
Add additional allowed options --fingerprint and --with-colons.
2013-03-18 19:36:30 +00:00
Isis Lovecruft
617eb53e57
Apply patch 0001: Make _open_subprocess argument more explicit in _handle_io().
2013-03-18 19:36:30 +00:00
Isis Lovecruft
311ee4b83b
Add unittest for discovery of keyring files.
2013-03-18 19:36:30 +00:00
Isis Lovecruft
b776247176
Cleanup the docstring and code in gnupg.GPG.list_keys().
2013-03-18 19:36:30 +00:00
Isis Lovecruft
608efaf60a
Rewrite method gnupg.GPG.make_args() to use lists for _sanitise().
2013-03-18 19:36:30 +00:00
Isis Lovecruft
a7940e3c84
Rewrite checks in gnupg.GPG.__init__().
2013-03-18 19:36:30 +00:00
Isis Lovecruft
852a0fae97
Rewrite function _sanitise().
2013-03-18 19:36:29 +00:00
Isis Lovecruft
7ac7af9bcb
Update list of allowed gpg options.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
b35309e73f
Update docstrings in several functions.
...
* Including updates to:
_underscore()
_hyphenate()
_is_allowed()
2013-03-18 19:36:29 +00:00
Isis Lovecruft
058c6f6ca8
Change _is_file to return booleans and never raise anything.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
babff61ec2
Shorten assertion string in gnupg.GPG.__init__().
2013-03-18 19:36:29 +00:00
Isis Lovecruft
ed63f622a1
Change logger messages in gnupg.GPG.sign() to be at the debug level.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
601dbb0dd0
Set parameter args in gnupg.GPG.make_args() to None by default.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
45cb40c8b1
Only process safe_args in gnupg.GPG.__init__() as a dict if it is one.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
c0265943e2
Create stricter checks on which gpg binary to call.
...
* Update documentation for gnupg.GPG.__init__().
2013-03-18 19:36:29 +00:00
Isis Lovecruft
3784f0469b
Remove trailing whitespace in function _sanitise().
2013-03-18 19:36:29 +00:00
Isis Lovecruft
c477033506
Change function _is_allowed() to check one option at a time.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
72b74d1960
Fix the _allowed frozenset to work with _hyphenate option string formatting.
...
* Change assertion checks to reflect the changes to _allowed.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
ffe82751b1
Remove vars frozenset from _is_allowed() because it is unnecessary.
...
* Using _allowed and _possible frozensets to store gpg options and flags instead.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
260814f939
Add class UsageError for future devs who incorrectly add feature sets.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
0af1c84fa6
Switch back to setting gnupg.GPG class as self.gpg.
...
* The doctests in test_gnupg.py require this, and it would be more work to change,
so just leave it as it was for now.
* Update documentation for the _which() function.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
745a581fea
Fix problem of attempting to sanitise non-existent options.
2013-03-18 19:36:29 +00:00
Isis Lovecruft
01861c03da
Change variable names in GPG.__init__().
2013-03-18 19:36:29 +00:00
Isis Lovecruft
f2fd09490c
Sanitise input parameters in function GPG.make_args().
2013-03-18 19:36:29 +00:00
Isis Lovecruft
a58f4b0492
Add function _hyphenate().
2013-03-18 19:36:29 +00:00
Isis Lovecruft
845ac96de8
Sanitise input 'options' to GPG.__init__().
2013-03-18 19:36:29 +00:00
Isis Lovecruft
a228c91fa7
Fix variable names in assertions in GPG.__init__().
2013-03-18 19:36:29 +00:00