?
Solved

c# how can I encrypt/decrypt a string to save into sql.

Posted on 2007-03-23
3
Medium Priority
?
1,256 Views
Last Modified: 2008-10-29
How can I encrypt data and send it into sql for storage...then later query that data decrypt it and present the value.

I dont mean I need to know who to read and write from SQL..but rather how can I encrypt say a string value so I can save teh encrypted value to a table..then later decrypt that same value aftre retriveing it from the database.

I need a c# solution. Either code or at least a document that explains how to do this. I am NOT talking about encryption teh web config connection string...

0
Comment
Question by:Prysson
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 23

Assisted Solution

by:Jens Fiederer
Jens Fiederer earned 200 total points
ID: 18781203
The normal Microsoft documentation for the CryptoStream class gives you a pretty good example (code), as well as detailed information.
0
 
LVL 4

Accepted Solution

by:
g_johnson earned 1800 total points
ID: 18782185
0
 

Expert Comment

by:manjunathcv
ID: 22829640
i recently came across this situation and  here is the sample code

http://probedeep.blogspot.com/2008/10/simple-password-string-encryption-and.html
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article shows how to use the open source plupload control to upload multiple images. The images are resized on the client side before uploading and the upload is done in chunks. Background I had to provide a way for user…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Suggested Courses

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question