Click here to Skip to main content
15,887,364 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
code of how we send the password to given email in asp.net in encrypt form
Posted
Comments
Herman<T>.Instance 17-Aug-11 6:34am    
this is not a question but an order
LittleYellowBird 17-Aug-11 6:37am    
Try to rephrase your problem as an actual question. Use the 'Improve question' link at the bottom right of you message. :)
Sergey Alexandrovich Kryukov 18-Aug-11 22:27pm    
It looks like it's base on misconception. Please see my solution.
--SA

1 solution

"Send the password to given email… in encrypt form" would defeat the purpose of encryption.

This is not how encrypting is done these days. Amazingly enough, to people never familiar to each other and never having any preliminary arrangement can exchange secret messages using open communication line; and even if some person spied on them from the very beginning will not be able to decrypt the messages, even if this person capture all keys transmitted.

Most people try to use logic and make a conclusion that this is impossible. They do a subtle logical mistake which can be fixed if one reads about the idea of public-key cryptography. It can be understood by reading this: http://en.wikipedia.org/wiki/Public-key_cryptography[^].

Just follow the communications between Alice and Bob and you will get the idea.

Such algorithms are also called asymmetric algorithms.

In turn, this is all based on the idea of one-way function, see http://en.wikipedia.org/wiki/One-way_function[^].

Well-known RSA algorithm (http://en.wikipedia.org/wiki/RSA[^]) is one of the major candidates for a one-way function and is one of the most popular encryption methods. There is a number of others.

Now, this is all well implemented in .NET. See:
http://msdn.microsoft.com/en-us/library/system.security.cryptography.asymmetricalgorithm.aspx[^],
http://msdn.microsoft.com/en-us/library/system.security.cryptography.aspx[^].

—SA
 
Share this answer
 

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