# File lib/puppet/sslcertificates/ca.rb, line 54 54: def initialize(hash = {}) 55: Puppet.settings.use(:main, :ca, :ssl) 56: self.setconfig(hash) 57: 58: if Puppet[:capass] 59: if FileTest.exists?(Puppet[:capass]) 60: #puts "Reading #{Puppet[:capass]}" 61: #system "ls -al #{Puppet[:capass]}" 62: #File.read Puppet[:capass] 63: @config[:password] = self.getpass 64: else 65: # Don't create a password if the cert already exists 66: @config[:password] = self.genpass unless FileTest.exists?(@config[:cacert]) 67: end 68: end 69: 70: self.getcert 71: init_crl 72: unless FileTest.exists?(@config[:serial]) 73: Puppet.settings.write(:serial) do |f| 74: f << "%04X" % 1 75: end 76: end 77: end