Hide output from perl script system command

dan radom dan at radom.org
Wed Nov 12 16:42:04 CST 2003


* brad (brad at bradandkim.net) wrote:
> I am adding a system command to be run inside of an existing perl script
> that is triggered from a web form.  Now that I have added the system
> command (an expect script) the entire send/expect output is displayed on
> the web page.  I cannot have the output go to the web browser so I need
> a way around this.  I no next to zero about perl.  Is there an easy way
> to do this?  Are there security issues having an expect script that logs
> into another server and runs a set of commands on that server be
> triggered from a web form?
> 

call your system command with > /dev/null 2>&1 to send sedout and stderr
to the bit bucket.

dan




More information about the Kclug mailing list