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-18 13:32:43 -0800
commit867bee3e693182235a7e2cbff80721a565b2c02e (patch)
treeeeda52f961346cc1a683c95fb42d107dd71f1636
parent8f749fdcb1b0fc14b974d2d979d16d83544032d2 (diff)
downloadchef-867bee3e693182235a7e2cbff80721a565b2c02e.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)