kidToUuid

fun ByteString?.kidToUuid(): Uuid

Convert a KID from a License KeyContainer.id to a Uuid.

KID bytes are not always 16 raw bytes: some services send a decimal digit string, and some send fewer than 16 bytes. They are never Base64 — decoding them as such (as this did) silently mangles every ASCII or hex-string KID. Use the String overload for Base64 input.

Returns the nil UUID for a missing or empty KID.


Convert a Base64-encoded KID String to a Uuid.