CryptoSys PKI Pro Manual

rsaToXMLStringEx

Create an XML string representation of an RSA internal key string with option to add a namespace prefix.

Syntax

[VBA]
Public Function rsaToXMLStringEx ( _
    szKeyString As String, _
    szPrefix As String, _
    Optional nOptions As Long = 0 _
) As String

Parameters

szKeyString
The RSA public or private key in internal format.
szPrefix
Namespace prefix to be added to all elements, e.g. "ds".
nOptions
Default (0) to output in appropriate W3C standard format (RSAKeyValue for public key and RSAKeyPair for private key), or select and combine:
PKI_XML_RSAKEYVALUE to force private key output as .NET-compatible RSAKeyValue format (instead of W3C RSAKeyPair)
PKI_XML_EXCLPRIVATE to exclude the private key (use to get a public key RSAKeyValue from a private key)
PKI_XML_HEXBINARY to output with data in non-conforming (but convenient) hexBinary format.

Return Value

String: XML string or empty string on error.

Remarks

Use this extended function to add a namespace prefix to all elements in the XML output; for example, <ds:RSAKeyValue>.
[PREV: rsaToXMLString...]   [Contents]   [Index]   
   [NEXT: sigSignData...]

Copyright © 2004-24 D.I. Management Services Pty Ltd. All rights reserved. Generated 2024-09-23T07:52:09Z.