in reply to Executing external Programs

you can use IPC::Open2 or IPC::Open3 for control over more than 1 of the 3 standard filedescriptors a process has. In this case open3 (which gives you filehandles for STDIN, STDOUT and STDERR) should do the trick.