Google
 

Saturday, August 1, 2009

How to wrap plsql code

Dear Friends,

Today i come across a requirement to UNWRAP plsql code. want to share with you all.

How to wrap plsql code (procedure,function,trigger)

1. There is client side OS utility "WRAP" through we can wrap plsql code.

2. What is the syntax and parameters

1. The syntax is very simple and there to parameter.

Syntax: cmd>wrap iname=test.sql oname=wrap_test.sql

Parameter:

iname = input plsql code file

oname = output with wrap plsql code file

eg:

SQL> host wrap iname=c:\test.sql oname=c:\test_unwrap.sql
PL/SQL Wrapper: Release 10.1.0.4.2- Production on Sat Aug 01 17:08:02 2009
Copyright (c) 1993, 2004, Oracle. All rights reserved.
Processing c:\test.sql to c:\test_unwrap.sql

SQL> @c:\test_unwrap.sql
Procedure created.
SQL> select text from user_source where name='TEST';
TEXT

--------------------------------------------------------------------------------
procedure TEST wrappeda000000b2abcdabcdabcdabcdabcdabcdabcdabcd
TEXT

--------------------------------------------------------------------------------
abcdabcdabcdabcdabcdabcdabcd723 55DcPgmpJJ2JAE/YKfa+Z8kj6scxUwg5nnm7+fMr2ywFznUrLL7sB0i8DAMv7ShpuZgQgti8CBxy3Jpqbo3ecD

Content of TEST.SQL file

SQL> host type c:\test.sql

create or replace procedure TEST

as

begin

null;

end;

/

Reference:

http://download.oracle.com/docs/cd/B10501_01/appdev.920/a96624/c_wrap.htm

http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:1484204932051

It is easy to wrap the plsql code but what happen when we need to unwrap the code without source code file :)

The same situation happen with me... but i found one link on google to unwrap plsql code...

I can't refer here for security reason. Sorry


Subscribe to oracleclub
Powered by tech.groups.yahoo.com

Subscribe via email

Enter your email address:

Delivered by FeedBurner