Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
151 commits
Select commit Hold shift + click to select a range
cbd2fa1
Remove unneeded inheritance on `object`
KOLANICH Nov 3, 2022
1497a55
Replaced old-style `super` with the modern one.
KOLANICH Nov 3, 2022
1aafeb8
Modernized yields into `yield from`
KOLANICH Nov 3, 2022
f66009e
Modernized collections to literal comprehensions syntax
KOLANICH Nov 3, 2022
d342d3f
Got rid of Unicode literals
KOLANICH Nov 24, 2022
2b409f4
Removed unneeded traced of Python 2 related to division
KOLANICH Nov 24, 2022
9e3110d
define more subpacket features
janmojzis Jan 18, 2023
2a37a53
Drop unneccessary duplicate string registrations
dkg Feb 2, 2023
609cb8a
remove more `six` references
ktdreyer May 26, 2023
a3941e0
Tests: Check on forward-compatibility failures
dkg Jun 11, 2023
fb4bea1
Drop unused test_load_ask_bench.py
dkg Feb 11, 2023
d5155d2
tests: Avoid passing naive datetime objects
dkg May 9, 2023
17cb140
Avoid looking for encrypted messages with "Plaintext" encoding
dkg Jun 14, 2023
8e4f7ca
rename setter for EmbeddedSignature._sig (otherwise definition was al…
dkg May 9, 2023
0f8c67d
Drop erroneous SubkeyBindingSignature
dkg May 11, 2023
edd7e4f
handle Armored text with UTF-8 comments
dkg Jun 11, 2023
26e6c37
initial PGPy-backed implementation of sop
dkg Oct 25, 2019
8dabb3a
sop.py: allow instances to augment the interface; provide autocomplete
dkg Oct 25, 2019
1d5e06e
treat keyflags as a set, as expected
dkg Oct 26, 2019
814a65e
use specialized exception for missing options
dkg Oct 26, 2019
adbd3bd
sopgpy: add armor and dearmor subcommands
dkg Oct 27, 2019
820a9fc
indicate each unsupported feature separately for cleaner diffs
dkg Oct 27, 2019
19c7f7e
sopgpy: added --sessionkey to encrypt subcommand
dkg Oct 27, 2019
699f4b0
cleanup and overhaul python sop.py framework
dkg Oct 28, 2019
dad83bc
clean up signature result printing
dkg Oct 28, 2019
48f2cc1
sopgpy: do not try to encrypt with IDEA
dkg Oct 28, 2019
0a64e50
sop decrypt: handle session key and verification output cleanly
dkg Oct 28, 2019
95b635a
Enable easier extension to the sop interface
dkg Oct 28, 2019
d5aaa90
sopgpy: Improve shebang so that we can use virtualenv.
teythoon Oct 29, 2019
6a5f4cd
sopgpy: move to 0.2.0 of python-sop
dkg Nov 8, 2019
b2b861c
PGPy removed __version__ in 0.5.4. This fix relies on python ≥ 3.8
dkg Feb 2, 2022
e0b6b9a
sopgpy: encrypt --sign-with
dkg Feb 2, 2022
0fbb2aa
sopgpy decrypt: handle --verify-with
dkg Feb 2, 2022
65fe736
sopgpy encrypt: implement --with-password
dkg Feb 2, 2022
03c9eae
sopgpy decrypt: implement --with-password
dkg Feb 2, 2022
a1fd82f
sopgpy sign: Raise the correct error when trying to sign non-UTF-8 te…
dkg Feb 2, 2022
60a046e
reported multiple signature problem to PGPy
dkg Feb 2, 2022
e136dd7
sopgpy encrypt: respect --as= argument
dkg Feb 2, 2022
99b839b
Avoid passing a bytes object as a passphrase to pgpy ≤ 0.5.4
dkg Feb 4, 2022
a6eb7db
Bump sopgpy version to 0.2.0
dkg Feb 4, 2022
b5d9886
sopgpy: move _multisig bogus object to its own definition
dkg Aug 24, 2022
112f8f5
sopgpy: drop sop armor's --allow-nested option (deprecated in the spec)
dkg Aug 24, 2022
40aa017
sopgpy: fix decrypt warnings when symmetric decryption fails
dkg Aug 24, 2022
6da28fc
sopgpy: clean up _maybe_armor type definitions
dkg Aug 24, 2022
a727188
sopgpy: clean up tz-naive objects if pgpy emits them (it shouldn't)
dkg Aug 24, 2022
28fc92f
sopgpy: create wrapper that permits a closure to do operations with a…
dkg Aug 24, 2022
6678af8
sopgpy: add sop sign --micalg-out
dkg Aug 24, 2022
6210476
sopgpy: announce backend distinctly from version of sopgpy
dkg Aug 24, 2022
faf8f4e
sopgpy: add sop generate-key --with-key-password
dkg Aug 24, 2022
14d94b7
sopgpy: add --with-key-password to decrypt, sign, and encrypt (when s…
dkg Aug 24, 2022
323b48f
sopgpy: add inline-{detach,sign,verify}
dkg Aug 24, 2022
b7c3192
sopgpy: bump to version 0.3.0 (depends on sop 0.4.0)
dkg Aug 24, 2022
114321b
sopgpy generate-key: improve key password
dkg Nov 7, 2022
8272870
sopgpy: move to PGPy 0.6.0 (sigsubj changes)
dkg Jan 24, 2023
34a35b8
sopgpy: move to PGPy 0.6.0 (from_blob() behavior changes)
dkg Jan 24, 2023
be04b27
sopgpy: change license to match PGPy license. I am the sole author s…
dkg Jun 1, 2023
70601fc
sopgpy: use the PGPy version directly, rather than a distinct sopgpy …
dkg Jun 2, 2023
a2a0621
sopgpy version --extended: add version info about cryptography module…
dkg Jun 2, 2023
02bd731
intentionally distribute sopgpy as part of the module
dkg Jun 2, 2023
4127e47
sopgpy: drop trailing whitespace
dkg Jun 2, 2023
c3090f9
sopgpy: return ArgumentParser for argparse-manpage
dkg Jun 2, 2023
8d071c8
sopgpy: lowercase name to match the command-line name
dkg Jun 3, 2023
d21c5de
use keyword-based arguments when creating SOPSigResult
dkg Jun 8, 2023
773f39b
OPSv3: get the "nested" flag right
dkg May 20, 2023
e0c2ba8
Add PGPSignatures object, representing bundled detached signatures
dkg Jun 11, 2023
f087339
sopgpy: clean up type annotations
dkg Jun 15, 2023
37a741b
sopgpy: use sop 0.5.1 (support profiles)
dkg Jun 15, 2023
cbe16c5
sopgpy generate-key: Add "rfc4880" profile, for 3072-bit RSA keys
dkg Jun 15, 2023
0aa4d68
PEP-8 whitespace cleanup
dkg Jun 16, 2023
a01c66c
Add PubKeyAlgorithm.Unknown
dkg Jun 13, 2023
d38c069
Handle signatures that use an unknown public key algorithm
dkg Jun 12, 2023
0e298a9
Handle subkeys with unknown public key algorithms cleanly
dkg Jun 13, 2023
692eafd
Add PGPSignatures object, representing bundled detached signatures
dkg Jun 11, 2023
d9e1941
use PGPSignatures to handle multi-sig detached signatures
dkg Jun 13, 2023
eb9310a
PGPMessage: ignore opaque packets when assembling
dkg Jun 13, 2023
9d26b2e
PKESKv3: correct packet length consumption when pubkey algorithm is u…
dkg Jun 13, 2023
cdb6347
PKESKv3: handle unknown pubkey algorithms cleanly
dkg Jun 13, 2023
6d78d1b
String2KeyType: introduce "Unknown" option, and note opaque values wh…
dkg Jun 13, 2023
feb4506
Drop the use of pyasn1 for DSA/ECDSA signature translation
dkg May 12, 2023
23ea160
Overhaul EllipticCurveOID (reduce dependencies)
dkg May 13, 2023
a1b1947
HashAlgorithm: treat Unknown explicitly, like PubKeyAlgorithm
dkg Jun 13, 2023
522df3c
When a curve is unknown, treat the EC point as an opaque MPI
dkg Jun 14, 2023
cee0467
PEP-8: whitespace tuneup
dkg Jun 16, 2023
ba04c11
Avoid spurious CryptographyDeprecationWarning
dkg Feb 22, 2023
fb885e6
Fix test: ensure that deprecation warnings don't interfere with test …
dkg Mar 27, 2023
221a1f1
drop use of imghdr
dkg Feb 11, 2023
3227a57
Merge branches 'dont-encrypt-plaintext', 'avoid-naive-datetime', 'cry…
dkg Jun 28, 2023
3150ef4
Merge branch 'compat-tests' into dkg/overhaul
dkg Jun 28, 2023
98b69c2
Merge branch 'sop' into dkg/overhaul
dkg Jun 28, 2023
efa2fed
PGPKey.from_file,from_blob: Drop failed filtering of keyid mapping
dkg Jul 11, 2023
d2dda7d
Merge branch 'cleanup-keylist' into dkg/overhaul
dkg Jul 13, 2023
fd128d6
python cleanup: collections.abc was split out in python 3.3
dkg Mar 16, 2023
55c2ad4
drop __nonzero__ -- 3.x uses __bool__
dkg Feb 10, 2023
0863a7b
drop double export of fingerprint
dkg May 2, 2023
604772d
use functools.singledispatch instead of singledispatch
dkg May 3, 2023
bdcf97e
add an explicit "return None" when selfsig has nothing
dkg May 3, 2023
0fc8fd0
Rename _encrypt and _decrypt to _cfb_encrypt and _cfb_decrypt
dkg Mar 26, 2023
98718cd
PGPKey.encrypt: enumerate optional arguments and type signatures
dkg Mar 26, 2023
cb2e080
Add a handful of type signatures
dkg Mar 26, 2023
1f158e8
SKESK: clarify type signatures for encrypt_sk and decrypt_sk
dkg Feb 15, 2023
34ee5d0
Add type signatures for PKESK.encrypt_sk and PKESK.decrypt_sk
dkg May 2, 2023
b1c0e6e
PKESK: make dynamic arguments lists instead of tuples
dkg May 3, 2023
ef038aa
PGPUID: make regex-matcher more comprehensible to typechecker
dkg May 3, 2023
6565828
Note that __ver__ of a packet is either int or None (unversioned)
dkg May 3, 2023
996c00e
packets.PubKey.fingerprint: property is of type Fingerprint
dkg May 3, 2023
2b906eb
pgpy/types.py: clean up mypy warnings
dkg May 4, 2023
6c372b3
declare FlagList and ByteFlag types as None or some type
dkg May 9, 2023
0d1339d
Tell the typechecker that MPIs, PrivKey, and PubKey can all use varia…
dkg May 9, 2023
de8b582
Use the standard name for a namedtuple to satisfy the typechecker
dkg May 9, 2023
ef04603
PGPSignature: document non-controversial type signatures
dkg May 10, 2023
2df15a0
Add more simple type annotations
dkg May 13, 2023
77c89ea
_cfb_encrypt, _cfb_decrypt: add type signatures
dkg May 10, 2023
ef0cb79
SorteDeque: add type annotations
dkg May 10, 2023
7c63a6c
Add enumerated types for Signature and Attribute subpackets
dkg May 12, 2023
bbac9e8
PEP-8 cleanup (mostly whitespace fiddling)
dkg Jun 15, 2023
56a3dbb
Armorable.ascii_unarmor: clean up type signatures
dkg Jun 15, 2023
b93a2b7
Packet() constructor is safe due to MetaDispatchable, despite Packet …
dkg Jun 15, 2023
9002f31
clean up type checking for CipherTexts
dkg Jun 15, 2023
ea28e87
Clean up type checking for Signatures
dkg Jun 15, 2023
cb6a764
clean up type checking for Key material fields
dkg Jun 15, 2023
b72e316
Test attempts to use EdDSA with anything but Ed25519
dkg May 13, 2023
2f06397
Ensure that IssuerFingerprint subpacket contains None or Fingerprint
dkg Feb 2, 2023
62eee3e
clarify when a key must have a UID
dkg Feb 1, 2023
0d6ec16
drop Backend enum and corresponding default_backend() calls
dkg May 10, 2023
b4e87f3
drop HashAlgorithm.tuned_count (not necessary, we just max out S2K)
dkg May 10, 2023
d7acaeb
Add named S2KUsage enum, in alignment with the new registry in crypto…
dkg May 10, 2023
8b326f2
HashAlgorithm.digest() -- one-off hash from the cryptography module
dkg May 16, 2023
88784cb
Fingerprint: learn its version explicitly
dkg May 10, 2023
cdc4799
Drop all use of hashlib
dkg May 18, 2023
1cd7a38
Move make_onepass to Signature packets
dkg May 18, 2023
878bc48
String2Key: improve type signatures
dkg Jun 16, 2023
6e225cd
Each public key implementation should know what "pubkey algo" it uses
dkg Apr 11, 2023
0bd8c1a
Overhaul dispatch mechanism to use Enums instead of ints
dkg May 12, 2023
86aa055
Drop check for __typeid__.__abstractmethod__
dkg May 11, 2023
64630b4
Consolidate fingerprint-bearing subpackets
dkg May 13, 2023
e3691ae
place KeyFlags ("usage") subpacket in order with other subpackets
dkg Feb 4, 2023
72b77fe
Allow the user to explicitly set `features` flags
dkg Feb 4, 2023
1fe2a14
Ensure feature flags can be placed on Direct Key signatures
dkg Feb 4, 2023
a2c1317
When adding a subpacket to the hashed region, remove it from unhashed
dkg Mar 7, 2023
ff345c1
Create normalized signatures by sorting subpackets by type ID
dkg Mar 7, 2023
3efde16
string representation of subpacket should report when it is critical
dkg Mar 7, 2023
717d240
Make it possible to add a critical subpacket
dkg Mar 7, 2023
fb318ab
Make CreationTime and KeyFlags subpackets critical by default
dkg Mar 7, 2023
bb17b59
when algorithm IDs don't need MPIs, enable a different way to emit them.
dkg Feb 26, 2023
7b83b7e
PGPKey.userids always returns a list of PGPUIDs
dkg May 10, 2023
5755e6d
constants.py: add type annotations
dkg Jun 16, 2023
43db15b
PrivKey._generate should make reasonable choices if params are None
dkg May 13, 2023
5ed3fc4
Deprecate short ID
dkg May 15, 2023
dad51bb
String2Key: auto-generate salt
dkg Jun 17, 2023
7204a64
Correct tests for String2Key
dkg Mar 27, 2023
4c364ab
String2Key: auto-populate iv
dkg Mar 26, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,6 @@ exclude_lines =
# skip abstract methods
@(abc\.)?abstract

# Python 2.x compatibility stuff
if six.PY2:
if six.PY3:
def __nonzero__

# debug-only code
def __repr__

Expand Down
9 changes: 7 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ To install PGPy, simply:

$ pip install PGPy

Command-Line Interface
----------------------

This module will install `sopgpy`, an implementation of the `Stateless OpenPGP Command-line Interface <https://datatracker.ietf.org/doc/draft-dkg-openpgp-stateless-cli/>`_.

Documentation
-------------

Expand All @@ -56,9 +61,9 @@ Requirements

- `Cryptography <https://pypi.python.org/pypi/cryptography>`_

- `pyasn1 <https://pypi.python.org/pypi/pyasn1/>`_
To use `sopgpy` you'll also need:

- `six <https://pypi.python.org/pypi/six>`_
- `sop <https://pypi.org/project/sop/>`_ >= 0.5.1

License
-------
Expand Down
35 changes: 35 additions & 0 deletions docs/source/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,41 @@
Changelog
*********

v0.7.0
======

(not yet released)

Dependency changes
------------------

pyasn1 is no longer needed

Now depends transitively (via the cryptography module) on OpenSSL
1.1.1 or later for Brainpool, X25519, Ed25519.

API additions
-------------

PGPSignatures represents a detached signature, which can contain more
than a single signature. It is a simple sequence of individual
PGPSignature objects.

API changes
-----------

Armorable.is_ascii() is deprecated. You probably want
Armorable.is_utf8() instead, since OpenPGP assumes that all text is
UTF-8.

EllipticCurveOID.Invalid was removed -- EllipticCurveOID only
enumerates supported curves now.

HashAlgorithm.hasher now returns a
cryptography.hazmat.primitives.hashes.Hash object, not a hashlib.HASH
object. The main difference between these interfaces is the use of
finalize() instead of digest().

v0.6.0
======

Expand Down
1 change: 0 additions & 1 deletion gentoo/pgpy-0.4.0.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ IUSE=""
DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]"
RDEPEND="dev-python/singledispatch[${PYTHON_USEDEP}]
dev-python/pyasn1[${PYTHON_USEDEP}]
>=dev-python/six-1.9.0[${PYTHON_USEDEP}]
>=dev-python/cryptography-1.1.0[${PYTHON_USEDEP}]
$(python_gen_cond_dep 'dev-python/enum34[${PYTHON_USEDEP}]' python2_7 python3_3)"
DOCS=( README.rst )
Expand Down
2 changes: 2 additions & 0 deletions pgpy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
from .pgp import PGPKeyring
from .pgp import PGPMessage
from .pgp import PGPSignature
from .pgp import PGPSignatures
from .pgp import PGPUID

__all__ = ['constants',
Expand All @@ -13,4 +14,5 @@
'PGPKeyring',
'PGPMessage',
'PGPSignature',
'PGPSignatures',
'PGPUID', ]
103 changes: 0 additions & 103 deletions pgpy/_curves.py

This file was deleted.

Loading