Jira (PUP-10922) The fqdn_rand() function should not assume case-consistency in the fqdn fact

56 views
Skip to first unread message

Robert August Vincent II (Jira)

unread,
Feb 15, 2021, 10:13:03 AM2/15/21
to puppe...@googlegroups.com
Robert August Vincent II created an issue
 
Puppet / Task PUP-10922
The fqdn_rand() function should not assume case-consistency in the fqdn fact
Issue Type: Task Task
Affects Versions: PUP 7.3.0, PUP 6.17.0
Assignee: Henrik Lindberg
Components: Functions
Created: 2021/02/15 7:12 AM
Priority: Normal Normal
Reporter: Robert August Vincent II

The DNS standard does not require hostnames to be case-consistent across different servers which are authoritative for the same domain.

Therefore, the fqdn_rand function should not assume that the FQDN of a given server, (which may rely on DNS lookup via getaddrinfo) will always be returned with identical case.

See https://support.puppet.com/hc/en-us/requests/43144

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v8.5.2#805002-sha1:a66f935)
Atlassian logo

Robert August Vincent II (Jira)

unread,
Feb 15, 2021, 11:41:02 AM2/15/21
to puppe...@googlegroups.com

Mihai Buzgau (Jira)

unread,
Feb 16, 2021, 2:36:04 AM2/16/21
to puppe...@googlegroups.com
Mihai Buzgau updated an issue
Change By: Mihai Buzgau
Comment: Hi [~pillarsdotnet] 

Thank you for raising this ticket. Since this contains information about a support ticket, I'm moving this ticket to "Confidential" (it is only visible by you and Puppet employees).

 

zendesk.jira (Jira)

unread,
Feb 16, 2021, 6:16:03 AM2/16/21
to puppe...@googlegroups.com

zendesk.jira (Jira)

unread,
Feb 16, 2021, 6:16:03 AM2/16/21
to puppe...@googlegroups.com
zendesk.jira updated an issue
Change By: zendesk.jira
Zendesk Ticket Count: 1
Zendesk Ticket IDs: 43144

Jarret Lavallee (Jira)

unread,
Feb 16, 2021, 9:37:03 AM2/16/21
to puppe...@googlegroups.com
Jarret Lavallee commented on Improvement PUP-10922
 
Re: The fqdn_rand() function should not assume case-consistency in the fqdn fact

Changing the case may cause changes across customers that have standardized uppercase hostnames. To avoid a large changeset, a `certname_rand` could be implemented as the certname should always be lowercase and should not change without a certificate regeneration.

Robert August Vincent II (Jira)

unread,
Feb 16, 2021, 9:46:03 AM2/16/21
to puppe...@googlegroups.com

If a certname_rand() function is added, then the multiple Puppet Enterprise modules which call fqdn_rand() should be rewritten to call certname_rand() instead.

Mihai Buzgau (Jira)

unread,
Feb 17, 2021, 6:54:02 AM2/17/21
to puppe...@googlegroups.com

Mihai Buzgau (Jira)

unread,
Feb 17, 2021, 6:54:03 AM2/17/21
to puppe...@googlegroups.com

Gheorghe Popescu (Jira)

unread,
Feb 17, 2021, 6:56:02 AM2/17/21
to puppe...@googlegroups.com

zendesk.jira (Jira)

unread,
Feb 17, 2021, 7:44:02 PM2/17/21
to puppe...@googlegroups.com
zendesk.jira updated an issue
Change By: zendesk.jira
Zendesk Ticket Count: 1 2
Zendesk Ticket IDs: 42419, 43144

Robert August Vincent II (Jira)

unread,
Feb 22, 2021, 8:46:03 AM2/22/21
to puppe...@googlegroups.com
 
Re: The fqdn_rand() function should not assume case-consistency in the fqdn fact

For example, running Puppet on our development Puppet server (with no code or configuration changes) gives the following output, because the DNS lookup of the hostname differs in case from the previous run:

