Implementing command to change password #237
|
I'm developing a CLI which will replace bash as the user's shell on Linux. For this I need to read the password from the user and confirmation of the password, without displaying it on the terminal. I need to either directly execute the passwd command and let it take these inputs, or I need to read these from my CLI and pass it on to the passwd command. I tried using std::getline, std::cin.getline and also executing passwd command using system() and popen() but in all instances it is not able to read all the characters entered by the user. Is there a way to achieve this using this CLI framework? Any suggestions or workarounds? |
Answered by
daniele77
Apr 26, 2024
Replies: 1 comment 4 replies
|
I guess discussion #204 should answer your question. |
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I've just committed a fix that should enable user keyboard handling on Linux platform as well (commit 17dafd8).
It's the issue #239.
Please, see if this solves your problem.