Preliminary checkin of (mostly useless) Net::SAM perl module.

Net::SAM::StreamSession is currently unimplemented.
Net::Sam::[Datagram|Raw]Session block when they shouldn't and are buggy.
This commit is contained in:
brianr
2004-05-16 21:35:46 +00:00
committed by zzz
parent ff0023a889
commit 6003b2902f
5 changed files with 303 additions and 0 deletions

18
apps/sam/perl/samcat.pl Normal file
View File

@@ -0,0 +1,18 @@
#!/usr/bin/perl
use Net::SAM::RawSession;
use Net::SAM::DatagramSession;
$sam=Net::SAM::DatagramSession->new($ARGV[0], "BOTH", "tunnels.depthInbound=0");
print "Connected? " . $sam->connected() . "\n";
$me = $sam->lookup("ME");
print "Sending to $me.\n";
$sam->send($me,"fooquux");
$sam->readprocess();
($source, $message) = @{ $sam->receive() };
print "$source -- $message";