Geeks With Blogs


Tiago Salgado .NET / SQL Server / IT / etc...

When we don't want to others have access to our Stored Procedures, Triggers or Views code, created on a database, you can create and encrypt easily, just by adding a "WITH ENCRYPTION".

Here’s an example to create a Stored Procedure:

  1. CREATE PROCEDURE encrypted_SP(@var varchar(10))  
  3. AS  
  4.     -- this is an encrypted stored procedure  
  5.     print @var 

Thus, our SP will appear in the Object Explorer as follows:

As you can see, is very simple to create an encrypted stored procedure.

But sometimes, we need (realy) a way to see that code, and its necessary to use third party tools.

This is where the SQL Decryptor Optillect is useful. By accessing our database by this application, with only one double-click on the stored procedure that is encrypted, we can quickly see the code that we want.

Posted on Sunday, March 27, 2011 12:10 AM | Back to top

Comments on this post: Encrpyt and decrypt a Stored Procedure

# re: Encrpyt and decrypt a Stored Procedure
Requesting Gravatar...
test Encryption
Left by Nicolas Chami on Dec 20, 2011 11:26 AM

Your comment:
 (will show your gravatar)

Copyright © Tiago Salgado | Powered by: