powered by
Read and write RSA, ECDSA or AES keys as JSON web keys.
read_jwk(file)write_jwk(x, path = NULL)
write_jwk(x, path = NULL)
path to file with key data or literal json string
an RSA or EC key or pubkey file
file path to write output
# generate an ecdsa key library(openssl) key <- ec_keygen("P-521") write_jwk(key) write_jwk(as.list(key)$pubkey) # Same for RSA key <- rsa_keygen() write_jwk(key) write_jwk(as.list(key)$pubkey)
Run the code above in your browser using DataLab