Is there a way to view the ECDH Shared Secret generated within microsoft CNG?

403 Views Asked by At

I am trying to perform a ECDH key exchange between MS CNG and another device. In order to debug things, I would like to see what shared secret is being generated in CNG so i can compare it with the secret generated by my other device. Anybody know of a way to do this?

1

There are 1 best solutions below

1
On

Take a look at CNG documentation at MSDN: NCryptSecretAgreement function. The same function is accessible from .NET.