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

SSH/GPG keys with passwords #37

Closed
christopher-dG opened this issue Nov 13, 2019 · 3 comments · Fixed by #43 or #52
Closed

SSH/GPG keys with passwords #37

christopher-dG opened this issue Nov 13, 2019 · 3 comments · Fixed by #43 or #52
Labels
enhancement New feature or request

Comments

@christopher-dG
Copy link
Member

Currently there's nothing to input a password to GPG, and this is blocking me from using my own GPG key. I've tried a few things but I need to do more digging.

@christopher-dG christopher-dG added the enhancement New feature or request label Nov 13, 2019
@DilumAluthge
Copy link
Member

For what it’s worth, I don’t think you should upload your own personal GPG key anywhere.

I think the best practice here will be:

  1. Create a GitHub bot user MyBot
  2. Create a new GPG key, and upload the public key to the GitHub profile of MyBot
  3. Upload the private key to TagBot

So your tags will be signed by MyBot.

@christopher-dG
Copy link
Member Author

If I used GPG for anything but Git, then I'd probably agree, but as it stands the consequence of losing my GPG key is basically the same as losing another one made for a bot

@christopher-dG
Copy link
Member Author

christopher-dG commented Feb 6, 2020

Low priority, but this could be a thing again, SSH keys too.

Some ideas:

For SSH, we need to start ssh-agent and make sure to add the output variables into the environment. Then we can follow the instructions here to ssh-add the key and avoid any future password prompts. We need to use the expect method because there's no -p option in our version of ssh-add.

GPG:

There's a Python library that handles sending input to gpg, it just needed a small patch (here). With that package, we can enable gpg-agent and import the key with the password, which should remove the need for any other password prompt.

@christopher-dG christopher-dG changed the title GPG keys with passwords SSH/GPG keys with passwords Feb 6, 2020
christopher-dG added a commit that referenced this issue Feb 6, 2020
I don't think this actually works properly yet, it's just a POC.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
2 participants