slipset / deps-deploy

deploy your stuff
Eclipse Public License 1.0
148 stars 31 forks source link

[Fix #2] Provide mechanism for reading gpg encrypted creds file #4

Open slipset opened 5 years ago

SevereOverfl0w commented 5 years ago
❯ gpg2 --encrypt .clojars_creds.edn 
You did not specify a user ID. (you may use "-r")

Current recipients:

Enter the user ID.  End with an empty line: 

The example for encryption doesn't have an obvious answer for this. Assuming I should provide a self-recipient.

gpg2 -r dominic@juxt.pro --encrypt .clojars_creds.edn

This command leaves .clojars_creds.edn in plaintext on my filesystem, so we should warn users to cleanup using shred, or rm otherwise.

It was unclear until I read through the source that .clojars_creds.edn should be in the project dir, not $HOME.

I got the error:

Exception in thread "main" clojure.lang.ArityException: Wrong number of args (2) passed to: deps-deploy/-main

When running it. I guess this is just a rebase thing though!

When prompted for my password (which I have no idea what it is!), I wasn't able to hit enter. I had to use Ctrl-D?

Exception in thread "main" java.lang.ClassCastException: org.bouncycastle.openpgp.PGPPublicKeyEncryptedData cannot be cast to org.bouncycastle.openpgp.PGPPBEEncryptedData

I then got this.

I use a smart card, so I have no idea what my password is. On top of that, on Linux, pinentry is used to prompt for the password. It's used to collect information securely. I have no idea if what we're doing here is or isn't secure. https://www.gnupg.org/related_software/pinentry/index.en.html