Issue #14852 has been updated by Jeff McCune.

Target version changed from 2.7.20 to 2.7.18

----------------------------------------
Bug #14852: Puppet should correctly parse CN when DN contains an emailAddress 
following the CN
https://projects.puppetlabs.com/issues/14852#change-94370

* Author: Jeff McCune
* Status: Merged - Pending Release
* Priority: Normal
* Assignee: Jeff McCune
* Category: SSL
* Target version: 2.7.18
* Affected Puppet version: 
* Keywords: ssl certificate dn subject cn emailAddress cert
* Branch: https://github.com/puppetlabs/puppet/pull/837
----------------------------------------
# Impact Data #

At least one user on the puppet-users list has run into this.

* [Puppet Users - SSL emailAddress interpreted as part of the CN when using 
puppet with an external PKI](http://goo.gl/9DHmg)

# Overview #

If the certificate used on the agent has a DN containing an emailAddress 
component following the CN component, Puppet will incorrectly parse out the CN.

# Expected Behavior #

Given the certificate with DN `subject= /C=UK/ST=Greater 
London/O=example/CN=mir.example.net/[email protected]` Puppet 
should parse out the CN as `mir.example.net`.

# Actual Behavior #

Pupet parses out the CN as `mir.example.net/[email protected]`.

# Additional Data #

This appears to be related to a bad regular expression in 
[lib/puppet/network/http/rack/rest.rb](https://github.com/puppetlabs/puppet/blob/fb4c64b6a54b37ef1357f853fb6d00e17202b410/lib/puppet/network/http/rack/rest.rb#L89)
 on line 89.

`dn_matchdata = dn.match(/^.*?CN\s*=\s*(.*)/)`


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to