diff --git a/src/cloud/common/CloudAuth/BasicCloudAuth.rb b/src/cloud/common/CloudAuth/BasicCloudAuth.rb index c4d53e8c03..63a60369d1 100644 --- a/src/cloud/common/CloudAuth/BasicCloudAuth.rb +++ b/src/cloud/common/CloudAuth/BasicCloudAuth.rb @@ -5,6 +5,10 @@ module BasicCloudAuth if auth.provided? && auth.basic? username, password = auth.credentials + if @conf[:hash_passwords] + password = Digest::SHA1.hexdigest(password) + end + one_pass = get_password(username) if one_pass && one_pass == password @token = "#{username}:#{password}"