Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 How to decrypt Stored Procedure

Author  Topic 

aravindt77
Posting Yak Master

120 Posts

Posted - 2008-12-02 : 06:26:58
Hi,

I want to know regarding Stored PRocedure

" How to decrypt or fetch the definition of encrypted Stored procedure? "

Thanks & Regards

ARV

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-12-02 : 06:33:42
use either DecryptByAsmke,DecryptByCert,DecryptByKey... depending on what method you used for encryption.
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2008-12-02 : 06:34:42
There is a reason for the procedure code to be encrypted.
And that is to keep nosy people out of the code.

There are simple methods to decrypt the code for procedures, but we will not aid you.
If you didn't write the code, you are not allowed to see it.

If you have written the code, or the key (as suggested by Visakh) is public, you can decrypt the procedure code.


E 12°55'05.63"
N 56°04'39.26"
Go to Top of Page

aravindt77
Posting Yak Master

120 Posts

Posted - 2008-12-02 : 06:37:29
Hi ,
I m working with SQL Server and a beginner also. I want the content of a procedure which is encrypted. the encryption what i made is while creation of stored procedure just mentioned the workd encryption thats all. But now i need to take the definition. Its only for a tutorial purpose.

Hope u all get me

ARV
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2008-12-02 : 06:51:04
Comment out the "WITH ENCRYPTION" part and your code for the stored procedure will be in clear text.



E 12°55'05.63"
N 56°04'39.26"
Go to Top of Page

aravindt77
Posting Yak Master

120 Posts

Posted - 2008-12-02 : 06:52:57
CREATE PROC GetDetails(@usr nvarchar(100))
WITH ENCRYPTION
AS
BEGIN

SELECT * FROM aaa WHERE Usrs = @usr

RETURN
END
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2008-12-02 : 06:55:24
For tutorial porposes, use Google how to decrypt encrypted stored procedures.



E 12°55'05.63"
N 56°04'39.26"
Go to Top of Page

aravindt77
Posting Yak Master

120 Posts

Posted - 2008-12-02 : 07:00:04
OK.. THANKS A LOT
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2008-12-02 : 07:02:22
You're welcome.



E 12°55'05.63"
N 56°04'39.26"
Go to Top of Page

Optillect
Starting Member

2 Posts

Posted - 2010-10-12 : 16:44:25
spam removed
Go to Top of Page
   

- Advertisement -