Skip to content
Snippets Groups Projects
Commit cfd0d66c authored by Grzegorz Bizon's avatar Grzegorz Bizon
Browse files

Reassign secret token when regenerating one

parent 21e3712a
No related branches found
No related tags found
No related merge requests found
Loading
@@ -47,8 +47,8 @@ module Gitlab
Loading
@@ -47,8 +47,8 @@ module Gitlab
   
unless File.size?(secret_file) unless File.size?(secret_file)
# Generate a new token of 16 random hexadecimal characters and store it in secret_file. # Generate a new token of 16 random hexadecimal characters and store it in secret_file.
token = SecureRandom.hex(16) @secret_token = SecureRandom.hex(16)
File.write(secret_file, token) File.write(secret_file, @secret_token)
end end
   
link_path = File.join(shell_path, '.gitlab_shell_secret') link_path = File.join(shell_path, '.gitlab_shell_secret')
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment