Click here to Skip to main content
15,887,596 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
27 minutes ago|LINK

HI all,

How to retrieve the public key, which is exported and saved in a disk using c#. And then i need to convert it to RSAPublickey type.
Or
i have a public key in my disk .So now i want to read that file and create an RSAPublickey object from that.How that can be done?

Thanks

Akhil lal
Posted
Comments
Sergey Alexandrovich Kryukov 21-May-14 11:31am    
We have no idea what file do you mean. It's likely that you don't have to extract a key by yourself and can use the file itself. Without knowing what is it, it makes no sense.
—SA
akhil lal 22-May-14 6:03am    
Hi,
I have HSM device . they provide a user interface to create keypair.From that i exported the public key to a file.suppose i export it to a text file. So now i need to access this public key in my c# application.Thats what i mean.
i am a beginer in this crypotgraphy and all. please correct me if i am wrong.
Sergey Alexandrovich Kryukov 22-May-14 14:29pm    
What kind of file? How it's named? Is it XML? something else? *.snk, *.pfx, anything else? Normally, you can use the file itself to use the key it stores...
—SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900