Package-level declarations

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun <A : Asn1Element, T : Asn1Encodable<A>> Asn1Decodable<A, T>.decodeFromDer(source: Source, limit: Long, assertTag: Asn1Element.Tag? = null): T

Decodes an ASN.1 object of type T from a DER-encoded source.

Link copied to clipboard
fun Asn1Element.encodeToDer(sink: Sink)
fun Asn1Encodable<*>.encodeToDer(sink: Sink)
Link copied to clipboard
fun Asn1Element.Companion.parse(source: Source, limit: Long): Asn1Element

Parses an ASN.1 element from the given source with the specified size limit.

Link copied to clipboard
fun Asn1Element.Companion.parseAll(source: Source, limit: Long): List<Asn1Element>

Parses all ASN.1 elements from the given source within the specified limit.

Link copied to clipboard
fun Asn1Element.Companion.parseFirst(source: Source, limit: Long): Pair<Asn1Element, Long>

Parses the first ASN.1 element from the given source within the specified limit.

Link copied to clipboard
fun Source.readAsn1Asn1IntegerContent(nBytes: Int, lenient: Boolean = false): Asn1Integer
Link copied to clipboard
fun Source.readAsn1BooleanContent(nBytes: Int = 1): Boolean
Link copied to clipboard
fun Source.readAsn1ByteContent(nBytes: Int, lenient: Boolean = false): Byte
Link copied to clipboard
fun Source.readAsn1DoubleContent(nBytes: Int, lenient: Boolean = false): Double
Link copied to clipboard
fun Source.readAsn1Element(limit: Long): Pair<Asn1Element, Long>

Reads an ASN.1 element from the source up to the specified byte limit.

Link copied to clipboard
fun Source.readAsn1FloatContent(nBytes: Int, lenient: Boolean = false): Float
Link copied to clipboard
Link copied to clipboard
fun Source.readAsn1IntContent(nBytes: Int, lenient: Boolean = false): Int
Link copied to clipboard
fun Source.readAsn1LongContent(nBytes: Int, lenient: Boolean = false): Long
Link copied to clipboard
fun Source.readAsn1RealContent(nBytes: Int, lenient: Boolean = false): Asn1Real
Link copied to clipboard
fun Source.readAsn1ShortContent(nBytes: Int, lenient: Boolean = false): Short
Link copied to clipboard
fun Source.readAsn1StringContent(nBytes: Int): String
Link copied to clipboard
fun Source.readAsn1UByteContent(nBytes: Int, lenient: Boolean = false): UByte
Link copied to clipboard
fun Source.readAsn1UIntContent(nBytes: Int, lenient: Boolean = false): UInt
Link copied to clipboard
fun Source.readAsn1ULongContent(nBytes: Int, lenient: Boolean = false): ULong
Link copied to clipboard
fun Source.readAsn1UShortContent(nBytes: Int, lenient: Boolean = false): UShort
Link copied to clipboard
fun Source.readAsn1UtcTimeContent(nBytes: Int): Instant
Link copied to clipboard

Reads all available data from the source up to the specified limit and parses it into a list of ASN.1 elements along with the total number of bytes read.

Link copied to clipboard
fun Source.readTwosComplementInt(nBytes: Int, lenient: Boolean = false): Int
Link copied to clipboard
fun Source.readTwosComplementLong(nBytes: Int, lenient: Boolean = false): Long
Link copied to clipboard
fun Source.readTwosComplementUInt(nBytes: Int, lenient: Boolean = false): UInt
Link copied to clipboard
fun Source.readTwosComplementULong(nBytes: Int, lenient: Boolean = false): ULong
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Sink.writeAsn1ByteContent(value: Byte): Int
Link copied to clipboard
Link copied to clipboard
fun Sink.writeAsn1FloatContent(value: Float): Int
Link copied to clipboard
Link copied to clipboard
fun Sink.writeAsn1IntContent(value: Int): Int
Link copied to clipboard
fun Sink.writeAsn1LongContent(value: Long): Int
Link copied to clipboard
Link copied to clipboard
fun Sink.writeAsn1ShortContent(value: Short): Int
Link copied to clipboard
Link copied to clipboard
fun Sink.writeAsn1UByteContent(value: UByte): Int
Link copied to clipboard
fun Sink.writeAsn1UIntContent(value: UInt): Int
Link copied to clipboard
fun Sink.writeAsn1ULongContent(value: ULong): Int
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Sink.writeAsn1VarInt(number: UInt): Int
fun Sink.writeAsn1VarInt(number: ULong): Int
Link copied to clipboard
fun Sink.writeMagnitudeLong(value: Long): Int
Link copied to clipboard
fun Sink.writeTwosComplementLong(value: Long): Int
Link copied to clipboard
fun Sink.writeTwosComplementUInt(value: UInt): Int
Link copied to clipboard