indutny / elliptic

Fast Elliptic Curve Cryptography in plain javascript

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to convert a DER-formatted signature back to a Signature object?

fauxbytes opened this issue · comments

Given:

let sig = ecKey.sign(msg);
let sigDerHex = sig.toDER('hex');

Is there a way to rehydrate sigDerHex back to a Signature Object?

Many thanks!

Project looks dead. The Signature constructor is capable of performing the conversion, but this has not been exposed for some reason.