Re: SQL Server 2005 encryption with databound controls
- From: "Finn Stampe Mikkelsen" <stampe@xxxxxxx>
- Date: Sun, 15 Nov 2009 23:33:33 +0100
"Alberto Poblacion" <earthling-quitaestoparacontestar@xxxxxxxxxxxxx> skrev i meddelelsen news:#Slp46cZKHA.228@xxxxxxxxxxxxxxxxxxxxxxx
"Finn Stampe Mikkelsen" <stampe@xxxxxxx> wrote in message news:e4rwa5XZKHA.5608@xxxxxxxxxxxxxxxxxxxxxxxI'm looking for ways to encrypt data in my MDF database (SQL Express) and i wonder if anybody had some examples on how to use it, especially in conjunction with databound controls using dataset's..
When you say "databound controls using datasets", I presume that the controls are bound to a dataset and that you transfer the contents of the dataset from/to the database using a DataAdapter. If you want the contents of the data encrypted inside the database (but not inside the dataset or when travelling from the client to the database), then you can encapsulate all the encryption and decryption inside stored procedures, and you can configure the DataAdapter to use those SPs, rather than the sql queries themselves.
Inside the SPs, you would pass your data through the standard SQL Server 2005 functions for encryption and decryption (EncryptByKey and DecryptByKey) before writing or reading the actual table.
If you were using Sql Server 2008 I would suggest the much simpler avenue of using Transparent Data Encryption, but unfortunately this is not available in the Express version.
Hi
You are quite correct in your assumption. I cannot use SQL 2008, so that is not an option.
Your solution using SP, would that not leave the data vulnerable?? I mean the SP would not itself be encrypted and would the possible hacker of the MDF file be able to decrypt the data by just using this SP??
Pls. excuse me, cause i'm not familiar with the server functions you mentioned, so i'm not sure how they are used. A code example would really help me see the light, so to speak.. ;-))
/Finn
--
Der er 10 slags mennesker - Dem som forstår binær og dem som ikke gør.
There are 10 kinds of people. Those who understand binary and those who don't.
Es gibt 10 Arten von Menschen. Die, die Binär verstehen, bzw. die, die es nicht tuhen.
.
- Follow-Ups:
- Re: SQL Server 2005 encryption with databound controls
- From: Alberto Poblacion
- Re: SQL Server 2005 encryption with databound controls
- References:
- SQL Server 2005 encryption with databound controls
- From: Finn Stampe Mikkelsen
- Re: SQL Server 2005 encryption with databound controls
- From: Alberto Poblacion
- SQL Server 2005 encryption with databound controls
- Prev by Date: Re: Madoff programmers were a modest bunch...and what language did they use?
- Next by Date: Re: Database - go through every field
- Previous by thread: Re: SQL Server 2005 encryption with databound controls
- Next by thread: Re: SQL Server 2005 encryption with databound controls
- Index(es):
Relevant Pages
|