úÎ|êqĞd      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abc  BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknownNoneHM d.The Get monad is an Exception and State monad.e!Have we read all available input?fThe result of a parse.gThe parse succeeded. The hU is the input that had not yet been consumed (if any) when the parse succeeded.i‚Supply this continuation with more input so that the parser can resume. To indicate that no more input is available, use an j string.kThe parse failed. The l0 is the message describing the error, if any.mRun the Get monad applies a get%-based parser on the input ByteStringn If at least nK bytes of input are available, return the current input, otherwise fail.o If at least nK bytes of input are available, return the current input, otherwise fail.p$Immediately demand more input via a i continuation result.q An efficient get5 method for strict ByteStrings. Fails if fewer than nZ bytes are left in the input. This function creates a fresh copy of the underlying bytes.rPull n. bytes from the input, as a strict ByteString.$dsteuvwxyz{fgik|}~€mnop‚qrƒ„…†‡ˆ‰Š d{fgikmqrƒdstevuwxyz{fkig|}~€mnop‚qrƒ„…†‡ˆ‰Š  BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknown Safe-Inferred‹ZuintOfBytes returns the number of bytes and the unsigned integer represented by the bytes ŒxintOfBytes returns the number of bytes in the list and the represented integer by a two's completement list of bytes HbytesOfInt convert an integer into a two's completemented list of bytes ‹Œ‹Œ‹Œ BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknown Safe-Inferred+)Possible errors during parsing operations>Policy failed including the name of the policy and the reason.!Decoding of a knowed type failed.ADecoding of a type that is not implemented. Contribution welcome.7Parsing is not finished, there is construction unended.Parsing an invalid header.AAn unexpected situation has come up parsing an ASN1 event stream.:A construction goes over the size specified in the header.3Invalid primitive with infinite length in a stream. Unexpected EOC in the stream. ,represent one event from an asn1 data stream Constructed value end Constructed value start  Primitive ASN1 Header=ASN1 Header with the class, tag, constructed flag and length.&ASN1 Length with all different formatsCLength is indefinite expect an EOC in the stream to finish the typeLong form of N bytes6Short form with only one byte. length has to be < 127.ASN1 Tag Element class          BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknownNone‘parse an ASN1 header’!Parse the first word of an header“?putIdentifier encode an ASN1 Identifier into a marshalled value”VputLength encode a length into a ASN1 length. - see getLength for the encoding rules ‘’•–“”‘“‘’•–“”  BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknownNone—(Represent the events and state thus far.˜.represent the parsing state of an ASN1 stream.™†nothing means the parser stop this construction on an ASN1 end tag, otherwise specify the position where the construction terminate.š-create a new empty parse state. position is 0›’run incrementally the ASN1 parser on a bytestring. the result can be either an error, or on success a list of events, and the new parsing state.œcwhen no more input is available, it's important to check that the parser is in a finish state too.LParse one lazy bytestring and returns on success all ASN1 events associated.NParse one strict bytestring and returns on success all ASN1 events associated.—˜Ÿ ¡™š¢£¤› parser stateinput data as bytesœ—˜š›œ —˜Ÿ¡ ™š¢£¤›œ  BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknownNone8transform a list of ASN1 Events into a strict bytestring6transform a list of ASN1 Events into a lazy bytestring BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknownNone    BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknown Safe-Inferred+ represent a bitarray / bitmap!1throwed in case of out of bounds in the bitarray.#+returns the length of bits in this bitarray$get the nth bits%&set the nth bit to the value specified&set the nth bits'clear the nth bits(%get padded bytestring of the bitarray)*number of bit to skip at the end (padding)  !"#¥$%&'()¦  !"#$%&'()  !"#$%&'()  !"#¥$%&'()¦ BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknown Safe-Inferred+Define high level ASN1 object.EDefine the type of container!*+,-./0123456789:;<=>?@ABCDEFGHIJ'*+,-./0123456789:;<=>?@ABCDEFGHIJ'+DCBA@?>=<;:9876543210/.-,*EHGFIJ*+DCBA@?>=<;:9876543210/.-,EHGFIJ BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknown Safe-Inferred KIDescribe an ASN1 encoding, that transform an asn1stream into a bytestreamL&encode a stream into a lazy bytestringMtransition class.N,decode a lazy bytestring into an ASN1 streamOIDescribe an ASN1 decoding, that transform a bytestream into an asn1streamP,decode a lazy bytestring into an ASN1 streamQ.decode a strict bytestring into an ASN1 streamR2decode a strict bytestring into an ASN1Repr streamS(encode a stream into a strict bytestring KLMNOPQRS KLMNOPQRS OPMNKLQRSKLMNOPQRS BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknownNoneB TParse ASN1 MonadUWrun the parse monad over a stream and returns the result and the remaining ASN1 Stream.V9run the parse monad over a stream and returns the result.W get next element from the streamX@get next container of specified type and return all its elementsYDrun a function of the next elements of a container of specified typeZ]just like getNextContainer, except it doesn't throw an error if the container doesn't exists.[\just like onNextContainer, except it doens't throw an error if the container doesn't exists.\/returns if there's more elements in the stream. T§¨UVWXYZ[\ TUVWXYZ[\ TUVY[XZW\ T§¨UVWXYZ[\ BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknown Safe-Inferred]1an object that can be marshalled from and to ASN1^(transform an object into an ASN1 stream._Greturns either an object along the remaining ASN1 stream, or an error.]^_]^_]^_]^_ BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknownNone©agetInteger, parse a value bytestring and get the integer out of the two complement encoded bytes ªreturn an OID («¬­®¯°±²³´µ¶·©¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇªÈÉÊËÌÍÎÏĞ@+,-./0123456789:;<=>?@ABCDEFGH®¯±²³´µ¶·©¸º»¼½¾¿ÀÁÂÃÄÅÆÇªÈÉËÌÍÎÏĞ(«¬­®¯°±²³´µ¶·©¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇªÈÉÊËÌÍÎÏĞ BSD-style#Vincent Hanquez <vincent@snarc.org> experimentalunknownNone<`"Distinguished Encoding Rules (DER)bBasic Encoding Rules (BER)ÑFDER header need to be all of finite size and of minimum possible size. `abcÒÓÑÔÕÖרÙ`abcbc`a `abcÒÓÑÔÕÖרÙÚ !"#$%&'( ) * + ,--../0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijkllmm n o p qrst urvw xyz{ | } ~  € n ‚ ƒ „ … † ‡ ˆ ‰ Š ‹ Œ ‘ ’ “ ” • – — ˜ ™ š › œ  Ÿ   ¡ ¢ £ ¤ ¥ ¦ § ¨ © ª ¦ « ¬ ­ ® ¯ ° ±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏĞÑÒÓÔÕÖרÙÚÛÜİŞßàáâãäåæçasn1-data-0.7.2Data.ASN1.TypesData.ASN1.BinaryEncoding.RawData.ASN1.BitArrayData.ASN1.StreamData.ASN1.EncodingData.ASN1.ParseData.ASN1.ObjectData.ASN1.BinaryEncoding Data.ASN1.GetData.ASN1.InternalData.ASN1.SerializeData.ASN1.BinaryEncoding.ParseData.ASN1.BinaryEncoding.WriterData.ASN1.Prim ASN1Error PolicyFailedTypeDecodingFailedTypeNotImplementedParsingPartialParsingHeaderFailStreamUnexpectedSituationStreamConstructionWrongSizeStreamInfinitePrimitiveStreamUnexpectedEOC ASN1EventConstructionEndConstructionBegin PrimitiveHeader ASN1Header ASN1Length LenIndefiniteLenLongLenShortASN1Tag ASN1ClassPrivateContext Application UniversalparseLBSparseBS toByteStringtoLazyByteStringBitArrayBitArrayOutOfBoundbitArrayLengthbitArrayGetBitbitArraySetBitValuebitArraySetBitbitArrayClearBitbitArrayGetData toBitArrayASN1ReprASN1EndStartOther BMPStringCharacterStringUniversalString GeneralString VisibleString GraphicStringGeneralizedTimeUTCTime IA5StringVideoTexString T61StringPrintableString NumericString UTF8String EnumeratedRealOIDNull OctetString BitStringIntValBooleanASN1ConstructionType ContainerSetSequencegetConstructedEndgetConstructedEndRepr ASN1Encoding encodeASN1ASN1DecodingReprdecodeASN1Repr ASN1Decoding decodeASN1 decodeASN1'decodeASN1Repr' encodeASN1' ParseASN1runParseASN1State runParseASN1getNextgetNextContaineronNextContainergetNextContainerMaybeonNextContainerMaybehasNext ASN1ObjecttoASN1fromASN1DERBERGetMoreResultDonebytestring-0.10.4.0Data.ByteString.Internal ByteStringPartialData.ByteStringemptyFailbaseGHC.BaseString runGetPosensure ensureRec demandInput getBytesCopygetBytesunGet IncompleteCompletePositionSuccessFailureBufferInputappend bufferBytesputfinalKfailKrunGetfailDescgetWord8$fMonadPlusGet $fMonadGet$fAlternativeGet$fApplicativeGet $fFunctorGet$fFunctorResult $fShowResult uintOfBytes intOfBytes bytesOfInt bytesOfUIntputVarEncodingIntegral$fExceptionASN1Error getHeaderparseFirstWord putHeader putLength getTagLong getLength ParseCursor ParseStateConstructionEndAt newParseState runParseState isParseDone ParsePosition ParseExpectExpectPrimitive ExpectHeaderisEOCasn1LengthToConst mplusEitherbitArrayOutOfBound$fExceptionBitArrayOutOfBoundPrunP getIntegergetOIDASN1Ret encodeUCS2BE decodeUCS2BE encodeHeaderencodePrimitiveHeaderencodePrimitiveDataencodePrimitive encodeOne encodeListencodeConstructedmkSmallestLengthdecodePrimitive getBoolean getBitString getStringgetOctetStringgetNumericStringgetPrintableString getUTF8String getT61StringgetVideoTexString getIA5StringgetGraphicStringgetVisibleStringgetGeneralStringgetUniversalStringgetCharacterString getBMPStringgetNull getUTCTimegetGeneralizedTimeputTime putUTCTimeputGeneralizedTime putInteger putBitString putStringputOIDcheckDERdecodeConstructiondecodeEventASN1Repr encodeToRaw$fASN1EncodingDER$fASN1DecodingDER$fASN1DecodingReprDER$fASN1DecodingBER$fASN1DecodingReprBER