decompressEcPublicKey

Decompresses an EC public key point to SEC1 uncompressed form (0x04 || x || y).

Accepts a compressed point (0x02/0x03 || x, decompressed by solving y² = x³ + ax + b over GF(p)) or a legacy uncompressed point (returned unchanged, for backward compatibility with pre-spec did:key encodings).

Throws

if algorithm is not a supported EC curve, point is not a valid SEC1 encoding, or x is not on the curve