From 283d9877cb82722c9cb5d59d6c6975925d5370f7 Mon Sep 17 00:00:00 2001 From: Matt Whiteley Date: Fri, 28 Oct 2016 10:19:27 -0700 Subject: Use SHA2 Signed-off-by: Matt Whiteley --- lib/mixlib/authentication/signedheaderauth.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/mixlib/authentication/signedheaderauth.rb b/lib/mixlib/authentication/signedheaderauth.rb index b6be746..4a19092 100644 --- a/lib/mixlib/authentication/signedheaderauth.rb +++ b/lib/mixlib/authentication/signedheaderauth.rb @@ -264,7 +264,7 @@ module Mixlib raise AuthenticationError, "Could not connect to ssh-agent. Make sure the SSH_AUTH_SOCK environment variable is set properly! (#{e.class.name}: #{e.message})" end begin - ssh2_signature = agent.sign(keypair.public_key, string_to_sign) + ssh2_signature = agent.sign(keypair.public_key, string_to_sign, Net::SSH::Authentication::Agent::SSH_AGENT_RSA_SHA2_256) rescue => e raise AuthenticationError, "Ssh-agent could not sign your request. Make sure your key is loaded with ssh-add! (#{e.class.name}: #{e.message})" end -- cgit v1.2.1