Sign-in hardening: count parallel wrong passwords of a session, and small follow-ups of the signed-in count
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 45/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- csharp
調査の方向性
Start in src/FluentCMS.Core/Identity/ and trace CmsUserManager.ChangePasswordAsync, TwoFactorService.RequireCodeAsync, ClearingPasswordChangeAsync, SetPasswordAsync, and CmsUserStore.cs; the issue also names docs/host-configuration.md. Read the linked follow-ups and their review context, then find the existing tests for these flows. Done means the five listed behaviors are covered by code, tests, or the specified spec update, and the documentation sentence is corrected.
索引モデルが issue の本文から書いたものです。
説明
Follow-ups of #3371, #3378 and #3381 (#3444), found in its review. Paths are under src/FluentCMS.Core/Identity/.
- Parallel wrong passwords on change-password are not all counted.
CmsUserManager.ChangePasswordAsyncignores the result ofSignedInAccessFailedAsync, as it ignoredAccessFailedAsyncbefore. A holder of a stolen cookie who posts N guesses at once has them all read one concurrency stamp: each answers "wrong password", one save wins, and the count rises by one. A right guess that loses its save answersConcurrencyFailure, which tells the sender it was right. The per-addressAuthlimit (20 a minute) is then the only bound, against the intended 5 in 5 minutes. Codes are not affected, since a right code must win its own save. - A right two-factor code resets the count of wrong passwords too.
ResetSignedInFailuresAsyncis called fromTwoFactorService.RequireCodeAsync, so a session that holds the second factor gives 4 wrong passwords, one right code at/me/two-factor/recovery-codes, and starts again. - The forced-change flag is put back over a reloaded user.
ClearingPasswordChangeAsyncandSetPasswordAsyncrestoremustChangePasswordafter a failed save without checking that the user was not reloaded, the pattern #3381 fixed for the failure count. No path of core saves the user again in that scope today. IsTokenKeyViolationmatches the table name anywhere in the provider's message (CmsUserStore.cs). SQL Server repeats the duplicate key value, so another unique violation whose value containscms_user_tokenwould be answered as a refusal. It can never become a success.docs/host-configuration.mdstill says the token endpoint refuses a code or refresh token of a locked-out user, which #3271 ended.
Wanted
- Every wrong current password of a session counted when requests run at once, and no different answer for a right one that lost its save, with a test.
- Wrong passwords and wrong codes of a session counted apart, or the reason they share a count recorded in the spec.
- The flag restored only when the user was not reloaded.
- The token key matched by the constraint's name on the three providers.
- The sentence corrected.
Bundle 28.
- 主要言語
- C#
- スター
- 567
- フォーク
- 107
- 平均マージ
- 1時間 19分
- マージ済み PR(30日)
- 353
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
fluentcms/FluentCMS のほかの issue
-
area:localization plugin type:bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
area:storage type:bug
難易度 4/5 3〜5日 初心者へのやさしさ 48/100
メンテナーはふだん 1 日以内に返信
-
area:testing type:bug
難易度 3/5 1〜2日 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
area:api area:publishing type:feature
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
fluentcms/FluentCMS#3473 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
area:storage plugin type:bug
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
メンテナーはふだん 1 日以内に返信
fluentcms/FluentCMS の issue をすべて見る
似ている issue
-
fix(ocr): compile the Tesseract-free pipeline with Tokio runtime対応中かも @Goldziher が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
priority:P2
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
-
lompotc silently drops Java/C# class members past 128 instead of erroring, as its header claimsオープンbug sev-5 vm
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
-
area:jobads-cv bug FE mvp P3
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
klasolsson81/jobbliggaren#2271 ·
メンテナーはふだん 1 日以内に返信