Title: ?????? ppencode
1?????? ppencode
- Shibuya Perl Mongers
- ?? ??
2?????
3Perl????????????
- Perl?????????3(???)
- ??????? ????????
- ???????? ????????????
- ???????????????!
- Perl??????????
- ????????????????!
- ???????????????????!
- ???????????!
? Lets ???????????
4Quiz ?????????????????
!/usr/bin/perl sin cos and s qq qx xor s x x
print uc chr lc ord qq sleep times x xor int log
cos xor eval and eval and print uc chr ord
scalar reverse qq exit binmode xor qq write qw
xor print uc chr ord scalar reverse qw tell my
print
?? ? ????? LLDN ????????????????
5Just Another Perl Hacker
- ????? JAPH
- ?just another perl hacker??????80x40???Perl?????
- ?????USENET???????????Perl??????????????
? ??????????JAPH
_at_asplit(/(\d)/, "4Hacker,2another3Perl1Just") sh
ift(_at_a)a_at_a print "_at_a1..4"
Randal Schwartz 1 Feb 1990 222858 GMT
Shibuya Perl Mongers????????5 (2004?12?16?) http
//shibuya.pm.org/blosxom/techtalks/200412.html
???1,500- ?? ?? (?)
6(?)STAR WARS
!/usr/local/bin/perl undef/_ltDATAgty/ODA\n
/ /ds_at_yodamaplengthsplitprint chr oct
join('',splice(_at_yoda,0,3))-111 while_at_yoda __DATA_
_ 00O00O000O00O0000 000O
DD000000O0 0DO0000000O0000O00 O00000
00O00000O0O 0000 0O0
O00 O00 00D 0DO 00O0 0O0
00D 000 DO0D00000D 0O00
DOD 000000O00000 000 O00O
DD0000D000O0 000 0O00O0000D00DO 0OD
D00O000D00O0 00000DO00O0 000 000O
00D0 O0D O00000O0DO0 0O000 OD0D
O00O0 0000 DDDO000000 O00O000000
0O000 O00DDO 00000 0O0D00 00O0O00000O
0O00O000000 0O0O00OD00000DDD 00O 0D0
DDD D0O 00O0D 00000O00000000 O00
DO0 D00D00O000 00D00 D0O00 O0000
000O000O00DO 000 00O0 0OD00
O00 000 0O000D000O00O0 000
0D0O000000O00O00 0 0 0O0D
0000 0O0 0O0000000O000O
http//www.cpan.org/misc/japh
7Obfuscated Programming
- ?????????
- JAPH ????????????????????just another perl
hacker????????? - ?????????????????????
- 80x40???????????????????
8(?)???????
package Earthsub Greet
_('Y','')_'!(Middle
Earth.ageltEarth
.age)?!(definedtimezOn
e2)?!(push_at_timeZone,loc
altime())?rotation?q?The Worl
d?q\wq\da-fq?..
?q."42b3d3728656
c6c6f6 0277f627c64672
b3072796e647 42b3b3rg7d"Ym
\\pu sh_at__,bless
c
ontinent
s\
pangaea l
ocal_at__local "o
cean"A(defi
nedcontinents)?
(vec(,
YYsplit(\' \',\
)3,YYsplit( q??,)2-
((Ytr/oa e
iu//)2))28160)?q
.q?!?\'?\'
AYs \Q.\Epack(
\'h\',j oin(q(),
grep_ Ym,,,
split("
",_at__0
)) )e
gexe d
"s ort
lt gt,
YY _at__
"'
s,(\r\n\s),,gs.Y.\x7e.g
evalGreet'the world'
http//www.perlmonks.org/index.pl?node_id329174
9ppencode ????
- Fun With Reserved Keywords ?
- ???????????
10ppencode ????
- ppencode ???
- ??????????(???????????) Perl????????????Perl?????
- ???????
echo -n "Have fun!" ppencode
!/usr/bin/perl cos xor print chr ord uc qq chr
uc xor print chr ord qq each ge xor print chr ord
qq eval ge xor print chr ord qw x eq x xor print
chr ord qq q eq xor print chr ord qw q fcntl q
xor print chr ord qw q uc q xor print chr ord qw
q no q xor print chr length q q while syswrite
setgrent symlink q
11Perl???? (220)
???/??? (38)
lt gt le ge eq ne cmp not and or xor if else
elsif while for foreach continue goto last local
map my next redo require return use tr y s m q qq
qr qw qx x
???? (182)
?????????
abs accept alarm atan2 bind binmode bless caller
chdir chmod chomp chop chown chr chroot close
closedir connect cos crypt dbmclose dbmopen
defined delete die do dump each eof eval exec
exists exit exp fcntl fileno flock fork formline
getc getlogin getpeername getpgrp getppid
getpriority getpwnam getgrnam gethostbyname
getnetbyname getprotobyname getpwuid getgrgid
getservbyname gethostbyaddr getnetbyaddr
getprotobynumber getservbyport getpwent getgrent
gethostent getnetent getprotoent getservent
setpwent setgrent sethostent setnetent
setprotoent setservent endpwent endgrent
endhostent endnetent endprotoent endservent
getsockname getsockopt glob gmtime grep hex
import index int ioctl join keys kill lc lcfirst
length link listen localtime log lstat mkdir
msgctl msgget msgrcv msgsnd no oct open opendir
ord pack pipe pop pos print printf push quotemeta
rand read readdir readlink recv ref rename reset
reverse rewinddir rindex rmdir scalar seek
seekdir select semctl semget semop send setpgrp
setpriority setsockopt shift shmctl shmget
shmread shmwrite shutdown sin sleep socket
socketpair sort splice split sprintf sqrt srand
stat study substr symlink syscall sysread system
syswrite tell telldir tie time times truncate uc
ucfirst umask undef unlink unpack untie unshift
utime values vec wait waitpid wantarray warn write
12??????
- ??
- 0 1 2 3 4 5 6 7 8 9 ???????!
- ??
- ?? , _at_, , ????? ??? , ???!
- ???? ??????? ?????!
- ??? \ () - ! ? .. ?!
- ????
- ??????? ()
- ??????????
- ????????????? -- ??????!
13ppencode ????
- ppencode ???
- ??????????(???????????) Perl????????????Perl?????
- ?????????????
- ???????? gen_ppencode
- ppencode ????????Perl?????
- ???????????????????
- ???????????? (220 x 220 x )
- ???????????????
- ?????????????(???????)
14??????????????????
- ????? ????? xor ???
- q/??/ ? q x??x ? q else ? ls
- qq/??/ ? qq x??x ? qq else ? ls
- qw(?? ??) ? qw x?? ??x ? qw sin cos
- print chr ord abc ? ???? a ???
- reverse ? ?????? ? ???????
- uc, uppercase ? tr/a-z/A-Z/
- length ? ?????? ? ???ASCII???
15Ajax?????
http//namazu.org/takesako/ppencode/demo.html
16ppencode ??????????
- ?????????????
- Perl ??????????????
- ??? Perl ?????????!
- ?????????????????!
- cd /usr/bin sudo ln s perl ppdecode
- uuencode ?????!
- ?????
- I love you ?????????????????
- ???Geek????????!
17?????
- ?????Perl JAPH??????
- http//www-6.ibm.com/jp/developerworks/linux/01102
6/j_l-japh.html - Perl Monks - Fun With Reserved Keywords
- http//www.perlmonks.org/index.pl?node_id290607
- CPAN AcmeEyeDrops
- http//search.cpan.org/asavige/Acme-EyeDrops-1.50
/
18???
- Lets ???????????
- Perl ???????????????
- awk ?
- Haskell ?
- Lisp ?
- ML ?
- Perl ? OK !
- PHP ?
- Python ?
- Ruby ?
?????!
19??????????????
- http//namazu.org/takesako/