Skip to content

Instantly share code, notes, and snippets.

@viliampucik
Created August 10, 2016 07:24
Show Gist options
  • Save viliampucik/133ec80d354e3e1362c5cc66474a00bb to your computer and use it in GitHub Desktop.
Save viliampucik/133ec80d354e3e1362c5cc66474a00bb to your computer and use it in GitHub Desktop.
perl -MPOSIX -MIO::Socket -We '
my $s = IO::Socket::INET->new(
Proto => "udp",
LocalAddr => "0.0.0.0:162"
);
while ( $s->recv( $_, 65535 ) ) {
print strftime( "%F %T", localtime ), " ", $s->peerhost(), " $_\n";
}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment