Thursday, August 18, 2011 8:09 AM
I was reading an article on how to decrypt objects in database. I encrypt a stored procedure using the following statement
PROCEDURE sp_update_salary WITH ENCRYPTION AS DECLARE @perIncrease AS INT DECLARE @employeeid AS INT UPDATE [AdventureWorks].[HumanResources].[Employee] SET salary= salary *@perincrease WHERE employeeid =@employeeid
but i do not know how to decrypt it again in order to modify the stored procedure
Thank in advance for your help
Thursday, August 18, 2011 8:38 AM
You can not decrypt the code except you have original code written some where. Insted of encrypting stored procedure you can revoke view definition permission user rights. go through below article suggest main big problems with encrypting stored procedure.
Also follow the below thread.
Failure in Life is failure to try... PGDCA-98(South Gujarat University),MCTS (SQL Server 2005)
Thursday, August 18, 2011 10:20 AM
there are hundreds of thousends of tools available in the net.
Some are for free, most have to be paid.
I would recommend to have your devs stored as a file or in a SourceControl-Tool (like SourceSafe)
To revoke VIEW DEFINITION is o.k. for "normal" users but not for db_owner.
So this recommendation is - from my point of view - to a good idea.
MCITP Database Administrator 2005
MCITP Database Administrator 2008
MCITS Microsoft SQL Server 2008, Database Development
db Berater GmbH
Friday, August 19, 2011 2:59 PM
You may find this article from SQL Server Magazine useful, although it only includes through SQL Server 2005. (But I do not know of any further steps for stored procedure encryption taken in 2008.)
Hope it helps,
Tuesday, March 06, 2012 2:12 PM
this is the best one i have ever seen khalid
go this link and download decryptsql