IPWorks OpenPGP 2020 .NET Edition

Questions / Feedback?

RecipientInfo Event

Fired for each recipient key of the encrypted message.

Syntax

public event OnRecipientInfoHandler OnRecipientInfo;

public delegate void OnRecipientInfoHandler(object sender, PimapRecipientInfoEventArgs e);

public class PimapRecipientInfoEventArgs : EventArgs {
  public string KeyId { get; }
  public string PublicKeyAlgorithm { get; }
}
Public Event OnRecipientInfo As OnRecipientInfoHandler

Public Delegate Sub OnRecipientInfoHandler(sender As Object, e As PimapRecipientInfoEventArgs)

Public Class PimapRecipientInfoEventArgs Inherits EventArgs
  Public ReadOnly Property KeyId As String
  Public ReadOnly Property PublicKeyAlgorithm As String
End Class

Remarks

This event fires when the Decrypt or DecryptAndVerifySignature method is called.

KeyId is the Id of the key used to encrypt the message. If a subkey was used to encrypt the message this will be the Id of that subkey. It is the hex-encoded, 4- or 8-byte Id of the key. It is the same as the last 4 or 8 bytes of the fingerprint. For instance:

BF52A0AB
This can be used to identify the correct key to specify in Keys. Keys can be set from within this event as this event fires directly before the decryption process begins.

Copyright (c) 2022 /n software inc. - All rights reserved.
IPWorks OpenPGP 2020 .NET Edition - Version 20.0 [Build 8249]