web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Business Central forum

BC140 - XML Signing

(0) ShareShare
ReportReport
Posted on by 15

I've been trying to sign XML through CU 6227 "Signed XML Mgt." with function SignXmlText,

Function requires "private key", and i don't know how would i get private key.

CU 3043 "DotNet_X509Certificate2" that has no external function to get private key, and dotnet variable DotNetX509Certificate2 has privatekey method, to return private key.

And function that initializes CU X509Certificate2 does not work because one of the parameters is Codeunit "DotNet_X509KeyStorageFlags" that has no external functions so it cant be initialized.

So my question is, how do i sign XML?

I have the same question (0)
  • Suggested answer
    Stefano Demiliani Profile Picture
    37,166 Most Valuable Professional on at

    Do you want to do that in SaaS? I think it's quite hard, private keys or certificates are nornaly stored on the client machine.

  • fmoric@In2 Profile Picture
    15 on at

    Yes, through extension.

    I've missed a few details:

    So I have certificate (p12) that we get from Tax Authority for signing XML to send invoices to Tax Authority.

    I was thinking about using Certificates to store certificate in database, so i can sign XML.

    But problem is that i don't know how to get private key from certificate, so i can sign XML.

  • Felipe Kavai Profile Picture
    35 on at

    Hey,

    I am like the same problem, did you get any solution?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard > Business Central

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans