🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.lang.perl
Article #52154

Re: perl i wysylanie maila [Mail::Sender]

#52154
From: MaRc
Date: Thu, 13 Jan 2011 17:26
69 lines
3418 bytes
> Ustaw debug na zapis do pliku a potem go obejrzyj:

ok. uzylem opcj debugowania i Net::SMTP.
widze ze nie tylko o dluga linijke chodzi.

oto kawalek kodu:

my $message = <<"EOM";
This is a test. Please ignore this message.
EOM

my $message1 = <<"EOM";
This is a test. Please ignore this message.
EOM

$smtp->data();
$smtp->datasend( "Subject: to jest temat\n" );
$smtp->datasend( $message );
for (my $i=0; $i<101; $i++){
$smtp->datasend( $message1 );
}
$smtp->dataend;
$smtp->quit;

specjalnie zrobilem petle for zeby wykluczyc dluga linijke.

oto wydruk z odpalenia skryptu:

Server variables assigned
Net::SMTP>>> Net::SMTP(2.31)
Net::SMTP>>>   Net::Cmd(2.29)
Net::SMTP>>>     Exporter(5.62)
Net::SMTP>>>   IO::Socket::INET(1.31)
Net::SMTP>>>     IO::Socket(1.30_01)
Net::SMTP>>>       IO::Handle(1.27)
Net::SMTP=GLOB(0x9935e90)<<< 220 pat.example.pl ESMTP Postfix (Debian/GNU)
Net::SMTP=GLOB(0x9935e90)>>> EHLO alix.example.pl
Net::SMTP=GLOB(0x9935e90)<<< 250-pat.example.pl
Net::SMTP=GLOB(0x9935e90)<<< 250-PIPELINING
Net::SMTP=GLOB(0x9935e90)<<< 250-SIZE 30720000
Net::SMTP=GLOB(0x9935e90)<<< 250-VRFY
Net::SMTP=GLOB(0x9935e90)<<< 250-ETRN
Net::SMTP=GLOB(0x9935e90)<<< 250-STARTTLS
Net::SMTP=GLOB(0x9935e90)<<< 250-AUTH PLAIN LOGIN
Net::SMTP=GLOB(0x9935e90)<<< 250-AUTH=PLAIN LOGIN
Net::SMTP=GLOB(0x9935e90)<<< 250-ENHANCEDSTATUSCODES
Net::SMTP=GLOB(0x9935e90)<<< 250-8BITMIME
Net::SMTP=GLOB(0x9935e90)<<< 250 DSN
Server connection opened
Net::SMTP=GLOB(0x9935e90)>>> AUTH PLAIN hfjkashfuihauihfahf
Net::SMTP=GLOB(0x9935e90)<<< 235 2.7.0 Authentication successful
Net::SMTP=GLOB(0x9935e90)>>> MAIL FROM:<alix@example.pl>
Net::SMTP=GLOB(0x9935e90)<<< 250 2.1.0 Ok
Net::SMTP=GLOB(0x9935e90)>>> RCPT TO:<marcin@example.pl>
Net::SMTP=GLOB(0x9935e90)<<< 250 2.1.5 Ok
Server variables checked
Net::SMTP=GLOB(0x9935e90)>>> DATA
Net::SMTP=GLOB(0x9935e90)<<< 354 End data with <CR><LF>.<CR><LF>
Net::SMTP=GLOB(0x9935e90)>>> Subject: to jest temat
Net::SMTP=GLOB(0x9935e90)>>> This is a test. Please ignore this message.
Net::SMTP=GLOB(0x9935e90)>>> This is a test. Please ignore this message.
[...]
Net::SMTP=GLOB(0x9935e90)>>> This is a test. Please ignore this message.
Net::SMTP=GLOB(0x9935e90)>>> This is a test. Please ignore this message.
Net::SMTP=GLOB(0x9935e90)>>> This is a test. Please ignore this message.
Net::SMTP=GLOB(0x9935e90)>>> .
Net::SMTP=GLOB(0x9935e90): Timeout at ./mail2.pl line 63
Net::SMTP=GLOB(0x9935e90)>>> QUIT
Technical Details
Message-ID: <ignckp$nl0$1@pippin.nask.net.pl>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!news.supermedia.pl!news.nask.pl!news.nask.org.pl!not-for-mail
References: <ign5o5$k8j$1@pippin.nask.net.pl> <68pssgjw3b+B1D@richard.huge.strangled.net>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!news.supermedia.pl!news.nask.pl!news.nask.org.pl!not-for-mail
From: MaRc <marc@gmails.com>
Newsgroups: pl.comp.lang.perl
Subject: Re: perl i wysylanie maila [Mail::Sender]
Date: Thu, 13 Jan 2011 18:26:49 +0100
Organization: NASK - www.nask.pl
Lines: 75
Message-ID: <ignckp$nl0$1@pippin.nask.net.pl>
References: <ign5o5$k8j$1@pippin.nask.net.pl> <68pssgjw3b+B1D@richard.huge.strangled.net>
NNTP-Posting-Host: 193.59.37.1
Mime-Version: 1.0
X-Trace: pippin.nask.net.pl 1294939609 24224 193.59.37.1 (13 Jan 2011 17:26:49 GMT)
X-Complaints-To: abuse ATSIGN nask.pl
NNTP-Posting-Date: Thu, 13 Jan 2011 17:26:49 +0000 (UTC)
In-Reply-To: <68pssgjw3b+B1D@richard.huge.strangled.net>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.13) Gecko/20101208 Thunderbird/3.1.7
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit