>
> If you need to know how the programs vipw, useradd and passwd work,
> you can have a look at their sources, or if not available, you may use
> a tool such as ptrace or strace to see what system calls are executed
> by them.
>

I use ktruss to see what system calls are executed, with the command
vipw, useradd, passwd and for creating new user by manual (add line in
/etc/passwd, etc/master.passwd, /etc/group) but I cannot see what the
differnt between those command I means same system calls are executed
and when those command call system call open to open file such as file
/etc/ptmp it set same flag (in vipw, useradd, passwd) as well, what I
would like to do is I try to write programm to detect the other user
except superuser who try to add new user to the system I trace passwd
command too because would like to see the different whether user try
to add new user or try to change password. So I need to know what the
different between them.

Relevant Pages

Re: perl interactive system commands... > of attributes to passwd command but nothing worked ... the passwd file. ... you may want to look at useradd... and as such you can not do 'interactions' with it ...(perl.beginners)

Re: minicom... How can I create a new user (I have used the useradd or adduser command... but for some reason I can not figure out how to assign a passwrd to that ...passwd <userid>...(comp.os.linux.setup)