MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / isUnauthenticatedCallback

Function isUnauthenticatedCallback

apps/local/src/identity.ts:59–66  ·  view source on GitHub ↗
(request: Request)

Source from the content-addressed store, hash-verified

57// the shell's `isUnauthenticatedOAuthCallbackPath` exemption (cloud/self-host
58// instead authenticate the callback via the same-origin session cookie).
59const isUnauthenticatedCallback = (request: Request): boolean => {
60 // oxlint-disable-next-line executor/no-try-catch-or-throw -- boundary: parsing a request URL that should always be valid here
61 try {
62 return /\/oauth\/callback(\/|$)/.test(new URL(request.url).pathname);
63 } catch {
64 return false;
65 }
66};
67
68/**
69 * Build the local `IdentityProvider`: validate the request's bearer token

Callers 1

makeLocalIdentityLayerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected