Sheldon Guo acb61e214f
fix(auth): enhance token concurrent update and auth error handling logic (#6208)
* fix: add optional chaining for safe access to response headers in auth middleware

* fix: add skipNotify option to handle error notifications in SSE stream

* fix: handle expired session error in auth flow and remove unused cache update

* fix: implement renewed JTI cache duration and update related tests

* fix: add skipNotify option to updateUnreadMsgsCount for improved notification handling
2025-02-14 10:55:02 +08:00

15 lines
584 B
TypeScript

/**
* This file is part of the NocoBase (R) project.
* Copyright (c) 2020-2024 NocoBase Co., Ltd.
* Authors: NocoBase Team.
*
* This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
* For more information, please refer to: https://www.nocobase.com/agreement.
*/
export const tokenPolicyRecordKey = 'token-policy-config';
export const tokenPolicyCacheKey = 'auth:' + tokenPolicyRecordKey;
export const tokenPolicyCollectionName = 'tokenControlConfig';
export const issuedTokensCollectionName = 'issuedTokens';
export const RENEWED_JTI_CACHE_MS = 10000;