Class EncryptionResult
java.lang.Object
org.pgpainless.encryption_signing.EncryptionResult
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic EncryptionResult.Builder
builder()
Create a builder for the encryption result class.Return the compression algorithm that was used to compress the message before encryption/signing.MultiMap<SubkeyIdentifier,
org.bouncycastle.openpgp.PGPSignature> Return aMultiMap
of key identifiers and detached signatures that were generated for the message.Return the symmetric encryption algorithm used to encrypt the message.Return the encoding format of the encrypted/signed data.Return the file name of the encrypted/signed data.Return the modification date of the encrypted/signed file.Return the set of recipient encryption keys.boolean
isEncryptedFor
(org.bouncycastle.openpgp.PGPPublicKeyRing certificate) Returns true, if the message was encrypted for at least one subkey of the given certificate.boolean
Return true, if the message is marked as for-your-eyes-only.
-
Method Details
-
getEncryptionAlgorithm
Return the symmetric encryption algorithm used to encrypt the message.- Returns:
- symmetric encryption algorithm
-
getCompressionAlgorithm
Return the compression algorithm that was used to compress the message before encryption/signing.- Returns:
- compression algorithm
-
getDetachedSignatures
Return aMultiMap
of key identifiers and detached signatures that were generated for the message. Each key of the map represents a signing key, which has one or more detached signatures associated with it.- Returns:
- detached signatures
-
getRecipients
Return the set of recipient encryption keys.- Returns:
- recipients
-
getFileName
Return the file name of the encrypted/signed data.- Returns:
- filename
-
getModificationDate
Return the modification date of the encrypted/signed file.- Returns:
- modification date
-
getFileEncoding
Return the encoding format of the encrypted/signed data.- Returns:
- encoding format
-
isForYourEyesOnly
public boolean isForYourEyesOnly()Return true, if the message is marked as for-your-eyes-only. This is typically done by setting the filename "_CONSOLE".- Returns:
- is message for your eyes only?
-
isEncryptedFor
public boolean isEncryptedFor(org.bouncycastle.openpgp.PGPPublicKeyRing certificate) Returns true, if the message was encrypted for at least one subkey of the given certificate.- Parameters:
certificate
- certificate- Returns:
- true if encrypted for 1+ subkeys, false otherwise.
-
builder
Create a builder for the encryption result class.- Returns:
- builder
-