I wrote a simple script that does essentially this. I even wrote a little scheduler for it as NT isn't as neat as *nix for scheduling. I felt very proud, then I discovered that Lincon Stein's book had pretty much the same thing in already, plus his was better.
Have a look at his book, it's got a very good desciption of all things Net:: and CGI. Perl Network Programming