summaryrefslogtreecommitdiffstats
path: root/lib/puppet
diff options
context:
space:
mode:
Diffstat (limited to 'lib/puppet')
-rwxr-xr-xlib/puppet/type/user.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/puppet/type/user.rb b/lib/puppet/type/user.rb
index 9e32c89ae..e6b16a9ac 100755
--- a/lib/puppet/type/user.rb
+++ b/lib/puppet/type/user.rb
@@ -142,6 +142,10 @@ module Puppet
newproperty(:password, :required_features => :manages_passwords) do
desc "The user's password, in whatever encrypted format the local machine requires. Be sure to enclose any value that includes a dollar sign ($) in single quotes (\')."
+ validate do |value|
+ raise ArgumentError, "Passwords cannot include ':'" if value.include?(":")
+ end
+
def change_to_s(currentvalue, newvalue)
if currentvalue == :absent
return "created password"