July 11, 2008 at 12:27 am
Hi i want to encrypt data and dcrypt the
May i know the process i m using sqlserver 2000 standard edition ....
Thankz in advance.
July 11, 2008 at 12:53 am
SQL 2000 has no built in encryption/decryption mechanisms.
p.s. SQL 2000 posts should go in the SQL 2000 forums
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
July 14, 2008 at 2:40 pm
Use BOL to learn how to use SQL 2005's built in encryption functions. If you are using SQL 2000 you need to do the encryption/decryption in the business layer. That is where I would do it anyway.
Jack Corbett
Consultant - Straight Path Solutions
Check out these links on how to get faster and more accurate answers:
Forum Etiquette: How to post data/code on a forum to get the best help
Need an Answer? Actually, No ... You Need a Question
July 15, 2008 at 5:55 am
SELECT ENCRYPT ('Test')-> when this select query is run on a database the value obtained is in an encrypted format.
Hence, if you did mean that you what to enter a password in encryted format, so that no one else would be able to see it, then this method could help you 😛
so when you are inserting a new password into the table field then use
INSERT INTO tablename values('id',ENCRYPT('password'))
and when you did try to retrieve the info back, you would get the password you stored ...
hope this helps and this is what you want...;)
July 15, 2008 at 6:13 am
rinu philip (7/15/2008)
SELECT ENCRYPT ('Test')-> when this select query is run on a database the value obtained is in an encrypted format.
On which version of SQL? On SQL 2005, it throws an error.
SELECT ENCRYPT ('Test')
Msg 195, Level 15, State 10, Line 1
'ENCRYPT' is not a recognized built-in function name.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
July 15, 2008 at 6:15 am
I have tried it on sql 2000.:) and it worked..
July 15, 2008 at 6:26 am
rinu philip (7/15/2008)
I have tried it on sql 2000.:) and it worked..
I thnk that's an ODBC function, rather than native SQL. Can't find a confirmation though.
Either way, there's no associated decrypt
Ref:
http://www.sqlservercentral.com/articles/Security/encryptfunction/372/
http://windowsitpro.com/article/articleid/14035/how-do-i-encrypt-fields-in-sql-server.html
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
July 15, 2008 at 7:22 am
hmm..you may be right, I actually used this command through VB, however when the users forgot their password we had to reset with a new one! there was no way to retrieve 😉
July 15, 2008 at 7:50 am
It's not a documented function and therefore unsupported. Given that I can't find any info about it, you probably couldn't show to an auditor it's algorithm or strength, meaning it likely wouldn't be found acceptable.
K. Brian Kelley
@kbriankelley
July 15, 2008 at 8:44 am
There was a way in SQL 2000 to perform an MD5, one way encryption of data, and ENCRYPT() works on my SS2K instance.
However this cannot be decrypted. You can "compare" two encrypted values to see if they are equal, but you cannot retrieve the data.
Viewing 12 posts - 1 through 11 (of 11 total)
You must be logged in to reply to this topic. Login to reply