SecureBlackbox 2020 iOS Edition

Questions / Feedback?

MailWriter Class

Properties   Methods   Events   Configuration Settings   Errors  

The MailWriter class composes, encrypts, and signs e-mail messages.

Syntax

SecureBlackboxMailWriter
SecureBlackboxMailWriterSwift

Remarks

Use MailWriter to compose, sign, and encrypt e-mail messages, and prepare them for sending or saving.

Property List


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

- attachEncodingThe encoding to be applied to the attachments.
- attachCountThe number of records in the Attach arrays.
- attachContentSubtype:(int)attachIndexContains the content subtype of the attachment.
- attachContentType:(int)attachIndexContain the content type of the attachment.
- attachCreationDate:(int)attachIndexThe creation date.
- attachData:(int)attachIndexThe content of the attachment.
- attachDescription:(int)attachIndexTextual description of the attachment.
- attachFilename:(int)attachIndexSpecifies the name of the attachment file.
- attachID:(int)attachIndexContains the attachment's unique identifier.
- attachModificationDate:(int)attachIndexSpecifies the date and time of the file's last modification.
- attachReadDate:(int)attachIndexSpecifies the file's last read date.
- attachSize:(int)attachIndexAttachment's size in bytes.
- bccAddrCountThe number of records in the BccAddr arrays.
- bccAddrAddress:(int)bccAddrIndexContains the e-mail address in the form of john@doe.
- bccAddrDisplayName:(int)bccAddrIndexContains the friendly name of the user of this address, such as John Doe.
- bccAddrGroupName:(int)bccAddrIndexThe name of the group this address belongs to.
- ccAddrCountThe number of records in the CcAddr arrays.
- ccAddrAddress:(int)ccAddrIndexContains the e-mail address in the form of john@doe.
- ccAddrDisplayName:(int)ccAddrIndexContains the friendly name of the user of this address, such as John Doe.
- ccAddrGroupName:(int)ccAddrIndexThe name of the group this address belongs to.
- charsetThe charset to apply to Message .
- encryptionCertCountThe number of records in the EncryptionCert arrays.
- encryptionCertBytes:(int)encryptionCertIndexReturns raw certificate data in DER format.
- encryptionCertHandle:(int)encryptionCertIndexAllows to get or set a 'handle', a unique identifier of the underlying property object.
- 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.
- fromAddrCountThe number of records in the FromAddr arrays.
- fromAddrAddress:(int)fromAddrIndexContains the e-mail address in the form of john@doe.
- fromAddrDisplayName:(int)fromAddrIndexContains the friendly name of the user of this address, such as John Doe.
- fromAddrGroupName:(int)fromAddrIndexThe name of the group this address belongs to.
- headerEncodingThe encoding to be applied to the message header.
- mailerThe name of the software used to compose and/or send the message.
- msgAttachmentCountReturns the number of attachments in this message.
- msgBccThe contents of the BCC header property.
- msgCcThe value of the CC header property.
- msgCommentsContains additional information about the message body.
- msgDateThe date and time when the message entered the mail delivery system.
- msgDeliveryReceiptEnables delivery notification.
- msgFromContains the value of the From header property.
- msgHtmlTextThe HTML version of the message.
- msgIDThe contents of the Message-ID header property.
- msgInReplyToThe value of the In-Reply-To header property.
- msgKeywordsThe value of the Keywords header property.
- msgMailerThe name of the software that was used to send the message.
- msgPlainTextThe plain text version of the message.
- msgPrioritySpecifies the message priority.
- msgReadReceiptEnables a read notification.
- msgReferencesThe value of the References header property.
- msgReplyToThe value of the Reply-To header property.
- msgReturnPathThe value of the Return-Path header property.
- msgSenderThe value of the Sender header property.
- msgSendToThe value of the To header property.
- msgSubjectContains the subject property of this message.
- headerFieldCountThe number of records in the HeaderField arrays.
- headerFieldName:(int)headerFieldIndexThe name element in a (name, value) pair.
- headerFieldValue:(int)headerFieldIndexThe value element in a (name, value) pair.
- profileSpecifies a pre-defined profile to apply when creating the signature.
- replyToAddrCountThe number of records in the ReplyToAddr arrays.
- replyToAddrAddress:(int)replyToAddrIndexContains the e-mail address in the form of john@doe.
- replyToAddrDisplayName:(int)replyToAddrIndexContains the friendly name of the user of this address, such as John Doe.
- replyToAddrGroupName:(int)replyToAddrIndexThe name of the group this address belongs to.
- secSettingsClaimedSigningTimeSpecifies the signing time from the signer's computer.
- secSettingsEncryptWhether to encrypt the message.
- secSettingsEncryptionAlgorithmSpecifies the encryption algorithm to be used.
- secSettingsHashAlgorithmSpecifies the hash algorithm to be used.
- secSettingsSignWhether to sign the message.
- secSettingsSignatureFormatSpecifies the signature format to use for the signed message.
- secSettingsSignBeforeEncryptSpecifies the order of encryption and signing operations.
- secSettingsSignMessageHeaderSpecifies whether to include the message header in the signature calculation.
- senderAddrAddressContains the e-mail address in the form of john@doe.
- senderAddrDisplayNameContains the friendly name of the user of this address, such as John Doe.
- senderAddrGroupNameThe name of the group this address belongs to.
- sendToAddrCountThe number of records in the SendToAddr arrays.
- sendToAddrAddress:(int)sendToAddrIndexContains the e-mail address in the form of john@doe.
- sendToAddrDisplayName:(int)sendToAddrIndexContains the friendly name of the user of this address, such as John Doe.
- sendToAddrGroupName:(int)sendToAddrIndexThe name of the group this address belongs to.
- signingCertBytesReturns raw certificate data in DER format.
- signingCertHandleAllows to get or set a 'handle', a unique identifier of the underlying property object.
- signingChainCountThe number of records in the SigningChain arrays.
- signingChainBytes:(int)signingChainIndexReturns raw certificate data in DER format.
- signingChainHandle:(int)signingChainIndexAllows to get or set a 'handle', a unique identifier of the underlying property object.
- textEncodingThe encoding to be applied to the message.

Method List


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

- attachBytesCreates an attachment from a memory buffer.
- attachFileCreates an attachment from a file.
- attachImageCreates an image attachment from a memory buffer.
- configSets or retrieves a configuration setting.
- saveToBytesSerializes the message to a byte array.
- saveToFileSerializes the message to a file.

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.

- onErrorReports information about errors during e-mail message assembling or saving.
- onExternalSignHandles remote or external signing initiated by the SignExternal method or other source.
- onNotificationThis event notifies the application about an underlying control flow event.

Configuration Settings


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

BitsInKeyKey length for the block cipher used for encryption. The value should be a multiple of 8.
IncludeSigningCertificateIf true (by default), the signing certificate is included into the signature. Otherwise, it is included only if SigningChain is not empty.
TempPathPath for storing temporary files.
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 8165]