Skip to content

Commit 16e457c

Browse files
authored
Allow matchingRule and attrstyle in olcAccess
We had a requirement to use a diffent matchingRule for the Access Rule. This inported well but on the next run it did fail because it could not parse it. This fixes this
1 parent 5cdd691 commit 16e457c

File tree

1 file changed

+1
-1
lines changed
  • lib/puppet/provider/openldap_access

1 file changed

+1
-1
lines changed

lib/puppet/provider/openldap_access/olc.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def self.instances
3030
suffix = line.split[1]
3131
when %r{^olcAccess: }
3232
begin
33-
position, what, bys = line.match(%r{^olcAccess:\s+\{(\d+)\}to\s+(\S+(?:\s+filter=\S+)?(?:\s+attrs=\S+)?(?:\s+val=\S+)?)(\s+by\s+.*)+$}).captures
33+
position, what, bys = line.match(%r{^olcAccess:\s+\{(\d+)\}to\s+(\S+(?:\s+filter=\S+)?(?:\s+attrs=\S+)?(?:\s+val(?:/\S+)?(?:\.\S+)?=\S+)?)(\s+by\s+.*)+$}).captures
3434
rescue StandardError
3535
raise Puppet::Error, "Failed to parse olcAccess for suffix '#{suffix}': #{line}"
3636
end

0 commit comments

Comments
 (0)