Skip to content

Commit 5e5bcc6

Browse files
authored
Merge pull request #1738 from silentoplayz/codex/docs-support-jwt-expiration
docs: explain when JWT expiration changes take effect
2 parents a1b3b85 + a3b0a58 commit 5e5bcc6

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎docs/reference/env-configuration.mdx‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2436,6 +2436,8 @@ For maximum performance, enable both: `ENABLE_BASE_MODELS_CACHE=True` with `MODE
24362436
- Description: Sets how long a sign-in token stays valid, as a number followed by a unit: `ms`, `s`, `m`, `h`, `d` or `w`, for example `4w` or `12h`. Use `-1` for no expiration. A number without a unit, such as `30`, is not valid, and **Settings > Authentication** (admin section) does not save it.
24372437
- Persistence: This environment variable is a `ConfigVar` variable.
24382438

2439+
To check or change the active lifetime, open **Settings > Authentication** in the admin panel and look for **JWT Expiration**. With persistent configuration enabled, a stored value takes precedence over the environment value. Saving a new lifetime applies to newly issued sign-in tokens. Existing tokens keep their original expiration, so sign out and back in to test the new lifetime.
2440+
24392441
:::warning
24402442

24412443
Setting `JWT_EXPIRES_IN` to `-1` disables JWT expiration, making issued tokens valid forever. **This is extremely dangerous in production** and exposes your system to severe security risks if tokens are leaked or compromised.

0 commit comments

Comments
 (0)