MCPcopy Create free account
hub / github.com/ChatLab/ChatLab / setRequireAuth

Function setRequireAuth

packages/http-routes/src/auth.ts:24–26  ·  view source on GitHub ↗
(enabled: boolean)

Source from the content-addressed store, hash-verified

22 * Used for server/headless deployments where same-origin assumption doesn't hold.
23 */
24export function setRequireAuth(enabled: boolean): void {
25 requireAuthEnabled = enabled
26}
27
28// Compare via HMAC digests (fixed 32-byte length) to avoid leaking token length
29const hmacKey = randomBytes(32)

Callers 3

startHttpServerFunction · 0.90
stopHttpServerFunction · 0.90
auth.test.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected