in reply to Breaking a Filter::decrypt like source filter

This node falls below the community's threshold of quality. You may see it by logging in.
  • Comment on Re: Breaking a Filter::decrypt like source filter

Replies are listed 'Best First'.
Re^2: Breaking a Filter::decrypt like source filter
by olego (Acolyte) on Jan 24, 2007 at 22:43 UTC
    You're far off the path. I'm not into hiding my sources, but into learning on Perl as a whole. Since I can not 'prove' this you may believe what you like to. On the other hand, with you having no evidence for your assumptions, I think you're too quick in your conclusions on the motivations of posters.
    On the library thing: I don't know too much on static and shared C libraries. But you may notice that, depending on your configuration, your Perl ships with those .a files, too. Including extensions as static into Perl does not seem to mean what you think it means.

    ~/tmp$ find perl -name '*.a' perl/lib/5.8.8/i686-linux/auto/DynaLoader/DynaLoader.a perl/lib/5.8.8/i686-linux/CORE/libperl.a perl/lib/5.8.8/i686-linux-thread-multi/auto/DynaLoader/DynaLoader.a perl/lib/5.8.8/i686-linux-thread-multi/auto/attrs/attrs.a perl/lib/5.8.8/i686-linux-thread-multi/auto/Cwd/Cwd.a perl/lib/5.8.8/i686-linux-thread-multi/auto/Fcntl/Fcntl.a perl/lib/5.8.8/i686-linux-thread-multi/auto/File/Glob/Glob.a perl/lib/5.8.8/i686-linux-thread-multi/auto/Filter/Util/Call/Call.a perl/lib/5.8.8/i686-linux-thread-multi/auto/Filter/decrypt/decrypt.a perl/lib/5.8.8/i686-linux-thread-multi/auto/IO/IO.a perl/lib/5.8.8/i686-linux-thread-multi/auto/IPC/SysV/SysV.a perl/lib/5.8.8/i686-linux-thread-multi/auto/List/Util/Util.a perl/lib/5.8.8/i686-linux-thread-multi/auto/MIME/Base64/Base64.a perl/lib/5.8.8/i686-linux-thread-multi/auto/PerlIO/encoding/encoding.a perl/lib/5.8.8/i686-linux-thread-multi/auto/PerlIO/scalar/scalar.a perl/lib/5.8.8/i686-linux-thread-multi/auto/PerlIO/via/via.a perl/lib/5.8.8/i686-linux-thread-multi/auto/Socket/Socket.a perl/lib/5.8.8/i686-linux-thread-multi/auto/Sys/Hostname/Hostname.a perl/lib/5.8.8/i686-linux-thread-multi/auto/Time/HiRes/HiRes.a perl/lib/5.8.8/i686-linux-thread-multi/CORE/libperl.a
Re^2: Breaking a Filter::decrypt like source filter
by ysth (Canon) on Jan 25, 2007 at 02:03 UTC
    (After all why would anyone distribute the .a lib together with a perl that has that same module linked in? Doesn't make any sense.)
    The .a lib is distributed with static modules so you can build additional static modules later (which needs to relink perl with all the previous .a libs).

      Right, but as in Perl, context matters :-)

      "The encryption extension is no Shared Object (not an .so file, but an .a file, and running it with a Perl executable different from that one provided with the extension ends up in 'Can't find shared object file for ... in @INC') ... "

      So apparently, someone linked the encryption extension statically with the Perl executable to make it harder to reverse engineer. Now why would that fictive person ship this super secret decryption code along with the rest as a separate .a file? To make it easy for everyone to relink it with a perl patched to dump the cleartext code? Only fools would do that.

      ___

      "The secret to creativity is knowing how to hide your sources." - Albert Einstein

        Only fools would do that.
        Not fools, just the ignorant. If you don't know why EU::MM installs the library for static modules, you probably won't suspect that it does so. And even if you look over the list of files you are distributing, it may not occur to you that that library has your module's code, not just some kind of binding layer for it.
        #!/usr/bin/perl print "\n* Perl2exe Perl sourcecode revealer test code\n". " by Thijs (Thice) Bosschert\n". " v1.0 17-06-2012\n\n"; # Comment: This is a test comment print "\n* This is just a test line.\n\n";