serializeAsCwt

suspend fun serializeAsCwt(key: AsymmetricKey, subject: String, expiresIn: Duration = 20.minutes + Random.Default.nextInt(1000).seconds): ByteArray

Creates JWT serialization of the status list.

Return

signed JWT that represents this status list

Parameters

key

key that is used to sign JWT

subject

value for sub claim in JWT

expiresIn

how long the status list is valid (random duration about half an our by default, so that update requests don't all come at the same time)