SecureBlackbox 2020 iOS Edition

Questions / Feedback?

PGPReader Class

Properties   Methods   Events   Configuration Settings   Errors  

The PGPReader class reads and unprotects protected PGP files.

Syntax

SecureBlackboxPGPReader
SecureBlackboxPGPReaderSwift

Remarks

PGPReader allows you to parse PGP messages and manipulate PGP-secured data. It decrypts the protected data, decompresses it, verifies signatures, and returns "clear" data.

Property List


The following is the full list of the properties of the class with short descriptions. Click on the links for further details.

- armoredIndicates if the processed message had been base64-armored.
- compressedIndicates if the processed message had been compressed.
- decryptingKeyCountThe number of records in the DecryptingKey arrays.
- decryptingKeyHandle:(int)decryptingKeyIndexAllows to get or set a 'handle', a unique identifier of the underlying property object.
- decryptingKeyKeyFP:(int)decryptingKeyIndexThe 20-byte fingerprint (hash value) of this key.
- decryptingKeyKeyID:(int)decryptingKeyIndexContains a 8-byte key identifier.
- decryptingKeyPassphrase:(int)decryptingKeyIndexThe key protection password.
- decryptingKeyPassphraseValid:(int)decryptingKeyIndexUse this property to check whether the specified Passphrase is valid and can be used to unlock the secret key.
- decryptingKeyUsername:(int)decryptingKeyIndexSpecifies the name of the user bound to this key.
- externalCryptoCustomParamsCustom parameters to be passed to the signing service (uninterpreted).
- externalCryptoDataAdditional data to be included in the async state and mirrored back by the requestor.
- externalCryptoExternalHashCalculationSpecifies whether the message hash is to be calculated at the external endpoint.
- externalCryptoHashAlgorithmSpecifies the request's signature hash algorithm.
- externalCryptoKeyIDThe ID of the pre-shared key used for DC request authentication.
- externalCryptoKeySecretThe pre-shared key used for DC request authentication.
- externalCryptoMethodSpecifies the asynchronous signing method.
- externalCryptoModeSpecifies the external cryptography mode.
- externalCryptoPublicKeyAlgorithmProvide public key algorithm here if the certificate is not available on the pre-signing stage.
- keyPassphraseSpecifies a passphrase for the decryption key.
- passphraseSpecifies a message decryption password.
- processedLengthReports the number of bytes processed.
- profileSpecifies a pre-defined profile to apply when creating the signature.
- signatureCountThe number of records in the Signature arrays.
- signatureCertificationType:(int)signatureIndexSpecifies the type of a UserID signature.
- signatureCreationTime:(int)signatureIndexThe time when the signature was created, in Universal Coordinated Time (UTC).
- signatureExpirationTime:(int)signatureIndexSpecifies signature expiration time, in seconds since its creation time (CreationTime).
- signatureExportable:(int)signatureIndexSpecifies whether a certification signature is "exportable", meaning it can be used by entities other than the signature's issuer.
- signatureHandle:(int)signatureIndexAllows to get or set a 'handle', a unique identifier of the underlying property object.
- signatureHashAlgorithm:(int)signatureIndexSpecifies the hash algorithm used in the signature.
- signatureKeyExpirationTime:(int)signatureIndexThe number of seconds after which the signed key will expire.
- signatureLegacyFormat:(int)signatureIndexIndicates whether signature uses PGP 2.
- signaturePolicyURL:(int)signatureIndexContains the URL of the signature policy.
- signaturePrimaryUserID:(int)signatureIndexIndicates whether the UserID covered by the signature is the main user id for this key.
- signatureReasonForRevocation:(int)signatureIndexDescribes the reason why the key or the certificate was revoked.
- signatureRevocable:(int)signatureIndexSpecifies whether the signature can be revoked.
- signatureRevocation:(int)signatureIndexIndicates whether or not the signature is a revocation signature.
- signatureSignatureClass:(int)signatureIndexIndicates the signature class.
- signatureSignerKeyID:(int)signatureIndexIndicates the KeyID of the signing key.
- signatureSignerUserID:(int)signatureIndexIndicates the UserID associated with the signing key.
- signatureStrictlyValid:(int)signatureIndexReturns True if this signature is valid in a strict way (no compatibility relaxations).
- signatureTextSignature:(int)signatureIndexIndicates whether or not the signature is made over a text document.
- signatureTrustAmount:(int)signatureIndexSpecifies the amount of trust assigned by this signature.
- signatureTrustLevel:(int)signatureIndexThe trust level assigned by this signature.
- signatureValidated:(int)signatureIndexWhether the signature has been validated.
- signatureValidity:(int)signatureIndexProvides the validity status of the signature if the signature has been validated.
- signatureVersion:(int)signatureIndexIndicates the signature version.
- verifyingKeyCountThe number of records in the VerifyingKey arrays.
- verifyingKeyHandle:(int)verifyingKeyIndexAllows to get or set a 'handle', a unique identifier of the underlying property object.
- verifyingKeyKeyFP:(int)verifyingKeyIndexThe 20-byte fingerprint (hash value) of this key.
- verifyingKeyKeyID:(int)verifyingKeyIndexContains a 8-byte key identifier.
- verifyingKeyUsername:(int)verifyingKeyIndexSpecifies the name of the user bound to this key.

