summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorRyan Davis <ryand@zenspider.com>2020-01-11 15:45:20 -0800
committerRyan Davis <ryand@zenspider.com>2020-01-11 15:45:20 -0800
commitee9017504a7420ea5d80c9d7a5f1e998e65c9258 (patch)
tree80828e991234e6025fae25d7594e29e4eeceb77f /lib
parent19b8b2e9957ac53f481e14b5192c37d1344a1e1b (diff)
downloadhoe-ee9017504a7420ea5d80c9d7a5f1e998e65c9258.tar.gz
+ Load encrypted private key using ENV['GEM_PRIVATE_KEY_PASSPHRASE'] as passphrase. (larskanis)
[git-p4: depot-paths = "//src/hoe/dev/": change = 12494]
Diffstat (limited to 'lib')
-rw-r--r--lib/hoe/signing.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/hoe/signing.rb b/lib/hoe/signing.rb
index 73a5761..36f2e0a 100644
--- a/lib/hoe/signing.rb
+++ b/lib/hoe/signing.rb
@@ -72,7 +72,8 @@ module Hoe::Signing
end
if signing_key and cert_chain then
- spec.signing_key = OpenSSL::PKey::RSA.new File.read signing_key
+ passphrase = ENV['GEM_PRIVATE_KEY_PASSPHRASE']
+ spec.signing_key = OpenSSL::PKey::RSA.new(File.read(signing_key), passphrase)
spec.cert_chain = cert_chain
end
end