in reply to Question about IO::Socket
Given that IO::Socket is based on IO::Handle, I would suggest looking there for the read, print, sysread, syswrite functions. You should be able to read and write to an IO::Socket through these functions.