diff options
Diffstat (limited to 'src/leap/mx/vendor/pgpy/errors.py')
-rw-r--r-- | src/leap/mx/vendor/pgpy/errors.py | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/src/leap/mx/vendor/pgpy/errors.py b/src/leap/mx/vendor/pgpy/errors.py new file mode 100644 index 0000000..6af0612 --- /dev/null +++ b/src/leap/mx/vendor/pgpy/errors.py @@ -0,0 +1,39 @@ +""" errors.py +""" + +__all__ = ('PGPError', + 'PGPEncryptionError', + 'PGPDecryptionError', + 'PGPOpenSSLCipherNotSupported', + 'PGPInsecureCipher', + 'WontImplementError',) + + +class PGPError(Exception): + """Raised as a general error in PGPy""" + pass + + +class PGPEncryptionError(Exception): + """Raised when encryption fails""" + pass + + +class PGPDecryptionError(Exception): + """Raised when decryption fails""" + pass + + +class PGPOpenSSLCipherNotSupported(Exception): + """Raised when OpenSSL does not support the requested cipher""" + pass + + +class PGPInsecureCipher(Exception): + """Raised when a cipher known to be insecure is attempted to be used to encrypt data""" + pass + + +class WontImplementError(NotImplementedError): + """Raised when something that is not implemented, will not be implemented""" + pass |