Notice: /Stage[main]/Pe_repo::Bulk_pluginsync/Cron[create tar.gz of pluginsync cache]/minute: minute changed ['36'] to ['2']
Notice: /Stage[main]/Pe_repo::Bulk_pluginsync/Cron[create zip of pluginsync cache]/minute: minute changed ['36'] to ['2']                                                   Notice: /Stage[main]/Puppet_enterprise::Master::Recover_configuration/Cron[puppet infra recover_configuration]/minute: minute changed ['7', '37'] to ['25', '55']           Notice: /Stage[main]/Pwcpatch::Cron/Cron[Set RedHat and CentOS patching schedule]/minute: minute changed ['35'] to ['3']                                                    Notice: /Stage[main]/Pwcpatchcompliance::Linux/Cron[Patch Compliance Check - Static]/minute: minute changed ['39'] to ['16']                                                Notice: /Stage[main]/Puppet_metrics_collector::Service::Puppetserver/Puppet_metrics_collector::Pe_metric[puppetserver]/Cron[puppetserver_metrics_tidy]/minute: minute changed ['20'] to ['50']                                                                    Notice: /Stage[main]/Puppet_metrics_collector::Service::Puppetserver/Puppet_metrics_collector::Pe_metric[puppetserver]/Cron[puppetserver_metrics_tidy]/hour: hour changed ['1'] to ['0']                                                                          Notice: /Stage[main]/Puppet_metrics_collector::Service::Puppetdb/Puppet_metrics_collector::Pe_metric[puppetdb]/Cron[puppetdb_metrics_tidy]/minute: minute changed ['10'] to ['25']
Notice: /Stage[main]/Puppet_metrics_collector::Service::Orchestrator/Puppet_metrics_collector::Pe_metric[orchestrator]/Cron[orchestrator_metrics_tidy]/minute: minute changed ['15'] to ['20']
Notice: /Stage[main]/Puppet_metrics_collector::Service::Orchestrator/Puppet_metrics_collector::Pe_metric[orchestrator]/Cron[orchestrator_metrics_tidy]/hour: hour changed ['1'] to ['0']
Notice: /Stage[main]/Puppet_metrics_collector::Service::Ace/Puppet_metrics_collector::Pe_metric[ace]/Cron[ace_metrics_tidy]/minute: minute changed ['25'] to ['15']
Notice: /Stage[main]/Puppet_metrics_collector::Service::Ace/Puppet_metrics_collector::Pe_metric[ace]/Cron[ace_metrics_tidy]/hour: hour changed ['1'] to ['2']
Notice: /Stage[main]/Puppet_metrics_collector::Service::Bolt/Puppet_metrics_collector::Pe_metric[bolt]/Cron[bolt_metrics_tidy]/minute: minute changed ['35'] to ['50']
Notice: /Stage[main]/Puppet_metrics_collector::Service::Bolt/Puppet_metrics_collector::Pe_metric[bolt]/Cron[bolt_metrics_tidy]/hour: hour changed ['0'] to ['2']

Robert August Vincent II (Jira)

unread,
Feb 24, 2021, 1:15:02 PM2/24/21
to puppe...@googlegroups.com

Tried to sign the CLA but the tool doesn't appear to be working.

Robert August Vincent II (Jira)

unread,
Feb 24, 2021, 1:31:02 PM2/24/21
to puppe...@googlegroups.com
Robert August Vincent II updated an issue
 
Comment:
Tried to sign the CLA but the tool doesn't appear to be working.

Mihai Buzgau (Jira)

unread,
Mar 3, 2021, 6:36:02 AM3/3/21
to puppe...@googlegroups.com
Mihai Buzgau updated an issue
Change By: Mihai Buzgau
Sprint: NW - 2021-03-03 , NW - 2021-03-17

Ciprian Badescu (Jira)

unread,
Mar 11, 2021, 10:02:01 AM3/11/21
to puppe...@googlegroups.com
Ciprian Badescu commented on Improvement PUP-10922
 
Re: The fqdn_rand() function should not assume case-consistency in the fqdn fact

Robert August Vincent II, is adding a new function (like certname_rand())  helpful in your case?

Changing existing fqdn_rand() function behavior may cause issues, see: https://tickets.puppetlabs.com/browse/PUP-8141 change of fqdn_rand() reverted by https://tickets.puppetlabs.com/browse/PUP-8469

Ciprian Badescu (Jira)

unread,
Mar 15, 2021, 12:23:03 PM3/15/21
to puppe...@googlegroups.com

On second though, even if is not purely a config, we could implement a puppet configuration flag to control whether the fqdn_rand function is case sensitive or not. Thoughts?

