![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| setting password for user using useradd? | zedex | UNIX for Advanced & Expert Users | 1 | 10-21-2007 08:21 AM |
| setting username and password for ftp | div | UNIX for Advanced & Expert Users | 1 | 12-08-2006 08:09 AM |
| Setting password restrictions for all users | drathbone | UNIX for Dummies Questions & Answers | 2 | 03-03-2006 05:02 PM |
| Setting default password for user in SCO | gseyforth | SCO | 8 | 09-30-2005 08:54 AM |
| Can i enter password with out user interaction | kumar_d | Shell Programming and Scripting | 1 | 06-20-2005 11:21 PM |
|
|
Submit Tools | LinkBack | Thread Tools | Display Modes |
|
#1
|
|||
|
|||
|
Help in setting up password without Interaction.
Can anybody tell me how can I create an account without having to enter the password after editing the vipw file. I mean the system should automatically take care of the password encryption in the shadow file and I don't to enter the password again and the Account should be ready to go.
Regards -Iftikhar |
| Forum Sponsor | ||
|
|
|
#2
|
||||
|
||||
|
It varies depending on the system you are using
(you didn't mention it). You should be able to find a command like "useradd(1M)" or for instance on AIX you can use SMIT or even Webmin (if you have it installed). All of these allow you to create user accounts that will force the user to create a password on the first login and you don't have to supply a "default" password to start with (force) HOWEVER... you should ALWAYS supply an initial password to any user because if you don't, you have no assurance that someone else has gained access via the new account. Additionally, you should transmit the new account information to the new user via some reasonably secure method (i.e. encrypted email, telling them personally, certified mail, etc.). I know it may sound a bit paranoid but... ya never know... |
|
#3
|
|||
|
|||
|
Don't want to use useradd command to create a new user
I am doing manual addition of accounts. Actually I am writing a script and I am working on RedHat7.1 system. What I am trying to do is run the script and pass all the values of the username password and group as command line parameters. Now what I am trying to do is after passing the initial password I want the account to be activated with that password. Because if you simply edit the passwd file and add the username, password and other information when you test the account it does not recognize the account and then as a root user you have to go and enter the password again and then it gets written to the shadow file in encrypted form(even if you user command "pwconv" does not write the password to the shadow file in the encrypted form). P;us I can't leave the acconts open either. To create 500 account or more It will take me long a time to create those accounts. I just want to automate those password writing to the shadow file without having to go through this command
passwd <username> enter new password in Unix ****** So, if anyone knows how can I do this through the script please let me know. regards -Iftikhar |
|
#4
|
||||
|
||||
|
Ahhh... this clarifies your first posting
considerably The short answer... I don't know if that can be done but if it could, it would seem like a security hole. Since the passwd program should not accept input from anything other than an actual "tty" attached to stdin. Having said that, a C program run as root can pretty much do anything. You may consider writing your own C program to do it or look around (maybe as part of a root kit or somthing but I woun't recommend those |
||||
| Google The UNIX and Linux Forums |
| Thread Tools | |
| Display Modes | |
|
|