Skip to content
Discussion options

You must be logged in to vote

Cloudflare has excellent Web Crypto support, as do the most recents versions of Deno, so you should be able to do this just fine in a worker and in Denoflare. Use importKey to load the pem etc, I've done it in another project of mine called Minipub, feel free to steal the code.

A few things to note:

  • The Cloudflare environment variable limit size is now 5kb, so you might not need to split up the value into pieces
  • For a private key, you should use a secret worker variable binding, not plain text. ("secret" instead of "value" in denoflare config)
  • You should definitely not send the pem contents in the Authorization header! They should never leave the worker. It looks like GH uses the pem to g…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@bebraw
Comment options

@bebraw
Comment options

@johnspurlock-skymethod
Comment options

Answer selected by bebraw
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants