develooper Front page | perl.perl5.porters | Postings from October 2003

Re: How to tell if Perl has -DDEBUGGING?

Thread Previous | Thread Next
Michael G Schwern
October 26, 2003 12:29
Re: How to tell if Perl has -DDEBUGGING?
Message ID:
On Sun, Oct 26, 2003 at 07:12:14PM +0000, Nick Ing-Simmons wrote:
> perl -MO=Deparse secret-script
> will load the decrypt filter and then render the script ;-)

Filter::decrypt has a way of disabiling that these days, so it says,
by detecting if the compiler is in use.  But that means you can still
take the code apart, starting with the publicly documented functions using

       6.   Check that the Perl Compiler isn't being used.

            There is code in the BOOT: section of decrypt.xs that
            shows how to detect the presence of the Compiler.
            Make sure you include it in your module.

            Assuming you haven't taken any steps to spot when the
            compiler is in use and you have an encrypted Perl
            script called "", you can get access the
            source code inside it using the perl Compiler back-
            end, like this

                perl -MO=Deparse

            Note that even if you have included the BOOT: test,
            it is still possible to use the Deparse module to get
            the source code for individual subroutines.

Michael G Schwern
There is a disurbing lack of PASTE ENEMA on the internet.

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About