  Sir Meowmix III
@windstream.net
| reply to Dennis Re: running a shell script via cgi web interface
I believe that 'nobody' should be able to write to /tmp without issue, would you mind sharing the code here? I'm assuming it's written in Bash?
How are you handling, in the code, the HTTP POST/GET? How are you sure it's working correctly, are you able to echo it back and see it? Are you correctly reading the CGI input from stdin? |
|
  Dennis Premium,Mod join:2001-01-26 Algonquin, IL
·AT&T Yahoo
Host: Chicago Users Find Hot Deals Users find Hot Dea.. Requests for Hot D.. Home Repair & Impr..
1 edit | well, here is the jist of the code...at least the part I am having problems with. I have to remove some bits of it since it's for work and all...
here's teh cgi:
and here is the shell script called dennis.sh
Those touches in the beginning....never happen. I works just fine when I do it from the cli of course...but not via apache. I originally added them in order try and fix this problem but tit seems they don't. And of course the $1 is the variable I'm passing.
When I have it use a pre-existing file (which won't work for me, was only for testing) then this is the ownership I get.
-- My Blog. Because I desperately need the acknowledgement of others.
Visit the Judd Family website to see my kids! |
|
  nwrickert sand groper Premium,MVM join:2004-09-04 Geneva, IL | Those touches in the beginning....never happen. That's probably because "$1" is undefined. -- AT&T dsl; Westell 327w modem/router; openSuSE 11.0; firefox 3.0.10 |
|
  Dennis Premium,Mod join:2001-01-26 Algonquin, IL
·AT&T Yahoo
Host: Chicago Users Find Hot Deals Users find Hot Dea.. Requests for Hot D.. Home Repair & Impr..
2 edits | said by nwrickert :Those touches in the beginning....never happen. That's probably because "$1" is undefined. ....ok well so if that's the case then if the touches are indeed happening, there must be frament files in the /tmp directory...
so yeah, ok.....the variable must not be passing. So $1 is just a cli variable, and $HTTP_POST would be necessary in its stead.
I'll try that and see what happens.
-- My Blog. Because I desperately need the acknowledgement of others.
Visit the Judd Family website to see my kids! |
|