chef-api icon indicating copy to clipboard operation
chef-api copied to clipboard

Adding fix for SSL verification in v0.5.0

Open ErinMorelli opened this issue 6 years ago • 3 comments

Hello! I'm using version 0.5.0 of chef-api with Ruby 1.9.3 and an AWS OpsWorks server. I ran into an issue with connecting to the server with SSL verification enabled and using Amazon's provided PEM file. Turns out the issue is because the PEM they provide only has a Certificate, not both a Certificate and Key, so the connection is failing around this line when a key cannot be parsed.

This PR is to replace the cert and key parsing lines with a single line leveraging the ca_file field for the PEM instead which seems to be a more reliable way of connecting with a non-standard PEM. I've only made the change to v0.5.0.

ErinMorelli avatar Nov 21 '17 18:11 ErinMorelli