Click here to Skip to main content
15,898,924 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more:
hi,

how to check whether the data is encrypted or not.??
and how to control error if we are tryin to get value by decrypting which is not actually encrypted??
Posted
Updated 18-Aug-11 1:51am
v2

can you read it? then it's not encrypted
 
Share this answer
 
Comments
Arpit khare 18-Aug-11 8:01am    
i mean to say that if i m decrypting the data which is coming from XML that is actually not save in encrypted form then it gives exception so how i check this condition.
Simon Bang Terkildsen 18-Aug-11 8:21am    
yeah the answer was meant as a joke, see John's answer.
if it's data you store yourself I would personally just encrypt it all, unless ofcourse the workload of is so high that decrypting data everytime becomes an issue.
The only way you can tell programatically is by trying to decrypt it and handle any exception that is thrown.
 
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