0

The output format of ECDSA Signature Algorithm is a tuple (r,s) according to its wiki aticle and other similar sources.

But when I triedy the signature generated through their my own algo through standard crypto programming libraries, the signature required as input is a single hex string.

I have searched the internet for standards regarding this conversion but haven't found much satisfactory results.

Divyansh
  • 3
  • 3
  • There are two common formats for ECDSA signatures, ASN.1/DER and P1363 (r|s), see e.g. [here](https://crypto.stackexchange.com/q/57731). – Topaco Dec 23 '22 at 10:15
  • Thanks @Topaco. This helped a lot! Is there some standard format for storing the public key for ecdsa as well since it is a point on the elliptic curve, and therefore a tuple ? – Divyansh Dec 24 '22 at 06:21
  • There are several formats for public EC keys, raw (x|y), uncompressed/compressed (e.g. [here](https://medium.com/asecuritysite-when-bob-met-alice/02-03-or-04-so-what-are-compressed-and-uncompressed-public-keys-6abcb57efeb6)), X.509/SPKI (a more general format, also for RSA etc., e.g. [here](https://jpassing.com/2021/11/30/using-pem-to-encode-public-keys/), Sec. 2), etc. – Topaco Dec 24 '22 at 07:49

0 Answers0