summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn McCrae <john.mccrae@progress.com>2022-01-06 15:22:56 -0800
committerJohn McCrae <john.mccrae@progress.com>2022-01-31 15:55:54 -0800
commitb21b8c3aa8b31fbece16577a2322e54be291305b (patch)
tree42852992ad3366641e4cf8dfd9e6d1b61a180b23
parent74da8491c0510a4078570dc1dfc7ebe156559eb7 (diff)
downloadchef-b21b8c3aa8b31fbece16577a2322e54be291305b.tar.gz
Updated the chef client to retrieve certs from the Windows registry. Tests included. This is PR3 since I keep trashing them
Signed-off-by: John McCrae <john.mccrae@progress.com>
-rw-r--r--lib/chef/http/authenticator.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/http/authenticator.rb b/lib/chef/http/authenticator.rb
index 2fbf8b2b24..60718ee995 100644
--- a/lib/chef/http/authenticator.rb
+++ b/lib/chef/http/authenticator.rb
@@ -173,7 +173,7 @@ class Chef
@win32registry.create_key(new_path, true)
end
# cspell:disable-next-line
- some_chars = "~!@#$%^&*_-+=`|\\(){}[<]:;'>,.?/0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz".each_char.to_a
+ some_chars = "~!@#%^&*_-+=`|\\(){}[<]:;'>,.?/0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz".each_char.to_a
password = some_chars.sample(1 + rand(some_chars.count)).join[0...14]
values = { name: "PfxPass", type: :string, data: password }
@win32registry.set_value(new_path, values)