SQL Server Stored Procedure function encryption and decryption encryption of stored procedures and functions: WITHENCRYPTION! -- [If! SupportLineBreakNewLine] --! -- [Endif] -- CREATEproceduredbo. sp_XML_main @ table_namenvarchar (260), @ dirnamenvarchar (20) WITHENCRYPTIONasbegin ......
SQL Server Stored Procedures/function ENCRYPTION/Decryption ENCRYPTION of stored procedures and stored functions: WITH ENCRYPTION! -- [If! SupportLineBreakNewLine] --! -- [Endif] -- CREATE procedure dbo. sp_XML_main @ table_name nvarchar (260) = '', @ dirname nvarchar (20) ='' with encryption as begin ......
SQL Server Stored Procedure/function encryption/Decryption
ENCRYPTION of stored procedures and stored functions: WITH ENCRYPTION
CREATE procedure dbo. sp_XML_main
@ Table_name nvarchar (260) = '',
@ Dirname nvarchar (20) =''
WITH ENCRYPTION
As
Begin
....................
End
Go
Decryption of stored procedures and stored Functions
If exists (select * from dbo. sysobjects where id = object_id (n' [dbo]. [sp_decrypt] ') and OBJECTPROPERTY (id, n' IsProcedure') = 1)
Drop procedure [dbo]. [sp_decrypt]
GO
/* -- Crack functions, processes, triggers, and views. Limited to SQLSERVER2000
-- Author: J9988 -- All rights reserved */
/* -- Call example
-- Decrypts a specified Stored Procedure
Exec sp_decrypt 'encrypt P _ Test'
-- Decrypt all stored procedures
Declare tb cursor
Select name from sysobjects where xtype = 'p' and status> 0 and name <> 'SP _ decrypt'
Declare @ name sysname
Open tb
Fetch next from tb into @ name
While @ fetch_status = 0
Begin
Print '/* ------- stored procedure [' + @ name + '] ----------- */'
Exec sp_decrypt @ name
Fetch next from tb into @ name
End
Close tb
Deallocate tb
--*/
If exists (select * from dbo. sysobjects where id = object_id (n' [dbo]. [SP_DECRYPT] ') and OBJECTPROPERTY (id, n' IsProcedure') = 1)
Drop procedure [dbo]. [SP_DECRYPT]
GO
Create procedure sp_decrypt (@ objectName varchar (50 ))
AS
Begin
Set nocount on
-- Unlimitedly cracked bytes, applicable to SQLSERVER2000 stored procedures, functions, views, and triggers