Part.openpgpEncrypt

Encrypts (and optionally signs) the content of the mime_part and then replaces the content with the new, encrypted, content.

class Part
bool
openpgpEncrypt

Parameters

sign bool

true if the content should also be signed; otherwise, false

userid string

the key id (or email address) to use when signing (assuming sign is true)

flags gmime.types.EncryptFlags

a set of #GMimeEncryptFlags

recipients string[]

an array of recipient key ids and/or email addresses

Return Value

Type: bool

true on success or false on error.

Throws