#!/usr/bin/perl use warnings; use IO::Socket; my $sock = new IO::Socket::INET ( PeerAddr => 'xelix.net', PeerPort => '20400', Prot => 'tcp', Timeout => 10, ) || die("Failed to create sock $!\n"); print "Connecting\n"; while (1) { $buf = scalar<$sock>; print $buf; }