Skip to content
File

Blob: src/workerd/api/crypto/jwk.h

cpp18 lines
1#pragma once
2 
3#include "keys.h"
4 
5namespace workerd::api {
6 
7// TODO(soon): All of the JWK conversion logic will be moved in here
8// soon. Currently this only covers conversion with ncrypto keys not
9// kj::Own held keys.
10 
11SubtleCrypto::JsonWebKey toJwk(
12 const ncrypto::EVPKeyPointer& key, KeyType keyType = KeyType::PUBLIC);
13 
14ncrypto::EVPKeyPointer fromJwk(
15 const SubtleCrypto::JsonWebKey& jwk, KeyType keyType = KeyType::PUBLIC);
16 
17} // namespace workerd::api