Sign data with ECDSA.


Computes a digital signature using ECDSA on the provided data.

Shell Example

Sign data in file data using key 0x52b6 and put the result in file sig:

yubihsm> sign ecdsa 0 0x52b6 ecdsa-sha256 data sig

Protocol Details


Tc = 0x56

Lc = 2 + LD

Vc = I || D

I := Object ID of the Asymmetric Key (2 bytes)

D := H

The DSI for ECDSA is a possibly zero-left-padded hash of the data, H.


Tr = 0xd6

Lr = LDS

Vr = DS

DS := Resulting signature

The length of DS, LDS, depends on the Algorithm used and equals the length of the signature plus its DER encoding.