Adding a user manually to the /etc/passwd file, by tacking on this line:
Code:
testuser:x:500:500:Test User:/home/testuser:/bin/bash
then saving, I get this:
Code:
[root@localhost ~]# vipw
You are using shadow passwords on this system.
Would you like to edit /etc/shadow now [y/n]?
Now, if I enter y, I get taken to the shadow file, obviously. What should I enter here?? If I just enter a random password string such as this line:
Code:
testuser:asdfweusljasdfunwdfsasasf
First I have to force it to write to a readonly file, then when I do the following, I get an error.
Code:
[root@localhost ~]# passwd testuser
Changing password for user testuser.
passwd: Authentication token manipulation error
How am I actually meant to do this? I know I can do this with useradd and through x, but how can I manually do it?