Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

my fisrt japh with the unpack function

by Asmo (Monk)
on Sep 22, 2001 at 13:56 UTC ( [id://114038]=obfuscated: print w/replies, xml ) Need Help??

print unpack(u,"92G5S=\"!!\;F]T\:&5R(\%!E<FP@\(\$AA8VME<@``");

I'm not very good with this function because it's very new for me,so i tried to use it with a JAPH, what do you think ?

Asmo

Replies are listed 'Best First'.
Re: my fisrt japh with the unpack function
by blakem (Monsignor) on Sep 22, 2001 at 14:10 UTC
    nice... you can eliminate those backslashes by using the q operator. It allows you to choose your string delimiters, like so:
    print unpack(u,q/92G5S="!!;F]T:&5R(%!E<FP@($AA8VME<@``/);
    Or since this is obfu, pick an unusual char for a delimiter, perhaps 'u':
    print unpack(u,q u92G5S="!!;F]T:&5R(%!E<FP@($AA8VME<@``u);
    even better, how about ',':
    print unpack(u,q,92G5S="!!;F]T:&5R(%!E<FP@($AA8VME<@``,);
    This lets us obfu it further...
    print unpack u,(q,u,,q,92G5S="!!;F]T:&5R(%!E<FP@($AA8VME<@``,);
    figuring that one out is left as an excercise to the reader...

    Read more about it at perlop.

    -Blake

      Ok, thanks for this advice !

      Asmo
Re: my fisrt japh with the unpack function
by rob_au (Abbot) on Sep 22, 2001 at 14:19 UTC
    While I don't want to discourage your efforts in extending your knowledge of Perl and the functions therein, I must object to this being classified as "obfuscated code". The primary reason for this is that the code logic and execution is hardly obscured or hidden - It is a single unpack statement from which the results are print-ed, nothing more.

    For a bit of background reading on how to write really good obfuscated code, I would recommend having a look at the two obfuscation code reviews by japhy here and here. Also too have a look at the obfuscated code written by the mighty Erudil, including the camel code.

     

    Ooohhh, Rob no beer function well without!

      Ok, i will read those, but you know, for me, it is obfuscated as it seems unreadable ;-) btw, am i the only newbie here ?

      Asmo
        The fact that you are a newbie doesn't mean we will outcast you.

        What you should do is learn the language very thoroughly like japhy has, then learn how to manipulate it. Once you have done that, you too can write some pretty cool obfu's.

        _______________________________________________________
        s&&q+\+blah+&oe&&s<hlab>}map{s}&&q+}}+;;s;\+;;g;y;ahlb;veaD;&&print;

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: obfuscated [id://114038]
Approved by root
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (4)
As of 2024-04-20 06:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found