SmimeResultDecryptedMessage Property
Gets a reference to the decrypted message.

Namespace: MailBee.Security
Assembly: MailBee.NET (in MailBee.NET.dll) Version: 12.6.0 build 690 for .NET 4.5
Syntax
public MailMessage DecryptedMessage { get; }

Property Value

Type: MailMessage
A reference to the decrypted message (or to the source message if it was not encrypted), or a null reference (Nothing in Visual Basic) if this SmimeResult object was returned by Verify(MailMessage, MessageVerificationFlags, CertificateStore) or Verify2(MailMessage, MessageVerificationFlags, X509Certificate2Collection) method call (see comments below).
Remarks
You should use Decrypt(MailMessage), Decrypt2(MailMessage, X509Certificate2Collection), DecryptAndVerify(MailMessage, MessageVerificationFlags), DecryptAndVerify2(MailMessage, MessageVerificationFlags, X509Certificate2Collection, X509Certificate2Collection) methods or their overloads to get SmimeResult object with DecryptedMessage property set.
Note Note
There is a case when Verify(MailMessage, MessageVerificationFlags, CertificateStore)/Verify2(MailMessage, MessageVerificationFlags, X509Certificate2Collection) methods and their overloads can still return non-null value for a messsage which is not encrypted but opaque-signed (so-called attached signature when the message and its signature are encoded in a single "smime.p7m" attachment). Such messages look almost the same as encrypted ones. In this case, MailBee not just verifies the signature but also sets DecryptedMessage property with the decoded message, extracted from "smime.p7m" data.
See Also