BPToBytes

Cryptography

Description

Serializes a Brainpool big-integer value to a fixed-length big-endian byte string

Syntax

Delphi

Function BPToBytes(Const V: TBPValue; ByteLen: Integer): AnsiString;

Parameters

VThe value to serialize
ByteLenOutput length between 1 and 64 bytes; the value is truncated or zero-padded to fit

Return values

ByteLen bytes, most significant byte first; an empty string when ByteLen is out of range

Remarks

Curve workflows need fixed-width coordinates, so pass the curve byte length rather than a minimal encoding

Inverse of BPFromBytes

See also

BPFromBytes, BPLoadCurve, BPKeyGen, BPSignFixedK