Skip to content
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

feat: a possible better way to enter password #59

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

stceum
Copy link
Contributor

@stceum stceum commented Oct 7, 2024

  • 一种可能更好的输入密码的方式。

    之前:(需要密码,该密码可能存在于 bash/zsh/... 历史记录中):

    $ ipgw config account add -u xxxxxxx -p xxx...xxx # 可能不安全

    现在:

    $ ipgw config account add -u xxxxxxx
    Enter Password: # 输入时不回显

  • A possible better way to enter password.

    previous (password is required which may exist in the bash/zsh/... history):

    $ ipgw config account add -u xxxxxxx -p xxx...xxx # Potentially unsafe

    current:

    $ ipgw config account add -u xxxxxxx
    Enter Password: # type in without echo

@@ -147,10 +162,21 @@ var (
}

password := ctx.String("password")
if password == "" {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

如果使用者用 set 只是想把账号设置成 default 而不涉及密码的话,这样处理是有问题的

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我疏忽了这里🫢,有空我再改一下这里的逻辑

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants