We are trying to implement XmlDocument signing on Business Central.
If we understand the code correctly, we're supposed to import certificates into isolated storage, which we did.
And then we think we're supposed to use SignXmlText function from codeunit 6227.
[External] SignXmlText(XmlText : Text;PrivateKey : Text) : Text
However there does not seem to be any way to get access to the privatekey.
By looking at the code this is supposed to be hex encoded binary blob with the actual private key data.
Are there any samples / documentation where we could see how we're supposed to do this?
Docker image: bcinsider.azurecr.io/bcsandbox-master
Application version: 14.0.26992.0
Platform version: 14.0.26873.0
[Ok := ] IsolatedStorage.Get(Key: String, [DataScope: DataScope], var Value: Text)
MIIf3wIBAzCCH5gGCSqGSIb3DQEHAaCCH4kEgh+FMIIfgTCCBXUGCSqGSIb3DQEHAa.......PU/B+DBBTUPQ0mM1HU9n2dZrHVLrRR6DP1lwIDAYag
A call to System.Security.Cryptography.RSACryptoServiceProvider.ImportCspBlob failed with this message: Bad Version of provider.
He probably thinks about table 1262 "Isolated Certificate" not "Isolated storage"?
This can be done through UI.
BR,
Bojan
How is your code for importing the certificate key into the Isolated Storage?
You can read a key saved in the Isolated Storage by using:
[Ok := ] IsolatedStorage.Get(Key: String, [DataScope: DataScope], var Value: Text)
With this method, the key you read is associated to the Value text variable.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 290,451 Super User 2024 Season 2
Martin Dráb 228,353 Most Valuable Professional
nmaenpaa 101,148