Commit cfd0d66c authored by Grzegorz Bizon's avatar Grzegorz Bizon

Reassign secret token when regenerating one

parent 21e3712a
...@@ -47,8 +47,8 @@ module Gitlab ...@@ -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')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment