From c2617211cf5037c5ddb7f59992c35c6dd62a529e Mon Sep 17 00:00:00 2001 From: Markus Roberts Date: Fri, 11 Dec 2009 15:25:00 -0800 Subject: Fix for #2911 (Allow capital letters in selinux contexts) This is Matthias Saou's patch from the ticket; it adjusts the regular expression to permit capital letters where needed. --- lib/puppet/util/selinux.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/puppet/util/selinux.rb b/lib/puppet/util/selinux.rb index 3eff03996..f1336f946 100644 --- a/lib/puppet/util/selinux.rb +++ b/lib/puppet/util/selinux.rb @@ -73,7 +73,7 @@ module Puppet::Util::SELinux if context.nil? or context == "unlabeled" return nil end - unless context =~ /^([a-z0-9_]+):([a-z0-9_]+):([a-z0-9_]+)(?::([a-zA-Z0-9:,._-]+))?/ + unless context =~ /^([a-z0-9_]+):([a-z0-9_]+):([a-zA-Z0-9_]+)(?::([a-zA-Z0-9:,._-]+))?/ raise Puppet::Error, "Invalid context to parse: #{context}" end ret = { -- cgit