Mihai Buzgau (Jira)

unread,
Mar 17, 2021, 8:00:04 AM3/17/21
to puppe...@googlegroups.com
Mihai Buzgau updated an issue
Change By: Mihai Buzgau
Sprint: NW - 2021-03-03, NW - 2021-03-17 , NW - 2021-03-31

Gareth McGrillan (Jira)

unread,
Mar 23, 2021, 2:01:04 PM3/23/21
to puppe...@googlegroups.com
Gareth McGrillan commented on Improvement PUP-10922
 
Re: The fqdn_rand() function should not assume case-consistency in the fqdn fact

Hi Robert August Vincent II

Would any of Ciprian's options be suitable fixes for you?

Many thanks,

Gareth...

Mihai Buzgau (Jira)

unread,
Mar 31, 2021, 5:31:04 AM3/31/21
to puppe...@googlegroups.com
Mihai Buzgau updated an issue
Change By: Mihai Buzgau
Sprint: NW - 2021-03-03, NW - 2021-03-17, NW - 2021-03-31 , NW - 2021-04-14

Mihai Buzgau (Jira)

unread,
Apr 14, 2021, 6:22:01 AM4/14/21
to puppe...@googlegroups.com
Mihai Buzgau updated an issue
Change By: Mihai Buzgau
Sprint: NW - 2021-03-03, NW - 2021-03-17, NW - 2021-03-31, NW - 2021-04-14 , NW-2021-04-28
This message was sent by Atlassian Jira (v8.13.2#813002-sha1:c495a97)
Atlassian logo

Gareth McGrillan (Jira)

unread,
Apr 14, 2021, 7:03:01 AM4/14/21
to puppe...@googlegroups.com

Ciprian mentioned a possible option for addressing this issue  - would this be suitable?

Many thanks,

Gareth...

Ciprian Badescu (Jira)

unread,
Apr 21, 2021, 3:28:04 AM4/21/21
to puppe...@googlegroups.com
Ciprian Badescu updated an issue
 
Change By: Ciprian Badescu
Sprint: ready for triage, NW - 2021-03-03, NW - 2021-03-17, NW - 2021-03-31, NW - 2021-04-14

Ciprian Badescu (Jira)

unread,
Apr 21, 2021, 3:28:05 AM4/21/21
to puppe...@googlegroups.com
Ciprian Badescu updated an issue
Change By: Ciprian Badescu
Sprint: NW - 2021-03-03, NW - 2021-03-17, NW - 2021-03-31, NW - 2021-04-14 , NW-2021-04-28

Josh Cooper (Jira)

unread,
Apr 23, 2021, 1:44:02 PM4/23/21
to puppe...@googlegroups.com

Josh Cooper (Jira)

unread,
Apr 29, 2021, 3:40:03 PM4/29/21
to puppe...@googlegroups.com

Josh Cooper (Jira)

unread,
Apr 29, 2021, 3:40:04 PM4/29/21
to puppe...@googlegroups.com
Josh Cooper updated an issue
 
Change By: Josh Cooper
Fix Version/s: PUP 7.7.0
Fix Version/s: PUP 6.23.0

Josh Cooper (Jira)

unread,
Apr 29, 2021, 3:47:02 PM4/29/21
to puppe...@googlegroups.com
Josh Cooper updated an issue
Change By: Josh Cooper
Release Notes: Enhancement
Release Notes Summary: The `fqdn_rand` function accepts an optional parameter to downcase the FQDN fact, such as : fqdn_rand(100, 'expensive job 1', true) By default, the function remains case-sensitive.

Josh Cooper (Jira)

unread,
Apr 29, 2021, 4:10:04 PM4/29/21
to puppe...@googlegroups.com
Josh Cooper updated an issue
Change By: Josh Cooper
Release Notes Summary: The `fqdn_rand` function accepts an optional parameter to downcase the FQDN fact so that the function's result is not sensitive FQDN case. The parameter must be passed after the SEED string , such as : fqdn_rand(100, 'expensive job 1', true) . By default, the function remains case-sensitive.

Josh Cooper (Jira)

unread,
May 6, 2021, 1:19:02 PM5/6/21
to puppe...@googlegroups.com

Claire Cadman (Jira)

unread,
May 18, 2021, 10:05:02 AM5/18/21
to puppe...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages