Re: Re: how create system users with php

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



M. Sokolewicz wrote:
shell_exec('pw useradd username -g groupname -d /home/username -m');
however, you'd need to be running as root, or atleast need to su to root; which is quite a security hazard

I recomend sudo. You can set strict restrictions on the executed commands and its arguments.



Umar Draz wrote:

Hi dear members!!
i want a script that i can add system user through
php. For example i have FreeBSD 5.3 for adding a user in freebsd i use
this command
pw useradd username -g groupname -d /home/username -m
now i want creating user through php what kind of
script will be required
thanks and regards
Umar Draz

-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux