oidc-client-ts/src/JsonService.ts at mai...
https://github.com/authts/oidc-client-ts/blob/main/src/JsonService.ts#L50 the actual failure is here
GitHub
oidc-client-ts/src/JsonService.ts at main · authts/oidc-client-ts
OpenID Connect (OIDC) and OAuth2 protocol support for browser-based JavaScript applications - authts/oidc-client-ts
1 Reply
the issue is setting Credentials, not a header
hmm
well.. i'm not particularly married to this library, if there is an OAuth/OpenID Connect client that actually supports workers, i would much rather use that
i just wasn't able to find one
is that the only thing that cloudflare doesn't support from browser apis?
sigh
i do not enjoy forking libraries
I'll see if I can convince them to add support somehow
if i can't, i may fork
Oh absolutely not
it worked
hmmm
is this a sarcastic suggestion
because npm is currently dead on my machine
hmmm
would i need to throw this in the start of every http client instantiation
well, anywhere in pages functions?
or just "in every handler"
i wonder if it'll work in a middleware
i think so
because it's await next
i'll test
well that's throwing errors, but i have a more immediate problem
UNABLE_TO_GET_ISSUER_CERT_LOCALLY
and i have no idea how to troubleshoot it
npm, pnpm, wrangler
anything that tries to acess the internet from node i think
no
why would i use a http registry
like i see a lot of solutions online that are just "ignore security"
hmmm
i wonder if that happened
i'm scared that i screwed something up with my dns
no, macOS
well, my issue is that google has been no help at all
no
Turns out homebrew node is just broken, using nvm node works fine
anyway, i now get the error
using a very slightly tweaked version of this
dang the ts compiler is so smart lol
(no, i don't have any types yet but still)
hmm
despite the stacktrace starting at the middleware, i still get
The 'credentials' field on 'RequestInitializerDict' is not implemented.
something like this:
hmm
that seems to have the exact same problem?
what?
why on earth would this like
happen
even removing the if
THEN THOUGH
that it is