跳到主要内容
ecdsa.com

DER ⇄ 原始格式签名转换器

粘贴任一格式的 ECDSA 签名——ASN.1 DER 或原始 r‖s(IEEE P1363)——即可同时得到两种格式,并提取 r 和 s、检测 high-S,以及重新生成规范编码。

100% 本地运行——所有操作都在你的浏览器中完成,不会向任何服务器发送数据

How it works

An ECDSA signature is just two big integers, r and s — but two ecosystems package them differently. TLS, X.509 certificates and OpenSSL wrap them in ASN.1 DER, a self-describing structure (SEQUENCE of two INTEGERs) whose length varies from signature to signature. JWS/JWT, WebCrypto and most blockchains instead use the raw IEEE P1363 form: r and s zero-padded to the curve size and simply concatenated, so a P-256 signature is always exactly 64 bytes. Feeding one format to a verifier that expects the other is one of the most common reasons a perfectly good signature "fails" to verify.

Two more subtleties trip people up. For every valid signature (r, s) the mirrored pair (r, n − s) is also valid, so strict systems — Bitcoin most famously — canonicalize by requiring the low-S half (s ≤ n/2); this tool flags high-S values and can normalize them. And DER itself has exactly one legal encoding per value: extra leading zeros, missing sign-padding or long-form lengths make a signature that lenient parsers accept but strict ones reject, so the converter warns about them and always emits the canonical bytes. Everything runs locally in your browser — nothing you paste is ever sent anywhere.