Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Re^2: System commands using CGI

by nikhilB (Initiate)
on Dec 03, 2012 at 10:55 UTC ( #1006846=note: print w/replies, xml ) Need Help??

in reply to Re: System commands using CGI
in thread System commands using CGI

Thanks all for the response. I am trying to run a the perl script from the browser. The perl script is supposed to run some system level commands and print on the webpage. I figured out that the changes needed in the httpd.conf file and I was able to run some simple commands like ls and who from the browser. However I am unable to run the commands which require the root access for example useradd. Any idea what I need to do to execute the commands which require the root access ? Thanks, Nikhil.

Replies are listed 'Best First'.
Re^3: System commands using CGI
by Anonymous Monk on Dec 03, 2012 at 11:36 UTC
Re^3: System commands using CGI
by ColonelPanic (Friar) on Dec 03, 2012 at 11:57 UTC

    As Anonymous Monk pointed out, this is a bad idea. In fact, that is precisely why you can't do it: web servers are specifically set up to prevent that sort of thing.

    What do you want to do, anyway?

    When's the last time you used duct tape on a duct? --Larry Wall

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1006846]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (1)
As of 2018-02-22 21:00 GMT
Find Nodes?
    Voting Booth?
    When it is dark outside I am happiest to see ...

    Results (299 votes). Check out past polls.