-
Notifications
You must be signed in to change notification settings - Fork 63
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
Request to add prompt for password #55
Comments
This is a good idea! But unfortunately it doesn't look like it's supported by the https://github.com/spf13/cobra, the cli library that's we're using: spf13/cobra#248 |
Thanks for the tip @jhuggart, I'll look into that! |
I wrote up two implementations of this using https://github.com/manifoldco/promptui and Go's builtin golang.org/x/crypto/ssh/terminal manifoldco/promptui implementation Binary sizes:
Promptui looks a bit flashier and will obviously open up other possibilities for interactive prompts that we might want in the future, but /x/crypto/ssh/terminal is a lot slimmer. Promptui allows you to set limits on the password, which might not be interesting for this purpose, but it displays "*" instead of what you type, where as /x/crypto/ssh/terminal just shows nothing at all which can be confusing for some. @jhuggart If you are still using Vulcanizer, could you check out one of my branches and try it out? I don't have a cluster with auth enabled handy right now so I can't validate if this actually works. |
Sorry about this @leosunmo! Really appreciate your work and I'm going to dedicate some time next week to look at it. |
No worries Nick, not in a huge rush, I don't even use the feature. Just very keen to close the last two issues ;) |
I've used https://github.com/AlecAivazis/survey for various interactive prompts including masked password in a CLI that is built with Cobra. |
Currently we can password passwords only by
vulcanizer.yaml
configuration file or in cmdline.Can/Should we allow password as prompt if not provided after
--password
flag? (or new flag all together)The text was updated successfully, but these errors were encountered: