Type Definitions

AsciiArmored

Ascii Armored PGP Text Block

Type:
  • String

AutocryptMailHeaders

Type:
  • Object
Properties
NameTypeDescription
autocryptString

the Autocrypt header to process

fromString

the From header

dateString

the Date header

BackupSyncHandler(packet) → {Promise.<undefined, Error>}

Parameters:
NameTypeDescription
packetBackupSyncPacket

object with backup data

Returns:
Type: 
Promise.<undefined, Error>

BackupSyncPacket

Type:
  • Object
Properties
NameTypeDescription
backupAsciiArmored

encrypted key backup as PGP armored message

CssSelector

CSS Selector String

Type:
  • String

DisplayContainer

Type:
  • Object
Properties
NameTypeDescription
errorError

Error object with code and message attribute
error.code = 'DECRYPT_ERROR' - generic decrypt error
error.code = 'ARMOR_PARSE_ERROR' - error while parsing the armored message
error.code = 'PWD_DIALOG_CANCEL' - user canceled password dialog
error.code = 'NO_KEY_FOUND' - no private key found to decrypt this message

DisplayContainerOptions

Type:
  • Object
Properties
NameTypeDescription
senderAddressString

email address of sender, used to indentify key for signature verification

DownloadSyncHandler(downloadObj) → {Promise.<DownloadSyncReply, Error>}

Parameters:
NameTypeDescription
downloadObjObject

meta info for download

Properties
NameTypeDescription
eTagString

entity tag for the current local keyring, or null if no local eTag

Returns:
  • if version on server has same eTag, then keyringMsg property of reply is empty, but eTag in reply has to be set
    if server is initial and downloadObj.eTag is not null, then the promise is resolved with empty eTag
Type: 
Promise.<DownloadSyncReply, Error>

DownloadSyncReply

Type:
  • Object
Properties
NameTypeDescription
keyringMsgAsciiArmored

encrypted keyring as PGP armored message, or null if no newer version available

eTagString

entity tag for the current encrypted keyring message, or null if server is intial

EditorContainerOptions

Type:
  • Object
Properties
NameTypeDescription
quotanumber

mail content (text + attachments) limit in kilobytes (default: 20480)

signMsgboolean

if true then the mail will be signed (default: false)

armoredDraftAsciiArmored

a PGP message, signed and encrypted with the default key of the user, will be used to restore a draft in the editor
The armoredDraft parameter can't be combined with the parameters: predefinedText, quotedMail... parameters, keepAttachments

predefinedTextString

text that will be added to the editor

quotedMailAsciiArmored

mail that should be quoted

quotedMailIndentboolean

if true the quoted mail will be indented (default: true)

quotedMailHeaderString

header to be added before the quoted mail

keepAttachmentsboolean

add attachments of quotedMail to editor (default: false)

KeyBackupContainerOptions

Type:
  • Object
Properties
NameTypeDescription
initialSetupBoolean

(default: true)

KeyGenContainerOptions

Type:
  • Object
Properties
NameTypeDescription
userIdsArray.<UserId>

array of user IDs. The first entry in the array is set as the primary user ID.

keySizenumber

key size in bit, optional, default: 2048, valid values: 2048, 4096.

LookupResult

Type:
  • Object
Properties
NameTypeAttributesDescription
fingerprintString

Fingerprint of the key

lastModifiedDate

last time the key was modified

sourceString

Source the key was found at

Currently available:

* 'LOC' - local key ring

* 'WKD' - web key directory

* 'MKS' - mailvelope key server

* 'OKS' - keys.openpgp.org

* 'AC' - autocrypt

lastSeenDate<optional>

last time the key was seen

(not set for local keys)

armoredString<optional>

Armored key that can be imported

(not set for local keys)

OpenSettingsOptions

Type:
  • Object
Properties
NameTypeDescription
showDefaultKeyBoolean

(default: false)

PrivateKeyContainerOptions

Type:
  • Object
Properties
NameTypeDescription
restorePasswordboolean

(default: false)

RestoreSyncHandler() → {Promise.<BackupSyncPacket, Error>}

Returns:
Type: 
Promise.<BackupSyncPacket, Error>

SettingsContainerOptions

Type:
  • Object
Properties
NameTypeDescription
emailString

the email address of the current user

fullNameString

the full name of the current user

SyncHandlerObject

Type:
  • Object
Properties
NameTypeDescription
uploadSyncUploadSyncHandler

function called by Mailvelope to upload the keyring (public keys), the message is encrypted with the default private key

downloadSyncDownloadSyncHandler

function called by Mailvelope to download the encrypted keyring (public keys)

backupBackupSyncHandler

function called by Mailvelope to upload a symmetrically encrypted private key backup

restoreRestoreSyncHandler

function called by Mailvelope to restore a private key backup

UploadSyncHandler(uploadObj) → {Promise.<UploadSyncReply, Error>}

Parameters:
NameTypeDescription
uploadObjObject

object with upload data

Properties
NameTypeDescription
eTagString

entity tag for the uploaded encrypted keyring, or null if initial upload

keyringMsgAsciiArmored

encrypted keyring as PGP armored message

Returns:
  • if version on server has different eTag, then the promise is rejected
    if server is initial and uploadObj.eTag is not null, then the promise is rejected
Type: 
Promise.<UploadSyncReply, Error>

UploadSyncReply

Type:
  • Object
Properties
NameTypeDescription
eTagString

entity tag for the uploaded encrypted keyring

UserId

Type:
  • Object
Properties
NameTypeDescription
emailString

the email address of the current user

fullNameString

the full name of the current user

additionalMailHeaders

Type:
  • Object
Properties
NameTypeDescription
autocryptString

the Autocrypt header that should be

added to the outgoing mail

outgoingMailHeaders

Type:
  • Object
Properties
NameTypeDescription
fromString

the From header