File tree Expand file tree Collapse file tree 3 files changed +14
-0
lines changed Expand file tree Collapse file tree 3 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -105,6 +105,7 @@ Shaheed Haque
105105Shaun Stanworth
106106Silvano Cerza
107107Sora Yanai
108+ Sören Wegener
108109Spencer Carroll
109110Stéphane Raimbault
110111Tom Evans
Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1616
1717## [ unreleased]
1818### Added
19+ * #1404 Add a new setting ` REFRESH_TOKEN_REUSE_PROTECTION `
1920### Changed
2021### Deprecated
2122### Removed
Original file line number Diff line number Diff line change @@ -185,6 +185,18 @@ The import string of the class (model) representing your refresh tokens. Overwri
185185this value if you wrote your own implementation (subclass of
186186``oauth2_provider.models.RefreshToken ``).
187187
188+ REFRESH_TOKEN_REUSE_PROTECTION
189+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
190+ When this is set to ``True `` (default ``False ``), and ``ROTATE_REFRESH_TOKEN `` is used, the server will check
191+ if a previously, already revoked refresh token is used a second time. If it detects a reuse, it will automatically
192+ revoke all related refresh tokens.
193+ A reused refresh token indicates a breach. Since the server can't determine which request came from the legitimate
194+ user and which from an attacker, it will end the session for both. The user is required to perform a new login.
195+
196+ Can be used in combination with ``REFRESH_TOKEN_GRACE_PERIOD_SECONDS ``
197+
198+ More details at https://datatracker.ietf.org/doc/html/draft-ietf-oauth-security-topics-29#name-recommendations
199+
188200ROTATE_REFRESH_TOKEN
189201~~~~~~~~~~~~~~~~~~~~
190202When is set to ``True `` (default) a new refresh token is issued to the client when the client refreshes an access token.
You can’t perform that action at this time.
0 commit comments