From bf701dcb819bf06449557b2ef6b2adf207a78586 Mon Sep 17 00:00:00 2001 From: luke Date: Thu, 15 Sep 2005 20:16:21 +0000 Subject: adding extra checks to make sure networking is secure, and refactoring a heckuva lot of test git-svn-id: https://reductivelabs.com/svn/puppet/trunk@671 980ebf18-57e1-0310-9a29-db15c13687c0 --- lib/puppet/parser/ast.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'lib/puppet/parser') diff --git a/lib/puppet/parser/ast.rb b/lib/puppet/parser/ast.rb index 4c2f699c0..1918f60e9 100644 --- a/lib/puppet/parser/ast.rb +++ b/lib/puppet/parser/ast.rb @@ -11,6 +11,8 @@ module Puppet class ASTError < RuntimeError; end #--------------------------------------------------------------- class AST + Puppet.setdefault(:typecheck, true) + Puppet.setdefault(:paramcheck, true) attr_accessor :line, :file, :parent @@pink = "" @@ -482,6 +484,8 @@ module Puppet # for types objtype = @type.value + # This will basically always be on, but I wanted to make it at + # least simple to turn off if it came to that if Puppet[:typecheck] builtin = false begin @@ -492,6 +496,8 @@ module Puppet if builtin # we're a builtin type #Puppet.debug "%s is a builtin type" % objtype + # like :typecheck, this always defaults to on, but + # at least it's easy to turn off if necessary if Puppet[:paramcheck] @params.each { |param| #p self.name -- cgit