Perhaps you do not wish to go this route but I use: system(escapeshellcmd("smbpasswd -a -m $username")); ni wrote: > In our ldap, we have people who are in the following objectclasses