aboutsummaryrefslogtreecommitdiffstats
path: root/fetchmail-SA-2010-02.txt
Commit message (Expand)AuthorAgeFilesLines
* Convert most references from berlios.de to sourceforge.net.Matthias Andree2014-05-211-12/+12
* Relicense security/errata notices as CC BY-ND 3.0.Matthias Andree2012-05-031-10/+12
* Re-sign SA 2010-02.Matthias Andree2010-05-061-16/+26
* Fix history date in fetchmail-SA-2010-02.txt.Matthias Andree2010-05-061-27/+17
* Complete and sign fetchmail SA 2010-02.Matthias Andree2010-05-061-28/+44
* Document apparent glibc relation of CVE-2010-1167.Matthias Andree2010-04-291-0/+7
* SECURITY FIX (one missed): DoS on EILSEQ in report_*() in -vv and multibyte-l...Matthias Andree2010-04-241-6/+23
* Add CVE name. Fix Type: (spotted by Florian Weimer.)Matthias Andree2010-04-201-2/+2
* Add a note that security announcements may appear before releases.Matthias Andree2010-04-191-0/+2
* SECURITY FIX: DoS on EILSEQ in report_*() in -vv and multibyte-locales.Matthias Andree2010-04-181-0/+209
Name.Exception */ .highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */ .highlight .nl { color: #336699; font-style: italic } /* Name.Label */ .highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */ .highlight .py { color: #336699; font-weight: bold } /* Name.Property */ .highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */ .highlight .nv { color: #336699 } /* Name.Variable */ .highlight .ow { color: #008800 } /* Operator.Word */ .highlight .w { color: #bbbbbb } /* Text.Whitespace */ .highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */ .highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */ .highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */ .highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */ .highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */ .highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */ .highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */ .highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */ .highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */ .highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */ .highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */ .highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */ .highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */ .highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */ .highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */ .highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */ .highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */ .highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
#!/usr/bin/perl

BEGIN { $SIG{'__WARN__'} = sub {};};

$hostname = "criens.u-psud.fr";
$username = "p99dreyf";
$passwd = "xxxxxxxx";
$command = "exec ~/bin/imapd";

use Net::Telnet ();
$host = new Net::Telnet (Timeout => 10,
                         Port => 23,
                         Prompt => '/p99dreyf>\s?$/',
                         Cmd_remove_mode => 1);

$host->option_accept(Dont => &Net::Telnet::TELOPT_ECHO,
                     Wont => &Net::Telnet::TELOPT_ECHO);
                     open (FILE,">log");
$host->dump_log("log2");
$host->input_log("log3");
## Issue some commands.
$host->open($hostname);
#$host->login($username, $passwd);
$host->waitfor('/login:\s?$/');
$host->print("$username");
$host->waitfor('/Password:\s?$/');
$host->print("$passwd");
$host->waitfor('/p99dreyf>\s?$/');

$host->print("$command");
$strip=1;
while ($strip) {
        $greeting=$host->getline();
   if ($greeting=~/^\* PREAUTH.*$/) { print "$greeting"; $strip=0;};
}
    do {
      do {
        $cmd=<STDIN>;
        chop $cmd;
      } while ($cmd !~/[A-Za-z0-9]/);
      $host->print("$cmd");
      print FILE ">>$cmd<<\n";
      do {
        $line=$host->getline();
        chop($line);
        print "$line\n";
        print FILE "<<$line<<\n";
      } while (($line!~/^[A-Za-z0-9]+ (OK|BAD|Expunge).*$/) &&
                ($line!~/^\* BAD.*$/));
      print FILE "--next cmd\n";
    } while ($line!~/^[A-Za-z0-9]+ OK LOGOUT.*$/);

exit;