Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

(FM-7383) allow device manager to work with Puppet 6 #27

Merged
merged 1 commit into from
Sep 21, 2018

Conversation

Thomas-Franklin
Copy link
Contributor

@Thomas-Franklin Thomas-Franklin commented Sep 21, 2018

Puppet 6.0.0 removed puppet cert and it is now part of puppetserver ca. This PR changes the behaviour to use puppetserver ca sign/list when running on Puppet 6.0.0 and above.

ssl_host suitable algorithms array was also removed, so referencing the array directly to overcome this behaviour as no mention in Puppet 6.0.0 as to where it was moved too.

Puppet 6.0.0 removed `puppet cert` and it is now part of `puppetserver
ca`. This PR changes the behaviour to use `puppetserver ca sign/list`
when running on Puppet 6.0.0 and above.

ssl_host suitable algorithms array was also removed, so referencing the
array directly to overcome this behaviour as no mention in Puppet 6.0.0
as to where it was moved too.
@Thomas-Franklin Thomas-Franklin changed the title (FM-7383) updating the puppetserver ca command to specify certname (FM-7383) allow device manager to work with Puppet 6 Sep 21, 2018
@da-ar da-ar merged commit 604499d into puppetlabs:master Sep 21, 2018
@@ -42,8 +42,7 @@ def read_device_certificate_fingerprints(cert_name)
return nil unless certificate
fingerprints = {}
fingerprints['default'] = certificate.fingerprint
ssl_host = Puppet::SSL::Host.new
mdas = ssl_host.suitable_message_digest_algorithms
mdas = [:SHA1, :SHA224, :SHA256, :SHA384, :SHA512] # ssl_host.suitable_message_digest_algorithms was removed in Puppet 6, specifying the array directly
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@da-ar

If we are interested in a 'canonical' list, suitable_message_digest_algorithms appears to have moved to default_digest_algorithm in Puppet 6.0; and is FIPS-aware, as per PUP-8021:

https://github.com/puppetlabs/puppet/blob/6.0.x/lib/puppet/defaults.rb

mdas  = Puppet.valid_digest_algorithms

Defaults in Puppet 6.0 also offers Puppet.default_digest_algorithm which may be enough to satisfy FM-7115.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is being addressed in #29

@da-ar da-ar added the bugfix Something isn't working label Sep 25, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bugfix Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants