diff options
author | Harsh Shandilya <me@msfjarvis.dev> | 2022-06-14 13:00:54 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-14 07:30:54 +0000 |
commit | d65fc88a149aa543c272f088febf21dad9c55cf8 (patch) | |
tree | c5f1b2c6df2018e2ff22cb7bfd0007568db87ac7 /crypto-common/src | |
parent | 2ba3a086229ac46eb5287716e434b5bd32ea6d2a (diff) |
Reimplement PGPainless encryption logic (#1955)
* crypto-pgpainless: reimplement encryption logic
* crypto-pgpainless: add an explicit error type for empty keyset
Diffstat (limited to 'crypto-common/src')
-rw-r--r-- | crypto-common/src/main/kotlin/dev/msfjarvis/aps/crypto/errors/CryptoException.kt | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/crypto-common/src/main/kotlin/dev/msfjarvis/aps/crypto/errors/CryptoException.kt b/crypto-common/src/main/kotlin/dev/msfjarvis/aps/crypto/errors/CryptoException.kt index aee23710..b795bbf1 100644 --- a/crypto-common/src/main/kotlin/dev/msfjarvis/aps/crypto/errors/CryptoException.kt +++ b/crypto-common/src/main/kotlin/dev/msfjarvis/aps/crypto/errors/CryptoException.kt @@ -37,5 +37,8 @@ public sealed class CryptoHandlerException(message: String? = null, cause: Throw /** The passphrase provided for decryption was incorrect. */ public class IncorrectPassphraseException(cause: Throwable) : CryptoHandlerException(null, cause) +/** No keys were provided for encryption. */ +public class NoKeysProvided(message: String?) : CryptoHandlerException(message, null) + /** An unexpected error that cannot be mapped to a known type. */ public class UnknownError(cause: Throwable) : CryptoHandlerException(null, cause) |