NotRawByteEncodable

This is the opposite of a RawByteEncodable signature

This inverse "non-trait" is required to group CryptoSignature subtypes which cannot be encoded into raw byte arrays, since not all properties required to do so are known. For example, EC signatures parsed from an X509Certificate do not specify a curve. For signatures obtained this way, it is impossible to know how the components should be padded before encoding it into raw bytes.

The reason this interface exists, is that it allows for grouping all such signatures in the same manner as the RawByteEncodable ones, to allow for exhaustive when clauses

Inheritors

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

In Java EC signatures are returned as DER-encoded, RSA signatures however are raw bytearrays

Link copied to clipboard

Signature encoded as per X.509:

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun encodeToDerSafe(): KmmResult<ByteArray>
Link copied to clipboard
abstract fun encodeToTlv(): Asn1Element
Link copied to clipboard
Link copied to clipboard
open fun encodeToTlvSafe(): KmmResult<Asn1Element>
Link copied to clipboard
open infix fun withImplicitTag(tagValue: ULong): Asn1Element