Encrypt the whole file data which is the equivalent of rgbPlaintext or Sign the file hash and then Verify the signature. Using CNG is the same as Calling Native Functions from Managed Code.
And In my opinion, CNG is a set of APIs which provide a abstract model for private key storage.
Have a look at SignHash which calls NCryptOpenStorageProvider. As far as I see, StorageProvider provides some services.
What is diffrent beween CNG and Microsoft Key storage provider?
SUBRAMANIAN Prabhakaran
1
Reputation point
Hi Team,
I have gone through the below link about CNG and Key Storage Provider.
https://learn.microsoft.com/en-us/windows/win32/seccng/key-storage-and-retrieval
I did not get clear view of these sections.
What is CNG? and what is different between CNG and Key Storage Provider?
Can i protect a file(like text file,ini file data etc..) by using Key Storage Provider? if it is possible how can i implement it in C#.Net?
Regards,
Prabhakaran
1 answer
Sort by: Most helpful
-
Xiaopo Yang - MSFT 12,726 Reputation points Microsoft Vendor
2021-11-29T09:51:46.11+00:00