-
Notifications
You must be signed in to change notification settings - Fork 241
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement reading password from pipe/stdin #927
Conversation
Add alternative function to agetpass for reading password from stdin or pipe. Signed-off-by: Tomas Halman <tomas@halman.net>
Which use case does this cover compared to what |
Hmm, I found that my PR does not work correctly with PAM. Let me investigate it first. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't remove the -s
comment in this PR. (Never mind; fixed in master.)
New option --stdin/-t is available for root user. It is useful for automation/setup and it makes shadow utils passwd more versatile. Signed-off-by: Tomas Halman <tomas@halman.net>
It is useful in automation and tests and compatibility. Distributions like Fedora and RHEL (and clones) uses another implementation of passwd that has --stdin option. To make transition easier for Fedora/RHEL users, I would like to have this option implemented in passwd utility. But yes you are right, this can be achieved in many different ways. |
Removed from PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thanks for the patch and your hard work here!
Just to add to my initial remark: The solution with Thank you for clarification! |
New option --stdin/-s is available for root user. It is useful
for automation/setup and it makes shadow utils passwd more versatile.