[prev in list] [next in list] [prev in thread] [next in thread]
List: postfix-users
Subject: OT: Base64 encoding in obfuscated Perl (was: Re: How to prevent the '<hostname> Daily Mail Report fo
From: Liviu Daia <Liviu.Daia () imar ! ro>
Date: 2003-08-31 16:55:51
[Download RAW message or body]
On 31 August 2003, Andreas Meyer <anmeyer@anup.de> wrote:
[...]
> I do it this way:
>
> #!/bin/sh
>
> DATE=`date -d "yesterday"`
>
> perl /root/bin/pflogsumm.pl -d yesterday --problems_first --verp_mung --verbose_msg_detail \
> --iso_date_time --smtpd_stats --ignore_case -h 10 -u 10 --mailq \
> /var/log/mail > $$ && /usr/bin/mpack -s "Postfix on DELTA $DATE" -d /root/heute.txt $$ \
> mail1@meyer.home && rm -f $$
Off topic, but still related: can some Perl-Fu master out there
please explain (preferably in layman terms) why the following
abomination works fine for encoding files as Base64:
perl -MMIME::Base64 -e 'print encode_base64 $b while (read STDIN, $b, 57)' <file
while this one only works for small files:
perl -MMIME::Base64 -pne '$/=\57; $_=encode_base64 $_' <file
Regards,
Liviu Daia
--
Dr. Liviu Daia e-mail: Liviu.Daia@imar.ro
Institute of Mathematics web page: http://www.imar.ro/~daia
of the Romanian Academy PGP key: http://www.imar.ro/~daia/daia.asc
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic