socket program

All,

I am looked to develop a socket program from one Solaris server to another Solaris server to send UDP packets from a source UDP port number 2505 on the first server to the source port 2505 on the second server. Is it possible to do? What is the best way to do this?

I want to set the destination port on the first server to UDP port number 29000. I want the second server to have the source port be 2505. Any help would be appreciated.

Thanks

I'd tend to use Perl for problems of this type. Look at this tutorial:

Socket Programming in PERL

Or this one:

PERL Socket - Networking Programming