# passwd

A Linux command-line utility for changing user account passwords and password validity settings.

This is one page of public article previews, not the complete archive. Follow Next page to continue. Summaries are not the original full articles.

## Hpf-passwd: Easily change passwords while using \`hashedPasswordFile\`

DevFeed: [Hpf-passwd: Easily change passwords while using \`hashedPasswordFile\`](<https://devfeed.tech/articles/hpf-passwd-easily-change-passwords-while-using-hashedpasswordfile-31351.md>)

Original publisher: [Read original article](<https://discourse.nixos.org/t/hpf-passwd-easily-change-passwords-while-using-hashedpasswordfile/79254>)

Author: Anomalocaris

Published: 2026-07-31T01:54:54Z

Content type: article

Language: en

Sources: [Announcements - NixOS Discourse](<https://devfeed.tech/sources/announcements-nixos-discourse.md>)

Topics: [passwords](<https://devfeed.tech/topics/passwords.md>), [passwd](<https://devfeed.tech/topics/passwd.md>), [configuration](<https://devfeed.tech/topics/configuration.md>), [account](<https://devfeed.tech/topics/account.md>), [systems](<https://devfeed.tech/topics/systems.md>)

Tags: [announcements](<https://devfeed.tech/tags/announcements.md>), [config](<https://devfeed.tech/tags/config.md>), [passwd](<https://devfeed.tech/tags/passwd.md>), [passwords](<https://devfeed.tech/tags/passwords.md>), [script](<https://devfeed.tech/tags/script.md>), [systems](<https://devfeed.tech/tags/systems.md>)

### AI overview

The author introduces hpf-passwd, a standalone script for changing passwords for NixOS user accounts configured with hashedPasswordFile. It imitates passwd's semantics but is not a complete drop-in replacement and currently lacks features such as password expiration management.

### Source excerpt

For a while, I've used users.users.*.hashedPasswordFile with users.mutableUsers = true to minimize configuration drift. However, as far as I could tell, no one had created a convenient way to set or change these passwords, so I wrote a quick and dirty script and called it a day. More recently, I was reworking this script and realized I could decouple it completely from my config, spin it off into its own project, and polish it up so other people could benefit from it. The result is hpf-passwd. Currently, it's a single script that mainly just lets you change the password of a given user account, provided it has users.users.<username>.hashedPasswordFile set. Befitting its name, it tries to mimic passwd's semantics to try to be intuitive. However, it can never be a 1:1 drop-in replacement. As far as I am aware, there is no way to set things like expiration dates for passwords managed like this. I plan to eventually add some more features, like a chpasswd-style script, and features that ensure all the users with hashedPasswordFile have a password set to help with bootstrapping, but it's currently pretty barebones. However, it is enough for my personal needs at the moment and so I figure it is a good time to get some more eyes on it. github.com GitHub - Anomalocaridid/hpf-passwd: Manage passwords on NixOS systems that use... Manage passwords on NixOS systems that use `hashedPasswordFile` 1 post - 1 participant Read full topic

## Linux turn OFF password expiration / aging

DevFeed: [Linux turn OFF password expiration / aging](<https://devfeed.tech/articles/linux-turn-off-password-expiration-aging-41967.md>)

Original publisher: [Read original article](<https://www.cyberciti.biz/tips/setting-off-password-aging-expiration.html>)

Author: Vivek Gite

Published: 2024-09-20T11:46:01Z

Content type: tutorial

Language: en

Sources: [nixCraft: Linux Tips, Hacks, Tutorials, And Ideas In Blog Format (RSS/FEED)](<https://devfeed.tech/sources/nixcraft-linux-tips-hacks-tutorials-and-ideas-in-blog-format-rss-feed.md>)

Topics: [passwords](<https://devfeed.tech/topics/passwords.md>), [Linux](<https://devfeed.tech/topics/linux.md>), [Users](<https://devfeed.tech/topics/users.md>), [passwd](<https://devfeed.tech/topics/passwd.md>), [Shell](<https://devfeed.tech/topics/shell.md>)

Tags: [account](<https://devfeed.tech/tags/account.md>), [command](<https://devfeed.tech/tags/command.md>), [debian-linux](<https://devfeed.tech/tags/debian-linux.md>), [howto](<https://devfeed.tech/tags/howto.md>), [linux](<https://devfeed.tech/tags/linux.md>), [passwd](<https://devfeed.tech/tags/passwd.md>), [password](<https://devfeed.tech/tags/password.md>), [passwords](<https://devfeed.tech/tags/passwords.md>), [redhat-fedora-linux](<https://devfeed.tech/tags/redhat-fedora-linux.md>), [root-user](<https://devfeed.tech/tags/root-user.md>), [safety](<https://devfeed.tech/tags/safety.md>), [security](<https://devfeed.tech/tags/security.md>), [suse-linux](<https://devfeed.tech/tags/suse-linux.md>), [sys-admin](<https://devfeed.tech/tags/sys-admin.md>), [tip-of-the-day](<https://devfeed.tech/tags/tip-of-the-day.md>), [tips](<https://devfeed.tech/tags/tips.md>), [troubleshooting](<https://devfeed.tech/tags/troubleshooting.md>), [ubuntu-linux](<https://devfeed.tech/tags/ubuntu-linux.md>), [users](<https://devfeed.tech/tags/users.md>)

### AI overview

A Linux tutorial explaining password aging and expiration, including how to inspect account settings with chage, disable expiration for a user, and verify the resulting settings. It recommends using chage instead of directly editing /etc/shadow for safety.

### Source excerpt

The /etc/shadow file stores the actual password in encrypted format using a hash (salted) function for the user's account with additional properties related to the user passwords, such as password expiration date or password aging. The /etc/passwd stores usernames and their properties, such as home directory, login shell, and more. The password expiration information for a user is contained in the last six fields. The Linux password expiration for a select user can be disabled by editing the /etc/shadow file. However, I recommend using the chage command for safety reasons. The chage command changes the number of days between password changes and the last password change date. The Linux system uses this information to determine when users must change their passwords. Love this? sudo share_on: Twitter - Facebook - LinkedIn - Whatsapp - Reddit The post Linux turn OFF password expiration / aging appeared first on nixCraft.

## Command to change root password

DevFeed: [Command to change root password](<https://devfeed.tech/articles/command-to-change-root-password-27621.md>)

Original publisher: [Read original article](<https://gagor.pro/2014/05/command-to-change-root-password/>)

Author: Tom

Published: 2014-05-08T00:00:00Z

Content type: tutorial

Language: en

Sources: [Tomasz Gągor](<https://devfeed.tech/sources/tomasz-gagor.md>)

Topics: [passwd](<https://devfeed.tech/topics/passwd.md>), [Command-line interface](<https://devfeed.tech/topics/cli.md>), [passwords](<https://devfeed.tech/topics/passwords.md>)

Tags: [bash](<https://devfeed.tech/tags/bash.md>), [command](<https://devfeed.tech/tags/command.md>), [command-line](<https://devfeed.tech/tags/command-line.md>), [linux](<https://devfeed.tech/tags/linux.md>), [passwd](<https://devfeed.tech/tags/passwd.md>), [password](<https://devfeed.tech/tags/password.md>), [root](<https://devfeed.tech/tags/root.md>)

### AI overview

A short tutorial shows how to change the root password from the command line without interactive input, using an echo and chpasswd pipeline.

### Source excerpt

Everybody knows passwd command but it's useless when you need to change ex. root password from command line without waiting for input. In such case oneliner below could help: echo "root:new_password" | chpasswd

## Włam na lokalne konto root'a

DevFeed: [Włam na lokalne konto root'a](<https://devfeed.tech/articles/w-am-na-lokalne-konto-root-a-27492.md>)

Original publisher: [Read original article](<https://gagor.pro/2011/08/wlam-na-lokalne-konto-roota/>)

Author: Tom

Published: 2011-08-27T00:00:00Z

Content type: tutorial

Language: pl

Sources: [Tomasz Gągor](<https://devfeed.tech/sources/tomasz-gagor.md>)

Topics: [Linux](<https://devfeed.tech/topics/linux.md>), [passwd](<https://devfeed.tech/topics/passwd.md>), [Bash](<https://devfeed.tech/topics/bash.md>), [Kernel](<https://devfeed.tech/topics/kernel.md>)

Tags: [bash](<https://devfeed.tech/tags/bash.md>), [kernel](<https://devfeed.tech/tags/kernel.md>), [linux](<https://devfeed.tech/tags/linux.md>), [passwd](<https://devfeed.tech/tags/passwd.md>)

### AI overview

This Polish tutorial describes a method for resetting a Linux root password when the existing password is unavailable. It explains editing the GRUB kernel parameters to boot directly into Bash with root privileges, using passwd to change the password, and then rebooting. The article notes that the method does not work on every Linux system, particularly systems using initramfs-tools.

### Source excerpt

Jeżeli tu zaglądasz pewnie zdarzyło Ci się kiedyś, że przykładowo wygrzebujesz jakiś stary serwer i nie masz pojęcia co na nim było, ani do czego służyło, czy jeszcze działa... Albo jeszcze inaczej - serwer działał tak długo, że wszystkie osoby znające hasło na root'a przeszły na emeryturę lub zmarły... Nieistotne 😃 Jest pewna prosta sztuczka, pozwalająca wbić się na konto root'a nie znając hasła - dając nam możliwość jego zmiany. Potrzebne dwa restarty ale za to nie trzeba korzystać z żadnychlive cd.