discourse/spec/fabricators
Alan Guo Xiang Tan e97ef7e9af
FEATURE: Allow site admin to mark a user's password as expired (#27314)
This commit adds the ability for site administrators to mark users'
passwords as expired. Note that this commit does not add any client side
interface to mark a user's password as expired.

The following changes are introduced in this commit:

1. Adds a `user_passwords` table and `UserPassword` model. While the
   `user_passwords` table is currently used to only store expired
   passwords, it will be used in the future to store a user's current
   password as well.

2. Adds a `UserPasswordExpirer.expire_user_password` method which can
   be used from the Rails console to mark a user's password as expired.

3. Updates `SessionsController#create` to check that the user's current
   password has not been marked as expired after confirming the
   password. If the password is determined to be expired based on the
   existence of a `UserPassword` record with the `password_expired_at`
   column set, we will not log the user in and will display a password
   expired notice. A forgot password email is automatically send out to
   the user as well.
2024-06-04 15:42:53 +08:00
..
admin_notice_fabricator.rb DEV: Database backed admin notices (#26192) 2024-05-23 09:29:08 +08:00
allowed_pm_users.rb
api_key_fabricator.rb
associated_group_fabricator.rb
badge_fabricator.rb DEV: convert grant badge modal to component API (#23378) 2023-09-11 13:56:31 +08:00
bookmark_fabricator.rb
category_fabricator.rb
category_group_fabricator.rb
color_scheme_color_fabricator.rb
color_scheme_fabricator.rb
dimissed_topic_user.rb
do_not_disturb_fabricator.rb
email_change_request_fabricator.rb
email_log_fabricator.rb
email_token_fabricator.rb
embeddable_host_fabricator.rb
embeddable_host_tag_fabricator.rb FEATURE: Extend embeddable hosts with Individual tags and author assignments (#26868) 2024-05-16 15:47:01 -04:00
external_upload_stub_fabricator.rb
flag_fabricator.rb DEV: move post flags into database (#27125) 2024-05-23 12:19:07 +10:00
flag_post_action_fabricator.rb DEV: move post flags into database (#27125) 2024-05-23 12:19:07 +10:00
form_template_fabricator.rb FEATURE: support to initial values for form templates through /new-topic (#23313) 2023-08-29 18:41:33 -03:00
group_fabricator.rb
group_history_fabricator.rb
group_request_fabricator.rb
group_user_fabricator.rb
ignored_user_fabricator.rb
incoming_email_fabricator.rb
incoming_link_fabricator.rb
invite_fabricator.rb
invited_user_fabricator.rb
like_fabricator.rb
muted_user.rb
notification_fabricator.rb
optimized_image_fabricator.rb
permalink_fabricator.rb
post_action_fabricator.rb
post_custom_field_fabricator.rb
post_detail_fabricator.rb
post_fabricator.rb DEV: Fix random typos (#25957) 2024-02-29 12:24:37 +01:00
post_reply_key_fabricator.rb
post_revision_fabricator.rb
problem_check_tracker_fabricator.rb DEV: Add DB backed problem checks to support perform_every config (#25834) 2024-02-27 11:17:39 +08:00
published_page_fabricator.rb
push_subscription_fabricator.rb
reviewable_claimed_topic_fabricator.rb
reviewable_fabricator.rb DEV: Housekeeping for CleanUpUploads job (#24361) 2023-11-20 09:50:09 +10:00
reviewable_score_fabricator.rb
screened_email_fabricator.rb DEV: find_each in CSV exports (#22573) 2023-08-17 12:33:52 +10:00
screened_ip_address_fabricator.rb DEV: find_each in CSV exports (#22573) 2023-08-17 12:33:52 +10:00
screened_url_fabricator.rb
search_log_fabricator.rb
shared_draft_fabricator.rb
sidebar_section_fabricator.rb
sidebar_section_link_fabricator.rb
sidebar_url_fabricator.rb
single_sign_on_record_fabricator.rb
skipped_email_log_fabricator.rb
tag_fabricator.rb
tag_group_fabricator.rb
tag_group_permission_fabricator.rb
theme_fabricator.rb
theme_field_fabricator.rb FEATURE: Theme settings migrations (#24071) 2023-11-02 08:10:15 +03:00
theme_settings_migration_fabricator.rb FEATURE: Theme settings migrations (#24071) 2023-11-02 08:10:15 +03:00
topic_allowed_group_fabricator.rb
topic_allowed_user_fabricator.rb
topic_embed_fabricator.rb FEATURE: Prefer topic_embed's cached content when summarizing (#25190) 2024-01-09 14:00:01 -03:00
topic_fabricator.rb FEATURE: Allow "move to inbox" and "move to archive" for private messages using new bulk topic dropdown (#27236) 2024-06-03 14:37:28 +10:00
topic_tag_fabricator.rb
topic_timer_fabricator.rb
topic_user_fabricator.rb
translation_override_fabricator.rb
upload_fabricator.rb
user_action_fabricator.rb
user_api_key_fabricator.rb
user_associated_account_fabricator.rb FEATURE: Merge user associated accounts, favouring the target user upon conflict (#26645) 2024-04-16 17:37:33 +08:00
user_avatar_fabricator.rb
user_badge_fabricator.rb
user_custom_field_fabricator.rb FIX: Move user reindexing into a job (#26753) 2024-04-25 20:58:34 +08:00
user_email_fabricator.rb
user_fabricator.rb DEV: Make all admins TL4 in tests (#25435) 2024-03-26 11:41:12 +08:00
user_field_fabricator.rb FEATURE: Implement new required options in admin user fields UI (#27079) 2024-05-23 19:18:25 +08:00
user_field_option_fabricator.rb.rb
user_history_fabricator.rb
user_option_fabricator.rb
user_password_fabricator.rb FEATURE: Allow site admin to mark a user's password as expired (#27314) 2024-06-04 15:42:53 +08:00
user_profile_fabricator.rb DEV: Fix various rubocop lints (#24749) 2023-12-06 23:25:00 +01:00
user_second_factor_fabricator.rb
user_security_key_fabricator.rb DEV: Refactor webauthn to support passkeys (1/3) (#23586) 2023-10-03 14:59:28 -04:00
user_status_fabricator.rb
watched_word_fabricator.rb
watched_word_group_fabricator.rb FEATURE: Allow watched words to be created as a group (#26632) 2024-04-29 15:50:55 +05:30
web_crawler_request_fabricator.rb
web_hook_fabricator.rb FEATURE: granular webhooks (#23070) 2023-10-09 03:35:31 +00:00