Method List


The following is the full list of the methods of the class with short descriptions. Click on the links for further details.

- configSets or retrieves a configuration setting.
- decryptAndVerifyDecrypts and verifies a protected message.
- decryptAndVerifyFileDecrypts and verifies a protected message.
- decryptAndVerifyStringDecrypts and verifies a protected message.
- verifyDetachedVerifies a detached signature.
- verifyDetachedFileVerifies a detached signature.
- verifyDetachedStringVerifies a detached signature.

Event List


The following is the full list of the events fired by the class with short descriptions. Click on the links for further details.

- onEncryptionInfoReports early information on encryption parameters.
- onErrorInformation about errors during PGP decryption/verification.
- onExternalDecryptHandles remote or external decryption.
- onFileExtractionStartReports the beginning of file extraction process.
- onKeyPassphraseNeededRequests a key protection password from the application.
- onMultipleFilesFoundFires if the PGP message is recognized to contain multiple files.
- onNotificationThis event notifies the application about an underlying control flow event.
- onPassphraseNeededRequests a data protection password from the application.
- onProgressReports the progress of the decryption operation.
- onSignedNotifies the application about a signed message.

Configuration Settings


The following is a list of configuration settings for the class with short descriptions. Click on the links for further details.

IgnoreDataPacketLengthsWhether to check the length of input data packets.
PasswordAttemptsThe number of attempts allowed for entering password.
TempPathPath for storing temporary files.
UndefInputLengthSet this property if you are working with non-seekable streams.
UseGreedyMemoryConsumptionWhether to limit memory consumption for the cost of speed.
CheckKeyIntegrityBeforeUseEnables or disable private key integrity check before use.
CookieCachingSpecifies whether a cookie cache should be used for HTTP(S) transports.
CookiesGets or sets local cookies for the class (supported for HTTPClient, RESTClient and SOAPClient only).
DefDeriveKeyIterationsSpecifies the default key derivation algorithm iteration count.
EnableClientSideSSLFFDHEEnables or disables finite field DHE key exchange support in TLS clients.
GlobalCookiesGets or sets global cookies for all the HTTP transports.
HttpUserAgentSpecifies the user agent name to be used by all HTTP clients.
LogDestinationSpecifies the debug log destination.
LogDetailsSpecifies the debug log details to dump.
LogFileSpecifies the debug log filename.
LogFiltersSpecifies the debug log filters.
LogFlushModeSpecifies the log flush mode.
LogLevelSpecifies the debug log level.
LogMaxEventCountSpecifies the maximum number of events to cache before further action is taken.
LogRotationModeSpecifies the log rotation mode.
MaxASN1BufferLengthSpecifies the maximal allowed length for ASN.1 primitive tag data.
MaxASN1TreeDepthSpecifies the maximal depth for processed ASN.1 trees.
OCSPHashAlgorithmSpecifies the hash algorithm to be used to identify certificates in OCSP requests.
UseOwnDNSResolverSpecifies whether the client classes should use own DNS resolver.
UseSharedSystemStoragesSpecifies whether the validation engine should use a global per-process copy of the system certificate stores.
UseSystemOAEPAndPSSEnforces or disables the use of system-driven RSA OAEP and PSS computations.
UseSystemRandomEnables or disables the use of the OS PRNG.

Copyright (c) 2022 /n software inc. - All rights reserved.
SecureBlackbox 2020 iOS Edition - Version 20.0 [Build 8166]