Click here to Skip to main content
15,912,312 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
C#
I need help to encrypt the generated product key i.e in alphanumberic for my web application. please help me with your idea how to encrypt the generated code using C#

thnk u

What I have tried:

Guid g;
g = Guid.NewGuid();
Console.WriteLine(g);
Console.WriteLine(Guid.NewGuid());

with this i generate the key and save it in my sql database.
Now i need to encrypt the generated code. Please share your idea.
Posted
Updated 8-Oct-16 20:53pm
Comments
Michael_Davies 9-Oct-16 2:34am    
Put the words "c# encrypt" into the search box at the top right of this site, when you get the results tick Articles on the left then search again.

 
Share this answer
 
You can use MD5, like we use for saving encrypted password in database
using-md5-encryption-with-c-and-microsoft-sql-server/[^]
 
Share this answer
 
Comments
Patrice T 9-Oct-16 2:33am    
MD5 is not encryption !
Richard MacCutchan 9-Oct-16 2:52am    
If you are using MD5 to encrypt passwords then you are doing it all wrong. You should use hashing and only ever save the hash values.
manu_dhobale 10-Oct-16 7:57am    
Thanks guys for corrections

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