I want to write GUI aplication for creating linux users in pyGTK. In linux console it’s not a problem, because of the commands useradd and adduser, but I don’t know how to do that via GUI application?
I want to create GUI form with 3 entries (first “name”, second “password”, third “confirm password”) and button “add”. I don’t know how to send variable with password to useradd and adduser commands. What option should I use? Or there is another way?
You can call something like
where
PASSWORDis what you get as a result ofcrypt()function defined inunistd.h.As you’ve found out yourself, in the case of Python it looks like this