unix/mac questions about password changes or storage, the related `.passwd` file or `passwd` command
Questions tagged [passwd]
140 questions
1
vote
1 answer
Using OpenSSL to generate passwd on iPhone
I have the OpenSSL library working fine on my iPhone, and can create hashes etc... I was just wondering how I'd create a salted password within the app so it matches the output of this:
openssl passwd -crypt -salt xxxxxxxxxxxx password
I'm looking…

a1phanumeric
- 814
- 2
- 12
- 29
1
vote
0 answers
domain users and permissions in linux
I have multiple Linux servers (Ubuntu) that are joined to an active directory, and users are using their own credentials to log in, the problem is where I wanna define uid and gid for these users to grant root permission at the start (I need to…

Milad Zahmatkesh
- 11
- 1
1
vote
1 answer
Changing eDirectory Password From Linux Machine
I have Configured LDAP Authentication for my Linux Machines. The LDAP Server is Novell eDirectory. The LDAP Users are able to login into the machine. But when i am issuing passwd command it is asking LDAP password then asking to give me new…

Dungeon Hunter
- 19,827
- 13
- 59
- 82
1
vote
1 answer
Ansible user module: how to have the UID defined to a default setting?
I have a list of dictionaries containing user details. Some of them need specific UIDs, but most of them don't.
Example:
# list_of_dictionaries__users
- { name: user1, uid: 654, group: user1 }
- { name: user2, group: user2 }
- { name: user3,…

KrNeki
- 135
- 8
1
vote
1 answer
Where I can find the Python `pwd` module for MS Windows?
I use the Python standard library pwd module on GNU+Linux, but now I try to run my application in Microsoft Windows and can not find it.
I'm using python 2.6.6. Where can I find the pwd module for use in Python on MS Windows?

Charlires
- 863
- 1
- 11
- 30
1
vote
1 answer
How to handle errors from passwd in expect script?
I'm trying to create an expect script to update a user's password non-interactively. New to expect and shell scripting. I want to be able to capture and handle errors encountered. For example, if I'm running passwd normally, and my new password…

Scooter
- 11
- 2
1
vote
1 answer
Identify Linux passwd file
I need help in writing a function (python preferably) to identify if a file is /etc/passwd or etc/shadow. So far I have tried using print(pw.getpwall()) but this reads the file from the os env. I need a library that takes input and can tell if a…

secjedi
- 13
- 4
1
vote
2 answers
Enabling root user on Ubuntu 18.04
I’ve bought a bare metal server and I was provided with a non-root user to log in.
I’ve tried enabling the root with sudo passwd root and changing the password and after I used sudo passwd -u root but I still get invalid username/password when I try…

Robert Bant
- 11
- 2
1
vote
0 answers
PAM: Confirm old password before changing to new password in SUSE Linux
OS: SUSE Linux Enterprise Server 10
Login as root
server:~ # cat /etc/pam.d/common-password | grep -i ^PASS
password required pam_cracklib.so retry=3 minlen=9 dcredit=-1 ucredit=-1 lcredit=-1 ocredit=-1 difok=4
password required …

carlregencia
- 15
- 5
1
vote
3 answers
Errors while changing "passwd" in openwrt
I am using ext4 as my root file system. I am using OpenWRT Chaos Calmer. When I change the passwd, I see the following error sometimes:
root@US16SIQC:~# passwd
Changing password for root
New password:
Bad password: too short
Retype password:…

Ramana Reddy
- 369
- 1
- 8
- 28
1
vote
2 answers
Problem with an expect script
I'm trying to create a script to update a password in a
non-interactive way. It's working on my laptop but fails on my server.
Both are running the same configuration, using Etch.
This is the script:
#!/usr/bin/expect -f
# Change user passwd
set…
Pooly
1
vote
1 answer
how to pass a user password ,stored in config file to passwd command
I am trying to create linux users using a script . The username and corresponding password are stored in a config file.
config file is given below
username="user1"
password="passxxx"
using a shell script i am creating linux users with username and…

Adhz
- 55
- 7
1
vote
0 answers
expect / passwd script over ssh: Authentication token manipulation error
I want to create script for password change using ssh. So I'm using expect and bash to run my script.
This is part of my code:
1 #!/usr/bin/expect -f
1
2 set user [lindex $argv 0]
3 set host [lindex $argv 1]
4 set password [lindex $argv…

syncerror
- 131
- 1
- 10
1
vote
0 answers
Change/Set password for git system account on omnibus gitlab server
We installed gitlab in omnibus method.We are using gitlab-rake console for lot of our administration activity.If it is a one time activity we can get root access and do our activity as sudo.In case of permanent scheduled operation we are facing…

grethinam
- 43
- 1
- 6
1
vote
1 answer
change user password using shell_exec function
I have created a new user and password. Now I need to change the username and password from the web page. I am able to change the username using usermod.
But I am not able to change to password using the passwd command.
Here the…

user12345
- 357
- 2
- 3
- 11