2

I have used SQL Server database with data to be encrypted and I will use symmetric key for encryption and will encrypt it by asymmetric key now comes the question how to give user permission to encrypt and not to decrypt

I have found this article that propose creating two procedures and use them as security mechanism however my question here where is the public/private key thing of asymmetric encryption.

Are there any other solutions?

  • What version of SQL are you running? – user2320464 Jun 15 '15 at 3:08
  • I am using Sql Server 2012 – Hossam Barakat Jun 19 '15 at 11:13
-1

I wrote a series of stored procedures (specifically for MySQL vs. MSSQL) that might be of interest. You can view it at sqlSec.

Keep in mind that it is more a proof of concept using stored procedures to rotate symmetric encryption keys but does provide a transparent encryption/decryption procedure examples in the readme.

  • Thanks for the references however I still didn't understand how that is really handled inside SQL Server – Hossam Barakat May 16 '15 at 0:47
  • 1
    Why are you trying to do encryption in the database? It's going to be 10 times easier to do your encryption in some language other than t-sql that interacts as a client rather than on the sql server directly. – Steve Sether Feb 10 '16 at 15:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.