mirror of
https://github.com/discourse/discourse.git
synced 2026-08-14 06:55:03 -05:00
SECURITY: expire all existing sessions if user changes passwords
This commit is contained in:
+4
-1
@@ -320,7 +320,10 @@ class User < ActiveRecord::Base
|
||||
|
||||
def password=(password)
|
||||
# special case for passwordless accounts
|
||||
@raw_password = password unless password.blank?
|
||||
unless password.blank?
|
||||
@raw_password = password
|
||||
self.auth_token = nil
|
||||
end
|
||||
end
|
||||
|
||||
def password
|
||||
|
||||
Reference in New Issue
Block a user