idova has asked for the wisdom of the Perl Monks concerning the following question:

I was some time ago set the task of creating a chat program, and for the most i have succeeded :). I know the socket code that i made works for most servers but a firewall prevents others from seeing it. We have found a host that will let us run the chat server and said there is no firewall but it dont seem to work. The server owner tells me that a cobalt raq4 server behaves slightly different from other servers and that the chat code may have to change. Now to the question, where can i find perl code for a chat server that opens up ports for tcp connection for a client to send to which runs on a cobalt server.

this is the current code i used but doesn't seem to quiet work

use POSIX qw(setsid); use IO::Socket; use Socket; use IO::Select; $verb = 50; # verbosity for console messages $main = new IO::Socket::INET (LocalHost => '-not showing the ip here, +sorry people', LocalPort => 4448, Listen => 5, Proto => 'tcp', Reuse => 1 ) || die $!; $zero = chr(0); $/ = $zero; $\ = $zero; $| = 1; #&daemonize; # Initialise IO::Select --------------------------- $handles = new IO::Select->new($main); print "Starting listening cycle\n" if ($verb > 1); while(@send_pipe = $handles->can_read) { ..... }

Replies are listed 'Best First'.
Re: ports and sockets on a cobalt server
by dws (Chancellor) on Sep 27, 2003 at 23:14 UTC
    The server owner tells me that a cobalt raq4 server behaves slightly different from other servers and that the chat code may have to change.

    I'm suspicious of his claim, and recommend that you prod him for details. That might give us context in which to answer your question.