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

--prikey option should be removed #34

Open
Lvceo opened this issue Dec 15, 2022 · 3 comments
Open

--prikey option should be removed #34

Lvceo opened this issue Dec 15, 2022 · 3 comments

Comments

@Lvceo
Copy link

Lvceo commented Dec 15, 2022

--prikey option should be removed as it's a security breach, IMHO.

What about having this shown to every user logged into the system?

$ ps ax | grep nostr
 553521 pts/1    Sl+    0:02 ./nostr_console_elf64 --prikey 680a0693d62e04198472d6def92b801d11fbd417f223000d45f4bbb1e6a3a851

Private key should be imperatively passed over a dotfile in HOME DIR.

@vishalxl
Copy link
Owner

good point. what about the idea of having a password encrypted dotfile? Would this be needed for example on windows ? Linux has file permissions, but do we still want files containing private keys to be encrypted by some other password?

@Lvceo
Copy link
Author

Lvceo commented Dec 17, 2022

IMO @vishalxl , this should be working like the SSH client (which use PKI more or less the same way as nostr).
dotfile should not be encrypted, authorization is already done by user logging into his account, this user is already protected by the OS security implementation. Like referred in #35 having a file in 600 mode is enough to avoid other users accessing the same FS. Having a look to SSH man page, in the FILES section, you will see a quick description of private key storage (for instance ~/.ssh/id_dsa). If you respect this, you are OK. May be a dotdir would be preferable to provide more flexibility for the tool, like multi account feature (different priv/pub keys), and storing preferences for each of them separately.

@jblachly
Copy link

dotfile should not be encrypted

Concur 100%; dotfiles even with authorization credentails (example of .ssh config given, but also e.g. AWS credentials file) are just mode-protected

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

No branches or pull requests

3 participants