-
Hi - attempting to use Jose to both sign and verify JWT tokens in a Cloudflare Pages application. Server-side is implemented in typescript. I should prefix this with the obligatory "I'm a typescript noob" etc! I had this working fine, along the lines of:
It worked, I got a jwt fine - it checked out in a debugger, my client side was happy etc. Now, wrangling on some non-auth related development, and now this does not work, I instead get:
I found another post, which indicated this was because the arg passed to sign() was not an instance of a CryptoKey. So have tried pulling this together:
With no change whatsoever in the result sadly. I'm not convinced this is particularly a Jose issue - I'm beginning to appreciate cloudflare pages is a bit of a work in progress. Anyone have any advice on resolving this? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
This worked so far on all our machines, and since today the one dev on linux has the same issue! It works fine in cloudflare workers and on the other dev machines. Maybe also different node versions? Works on Mac/Node 16.18, doesn't work on Linux/Node 19.3. Edit: works on the other devs machine after downgrading node to 18 Related Miniflare Discussion: cloudflare/miniflare#457 |
Beta Was this translation helpful? Give feedback.
-
Resolved upstream cloudflare/miniflare#457 |
Beta Was this translation helpful? Give feedback.
Resolved upstream cloudflare/miniflare#457