From 2e5bf7be4c72eca35599c19a5b7873c4b4beeb00 Mon Sep 17 00:00:00 2001 From: timothy-spencer Date: Thu, 13 Apr 2017 16:53:26 -0700 Subject: [PATCH 1/2] Make additional option work with createstore __Why__ * Need it to add SAN data to cert __How__ * Wiggle fingers properly --- metadata.rb | 2 +- providers/manage.rb | 3 --- recipes/test.rb | 1 + 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/metadata.rb b/metadata.rb index f5cb625..01d98cc 100644 --- a/metadata.rb +++ b/metadata.rb @@ -4,7 +4,7 @@ license 'Apache 2.0' description 'Installs/Configures keytool' long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) -version '0.8.0 +version '0.8.1 %w( redhat diff --git a/providers/manage.rb b/providers/manage.rb index e627968..3022e48 100644 --- a/providers/manage.rb +++ b/providers/manage.rb @@ -97,13 +97,10 @@ def is_current_pass?(pass) end action :createstore do - @keytool = new_resource.keytool keytool_command= <<-eos -genkey -noprompt \ -alias #{new_resource.keystore_alias} \ -dname "CN=#{new_resource.common_name}, OU=#{new_resource.org_unit}, O=#{new_resource.org}, L=#{new_resource.location}, C=#{new_resource.country}" \ - -keystore #{new_resource.keystore} \ - -storepass #{new_resource.storepass} \ -keypass #{new_resource.storepass} eos @keytool += keytool_command diff --git a/recipes/test.rb b/recipes/test.rb index 86ffe67..cd1f3e3 100644 --- a/recipes/test.rb +++ b/recipes/test.rb @@ -124,4 +124,5 @@ location 'test_location' country 'country' storepass '1qaz2wsx' + additional '-ext san=dns:localhost,ip:127.0.0.1' end From 54a26c087d419af4517b941db37c7421feed8f7b Mon Sep 17 00:00:00 2001 From: timothy-spencer Date: Thu, 13 Apr 2017 16:58:45 -0700 Subject: [PATCH 2/2] fix unterminated quote too --- metadata.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/metadata.rb b/metadata.rb index 01d98cc..5ae2f5e 100644 --- a/metadata.rb +++ b/metadata.rb @@ -4,7 +4,7 @@ license 'Apache 2.0' description 'Installs/Configures keytool' long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) -version '0.8.1 +version '0.8.1' %w( redhat