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

Prompt for SSH key encryption passwords on connection #20

Open
robled opened this issue Aug 19, 2019 · 3 comments
Open

Prompt for SSH key encryption passwords on connection #20

robled opened this issue Aug 19, 2019 · 3 comments
Labels

Comments

@robled
Copy link

robled commented Aug 19, 2019

I'm running Pisth version 11.3.1. If an encrypted SSH private key is added to the client, it seems that the passphrase for decrypting that SSH private key is saved in the host profile. It seems that this passphrase is stored permanently (plaintext?). The private key should remain encrypted on disk at all times, and only decrypted in-memory when the user connects to a host and enters the passphrase.

@ColdGrub1384
Copy link
Owner

ColdGrub1384 commented Aug 20, 2019

The passphrase is stored in the iOS keychain, which is encrypted.

KeychainWrapper.standard.set(data, forKey: pubKey)

KeychainWrapper.standard.set(data, forKey: privKey)

@robled
Copy link
Author

robled commented Aug 21, 2019

Oh, that's pretty cool! Does this mean that I should see an entry for it in Settings -> Passwords & Accounts? Is it decrypted at connection time via Face ID? Apologies for all the basic questions, as I'm pretty new to iOS.

Not sure if I missed something in the UI, but since other SSH clients make it fairly clear to the user that the key is encrypted on-disk, it might be helpful to have a little message somewhere near where you put in your passphrase to inform the user of this.

@ColdGrub1384
Copy link
Owner

Passwords are not stored in Passwords & Accounts. By Keychain, I meant an API by Apple to encrypt things in apps. https://developer.apple.com/documentation/security/keychain_services

I will add a message for making clear the data is encrypted

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

No branches or pull requests

2 participants