Sample code for 30+ languages & platforms
Xojo Plugin

Example: Crypt2.LastSignerCert method

Demonstrates how to call the LastSignerCert method.

Chilkat Xojo Plugin Downloads

Xojo Plugin
Dim success As Boolean
success = False

Dim crypt As New Chilkat.Crypt2

Dim p7m_path As String
p7m_path = "qa_data/p7m/Firma.docx.p7m"
Dim out_path As String
out_path = "qa_output/Firma.docx"

success = crypt.VerifyP7M(p7m_path,out_path)
If (success = False) Then
    System.DebugLog(crypt.LastErrorText)
    Return
End If

// Examine the certificate(s) used for signing.
Dim numSigners As Int32
numSigners = crypt.NumSignerCerts
Dim i As Int32
i = 0

Dim cert As New Chilkat.Cert

While i < numSigners
    success = crypt.LastSignerCert(i,cert)
    System.DebugLog("Signer: " + cert.SubjectDN)
    i = i + 1
Wend