Re: apache user cannot execute useradd via sudo :(
| From: | Michael A. Peters | Date: | Sat, 23 May 2009 04:36:41 +0000 |
| Subject: | Re: apache user cannot execute useradd via sudo :( | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-292998@lists.php.net to get a copy of this message | ||
vuthecuong wrote:
I'm not that familiar with sudo, but I suspect it may have to do with the fact apache is a user without a shell. look in the sudo log file. If you don't see anything, look in /var/log/secure and /var/log/messages and /var/log/httpd/error_log If you don't see the problem, log into a root shell. Then run su apache to become the apache user and try the command and see what happens. Really though, this isn't a job for sudo. It's a job for a suid root shell script (I'd suggest perl or python or maybe tcl/expect).Yeah I know my script don't care at all about security. I'm keeping it fot the sake of simplicity. After making it 'work', I will take a look seriously about security. So, why it not create user for me? thanks and regards