mirror of
https://github.com/fluent/fluentd-ui.git
synced 2026-05-05 19:06:12 +02:00
Only store password if default password is used
This commit is contained in:
parent
ec44ba10d6
commit
982b5b3d4e
@ -38,6 +38,8 @@ class SessionsController < ApplicationController
|
||||
def sign_in(user)
|
||||
# NOTE: Cookie will encrypt by Rails, but store raw password into session is a bad practice.
|
||||
# If we use some DB in the future, change this to store token with expire limitation (not password).
|
||||
session[:succeed_password] = session_params[:password]
|
||||
#
|
||||
# Currently, only store to session if default password is used.
|
||||
session[:succeed_password] = session_params[:password] if session_params[:password] == Settings.default_password
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user