Encrypting Columns

  • Is it possible set up a column, or a trigger than can encrypt a column. (i.e. credit card numbers sittiing in a column should be encrypted). I know I could do this on the middle tier, but I wanted to know if there is a function, trigger, etc. I can create to do this at the back end.

    Thanks

  • You can do this, but the information has potentially been comprimised by transitting the wire unencrypted.

    You would set the trigger to update the column with the envrypted value using some algorithm. Note that if you include the key in the trigger, this is a potential promblem.

    Steve Jones

    steve@dkranch.net

  • I'm only using it for an internal application I am writing. How do I do this. I tested the encrypt() function, but once it encrypts I can't reverse it. What should I be doing?

    Any ideas?

    quote:


    You can do this, but the information has potentially been comprimised by transitting the wire unencrypted.

    You would set the trigger to update the column with the envrypted value using some algorithm. Note that if you include the key in the trigger, this is a potential promblem.

    Steve Jones

    steve@dkranch.net


  • You would need to build your own algorithm to encrypt/decrypt. I would store the key in a table (lock this down) and use a UDF to perform the encryption.

    Steve Jones

    steve@dkranch.net

  • Actually if you concern is the encryption of sensitive data the point is to do a one way encryption this means the original data should be required to confirm it. If using a two way encryption you have to be carefull how you approach this as the key placed anywhere in the software chain is a potential for compromising. That said, I would look at using DES encryption or some other standard with high bit encryption level which will make it harder to decrypt without the key. DES is put out in DLLs and OCXs that can be shipped with you product or if server side accessed by ASP or another DLL built with the wrapper for Extended Procedures.

    "Don't roll your eyes at me. I will tape them in place." (Teacher on Boston Public)

  • Also, there are a few good articles on this site. Click "search" and enter encryption.

    Steve Jones

    steve@dkranch.net

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply