documentation
[skip ci]
This commit is contained in:
13
README.rst
13
README.rst
@@ -6,11 +6,11 @@ PGPy: Pretty Good Privacy for Python
|
||||
:alt: Latest stable version
|
||||
|
||||
.. image:: https://travis-ci.org/SecurityInnovation/PGPy.svg?branch=develop
|
||||
:target: https://travis-ci.org/SecurityInnovation/PGPy?branch=develop
|
||||
:target: https://travis-ci.org/SecurityInnovation/PGPy?branch=master
|
||||
:alt: Travis-CI
|
||||
|
||||
.. image:: https://coveralls.io/repos/github/SecurityInnovation/PGPy/badge.png?branch=develop
|
||||
:target: https://coveralls.io/github/SecurityInnovation/PGPy?branch=develop
|
||||
:target: https://coveralls.io/github/SecurityInnovation/PGPy?branch=master
|
||||
:alt: Coveralls
|
||||
|
||||
Homepage: None yet.
|
||||
@@ -38,12 +38,19 @@ Documentation
|
||||
|
||||
`PGPy Documentation <https://pythonhosted.org/PGPy/>`_
|
||||
|
||||
Discussion
|
||||
----------
|
||||
|
||||
Please report any bugs found on the `issue tracker <https://github.com/SecurityInnovation/PGPy/issues>`_
|
||||
|
||||
You can also join ``#pgpy`` on Freenode to ask questions or get involved
|
||||
|
||||
Requirements
|
||||
------------
|
||||
|
||||
- Python 3 >= 3.3; Python 2 >= 2.7
|
||||
|
||||
Tested with: 3.5, 3.4, 3.3, 2.7
|
||||
Tested with: 3.6, 3.5, 3.4, 3.3, 2.7
|
||||
|
||||
- `Cryptography <https://pypi.python.org/pypi/cryptography>`_
|
||||
|
||||
|
||||
@@ -8,16 +8,13 @@ Classes
|
||||
|
||||
.. autoclass:: PGPKey
|
||||
:members:
|
||||
:noindex:
|
||||
|
||||
.. py:attribute:: ascii_header
|
||||
:noindex:
|
||||
:annotation: = OrderedDict([('Version', 'PGPy v|version|')])
|
||||
|
||||
An :py:obj:`~collections.OrderedDict` of headers that appear, in order, in the ASCII-armored form of this object.
|
||||
|
||||
.. py:classmethod:: from_file(filename)
|
||||
:noindex:
|
||||
|
||||
Create a new :py:obj:`PGPKey` object, with contents loaded from a file. May be binary or ASCII armored.
|
||||
|
||||
@@ -32,7 +29,6 @@ Classes
|
||||
# others: { (Fingerprint, bool(key.is_public): PGPKey }
|
||||
|
||||
.. py:classmethod:: from_blob(blob)
|
||||
:noindex:
|
||||
|
||||
Create a new :py:obj:`PGPKey` object, with contents loaded from a blob. May be binary or ASCII armored.
|
||||
|
||||
@@ -55,7 +51,6 @@ Classes
|
||||
:members:
|
||||
|
||||
.. py:attribute:: ascii_header
|
||||
:noindex:
|
||||
|
||||
An :py:obj:`~collections.OrderedDict` of headers that appear, in order, in the ASCII-armored form of this object.
|
||||
|
||||
@@ -67,12 +62,10 @@ Classes
|
||||
:members:
|
||||
|
||||
.. py:attribute:: ascii_header
|
||||
:noindex:
|
||||
|
||||
An :py:obj:`~collections.OrderedDict` of headers that appear, in order, in the ASCII-armored form of this object.
|
||||
|
||||
.. py:classmethod:: from_file(filename)
|
||||
:noindex:
|
||||
|
||||
Create a new :py:obj:`PGPMessage` object, with contents loaded from a file. May be binary or ASCII armored.
|
||||
|
||||
@@ -83,7 +76,6 @@ Classes
|
||||
:returns: :py:obj:`PGPMessage`
|
||||
|
||||
.. py:classmethod:: from_blob(blob)
|
||||
:noindex:
|
||||
|
||||
Create a new :py:obj:`PGPMessage` object, with contents loaded from a blob. May be binary or ASCII armored.
|
||||
|
||||
@@ -102,12 +94,10 @@ Classes
|
||||
:members:
|
||||
|
||||
.. py:attribute:: ascii_header
|
||||
:noindex:
|
||||
|
||||
An :py:obj:`~collections.OrderedDict` of headers that appear, in order, in the ASCII-armored form of this object.
|
||||
|
||||
.. py:classmethod:: from_file(filename)
|
||||
:noindex:
|
||||
|
||||
Create a new :py:obj:`PGPSignature` object, with contents loaded from a file. May be binary or ASCII armored.
|
||||
|
||||
@@ -118,7 +108,6 @@ Classes
|
||||
:returns: :py:obj:`PGPSignature`
|
||||
|
||||
.. py:classmethod:: from_blob(blob)
|
||||
:noindex:
|
||||
|
||||
Create a new :py:obj:`PGPSignature` object, with contents loaded from a blob. May be binary or ASCII armored.
|
||||
|
||||
@@ -8,68 +8,53 @@ Constants
|
||||
|
||||
.. autoclass:: PubKeyAlgorithm
|
||||
:no-members:
|
||||
:noindex:
|
||||
|
||||
.. autoattribute:: RSAEncryptOrSign
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: DSA
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: ElGamal
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: ECDH
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: ECDSA
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
:py:class:`EllipticCurveOID`
|
||||
----------------------------
|
||||
|
||||
.. autoclass:: EllipticCurveOID
|
||||
:noindex:
|
||||
:no-members:
|
||||
|
||||
.. autoattribute:: Curve25519
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Ed25519
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: NIST_P256
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: NIST_P384
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: NIST_P521
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Brainpool_P256
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Brainpool_P384
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Brainpool_P512
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: SECP256K1
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
|
||||
@@ -78,46 +63,35 @@ Constants
|
||||
|
||||
.. autoclass:: SymmetricKeyAlgorithm
|
||||
:no-members:
|
||||
:noindex:
|
||||
|
||||
.. autoattribute:: IDEA
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: TripleDES
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: CAST5
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Blowfish
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: AES128
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: AES192
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: AES256
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Camellia128
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Camellia192
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Camellia256
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
|
||||
@@ -126,22 +100,17 @@ Constants
|
||||
|
||||
.. autoclass:: CompressionAlgorithm
|
||||
:no-members:
|
||||
:noindex:
|
||||
|
||||
.. autoattribute:: Uncompressed
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: ZIP
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: ZLIB
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: BZ2
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
:py:class:`HashAlgorithm`
|
||||
@@ -149,34 +118,26 @@ Constants
|
||||
|
||||
.. autoclass:: HashAlgorithm
|
||||
:no-members:
|
||||
:noindex:
|
||||
|
||||
.. autoattribute:: MD5
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: SHA1
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: RIPEMD160
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: SHA256
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: SHA384
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: SHA512
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: SHA224
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
|
||||
@@ -185,62 +146,47 @@ Constants
|
||||
|
||||
.. autoclass:: SignatureType
|
||||
:no-members:
|
||||
:noindex:
|
||||
|
||||
.. autoattribute:: BinaryDocument
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: CanonicalDocument
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Standalone
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Generic_Cert
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Persona_Cert
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Positive_Cert
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Subkey_Binding
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: PrimaryKey_Binding
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: DirectlyOnKey
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: KeyRevocation
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: SubkeyRevocation
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: CertRevocation
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Timestamp
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: ThirdParty_Confirmation
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
|
||||
@@ -249,34 +195,26 @@ Constants
|
||||
|
||||
.. autoclass:: KeyFlags
|
||||
:no-members:
|
||||
:noindex:
|
||||
|
||||
.. autoattribute:: Certify
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Sign
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: EncryptCommunications
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: EncryptStorage
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Split
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Authentication
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: MultiPerson
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
|
||||
@@ -285,25 +223,19 @@ Constants
|
||||
|
||||
.. autoclass:: RevocationReason
|
||||
:no-members:
|
||||
:noindex:
|
||||
|
||||
.. autoattribute:: NotSpecified
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Superseded
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Compromised
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: Retired
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
.. autoattribute:: UserID
|
||||
:noindex:
|
||||
:annotation:
|
||||
|
||||
@@ -1,9 +0,0 @@
|
||||
Exceptions
|
||||
==========
|
||||
|
||||
.. py:currentmodule:: pgpy.errors
|
||||
|
||||
.. automodule:: pgpy.errors
|
||||
:members:
|
||||
:undoc-members:
|
||||
:noindex:
|
||||
36
docs/source/api/exceptions.rst.inc
Normal file
36
docs/source/api/exceptions.rst.inc
Normal file
@@ -0,0 +1,36 @@
|
||||
Exceptions
|
||||
==========
|
||||
|
||||
.. py:currentmodule:: pgpy.errors
|
||||
|
||||
|
||||
:py:class:`PGPError`
|
||||
--------------------
|
||||
|
||||
.. autoexception:: PGPError
|
||||
|
||||
|
||||
:py:class:`PGPEncryptionError`
|
||||
------------------------------
|
||||
|
||||
.. autoexception:: PGPEncryptionError
|
||||
|
||||
:py:class:`PGPDecryptionError`
|
||||
------------------------------
|
||||
|
||||
.. autoexception:: PGPDecryptionError
|
||||
|
||||
:py:class:`PGPOpenSSLCipherNotSupported`
|
||||
----------------------------------------
|
||||
|
||||
.. autoexception:: PGPOpenSSLCipherNotSupported
|
||||
|
||||
:py:class:`PGPInsecureCipher`
|
||||
-----------------------------
|
||||
|
||||
.. autoexception:: PGPInsecureCipher
|
||||
|
||||
:py:class:`WontImplementError`
|
||||
------------------------------
|
||||
|
||||
.. autoexception:: WontImplementError
|
||||
@@ -2,15 +2,8 @@
|
||||
PGPy API
|
||||
********
|
||||
|
||||
.. toctree::
|
||||
:hidden:
|
||||
.. include:: exceptions.rst.inc
|
||||
|
||||
exceptions
|
||||
constants
|
||||
classes
|
||||
.. include:: constants.rst.inc
|
||||
|
||||
.. include:: exceptions.rst
|
||||
|
||||
.. include:: constants.rst
|
||||
|
||||
.. include:: classes.rst
|
||||
.. include:: classes.rst.inc
|
||||
|
||||
@@ -4,11 +4,18 @@
|
||||
Changelog
|
||||
*********
|
||||
|
||||
v0.5.0
|
||||
v0.4.1
|
||||
======
|
||||
|
||||
Released: |today|
|
||||
|
||||
Bugs Fixed
|
||||
----------
|
||||
* Fixed an issue with dearmoring ASCII-armored PGP blocks with windows-style newlines (#156)
|
||||
* Improved the robustness of the code that tunes the hash count for deriving symmetric encryption keys (#157)
|
||||
* Fixed an issue with how public keys are created from private keys that was causing exports to become malformed (#168)
|
||||
* Added explicit support for Python 3.6 (#166)
|
||||
|
||||
New Features
|
||||
------------
|
||||
* Added support for Brainpool Standard curves for users who have OpenSSL 1.0.2 available
|
||||
|
||||
@@ -24,7 +24,7 @@ Mac OS X
|
||||
|
||||
If you are on Mac OS, you may experience more limited functionality without installing a more capable version of OpenSSL.
|
||||
|
||||
You may refer to Cryptography's documentation on `Using your own OpenSSL on OS X <https://cryptography.io/en/latest/installation/#using-your-own-openssl-on-os-x>`_ for information on how to do so.
|
||||
You may refer to Cryptography's documentation on `Building cryptography on OS X <https://cryptography.io/en/latest/installation/#building-cryptography-on-os-x>`_ for information on how to do so.
|
||||
|
||||
|
||||
Installation
|
||||
|
||||
@@ -284,7 +284,7 @@ This section covers things that are considered extensions to PGP, but are not co
|
||||
- Curve, True, SECP256K1
|
||||
|
||||
.. note:: Use of Brainpool curves with ECDSA/ECDH
|
||||
:text: Although these curves are not explicitly mentioned in an RFC for OpenPGP at this point, GnuPG 2.1.x+ does support using them, so I have included them here as well.
|
||||
Although these curves are not explicitly mentioned in an RFC for OpenPGP at this point, GnuPG 2.1.x+ does support using them, so I have included them here as well.
|
||||
|
||||
\* Cipher availability depends on the currently installed OpenSSL being compiled with support for it
|
||||
|
||||
|
||||
@@ -650,7 +650,7 @@ class Fingerprint(str):
|
||||
"""
|
||||
A subclass of ``str``. Can be compared using == and != to ``str``, ``unicode``, and other :py:obj:`Fingerprint` instances.
|
||||
|
||||
Primarily used as a key for internal dictionaries, so it ignores spaces when comparing and
|
||||
Primarily used as a key for internal dictionaries, so it ignores spaces when comparing and hashing
|
||||
"""
|
||||
@property
|
||||
def keyid(self):
|
||||
|
||||
Reference in New Issue
Block a user