in reply to peeking at the working interpreter

I've used the simple rot13 perl filter from the pod (for amusement). If you start the debugger (perl -d <rot13_encrypted_file>) and do a l 1-10 (list rows 1-10) you'll get them fully readable and decrypted.
I haven't tried any C language perl filters, but you can try to have a peek your self with perl -d.

You'll probably need to statically link the decrypter in perl and also disable debugging to have some small ammount of security.

/brother t0mas

Replies are listed 'Best First'.
RE: Re: peeking at the working interpreter
by gregorovius (Friar) on Sep 06, 2000 at 18:40 UTC
    The -d option is disabled when you use the decrypt template from the Filter module at CPAN. At least this seems to be safe from the perl debugger. This is is the code that does the disabling on the decrypt.xs file:
    #ifdef DEBUGGING /* Don't run if compiled with DEBUGGING */ croak("recompile without -DDEBUGGING") ; #endif . . . /* make sure the Perl debugger isn't enabled */ if( PL_perldb ) croak("debugger disabled") ;
      The -d option is disabled when you use the decrypt template from the Filter module at CPAN

      Good move.

      Try hitting it with perl -MO=Deparse file.pl and see what you get. Deparse uses the internal compiled structure, maybe you'll get lucky? with that. I don't know if you'll be able to run the B:: modules without the debugger (I've never compiled perl without it) so I'm just guessing here :)

      /brother t0mas
        Here's what I get with Deparse:
        [C:/TEMP] perl -MO=Deparse not_encrypted.pl print "hello world\n"; ... [C:/TEMP] perl -MO=Deparse encrypted.pl Aborting, Compiler detected at d:/Claudio/Perl/lib/DynaLoader.pm line +219. Compilation failed in require at encriptado.pl line 1. BEGIN failed--compilation aborted at encriptado.pl line 1.
        This is the code in the decrypt.xs template that cares for this:
        /* Check for the presence of the Perl Compiler */ if (gv_stashpvn("B", 1, FALSE)) croak("Aborting, Compiler detected") ;
        Thanks for the help!