Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Are package bodies encrypted?

Re: Are package bodies encrypted?

From: Sybrand Bakker <gooiditweg_at_sybrandb.demon.nl>
Date: Sat, 12 Apr 2003 06:50:28 +0200
Message-ID: <ubud9vc3spubnhlml5fdhe2ka226n4euql@4ax.com>


Answers embedded

On Fri, 11 Apr 2003 12:21:56 -0400, "Thomas T" <T_at_T> wrote:

>Just starting to experiment with packages... and was looking at the few
>Oracle packages in my Oracle 8.1.7 test server. Are the package bodies
>encrypted? I can see the Package Spec for DBMS_ALERT, but when I click on
>the Package Body for DBMS_ALERT, it seems to be encrypted?
>

The Oracle term is 'wrapped'. It looks like a sort of p-code, many compilers are using, because you still can see the bind variables. They were wrapped on purpose to avoid giving away the source.

>I'm guessing encryption because if I look at the HTP package spec and body,
>I can see all the procedures and functions.
>
>Were they encrypted using the DBMS_OBFUSCATION_TOOLKIT? If so, can I
>decrypt them back to see what's in there?
You can't, and if you can you will violate your license.
>
>Or are these not encrypted, but compiled, and I won't be able to see my own
>source code? I'd hate to define a package spec and package body, and then
>not be able to look at the code for my procedures. Seems strange that most
>of these built-in packages have hidden bodies, and the rest are visible. I
>tried a web search, but either nobody's asked this question yet, or I can't
>find the proper phrase to search for.

You must explicitly wrap packages using the wrap utility provided in the Oracle bin directory.
If you don't wrap your package you can read the source code in user_source. The compiled code is in different dictionary tables.

>
>I think it's about time I go pick up the Oracle 9i PL/SQL Programming book;
>hopefully it's more advanced then the PL/SQL v2.2 book I have (written in
>1995 for Oracle 7)! The book only has 16 pages of coverage. Or, is there
>another book that explains more of the PL/SQL and package details... like,
>maybe a book designed for the OCP exams? (There's nothing I hate more than
>buying a book, only to find out that I know half of it, and of the other
>half, 1/3 contains topics that I'd never use.)

Just buy the book of Steven Feuerstein published by O'Reilly and forget about the rest.
>
>One more question; can I migrate existing procedures into a package? Or do
>I just copy the code into a new package body, and then delete the original
>stand-alone procedure?

yes

>
>Thanks!
>
>-Thomas
>

Regards

Sybrand Bakker, Senior Oracle DBA

To reply remove -verwijderdit from my e-mail address Received on Fri Apr 11 2003 - 23:50:28 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US