Encrypt an XML document according to the XSPP.

Namespace: Nehta.VendorLibrary.SM.SMD
Assembly: Nehta.VendorLibrary.SM.SMD (in Nehta.VendorLibrary.SM.SMD.dll) Version: 1.0.5.0 (1.0.5.0)

Syntax

C#
public static XmlDocument XspEncrypt(
	this XmlDocument document,
	X509Certificate2 encryptionCert
)
Visual Basic
<ExtensionAttribute> _
Public Shared Function XspEncrypt ( _
	document As XmlDocument, _
	encryptionCert As X509Certificate2 _
) As XmlDocument
Visual C++
[ExtensionAttribute]
public:
static XmlDocument^ XspEncrypt(
	XmlDocument^ document, 
	X509Certificate2^ encryptionCert
)

Parameters

document
Type: System.Xml..::..XmlDocument
The XML document to be encrypted.
encryptionCert
Type: System.Security.Cryptography.X509Certificates..::..X509Certificate2
The certificate to encrypt the XML document with.

Return Value

The encrypted XML document.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type XmlDocument. When you use instance method syntax to call this method, omit the first parameter. For more information, see or .

See Also