asn1-data-0.2.1: ASN1 data reader and writer in RAW, BER, DER and CER forms

Portabilityunknown
Stabilityexperimental
MaintainerVincent Hanquez <vincent@snarc.org>

Data.ASN1.Raw

Contents

Description

A module containing raw ASN1 serialization/derialization tools

Synopsis

Documentation

get structure

ASN1 definitions

data ValLength Source

Constructors

LenShort Int

Short form with only one byte. length has to be < 127.

LenLong Int Int

Long form of N bytes

LenIndefinite

Length is indefinite expect an EOC in the stream to finish the type

data ValStruct Source

Constructors

Primitive ByteString

Primitive of a strict value

Constructed [Value]

Constructed of a list of values

get value from a Get structure

getValueCheck :: CheckFn -> GetErr ValueSource

getValueCheck decode an ASN1 value and check the values received through the check fn

put value in a Put structure

putValue :: Value -> PutSource

putValue encode an ASN1 value using the shortest definite length