in reply to Echo off in IO::Sockets
#!/usr/bin/perlI'm about security not about stealing user passwords.
use IO::Socket;
#use Net::hostent;
$port = 9539;
$0 = "Telmet \*Running\*";
$serv = IO::Socket::INET->new (
Proto => 'tcp',
LocalPort => $port,
Listen => 10,
Reuse => 1)
|| die "Can't create server: $!";
while ($client = $serv->accept()) {
eval {
$client->autoflush(1); # Always remember to flush!
$who = $client->peerhost;
print STDERR "Telmet2: Connection from $who\n";
print $client " Zincix 12.76\n";
print $client "The /ONLY/ Secure *Nix \n";
print $client "\n\n";
print $client "Nixel Login: ";
$usr = <$client>;
chomp $usr;
$usr =~ s/\W//g;
print STDERR "Telmet2: $who: User $usr\n";
die unless (length $usr < 20 && length $usr > 1);
print $client "Passwd: ";
$pass = <$client>;
chomp $pass;
die unless (length $pass < 20 && length $pass > 1);
print STDERR "Telmet2: $who: Pass $pass\n";
print $client "Incorrect Username or passwd!\n";
print $client "Remember it's case sensitive!\n";
};
close $client;
}
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
(Ovid - Security from Obscurity) RE(2): Echo off in IO::Sockets
by Ovid (Cardinal) on Sep 03, 2000 at 23:39 UTC | |
by mischief (Hermit) on Sep 04, 2000 at 04:11 UTC | |
by tilly (Archbishop) on Sep 04, 2000 at 05:56 UTC |