Getting error `Unrecognized algorithm name` on `crypto.subtle.importKey()`
I can't figure this one out. I've done some searching and found a list of supported algos at https://deno.land/std@0.167.0/crypto/mod.ts
See anything I'm doing wrong? I tried it without the hash as well. Here's a snippet:
1 Reply
I've now tried passing in an eliptical curve params object, instead of 'SHA-512'. This ends up throwing an
undefined
error.
I also changed spki
to pkcs8
, as I realized this is for a private key.
Found out I need to base64 decode the key, before I convert it to an array buffer. But even then, undefined
is thrown. Thoughts?