mirror of
https://github.com/glitch-soc/mastodon.git
synced 2025-12-15 16:59:41 +00:00
Remove Legacy OTP Secret code (#34743)
This commit is contained in:
@@ -15,9 +15,6 @@
|
||||
# current_sign_in_at :datetime
|
||||
# disabled :boolean default(FALSE), not null
|
||||
# email :string default(""), not null
|
||||
# encrypted_otp_secret :string
|
||||
# encrypted_otp_secret_iv :string
|
||||
# encrypted_otp_secret_salt :string
|
||||
# encrypted_password :string default(""), not null
|
||||
# last_emailed_at :datetime
|
||||
# last_sign_in_at :datetime
|
||||
@@ -46,14 +43,17 @@
|
||||
|
||||
class User < ApplicationRecord
|
||||
self.ignored_columns += %w(
|
||||
admin
|
||||
current_sign_in_ip
|
||||
encrypted_otp_secret
|
||||
encrypted_otp_secret_iv
|
||||
encrypted_otp_secret_salt
|
||||
filtered_languages
|
||||
last_sign_in_ip
|
||||
moderator
|
||||
remember_created_at
|
||||
remember_token
|
||||
current_sign_in_ip
|
||||
last_sign_in_ip
|
||||
skip_sign_in_token
|
||||
filtered_languages
|
||||
admin
|
||||
moderator
|
||||
)
|
||||
|
||||
include LanguagesHelper
|
||||
@@ -76,8 +76,6 @@ class User < ApplicationRecord
|
||||
otp_secret_encryption_key: Rails.configuration.x.otp_secret,
|
||||
otp_secret_length: 32
|
||||
|
||||
include LegacyOtpSecret # Must be after the above `devise` line in order to override the legacy method
|
||||
|
||||
devise :two_factor_backupable,
|
||||
otp_number_of_backup_codes: 10
|
||||
|
||||
|
||||
Reference in New Issue
Block a user