note
Sarten X
You can, though I'm not sure if there's any quirks to it (including how it behaves when not run from inetd)
<code>
my $hersockaddr = getpeername(STDOUT);
my ($port, $iaddr) = sockaddr_in($hersockaddr);
my $ip = inet_ntoa($iaddr);
</code>
That gives you <code>$port</code> and <code>$ip</code> nicely ready to use.
544341
633233