@peculiar/certificates-viewer 4.6.0 → 4.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/attribute-certificate-viewer.js +2 -2
- package/components/attribute-certificate-viewer.js.map +1 -1
- package/components/button-menu.js +1 -1
- package/components/button.js +3 -1
- package/components/button.js.map +1 -1
- package/components/certificate-chain-viewer.js +2 -2
- package/components/certificate-chain-viewer.js.map +1 -1
- package/components/certificate-viewer.js +2 -2
- package/components/certificate-viewer.js.map +1 -1
- package/components/circular-progress.js +1 -1
- package/components/crl-viewer.js +2 -2
- package/components/crl-viewer.js.map +1 -1
- package/components/csr-viewer.js +2 -2
- package/components/csr-viewer.js.map +1 -1
- package/components/download.js +3286 -3079
- package/components/download.js.map +1 -1
- package/components/highlight-words.js +1 -1
- package/components/index.js +1 -1
- package/components/miscellaneous.js.map +1 -1
- package/components/peculiar-certificate-decoder.js +2 -2
- package/components/peculiar-certificate-decoder.js.map +1 -1
- package/components/peculiar-certificates-viewer.js +1 -1
- package/components/peculiar-text-hider.js +1 -1
- package/dist/cjs/{actions-Dl4HXXlI.js → actions-ByC9jQU-.js} +3 -3
- package/dist/cjs/{actions-Dl4HXXlI.js.map → actions-ByC9jQU-.js.map} +1 -1
- package/dist/cjs/{arrow_top-DBMPHVlB.js → arrow_top-Cw9KN115.js} +3 -3
- package/dist/cjs/{arrow_top-DBMPHVlB.js.map → arrow_top-Cw9KN115.js.map} +1 -1
- package/dist/cjs/{button-B0CduHSE.js → button-C8EWG_-r.js} +6 -4
- package/dist/cjs/button-C8EWG_-r.js.map +1 -0
- package/dist/cjs/{certification_request-DaJSDP3R.js → certification_request-CxHe71zR.js} +3288 -3081
- package/dist/cjs/certification_request-CxHe71zR.js.map +1 -0
- package/dist/cjs/{cross-pi7K0cHC.js → cross-3DqhA0G_.js} +3 -3
- package/dist/cjs/{cross-pi7K0cHC.js.map → cross-3DqhA0G_.js.map} +1 -1
- package/dist/cjs/{download-D9skkVoT.js → download-DQP0KR4o.js} +3 -3
- package/dist/cjs/{download-D9skkVoT.js.map → download-DQP0KR4o.js.map} +1 -1
- package/dist/cjs/{index-BO3rFndV.js → index-uHmGhObe.js} +430 -157
- package/dist/cjs/index-uHmGhObe.js.map +1 -0
- package/dist/cjs/index.cjs.js +9 -9
- package/dist/cjs/{link-kgbgxxVh.js → link-Cgh8wnbs.js} +4 -4
- package/dist/cjs/{link-kgbgxxVh.js.map → link-Cgh8wnbs.js.map} +1 -1
- package/dist/cjs/loader.cjs.js +3 -4
- package/dist/cjs/loader.cjs.js.map +1 -1
- package/dist/cjs/{miscellaneous-Ce9aGjKB.js → miscellaneous-DeBEwLDy.js} +7 -7
- package/dist/cjs/miscellaneous-DeBEwLDy.js.map +1 -0
- package/dist/cjs/peculiar-attribute-certificate-viewer.peculiar-certificate-chain-viewer.peculiar-crl-viewer.peculiar-csr-viewer.entry.cjs.js.map +1 -1
- package/dist/cjs/peculiar-attribute-certificate-viewer_4.cjs.entry.js +12 -12
- package/dist/cjs/peculiar-attribute-certificate-viewer_4.cjs.entry.js.map +1 -1
- package/dist/cjs/peculiar-button-menu_3.cjs.entry.js +3 -3
- package/dist/cjs/peculiar-certificate-decoder.cjs.entry.js +6 -6
- package/dist/cjs/peculiar-certificate-decoder.cjs.entry.js.map +1 -1
- package/dist/cjs/peculiar-certificate-decoder.entry.cjs.js.map +1 -1
- package/dist/cjs/peculiar-certificate-viewer.cjs.entry.js +8 -8
- package/dist/cjs/peculiar-certificate-viewer.cjs.entry.js.map +1 -1
- package/dist/cjs/peculiar-certificate-viewer.entry.cjs.js.map +1 -1
- package/dist/cjs/peculiar-certificates-viewer.cjs.entry.js +7 -7
- package/dist/cjs/peculiar-text-hider.cjs.entry.js +3 -3
- package/dist/cjs/peculiar.cjs.js +4 -5
- package/dist/cjs/peculiar.cjs.js.map +1 -1
- package/dist/cjs/{pkcs10_certificate_request-D13Ssi7Z.js → pkcs10_certificate_request-CHMDxe2Z.js} +3 -3
- package/dist/cjs/{pkcs10_certificate_request-D13Ssi7Z.js.map → pkcs10_certificate_request-CHMDxe2Z.js.map} +1 -1
- package/dist/cjs/{x509_certificate-h5GZArG6.js → x509_certificate-CzplJQ0X.js} +3 -3
- package/dist/cjs/{x509_certificate-h5GZArG6.js.map → x509_certificate-CzplJQ0X.js.map} +1 -1
- package/dist/cjs/{x509_crl-CDPt6P1z.js → x509_crl-B7kFbLDV.js} +4 -4
- package/dist/cjs/{x509_crl-CDPt6P1z.js.map → x509_crl-B7kFbLDV.js.map} +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/attribute-certificate-viewer/attribute-certificate-viewer.js +7 -7
- package/dist/collection/components/button-menu/button-menu.js +1 -0
- package/dist/collection/components/button-menu/button-menu.js.map +1 -1
- package/dist/collection/components/certificate-chain-viewer/certificate-chain-viewer.css +3 -0
- package/dist/collection/components/certificate-chain-viewer/certificate-chain-viewer.js +2 -1
- package/dist/collection/components/certificate-chain-viewer/certificate-chain-viewer.js.map +1 -1
- package/dist/collection/components/certificate-decoder/certificate-decoder.js +2 -1
- package/dist/collection/components/certificate-decoder/certificate-decoder.js.map +1 -1
- package/dist/collection/components/certificate-viewer/certificate-viewer.css +3 -0
- package/dist/collection/components/certificate-viewer/certificate-viewer.js +8 -8
- package/dist/collection/components/certificates-viewer/certificates-viewer.js +4 -3
- package/dist/collection/components/certificates-viewer/certificates-viewer.js.map +1 -1
- package/dist/collection/components/circular-progress/circular-progress.js +2 -2
- package/dist/collection/components/crl-viewer/crl-viewer.js +6 -6
- package/dist/collection/components/csr-viewer/csr-viewer.js +5 -5
- package/dist/collection/components/highlight-words/highlight-words.js +1 -1
- package/dist/collection/components/typography/typography.js +1 -1
- package/dist/collection/components/typography/typography.js.map +1 -1
- package/dist/esm/{actions-DzoPRObK.js → actions-BOY2Tl0T.js} +3 -3
- package/dist/esm/{actions-DzoPRObK.js.map → actions-BOY2Tl0T.js.map} +1 -1
- package/dist/esm/{arrow_top-CF9pv-tQ.js → arrow_top-DL0RWe4n.js} +3 -3
- package/dist/{esm-es5/arrow_top-CF9pv-tQ.js.map → esm/arrow_top-DL0RWe4n.js.map} +1 -1
- package/dist/esm/{button-Do0R_8PZ.js → button-Bbh7MwG6.js} +6 -4
- package/dist/esm/button-Bbh7MwG6.js.map +1 -0
- package/dist/esm/{certification_request-DazysL_f.js → certification_request-PeMaLTUD.js} +3288 -3081
- package/dist/esm/certification_request-PeMaLTUD.js.map +1 -0
- package/dist/esm/{cross-DdCuR1F2.js → cross-G84H_-QL.js} +3 -3
- package/dist/{esm-es5/cross-DdCuR1F2.js.map → esm/cross-G84H_-QL.js.map} +1 -1
- package/dist/esm/{download-Cqfc-Sxf.js → download-ykcxSgxU.js} +3 -3
- package/dist/esm/{download-Cqfc-Sxf.js.map → download-ykcxSgxU.js.map} +1 -1
- package/dist/esm/{index-DDDrq3In.js → index-CwgZaF40.js} +430 -158
- package/dist/esm/index-CwgZaF40.js.map +1 -0
- package/dist/esm/index.js +9 -9
- package/dist/esm/{link-qg3yKAoS.js → link-CGURvKy1.js} +4 -4
- package/dist/esm/{link-qg3yKAoS.js.map → link-CGURvKy1.js.map} +1 -1
- package/dist/esm/loader.js +3 -4
- package/dist/esm/loader.js.map +1 -1
- package/dist/esm/{miscellaneous-BJPX0Hs_.js → miscellaneous-bVeJt-6m.js} +7 -7
- package/dist/esm/miscellaneous-bVeJt-6m.js.map +1 -0
- package/dist/esm/peculiar-attribute-certificate-viewer.peculiar-certificate-chain-viewer.peculiar-crl-viewer.peculiar-csr-viewer.entry.js.map +1 -1
- package/dist/esm/peculiar-attribute-certificate-viewer_4.entry.js +12 -12
- package/dist/esm/peculiar-attribute-certificate-viewer_4.entry.js.map +1 -1
- package/dist/esm/peculiar-button-menu_3.entry.js +3 -3
- package/dist/esm/peculiar-certificate-decoder.entry.js +6 -6
- package/dist/esm/peculiar-certificate-decoder.entry.js.map +1 -1
- package/dist/esm/peculiar-certificate-viewer.entry.js +8 -8
- package/dist/esm/peculiar-certificate-viewer.entry.js.map +1 -1
- package/dist/esm/peculiar-certificates-viewer.entry.js +7 -7
- package/dist/esm/peculiar-text-hider.entry.js +3 -3
- package/dist/esm/peculiar.js +4 -5
- package/dist/esm/peculiar.js.map +1 -1
- package/dist/esm/{pkcs10_certificate_request-SQcYKma2.js → pkcs10_certificate_request-CK8FH47X.js} +3 -3
- package/dist/{esm-es5/pkcs10_certificate_request-SQcYKma2.js.map → esm/pkcs10_certificate_request-CK8FH47X.js.map} +1 -1
- package/dist/esm/{x509_certificate-Dmgw53TR.js → x509_certificate-CEEWtU_T.js} +3 -3
- package/dist/{esm-es5/x509_certificate-Dmgw53TR.js.map → esm/x509_certificate-CEEWtU_T.js.map} +1 -1
- package/dist/esm/{x509_crl-B5TRu79b.js → x509_crl-BcZd9KVn.js} +4 -4
- package/dist/{esm-es5/x509_crl-B5TRu79b.js.map → esm/x509_crl-BcZd9KVn.js.map} +1 -1
- package/dist/esm-es5/{actions-DzoPRObK.js → actions-BOY2Tl0T.js} +2 -2
- package/dist/esm-es5/{actions-DzoPRObK.js.map → actions-BOY2Tl0T.js.map} +1 -1
- package/dist/esm-es5/{arrow_top-CF9pv-tQ.js → arrow_top-DL0RWe4n.js} +2 -2
- package/dist/{esm/arrow_top-CF9pv-tQ.js.map → esm-es5/arrow_top-DL0RWe4n.js.map} +1 -1
- package/dist/esm-es5/button-Bbh7MwG6.js +19 -0
- package/dist/esm-es5/button-Bbh7MwG6.js.map +1 -0
- package/dist/esm-es5/{certification_request-DazysL_f.js → certification_request-PeMaLTUD.js} +14 -14
- package/dist/esm-es5/certification_request-PeMaLTUD.js.map +1 -0
- package/dist/esm-es5/{cross-DdCuR1F2.js → cross-G84H_-QL.js} +2 -2
- package/dist/{esm/cross-DdCuR1F2.js.map → esm-es5/cross-G84H_-QL.js.map} +1 -1
- package/dist/esm-es5/{download-Cqfc-Sxf.js → download-ykcxSgxU.js} +2 -2
- package/dist/esm-es5/{download-Cqfc-Sxf.js.map → download-ykcxSgxU.js.map} +1 -1
- package/dist/esm-es5/index-CwgZaF40.js +6 -0
- package/dist/esm-es5/index-CwgZaF40.js.map +1 -0
- package/dist/esm-es5/index.js +1 -1
- package/dist/esm-es5/{link-qg3yKAoS.js → link-CGURvKy1.js} +3 -3
- package/dist/esm-es5/{link-qg3yKAoS.js.map → link-CGURvKy1.js.map} +1 -1
- package/dist/esm-es5/loader.js +2 -2
- package/dist/esm-es5/loader.js.map +1 -1
- package/dist/esm-es5/{miscellaneous-BJPX0Hs_.js → miscellaneous-bVeJt-6m.js} +2 -2
- package/dist/esm-es5/miscellaneous-bVeJt-6m.js.map +1 -0
- package/dist/esm-es5/peculiar-attribute-certificate-viewer.peculiar-certificate-chain-viewer.peculiar-crl-viewer.peculiar-csr-viewer.entry.js.map +1 -1
- package/dist/esm-es5/peculiar-attribute-certificate-viewer_4.entry.js +2 -2
- package/dist/esm-es5/peculiar-attribute-certificate-viewer_4.entry.js.map +1 -1
- package/dist/esm-es5/peculiar-button-menu_3.entry.js +1 -1
- package/dist/esm-es5/peculiar-certificate-decoder.entry.js +1 -1
- package/dist/esm-es5/peculiar-certificate-decoder.entry.js.map +1 -1
- package/dist/esm-es5/peculiar-certificate-viewer.entry.js +1 -1
- package/dist/esm-es5/peculiar-certificate-viewer.entry.js.map +1 -1
- package/dist/esm-es5/peculiar-certificates-viewer.entry.js +1 -1
- package/dist/esm-es5/peculiar-text-hider.entry.js +1 -1
- package/dist/esm-es5/peculiar.js +2 -2
- package/dist/esm-es5/peculiar.js.map +1 -1
- package/dist/esm-es5/{pkcs10_certificate_request-SQcYKma2.js → pkcs10_certificate_request-CK8FH47X.js} +2 -2
- package/dist/{esm/pkcs10_certificate_request-SQcYKma2.js.map → esm-es5/pkcs10_certificate_request-CK8FH47X.js.map} +1 -1
- package/dist/esm-es5/{x509_certificate-Dmgw53TR.js → x509_certificate-CEEWtU_T.js} +2 -2
- package/dist/{esm/x509_certificate-Dmgw53TR.js.map → esm-es5/x509_certificate-CEEWtU_T.js.map} +1 -1
- package/dist/esm-es5/{x509_crl-B5TRu79b.js → x509_crl-BcZd9KVn.js} +4 -4
- package/dist/{esm/x509_crl-B5TRu79b.js.map → esm-es5/x509_crl-BcZd9KVn.js.map} +1 -1
- package/dist/peculiar/index.esm.js +1 -1
- package/dist/peculiar/loader.esm.js.map +1 -1
- package/dist/peculiar/p-00d6f11f.system.entry.js +111 -0
- package/dist/peculiar/p-00d6f11f.system.entry.js.map +1 -0
- package/dist/peculiar/{p-218364f2.entry.js → p-0de4837d.entry.js} +2 -2
- package/dist/peculiar/p-0de4837d.entry.js.map +1 -0
- package/dist/peculiar/{p-16aa5600.system.entry.js → p-14fcbc5c.system.entry.js} +2 -2
- package/dist/peculiar/p-14fcbc5c.system.entry.js.map +1 -0
- package/dist/peculiar/{p-7b0e7f43.entry.js → p-27ae6a3a.entry.js} +2 -2
- package/dist/peculiar/{p-ab6a8a44.entry.js → p-315805ce.entry.js} +2 -2
- package/dist/peculiar/p-315805ce.entry.js.map +1 -0
- package/dist/peculiar/{p-5b843427.entry.js → p-5479a530.entry.js} +2 -2
- package/dist/peculiar/{p-52444a44.system.entry.js → p-591a9019.system.entry.js} +2 -2
- package/dist/peculiar/p-591a9019.system.entry.js.map +1 -0
- package/dist/peculiar/{p-a3c0f753.system.entry.js → p-607d08e8.system.entry.js} +2 -2
- package/dist/peculiar/{p-44648a8e.system.entry.js → p-84f69023.system.entry.js} +2 -2
- package/dist/peculiar/{p-15c2b820.entry.js → p-9d9f24bd.entry.js} +2 -2
- package/dist/peculiar/{p-Cm-ylIxb.system.js → p-B4PdAFCr.system.js} +4 -4
- package/dist/peculiar/p-B4PdAFCr.system.js.map +1 -0
- package/dist/peculiar/p-BGASC3UX.system.js +5 -0
- package/dist/peculiar/p-BGASC3UX.system.js.map +1 -0
- package/dist/peculiar/{p-BcFnjn1R.system.js.map → p-BaebEpW0.system.js.map} +1 -1
- package/dist/peculiar/{p-B2YrZuK2.system.js → p-Bi5mjeeg.system.js} +2 -2
- package/dist/peculiar/{p-B2YrZuK2.system.js.map → p-Bi5mjeeg.system.js.map} +1 -1
- package/dist/peculiar/{p-CDh6shXP.system.js → p-BipKYW6e.system.js} +8 -8
- package/dist/peculiar/p-BipKYW6e.system.js.map +1 -0
- package/dist/peculiar/{p-wYK0iVYg.system.js → p-Bknpl7EO.system.js} +3 -3
- package/dist/peculiar/{p-wYK0iVYg.system.js.map → p-Bknpl7EO.system.js.map} +1 -1
- package/dist/peculiar/p-BloT0Xj9.system.js.map +1 -0
- package/dist/peculiar/p-BypepohK.system.js.map +1 -0
- package/dist/peculiar/{p-DRoyzOgk.system.js → p-C9sY8yng.system.js} +2 -2
- package/dist/peculiar/{p-DRoyzOgk.system.js.map → p-C9sY8yng.system.js.map} +1 -1
- package/dist/peculiar/{p-CJro0Exb.js → p-CGRNSrHk.js} +43 -43
- package/dist/peculiar/p-CGRNSrHk.js.map +1 -0
- package/dist/peculiar/{p-DhdG07f8.js → p-CHnDlTqM.js} +2 -2
- package/dist/peculiar/{p-DhdG07f8.js.map → p-CHnDlTqM.js.map} +1 -1
- package/dist/peculiar/{p-YHrZ3f_s.system.js → p-CZwhKPgb.system.js} +2 -2
- package/dist/peculiar/p-CZwhKPgb.system.js.map +1 -0
- package/dist/peculiar/{p-BA8os2l6.system.js.map → p-CbJQZ9Hh.system.js.map} +1 -1
- package/dist/peculiar/{p-BBgwMHRZ.system.js → p-CdS84qJs.system.js} +5 -5
- package/dist/peculiar/{p-BBgwMHRZ.system.js.map → p-CdS84qJs.system.js.map} +1 -1
- package/dist/peculiar/{p-BmIps4bV.system.js → p-CezfC5i1.system.js} +41 -41
- package/dist/peculiar/p-CezfC5i1.system.js.map +1 -0
- package/dist/peculiar/{p-0HZUc9Ix.js → p-CjWRKsN-.js} +2 -2
- package/dist/peculiar/{p-0HZUc9Ix.js.map → p-CjWRKsN-.js.map} +1 -1
- package/dist/peculiar/{p-CkwiD_ia.js → p-CutTi-2B.js} +4 -4
- package/dist/peculiar/p-CutTi-2B.js.map +1 -0
- package/dist/peculiar/p-CwgZaF40.js +6 -0
- package/dist/peculiar/p-CwgZaF40.js.map +1 -0
- package/dist/peculiar/{p-DzItK48Y.js → p-D1eNnGDF.js} +4 -4
- package/dist/peculiar/{p-DzItK48Y.js.map → p-D1eNnGDF.js.map} +1 -1
- package/dist/peculiar/{p-BP2bmYR2.system.js → p-D8xU284r.system.js} +3 -3
- package/dist/peculiar/{p-BP2bmYR2.system.js.map → p-D8xU284r.system.js.map} +1 -1
- package/dist/peculiar/p-DKl0YViA.system.js +6 -0
- package/dist/peculiar/p-DKl0YViA.system.js.map +1 -0
- package/dist/peculiar/{p-CEHpBNWe.js → p-DMZr5ztF.js} +3 -3
- package/dist/peculiar/{p-CEHpBNWe.js.map → p-DMZr5ztF.js.map} +1 -1
- package/dist/peculiar/{p-BKKflyKt.system.js → p-DRvp86xt.system.js} +5 -5
- package/dist/peculiar/{p-BKKflyKt.system.js.map → p-DRvp86xt.system.js.map} +1 -1
- package/dist/peculiar/{p-DkAhB3Vy.js → p-DanjeXNk.js} +2 -2
- package/dist/peculiar/{p-DkAhB3Vy.js.map → p-DanjeXNk.js.map} +1 -1
- package/dist/peculiar/{p-3zhoLQno.js → p-DrmgUhyv.js} +4 -4
- package/dist/peculiar/{p-3zhoLQno.js.map → p-DrmgUhyv.js.map} +1 -1
- package/dist/peculiar/p-ITVWR0oT.system.js.map +1 -0
- package/dist/peculiar/{p-BBZwtkNN.system.js → p-J1t5v5N3.system.js} +4 -4
- package/dist/peculiar/{p-BBZwtkNN.system.js.map → p-J1t5v5N3.system.js.map} +1 -1
- package/dist/peculiar/{p-BHBizfwo.js → p-JyD6URnB.js} +3 -3
- package/dist/peculiar/{p-BHBizfwo.js.map → p-JyD6URnB.js.map} +1 -1
- package/dist/peculiar/{p-D13P_msn.system.js.map → p-N3w4Sc5c.system.js.map} +1 -1
- package/dist/peculiar/{p-BOSH9vjy.system.js → p-NnCM1ETy.system.js} +3 -3
- package/dist/peculiar/{p-BOSH9vjy.system.js.map → p-NnCM1ETy.system.js.map} +1 -1
- package/dist/peculiar/{p-DazysL_f.js → p-PeMaLTUD.js} +7 -7
- package/dist/peculiar/p-PeMaLTUD.js.map +1 -0
- package/dist/peculiar/{p-CeKqQ13Z.js → p-ZT6tVIen.js} +4 -4
- package/dist/peculiar/{p-CeKqQ13Z.js.map → p-ZT6tVIen.js.map} +1 -1
- package/dist/peculiar/p-c8b3766a.entry.js +110 -0
- package/dist/peculiar/p-c8b3766a.entry.js.map +1 -0
- package/dist/peculiar/{p-d16ddef8.system.entry.js → p-de857304.system.entry.js} +2 -2
- package/dist/peculiar/{p--Pej0I-A.system.js.map → p-eziSY5IJ.system.js.map} +1 -1
- package/dist/peculiar/peculiar-attribute-certificate-viewer.peculiar-certificate-chain-viewer.peculiar-crl-viewer.peculiar-csr-viewer.entry.esm.js.map +1 -1
- package/dist/peculiar/peculiar-certificate-decoder.entry.esm.js.map +1 -1
- package/dist/peculiar/peculiar-certificate-viewer.entry.esm.js.map +1 -1
- package/dist/peculiar/peculiar.esm.js +1 -1
- package/dist/peculiar/peculiar.esm.js.map +1 -1
- package/dist/peculiar/peculiar.js +1 -1
- package/dist/types/components/typography/typography.d.ts +2 -1
- package/dist/types/components.d.ts +26 -0
- package/dist/types/stencil-public-runtime.d.ts +34 -6
- package/hydrate/index.d.ts +38 -24
- package/hydrate/index.js +4281 -3311
- package/hydrate/index.mjs +4280 -3312
- package/package.json +32 -33
- package/dist/cjs/app-globals-BOZYdIuK.js +0 -11
- package/dist/cjs/app-globals-BOZYdIuK.js.map +0 -1
- package/dist/cjs/button-B0CduHSE.js.map +0 -1
- package/dist/cjs/certification_request-DaJSDP3R.js.map +0 -1
- package/dist/cjs/index-BO3rFndV.js.map +0 -1
- package/dist/cjs/miscellaneous-Ce9aGjKB.js.map +0 -1
- package/dist/esm/app-globals-zVR349KA.js +0 -9
- package/dist/esm/app-globals-zVR349KA.js.map +0 -1
- package/dist/esm/button-Do0R_8PZ.js.map +0 -1
- package/dist/esm/certification_request-DazysL_f.js.map +0 -1
- package/dist/esm/index-DDDrq3In.js.map +0 -1
- package/dist/esm/miscellaneous-BJPX0Hs_.js.map +0 -1
- package/dist/esm-es5/app-globals-zVR349KA.js +0 -5
- package/dist/esm-es5/app-globals-zVR349KA.js.map +0 -1
- package/dist/esm-es5/button-Do0R_8PZ.js +0 -19
- package/dist/esm-es5/button-Do0R_8PZ.js.map +0 -1
- package/dist/esm-es5/certification_request-DazysL_f.js.map +0 -1
- package/dist/esm-es5/index-DDDrq3In.js +0 -6
- package/dist/esm-es5/index-DDDrq3In.js.map +0 -1
- package/dist/esm-es5/miscellaneous-BJPX0Hs_.js.map +0 -1
- package/dist/peculiar/p-16aa5600.system.entry.js.map +0 -1
- package/dist/peculiar/p-1cbb0d6b.entry.js +0 -110
- package/dist/peculiar/p-1cbb0d6b.entry.js.map +0 -1
- package/dist/peculiar/p-218364f2.entry.js.map +0 -1
- package/dist/peculiar/p-52444a44.system.entry.js.map +0 -1
- package/dist/peculiar/p-BAB4EyrL.system.js.map +0 -1
- package/dist/peculiar/p-BFenL1ap.system.js +0 -6
- package/dist/peculiar/p-BFenL1ap.system.js.map +0 -1
- package/dist/peculiar/p-BmIps4bV.system.js.map +0 -1
- package/dist/peculiar/p-CDh6shXP.system.js.map +0 -1
- package/dist/peculiar/p-CJro0Exb.js.map +0 -1
- package/dist/peculiar/p-CWs-Ocvt.system.js.map +0 -1
- package/dist/peculiar/p-CkwiD_ia.js.map +0 -1
- package/dist/peculiar/p-Cm-ylIxb.system.js.map +0 -1
- package/dist/peculiar/p-CwlxH4oM.system.js +0 -5
- package/dist/peculiar/p-CwlxH4oM.system.js.map +0 -1
- package/dist/peculiar/p-D5BWI7FK.system.js +0 -5
- package/dist/peculiar/p-D5BWI7FK.system.js.map +0 -1
- package/dist/peculiar/p-DDDrq3In.js +0 -6
- package/dist/peculiar/p-DDDrq3In.js.map +0 -1
- package/dist/peculiar/p-DJRm54BZ.system.js.map +0 -1
- package/dist/peculiar/p-DazysL_f.js.map +0 -1
- package/dist/peculiar/p-YHrZ3f_s.system.js.map +0 -1
- package/dist/peculiar/p-ab6a8a44.entry.js.map +0 -1
- package/dist/peculiar/p-d9013293.system.entry.js +0 -111
- package/dist/peculiar/p-d9013293.system.entry.js.map +0 -1
- package/dist/peculiar/p-zVR349KA.js +0 -5
- package/dist/peculiar/p-zVR349KA.js.map +0 -1
- /package/dist/peculiar/{p-7b0e7f43.entry.js.map → p-27ae6a3a.entry.js.map} +0 -0
- /package/dist/peculiar/{p-5b843427.entry.js.map → p-5479a530.entry.js.map} +0 -0
- /package/dist/peculiar/{p-a3c0f753.system.entry.js.map → p-607d08e8.system.entry.js.map} +0 -0
- /package/dist/peculiar/{p-44648a8e.system.entry.js.map → p-84f69023.system.entry.js.map} +0 -0
- /package/dist/peculiar/{p-15c2b820.entry.js.map → p-9d9f24bd.entry.js.map} +0 -0
- /package/dist/peculiar/{p-d16ddef8.system.entry.js.map → p-de857304.system.entry.js.map} +0 -0
|
@@ -75,14 +75,14 @@ function t(t,e,i,r="application/octet-stream"){const s=new Blob([t],{type:r});if
|
|
|
75
75
|
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
|
76
76
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
77
77
|
*
|
|
78
|
-
*/function f(){if(typeof BigInt==="undefined"){throw new Error("BigInt is not defined. Your environment doesn't implement BigInt.")}}function y(t){let e=0;let i=0;for(let i=0;i<t.length;i++){const r=t[i];e+=r.byteLength}const r=new Uint8Array(e);for(let e=0;e<t.length;e++){const s=t[e];r.set(new Uint8Array(s),i);i+=s.byteLength}return r.buffer}function S(t,e,i,r){if(!(e instanceof Uint8Array)){t.error="Wrong parameter: inputBuffer must be 'Uint8Array'";return false}if(!e.byteLength){t.error="Wrong parameter: inputBuffer has zero length";return false}if(i<0){t.error="Wrong parameter: inputOffset less than zero";return false}if(r<0){t.error="Wrong parameter: inputLength less than zero";return false}if(e.byteLength-i-r<0){t.error="End of input reached before message was fully decoded (inconsistent offset and length values)";return false}return true}class A{constructor(){this.items=[]}write(t){this.items.push(t)}final(){return y(this.items)}}const C=[new Uint8Array([1])];const v="0123456789";const m="name";const g="valueHexView";const w="isHexOnly";const E="idBlock";const P="tagClass";const D="tagNumber";const b="isConstructed";const B="fromBER";const I="toBER";const x="local";const T="";const O=new ArrayBuffer(0);const R=new Uint8Array(0);const M="EndOfContent";const N="OCTET STRING";const k="BIT STRING";function K(t){var e;return e=class e extends t{constructor(...t){var e;super(...t);const i=t[0]||{};this.isHexOnly=(e=i.isHexOnly)!==null&&e!==void 0?e:false;this.valueHexView=i.valueHex?n.BufferSourceConverter.toUint8Array(i.valueHex):R}get valueHex(){return this.valueHexView.slice().buffer}set valueHex(t){this.valueHexView=new Uint8Array(t)}fromBER(t,e,i){const r=t instanceof ArrayBuffer?new Uint8Array(t):t;if(!S(this,r,e,i)){return-1}const s=e+i;this.valueHexView=r.subarray(e,s);if(!this.valueHexView.length){this.warnings.push("Zero buffer length");return e}this.blockLength=i;return s}toBER(t=false){if(!this.isHexOnly){this.error="Flag 'isHexOnly' is not set, abort";return O}if(t){return new ArrayBuffer(this.valueHexView.byteLength)}return this.valueHexView.byteLength===this.valueHexView.buffer.byteLength?this.valueHexView.buffer:this.valueHexView.slice().buffer}toJSON(){return{...super.toJSON(),isHexOnly:this.isHexOnly,valueHex:n.Convert.ToHex(this.valueHexView)}}},e.NAME="hexBlock",e}class H{constructor({blockLength:t=0,error:e=T,warnings:i=[],valueBeforeDecode:r=R}={}){this.blockLength=t;this.error=e;this.warnings=i;this.valueBeforeDecodeView=n.BufferSourceConverter.toUint8Array(r)}static blockName(){return this.NAME}get valueBeforeDecode(){return this.valueBeforeDecodeView.slice().buffer}set valueBeforeDecode(t){this.valueBeforeDecodeView=new Uint8Array(t)}toJSON(){return{blockName:this.constructor.NAME,blockLength:this.blockLength,error:this.error,warnings:this.warnings,valueBeforeDecode:n.Convert.ToHex(this.valueBeforeDecodeView)}}}H.NAME="baseBlock";class j extends H{fromBER(t,e,i){throw TypeError("User need to make a specific function in a class which extends 'ValueBlock'")}toBER(t,e){throw TypeError("User need to make a specific function in a class which extends 'ValueBlock'")}}j.NAME="valueBlock";class U extends(K(H)){constructor({idBlock:t={}}={}){var e,i,r,s;super();if(t){this.isHexOnly=(e=t.isHexOnly)!==null&&e!==void 0?e:false;this.valueHexView=t.valueHex?n.BufferSourceConverter.toUint8Array(t.valueHex):R;this.tagClass=(i=t.tagClass)!==null&&i!==void 0?i:-1;this.tagNumber=(r=t.tagNumber)!==null&&r!==void 0?r:-1;this.isConstructed=(s=t.isConstructed)!==null&&s!==void 0?s:false}else{this.tagClass=-1;this.tagNumber=-1;this.isConstructed=false}}toBER(t=false){let e=0;switch(this.tagClass){case 1:e|=0;break;case 2:e|=64;break;case 3:e|=128;break;case 4:e|=192;break;default:this.error="Unknown tag class";return O}if(this.isConstructed)e|=32;if(this.tagNumber<31&&!this.isHexOnly){const i=new Uint8Array(1);if(!t){let t=this.tagNumber;t&=31;e|=t;i[0]=e}return i.buffer}if(!this.isHexOnly){const i=c(this.tagNumber,7);const r=new Uint8Array(i);const s=i.byteLength;const n=new Uint8Array(s+1);n[0]=e|31;if(!t){for(let t=0;t<s-1;t++)n[t+1]=r[t]|128;n[s]=r[s-1]}return n.buffer}const i=new Uint8Array(this.valueHexView.byteLength+1);i[0]=e|31;if(!t){const t=this.valueHexView;for(let e=0;e<t.length-1;e++)i[e+1]=t[e]|128;i[this.valueHexView.byteLength]=t[t.length-1]}return i.buffer}fromBER(t,e,i){const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}const s=r.subarray(e,e+i);if(s.length===0){this.error="Zero buffer length";return-1}const o=s[0]&192;switch(o){case 0:this.tagClass=1;break;case 64:this.tagClass=2;break;case 128:this.tagClass=3;break;case 192:this.tagClass=4;break;default:this.error="Unknown tag class";return-1}this.isConstructed=(s[0]&32)===32;this.isHexOnly=false;const c=s[0]&31;if(c!==31){this.tagNumber=c;this.blockLength=1}else{let t=1;let e=this.valueHexView=new Uint8Array(255);let i=255;while(s[t]&128){e[t-1]=s[t]&127;t++;if(t>=s.length){this.error="End of input reached before message was fully decoded";return-1}if(t===i){i+=255;const t=new Uint8Array(i);for(let i=0;i<e.length;i++)t[i]=e[i];e=this.valueHexView=new Uint8Array(i)}}this.blockLength=t+1;e[t-1]=s[t]&127;const r=new Uint8Array(t);for(let i=0;i<t;i++)r[i]=e[i];e=this.valueHexView=new Uint8Array(t);e.set(r);if(this.blockLength<=9)this.tagNumber=a(e,7);else{this.isHexOnly=true;this.warnings.push("Tag too long, represented as hex-coded")}}if(this.tagClass===1&&this.isConstructed){switch(this.tagNumber){case 1:case 2:case 5:case 6:case 9:case 13:case 14:case 23:case 24:case 31:case 32:case 33:case 34:this.error="Constructed encoding used for primitive type";return-1}}return e+this.blockLength}toJSON(){return{...super.toJSON(),tagClass:this.tagClass,tagNumber:this.tagNumber,isConstructed:this.isConstructed}}}U.NAME="identificationBlock";class _ extends H{constructor({lenBlock:t={}}={}){var e,i,r;super();this.isIndefiniteForm=(e=t.isIndefiniteForm)!==null&&e!==void 0?e:false;this.longFormUsed=(i=t.longFormUsed)!==null&&i!==void 0?i:false;this.length=(r=t.length)!==null&&r!==void 0?r:0}fromBER(t,e,i){const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}const s=r.subarray(e,e+i);if(s.length===0){this.error="Zero buffer length";return-1}if(s[0]===255){this.error="Length block 0xFF is reserved by standard";return-1}this.isIndefiniteForm=s[0]===128;if(this.isIndefiniteForm){this.blockLength=1;return e+this.blockLength}this.longFormUsed=!!(s[0]&128);if(this.longFormUsed===false){this.length=s[0];this.blockLength=1;return e+this.blockLength}const o=s[0]&127;if(o>8){this.error="Too big integer";return-1}if(o+1>s.length){this.error="End of input reached before message was fully decoded";return-1}const c=e+1;const u=r.subarray(c,c+o);if(u[o-1]===0)this.warnings.push("Needlessly long encoded length");this.length=a(u,8);if(this.longFormUsed&&this.length<=127)this.warnings.push("Unnecessary usage of long length form");this.blockLength=o+1;return e+this.blockLength}toBER(t=false){let e;let i;if(this.length>127)this.longFormUsed=true;if(this.isIndefiniteForm){e=new ArrayBuffer(1);if(t===false){i=new Uint8Array(e);i[0]=128}return e}if(this.longFormUsed){const r=c(this.length,8);if(r.byteLength>127){this.error="Too big length";return O}e=new ArrayBuffer(r.byteLength+1);if(t)return e;const s=new Uint8Array(r);i=new Uint8Array(e);i[0]=r.byteLength|128;for(let t=0;t<r.byteLength;t++)i[t+1]=s[t];return e}e=new ArrayBuffer(1);if(t===false){i=new Uint8Array(e);i[0]=this.length}return e}toJSON(){return{...super.toJSON(),isIndefiniteForm:this.isIndefiniteForm,longFormUsed:this.longFormUsed,length:this.length}}}_.NAME="lengthBlock";const F={};class V extends H{constructor({name:t=T,optional:e=false,primitiveSchema:i,...r}={},s){super(r);this.name=t;this.optional=e;if(i){this.primitiveSchema=i}this.idBlock=new U(r);this.lenBlock=new _(r);this.valueBlock=s?new s(r):new j(r)}fromBER(t,e,i){const r=this.valueBlock.fromBER(t,e,this.lenBlock.isIndefiniteForm?i:this.lenBlock.length);if(r===-1){this.error=this.valueBlock.error;return r}if(!this.idBlock.error.length)this.blockLength+=this.idBlock.blockLength;if(!this.lenBlock.error.length)this.blockLength+=this.lenBlock.blockLength;if(!this.valueBlock.error.length)this.blockLength+=this.valueBlock.blockLength;return r}toBER(t,e){const i=e||new A;if(!e){L(this)}const r=this.idBlock.toBER(t);i.write(r);if(this.lenBlock.isIndefiniteForm){i.write(new Uint8Array([128]).buffer);this.valueBlock.toBER(t,i);i.write(new ArrayBuffer(2))}else{const e=this.valueBlock.toBER(t);this.lenBlock.length=e.byteLength;const r=this.lenBlock.toBER(t);i.write(r);i.write(e)}if(!e){return i.final()}return O}toJSON(){const t={...super.toJSON(),idBlock:this.idBlock.toJSON(),lenBlock:this.lenBlock.toJSON(),valueBlock:this.valueBlock.toJSON(),name:this.name,optional:this.optional};if(this.primitiveSchema)t.primitiveSchema=this.primitiveSchema.toJSON();return t}toString(t="ascii"){if(t==="ascii"){return this.onAsciiEncoding()}return n.Convert.ToHex(this.toBER())}onAsciiEncoding(){return`${this.constructor.NAME} : ${n.Convert.ToHex(this.valueBlock.valueBeforeDecodeView)}`}isEqual(t){if(this===t){return true}if(!(t instanceof this.constructor)){return false}const e=this.toBER();const i=t.toBER();return h(e,i)}}V.NAME="BaseBlock";function L(t){if(t instanceof F.Constructed){for(const e of t.valueBlock.value){if(L(e)){t.lenBlock.isIndefiniteForm=true}}}return!!t.lenBlock.isIndefiniteForm}class $ extends V{constructor({value:t=T,...e}={},i){super(e,i);if(t){this.fromString(t)}}getValue(){return this.valueBlock.value}setValue(t){this.valueBlock.value=t}fromBER(t,e,i){const r=this.valueBlock.fromBER(t,e,this.lenBlock.isIndefiniteForm?i:this.lenBlock.length);if(r===-1){this.error=this.valueBlock.error;return r}this.fromBuffer(this.valueBlock.valueHexView);if(!this.idBlock.error.length)this.blockLength+=this.idBlock.blockLength;if(!this.lenBlock.error.length)this.blockLength+=this.lenBlock.blockLength;if(!this.valueBlock.error.length)this.blockLength+=this.valueBlock.blockLength;return r}onAsciiEncoding(){return`${this.constructor.NAME} : '${this.valueBlock.value}'`}}$.NAME="BaseStringBlock";class G extends(K(j)){constructor({isHexOnly:t=true,...e}={}){super(e);this.isHexOnly=t}}G.NAME="PrimitiveValueBlock";var W;class Q extends V{constructor(t={}){super(t,G);this.idBlock.isConstructed=false}}W=Q;(()=>{F.Primitive=W})();Q.NAME="PRIMITIVE";function q(t,e){if(t instanceof e){return t}const i=new e;i.idBlock=t.idBlock;i.lenBlock=t.lenBlock;i.warnings=t.warnings;i.valueBeforeDecodeView=t.valueBeforeDecodeView;return i}function z(t,e=0,i=t.length){const r=e;let s=new V({},j);const n=new H;if(!S(n,t,e,i)){s.error=n.error;return{offset:-1,result:s}}const o=t.subarray(e,e+i);if(!o.length){s.error="Zero buffer length";return{offset:-1,result:s}}let a=s.idBlock.fromBER(t,e,i);if(s.idBlock.warnings.length){s.warnings.concat(s.idBlock.warnings)}if(a===-1){s.error=s.idBlock.error;return{offset:-1,result:s}}e=a;i-=s.idBlock.blockLength;a=s.lenBlock.fromBER(t,e,i);if(s.lenBlock.warnings.length){s.warnings.concat(s.lenBlock.warnings)}if(a===-1){s.error=s.lenBlock.error;return{offset:-1,result:s}}e=a;i-=s.lenBlock.blockLength;if(!s.idBlock.isConstructed&&s.lenBlock.isIndefiniteForm){s.error="Indefinite length form used for primitive encoding form";return{offset:-1,result:s}}let c=V;switch(s.idBlock.tagClass){case 1:if(s.idBlock.tagNumber>=37&&s.idBlock.isHexOnly===false){s.error="UNIVERSAL 37 and upper tags are reserved by ASN.1 standard";return{offset:-1,result:s}}switch(s.idBlock.tagNumber){case 0:if(s.idBlock.isConstructed&&s.lenBlock.length>0){s.error="Type [UNIVERSAL 0] is reserved";return{offset:-1,result:s}}c=F.EndOfContent;break;case 1:c=F.Boolean;break;case 2:c=F.Integer;break;case 3:c=F.BitString;break;case 4:c=F.OctetString;break;case 5:c=F.Null;break;case 6:c=F.ObjectIdentifier;break;case 10:c=F.Enumerated;break;case 12:c=F.Utf8String;break;case 13:c=F.RelativeObjectIdentifier;break;case 14:c=F.TIME;break;case 15:s.error="[UNIVERSAL 15] is reserved by ASN.1 standard";return{offset:-1,result:s};case 16:c=F.Sequence;break;case 17:c=F.Set;break;case 18:c=F.NumericString;break;case 19:c=F.PrintableString;break;case 20:c=F.TeletexString;break;case 21:c=F.VideotexString;break;case 22:c=F.IA5String;break;case 23:c=F.UTCTime;break;case 24:c=F.GeneralizedTime;break;case 25:c=F.GraphicString;break;case 26:c=F.VisibleString;break;case 27:c=F.GeneralString;break;case 28:c=F.UniversalString;break;case 29:c=F.CharacterString;break;case 30:c=F.BmpString;break;case 31:c=F.DATE;break;case 32:c=F.TimeOfDay;break;case 33:c=F.DateTime;break;case 34:c=F.Duration;break;default:{const t=s.idBlock.isConstructed?new F.Constructed:new F.Primitive;t.idBlock=s.idBlock;t.lenBlock=s.lenBlock;t.warnings=s.warnings;s=t}}break;case 2:case 3:case 4:default:{c=s.idBlock.isConstructed?F.Constructed:F.Primitive}}s=q(s,c);a=s.fromBER(t,e,s.lenBlock.isIndefiniteForm?i:s.lenBlock.length);s.valueBeforeDecodeView=t.subarray(r,r+s.blockLength);return{offset:a,result:s}}function J(t){if(!t.byteLength){const t=new V({},j);t.error="Input buffer has zero length";return{offset:-1,result:t}}return z(n.BufferSourceConverter.toUint8Array(t).slice(),0,t.byteLength)}function Z(t,e){if(t){return 1}return e}class X extends j{constructor({value:t=[],isIndefiniteForm:e=false,...i}={}){super(i);this.value=t;this.isIndefiniteForm=e}fromBER(t,e,i){const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}this.valueBeforeDecodeView=r.subarray(e,e+i);if(this.valueBeforeDecodeView.length===0){this.warnings.push("Zero buffer length");return e}let s=e;while(Z(this.isIndefiniteForm,i)>0){const t=z(r,s,i);if(t.offset===-1){this.error=t.result.error;this.warnings.concat(t.result.warnings);return-1}s=t.offset;this.blockLength+=t.result.blockLength;i-=t.result.blockLength;this.value.push(t.result);if(this.isIndefiniteForm&&t.result.constructor.NAME===M){break}}if(this.isIndefiniteForm){if(this.value[this.value.length-1].constructor.NAME===M){this.value.pop()}else{this.warnings.push("No EndOfContent block encoded")}}return s}toBER(t,e){const i=e||new A;for(let e=0;e<this.value.length;e++){this.value[e].toBER(t,i)}if(!e){return i.final()}return O}toJSON(){const t={...super.toJSON(),isIndefiniteForm:this.isIndefiniteForm,value:[]};for(const e of this.value){t.value.push(e.toJSON())}return t}}X.NAME="ConstructedValueBlock";var Y;class tt extends V{constructor(t={}){super(t,X);this.idBlock.isConstructed=true}fromBER(t,e,i){this.valueBlock.isIndefiniteForm=this.lenBlock.isIndefiniteForm;const r=this.valueBlock.fromBER(t,e,this.lenBlock.isIndefiniteForm?i:this.lenBlock.length);if(r===-1){this.error=this.valueBlock.error;return r}if(!this.idBlock.error.length)this.blockLength+=this.idBlock.blockLength;if(!this.lenBlock.error.length)this.blockLength+=this.lenBlock.blockLength;if(!this.valueBlock.error.length)this.blockLength+=this.valueBlock.blockLength;return r}onAsciiEncoding(){const t=[];for(const e of this.valueBlock.value){t.push(e.toString("ascii").split("\n").map((t=>` ${t}`)).join("\n"))}const e=this.idBlock.tagClass===3?`[${this.idBlock.tagNumber}]`:this.constructor.NAME;return t.length?`${e} :\n${t.join("\n")}`:`${e} :`}}Y=tt;(()=>{F.Constructed=Y})();tt.NAME="CONSTRUCTED";class et extends j{fromBER(t,e,i){return e}toBER(t){return O}}et.override="EndOfContentValueBlock";var it;class rt extends V{constructor(t={}){super(t,et);this.idBlock.tagClass=1;this.idBlock.tagNumber=0}}it=rt;(()=>{F.EndOfContent=it})();rt.NAME=M;var st;class nt extends V{constructor(t={}){super(t,j);this.idBlock.tagClass=1;this.idBlock.tagNumber=5}fromBER(t,e,i){if(this.lenBlock.length>0)this.warnings.push("Non-zero length of value block for Null type");if(!this.idBlock.error.length)this.blockLength+=this.idBlock.blockLength;if(!this.lenBlock.error.length)this.blockLength+=this.lenBlock.blockLength;this.blockLength+=i;if(e+i>t.byteLength){this.error="End of input reached before message was fully decoded (inconsistent offset and length values)";return-1}return e+i}toBER(t,e){const i=new ArrayBuffer(2);if(!t){const t=new Uint8Array(i);t[0]=5;t[1]=0}if(e){e.write(i)}return i}onAsciiEncoding(){return`${this.constructor.NAME}`}}st=nt;(()=>{F.Null=st})();nt.NAME="NULL";class ot extends(K(j)){constructor({value:t,...e}={}){super(e);if(e.valueHex){this.valueHexView=n.BufferSourceConverter.toUint8Array(e.valueHex)}else{this.valueHexView=new Uint8Array(1)}if(t){this.value=t}}get value(){for(const t of this.valueHexView){if(t>0){return true}}return false}set value(t){this.valueHexView[0]=t?255:0}fromBER(t,e,i){const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}this.valueHexView=r.subarray(e,e+i);if(i>1)this.warnings.push("Boolean value encoded in more then 1 octet");this.isHexOnly=true;l.call(this);this.blockLength=i;return e+i}toBER(){return this.valueHexView.slice()}toJSON(){return{...super.toJSON(),value:this.value}}}ot.NAME="BooleanValueBlock";var at;class ct extends V{constructor(t={}){super(t,ot);this.idBlock.tagClass=1;this.idBlock.tagNumber=1}getValue(){return this.valueBlock.value}setValue(t){this.valueBlock.value=t}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.getValue}`}}at=ct;(()=>{F.Boolean=at})();ct.NAME="BOOLEAN";class ut extends(K(X)){constructor({isConstructed:t=false,...e}={}){super(e);this.isConstructed=t}fromBER(t,e,i){let r=0;if(this.isConstructed){this.isHexOnly=false;r=X.prototype.fromBER.call(this,t,e,i);if(r===-1)return r;for(let t=0;t<this.value.length;t++){const e=this.value[t].constructor.NAME;if(e===M){if(this.isIndefiniteForm)break;else{this.error="EndOfContent is unexpected, OCTET STRING may consists of OCTET STRINGs only";return-1}}if(e!==N){this.error="OCTET STRING may consists of OCTET STRINGs only";return-1}}}else{this.isHexOnly=true;r=super.fromBER(t,e,i);this.blockLength=i}return r}toBER(t,e){if(this.isConstructed)return X.prototype.toBER.call(this,t,e);return t?new ArrayBuffer(this.valueHexView.byteLength):this.valueHexView.slice().buffer}toJSON(){return{...super.toJSON(),isConstructed:this.isConstructed}}}ut.NAME="OctetStringValueBlock";var lt;let pt=class t extends V{constructor({idBlock:t={},lenBlock:e={},...i}={}){var r,s;(r=i.isConstructed)!==null&&r!==void 0?r:i.isConstructed=!!((s=i.value)===null||s===void 0?void 0:s.length);super({idBlock:{isConstructed:i.isConstructed,...t},lenBlock:{...e,isIndefiniteForm:!!i.isIndefiniteForm},...i},ut);this.idBlock.tagClass=1;this.idBlock.tagNumber=4}fromBER(t,e,i){this.valueBlock.isConstructed=this.idBlock.isConstructed;this.valueBlock.isIndefiniteForm=this.lenBlock.isIndefiniteForm;if(i===0){if(this.idBlock.error.length===0)this.blockLength+=this.idBlock.blockLength;if(this.lenBlock.error.length===0)this.blockLength+=this.lenBlock.blockLength;return e}if(!this.valueBlock.isConstructed){const r=t instanceof ArrayBuffer?new Uint8Array(t):t;const s=r.subarray(e,e+i);try{if(s.byteLength){const t=z(s,0,s.byteLength);if(t.offset!==-1&&t.offset===i){this.valueBlock.value=[t.result]}}}catch(t){}}return super.fromBER(t,e,i)}onAsciiEncoding(){if(this.valueBlock.isConstructed||this.valueBlock.value&&this.valueBlock.value.length){return tt.prototype.onAsciiEncoding.call(this)}return`${this.constructor.NAME} : ${n.Convert.ToHex(this.valueBlock.valueHexView)}`}getValue(){if(!this.idBlock.isConstructed){return this.valueBlock.valueHexView.slice().buffer}const e=[];for(const i of this.valueBlock.value){if(i instanceof t){e.push(i.valueBlock.valueHexView)}}return n.BufferSourceConverter.concat(e)}};lt=pt;(()=>{F.OctetString=lt})();pt.NAME=N;class ht extends(K(X)){constructor({unusedBits:t=0,isConstructed:e=false,...i}={}){super(i);this.unusedBits=t;this.isConstructed=e;this.blockLength=this.valueHexView.byteLength}fromBER(t,e,i){if(!i){return e}let r=-1;if(this.isConstructed){r=X.prototype.fromBER.call(this,t,e,i);if(r===-1)return r;for(const t of this.value){const e=t.constructor.NAME;if(e===M){if(this.isIndefiniteForm)break;else{this.error="EndOfContent is unexpected, BIT STRING may consists of BIT STRINGs only";return-1}}if(e!==k){this.error="BIT STRING may consists of BIT STRINGs only";return-1}const i=t.valueBlock;if(this.unusedBits>0&&i.unusedBits>0){this.error='Using of "unused bits" inside constructive BIT STRING allowed for least one only';return-1}this.unusedBits=i.unusedBits}return r}const s=n.BufferSourceConverter.toUint8Array(t);if(!S(this,s,e,i)){return-1}const o=s.subarray(e,e+i);this.unusedBits=o[0];if(this.unusedBits>7){this.error="Unused bits for BitString must be in range 0-7";return-1}if(!this.unusedBits){const t=o.subarray(1);try{if(t.byteLength){const e=z(t,0,t.byteLength);if(e.offset!==-1&&e.offset===i-1){this.value=[e.result]}}}catch(t){}}this.valueHexView=o.subarray(1);this.blockLength=o.length;return e+i}toBER(t,e){if(this.isConstructed){return X.prototype.toBER.call(this,t,e)}if(t){return new ArrayBuffer(this.valueHexView.byteLength+1)}if(!this.valueHexView.byteLength){return O}const i=new Uint8Array(this.valueHexView.length+1);i[0]=this.unusedBits;i.set(this.valueHexView,1);return i.buffer}toJSON(){return{...super.toJSON(),unusedBits:this.unusedBits,isConstructed:this.isConstructed}}}ht.NAME="BitStringValueBlock";var dt;let ft=class t extends V{constructor({idBlock:t={},lenBlock:e={},...i}={}){var r,s;(r=i.isConstructed)!==null&&r!==void 0?r:i.isConstructed=!!((s=i.value)===null||s===void 0?void 0:s.length);super({idBlock:{isConstructed:i.isConstructed,...t},lenBlock:{...e,isIndefiniteForm:!!i.isIndefiniteForm},...i},ht);this.idBlock.tagClass=1;this.idBlock.tagNumber=3}fromBER(t,e,i){this.valueBlock.isConstructed=this.idBlock.isConstructed;this.valueBlock.isIndefiniteForm=this.lenBlock.isIndefiniteForm;return super.fromBER(t,e,i)}onAsciiEncoding(){if(this.valueBlock.isConstructed||this.valueBlock.value&&this.valueBlock.value.length){return tt.prototype.onAsciiEncoding.call(this)}else{const t=[];const e=this.valueBlock.valueHexView;for(const i of e){t.push(i.toString(2).padStart(8,"0"))}const i=t.join("");return`${this.constructor.NAME} : ${i.substring(0,i.length-this.valueBlock.unusedBits)}`}}};dt=ft;(()=>{F.BitString=dt})();ft.NAME=k;var yt;function St(t,e){const i=new Uint8Array([0]);const r=new Uint8Array(t);const s=new Uint8Array(e);let n=r.slice(0);const o=n.length-1;const a=s.slice(0);const c=a.length-1;let l=0;const p=c<o?o:c;let h=0;for(let t=p;t>=0;t--,h++){switch(true){case h<a.length:l=n[o-h]+a[c-h]+i[0];break;default:l=n[o-h]+i[0]}i[0]=l/10;switch(true){case h>=n.length:n=u(new Uint8Array([l%10]),n);break;default:n[o-h]=l%10}}if(i[0]>0)n=u(i,n);return n}function At(t){if(t>=C.length){for(let e=C.length;e<=t;e++){const t=new Uint8Array([0]);let i=C[e-1].slice(0);for(let e=i.length-1;e>=0;e--){const r=new Uint8Array([(i[e]<<1)+t[0]]);t[0]=r[0]/10;i[e]=r[0]%10}if(t[0]>0)i=u(t,i);C.push(i)}}return C[t]}function Ct(t,e){let i=0;const r=new Uint8Array(t);const s=new Uint8Array(e);const n=r.slice(0);const o=n.length-1;const a=s.slice(0);const c=a.length-1;let u;let l=0;for(let t=c;t>=0;t--,l++){u=n[o-l]-a[c-l]-i;switch(true){case u<0:i=1;n[o-l]=u+10;break;default:i=0;n[o-l]=u}}if(i>0){for(let t=o-c+1;t>=0;t--,l++){u=n[o-l]-i;if(u<0){i=1;n[o-l]=u+10}else{i=0;n[o-l]=u;break}}}return n.slice()}class vt extends(K(j)){constructor({value:t,...e}={}){super(e);this._valueDec=0;if(e.valueHex){this.setValueHex()}if(t!==undefined){this.valueDec=t}}setValueHex(){if(this.valueHexView.length>=4){this.warnings.push("Too big Integer for decoding, hex only");this.isHexOnly=true;this._valueDec=0}else{this.isHexOnly=false;if(this.valueHexView.length>0){this._valueDec=l.call(this)}}}set valueDec(t){this._valueDec=t;this.isHexOnly=false;this.valueHexView=new Uint8Array(p(t))}get valueDec(){return this._valueDec}fromDER(t,e,i,r=0){const s=this.fromBER(t,e,i);if(s===-1)return s;const n=this.valueHexView;if(n[0]===0&&(n[1]&128)!==0){this.valueHexView=n.subarray(1)}else{if(r!==0){if(n.length<r){if(r-n.length>1)r=n.length+1;this.valueHexView=n.subarray(r-n.length)}}}return s}toDER(t=false){const e=this.valueHexView;switch(true){case(e[0]&128)!==0:{const t=new Uint8Array(this.valueHexView.length+1);t[0]=0;t.set(e,1);this.valueHexView=t}break;case e[0]===0&&(e[1]&128)===0:{this.valueHexView=this.valueHexView.subarray(1)}break}return this.toBER(t)}fromBER(t,e,i){const r=super.fromBER(t,e,i);if(r===-1){return r}this.setValueHex();return r}toBER(t){return t?new ArrayBuffer(this.valueHexView.length):this.valueHexView.slice().buffer}toJSON(){return{...super.toJSON(),valueDec:this.valueDec}}toString(){const t=this.valueHexView.length*8-1;let e=new Uint8Array(this.valueHexView.length*8/3);let i=0;let r;const s=this.valueHexView;let n="";let o=false;for(let o=s.byteLength-1;o>=0;o--){r=s[o];for(let s=0;s<8;s++){if((r&1)===1){switch(i){case t:e=Ct(At(i),e);n="-";break;default:e=St(e,At(i))}}i++;r>>=1}}for(let t=0;t<e.length;t++){if(e[t])o=true;if(o)n+=v.charAt(e[t])}if(o===false)n+=v.charAt(0);return n}}yt=vt;vt.NAME="IntegerValueBlock";(()=>{Object.defineProperty(yt.prototype,"valueHex",{set:function(t){this.valueHexView=new Uint8Array(t);this.setValueHex()},get:function(){return this.valueHexView.slice().buffer}})})();var mt;class gt extends V{constructor(t={}){super(t,vt);this.idBlock.tagClass=1;this.idBlock.tagNumber=2}toBigInt(){f();return BigInt(this.valueBlock.toString())}static fromBigInt(t){f();const e=BigInt(t);const i=new A;const r=e.toString(16).replace(/^-/,"");const s=new Uint8Array(n.Convert.FromHex(r));if(e<0){const t=new Uint8Array(s.length+(s[0]&128?1:0));t[0]|=128;const r=BigInt(`0x${n.Convert.ToHex(t)}`);const o=r+e;const a=n.BufferSourceConverter.toUint8Array(n.Convert.FromHex(o.toString(16)));a[0]|=128;i.write(a)}else{if(s[0]&128){i.write(new Uint8Array([0]))}i.write(s)}const o=new gt({valueHex:i.final()});return o}convertToDER(){const t=new gt({valueHex:this.valueBlock.valueHexView});t.valueBlock.toDER();return t}convertFromDER(){return new gt({valueHex:this.valueBlock.valueHexView[0]===0?this.valueBlock.valueHexView.subarray(1):this.valueBlock.valueHexView})}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.valueBlock.toString()}`}}mt=gt;(()=>{F.Integer=mt})();gt.NAME="INTEGER";var wt;class Et extends gt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=10}}wt=Et;(()=>{F.Enumerated=wt})();Et.NAME="ENUMERATED";class Pt extends(K(j)){constructor({valueDec:t=-1,isFirstSid:e=false,...i}={}){super(i);this.valueDec=t;this.isFirstSid=e}fromBER(t,e,i){if(!i){return e}const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}const s=r.subarray(e,e+i);this.valueHexView=new Uint8Array(i);for(let t=0;t<i;t++){this.valueHexView[t]=s[t]&127;this.blockLength++;if((s[t]&128)===0)break}const o=new Uint8Array(this.blockLength);for(let t=0;t<this.blockLength;t++){o[t]=this.valueHexView[t]}this.valueHexView=o;if((s[this.blockLength-1]&128)!==0){this.error="End of input reached before message was fully decoded";return-1}if(this.valueHexView[0]===0)this.warnings.push("Needlessly long format of SID encoding");if(this.blockLength<=8)this.valueDec=a(this.valueHexView,7);else{this.isHexOnly=true;this.warnings.push("Too big SID for decoding, hex only")}return e+this.blockLength}set valueBigInt(t){f();let e=BigInt(t).toString(2);while(e.length%7){e="0"+e}const i=new Uint8Array(e.length/7);for(let t=0;t<i.length;t++){i[t]=parseInt(e.slice(t*7,t*7+7),2)+(t+1<i.length?128:0)}this.fromBER(i.buffer,0,i.length)}toBER(t){if(this.isHexOnly){if(t)return new ArrayBuffer(this.valueHexView.byteLength);const e=this.valueHexView;const i=new Uint8Array(this.blockLength);for(let t=0;t<this.blockLength-1;t++)i[t]=e[t]|128;i[this.blockLength-1]=e[this.blockLength-1];return i.buffer}const e=c(this.valueDec,7);if(e.byteLength===0){this.error="Error during encoding SID value";return O}const i=new Uint8Array(e.byteLength);if(!t){const t=new Uint8Array(e);const r=e.byteLength-1;for(let e=0;e<r;e++)i[e]=t[e]|128;i[r]=t[r]}return i}toString(){let t="";if(this.isHexOnly)t=n.Convert.ToHex(this.valueHexView);else{if(this.isFirstSid){let e=this.valueDec;if(this.valueDec<=39)t="0.";else{if(this.valueDec<=79){t="1.";e-=40}else{t="2.";e-=80}}t+=e.toString()}else t=this.valueDec.toString()}return t}toJSON(){return{...super.toJSON(),valueDec:this.valueDec,isFirstSid:this.isFirstSid}}}Pt.NAME="sidBlock";class Dt extends j{constructor({value:t=T,...e}={}){super(e);this.value=[];if(t){this.fromString(t)}}fromBER(t,e,i){let r=e;while(i>0){const e=new Pt;r=e.fromBER(t,r,i);if(r===-1){this.blockLength=0;this.error=e.error;return r}if(this.value.length===0)e.isFirstSid=true;this.blockLength+=e.blockLength;i-=e.blockLength;this.value.push(e)}return r}toBER(t){const e=[];for(let i=0;i<this.value.length;i++){const r=this.value[i].toBER(t);if(r.byteLength===0){this.error=this.value[i].error;return O}e.push(r)}return y(e)}fromString(t){this.value=[];let e=0;let i=0;let r="";let s=false;do{i=t.indexOf(".",e);if(i===-1)r=t.substring(e);else r=t.substring(e,i);e=i+1;if(s){const t=this.value[0];let e=0;switch(t.valueDec){case 0:break;case 1:e=40;break;case 2:e=80;break;default:this.value=[];return}const i=parseInt(r,10);if(isNaN(i))return;t.valueDec=i+e;s=false}else{const t=new Pt;if(r>Number.MAX_SAFE_INTEGER){f();const e=BigInt(r);t.valueBigInt=e}else{t.valueDec=parseInt(r,10);if(isNaN(t.valueDec))return}if(!this.value.length){t.isFirstSid=true;s=true}this.value.push(t)}}while(i!==-1)}toString(){let t="";let e=false;for(let i=0;i<this.value.length;i++){e=this.value[i].isHexOnly;let r=this.value[i].toString();if(i!==0)t=`${t}.`;if(e){r=`{${r}}`;if(this.value[i].isFirstSid)t=`2.{${r} - 80}`;else t+=r}else t+=r}return t}toJSON(){const t={...super.toJSON(),value:this.toString(),sidArray:[]};for(let e=0;e<this.value.length;e++){t.sidArray.push(this.value[e].toJSON())}return t}}Dt.NAME="ObjectIdentifierValueBlock";var bt;class Bt extends V{constructor(t={}){super(t,Dt);this.idBlock.tagClass=1;this.idBlock.tagNumber=6}getValue(){return this.valueBlock.toString()}setValue(t){this.valueBlock.fromString(t)}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.valueBlock.toString()||"empty"}`}toJSON(){return{...super.toJSON(),value:this.getValue()}}}bt=Bt;(()=>{F.ObjectIdentifier=bt})();Bt.NAME="OBJECT IDENTIFIER";class It extends(K(H)){constructor({valueDec:t=0,...e}={}){super(e);this.valueDec=t}fromBER(t,e,i){if(i===0)return e;const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i))return-1;const s=r.subarray(e,e+i);this.valueHexView=new Uint8Array(i);for(let t=0;t<i;t++){this.valueHexView[t]=s[t]&127;this.blockLength++;if((s[t]&128)===0)break}const o=new Uint8Array(this.blockLength);for(let t=0;t<this.blockLength;t++)o[t]=this.valueHexView[t];this.valueHexView=o;if((s[this.blockLength-1]&128)!==0){this.error="End of input reached before message was fully decoded";return-1}if(this.valueHexView[0]===0)this.warnings.push("Needlessly long format of SID encoding");if(this.blockLength<=8)this.valueDec=a(this.valueHexView,7);else{this.isHexOnly=true;this.warnings.push("Too big SID for decoding, hex only")}return e+this.blockLength}toBER(t){if(this.isHexOnly){if(t)return new ArrayBuffer(this.valueHexView.byteLength);const e=this.valueHexView;const i=new Uint8Array(this.blockLength);for(let t=0;t<this.blockLength-1;t++)i[t]=e[t]|128;i[this.blockLength-1]=e[this.blockLength-1];return i.buffer}const e=c(this.valueDec,7);if(e.byteLength===0){this.error="Error during encoding SID value";return O}const i=new Uint8Array(e.byteLength);if(!t){const t=new Uint8Array(e);const r=e.byteLength-1;for(let e=0;e<r;e++)i[e]=t[e]|128;i[r]=t[r]}return i.buffer}toString(){let t="";if(this.isHexOnly)t=n.Convert.ToHex(this.valueHexView);else{t=this.valueDec.toString()}return t}toJSON(){return{...super.toJSON(),valueDec:this.valueDec}}}It.NAME="relativeSidBlock";class xt extends j{constructor({value:t=T,...e}={}){super(e);this.value=[];if(t){this.fromString(t)}}fromBER(t,e,i){let r=e;while(i>0){const e=new It;r=e.fromBER(t,r,i);if(r===-1){this.blockLength=0;this.error=e.error;return r}this.blockLength+=e.blockLength;i-=e.blockLength;this.value.push(e)}return r}toBER(t,e){const i=[];for(let e=0;e<this.value.length;e++){const r=this.value[e].toBER(t);if(r.byteLength===0){this.error=this.value[e].error;return O}i.push(r)}return y(i)}fromString(t){this.value=[];let e=0;let i=0;let r="";do{i=t.indexOf(".",e);if(i===-1)r=t.substring(e);else r=t.substring(e,i);e=i+1;const s=new It;s.valueDec=parseInt(r,10);if(isNaN(s.valueDec))return true;this.value.push(s)}while(i!==-1);return true}toString(){let t="";let e=false;for(let i=0;i<this.value.length;i++){e=this.value[i].isHexOnly;let r=this.value[i].toString();if(i!==0)t=`${t}.`;if(e){r=`{${r}}`;t+=r}else t+=r}return t}toJSON(){const t={...super.toJSON(),value:this.toString(),sidArray:[]};for(let e=0;e<this.value.length;e++)t.sidArray.push(this.value[e].toJSON());return t}}xt.NAME="RelativeObjectIdentifierValueBlock";var Tt;class Ot extends V{constructor(t={}){super(t,xt);this.idBlock.tagClass=1;this.idBlock.tagNumber=13}getValue(){return this.valueBlock.toString()}setValue(t){this.valueBlock.fromString(t)}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.valueBlock.toString()||"empty"}`}toJSON(){return{...super.toJSON(),value:this.getValue()}}}Tt=Ot;(()=>{F.RelativeObjectIdentifier=Tt})();Ot.NAME="RelativeObjectIdentifier";var Rt;class Mt extends tt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=16}}Rt=Mt;(()=>{F.Sequence=Rt})();Mt.NAME="SEQUENCE";var Nt;class kt extends tt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=17}}Nt=kt;(()=>{F.Set=Nt})();kt.NAME="SET";class Kt extends(K(j)){constructor({...t}={}){super(t);this.isHexOnly=true;this.value=T}toJSON(){return{...super.toJSON(),value:this.value}}}Kt.NAME="StringValueBlock";class Ht extends Kt{}Ht.NAME="SimpleStringValueBlock";class jt extends ${constructor({...t}={}){super(t,Ht)}fromBuffer(t){this.valueBlock.value=String.fromCharCode.apply(null,n.BufferSourceConverter.toUint8Array(t))}fromString(t){const e=t.length;const i=this.valueBlock.valueHexView=new Uint8Array(e);for(let r=0;r<e;r++)i[r]=t.charCodeAt(r);this.valueBlock.value=t}}jt.NAME="SIMPLE STRING";class Ut extends jt{fromBuffer(t){this.valueBlock.valueHexView=n.BufferSourceConverter.toUint8Array(t);try{this.valueBlock.value=n.Convert.ToUtf8String(t)}catch(e){this.warnings.push(`Error during "decodeURIComponent": ${e}, using raw string`);this.valueBlock.value=n.Convert.ToBinary(t)}}fromString(t){this.valueBlock.valueHexView=new Uint8Array(n.Convert.FromUtf8String(t));this.valueBlock.value=t}}Ut.NAME="Utf8StringValueBlock";var _t;class Ft extends Ut{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=12}}_t=Ft;(()=>{F.Utf8String=_t})();Ft.NAME="UTF8String";class Vt extends jt{fromBuffer(t){this.valueBlock.value=n.Convert.ToUtf16String(t);this.valueBlock.valueHexView=n.BufferSourceConverter.toUint8Array(t)}fromString(t){this.valueBlock.value=t;this.valueBlock.valueHexView=new Uint8Array(n.Convert.FromUtf16String(t))}}Vt.NAME="BmpStringValueBlock";var Lt;class $t extends Vt{constructor({...t}={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=30}}Lt=$t;(()=>{F.BmpString=Lt})();$t.NAME="BMPString";class Gt extends jt{fromBuffer(t){const e=ArrayBuffer.isView(t)?t.slice().buffer:t.slice(0);const i=new Uint8Array(e);for(let t=0;t<i.length;t+=4){i[t]=i[t+3];i[t+1]=i[t+2];i[t+2]=0;i[t+3]=0}this.valueBlock.value=String.fromCharCode.apply(null,new Uint32Array(e))}fromString(t){const e=t.length;const i=this.valueBlock.valueHexView=new Uint8Array(e*4);for(let r=0;r<e;r++){const e=c(t.charCodeAt(r),8);const s=new Uint8Array(e);if(s.length>4)continue;const n=4-s.length;for(let t=s.length-1;t>=0;t--)i[r*4+t+n]=s[t]}this.valueBlock.value=t}}Gt.NAME="UniversalStringValueBlock";var Wt;class Qt extends Gt{constructor({...t}={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=28}}Wt=Qt;(()=>{F.UniversalString=Wt})();Qt.NAME="UniversalString";var qt;class zt extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=18}}qt=zt;(()=>{F.NumericString=qt})();zt.NAME="NumericString";var Jt;class Zt extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=19}}Jt=Zt;(()=>{F.PrintableString=Jt})();Zt.NAME="PrintableString";var Xt;class Yt extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=20}}Xt=Yt;(()=>{F.TeletexString=Xt})();Yt.NAME="TeletexString";var te;class ee extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=21}}te=ee;(()=>{F.VideotexString=te})();ee.NAME="VideotexString";var ie;class re extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=22}}ie=re;(()=>{F.IA5String=ie})();re.NAME="IA5String";var se;class ne extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=25}}se=ne;(()=>{F.GraphicString=se})();ne.NAME="GraphicString";var oe;class ae extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=26}}oe=ae;(()=>{F.VisibleString=oe})();ae.NAME="VisibleString";var ce;class ue extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=27}}ce=ue;(()=>{F.GeneralString=ce})();ue.NAME="GeneralString";var le;class pe extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=29}}le=pe;(()=>{F.CharacterString=le})();pe.NAME="CharacterString";var he;class de extends ae{constructor({value:t,valueDate:e,...i}={}){super(i);this.year=0;this.month=0;this.day=0;this.hour=0;this.minute=0;this.second=0;if(t){this.fromString(t);this.valueBlock.valueHexView=new Uint8Array(t.length);for(let e=0;e<t.length;e++)this.valueBlock.valueHexView[e]=t.charCodeAt(e)}if(e){this.fromDate(e);this.valueBlock.valueHexView=new Uint8Array(this.toBuffer())}this.idBlock.tagClass=1;this.idBlock.tagNumber=23}fromBuffer(t){this.fromString(String.fromCharCode.apply(null,n.BufferSourceConverter.toUint8Array(t)))}toBuffer(){const t=this.toString();const e=new ArrayBuffer(t.length);const i=new Uint8Array(e);for(let e=0;e<t.length;e++)i[e]=t.charCodeAt(e);return e}fromDate(t){this.year=t.getUTCFullYear();this.month=t.getUTCMonth()+1;this.day=t.getUTCDate();this.hour=t.getUTCHours();this.minute=t.getUTCMinutes();this.second=t.getUTCSeconds()}toDate(){return new Date(Date.UTC(this.year,this.month-1,this.day,this.hour,this.minute,this.second))}fromString(t){const e=/(\d{2})(\d{2})(\d{2})(\d{2})(\d{2})(\d{2})Z/gi;const i=e.exec(t);if(i===null){this.error="Wrong input string for conversion";return}const r=parseInt(i[1],10);if(r>=50)this.year=1900+r;else this.year=2e3+r;this.month=parseInt(i[2],10);this.day=parseInt(i[3],10);this.hour=parseInt(i[4],10);this.minute=parseInt(i[5],10);this.second=parseInt(i[6],10)}toString(t="iso"){if(t==="iso"){const t=new Array(7);t[0]=d(this.year<2e3?this.year-1900:this.year-2e3,2);t[1]=d(this.month,2);t[2]=d(this.day,2);t[3]=d(this.hour,2);t[4]=d(this.minute,2);t[5]=d(this.second,2);t[6]="Z";return t.join("")}return super.toString(t)}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.toDate().toISOString()}`}toJSON(){return{...super.toJSON(),year:this.year,month:this.month,day:this.day,hour:this.hour,minute:this.minute,second:this.second}}}he=de;(()=>{F.UTCTime=he})();de.NAME="UTCTime";var fe;class ye extends de{constructor(t={}){var e;super(t);(e=this.millisecond)!==null&&e!==void 0?e:this.millisecond=0;this.idBlock.tagClass=1;this.idBlock.tagNumber=24}fromDate(t){super.fromDate(t);this.millisecond=t.getUTCMilliseconds()}toDate(){return new Date(Date.UTC(this.year,this.month-1,this.day,this.hour,this.minute,this.second,this.millisecond))}fromString(t){let e=false;let i="";let r="";let s=0;let n;let o=0;let a=0;if(t[t.length-1]==="Z"){i=t.substring(0,t.length-1);e=true}else{const e=new Number(t[t.length-1]);if(isNaN(e.valueOf()))throw new Error("Wrong input string for conversion");i=t}if(e){if(i.indexOf("+")!==-1)throw new Error("Wrong input string for conversion");if(i.indexOf("-")!==-1)throw new Error("Wrong input string for conversion")}else{let t=1;let e=i.indexOf("+");let r="";if(e===-1){e=i.indexOf("-");t=-1}if(e!==-1){r=i.substring(e+1);i=i.substring(0,e);if(r.length!==2&&r.length!==4)throw new Error("Wrong input string for conversion");let s=parseInt(r.substring(0,2),10);if(isNaN(s.valueOf()))throw new Error("Wrong input string for conversion");o=t*s;if(r.length===4){s=parseInt(r.substring(2,4),10);if(isNaN(s.valueOf()))throw new Error("Wrong input string for conversion");a=t*s}}}let c=i.indexOf(".");if(c===-1)c=i.indexOf(",");if(c!==-1){const t=new Number(`0${i.substring(c)}`);if(isNaN(t.valueOf()))throw new Error("Wrong input string for conversion");s=t.valueOf();r=i.substring(0,c)}else r=i;switch(true){case r.length===8:n=/(\d{4})(\d{2})(\d{2})/gi;if(c!==-1)throw new Error("Wrong input string for conversion");break;case r.length===10:n=/(\d{4})(\d{2})(\d{2})(\d{2})/gi;if(c!==-1){let t=60*s;this.minute=Math.floor(t);t=60*(t-this.minute);this.second=Math.floor(t);t=1e3*(t-this.second);this.millisecond=Math.floor(t)}break;case r.length===12:n=/(\d{4})(\d{2})(\d{2})(\d{2})(\d{2})/gi;if(c!==-1){let t=60*s;this.second=Math.floor(t);t=1e3*(t-this.second);this.millisecond=Math.floor(t)}break;case r.length===14:n=/(\d{4})(\d{2})(\d{2})(\d{2})(\d{2})(\d{2})/gi;if(c!==-1){const t=1e3*s;this.millisecond=Math.floor(t)}break;default:throw new Error("Wrong input string for conversion")}const u=n.exec(r);if(u===null)throw new Error("Wrong input string for conversion");for(let t=1;t<u.length;t++){switch(t){case 1:this.year=parseInt(u[t],10);break;case 2:this.month=parseInt(u[t],10);break;case 3:this.day=parseInt(u[t],10);break;case 4:this.hour=parseInt(u[t],10)+o;break;case 5:this.minute=parseInt(u[t],10)+a;break;case 6:this.second=parseInt(u[t],10);break;default:throw new Error("Wrong input string for conversion")}}if(e===false){const t=new Date(this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond);this.year=t.getUTCFullYear();this.month=t.getUTCMonth();this.day=t.getUTCDay();this.hour=t.getUTCHours();this.minute=t.getUTCMinutes();this.second=t.getUTCSeconds();this.millisecond=t.getUTCMilliseconds()}}toString(t="iso"){if(t==="iso"){const t=[];t.push(d(this.year,4));t.push(d(this.month,2));t.push(d(this.day,2));t.push(d(this.hour,2));t.push(d(this.minute,2));t.push(d(this.second,2));if(this.millisecond!==0){t.push(".");t.push(d(this.millisecond,3))}t.push("Z");return t.join("")}return super.toString(t)}toJSON(){return{...super.toJSON(),millisecond:this.millisecond}}}fe=ye;(()=>{F.GeneralizedTime=fe})();ye.NAME="GeneralizedTime";var Se;class Ae extends Ft{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=31}}Se=Ae;(()=>{F.DATE=Se})();Ae.NAME="DATE";var Ce;class ve extends Ft{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=32}}Ce=ve;(()=>{F.TimeOfDay=Ce})();ve.NAME="TimeOfDay";var me;class ge extends Ft{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=33}}me=ge;(()=>{F.DateTime=me})();ge.NAME="DateTime";var we;class Ee extends Ft{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=34}}we=Ee;(()=>{F.Duration=we})();Ee.NAME="Duration";var Pe;class De extends Ft{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=14}}Pe=De;(()=>{F.TIME=Pe})();De.NAME="TIME";class be{constructor({name:t=T,optional:e=false}={}){this.name=t;this.optional=e}}class Be extends be{constructor({value:t=[],...e}={}){super(e);this.value=t}}class Ie extends be{constructor({value:t=new be,local:e=false,...i}={}){super(i);this.value=t;this.local=e}}class xe{constructor({data:t=R}={}){this.dataView=n.BufferSourceConverter.toUint8Array(t)}get data(){return this.dataView.slice().buffer}set data(t){this.dataView=n.BufferSourceConverter.toUint8Array(t)}fromBER(t,e,i){const r=e+i;this.dataView=n.BufferSourceConverter.toUint8Array(t).subarray(e,r);return r}toBER(t){return this.dataView.slice().buffer}}function Te(t,e,i){if(i instanceof Be){for(let r=0;r<i.value.length;r++){const s=Te(t,e,i.value[r]);if(s.verified){return{verified:true,result:t}}}{const t={verified:false,result:{error:"Wrong values for Choice type"}};if(i.hasOwnProperty(m))t.name=i.name;return t}}if(i instanceof be){if(i.hasOwnProperty(m))t[i.name]=e;return{verified:true,result:t}}if(t instanceof Object===false){return{verified:false,result:{error:"Wrong root object"}}}if(e instanceof Object===false){return{verified:false,result:{error:"Wrong ASN.1 data"}}}if(i instanceof Object===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(E in i===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(B in i.idBlock===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(I in i.idBlock===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}const r=i.idBlock.toBER(false);if(r.byteLength===0){return{verified:false,result:{error:"Error encoding idBlock for ASN.1 schema"}}}const s=i.idBlock.fromBER(r,0,r.byteLength);if(s===-1){return{verified:false,result:{error:"Error decoding idBlock for ASN.1 schema"}}}if(i.idBlock.hasOwnProperty(P)===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(i.idBlock.tagClass!==e.idBlock.tagClass){return{verified:false,result:t}}if(i.idBlock.hasOwnProperty(D)===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(i.idBlock.tagNumber!==e.idBlock.tagNumber){return{verified:false,result:t}}if(i.idBlock.hasOwnProperty(b)===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(i.idBlock.isConstructed!==e.idBlock.isConstructed){return{verified:false,result:t}}if(!(w in i.idBlock)){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(i.idBlock.isHexOnly!==e.idBlock.isHexOnly){return{verified:false,result:t}}if(i.idBlock.isHexOnly){if(g in i.idBlock===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}const r=i.idBlock.valueHexView;const s=e.idBlock.valueHexView;if(r.length!==s.length){return{verified:false,result:t}}for(let e=0;e<r.length;e++){if(r[e]!==s[1]){return{verified:false,result:t}}}}if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name)t[i.name]=e}if(i instanceof F.Constructed){let r=0;let s={verified:false,result:{error:"Unknown error"}};let n=i.valueBlock.value.length;if(n>0){if(i.valueBlock.value[0]instanceof Ie){n=e.valueBlock.value.length}}if(n===0){return{verified:true,result:t}}if(e.valueBlock.value.length===0&&i.valueBlock.value.length!==0){let e=true;for(let t=0;t<i.valueBlock.value.length;t++)e=e&&(i.valueBlock.value[t].optional||false);if(e){return{verified:true,result:t}}if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name)delete t[i.name]}t.error="Inconsistent object length";return{verified:false,result:t}}for(let o=0;o<n;o++){if(o-r>=e.valueBlock.value.length){if(i.valueBlock.value[o].optional===false){const e={verified:false,result:t};t.error="Inconsistent length between ASN.1 data and schema";if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name){delete t[i.name];e.name=i.name}}return e}}else{if(i.valueBlock.value[0]instanceof Ie){s=Te(t,e.valueBlock.value[o],i.valueBlock.value[0].value);if(s.verified===false){if(i.valueBlock.value[0].optional)r++;else{if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name)delete t[i.name]}return s}}if(m in i.valueBlock.value[0]&&i.valueBlock.value[0].name.length>0){let r={};if(x in i.valueBlock.value[0]&&i.valueBlock.value[0].local)r=e;else r=t;if(typeof r[i.valueBlock.value[0].name]==="undefined")r[i.valueBlock.value[0].name]=[];r[i.valueBlock.value[0].name].push(e.valueBlock.value[o])}}else{s=Te(t,e.valueBlock.value[o-r],i.valueBlock.value[o]);if(s.verified===false){if(i.valueBlock.value[o].optional)r++;else{if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name)delete t[i.name]}return s}}}}}if(s.verified===false){const e={verified:false,result:t};if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name){delete t[i.name];e.name=i.name}}return e}return{verified:true,result:t}}if(i.primitiveSchema&&g in e.valueBlock){const r=z(e.valueBlock.valueHexView);if(r.offset===-1){const e={verified:false,result:r.result};if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name){delete t[i.name];e.name=i.name}}return e}return Te(t,r.result,i.primitiveSchema)}return{verified:true,result:t}}function Oe(t,e){if(e instanceof Object===false){return{verified:false,result:{error:"Wrong ASN.1 schema type"}}}const i=z(n.BufferSourceConverter.toUint8Array(t));if(i.offset===-1){return{verified:false,result:i.result}}return Te(i.result,i.result,e)}var Re=Object.freeze({__proto__:null,Any:be,BaseBlock:V,BaseStringBlock:$,BitString:ft,BmpString:$t,Boolean:ct,CharacterString:pe,Choice:Be,Constructed:tt,DATE:Ae,DateTime:ge,Duration:Ee,EndOfContent:rt,Enumerated:Et,GeneralString:ue,GeneralizedTime:ye,GraphicString:ne,HexBlock:K,IA5String:re,Integer:gt,Null:nt,NumericString:zt,ObjectIdentifier:Bt,OctetString:pt,Primitive:Q,PrintableString:Zt,RawData:xe,RelativeObjectIdentifier:Ot,Repeated:Ie,Sequence:Mt,Set:kt,TIME:De,TeletexString:Yt,TimeOfDay:ve,UTCTime:de,UniversalString:Qt,Utf8String:Ft,ValueBlock:j,VideotexString:ee,ViewWriter:A,VisibleString:ae,compareSchema:Te,fromBER:J,verifySchema:Oe});var Me;(function(t){t[t["Sequence"]=0]="Sequence";t[t["Set"]=1]="Set";t[t["Choice"]=2]="Choice"})(Me||(Me={}));var Ne;(function(t){t[t["Any"]=1]="Any";t[t["Boolean"]=2]="Boolean";t[t["OctetString"]=3]="OctetString";t[t["BitString"]=4]="BitString";t[t["Integer"]=5]="Integer";t[t["Enumerated"]=6]="Enumerated";t[t["ObjectIdentifier"]=7]="ObjectIdentifier";t[t["Utf8String"]=8]="Utf8String";t[t["BmpString"]=9]="BmpString";t[t["UniversalString"]=10]="UniversalString";t[t["NumericString"]=11]="NumericString";t[t["PrintableString"]=12]="PrintableString";t[t["TeletexString"]=13]="TeletexString";t[t["VideotexString"]=14]="VideotexString";t[t["IA5String"]=15]="IA5String";t[t["GraphicString"]=16]="GraphicString";t[t["VisibleString"]=17]="VisibleString";t[t["GeneralString"]=18]="GeneralString";t[t["CharacterString"]=19]="CharacterString";t[t["UTCTime"]=20]="UTCTime";t[t["GeneralizedTime"]=21]="GeneralizedTime";t[t["DATE"]=22]="DATE";t[t["TimeOfDay"]=23]="TimeOfDay";t[t["DateTime"]=24]="DateTime";t[t["Duration"]=25]="Duration";t[t["TIME"]=26]="TIME";t[t["Null"]=27]="Null"})(Ne||(Ne={}));class ke{constructor(t,e=0){this.unusedBits=0;this.value=new ArrayBuffer(0);if(t){if(typeof t==="number"){this.fromNumber(t)}else if(n.BufferSourceConverter.isBufferSource(t)){this.unusedBits=e;this.value=n.BufferSourceConverter.toArrayBuffer(t)}else{throw TypeError("Unsupported type of 'params' argument for BitString")}}}fromASN(t){if(!(t instanceof ft)){throw new TypeError("Argument 'asn' is not instance of ASN.1 BitString")}this.unusedBits=t.valueBlock.unusedBits;this.value=t.valueBlock.valueHex;return this}toASN(){return new ft({unusedBits:this.unusedBits,valueHex:this.value})}toSchema(t){return new ft({name:t})}toNumber(){let t="";const e=new Uint8Array(this.value);for(const i of e){t+=i.toString(2).padStart(8,"0")}t=t.split("").reverse().join("");if(this.unusedBits){t=t.slice(this.unusedBits).padStart(this.unusedBits,"0")}return parseInt(t,2)}fromNumber(t){let e=t.toString(2);const i=e.length+7>>3;this.unusedBits=(i<<3)-e.length;const r=new Uint8Array(i);e=e.padStart(i<<3,"0").split("").reverse().join("");let s=0;while(s<i){r[s]=parseInt(e.slice(s<<3,(s<<3)+8),2);s++}this.value=r.buffer}}class Ke{get byteLength(){return this.buffer.byteLength}get byteOffset(){return 0}constructor(t){if(typeof t==="number"){this.buffer=new ArrayBuffer(t)}else{if(n.BufferSourceConverter.isBufferSource(t)){this.buffer=n.BufferSourceConverter.toArrayBuffer(t)}else if(Array.isArray(t)){this.buffer=new Uint8Array(t)}else{this.buffer=new ArrayBuffer(0)}}}fromASN(t){if(!(t instanceof pt)){throw new TypeError("Argument 'asn' is not instance of ASN.1 OctetString")}this.buffer=t.valueBlock.valueHex;return this}toASN(){return new pt({valueHex:this.buffer})}toSchema(t){return new pt({name:t})}}const He={fromASN:t=>t instanceof nt?null:t.valueBeforeDecodeView,toASN:t=>{if(t===null){return new nt}const e=J(t);if(e.result.error){throw new Error(e.result.error)}return e.result}};const je={fromASN:t=>t.valueBlock.valueHexView.byteLength>=4?t.valueBlock.toString():t.valueBlock.valueDec,toASN:t=>new gt({value:+t})};const Ue={fromASN:t=>t.valueBlock.valueDec,toASN:t=>new Et({value:t})};const _e={fromASN:t=>t.valueBlock.valueHexView,toASN:t=>new gt({valueHex:t})};const Fe={fromASN:t=>t.valueBlock.valueHexView,toASN:t=>new ft({valueHex:t})};const Ve={fromASN:t=>t.valueBlock.toString(),toASN:t=>new Bt({value:t})};const Le={fromASN:t=>t.valueBlock.value,toASN:t=>new ct({value:t})};const $e={fromASN:t=>t.valueBlock.valueHexView,toASN:t=>new pt({valueHex:t})};const Ge={fromASN:t=>new Ke(t.getValue()),toASN:t=>t.toASN()};function We(t){return{fromASN:t=>t.valueBlock.value,toASN:e=>new t({value:e})}}const Qe=We(Ft);const qe=We($t);const ze=We(Qt);const Je=We(zt);const Ze=We(Zt);const Xe=We(Yt);const Ye=We(ee);const ti=We(re);const ei=We(ne);const ii=We(ae);const ri=We(ue);const si=We(pe);const ni={fromASN:t=>t.toDate(),toASN:t=>new de({valueDate:t})};const oi={fromASN:t=>t.toDate(),toASN:t=>new ye({valueDate:t})};const ai={fromASN:()=>null,toASN:()=>new nt};function ci(t){switch(t){case Ne.Any:return He;case Ne.BitString:return Fe;case Ne.BmpString:return qe;case Ne.Boolean:return Le;case Ne.CharacterString:return si;case Ne.Enumerated:return Ue;case Ne.GeneralString:return ri;case Ne.GeneralizedTime:return oi;case Ne.GraphicString:return ei;case Ne.IA5String:return ti;case Ne.Integer:return je;case Ne.Null:return ai;case Ne.NumericString:return Je;case Ne.ObjectIdentifier:return Ve;case Ne.OctetString:return $e;case Ne.PrintableString:return Ze;case Ne.TeletexString:return Xe;case Ne.UTCTime:return ni;case Ne.UniversalString:return ze;case Ne.Utf8String:return Qe;case Ne.VideotexString:return Ye;case Ne.VisibleString:return ii;default:return null}}function ui(t){if(typeof t==="function"&&t.prototype){if(t.prototype.toASN&&t.prototype.fromASN){return true}else{return ui(t.prototype)}}else{return!!(t&&typeof t==="object"&&"toASN"in t&&"fromASN"in t)}}function li(t){var e;if(t){const i=Object.getPrototypeOf(t);if(((e=i===null||i===void 0?void 0:i.prototype)===null||e===void 0?void 0:e.constructor)===Array){return true}return li(i)}return false}function pi(t,e){if(!(t&&e)){return false}if(t.byteLength!==e.byteLength){return false}const i=new Uint8Array(t);const r=new Uint8Array(e);for(let e=0;e<t.byteLength;e++){if(i[e]!==r[e]){return false}}return true}class hi{constructor(){this.items=new WeakMap}has(t){return this.items.has(t)}get(t,e=false){const i=this.items.get(t);if(!i){throw new Error(`Cannot get schema for '${t.prototype.constructor.name}' target`)}if(e&&!i.schema){throw new Error(`Schema '${t.prototype.constructor.name}' doesn't contain ASN.1 schema. Call 'AsnSchemaStorage.cache'.`)}return i}cache(t){const e=this.get(t);if(!e.schema){e.schema=this.create(t,true)}}createDefault(t){const e={type:Me.Sequence,items:{}};const i=this.findParentSchema(t);if(i){Object.assign(e,i);e.items=Object.assign({},e.items,i.items)}return e}create(t,e){const i=this.items.get(t)||this.createDefault(t);const r=[];for(const t in i.items){const s=i.items[t];const n=e?t:"";let o;if(typeof s.type==="number"){const t=Ne[s.type];const e=Re[t];if(!e){throw new Error(`Cannot get ASN1 class by name '${t}'`)}o=new e({name:n})}else if(ui(s.type)){const t=new s.type;o=t.toSchema(n)}else if(s.optional){const t=this.get(s.type);if(t.type===Me.Choice){o=new be({name:n})}else{o=this.create(s.type,false);o.name=n}}else{o=new be({name:n})}const a=!!s.optional||s.defaultValue!==undefined;if(s.repeated){o.name="";const t=s.repeated==="set"?kt:Mt;o=new t({name:"",value:[new Ie({name:n,value:o})]})}if(s.context!==null&&s.context!==undefined){if(s.implicit){if(typeof s.type==="number"||ui(s.type)){const t=s.repeated?tt:Q;r.push(new t({name:n,optional:a,idBlock:{tagClass:3,tagNumber:s.context}}))}else{this.cache(s.type);const t=!!s.repeated;let e=!t?this.get(s.type,true).schema:o;e="valueBlock"in e?e.valueBlock.value:e.value;r.push(new tt({name:!t?n:"",optional:a,idBlock:{tagClass:3,tagNumber:s.context},value:e}))}}else{r.push(new tt({optional:a,idBlock:{tagClass:3,tagNumber:s.context},value:[o]}))}}else{o.optional=a;r.push(o)}}switch(i.type){case Me.Sequence:return new Mt({value:r,name:""});case Me.Set:return new kt({value:r,name:""});case Me.Choice:return new Be({value:r,name:""});default:throw new Error(`Unsupported ASN1 type in use`)}}set(t,e){this.items.set(t,e);return this}findParentSchema(t){const e=Object.getPrototypeOf(t);if(e){const t=this.items.get(e);return t||this.findParentSchema(e)}return null}}const di=new hi;const fi=t=>e=>{let i;if(!di.has(e)){i=di.createDefault(e);di.set(e,i)}else{i=di.get(e)}Object.assign(i,t)};const yi=t=>(e,i)=>{let r;if(!di.has(e.constructor)){r=di.createDefault(e.constructor);di.set(e.constructor,r)}else{r=di.get(e.constructor)}const s=Object.assign({},t);if(typeof s.type==="number"&&!s.converter){const r=ci(t.type);if(!r){throw new Error(`Cannot get default converter for property '${i}' of ${e.constructor.name}`)}s.converter=r}r.items[i]=s};class Si extends Error{constructor(){super(...arguments);this.schemas=[]}}class Ai{static parse(t,e){const i=J(t);if(i.result.error){throw new Error(i.result.error)}const r=this.fromASN(i.result,e);return r}static fromASN(t,e){var i;try{if(ui(e)){const i=new e;return i.fromASN(t)}const r=di.get(e);di.cache(e);let s=r.schema;if(t.constructor===tt&&r.type!==Me.Choice){s=new tt({idBlock:{tagClass:3,tagNumber:t.idBlock.tagNumber},value:r.schema.valueBlock.value});for(const e in r.items){delete t[e]}}const n=Te({},t,s);if(!n.verified){throw new Si(`Data does not match to ${e.name} ASN1 schema. ${n.result.error}`)}const o=new e;if(li(e)){if(!("value"in t.valueBlock&&Array.isArray(t.valueBlock.value))){throw new Error(`Cannot get items from the ASN.1 parsed value. ASN.1 object is not constructed.`)}const i=r.itemType;if(typeof i==="number"){const r=ci(i);if(!r){throw new Error(`Cannot get default converter for array item of ${e.name} ASN1 schema`)}return e.from(t.valueBlock.value,(t=>r.fromASN(t)))}else{return e.from(t.valueBlock.value,(t=>this.fromASN(t,i)))}}for(const t in r.items){const e=n.result[t];if(!e){continue}const s=r.items[t];const a=s.type;if(typeof a==="number"||ui(a)){const r=(i=s.converter)!==null&&i!==void 0?i:ui(a)?new a:null;if(!r){throw new Error("Converter is empty")}if(s.repeated){if(s.implicit){const i=s.repeated==="sequence"?Mt:kt;const n=new i;n.valueBlock=e.valueBlock;const a=J(n.toBER(false));if(a.offset===-1){throw new Error(`Cannot parse the child item. ${a.result.error}`)}if(!("value"in a.result.valueBlock&&Array.isArray(a.result.valueBlock.value))){throw new Error("Cannot get items from the ASN.1 parsed value. ASN.1 object is not constructed.")}const c=a.result.valueBlock.value;o[t]=Array.from(c,(t=>r.fromASN(t)))}else{o[t]=Array.from(e,(t=>r.fromASN(t)))}}else{let i=e;if(s.implicit){let t;if(ui(a)){t=(new a).toSchema("")}else{const e=Ne[a];const i=Re[e];if(!i){throw new Error(`Cannot get '${e}' class from asn1js module`)}t=new i}t.valueBlock=i.valueBlock;i=J(t.toBER(false)).result}o[t]=r.fromASN(i)}}else{if(s.repeated){if(!Array.isArray(e)){throw new Error("Cannot get list of items from the ASN.1 parsed value. ASN.1 value should be iterable.")}o[t]=Array.from(e,(t=>this.fromASN(t,a)))}else{o[t]=this.fromASN(e,a)}}}return o}catch(t){if(t instanceof Si){t.schemas.push(e.name)}throw t}}}class Ci{static serialize(t){if(t instanceof V){return t.toBER(false)}return this.toASN(t).toBER(false)}static toASN(t){if(t&&typeof t==="object"&&ui(t)){return t.toASN()}if(!(t&&typeof t==="object")){throw new TypeError("Parameter 1 should be type of Object.")}const e=t.constructor;const i=di.get(e);di.cache(e);let r=[];if(i.itemType){if(!Array.isArray(t)){throw new TypeError("Parameter 1 should be type of Array.")}if(typeof i.itemType==="number"){const s=ci(i.itemType);if(!s){throw new Error(`Cannot get default converter for array item of ${e.name} ASN1 schema`)}r=t.map((t=>s.toASN(t)))}else{r=t.map((t=>this.toAsnItem({type:i.itemType},"[]",e,t)))}}else{for(const s in i.items){const n=i.items[s];const o=t[s];if(o===undefined||n.defaultValue===o||typeof n.defaultValue==="object"&&typeof o==="object"&&pi(this.serialize(n.defaultValue),this.serialize(o))){continue}const a=Ci.toAsnItem(n,s,e,o);if(typeof n.context==="number"){if(n.implicit){if(!n.repeated&&(typeof n.type==="number"||ui(n.type))){const t={};t.valueHex=a instanceof nt?a.valueBeforeDecodeView:a.valueBlock.toBER();r.push(new Q({optional:n.optional,idBlock:{tagClass:3,tagNumber:n.context},...t}))}else{r.push(new tt({optional:n.optional,idBlock:{tagClass:3,tagNumber:n.context},value:a.valueBlock.value}))}}else{r.push(new tt({optional:n.optional,idBlock:{tagClass:3,tagNumber:n.context},value:[a]}))}}else if(n.repeated){r=r.concat(a)}else{r.push(a)}}}let s;switch(i.type){case Me.Sequence:s=new Mt({value:r});break;case Me.Set:s=new kt({value:r});break;case Me.Choice:if(!r[0]){throw new Error(`Schema '${e.name}' has wrong data. Choice cannot be empty.`)}s=r[0];break}return s}static toAsnItem(t,e,i,r){let s;if(typeof t.type==="number"){const n=t.converter;if(!n){throw new Error(`Property '${e}' doesn't have converter for type ${Ne[t.type]} in schema '${i.name}'`)}if(t.repeated){if(!Array.isArray(r)){throw new TypeError("Parameter 'objProp' should be type of Array.")}const e=Array.from(r,(t=>n.toASN(t)));const i=t.repeated==="sequence"?Mt:kt;s=new i({value:e})}else{s=n.toASN(r)}}else{if(t.repeated){if(!Array.isArray(r)){throw new TypeError("Parameter 'objProp' should be type of Array.")}const e=Array.from(r,(t=>this.toASN(t)));const i=t.repeated==="sequence"?Mt:kt;s=new i({value:e})}else{s=this.toASN(r)}}return s}}class vi extends Array{constructor(t=[]){if(typeof t==="number"){super(t)}else{super();for(const e of t){this.push(e)}}}}class mi{static serialize(t){return Ci.serialize(t)}static parse(t,e){return Ai.parse(t,e)}static toString(t){const e=n.BufferSourceConverter.isBufferSource(t)?n.BufferSourceConverter.toArrayBuffer(t):mi.serialize(t);const i=J(e);if(i.offset===-1){throw new Error(`Cannot decode ASN.1 data. ${i.result.error}`)}return i.result.toString()}}function gi(t,e,i,r){var s=arguments.length,n=s<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,o;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")n=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)if(o=t[a])n=(s<3?o(n):s>3?o(e,i,n):o(e,i))||n;return s>3&&n&&Object.defineProperty(e,i,n),n}typeof SuppressedError==="function"?SuppressedError:function(t,e,i){var r=new Error(i);return r.name="SuppressedError",r.error=t,r.suppressed=e,r};class wi{static isIPv4(t){return/^(\d{1,3}\.){3}\d{1,3}$/.test(t)}static parseIPv4(t){const e=t.split(".");if(e.length!==4){throw new Error("Invalid IPv4 address")}return e.map((t=>{const e=parseInt(t,10);if(isNaN(e)||e<0||e>255){throw new Error("Invalid IPv4 address part")}return e}))}static parseIPv6(t){const e=this.expandIPv6(t);const i=e.split(":");if(i.length!==8){throw new Error("Invalid IPv6 address")}return i.reduce(((t,e)=>{const i=parseInt(e,16);if(isNaN(i)||i<0||i>65535){throw new Error("Invalid IPv6 address part")}t.push(i>>8&255);t.push(i&255);return t}),[])}static expandIPv6(t){if(!t.includes("::")){return t}const e=t.split("::");if(e.length>2){throw new Error("Invalid IPv6 address")}const i=e[0]?e[0].split(":"):[];const r=e[1]?e[1].split(":"):[];const s=8-(i.length+r.length);if(s<0){throw new Error("Invalid IPv6 address")}return[...i,...Array(s).fill("0"),...r].join(":")}static formatIPv6(t){const e=[];for(let i=0;i<16;i+=2){e.push((t[i]<<8|t[i+1]).toString(16))}return this.compressIPv6(e.join(":"))}static compressIPv6(t){const e=t.split(":");let i=-1;let r=0;let s=-1;let n=0;for(let t=0;t<e.length;t++){if(e[t]==="0"){if(s===-1){s=t}n++}else{if(n>r){i=s;r=n}s=-1;n=0}}if(n>r){i=s;r=n}if(r>1){const t=e.slice(0,i).join(":");const s=e.slice(i+r).join(":");return`${t}::${s}`}return t}static parseCIDR(t){const[e,i]=t.split("/");const r=parseInt(i,10);if(this.isIPv4(e)){if(r<0||r>32){throw new Error("Invalid IPv4 prefix length")}return[this.parseIPv4(e),r]}else{if(r<0||r>128){throw new Error("Invalid IPv6 prefix length")}return[this.parseIPv6(e),r]}}static decodeIP(t){if(t.length===64&&parseInt(t,16)===0){return"::/0"}if(t.length!==16){return t}const e=parseInt(t.slice(8),16).toString(2).split("").reduce(((t,e)=>t+ +e),0);let i=t.slice(0,8).replace(/(.{2})/g,(t=>`${parseInt(t,16)}.`));i=i.slice(0,-1);return`${i}/${e}`}static toString(t){const e=new Uint8Array(t);if(e.length===4){return Array.from(e).join(".")}if(e.length===16){return this.formatIPv6(e)}if(e.length===8||e.length===32){const t=e.length/2;const i=e.slice(0,t);const r=e.slice(t);const s=e.every((t=>t===0));if(s){return e.length===8?"0.0.0.0/0":"::/0"}const n=r.reduce(((t,e)=>t+(e.toString(2).match(/1/g)||[]).length),0);if(e.length===8){const t=Array.from(i).join(".");return`${t}/${n}`}else{const t=this.formatIPv6(i);return`${t}/${n}`}}return this.decodeIP(n.Convert.ToHex(t))}static fromString(t){if(t.includes("/")){const[e,i]=this.parseCIDR(t);const r=new Uint8Array(e.length);let s=i;for(let t=0;t<r.length;t++){if(s>=8){r[t]=255;s-=8}else if(s>0){r[t]=255<<8-s;s=0}}const n=new Uint8Array(e.length*2);n.set(e,0);n.set(r,e.length);return n.buffer}const e=this.isIPv4(t)?this.parseIPv4(t):this.parseIPv6(t);return new Uint8Array(e).buffer}}var Ei,Pi,Di;let bi=class t{constructor(t={}){Object.assign(this,t)}toString(){return this.bmpString||this.printableString||this.teletexString||this.universalString||this.utf8String||""}};gi([yi({type:Ne.TeletexString})],bi.prototype,"teletexString",void 0);gi([yi({type:Ne.PrintableString})],bi.prototype,"printableString",void 0);gi([yi({type:Ne.UniversalString})],bi.prototype,"universalString",void 0);gi([yi({type:Ne.Utf8String})],bi.prototype,"utf8String",void 0);gi([yi({type:Ne.BmpString})],bi.prototype,"bmpString",void 0);bi=gi([fi({type:Me.Choice})],bi);let Bi=class t extends bi{constructor(t={}){super(t);Object.assign(this,t)}toString(){return this.ia5String||(this.anyValue?n.Convert.ToHex(this.anyValue):super.toString())}};gi([yi({type:Ne.IA5String})],Bi.prototype,"ia5String",void 0);gi([yi({type:Ne.Any})],Bi.prototype,"anyValue",void 0);Bi=gi([fi({type:Me.Choice})],Bi);class Ii{constructor(t={}){this.type="";this.value=new Bi;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Ii.prototype,"type",void 0);gi([yi({type:Bi})],Ii.prototype,"value",void 0);let xi=Ei=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Ei.prototype)}};xi=Ei=gi([fi({type:Me.Set,itemType:Ii})],xi);let Ti=Pi=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Pi.prototype)}};Ti=Pi=gi([fi({type:Me.Sequence,itemType:xi})],Ti);let Oi=Di=class t extends Ti{constructor(t){super(t);Object.setPrototypeOf(this,Di.prototype)}};Oi=Di=gi([fi({type:Me.Sequence})],Oi);const Ri={fromASN:t=>wi.toString($e.fromASN(t)),toASN:t=>$e.toASN(wi.fromString(t))};class Mi{constructor(t={}){this.typeId="";this.value=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Mi.prototype,"typeId",void 0);gi([yi({type:Ne.Any,context:0})],Mi.prototype,"value",void 0);class Ni{constructor(t={}){this.partyName=new bi;Object.assign(this,t)}}gi([yi({type:bi,optional:true,context:0,implicit:true})],Ni.prototype,"nameAssigner",void 0);gi([yi({type:bi,context:1,implicit:true})],Ni.prototype,"partyName",void 0);let ki=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Mi,context:0,implicit:true})],ki.prototype,"otherName",void 0);gi([yi({type:Ne.IA5String,context:1,implicit:true})],ki.prototype,"rfc822Name",void 0);gi([yi({type:Ne.IA5String,context:2,implicit:true})],ki.prototype,"dNSName",void 0);gi([yi({type:Ne.Any,context:3,implicit:true})],ki.prototype,"x400Address",void 0);gi([yi({type:Oi,context:4,implicit:false})],ki.prototype,"directoryName",void 0);gi([yi({type:Ni,context:5})],ki.prototype,"ediPartyName",void 0);gi([yi({type:Ne.IA5String,context:6,implicit:true})],ki.prototype,"uniformResourceIdentifier",void 0);gi([yi({type:Ne.OctetString,context:7,implicit:true,converter:Ri})],ki.prototype,"iPAddress",void 0);gi([yi({type:Ne.ObjectIdentifier,context:8,implicit:true})],ki.prototype,"registeredID",void 0);ki=gi([fi({type:Me.Choice})],ki);const Ki="1.3.6.1.5.5.7";const Hi=`${Ki}.1`;const ji="2.5.29";var Ui;const _i=`${Hi}.1`;class Fi{constructor(t={}){this.accessMethod="";this.accessLocation=new ki;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Fi.prototype,"accessMethod",void 0);gi([yi({type:ki})],Fi.prototype,"accessLocation",void 0);let Vi=Ui=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Ui.prototype)}};Vi=Ui=gi([fi({type:Me.Sequence,itemType:Fi})],Vi);const Li=`${ji}.35`;class $i extends Ke{}class Gi{constructor(t={}){if(t){Object.assign(this,t)}}}gi([yi({type:$i,context:0,optional:true,implicit:true})],Gi.prototype,"keyIdentifier",void 0);gi([yi({type:ki,context:1,optional:true,implicit:true,repeated:"sequence"})],Gi.prototype,"authorityCertIssuer",void 0);gi([yi({type:Ne.Integer,context:2,optional:true,implicit:true,converter:_e})],Gi.prototype,"authorityCertSerialNumber",void 0);const Wi=`${ji}.19`;class Qi{constructor(t={}){this.cA=false;Object.assign(this,t)}}gi([yi({type:Ne.Boolean,defaultValue:false})],Qi.prototype,"cA",void 0);gi([yi({type:Ne.Integer,optional:true})],Qi.prototype,"pathLenConstraint",void 0);var qi;let zi=qi=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,qi.prototype)}};zi=qi=gi([fi({type:Me.Sequence,itemType:ki})],zi);var Ji;const Zi=`${ji}.29`;let Xi=Ji=class t extends zi{constructor(t){super(t);Object.setPrototypeOf(this,Ji.prototype)}};Xi=Ji=gi([fi({type:Me.Sequence})],Xi);var Yi;const tr=`${ji}.32`;let er=class t{constructor(t={}){Object.assign(this,t)}toString(){return this.ia5String||this.visibleString||this.bmpString||this.utf8String||""}};gi([yi({type:Ne.IA5String})],er.prototype,"ia5String",void 0);gi([yi({type:Ne.VisibleString})],er.prototype,"visibleString",void 0);gi([yi({type:Ne.BmpString})],er.prototype,"bmpString",void 0);gi([yi({type:Ne.Utf8String})],er.prototype,"utf8String",void 0);er=gi([fi({type:Me.Choice})],er);class ir{constructor(t={}){this.organization=new er;this.noticeNumbers=[];Object.assign(this,t)}}gi([yi({type:er})],ir.prototype,"organization",void 0);gi([yi({type:Ne.Integer,repeated:"sequence"})],ir.prototype,"noticeNumbers",void 0);class rr{constructor(t={}){Object.assign(this,t)}}gi([yi({type:ir,optional:true})],rr.prototype,"noticeRef",void 0);gi([yi({type:er,optional:true})],rr.prototype,"explicitText",void 0);let sr=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.IA5String})],sr.prototype,"cPSuri",void 0);gi([yi({type:rr})],sr.prototype,"userNotice",void 0);sr=gi([fi({type:Me.Choice})],sr);class nr{constructor(t={}){this.policyQualifierId="";this.qualifier=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],nr.prototype,"policyQualifierId",void 0);gi([yi({type:Ne.Any})],nr.prototype,"qualifier",void 0);class or{constructor(t={}){this.policyIdentifier="";Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],or.prototype,"policyIdentifier",void 0);gi([yi({type:nr,repeated:"sequence",optional:true})],or.prototype,"policyQualifiers",void 0);let ar=Yi=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Yi.prototype)}};ar=Yi=gi([fi({type:Me.Sequence,itemType:or})],ar);const cr=`${ji}.20`;let ur=class t{constructor(t=0){this.value=t}};gi([yi({type:Ne.Integer})],ur.prototype,"value",void 0);ur=gi([fi({type:Me.Choice})],ur);const lr=`${ji}.27`;let pr=class t extends ur{};pr=gi([fi({type:Me.Choice})],pr);var hr;const dr=`${ji}.31`;var fr;(function(t){t[t["unused"]=1]="unused";t[t["keyCompromise"]=2]="keyCompromise";t[t["cACompromise"]=4]="cACompromise";t[t["affiliationChanged"]=8]="affiliationChanged";t[t["superseded"]=16]="superseded";t[t["cessationOfOperation"]=32]="cessationOfOperation";t[t["certificateHold"]=64]="certificateHold";t[t["privilegeWithdrawn"]=128]="privilegeWithdrawn";t[t["aACompromise"]=256]="aACompromise"})(fr||(fr={}));class yr extends ke{toJSON(){const t=[];const e=this.toNumber();if(e&fr.aACompromise){t.push("aACompromise")}if(e&fr.affiliationChanged){t.push("affiliationChanged")}if(e&fr.cACompromise){t.push("cACompromise")}if(e&fr.certificateHold){t.push("certificateHold")}if(e&fr.cessationOfOperation){t.push("cessationOfOperation")}if(e&fr.keyCompromise){t.push("keyCompromise")}if(e&fr.privilegeWithdrawn){t.push("privilegeWithdrawn")}if(e&fr.superseded){t.push("superseded")}if(e&fr.unused){t.push("unused")}return t}toString(){return`[${this.toJSON().join(", ")}]`}}let Sr=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ki,context:0,repeated:"sequence",implicit:true})],Sr.prototype,"fullName",void 0);gi([yi({type:xi,context:1,implicit:true})],Sr.prototype,"nameRelativeToCRLIssuer",void 0);Sr=gi([fi({type:Me.Choice})],Sr);class Ar{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Sr,context:0,optional:true})],Ar.prototype,"distributionPoint",void 0);gi([yi({type:yr,context:1,optional:true,implicit:true})],Ar.prototype,"reasons",void 0);gi([yi({type:ki,context:2,optional:true,repeated:"sequence",implicit:true})],Ar.prototype,"cRLIssuer",void 0);let Cr=hr=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,hr.prototype)}};Cr=hr=gi([fi({type:Me.Sequence,itemType:Ar})],Cr);var vr;let mr=vr=class t extends Cr{constructor(t){super(t);Object.setPrototypeOf(this,vr.prototype)}};mr=vr=gi([fi({type:Me.Sequence,itemType:Ar})],mr);const gr=`${ji}.28`;class wr{constructor(t={}){this.onlyContainsUserCerts=wr.ONLY;this.onlyContainsCACerts=wr.ONLY;this.indirectCRL=wr.ONLY;this.onlyContainsAttributeCerts=wr.ONLY;Object.assign(this,t)}}wr.ONLY=false;gi([yi({type:Sr,context:0,optional:true})],wr.prototype,"distributionPoint",void 0);gi([yi({type:Ne.Boolean,context:1,defaultValue:wr.ONLY,implicit:true})],wr.prototype,"onlyContainsUserCerts",void 0);gi([yi({type:Ne.Boolean,context:2,defaultValue:wr.ONLY,implicit:true})],wr.prototype,"onlyContainsCACerts",void 0);gi([yi({type:yr,context:3,optional:true,implicit:true})],wr.prototype,"onlySomeReasons",void 0);gi([yi({type:Ne.Boolean,context:4,defaultValue:wr.ONLY,implicit:true})],wr.prototype,"indirectCRL",void 0);gi([yi({type:Ne.Boolean,context:5,defaultValue:wr.ONLY,implicit:true})],wr.prototype,"onlyContainsAttributeCerts",void 0);const Er=`${ji}.21`;var Pr;(function(t){t[t["unspecified"]=0]="unspecified";t[t["keyCompromise"]=1]="keyCompromise";t[t["cACompromise"]=2]="cACompromise";t[t["affiliationChanged"]=3]="affiliationChanged";t[t["superseded"]=4]="superseded";t[t["cessationOfOperation"]=5]="cessationOfOperation";t[t["certificateHold"]=6]="certificateHold";t[t["removeFromCRL"]=8]="removeFromCRL";t[t["privilegeWithdrawn"]=9]="privilegeWithdrawn";t[t["aACompromise"]=10]="aACompromise"})(Pr||(Pr={}));let Dr=class t{constructor(t=Pr.unspecified){this.reason=Pr.unspecified;this.reason=t}toJSON(){return Pr[this.reason]}toString(){return this.toJSON()}};gi([yi({type:Ne.Enumerated})],Dr.prototype,"reason",void 0);Dr=gi([fi({type:Me.Choice})],Dr);var br;const Br=`${ji}.37`;let Ir=br=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,br.prototype)}};Ir=br=gi([fi({type:Me.Sequence,itemType:Ne.ObjectIdentifier})],Ir);const xr=`${ji}.54`;let Tr=class t{constructor(t=new ArrayBuffer(0)){this.value=t}};gi([yi({type:Ne.Integer,converter:_e})],Tr.prototype,"value",void 0);Tr=gi([fi({type:Me.Choice})],Tr);const Or=`${ji}.24`;let Rr=class t{constructor(t){this.value=new Date;if(t){this.value=t}}};gi([yi({type:Ne.GeneralizedTime})],Rr.prototype,"value",void 0);Rr=gi([fi({type:Me.Choice})],Rr);var Mr;const Nr=`${ji}.18`;let kr=Mr=class t extends zi{constructor(t){super(t);Object.setPrototypeOf(this,Mr.prototype)}};kr=Mr=gi([fi({type:Me.Sequence})],kr);const Kr=`${ji}.15`;var Hr;(function(t){t[t["digitalSignature"]=1]="digitalSignature";t[t["nonRepudiation"]=2]="nonRepudiation";t[t["keyEncipherment"]=4]="keyEncipherment";t[t["dataEncipherment"]=8]="dataEncipherment";t[t["keyAgreement"]=16]="keyAgreement";t[t["keyCertSign"]=32]="keyCertSign";t[t["cRLSign"]=64]="cRLSign";t[t["encipherOnly"]=128]="encipherOnly";t[t["decipherOnly"]=256]="decipherOnly"})(Hr||(Hr={}));class jr extends ke{toJSON(){const t=this.toNumber();const e=[];if(t&Hr.cRLSign){e.push("crlSign")}if(t&Hr.dataEncipherment){e.push("dataEncipherment")}if(t&Hr.decipherOnly){e.push("decipherOnly")}if(t&Hr.digitalSignature){e.push("digitalSignature")}if(t&Hr.encipherOnly){e.push("encipherOnly")}if(t&Hr.keyAgreement){e.push("keyAgreement")}if(t&Hr.keyCertSign){e.push("keyCertSign")}if(t&Hr.keyEncipherment){e.push("keyEncipherment")}if(t&Hr.nonRepudiation){e.push("nonRepudiation")}return e}toString(){return`[${this.toJSON().join(", ")}]`}}var Ur;const _r=`${ji}.30`;class Fr{constructor(t={}){this.base=new ki;this.minimum=0;Object.assign(this,t)}}gi([yi({type:ki})],Fr.prototype,"base",void 0);gi([yi({type:Ne.Integer,context:0,defaultValue:0,implicit:true})],Fr.prototype,"minimum",void 0);gi([yi({type:Ne.Integer,context:1,optional:true,implicit:true})],Fr.prototype,"maximum",void 0);let Vr=Ur=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Ur.prototype)}};Vr=Ur=gi([fi({type:Me.Sequence,itemType:Fr})],Vr);class Lr{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Vr,context:0,optional:true,implicit:true})],Lr.prototype,"permittedSubtrees",void 0);gi([yi({type:Vr,context:1,optional:true,implicit:true})],Lr.prototype,"excludedSubtrees",void 0);const $r=`${ji}.36`;class Gr{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ne.Integer,context:0,implicit:true,optional:true,converter:_e})],Gr.prototype,"requireExplicitPolicy",void 0);gi([yi({type:Ne.Integer,context:1,implicit:true,optional:true,converter:_e})],Gr.prototype,"inhibitPolicyMapping",void 0);var Wr;const Qr=`${ji}.33`;class qr{constructor(t={}){this.issuerDomainPolicy="";this.subjectDomainPolicy="";Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],qr.prototype,"issuerDomainPolicy",void 0);gi([yi({type:Ne.ObjectIdentifier})],qr.prototype,"subjectDomainPolicy",void 0);let zr=Wr=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Wr.prototype)}};zr=Wr=gi([fi({type:Me.Sequence,itemType:qr})],zr);var Jr;const Zr=`${ji}.17`;let Xr=Jr=class t extends zi{constructor(t){super(t);Object.setPrototypeOf(this,Jr.prototype)}};Xr=Jr=gi([fi({type:Me.Sequence})],Xr);let Yr=class t{constructor(t={}){this.type="";this.values=[];Object.assign(this,t)}};gi([yi({type:Ne.ObjectIdentifier})],Yr.prototype,"type",void 0);gi([yi({type:Ne.Any,repeated:"set"})],Yr.prototype,"values",void 0);var ts;const es=`${ji}.9`;let is=ts=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ts.prototype)}};is=ts=gi([fi({type:Me.Sequence,itemType:Yr})],is);const rs=`${ji}.14`;class ss extends $i{}const ns=`${ji}.16`;class os{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ne.GeneralizedTime,context:0,implicit:true,optional:true})],os.prototype,"notBefore",void 0);gi([yi({type:Ne.GeneralizedTime,context:1,implicit:true,optional:true})],os.prototype,"notAfter",void 0);const as="1.2.840.113533.7.65.0";var cs;(function(t){t[t["keyUpdateAllowed"]=1]="keyUpdateAllowed";t[t["newExtensions"]=2]="newExtensions";t[t["pKIXCertificate"]=4]="pKIXCertificate"})(cs||(cs={}));class us extends ke{toJSON(){const t=[];const e=this.toNumber();if(e&cs.pKIXCertificate){t.push("pKIXCertificate")}if(e&cs.newExtensions){t.push("newExtensions")}if(e&cs.keyUpdateAllowed){t.push("keyUpdateAllowed")}return t}toString(){return`[${this.toJSON().join(", ")}]`}}class ls{constructor(t={}){this.entrustVers="";this.entrustInfoFlags=new us;Object.assign(this,t)}}gi([yi({type:Ne.GeneralString})],ls.prototype,"entrustVers",void 0);gi([yi({type:us})],ls.prototype,"entrustInfoFlags",void 0);var ps;const hs=`${Hi}.11`;let ds=ps=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ps.prototype)}};ds=ps=gi([fi({type:Me.Sequence,itemType:Fi})],ds);class fs{constructor(t={}){this.algorithm="";Object.assign(this,t)}isEqual(t){return t instanceof fs&&t.algorithm==this.algorithm&&(t.parameters&&this.parameters&&n.isEqual(t.parameters,this.parameters)||t.parameters===this.parameters)}}gi([yi({type:Ne.ObjectIdentifier})],fs.prototype,"algorithm",void 0);gi([yi({type:Ne.Any,optional:true})],fs.prototype,"parameters",void 0);class ys{constructor(t={}){this.algorithm=new fs;this.subjectPublicKey=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:fs})],ys.prototype,"algorithm",void 0);gi([yi({type:Ne.BitString})],ys.prototype,"subjectPublicKey",void 0);let Ss=class t{constructor(t){if(t){if(typeof t==="string"||typeof t==="number"||t instanceof Date){const e=new Date(t);if(e.getUTCFullYear()>2049){this.generalTime=e}else{this.utcTime=e}}else{Object.assign(this,t)}}}getTime(){const t=this.utcTime||this.generalTime;if(!t){throw new Error("Cannot get time from CHOICE object")}return t}};gi([yi({type:Ne.UTCTime})],Ss.prototype,"utcTime",void 0);gi([yi({type:Ne.GeneralizedTime})],Ss.prototype,"generalTime",void 0);Ss=gi([fi({type:Me.Choice})],Ss);class As{constructor(t){this.notBefore=new Ss(new Date);this.notAfter=new Ss(new Date);if(t){this.notBefore=new Ss(t.notBefore);this.notAfter=new Ss(t.notAfter)}}}gi([yi({type:Ss})],As.prototype,"notBefore",void 0);gi([yi({type:Ss})],As.prototype,"notAfter",void 0);var Cs;let vs=class t{constructor(e={}){this.extnID="";this.critical=t.CRITICAL;this.extnValue=new Ke;Object.assign(this,e)}};vs.CRITICAL=false;gi([yi({type:Ne.ObjectIdentifier})],vs.prototype,"extnID",void 0);gi([yi({type:Ne.Boolean,defaultValue:vs.CRITICAL})],vs.prototype,"critical",void 0);gi([yi({type:Ke})],vs.prototype,"extnValue",void 0);let ms=Cs=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Cs.prototype)}};ms=Cs=gi([fi({type:Me.Sequence,itemType:vs})],ms);var gs;(function(t){t[t["v1"]=0]="v1";t[t["v2"]=1]="v2";t[t["v3"]=2]="v3"})(gs||(gs={}));class ws{constructor(t={}){this.version=gs.v1;this.serialNumber=new ArrayBuffer(0);this.signature=new fs;this.issuer=new Oi;this.validity=new As;this.subject=new Oi;this.subjectPublicKeyInfo=new ys;Object.assign(this,t)}}gi([yi({type:Ne.Integer,context:0,defaultValue:gs.v1})],ws.prototype,"version",void 0);gi([yi({type:Ne.Integer,converter:_e})],ws.prototype,"serialNumber",void 0);gi([yi({type:fs})],ws.prototype,"signature",void 0);gi([yi({type:Oi})],ws.prototype,"issuer",void 0);gi([yi({type:As})],ws.prototype,"validity",void 0);gi([yi({type:Oi})],ws.prototype,"subject",void 0);gi([yi({type:ys})],ws.prototype,"subjectPublicKeyInfo",void 0);gi([yi({type:Ne.BitString,context:1,implicit:true,optional:true})],ws.prototype,"issuerUniqueID",void 0);gi([yi({type:Ne.BitString,context:2,implicit:true,optional:true})],ws.prototype,"subjectUniqueID",void 0);gi([yi({type:ms,context:3,optional:true})],ws.prototype,"extensions",void 0);class Es{constructor(t={}){this.tbsCertificate=new ws;this.signatureAlgorithm=new fs;this.signatureValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:ws})],Es.prototype,"tbsCertificate",void 0);gi([yi({type:fs})],Es.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ne.BitString})],Es.prototype,"signatureValue",void 0);class Ps{constructor(t={}){this.userCertificate=new ArrayBuffer(0);this.revocationDate=new Ss;Object.assign(this,t)}}gi([yi({type:Ne.Integer,converter:_e})],Ps.prototype,"userCertificate",void 0);gi([yi({type:Ss})],Ps.prototype,"revocationDate",void 0);gi([yi({type:vs,optional:true,repeated:"sequence"})],Ps.prototype,"crlEntryExtensions",void 0);class Ds{constructor(t={}){this.signature=new fs;this.issuer=new Oi;this.thisUpdate=new Ss;Object.assign(this,t)}}gi([yi({type:Ne.Integer,optional:true})],Ds.prototype,"version",void 0);gi([yi({type:fs})],Ds.prototype,"signature",void 0);gi([yi({type:Oi})],Ds.prototype,"issuer",void 0);gi([yi({type:Ss})],Ds.prototype,"thisUpdate",void 0);gi([yi({type:Ss,optional:true})],Ds.prototype,"nextUpdate",void 0);gi([yi({type:Ps,repeated:"sequence",optional:true})],Ds.prototype,"revokedCertificates",void 0);gi([yi({type:vs,optional:true,context:0,repeated:"sequence"})],Ds.prototype,"crlExtensions",void 0);class bs{constructor(t={}){this.tbsCertList=new Ds;this.signatureAlgorithm=new fs;this.signature=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ds})],bs.prototype,"tbsCertList",void 0);gi([yi({type:fs})],bs.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ne.BitString})],bs.prototype,"signature",void 0);const Bs="1.2.840.10045.2.1";const Is="1.2.840.10045.4.1";const xs="1.2.840.10045.4.3.1";const Ts="1.2.840.10045.4.3.2";const Os="1.2.840.10045.4.3.3";const Rs="1.2.840.10045.4.3.4";function Ms(t){return new fs({algorithm:t})}Ms(Is);Ms(xs);Ms(Ts);Ms(Os);Ms(Rs);let Ns=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.ObjectIdentifier})],Ns.prototype,"fieldType",void 0);gi([yi({type:Ne.Any})],Ns.prototype,"parameters",void 0);Ns=gi([fi({type:Me.Sequence})],Ns);class ks extends Ke{}let Ks=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.OctetString})],Ks.prototype,"a",void 0);gi([yi({type:Ne.OctetString})],Ks.prototype,"b",void 0);gi([yi({type:Ne.BitString,optional:true})],Ks.prototype,"seed",void 0);Ks=gi([fi({type:Me.Sequence})],Ks);var Hs;(function(t){t[t["ecpVer1"]=1]="ecpVer1"})(Hs||(Hs={}));let js=class t{constructor(t={}){this.version=Hs.ecpVer1;Object.assign(this,t)}};gi([yi({type:Ne.Integer})],js.prototype,"version",void 0);gi([yi({type:Ns})],js.prototype,"fieldID",void 0);gi([yi({type:Ks})],js.prototype,"curve",void 0);gi([yi({type:ks})],js.prototype,"base",void 0);gi([yi({type:Ne.Integer,converter:_e})],js.prototype,"order",void 0);gi([yi({type:Ne.Integer,optional:true})],js.prototype,"cofactor",void 0);js=gi([fi({type:Me.Sequence})],js);let Us=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.ObjectIdentifier})],Us.prototype,"namedCurve",void 0);gi([yi({type:Ne.Null})],Us.prototype,"implicitCurve",void 0);gi([yi({type:js})],Us.prototype,"specifiedCurve",void 0);Us=gi([fi({type:Me.Choice})],Us);class _s{constructor(t={}){this.version=1;this.privateKey=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],_s.prototype,"version",void 0);gi([yi({type:Ke})],_s.prototype,"privateKey",void 0);gi([yi({type:Us,context:0,optional:true})],_s.prototype,"parameters",void 0);gi([yi({type:Ne.BitString,context:1,optional:true})],_s.prototype,"publicKey",void 0);class Fs{constructor(t={}){this.r=new ArrayBuffer(0);this.s=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer,converter:_e})],Fs.prototype,"r",void 0);gi([yi({type:Ne.Integer,converter:_e})],Fs.prototype,"s",void 0);const Vs="1.2.840.113549.1.1";const Ls=`${Vs}.1`;const $s=`${Vs}.7`;const Gs=`${Vs}.9`;const Ws=`${Vs}.10`;const Qs=`${Vs}.2`;const qs=`${Vs}.4`;const zs=`${Vs}.5`;const Js=`${Vs}.12`;const Zs=`${Vs}.13`;const Xs=`${Vs}.15`;const Ys=`${Vs}.16`;const tn="1.3.14.3.2.26";const en="2.16.840.1.101.3.4.2.4";const rn="2.16.840.1.101.3.4.2.1";const sn="2.16.840.1.101.3.4.2.2";const nn="2.16.840.1.101.3.4.2.3";const on="2.16.840.1.101.3.4.2.5";const an="2.16.840.1.101.3.4.2.6";const cn="1.2.840.113549.2.2";const un="1.2.840.113549.2.5";const ln=`${Vs}.8`;function pn(t){return new fs({algorithm:t,parameters:null})}pn(cn);pn(un);const hn=pn(tn);pn(en);pn(rn);pn(sn);pn(nn);pn(on);pn(an);const dn=new fs({algorithm:ln,parameters:mi.serialize(hn)});const fn=new fs({algorithm:Gs,parameters:mi.serialize($e.toASN(new Uint8Array([218,57,163,238,94,107,75,13,50,85,191,239,149,96,24,144,175,216,7,9]).buffer))});pn(Ls);pn(Qs);pn(qs);pn(zs);pn(Xs);pn(Ys);pn(Js);pn(Zs);pn(Xs);pn(Ys);class yn{constructor(t={}){this.hashAlgorithm=new fs(hn);this.maskGenAlgorithm=new fs({algorithm:ln,parameters:mi.serialize(hn)});this.pSourceAlgorithm=new fs(fn);Object.assign(this,t)}}gi([yi({type:fs,context:0,defaultValue:hn})],yn.prototype,"hashAlgorithm",void 0);gi([yi({type:fs,context:1,defaultValue:dn})],yn.prototype,"maskGenAlgorithm",void 0);gi([yi({type:fs,context:2,defaultValue:fn})],yn.prototype,"pSourceAlgorithm",void 0);new fs({algorithm:$s,parameters:mi.serialize(new yn)});class Sn{constructor(t={}){this.hashAlgorithm=new fs(hn);this.maskGenAlgorithm=new fs({algorithm:ln,parameters:mi.serialize(hn)});this.saltLength=20;this.trailerField=1;Object.assign(this,t)}}gi([yi({type:fs,context:0,defaultValue:hn})],Sn.prototype,"hashAlgorithm",void 0);gi([yi({type:fs,context:1,defaultValue:dn})],Sn.prototype,"maskGenAlgorithm",void 0);gi([yi({type:Ne.Integer,context:2,defaultValue:20})],Sn.prototype,"saltLength",void 0);gi([yi({type:Ne.Integer,context:3,defaultValue:1})],Sn.prototype,"trailerField",void 0);new fs({algorithm:Ws,parameters:mi.serialize(new Sn)});class An{constructor(t={}){this.digestAlgorithm=new fs;this.digest=new Ke;Object.assign(this,t)}}gi([yi({type:fs})],An.prototype,"digestAlgorithm",void 0);gi([yi({type:Ke})],An.prototype,"digest",void 0);var Cn;class vn{constructor(t={}){this.prime=new ArrayBuffer(0);this.exponent=new ArrayBuffer(0);this.coefficient=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer,converter:_e})],vn.prototype,"prime",void 0);gi([yi({type:Ne.Integer,converter:_e})],vn.prototype,"exponent",void 0);gi([yi({type:Ne.Integer,converter:_e})],vn.prototype,"coefficient",void 0);let mn=Cn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Cn.prototype)}};mn=Cn=gi([fi({type:Me.Sequence,itemType:vn})],mn);class gn{constructor(t={}){this.version=0;this.modulus=new ArrayBuffer(0);this.publicExponent=new ArrayBuffer(0);this.privateExponent=new ArrayBuffer(0);this.prime1=new ArrayBuffer(0);this.prime2=new ArrayBuffer(0);this.exponent1=new ArrayBuffer(0);this.exponent2=new ArrayBuffer(0);this.coefficient=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer})],gn.prototype,"version",void 0);gi([yi({type:Ne.Integer,converter:_e})],gn.prototype,"modulus",void 0);gi([yi({type:Ne.Integer,converter:_e})],gn.prototype,"publicExponent",void 0);gi([yi({type:Ne.Integer,converter:_e})],gn.prototype,"privateExponent",void 0);gi([yi({type:Ne.Integer,converter:_e})],gn.prototype,"prime1",void 0);gi([yi({type:Ne.Integer,converter:_e})],gn.prototype,"prime2",void 0);gi([yi({type:Ne.Integer,converter:_e})],gn.prototype,"exponent1",void 0);gi([yi({type:Ne.Integer,converter:_e})],gn.prototype,"exponent2",void 0);gi([yi({type:Ne.Integer,converter:_e})],gn.prototype,"coefficient",void 0);gi([yi({type:mn,optional:true})],gn.prototype,"otherPrimeInfos",void 0);class wn{constructor(t={}){this.modulus=new ArrayBuffer(0);this.publicExponent=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer,converter:_e})],wn.prototype,"modulus",void 0);gi([yi({type:Ne.Integer,converter:_e})],wn.prototype,"publicExponent",void 0);var En,Pn;const Dn="1.3.6.1.4.1.18227.2.1";let bn=En=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,En.prototype)}};bn=En=gi([fi({type:Me.Sequence,itemType:fs})],bn);let Bn=Pn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Pn.prototype)}};Bn=Pn=gi([fi({type:Me.Sequence,itemType:Ne.BitString})],Bn);class In extends Ke{}let xn=class t{constructor(t={}){this.encryptionAlgorithm=new fs;this.encryptedData=new In;Object.assign(this,t)}};gi([yi({type:fs})],xn.prototype,"encryptionAlgorithm",void 0);gi([yi({type:In})],xn.prototype,"encryptedData",void 0);var Tn;var On;(function(t){t[t["v1"]=0]="v1"})(On||(On={}));class Rn extends Ke{}let Mn=Tn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Tn.prototype)}};Mn=Tn=gi([fi({type:Me.Sequence,itemType:Yr})],Mn);let Nn=class t{constructor(t={}){this.version=On.v1;this.privateKeyAlgorithm=new fs;this.privateKey=new Rn;Object.assign(this,t)}};gi([yi({type:Ne.Integer})],Nn.prototype,"version",void 0);gi([yi({type:fs})],Nn.prototype,"privateKeyAlgorithm",void 0);gi([yi({type:Rn})],Nn.prototype,"privateKey",void 0);gi([yi({type:Mn,implicit:true,context:0,optional:true})],Nn.prototype,"attributes",void 0);var kn;var Kn;(function(t){t[t["v1"]=0]="v1";t[t["v2"]=1]="v2"})(Kn||(Kn={}));let Hn=class t extends fs{};Hn=gi([fi({type:Me.Sequence})],Hn);let jn=class t{constructor(){this.version=Kn.v1;this.privateKeyAlgorithm=new fs;this.privateKey=new ArrayBuffer(0)}};gi([yi({type:Ne.Integer})],jn.prototype,"version",void 0);gi([yi({type:fs})],jn.prototype,"privateKeyAlgorithm",void 0);gi([yi({type:Ne.OctetString})],jn.prototype,"privateKey",void 0);gi([yi({type:Mn,context:0,implicit:true,optional:true})],jn.prototype,"attributes",void 0);gi([yi({type:Ne.BitString,context:1,implicit:true,optional:true})],jn.prototype,"publicKey",void 0);jn=gi([fi({type:Me.Sequence})],jn);let Un=class t extends jn{};Un=gi([fi({type:Me.Sequence})],Un);let _n=kn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,kn.prototype)}};_n=kn=gi([fi({type:Me.Sequence,itemType:jn})],_n);var Fn,Vn;const Ln="2.16.840.1.114027.80.4.1";let $n=class t extends fs{};$n=gi([fi({type:Me.Sequence})],$n);let Gn=Fn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Fn.prototype)}};Gn=Fn=gi([fi({type:Me.Sequence,itemType:ys})],Gn);let Wn=Vn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Vn.prototype)}};Wn=Vn=gi([fi({type:Me.Sequence,itemType:jn})],Wn);var Qn={exports:{}};var qn=Qn.exports;var zn;function Jn(){if(zn)return Qn.exports;zn=1;(function(t,e){!function(e,i){t.exports=i()}(qn,(function(){var t=1e3,e=6e4,i=36e5,r="millisecond",s="second",n="minute",o="hour",a="day",c="week",u="month",l="quarter",p="year",h="date",d="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,S={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],i=t%100;return"["+t+(e[(i-20)%10]||e[i]||e[0])+"]"}},A=function(t,e,i){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(i)+t},C={s:A,z:function(t){var e=-t.utcOffset(),i=Math.abs(e),r=Math.floor(i/60),s=i%60;return(e<=0?"+":"-")+A(r,2,"0")+":"+A(s,2,"0")},m:function t(e,i){if(e.date()<i.date())return-t(i,e);var r=12*(i.year()-e.year())+(i.month()-e.month()),s=e.clone().add(r,u),n=i-s<0,o=e.clone().add(r+(n?-1:1),u);return+(-(r+(i-s)/(n?s-o:o-s))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:u,y:p,w:c,d:a,D:h,h:o,m:n,s,ms:r,Q:l}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},v="en",m={};m[v]=S;var g="$isDayjsObject",w=function(t){return t instanceof b||!(!t||!t[g])},E=function t(e,i,r){var s;if(!e)return v;if("string"==typeof e){var n=e.toLowerCase();m[n]&&(s=n),i&&(m[n]=i,s=n);var o=e.split("-");if(!s&&o.length>1)return t(o[0])}else{var a=e.name;m[a]=e,s=a}return!r&&s&&(v=s),s||!r&&v},P=function(t,e){if(w(t))return t.clone();var i="object"==typeof e?e:{};return i.date=t,i.args=arguments,new b(i)},D=C;D.l=E,D.i=w,D.w=function(t,e){return P(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var b=function(){function S(t){this.$L=E(t.locale,null,true),this.parse(t),this.$x=this.$x||t.x||{},this[g]=true}var A=S.prototype;return A.parse=function(t){this.$d=function(t){var e=t.date,i=t.utc;if(null===e)return new Date(NaN);if(D.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(f);if(r){var s=r[2]-1||0,n=(r[7]||"0").substring(0,3);return i?new Date(Date.UTC(r[1],s,r[3]||1,r[4]||0,r[5]||0,r[6]||0,n)):new Date(r[1],s,r[3]||1,r[4]||0,r[5]||0,r[6]||0,n)}}return new Date(e)}(t),this.init()},A.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},A.$utils=function(){return D},A.isValid=function(){return!(this.$d.toString()===d)},A.isSame=function(t,e){var i=P(t);return this.startOf(e)<=i&&i<=this.endOf(e)},A.isAfter=function(t,e){return P(t)<this.startOf(e)},A.isBefore=function(t,e){return this.endOf(e)<P(t)},A.$g=function(t,e,i){return D.u(t)?this[e]:this.set(i,t)},A.unix=function(){return Math.floor(this.valueOf()/1e3)},A.valueOf=function(){return this.$d.getTime()},A.startOf=function(t,e){var i=this,r=!!D.u(e)||e,l=D.p(t),d=function(t,e){var s=D.w(i.$u?Date.UTC(i.$y,e,t):new Date(i.$y,e,t),i);return r?s:s.endOf(a)},f=function(t,e){return D.w(i.toDate()[t].apply(i.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),i)},y=this.$W,S=this.$M,A=this.$D,C="set"+(this.$u?"UTC":"");switch(l){case p:return r?d(1,0):d(31,11);case u:return r?d(1,S):d(0,S+1);case c:var v=this.$locale().weekStart||0,m=(y<v?y+7:y)-v;return d(r?A-m:A+(6-m),S);case a:case h:return f(C+"Hours",0);case o:return f(C+"Minutes",1);case n:return f(C+"Seconds",2);case s:return f(C+"Milliseconds",3);default:return this.clone()}},A.endOf=function(t){return this.startOf(t,false)},A.$set=function(t,e){var i,c=D.p(t),l="set"+(this.$u?"UTC":""),d=(i={},i[a]=l+"Date",i[h]=l+"Date",i[u]=l+"Month",i[p]=l+"FullYear",i[o]=l+"Hours",i[n]=l+"Minutes",i[s]=l+"Seconds",i[r]=l+"Milliseconds",i)[c],f=c===a?this.$D+(e-this.$W):e;if(c===u||c===p){var y=this.clone().set(h,1);y.$d[d](f),y.init(),this.$d=y.set(h,Math.min(this.$D,y.daysInMonth())).$d}else d&&this.$d[d](f);return this.init(),this},A.set=function(t,e){return this.clone().$set(t,e)},A.get=function(t){return this[D.p(t)]()},A.add=function(r,l){var h,d=this;r=Number(r);var f=D.p(l),y=function(t){var e=P(d);return D.w(e.date(e.date()+Math.round(t*r)),d)};if(f===u)return this.set(u,this.$M+r);if(f===p)return this.set(p,this.$y+r);if(f===a)return y(1);if(f===c)return y(7);var S=(h={},h[n]=e,h[o]=i,h[s]=t,h)[f]||1,A=this.$d.getTime()+r*S;return D.w(A,this)},A.subtract=function(t,e){return this.add(-1*t,e)},A.format=function(t){var e=this,i=this.$locale();if(!this.isValid())return i.invalidDate||d;var r=t||"YYYY-MM-DDTHH:mm:ssZ",s=D.z(this),n=this.$H,o=this.$m,a=this.$M,c=i.weekdays,u=i.months,l=i.meridiem,p=function(t,i,s,n){return t&&(t[i]||t(e,r))||s[i].slice(0,n)},h=function(t){return D.s(n%12||12,t,"0")},f=l||function(t,e,i){var r=t<12?"AM":"PM";return i?r.toLowerCase():r};return r.replace(y,(function(t,r){return r||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return D.s(e.$y,4,"0");case"M":return a+1;case"MM":return D.s(a+1,2,"0");case"MMM":return p(i.monthsShort,a,u,3);case"MMMM":return p(u,a);case"D":return e.$D;case"DD":return D.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return p(i.weekdaysMin,e.$W,c,2);case"ddd":return p(i.weekdaysShort,e.$W,c,3);case"dddd":return c[e.$W];case"H":return String(n);case"HH":return D.s(n,2,"0");case"h":return h(1);case"hh":return h(2);case"a":return f(n,o,true);case"A":return f(n,o,false);case"m":return String(o);case"mm":return D.s(o,2,"0");case"s":return String(e.$s);case"ss":return D.s(e.$s,2,"0");case"SSS":return D.s(e.$ms,3,"0");case"Z":return s}return null}(t)||s.replace(":","")}))},A.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},A.diff=function(r,h,d){var f,y=this,S=D.p(h),A=P(r),C=(A.utcOffset()-this.utcOffset())*e,v=this-A,m=function(){return D.m(y,A)};switch(S){case p:f=m()/12;break;case u:f=m();break;case l:f=m()/3;break;case c:f=(v-C)/6048e5;break;case a:f=(v-C)/864e5;break;case o:f=v/i;break;case n:f=v/e;break;case s:f=v/t;break;default:f=v}return d?f:D.a(f)},A.daysInMonth=function(){return this.endOf(u).$D},A.$locale=function(){return m[this.$L]},A.locale=function(t,e){if(!t)return this.$L;var i=this.clone(),r=E(t,e,true);return r&&(i.$L=r),i},A.clone=function(){return D.w(this.$d,this)},A.toDate=function(){return new Date(this.valueOf())},A.toJSON=function(){return this.isValid()?this.toISOString():null},A.toISOString=function(){return this.$d.toISOString()},A.toString=function(){return this.$d.toUTCString()},S}(),B=b.prototype;return P.prototype=B,[["$ms",r],["$s",s],["$m",n],["$H",o],["$W",a],["$M",u],["$y",p],["$D",h]].forEach((function(t){B[t[1]]=function(e){return this.$g(e,t[0],t[1])}})),P.extend=function(t,e){return t.$i||(t(e,b,P),t.$i=true),P},P.locale=E,P.isDayjs=w,P.unix=function(t){return P(1e3*t)},P.en=m[v],P.Ls=m,P.p={},P}))})(Qn);return Qn.exports}var Zn=Jn();var Xn=e(Zn);var Yn={exports:{}};var to=Yn.exports;var eo;function io(){if(eo)return Yn.exports;eo=1;(function(t,e){!function(e,i){t.exports=i()}(to,(function(){return function(t,e,i){t=t||{};var r=e.prototype,s={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function n(t,e,i,s){return r.fromToBase(t,e,i,s)}i.en.relativeTime=s,r.fromToBase=function(e,r,n,o,a){for(var c,u,l,p=n.$locale().relativeTime||s,h=t.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],d=h.length,f=0;f<d;f+=1){var y=h[f];y.d&&(c=o?i(e).diff(n,y.d,true):n.diff(e,y.d,true));var S=(t.rounding||Math.round)(Math.abs(c));if(l=c>0,S<=y.r||!y.r){S<=1&&f>0&&(y=h[f-1]);var A=p[y.l];a&&(S=a(""+S)),u="string"==typeof A?A.replace("%d",S):A(S,r,y.l,l);break}}if(r)return u;var C=l?p.future:p.past;return"function"==typeof C?C(u):C.replace("%s",u)},r.to=function(t,e){return n(t,e,this,true)},r.from=function(t,e){return n(t,e,this)};var o=function(t){return t.$u?i.utc():i()};r.toNow=function(t){return this.to(o(this),t)},r.fromNow=function(t){return this.from(o(this),t)}}}))})(Yn);return Yn.exports}var ro=io();var so=e(ro);
|
|
78
|
+
*/function f(){if(typeof BigInt==="undefined"){throw new Error("BigInt is not defined. Your environment doesn't implement BigInt.")}}function y(t){let e=0;let i=0;for(let i=0;i<t.length;i++){const r=t[i];e+=r.byteLength}const r=new Uint8Array(e);for(let e=0;e<t.length;e++){const s=t[e];r.set(new Uint8Array(s),i);i+=s.byteLength}return r.buffer}function S(t,e,i,r){if(!(e instanceof Uint8Array)){t.error="Wrong parameter: inputBuffer must be 'Uint8Array'";return false}if(!e.byteLength){t.error="Wrong parameter: inputBuffer has zero length";return false}if(i<0){t.error="Wrong parameter: inputOffset less than zero";return false}if(r<0){t.error="Wrong parameter: inputLength less than zero";return false}if(e.byteLength-i-r<0){t.error="End of input reached before message was fully decoded (inconsistent offset and length values)";return false}return true}class A{constructor(){this.items=[]}write(t){this.items.push(t)}final(){return y(this.items)}}const C=[new Uint8Array([1])];const v="0123456789";const m="name";const g="valueHexView";const w="isHexOnly";const E="idBlock";const P="tagClass";const D="tagNumber";const b="isConstructed";const B="fromBER";const I="toBER";const x="local";const T="";const O=new ArrayBuffer(0);const R=new Uint8Array(0);const M="EndOfContent";const N="OCTET STRING";const k="BIT STRING";function K(t){var e;return e=class e extends t{get valueHex(){return this.valueHexView.slice().buffer}set valueHex(t){this.valueHexView=new Uint8Array(t)}constructor(...t){var e;super(...t);const i=t[0]||{};this.isHexOnly=(e=i.isHexOnly)!==null&&e!==void 0?e:false;this.valueHexView=i.valueHex?n.BufferSourceConverter.toUint8Array(i.valueHex):R}fromBER(t,e,i){const r=t instanceof ArrayBuffer?new Uint8Array(t):t;if(!S(this,r,e,i)){return-1}const s=e+i;this.valueHexView=r.subarray(e,s);if(!this.valueHexView.length){this.warnings.push("Zero buffer length");return e}this.blockLength=i;return s}toBER(t=false){if(!this.isHexOnly){this.error="Flag 'isHexOnly' is not set, abort";return O}if(t){return new ArrayBuffer(this.valueHexView.byteLength)}return this.valueHexView.byteLength===this.valueHexView.buffer.byteLength?this.valueHexView.buffer:this.valueHexView.slice().buffer}toJSON(){return{...super.toJSON(),isHexOnly:this.isHexOnly,valueHex:n.Convert.ToHex(this.valueHexView)}}},e.NAME="hexBlock",e}class H{static blockName(){return this.NAME}get valueBeforeDecode(){return this.valueBeforeDecodeView.slice().buffer}set valueBeforeDecode(t){this.valueBeforeDecodeView=new Uint8Array(t)}constructor({blockLength:t=0,error:e=T,warnings:i=[],valueBeforeDecode:r=R}={}){this.blockLength=t;this.error=e;this.warnings=i;this.valueBeforeDecodeView=n.BufferSourceConverter.toUint8Array(r)}toJSON(){return{blockName:this.constructor.NAME,blockLength:this.blockLength,error:this.error,warnings:this.warnings,valueBeforeDecode:n.Convert.ToHex(this.valueBeforeDecodeView)}}}H.NAME="baseBlock";class j extends H{fromBER(t,e,i){throw TypeError("User need to make a specific function in a class which extends 'ValueBlock'")}toBER(t,e){throw TypeError("User need to make a specific function in a class which extends 'ValueBlock'")}}j.NAME="valueBlock";class U extends(K(H)){constructor({idBlock:t={}}={}){var e,i,r,s;super();if(t){this.isHexOnly=(e=t.isHexOnly)!==null&&e!==void 0?e:false;this.valueHexView=t.valueHex?n.BufferSourceConverter.toUint8Array(t.valueHex):R;this.tagClass=(i=t.tagClass)!==null&&i!==void 0?i:-1;this.tagNumber=(r=t.tagNumber)!==null&&r!==void 0?r:-1;this.isConstructed=(s=t.isConstructed)!==null&&s!==void 0?s:false}else{this.tagClass=-1;this.tagNumber=-1;this.isConstructed=false}}toBER(t=false){let e=0;switch(this.tagClass){case 1:e|=0;break;case 2:e|=64;break;case 3:e|=128;break;case 4:e|=192;break;default:this.error="Unknown tag class";return O}if(this.isConstructed)e|=32;if(this.tagNumber<31&&!this.isHexOnly){const i=new Uint8Array(1);if(!t){let t=this.tagNumber;t&=31;e|=t;i[0]=e}return i.buffer}if(!this.isHexOnly){const i=c(this.tagNumber,7);const r=new Uint8Array(i);const s=i.byteLength;const n=new Uint8Array(s+1);n[0]=e|31;if(!t){for(let t=0;t<s-1;t++)n[t+1]=r[t]|128;n[s]=r[s-1]}return n.buffer}const i=new Uint8Array(this.valueHexView.byteLength+1);i[0]=e|31;if(!t){const t=this.valueHexView;for(let e=0;e<t.length-1;e++)i[e+1]=t[e]|128;i[this.valueHexView.byteLength]=t[t.length-1]}return i.buffer}fromBER(t,e,i){const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}const s=r.subarray(e,e+i);if(s.length===0){this.error="Zero buffer length";return-1}const o=s[0]&192;switch(o){case 0:this.tagClass=1;break;case 64:this.tagClass=2;break;case 128:this.tagClass=3;break;case 192:this.tagClass=4;break;default:this.error="Unknown tag class";return-1}this.isConstructed=(s[0]&32)===32;this.isHexOnly=false;const c=s[0]&31;if(c!==31){this.tagNumber=c;this.blockLength=1}else{let t=1;let e=this.valueHexView=new Uint8Array(255);let i=255;while(s[t]&128){e[t-1]=s[t]&127;t++;if(t>=s.length){this.error="End of input reached before message was fully decoded";return-1}if(t===i){i+=255;const t=new Uint8Array(i);for(let i=0;i<e.length;i++)t[i]=e[i];e=this.valueHexView=new Uint8Array(i)}}this.blockLength=t+1;e[t-1]=s[t]&127;const r=new Uint8Array(t);for(let i=0;i<t;i++)r[i]=e[i];e=this.valueHexView=new Uint8Array(t);e.set(r);if(this.blockLength<=9)this.tagNumber=a(e,7);else{this.isHexOnly=true;this.warnings.push("Tag too long, represented as hex-coded")}}if(this.tagClass===1&&this.isConstructed){switch(this.tagNumber){case 1:case 2:case 5:case 6:case 9:case 13:case 14:case 23:case 24:case 31:case 32:case 33:case 34:this.error="Constructed encoding used for primitive type";return-1}}return e+this.blockLength}toJSON(){return{...super.toJSON(),tagClass:this.tagClass,tagNumber:this.tagNumber,isConstructed:this.isConstructed}}}U.NAME="identificationBlock";class F extends H{constructor({lenBlock:t={}}={}){var e,i,r;super();this.isIndefiniteForm=(e=t.isIndefiniteForm)!==null&&e!==void 0?e:false;this.longFormUsed=(i=t.longFormUsed)!==null&&i!==void 0?i:false;this.length=(r=t.length)!==null&&r!==void 0?r:0}fromBER(t,e,i){const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}const s=r.subarray(e,e+i);if(s.length===0){this.error="Zero buffer length";return-1}if(s[0]===255){this.error="Length block 0xFF is reserved by standard";return-1}this.isIndefiniteForm=s[0]===128;if(this.isIndefiniteForm){this.blockLength=1;return e+this.blockLength}this.longFormUsed=!!(s[0]&128);if(this.longFormUsed===false){this.length=s[0];this.blockLength=1;return e+this.blockLength}const o=s[0]&127;if(o>8){this.error="Too big integer";return-1}if(o+1>s.length){this.error="End of input reached before message was fully decoded";return-1}const c=e+1;const u=r.subarray(c,c+o);if(u[o-1]===0)this.warnings.push("Needlessly long encoded length");this.length=a(u,8);if(this.longFormUsed&&this.length<=127)this.warnings.push("Unnecessary usage of long length form");this.blockLength=o+1;return e+this.blockLength}toBER(t=false){let e;let i;if(this.length>127)this.longFormUsed=true;if(this.isIndefiniteForm){e=new ArrayBuffer(1);if(t===false){i=new Uint8Array(e);i[0]=128}return e}if(this.longFormUsed){const r=c(this.length,8);if(r.byteLength>127){this.error="Too big length";return O}e=new ArrayBuffer(r.byteLength+1);if(t)return e;const s=new Uint8Array(r);i=new Uint8Array(e);i[0]=r.byteLength|128;for(let t=0;t<r.byteLength;t++)i[t+1]=s[t];return e}e=new ArrayBuffer(1);if(t===false){i=new Uint8Array(e);i[0]=this.length}return e}toJSON(){return{...super.toJSON(),isIndefiniteForm:this.isIndefiniteForm,longFormUsed:this.longFormUsed,length:this.length}}}F.NAME="lengthBlock";const _={};class V extends H{constructor({name:t=T,optional:e=false,primitiveSchema:i,...r}={},s){super(r);this.name=t;this.optional=e;if(i){this.primitiveSchema=i}this.idBlock=new U(r);this.lenBlock=new F(r);this.valueBlock=s?new s(r):new j(r)}fromBER(t,e,i){const r=this.valueBlock.fromBER(t,e,this.lenBlock.isIndefiniteForm?i:this.lenBlock.length);if(r===-1){this.error=this.valueBlock.error;return r}if(!this.idBlock.error.length)this.blockLength+=this.idBlock.blockLength;if(!this.lenBlock.error.length)this.blockLength+=this.lenBlock.blockLength;if(!this.valueBlock.error.length)this.blockLength+=this.valueBlock.blockLength;return r}toBER(t,e){const i=e||new A;if(!e){L(this)}const r=this.idBlock.toBER(t);i.write(r);if(this.lenBlock.isIndefiniteForm){i.write(new Uint8Array([128]).buffer);this.valueBlock.toBER(t,i);i.write(new ArrayBuffer(2))}else{const e=this.valueBlock.toBER(t);this.lenBlock.length=e.byteLength;const r=this.lenBlock.toBER(t);i.write(r);i.write(e)}if(!e){return i.final()}return O}toJSON(){const t={...super.toJSON(),idBlock:this.idBlock.toJSON(),lenBlock:this.lenBlock.toJSON(),valueBlock:this.valueBlock.toJSON(),name:this.name,optional:this.optional};if(this.primitiveSchema)t.primitiveSchema=this.primitiveSchema.toJSON();return t}toString(t="ascii"){if(t==="ascii"){return this.onAsciiEncoding()}return n.Convert.ToHex(this.toBER())}onAsciiEncoding(){const t=this.constructor.NAME;const e=n.Convert.ToHex(this.valueBlock.valueBeforeDecodeView);return`${t} : ${e}`}isEqual(t){if(this===t){return true}if(!(t instanceof this.constructor)){return false}const e=this.toBER();const i=t.toBER();return h(e,i)}}V.NAME="BaseBlock";function L(t){var e;if(t instanceof _.Constructed){for(const e of t.valueBlock.value){if(L(e)){t.lenBlock.isIndefiniteForm=true}}}return!!((e=t.lenBlock)===null||e===void 0?void 0:e.isIndefiniteForm)}class $ extends V{getValue(){return this.valueBlock.value}setValue(t){this.valueBlock.value=t}constructor({value:t=T,...e}={},i){super(e,i);if(t){this.fromString(t)}}fromBER(t,e,i){const r=this.valueBlock.fromBER(t,e,this.lenBlock.isIndefiniteForm?i:this.lenBlock.length);if(r===-1){this.error=this.valueBlock.error;return r}this.fromBuffer(this.valueBlock.valueHexView);if(!this.idBlock.error.length)this.blockLength+=this.idBlock.blockLength;if(!this.lenBlock.error.length)this.blockLength+=this.lenBlock.blockLength;if(!this.valueBlock.error.length)this.blockLength+=this.valueBlock.blockLength;return r}onAsciiEncoding(){return`${this.constructor.NAME} : '${this.valueBlock.value}'`}}$.NAME="BaseStringBlock";class G extends(K(j)){constructor({isHexOnly:t=true,...e}={}){super(e);this.isHexOnly=t}}G.NAME="PrimitiveValueBlock";var W;class Q extends V{constructor(t={}){super(t,G);this.idBlock.isConstructed=false}}W=Q;(()=>{_.Primitive=W})();Q.NAME="PRIMITIVE";function q(t,e){if(t instanceof e){return t}const i=new e;i.idBlock=t.idBlock;i.lenBlock=t.lenBlock;i.warnings=t.warnings;i.valueBeforeDecodeView=t.valueBeforeDecodeView;return i}function z(t,e=0,i=t.length){const r=e;let s=new V({},j);const n=new H;if(!S(n,t,e,i)){s.error=n.error;return{offset:-1,result:s}}const o=t.subarray(e,e+i);if(!o.length){s.error="Zero buffer length";return{offset:-1,result:s}}let a=s.idBlock.fromBER(t,e,i);if(s.idBlock.warnings.length){s.warnings.concat(s.idBlock.warnings)}if(a===-1){s.error=s.idBlock.error;return{offset:-1,result:s}}e=a;i-=s.idBlock.blockLength;a=s.lenBlock.fromBER(t,e,i);if(s.lenBlock.warnings.length){s.warnings.concat(s.lenBlock.warnings)}if(a===-1){s.error=s.lenBlock.error;return{offset:-1,result:s}}e=a;i-=s.lenBlock.blockLength;if(!s.idBlock.isConstructed&&s.lenBlock.isIndefiniteForm){s.error="Indefinite length form used for primitive encoding form";return{offset:-1,result:s}}let c=V;switch(s.idBlock.tagClass){case 1:if(s.idBlock.tagNumber>=37&&s.idBlock.isHexOnly===false){s.error="UNIVERSAL 37 and upper tags are reserved by ASN.1 standard";return{offset:-1,result:s}}switch(s.idBlock.tagNumber){case 0:if(s.idBlock.isConstructed&&s.lenBlock.length>0){s.error="Type [UNIVERSAL 0] is reserved";return{offset:-1,result:s}}c=_.EndOfContent;break;case 1:c=_.Boolean;break;case 2:c=_.Integer;break;case 3:c=_.BitString;break;case 4:c=_.OctetString;break;case 5:c=_.Null;break;case 6:c=_.ObjectIdentifier;break;case 10:c=_.Enumerated;break;case 12:c=_.Utf8String;break;case 13:c=_.RelativeObjectIdentifier;break;case 14:c=_.TIME;break;case 15:s.error="[UNIVERSAL 15] is reserved by ASN.1 standard";return{offset:-1,result:s};case 16:c=_.Sequence;break;case 17:c=_.Set;break;case 18:c=_.NumericString;break;case 19:c=_.PrintableString;break;case 20:c=_.TeletexString;break;case 21:c=_.VideotexString;break;case 22:c=_.IA5String;break;case 23:c=_.UTCTime;break;case 24:c=_.GeneralizedTime;break;case 25:c=_.GraphicString;break;case 26:c=_.VisibleString;break;case 27:c=_.GeneralString;break;case 28:c=_.UniversalString;break;case 29:c=_.CharacterString;break;case 30:c=_.BmpString;break;case 31:c=_.DATE;break;case 32:c=_.TimeOfDay;break;case 33:c=_.DateTime;break;case 34:c=_.Duration;break;default:{const t=s.idBlock.isConstructed?new _.Constructed:new _.Primitive;t.idBlock=s.idBlock;t.lenBlock=s.lenBlock;t.warnings=s.warnings;s=t}}break;case 2:case 3:case 4:default:{c=s.idBlock.isConstructed?_.Constructed:_.Primitive}}s=q(s,c);a=s.fromBER(t,e,s.lenBlock.isIndefiniteForm?i:s.lenBlock.length);s.valueBeforeDecodeView=t.subarray(r,r+s.blockLength);return{offset:a,result:s}}function J(t){if(!t.byteLength){const t=new V({},j);t.error="Input buffer has zero length";return{offset:-1,result:t}}return z(n.BufferSourceConverter.toUint8Array(t).slice(),0,t.byteLength)}function Z(t,e){if(t){return 1}return e}class X extends j{constructor({value:t=[],isIndefiniteForm:e=false,...i}={}){super(i);this.value=t;this.isIndefiniteForm=e}fromBER(t,e,i){const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}this.valueBeforeDecodeView=r.subarray(e,e+i);if(this.valueBeforeDecodeView.length===0){this.warnings.push("Zero buffer length");return e}let s=e;while(Z(this.isIndefiniteForm,i)>0){const t=z(r,s,i);if(t.offset===-1){this.error=t.result.error;this.warnings.concat(t.result.warnings);return-1}s=t.offset;this.blockLength+=t.result.blockLength;i-=t.result.blockLength;this.value.push(t.result);if(this.isIndefiniteForm&&t.result.constructor.NAME===M){break}}if(this.isIndefiniteForm){if(this.value[this.value.length-1].constructor.NAME===M){this.value.pop()}else{this.warnings.push("No EndOfContent block encoded")}}return s}toBER(t,e){const i=e||new A;for(let e=0;e<this.value.length;e++){this.value[e].toBER(t,i)}if(!e){return i.final()}return O}toJSON(){const t={...super.toJSON(),isIndefiniteForm:this.isIndefiniteForm,value:[]};for(const e of this.value){t.value.push(e.toJSON())}return t}}X.NAME="ConstructedValueBlock";var Y;class tt extends V{constructor(t={}){super(t,X);this.idBlock.isConstructed=true}fromBER(t,e,i){this.valueBlock.isIndefiniteForm=this.lenBlock.isIndefiniteForm;const r=this.valueBlock.fromBER(t,e,this.lenBlock.isIndefiniteForm?i:this.lenBlock.length);if(r===-1){this.error=this.valueBlock.error;return r}if(!this.idBlock.error.length)this.blockLength+=this.idBlock.blockLength;if(!this.lenBlock.error.length)this.blockLength+=this.lenBlock.blockLength;if(!this.valueBlock.error.length)this.blockLength+=this.valueBlock.blockLength;return r}onAsciiEncoding(){const t=[];for(const e of this.valueBlock.value){t.push(e.toString("ascii").split("\n").map((t=>` ${t}`)).join("\n"))}const e=this.idBlock.tagClass===3?`[${this.idBlock.tagNumber}]`:this.constructor.NAME;return t.length?`${e} :\n${t.join("\n")}`:`${e} :`}}Y=tt;(()=>{_.Constructed=Y})();tt.NAME="CONSTRUCTED";class et extends j{fromBER(t,e,i){return e}toBER(t){return O}}et.override="EndOfContentValueBlock";var it;class rt extends V{constructor(t={}){super(t,et);this.idBlock.tagClass=1;this.idBlock.tagNumber=0}}it=rt;(()=>{_.EndOfContent=it})();rt.NAME=M;var st;class nt extends V{constructor(t={}){super(t,j);this.idBlock.tagClass=1;this.idBlock.tagNumber=5}fromBER(t,e,i){if(this.lenBlock.length>0)this.warnings.push("Non-zero length of value block for Null type");if(!this.idBlock.error.length)this.blockLength+=this.idBlock.blockLength;if(!this.lenBlock.error.length)this.blockLength+=this.lenBlock.blockLength;this.blockLength+=i;if(e+i>t.byteLength){this.error="End of input reached before message was fully decoded (inconsistent offset and length values)";return-1}return e+i}toBER(t,e){const i=new ArrayBuffer(2);if(!t){const t=new Uint8Array(i);t[0]=5;t[1]=0}if(e){e.write(i)}return i}onAsciiEncoding(){return`${this.constructor.NAME}`}}st=nt;(()=>{_.Null=st})();nt.NAME="NULL";class ot extends(K(j)){get value(){for(const t of this.valueHexView){if(t>0){return true}}return false}set value(t){this.valueHexView[0]=t?255:0}constructor({value:t,...e}={}){super(e);if(e.valueHex){this.valueHexView=n.BufferSourceConverter.toUint8Array(e.valueHex)}else{this.valueHexView=new Uint8Array(1)}if(t){this.value=t}}fromBER(t,e,i){const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}this.valueHexView=r.subarray(e,e+i);if(i>1)this.warnings.push("Boolean value encoded in more then 1 octet");this.isHexOnly=true;l.call(this);this.blockLength=i;return e+i}toBER(){return this.valueHexView.slice()}toJSON(){return{...super.toJSON(),value:this.value}}}ot.NAME="BooleanValueBlock";var at;class ct extends V{getValue(){return this.valueBlock.value}setValue(t){this.valueBlock.value=t}constructor(t={}){super(t,ot);this.idBlock.tagClass=1;this.idBlock.tagNumber=1}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.getValue}`}}at=ct;(()=>{_.Boolean=at})();ct.NAME="BOOLEAN";class ut extends(K(X)){constructor({isConstructed:t=false,...e}={}){super(e);this.isConstructed=t}fromBER(t,e,i){let r=0;if(this.isConstructed){this.isHexOnly=false;r=X.prototype.fromBER.call(this,t,e,i);if(r===-1)return r;for(let t=0;t<this.value.length;t++){const e=this.value[t].constructor.NAME;if(e===M){if(this.isIndefiniteForm)break;else{this.error="EndOfContent is unexpected, OCTET STRING may consists of OCTET STRINGs only";return-1}}if(e!==N){this.error="OCTET STRING may consists of OCTET STRINGs only";return-1}}}else{this.isHexOnly=true;r=super.fromBER(t,e,i);this.blockLength=i}return r}toBER(t,e){if(this.isConstructed)return X.prototype.toBER.call(this,t,e);return t?new ArrayBuffer(this.valueHexView.byteLength):this.valueHexView.slice().buffer}toJSON(){return{...super.toJSON(),isConstructed:this.isConstructed}}}ut.NAME="OctetStringValueBlock";var lt;let pt=class t extends V{constructor({idBlock:t={},lenBlock:e={},...i}={}){var r,s;(r=i.isConstructed)!==null&&r!==void 0?r:i.isConstructed=!!((s=i.value)===null||s===void 0?void 0:s.length);super({idBlock:{isConstructed:i.isConstructed,...t},lenBlock:{...e,isIndefiniteForm:!!i.isIndefiniteForm},...i},ut);this.idBlock.tagClass=1;this.idBlock.tagNumber=4}fromBER(t,e,i){this.valueBlock.isConstructed=this.idBlock.isConstructed;this.valueBlock.isIndefiniteForm=this.lenBlock.isIndefiniteForm;if(i===0){if(this.idBlock.error.length===0)this.blockLength+=this.idBlock.blockLength;if(this.lenBlock.error.length===0)this.blockLength+=this.lenBlock.blockLength;return e}if(!this.valueBlock.isConstructed){const r=t instanceof ArrayBuffer?new Uint8Array(t):t;const s=r.subarray(e,e+i);try{if(s.byteLength){const t=z(s,0,s.byteLength);if(t.offset!==-1&&t.offset===i){this.valueBlock.value=[t.result]}}}catch{}}return super.fromBER(t,e,i)}onAsciiEncoding(){if(this.valueBlock.isConstructed||this.valueBlock.value&&this.valueBlock.value.length){return tt.prototype.onAsciiEncoding.call(this)}const t=this.constructor.NAME;const e=n.Convert.ToHex(this.valueBlock.valueHexView);return`${t} : ${e}`}getValue(){if(!this.idBlock.isConstructed){return this.valueBlock.valueHexView.slice().buffer}const t=[];for(const e of this.valueBlock.value){if(e instanceof lt){t.push(e.valueBlock.valueHexView)}}return n.BufferSourceConverter.concat(t)}};lt=pt;(()=>{_.OctetString=lt})();pt.NAME=N;class ht extends(K(X)){constructor({unusedBits:t=0,isConstructed:e=false,...i}={}){super(i);this.unusedBits=t;this.isConstructed=e;this.blockLength=this.valueHexView.byteLength}fromBER(t,e,i){if(!i){return e}let r=-1;if(this.isConstructed){r=X.prototype.fromBER.call(this,t,e,i);if(r===-1)return r;for(const t of this.value){const e=t.constructor.NAME;if(e===M){if(this.isIndefiniteForm)break;else{this.error="EndOfContent is unexpected, BIT STRING may consists of BIT STRINGs only";return-1}}if(e!==k){this.error="BIT STRING may consists of BIT STRINGs only";return-1}const i=t.valueBlock;if(this.unusedBits>0&&i.unusedBits>0){this.error='Using of "unused bits" inside constructive BIT STRING allowed for least one only';return-1}this.unusedBits=i.unusedBits}return r}const s=n.BufferSourceConverter.toUint8Array(t);if(!S(this,s,e,i)){return-1}const o=s.subarray(e,e+i);this.unusedBits=o[0];if(this.unusedBits>7){this.error="Unused bits for BitString must be in range 0-7";return-1}if(!this.unusedBits){const t=o.subarray(1);try{if(t.byteLength){const e=z(t,0,t.byteLength);if(e.offset!==-1&&e.offset===i-1){this.value=[e.result]}}}catch{}}this.valueHexView=o.subarray(1);this.blockLength=o.length;return e+i}toBER(t,e){if(this.isConstructed){return X.prototype.toBER.call(this,t,e)}if(t){return new ArrayBuffer(this.valueHexView.byteLength+1)}if(!this.valueHexView.byteLength){return O}const i=new Uint8Array(this.valueHexView.length+1);i[0]=this.unusedBits;i.set(this.valueHexView,1);return i.buffer}toJSON(){return{...super.toJSON(),unusedBits:this.unusedBits,isConstructed:this.isConstructed}}}ht.NAME="BitStringValueBlock";var dt;let ft=class t extends V{constructor({idBlock:t={},lenBlock:e={},...i}={}){var r,s;(r=i.isConstructed)!==null&&r!==void 0?r:i.isConstructed=!!((s=i.value)===null||s===void 0?void 0:s.length);super({idBlock:{isConstructed:i.isConstructed,...t},lenBlock:{...e,isIndefiniteForm:!!i.isIndefiniteForm},...i},ht);this.idBlock.tagClass=1;this.idBlock.tagNumber=3}fromBER(t,e,i){this.valueBlock.isConstructed=this.idBlock.isConstructed;this.valueBlock.isIndefiniteForm=this.lenBlock.isIndefiniteForm;return super.fromBER(t,e,i)}onAsciiEncoding(){if(this.valueBlock.isConstructed||this.valueBlock.value&&this.valueBlock.value.length){return tt.prototype.onAsciiEncoding.call(this)}else{const t=[];const e=this.valueBlock.valueHexView;for(const i of e){t.push(i.toString(2).padStart(8,"0"))}const i=t.join("");const r=this.constructor.NAME;const s=i.substring(0,i.length-this.valueBlock.unusedBits);return`${r} : ${s}`}}};dt=ft;(()=>{_.BitString=dt})();ft.NAME=k;var yt;function St(t,e){const i=new Uint8Array([0]);const r=new Uint8Array(t);const s=new Uint8Array(e);let n=r.slice(0);const o=n.length-1;const a=s.slice(0);const c=a.length-1;let l=0;const p=c<o?o:c;let h=0;for(let t=p;t>=0;t--,h++){switch(true){case h<a.length:l=n[o-h]+a[c-h]+i[0];break;default:l=n[o-h]+i[0]}i[0]=l/10;switch(true){case h>=n.length:n=u(new Uint8Array([l%10]),n);break;default:n[o-h]=l%10}}if(i[0]>0)n=u(i,n);return n}function At(t){if(t>=C.length){for(let e=C.length;e<=t;e++){const t=new Uint8Array([0]);let i=C[e-1].slice(0);for(let e=i.length-1;e>=0;e--){const r=new Uint8Array([(i[e]<<1)+t[0]]);t[0]=r[0]/10;i[e]=r[0]%10}if(t[0]>0)i=u(t,i);C.push(i)}}return C[t]}function Ct(t,e){let i=0;const r=new Uint8Array(t);const s=new Uint8Array(e);const n=r.slice(0);const o=n.length-1;const a=s.slice(0);const c=a.length-1;let u;let l=0;for(let t=c;t>=0;t--,l++){u=n[o-l]-a[c-l]-i;switch(true){case u<0:i=1;n[o-l]=u+10;break;default:i=0;n[o-l]=u}}if(i>0){for(let t=o-c+1;t>=0;t--,l++){u=n[o-l]-i;if(u<0){i=1;n[o-l]=u+10}else{i=0;n[o-l]=u;break}}}return n.slice()}class vt extends(K(j)){setValueHex(){if(this.valueHexView.length>=4){this.warnings.push("Too big Integer for decoding, hex only");this.isHexOnly=true;this._valueDec=0}else{this.isHexOnly=false;if(this.valueHexView.length>0){this._valueDec=l.call(this)}}}constructor({value:t,...e}={}){super(e);this._valueDec=0;if(e.valueHex){this.setValueHex()}if(t!==undefined){this.valueDec=t}}set valueDec(t){this._valueDec=t;this.isHexOnly=false;this.valueHexView=new Uint8Array(p(t))}get valueDec(){return this._valueDec}fromDER(t,e,i,r=0){const s=this.fromBER(t,e,i);if(s===-1)return s;const n=this.valueHexView;if(n[0]===0&&(n[1]&128)!==0){this.valueHexView=n.subarray(1)}else{if(r!==0){if(n.length<r){if(r-n.length>1)r=n.length+1;this.valueHexView=n.subarray(r-n.length)}}}return s}toDER(t=false){const e=this.valueHexView;switch(true){case(e[0]&128)!==0:{const t=new Uint8Array(this.valueHexView.length+1);t[0]=0;t.set(e,1);this.valueHexView=t}break;case e[0]===0&&(e[1]&128)===0:{this.valueHexView=this.valueHexView.subarray(1)}break}return this.toBER(t)}fromBER(t,e,i){const r=super.fromBER(t,e,i);if(r===-1){return r}this.setValueHex();return r}toBER(t){return t?new ArrayBuffer(this.valueHexView.length):this.valueHexView.slice().buffer}toJSON(){return{...super.toJSON(),valueDec:this.valueDec}}toString(){const t=this.valueHexView.length*8-1;let e=new Uint8Array(this.valueHexView.length*8/3);let i=0;let r;const s=this.valueHexView;let n="";let o=false;for(let o=s.byteLength-1;o>=0;o--){r=s[o];for(let s=0;s<8;s++){if((r&1)===1){switch(i){case t:e=Ct(At(i),e);n="-";break;default:e=St(e,At(i))}}i++;r>>=1}}for(let t=0;t<e.length;t++){if(e[t])o=true;if(o)n+=v.charAt(e[t])}if(o===false)n+=v.charAt(0);return n}}yt=vt;vt.NAME="IntegerValueBlock";(()=>{Object.defineProperty(yt.prototype,"valueHex",{set:function(t){this.valueHexView=new Uint8Array(t);this.setValueHex()},get:function(){return this.valueHexView.slice().buffer}})})();var mt;class gt extends V{constructor(t={}){super(t,vt);this.idBlock.tagClass=1;this.idBlock.tagNumber=2}toBigInt(){f();return BigInt(this.valueBlock.toString())}static fromBigInt(t){f();const e=BigInt(t);const i=new A;const r=e.toString(16).replace(/^-/,"");const s=new Uint8Array(n.Convert.FromHex(r));if(e<0){const t=new Uint8Array(s.length+(s[0]&128?1:0));t[0]|=128;const r=BigInt(`0x${n.Convert.ToHex(t)}`);const o=r+e;const a=n.BufferSourceConverter.toUint8Array(n.Convert.FromHex(o.toString(16)));a[0]|=128;i.write(a)}else{if(s[0]&128){i.write(new Uint8Array([0]))}i.write(s)}const o=new mt({valueHex:i.final()});return o}convertToDER(){const t=new mt({valueHex:this.valueBlock.valueHexView});t.valueBlock.toDER();return t}convertFromDER(){return new mt({valueHex:this.valueBlock.valueHexView[0]===0?this.valueBlock.valueHexView.subarray(1):this.valueBlock.valueHexView})}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.valueBlock.toString()}`}}mt=gt;(()=>{_.Integer=mt})();gt.NAME="INTEGER";var wt;class Et extends gt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=10}}wt=Et;(()=>{_.Enumerated=wt})();Et.NAME="ENUMERATED";class Pt extends(K(j)){constructor({valueDec:t=-1,isFirstSid:e=false,...i}={}){super(i);this.valueDec=t;this.isFirstSid=e}fromBER(t,e,i){if(!i){return e}const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i)){return-1}const s=r.subarray(e,e+i);this.valueHexView=new Uint8Array(i);for(let t=0;t<i;t++){this.valueHexView[t]=s[t]&127;this.blockLength++;if((s[t]&128)===0)break}const o=new Uint8Array(this.blockLength);for(let t=0;t<this.blockLength;t++){o[t]=this.valueHexView[t]}this.valueHexView=o;if((s[this.blockLength-1]&128)!==0){this.error="End of input reached before message was fully decoded";return-1}if(this.valueHexView[0]===0)this.warnings.push("Needlessly long format of SID encoding");if(this.blockLength<=8)this.valueDec=a(this.valueHexView,7);else{this.isHexOnly=true;this.warnings.push("Too big SID for decoding, hex only")}return e+this.blockLength}set valueBigInt(t){f();let e=BigInt(t).toString(2);while(e.length%7){e="0"+e}const i=new Uint8Array(e.length/7);for(let t=0;t<i.length;t++){i[t]=parseInt(e.slice(t*7,t*7+7),2)+(t+1<i.length?128:0)}this.fromBER(i.buffer,0,i.length)}toBER(t){if(this.isHexOnly){if(t)return new ArrayBuffer(this.valueHexView.byteLength);const e=this.valueHexView;const i=new Uint8Array(this.blockLength);for(let t=0;t<this.blockLength-1;t++)i[t]=e[t]|128;i[this.blockLength-1]=e[this.blockLength-1];return i.buffer}const e=c(this.valueDec,7);if(e.byteLength===0){this.error="Error during encoding SID value";return O}const i=new Uint8Array(e.byteLength);if(!t){const t=new Uint8Array(e);const r=e.byteLength-1;for(let e=0;e<r;e++)i[e]=t[e]|128;i[r]=t[r]}return i}toString(){let t="";if(this.isHexOnly)t=n.Convert.ToHex(this.valueHexView);else{if(this.isFirstSid){let e=this.valueDec;if(this.valueDec<=39)t="0.";else{if(this.valueDec<=79){t="1.";e-=40}else{t="2.";e-=80}}t+=e.toString()}else t=this.valueDec.toString()}return t}toJSON(){return{...super.toJSON(),valueDec:this.valueDec,isFirstSid:this.isFirstSid}}}Pt.NAME="sidBlock";class Dt extends j{constructor({value:t=T,...e}={}){super(e);this.value=[];if(t){this.fromString(t)}}fromBER(t,e,i){let r=e;while(i>0){const e=new Pt;r=e.fromBER(t,r,i);if(r===-1){this.blockLength=0;this.error=e.error;return r}if(this.value.length===0)e.isFirstSid=true;this.blockLength+=e.blockLength;i-=e.blockLength;this.value.push(e)}return r}toBER(t){const e=[];for(let i=0;i<this.value.length;i++){const r=this.value[i].toBER(t);if(r.byteLength===0){this.error=this.value[i].error;return O}e.push(r)}return y(e)}fromString(t){this.value=[];let e=0;let i=0;let r="";let s=false;do{i=t.indexOf(".",e);if(i===-1)r=t.substring(e);else r=t.substring(e,i);e=i+1;if(s){const t=this.value[0];let e=0;switch(t.valueDec){case 0:break;case 1:e=40;break;case 2:e=80;break;default:this.value=[];return}const i=parseInt(r,10);if(isNaN(i))return;t.valueDec=i+e;s=false}else{const t=new Pt;if(r>Number.MAX_SAFE_INTEGER){f();const e=BigInt(r);t.valueBigInt=e}else{t.valueDec=parseInt(r,10);if(isNaN(t.valueDec))return}if(!this.value.length){t.isFirstSid=true;s=true}this.value.push(t)}}while(i!==-1)}toString(){let t="";let e=false;for(let i=0;i<this.value.length;i++){e=this.value[i].isHexOnly;let r=this.value[i].toString();if(i!==0)t=`${t}.`;if(e){r=`{${r}}`;if(this.value[i].isFirstSid)t=`2.{${r} - 80}`;else t+=r}else t+=r}return t}toJSON(){const t={...super.toJSON(),value:this.toString(),sidArray:[]};for(let e=0;e<this.value.length;e++){t.sidArray.push(this.value[e].toJSON())}return t}}Dt.NAME="ObjectIdentifierValueBlock";var bt;class Bt extends V{getValue(){return this.valueBlock.toString()}setValue(t){this.valueBlock.fromString(t)}constructor(t={}){super(t,Dt);this.idBlock.tagClass=1;this.idBlock.tagNumber=6}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.valueBlock.toString()||"empty"}`}toJSON(){return{...super.toJSON(),value:this.getValue()}}}bt=Bt;(()=>{_.ObjectIdentifier=bt})();Bt.NAME="OBJECT IDENTIFIER";class It extends(K(H)){constructor({valueDec:t=0,...e}={}){super(e);this.valueDec=t}fromBER(t,e,i){if(i===0)return e;const r=n.BufferSourceConverter.toUint8Array(t);if(!S(this,r,e,i))return-1;const s=r.subarray(e,e+i);this.valueHexView=new Uint8Array(i);for(let t=0;t<i;t++){this.valueHexView[t]=s[t]&127;this.blockLength++;if((s[t]&128)===0)break}const o=new Uint8Array(this.blockLength);for(let t=0;t<this.blockLength;t++)o[t]=this.valueHexView[t];this.valueHexView=o;if((s[this.blockLength-1]&128)!==0){this.error="End of input reached before message was fully decoded";return-1}if(this.valueHexView[0]===0)this.warnings.push("Needlessly long format of SID encoding");if(this.blockLength<=8)this.valueDec=a(this.valueHexView,7);else{this.isHexOnly=true;this.warnings.push("Too big SID for decoding, hex only")}return e+this.blockLength}toBER(t){if(this.isHexOnly){if(t)return new ArrayBuffer(this.valueHexView.byteLength);const e=this.valueHexView;const i=new Uint8Array(this.blockLength);for(let t=0;t<this.blockLength-1;t++)i[t]=e[t]|128;i[this.blockLength-1]=e[this.blockLength-1];return i.buffer}const e=c(this.valueDec,7);if(e.byteLength===0){this.error="Error during encoding SID value";return O}const i=new Uint8Array(e.byteLength);if(!t){const t=new Uint8Array(e);const r=e.byteLength-1;for(let e=0;e<r;e++)i[e]=t[e]|128;i[r]=t[r]}return i.buffer}toString(){let t="";if(this.isHexOnly)t=n.Convert.ToHex(this.valueHexView);else{t=this.valueDec.toString()}return t}toJSON(){return{...super.toJSON(),valueDec:this.valueDec}}}It.NAME="relativeSidBlock";class xt extends j{constructor({value:t=T,...e}={}){super(e);this.value=[];if(t){this.fromString(t)}}fromBER(t,e,i){let r=e;while(i>0){const e=new It;r=e.fromBER(t,r,i);if(r===-1){this.blockLength=0;this.error=e.error;return r}this.blockLength+=e.blockLength;i-=e.blockLength;this.value.push(e)}return r}toBER(t,e){const i=[];for(let e=0;e<this.value.length;e++){const r=this.value[e].toBER(t);if(r.byteLength===0){this.error=this.value[e].error;return O}i.push(r)}return y(i)}fromString(t){this.value=[];let e=0;let i=0;let r="";do{i=t.indexOf(".",e);if(i===-1)r=t.substring(e);else r=t.substring(e,i);e=i+1;const s=new It;s.valueDec=parseInt(r,10);if(isNaN(s.valueDec))return true;this.value.push(s)}while(i!==-1);return true}toString(){let t="";let e=false;for(let i=0;i<this.value.length;i++){e=this.value[i].isHexOnly;let r=this.value[i].toString();if(i!==0)t=`${t}.`;if(e){r=`{${r}}`;t+=r}else t+=r}return t}toJSON(){const t={...super.toJSON(),value:this.toString(),sidArray:[]};for(let e=0;e<this.value.length;e++)t.sidArray.push(this.value[e].toJSON());return t}}xt.NAME="RelativeObjectIdentifierValueBlock";var Tt;class Ot extends V{getValue(){return this.valueBlock.toString()}setValue(t){this.valueBlock.fromString(t)}constructor(t={}){super(t,xt);this.idBlock.tagClass=1;this.idBlock.tagNumber=13}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.valueBlock.toString()||"empty"}`}toJSON(){return{...super.toJSON(),value:this.getValue()}}}Tt=Ot;(()=>{_.RelativeObjectIdentifier=Tt})();Ot.NAME="RelativeObjectIdentifier";var Rt;class Mt extends tt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=16}}Rt=Mt;(()=>{_.Sequence=Rt})();Mt.NAME="SEQUENCE";var Nt;class kt extends tt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=17}}Nt=kt;(()=>{_.Set=Nt})();kt.NAME="SET";class Kt extends(K(j)){constructor({...t}={}){super(t);this.isHexOnly=true;this.value=T}toJSON(){return{...super.toJSON(),value:this.value}}}Kt.NAME="StringValueBlock";class Ht extends Kt{}Ht.NAME="SimpleStringValueBlock";class jt extends ${constructor({...t}={}){super(t,Ht)}fromBuffer(t){this.valueBlock.value=String.fromCharCode.apply(null,n.BufferSourceConverter.toUint8Array(t))}fromString(t){const e=t.length;const i=this.valueBlock.valueHexView=new Uint8Array(e);for(let r=0;r<e;r++)i[r]=t.charCodeAt(r);this.valueBlock.value=t}}jt.NAME="SIMPLE STRING";class Ut extends jt{fromBuffer(t){this.valueBlock.valueHexView=n.BufferSourceConverter.toUint8Array(t);try{this.valueBlock.value=n.Convert.ToUtf8String(t)}catch(e){this.warnings.push(`Error during "decodeURIComponent": ${e}, using raw string`);this.valueBlock.value=n.Convert.ToBinary(t)}}fromString(t){this.valueBlock.valueHexView=new Uint8Array(n.Convert.FromUtf8String(t));this.valueBlock.value=t}}Ut.NAME="Utf8StringValueBlock";var Ft;class _t extends Ut{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=12}}Ft=_t;(()=>{_.Utf8String=Ft})();_t.NAME="UTF8String";class Vt extends jt{fromBuffer(t){this.valueBlock.value=n.Convert.ToUtf16String(t);this.valueBlock.valueHexView=n.BufferSourceConverter.toUint8Array(t)}fromString(t){this.valueBlock.value=t;this.valueBlock.valueHexView=new Uint8Array(n.Convert.FromUtf16String(t))}}Vt.NAME="BmpStringValueBlock";var Lt;class $t extends Vt{constructor({...t}={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=30}}Lt=$t;(()=>{_.BmpString=Lt})();$t.NAME="BMPString";class Gt extends jt{fromBuffer(t){const e=ArrayBuffer.isView(t)?t.slice().buffer:t.slice(0);const i=new Uint8Array(e);for(let t=0;t<i.length;t+=4){i[t]=i[t+3];i[t+1]=i[t+2];i[t+2]=0;i[t+3]=0}this.valueBlock.value=String.fromCharCode.apply(null,new Uint32Array(e))}fromString(t){const e=t.length;const i=this.valueBlock.valueHexView=new Uint8Array(e*4);for(let r=0;r<e;r++){const e=c(t.charCodeAt(r),8);const s=new Uint8Array(e);if(s.length>4)continue;const n=4-s.length;for(let t=s.length-1;t>=0;t--)i[r*4+t+n]=s[t]}this.valueBlock.value=t}}Gt.NAME="UniversalStringValueBlock";var Wt;class Qt extends Gt{constructor({...t}={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=28}}Wt=Qt;(()=>{_.UniversalString=Wt})();Qt.NAME="UniversalString";var qt;class zt extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=18}}qt=zt;(()=>{_.NumericString=qt})();zt.NAME="NumericString";var Jt;class Zt extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=19}}Jt=Zt;(()=>{_.PrintableString=Jt})();Zt.NAME="PrintableString";var Xt;class Yt extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=20}}Xt=Yt;(()=>{_.TeletexString=Xt})();Yt.NAME="TeletexString";var te;class ee extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=21}}te=ee;(()=>{_.VideotexString=te})();ee.NAME="VideotexString";var ie;class re extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=22}}ie=re;(()=>{_.IA5String=ie})();re.NAME="IA5String";var se;class ne extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=25}}se=ne;(()=>{_.GraphicString=se})();ne.NAME="GraphicString";var oe;class ae extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=26}}oe=ae;(()=>{_.VisibleString=oe})();ae.NAME="VisibleString";var ce;class ue extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=27}}ce=ue;(()=>{_.GeneralString=ce})();ue.NAME="GeneralString";var le;class pe extends jt{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=29}}le=pe;(()=>{_.CharacterString=le})();pe.NAME="CharacterString";var he;class de extends ae{constructor({value:t,valueDate:e,...i}={}){super(i);this.year=0;this.month=0;this.day=0;this.hour=0;this.minute=0;this.second=0;if(t){this.fromString(t);this.valueBlock.valueHexView=new Uint8Array(t.length);for(let e=0;e<t.length;e++)this.valueBlock.valueHexView[e]=t.charCodeAt(e)}if(e){this.fromDate(e);this.valueBlock.valueHexView=new Uint8Array(this.toBuffer())}this.idBlock.tagClass=1;this.idBlock.tagNumber=23}fromBuffer(t){this.fromString(String.fromCharCode.apply(null,n.BufferSourceConverter.toUint8Array(t)))}toBuffer(){const t=this.toString();const e=new ArrayBuffer(t.length);const i=new Uint8Array(e);for(let e=0;e<t.length;e++)i[e]=t.charCodeAt(e);return e}fromDate(t){this.year=t.getUTCFullYear();this.month=t.getUTCMonth()+1;this.day=t.getUTCDate();this.hour=t.getUTCHours();this.minute=t.getUTCMinutes();this.second=t.getUTCSeconds()}toDate(){return new Date(Date.UTC(this.year,this.month-1,this.day,this.hour,this.minute,this.second))}fromString(t){const e=/(\d{2})(\d{2})(\d{2})(\d{2})(\d{2})(\d{2})Z/gi;const i=e.exec(t);if(i===null){this.error="Wrong input string for conversion";return}const r=parseInt(i[1],10);if(r>=50)this.year=1900+r;else this.year=2e3+r;this.month=parseInt(i[2],10);this.day=parseInt(i[3],10);this.hour=parseInt(i[4],10);this.minute=parseInt(i[5],10);this.second=parseInt(i[6],10)}toString(t="iso"){if(t==="iso"){const t=new Array(7);t[0]=d(this.year<2e3?this.year-1900:this.year-2e3,2);t[1]=d(this.month,2);t[2]=d(this.day,2);t[3]=d(this.hour,2);t[4]=d(this.minute,2);t[5]=d(this.second,2);t[6]="Z";return t.join("")}return super.toString(t)}onAsciiEncoding(){return`${this.constructor.NAME} : ${this.toDate().toISOString()}`}toJSON(){return{...super.toJSON(),year:this.year,month:this.month,day:this.day,hour:this.hour,minute:this.minute,second:this.second}}}he=de;(()=>{_.UTCTime=he})();de.NAME="UTCTime";var fe;class ye extends de{constructor(t={}){var e;super(t);(e=this.millisecond)!==null&&e!==void 0?e:this.millisecond=0;this.idBlock.tagClass=1;this.idBlock.tagNumber=24}fromDate(t){super.fromDate(t);this.millisecond=t.getUTCMilliseconds()}toDate(){const t=Date.UTC(this.year,this.month-1,this.day,this.hour,this.minute,this.second,this.millisecond);return new Date(t)}fromString(t){let e=false;let i="";let r="";let s=0;let n;let o=0;let a=0;if(t[t.length-1]==="Z"){i=t.substring(0,t.length-1);e=true}else{const e=new Number(t[t.length-1]);if(isNaN(e.valueOf()))throw new Error("Wrong input string for conversion");i=t}if(e){if(i.indexOf("+")!==-1)throw new Error("Wrong input string for conversion");if(i.indexOf("-")!==-1)throw new Error("Wrong input string for conversion")}else{let t=1;let e=i.indexOf("+");let r="";if(e===-1){e=i.indexOf("-");t=-1}if(e!==-1){r=i.substring(e+1);i=i.substring(0,e);if(r.length!==2&&r.length!==4)throw new Error("Wrong input string for conversion");let s=parseInt(r.substring(0,2),10);if(isNaN(s.valueOf()))throw new Error("Wrong input string for conversion");o=t*s;if(r.length===4){s=parseInt(r.substring(2,4),10);if(isNaN(s.valueOf()))throw new Error("Wrong input string for conversion");a=t*s}}}let c=i.indexOf(".");if(c===-1)c=i.indexOf(",");if(c!==-1){const t=new Number(`0${i.substring(c)}`);if(isNaN(t.valueOf()))throw new Error("Wrong input string for conversion");s=t.valueOf();r=i.substring(0,c)}else r=i;switch(true){case r.length===8:n=/(\d{4})(\d{2})(\d{2})/gi;if(c!==-1)throw new Error("Wrong input string for conversion");break;case r.length===10:n=/(\d{4})(\d{2})(\d{2})(\d{2})/gi;if(c!==-1){let t=60*s;this.minute=Math.floor(t);t=60*(t-this.minute);this.second=Math.floor(t);t=1e3*(t-this.second);this.millisecond=Math.floor(t)}break;case r.length===12:n=/(\d{4})(\d{2})(\d{2})(\d{2})(\d{2})/gi;if(c!==-1){let t=60*s;this.second=Math.floor(t);t=1e3*(t-this.second);this.millisecond=Math.floor(t)}break;case r.length===14:n=/(\d{4})(\d{2})(\d{2})(\d{2})(\d{2})(\d{2})/gi;if(c!==-1){const t=1e3*s;this.millisecond=Math.floor(t)}break;default:throw new Error("Wrong input string for conversion")}const u=n.exec(r);if(u===null)throw new Error("Wrong input string for conversion");for(let t=1;t<u.length;t++){switch(t){case 1:this.year=parseInt(u[t],10);break;case 2:this.month=parseInt(u[t],10);break;case 3:this.day=parseInt(u[t],10);break;case 4:this.hour=parseInt(u[t],10)+o;break;case 5:this.minute=parseInt(u[t],10)+a;break;case 6:this.second=parseInt(u[t],10);break;default:throw new Error("Wrong input string for conversion")}}if(e===false){const t=new Date(this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond);this.year=t.getUTCFullYear();this.month=t.getUTCMonth();this.day=t.getUTCDay();this.hour=t.getUTCHours();this.minute=t.getUTCMinutes();this.second=t.getUTCSeconds();this.millisecond=t.getUTCMilliseconds()}}toString(t="iso"){if(t==="iso"){const t=[];t.push(d(this.year,4));t.push(d(this.month,2));t.push(d(this.day,2));t.push(d(this.hour,2));t.push(d(this.minute,2));t.push(d(this.second,2));if(this.millisecond!==0){t.push(".");t.push(d(this.millisecond,3))}t.push("Z");return t.join("")}return super.toString(t)}toJSON(){return{...super.toJSON(),millisecond:this.millisecond}}}fe=ye;(()=>{_.GeneralizedTime=fe})();ye.NAME="GeneralizedTime";var Se;class Ae extends _t{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=31}}Se=Ae;(()=>{_.DATE=Se})();Ae.NAME="DATE";var Ce;class ve extends _t{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=32}}Ce=ve;(()=>{_.TimeOfDay=Ce})();ve.NAME="TimeOfDay";var me;class ge extends _t{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=33}}me=ge;(()=>{_.DateTime=me})();ge.NAME="DateTime";var we;class Ee extends _t{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=34}}we=Ee;(()=>{_.Duration=we})();Ee.NAME="Duration";var Pe;class De extends _t{constructor(t={}){super(t);this.idBlock.tagClass=1;this.idBlock.tagNumber=14}}Pe=De;(()=>{_.TIME=Pe})();De.NAME="TIME";class be{constructor({name:t=T,optional:e=false}={}){this.name=t;this.optional=e}}class Be extends be{constructor({value:t=[],...e}={}){super(e);this.value=t}}class Ie extends be{constructor({value:t=new be,local:e=false,...i}={}){super(i);this.value=t;this.local=e}}class xe{get data(){return this.dataView.slice().buffer}set data(t){this.dataView=n.BufferSourceConverter.toUint8Array(t)}constructor({data:t=R}={}){this.dataView=n.BufferSourceConverter.toUint8Array(t)}fromBER(t,e,i){const r=e+i;this.dataView=n.BufferSourceConverter.toUint8Array(t).subarray(e,r);return r}toBER(t){return this.dataView.slice().buffer}}function Te(t,e,i){if(i instanceof Be){for(const r of i.value){const i=Te(t,e,r);if(i.verified){return{verified:true,result:t}}}{const t={verified:false,result:{error:"Wrong values for Choice type"}};if(i.hasOwnProperty(m))t.name=i.name;return t}}if(i instanceof be){if(i.hasOwnProperty(m))t[i.name]=e;return{verified:true,result:t}}if(t instanceof Object===false){return{verified:false,result:{error:"Wrong root object"}}}if(e instanceof Object===false){return{verified:false,result:{error:"Wrong ASN.1 data"}}}if(i instanceof Object===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(E in i===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(B in i.idBlock===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(I in i.idBlock===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}const r=i.idBlock.toBER(false);if(r.byteLength===0){return{verified:false,result:{error:"Error encoding idBlock for ASN.1 schema"}}}const s=i.idBlock.fromBER(r,0,r.byteLength);if(s===-1){return{verified:false,result:{error:"Error decoding idBlock for ASN.1 schema"}}}if(i.idBlock.hasOwnProperty(P)===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(i.idBlock.tagClass!==e.idBlock.tagClass){return{verified:false,result:t}}if(i.idBlock.hasOwnProperty(D)===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(i.idBlock.tagNumber!==e.idBlock.tagNumber){return{verified:false,result:t}}if(i.idBlock.hasOwnProperty(b)===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(i.idBlock.isConstructed!==e.idBlock.isConstructed){return{verified:false,result:t}}if(!(w in i.idBlock)){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}if(i.idBlock.isHexOnly!==e.idBlock.isHexOnly){return{verified:false,result:t}}if(i.idBlock.isHexOnly){if(g in i.idBlock===false){return{verified:false,result:{error:"Wrong ASN.1 schema"}}}const r=i.idBlock.valueHexView;const s=e.idBlock.valueHexView;if(r.length!==s.length){return{verified:false,result:t}}for(let e=0;e<r.length;e++){if(r[e]!==s[1]){return{verified:false,result:t}}}}if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name)t[i.name]=e}if(i instanceof _.Constructed){let r=0;let s={verified:false,result:{error:"Unknown error"}};let n=i.valueBlock.value.length;if(n>0){if(i.valueBlock.value[0]instanceof Ie){n=e.valueBlock.value.length}}if(n===0){return{verified:true,result:t}}if(e.valueBlock.value.length===0&&i.valueBlock.value.length!==0){let e=true;for(let t=0;t<i.valueBlock.value.length;t++)e=e&&(i.valueBlock.value[t].optional||false);if(e){return{verified:true,result:t}}if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name)delete t[i.name]}t.error="Inconsistent object length";return{verified:false,result:t}}for(let o=0;o<n;o++){if(o-r>=e.valueBlock.value.length){if(i.valueBlock.value[o].optional===false){const e={verified:false,result:t};t.error="Inconsistent length between ASN.1 data and schema";if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name){delete t[i.name];e.name=i.name}}return e}}else{if(i.valueBlock.value[0]instanceof Ie){s=Te(t,e.valueBlock.value[o],i.valueBlock.value[0].value);if(s.verified===false){if(i.valueBlock.value[0].optional)r++;else{if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name)delete t[i.name]}return s}}if(m in i.valueBlock.value[0]&&i.valueBlock.value[0].name.length>0){let r={};if(x in i.valueBlock.value[0]&&i.valueBlock.value[0].local)r=e;else r=t;if(typeof r[i.valueBlock.value[0].name]==="undefined")r[i.valueBlock.value[0].name]=[];r[i.valueBlock.value[0].name].push(e.valueBlock.value[o])}}else{s=Te(t,e.valueBlock.value[o-r],i.valueBlock.value[o]);if(s.verified===false){if(i.valueBlock.value[o].optional)r++;else{if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name)delete t[i.name]}return s}}}}}if(s.verified===false){const e={verified:false,result:t};if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name){delete t[i.name];e.name=i.name}}return e}return{verified:true,result:t}}if(i.primitiveSchema&&g in e.valueBlock){const r=z(e.valueBlock.valueHexView);if(r.offset===-1){const e={verified:false,result:r.result};if(i.name){i.name=i.name.replace(/^\s+|\s+$/g,T);if(i.name){delete t[i.name];e.name=i.name}}return e}return Te(t,r.result,i.primitiveSchema)}return{verified:true,result:t}}function Oe(t,e){if(e instanceof Object===false){return{verified:false,result:{error:"Wrong ASN.1 schema type"}}}const i=z(n.BufferSourceConverter.toUint8Array(t));if(i.offset===-1){return{verified:false,result:i.result}}return Te(i.result,i.result,e)}var Re=Object.freeze({__proto__:null,Any:be,BaseBlock:V,BaseStringBlock:$,BitString:ft,BmpString:$t,Boolean:ct,CharacterString:pe,Choice:Be,Constructed:tt,DATE:Ae,DateTime:ge,Duration:Ee,EndOfContent:rt,Enumerated:Et,GeneralString:ue,GeneralizedTime:ye,GraphicString:ne,HexBlock:K,IA5String:re,Integer:gt,Null:nt,NumericString:zt,ObjectIdentifier:Bt,OctetString:pt,Primitive:Q,PrintableString:Zt,RawData:xe,RelativeObjectIdentifier:Ot,Repeated:Ie,Sequence:Mt,Set:kt,TIME:De,TeletexString:Yt,TimeOfDay:ve,UTCTime:de,UniversalString:Qt,Utf8String:_t,ValueBlock:j,VideotexString:ee,ViewWriter:A,VisibleString:ae,compareSchema:Te,fromBER:J,verifySchema:Oe});var Me;(function(t){t[t["Sequence"]=0]="Sequence";t[t["Set"]=1]="Set";t[t["Choice"]=2]="Choice"})(Me||(Me={}));var Ne;(function(t){t[t["Any"]=1]="Any";t[t["Boolean"]=2]="Boolean";t[t["OctetString"]=3]="OctetString";t[t["BitString"]=4]="BitString";t[t["Integer"]=5]="Integer";t[t["Enumerated"]=6]="Enumerated";t[t["ObjectIdentifier"]=7]="ObjectIdentifier";t[t["Utf8String"]=8]="Utf8String";t[t["BmpString"]=9]="BmpString";t[t["UniversalString"]=10]="UniversalString";t[t["NumericString"]=11]="NumericString";t[t["PrintableString"]=12]="PrintableString";t[t["TeletexString"]=13]="TeletexString";t[t["VideotexString"]=14]="VideotexString";t[t["IA5String"]=15]="IA5String";t[t["GraphicString"]=16]="GraphicString";t[t["VisibleString"]=17]="VisibleString";t[t["GeneralString"]=18]="GeneralString";t[t["CharacterString"]=19]="CharacterString";t[t["UTCTime"]=20]="UTCTime";t[t["GeneralizedTime"]=21]="GeneralizedTime";t[t["DATE"]=22]="DATE";t[t["TimeOfDay"]=23]="TimeOfDay";t[t["DateTime"]=24]="DateTime";t[t["Duration"]=25]="Duration";t[t["TIME"]=26]="TIME";t[t["Null"]=27]="Null"})(Ne||(Ne={}));class ke{constructor(t,e=0){this.unusedBits=0;this.value=new ArrayBuffer(0);if(t){if(typeof t==="number"){this.fromNumber(t)}else if(n.BufferSourceConverter.isBufferSource(t)){this.unusedBits=e;this.value=n.BufferSourceConverter.toArrayBuffer(t)}else{throw TypeError("Unsupported type of 'params' argument for BitString")}}}fromASN(t){if(!(t instanceof ft)){throw new TypeError("Argument 'asn' is not instance of ASN.1 BitString")}this.unusedBits=t.valueBlock.unusedBits;this.value=t.valueBlock.valueHex;return this}toASN(){return new ft({unusedBits:this.unusedBits,valueHex:this.value})}toSchema(t){return new ft({name:t})}toNumber(){let t="";const e=new Uint8Array(this.value);for(const i of e){t+=i.toString(2).padStart(8,"0")}t=t.split("").reverse().join("");if(this.unusedBits){t=t.slice(this.unusedBits).padStart(this.unusedBits,"0")}return parseInt(t,2)}fromNumber(t){let e=t.toString(2);const i=e.length+7>>3;this.unusedBits=(i<<3)-e.length;const r=new Uint8Array(i);e=e.padStart(i<<3,"0").split("").reverse().join("");let s=0;while(s<i){r[s]=parseInt(e.slice(s<<3,(s<<3)+8),2);s++}this.value=r.buffer}}class Ke{get byteLength(){return this.buffer.byteLength}get byteOffset(){return 0}constructor(t){if(typeof t==="number"){this.buffer=new ArrayBuffer(t)}else{if(n.BufferSourceConverter.isBufferSource(t)){this.buffer=n.BufferSourceConverter.toArrayBuffer(t)}else if(Array.isArray(t)){this.buffer=new Uint8Array(t)}else{this.buffer=new ArrayBuffer(0)}}}fromASN(t){if(!(t instanceof pt)){throw new TypeError("Argument 'asn' is not instance of ASN.1 OctetString")}this.buffer=t.valueBlock.valueHex;return this}toASN(){return new pt({valueHex:this.buffer})}toSchema(t){return new pt({name:t})}}const He={fromASN:t=>t instanceof nt?null:t.valueBeforeDecodeView,toASN:t=>{if(t===null){return new nt}const e=J(t);if(e.result.error){throw new Error(e.result.error)}return e.result}};const je={fromASN:t=>t.valueBlock.valueHexView.byteLength>=4?t.valueBlock.toString():t.valueBlock.valueDec,toASN:t=>new gt({value:+t})};const Ue={fromASN:t=>t.valueBlock.valueDec,toASN:t=>new Et({value:t})};const Fe={fromASN:t=>t.valueBlock.valueHexView,toASN:t=>new gt({valueHex:t})};const _e={fromASN:t=>t.valueBlock.valueHexView,toASN:t=>new ft({valueHex:t})};const Ve={fromASN:t=>t.valueBlock.toString(),toASN:t=>new Bt({value:t})};const Le={fromASN:t=>t.valueBlock.value,toASN:t=>new ct({value:t})};const $e={fromASN:t=>t.valueBlock.valueHexView,toASN:t=>new pt({valueHex:t})};const Ge={fromASN:t=>new Ke(t.getValue()),toASN:t=>t.toASN()};function We(t){return{fromASN:t=>t.valueBlock.value,toASN:e=>new t({value:e})}}const Qe=We(_t);const qe=We($t);const ze=We(Qt);const Je=We(zt);const Ze=We(Zt);const Xe=We(Yt);const Ye=We(ee);const ti=We(re);const ei=We(ne);const ii=We(ae);const ri=We(ue);const si=We(pe);const ni={fromASN:t=>t.toDate(),toASN:t=>new de({valueDate:t})};const oi={fromASN:t=>t.toDate(),toASN:t=>new ye({valueDate:t})};const ai={fromASN:()=>null,toASN:()=>new nt};function ci(t){switch(t){case Ne.Any:return He;case Ne.BitString:return _e;case Ne.BmpString:return qe;case Ne.Boolean:return Le;case Ne.CharacterString:return si;case Ne.Enumerated:return Ue;case Ne.GeneralString:return ri;case Ne.GeneralizedTime:return oi;case Ne.GraphicString:return ei;case Ne.IA5String:return ti;case Ne.Integer:return je;case Ne.Null:return ai;case Ne.NumericString:return Je;case Ne.ObjectIdentifier:return Ve;case Ne.OctetString:return $e;case Ne.PrintableString:return Ze;case Ne.TeletexString:return Xe;case Ne.UTCTime:return ni;case Ne.UniversalString:return ze;case Ne.Utf8String:return Qe;case Ne.VideotexString:return Ye;case Ne.VisibleString:return ii;default:return null}}function ui(t){if(typeof t==="function"&&t.prototype){if(t.prototype.toASN&&t.prototype.fromASN){return true}else{return ui(t.prototype)}}else{return!!(t&&typeof t==="object"&&"toASN"in t&&"fromASN"in t)}}function li(t){var e;if(t){const i=Object.getPrototypeOf(t);if(((e=i===null||i===void 0?void 0:i.prototype)===null||e===void 0?void 0:e.constructor)===Array){return true}return li(i)}return false}function pi(t,e){if(!(t&&e)){return false}if(t.byteLength!==e.byteLength){return false}const i=new Uint8Array(t);const r=new Uint8Array(e);for(let e=0;e<t.byteLength;e++){if(i[e]!==r[e]){return false}}return true}class hi{constructor(){this.items=new WeakMap}has(t){return this.items.has(t)}get(t,e=false){const i=this.items.get(t);if(!i){throw new Error(`Cannot get schema for '${t.prototype.constructor.name}' target`)}if(e&&!i.schema){throw new Error(`Schema '${t.prototype.constructor.name}' doesn't contain ASN.1 schema. Call 'AsnSchemaStorage.cache'.`)}return i}cache(t){const e=this.get(t);if(!e.schema){e.schema=this.create(t,true)}}createDefault(t){const e={type:Me.Sequence,items:{}};const i=this.findParentSchema(t);if(i){Object.assign(e,i);e.items=Object.assign({},e.items,i.items)}return e}create(t,e){const i=this.items.get(t)||this.createDefault(t);const r=[];for(const t in i.items){const s=i.items[t];const n=e?t:"";let o;if(typeof s.type==="number"){const t=Ne[s.type];const e=Re[t];if(!e){throw new Error(`Cannot get ASN1 class by name '${t}'`)}o=new e({name:n})}else if(ui(s.type)){const t=new s.type;o=t.toSchema(n)}else if(s.optional){const t=this.get(s.type);if(t.type===Me.Choice){o=new be({name:n})}else{o=this.create(s.type,false);o.name=n}}else{o=new be({name:n})}const a=!!s.optional||s.defaultValue!==undefined;if(s.repeated){o.name="";const t=s.repeated==="set"?kt:Mt;o=new t({name:"",value:[new Ie({name:n,value:o})]})}if(s.context!==null&&s.context!==undefined){if(s.implicit){if(typeof s.type==="number"||ui(s.type)){const t=s.repeated?tt:Q;r.push(new t({name:n,optional:a,idBlock:{tagClass:3,tagNumber:s.context}}))}else{this.cache(s.type);const t=!!s.repeated;let e=!t?this.get(s.type,true).schema:o;e="valueBlock"in e?e.valueBlock.value:e.value;r.push(new tt({name:!t?n:"",optional:a,idBlock:{tagClass:3,tagNumber:s.context},value:e}))}}else{r.push(new tt({optional:a,idBlock:{tagClass:3,tagNumber:s.context},value:[o]}))}}else{o.optional=a;r.push(o)}}switch(i.type){case Me.Sequence:return new Mt({value:r,name:""});case Me.Set:return new kt({value:r,name:""});case Me.Choice:return new Be({value:r,name:""});default:throw new Error(`Unsupported ASN1 type in use`)}}set(t,e){this.items.set(t,e);return this}findParentSchema(t){const e=Object.getPrototypeOf(t);if(e){const t=this.items.get(e);return t||this.findParentSchema(e)}return null}}const di=new hi;const fi=t=>e=>{let i;if(!di.has(e)){i=di.createDefault(e);di.set(e,i)}else{i=di.get(e)}Object.assign(i,t)};const yi=t=>(e,i)=>{let r;if(!di.has(e.constructor)){r=di.createDefault(e.constructor);di.set(e.constructor,r)}else{r=di.get(e.constructor)}const s=Object.assign({},t);if(typeof s.type==="number"&&!s.converter){const r=ci(t.type);if(!r){throw new Error(`Cannot get default converter for property '${i}' of ${e.constructor.name}`)}s.converter=r}r.items[i]=s};class Si extends Error{constructor(){super(...arguments);this.schemas=[]}}class Ai{static parse(t,e){const i=J(t);if(i.result.error){throw new Error(i.result.error)}const r=this.fromASN(i.result,e);return r}static fromASN(t,e){try{if(ui(e)){const i=new e;return i.fromASN(t)}const i=di.get(e);di.cache(e);let r=i.schema;const s=this.handleChoiceTypes(t,i,e,r);if(s===null||s===void 0?void 0:s.result){return s.result}if(s===null||s===void 0?void 0:s.targetSchema){r=s.targetSchema}const n=this.handleSequenceTypes(t,i,e,r);if(n&&"isManualMapping"in n){return n.result}const o=n;const a=new e;if(li(e)){return this.handleArrayTypes(t,i,e)}this.processSchemaItems(i,o,a);return a}catch(t){if(t instanceof Si){t.schemas.push(e.name)}throw t}}static handleChoiceTypes(t,e,i,r){if(t.constructor===tt&&e.type===Me.Choice&&t.idBlock.tagClass===3){for(const r in e.items){const s=e.items[r];if(s.context===t.idBlock.tagNumber&&s.implicit){if(typeof s.type==="function"&&di.has(s.type)){const e=di.get(s.type);if(e&&e.type===Me.Sequence){const e=new Mt;if("value"in t.valueBlock&&Array.isArray(t.valueBlock.value)&&"value"in e.valueBlock){e.valueBlock.value=t.valueBlock.value;const n=this.fromASN(e,s.type);const o=new i;o[r]=n;return{result:o}}}}}}}else if(t.constructor===tt&&e.type!==Me.Choice){const i=new tt({idBlock:{tagClass:3,tagNumber:t.idBlock.tagNumber},value:e.schema.valueBlock.value});for(const i in e.items){delete t[i]}return{targetSchema:i}}return null}static handleSequenceTypes(t,e,i,r){if(e.type===Me.Sequence){const s=Object.keys(e.items).filter((t=>{const i=e.items[t];return i.optional&&typeof i.type==="function"&&di.has(i.type)&&di.get(i.type).type===Me.Choice}));if(s.length>0&&"value"in t.valueBlock&&Array.isArray(t.valueBlock.value)&&i.name==="CertReqMsg"){return this.handleManualMapping(t,e,i)}const n=Te({},t,r);if(!n.verified){throw new Si(`Data does not match to ${i.name} ASN1 schema. ${n.result.error}`)}return n}else{const e=Te({},t,r);if(!e.verified){throw new Si(`Data does not match to ${i.name} ASN1 schema. ${e.result.error}`)}return e}}static handleManualMapping(t,e,i){const r=new i;const s=t.valueBlock.value;const n=Object.keys(e.items);let o=0;for(let t=0;t<n.length;t++){const i=n[t];const a=e.items[i];if(o>=s.length)break;if(a.repeated){r[i]=this.processRepeatedField(s,o,a);break}else if(typeof a.type==="number"){r[i]=this.processPrimitiveField(s[o],a);o++}else if(this.isOptionalChoiceField(a)){const t=this.processOptionalChoiceField(s[o],a);if(t.processed){r[i]=t.value;o++}}else{r[i]=this.fromASN(s[o],a.type);o++}}return{result:r,verified:true,isManualMapping:true}}static processRepeatedField(t,e,i){let r=t.slice(e);if(r.length===1&&r[0].constructor.name==="Sequence"){const t=r[0];if(t.valueBlock&&t.valueBlock.value&&Array.isArray(t.valueBlock.value)){r=t.valueBlock.value}}if(typeof i.type==="number"){const t=ci(i.type);if(!t)throw new Error(`No converter for ASN.1 type ${i.type}`);return r.filter((t=>t&&t.valueBlock)).map((e=>{try{return t.fromASN(e)}catch{return undefined}})).filter((t=>t!==undefined))}else{return r.filter((t=>t&&t.valueBlock)).map((t=>{try{return this.fromASN(t,i.type)}catch{return undefined}})).filter((t=>t!==undefined))}}static processPrimitiveField(t,e){const i=ci(e.type);if(!i)throw new Error(`No converter for ASN.1 type ${e.type}`);return i.fromASN(t)}static isOptionalChoiceField(t){return t.optional&&typeof t.type==="function"&&di.has(t.type)&&di.get(t.type).type===Me.Choice}static processOptionalChoiceField(t,e){try{const i=this.fromASN(t,e.type);return{processed:true,value:i}}catch(t){if(t instanceof Si&&/Wrong values for Choice type/.test(t.message)){return{processed:false}}throw t}}static handleArrayTypes(t,e,i){if(!("value"in t.valueBlock&&Array.isArray(t.valueBlock.value))){throw new Error(`Cannot get items from the ASN.1 parsed value. ASN.1 object is not constructed.`)}const r=e.itemType;if(typeof r==="number"){const e=ci(r);if(!e){throw new Error(`Cannot get default converter for array item of ${i.name} ASN1 schema`)}return i.from(t.valueBlock.value,(t=>e.fromASN(t)))}else{return i.from(t.valueBlock.value,(t=>this.fromASN(t,r)))}}static processSchemaItems(t,e,i){for(const r in t.items){const s=e.result[r];if(!s){continue}const n=t.items[r];const o=n.type;if(typeof o==="number"||ui(o)){i[r]=this.processPrimitiveSchemaItem(s,n,o)}else{i[r]=this.processComplexSchemaItem(s,n,o)}}}static processPrimitiveSchemaItem(t,e,i){var r;const s=(r=e.converter)!==null&&r!==void 0?r:ui(i)?new i:null;if(!s){throw new Error("Converter is empty")}if(e.repeated){return this.processRepeatedPrimitiveItem(t,e,s)}else{return this.processSinglePrimitiveItem(t,e,i,s)}}static processRepeatedPrimitiveItem(t,e,i){if(e.implicit){const r=e.repeated==="sequence"?Mt:kt;const s=new r;s.valueBlock=t.valueBlock;const n=J(s.toBER(false));if(n.offset===-1){throw new Error(`Cannot parse the child item. ${n.result.error}`)}if(!("value"in n.result.valueBlock&&Array.isArray(n.result.valueBlock.value))){throw new Error("Cannot get items from the ASN.1 parsed value. ASN.1 object is not constructed.")}const o=n.result.valueBlock.value;return Array.from(o,(t=>i.fromASN(t)))}else{return Array.from(t,(t=>i.fromASN(t)))}}static processSinglePrimitiveItem(t,e,i,r){let s=t;if(e.implicit){let t;if(ui(i)){t=(new i).toSchema("")}else{const e=Ne[i];const r=Re[e];if(!r){throw new Error(`Cannot get '${e}' class from asn1js module`)}t=new r}t.valueBlock=s.valueBlock;s=J(t.toBER(false)).result}return r.fromASN(s)}static processComplexSchemaItem(t,e,i){if(e.repeated){if(!Array.isArray(t)){throw new Error("Cannot get list of items from the ASN.1 parsed value. ASN.1 value should be iterable.")}return Array.from(t,(t=>this.fromASN(t,i)))}else{const r=this.handleImplicitTagging(t,e,i);if(this.isOptionalChoiceField(e)){try{return this.fromASN(r,i)}catch(t){if(t instanceof Si&&/Wrong values for Choice type/.test(t.message)){return undefined}throw t}}else{return this.fromASN(r,i)}}}static handleImplicitTagging(t,e,i){if(e.implicit&&typeof e.context==="number"){const e=di.get(i);if(e.type===Me.Sequence){const e=new Mt;if("value"in t.valueBlock&&Array.isArray(t.valueBlock.value)&&"value"in e.valueBlock){e.valueBlock.value=t.valueBlock.value;return e}}else if(e.type===Me.Set){const e=new kt;if("value"in t.valueBlock&&Array.isArray(t.valueBlock.value)&&"value"in e.valueBlock){e.valueBlock.value=t.valueBlock.value;return e}}}return t}}class Ci{static serialize(t){if(t instanceof V){return t.toBER(false)}return this.toASN(t).toBER(false)}static toASN(t){if(t&&typeof t==="object"&&ui(t)){return t.toASN()}if(!(t&&typeof t==="object")){throw new TypeError("Parameter 1 should be type of Object.")}const e=t.constructor;const i=di.get(e);di.cache(e);let r=[];if(i.itemType){if(!Array.isArray(t)){throw new TypeError("Parameter 1 should be type of Array.")}if(typeof i.itemType==="number"){const s=ci(i.itemType);if(!s){throw new Error(`Cannot get default converter for array item of ${e.name} ASN1 schema`)}r=t.map((t=>s.toASN(t)))}else{r=t.map((t=>this.toAsnItem({type:i.itemType},"[]",e,t)))}}else{for(const s in i.items){const n=i.items[s];const o=t[s];if(o===undefined||n.defaultValue===o||typeof n.defaultValue==="object"&&typeof o==="object"&&pi(this.serialize(n.defaultValue),this.serialize(o))){continue}const a=Ci.toAsnItem(n,s,e,o);if(typeof n.context==="number"){if(n.implicit){if(!n.repeated&&(typeof n.type==="number"||ui(n.type))){const t={};t.valueHex=a instanceof nt?a.valueBeforeDecodeView:a.valueBlock.toBER();r.push(new Q({optional:n.optional,idBlock:{tagClass:3,tagNumber:n.context},...t}))}else{r.push(new tt({optional:n.optional,idBlock:{tagClass:3,tagNumber:n.context},value:a.valueBlock.value}))}}else{r.push(new tt({optional:n.optional,idBlock:{tagClass:3,tagNumber:n.context},value:[a]}))}}else if(n.repeated){r=r.concat(a)}else{r.push(a)}}}let s;switch(i.type){case Me.Sequence:s=new Mt({value:r});break;case Me.Set:s=new kt({value:r});break;case Me.Choice:if(!r[0]){throw new Error(`Schema '${e.name}' has wrong data. Choice cannot be empty.`)}s=r[0];break}return s}static toAsnItem(t,e,i,r){let s;if(typeof t.type==="number"){const n=t.converter;if(!n){throw new Error(`Property '${e}' doesn't have converter for type ${Ne[t.type]} in schema '${i.name}'`)}if(t.repeated){if(!Array.isArray(r)){throw new TypeError("Parameter 'objProp' should be type of Array.")}const e=Array.from(r,(t=>n.toASN(t)));const i=t.repeated==="sequence"?Mt:kt;s=new i({value:e})}else{s=n.toASN(r)}}else{if(t.repeated){if(!Array.isArray(r)){throw new TypeError("Parameter 'objProp' should be type of Array.")}const e=Array.from(r,(t=>this.toASN(t)));const i=t.repeated==="sequence"?Mt:kt;s=new i({value:e})}else{s=this.toASN(r)}}return s}}class vi extends Array{constructor(t=[]){if(typeof t==="number"){super(t)}else{super();for(const e of t){this.push(e)}}}}class mi{static serialize(t){return Ci.serialize(t)}static parse(t,e){return Ai.parse(t,e)}static toString(t){const e=n.BufferSourceConverter.isBufferSource(t)?n.BufferSourceConverter.toArrayBuffer(t):mi.serialize(t);const i=J(e);if(i.offset===-1){throw new Error(`Cannot decode ASN.1 data. ${i.result.error}`)}return i.result.toString()}}function gi(t,e,i,r){var s=arguments.length,n=s<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,o;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")n=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)if(o=t[a])n=(s<3?o(n):s>3?o(e,i,n):o(e,i))||n;return s>3&&n&&Object.defineProperty(e,i,n),n}typeof SuppressedError==="function"?SuppressedError:function(t,e,i){var r=new Error(i);return r.name="SuppressedError",r.error=t,r.suppressed=e,r};class wi{static isIPv4(t){return/^(\d{1,3}\.){3}\d{1,3}$/.test(t)}static parseIPv4(t){const e=t.split(".");if(e.length!==4){throw new Error("Invalid IPv4 address")}return e.map((t=>{const e=parseInt(t,10);if(isNaN(e)||e<0||e>255){throw new Error("Invalid IPv4 address part")}return e}))}static parseIPv6(t){const e=this.expandIPv6(t);const i=e.split(":");if(i.length!==8){throw new Error("Invalid IPv6 address")}return i.reduce(((t,e)=>{const i=parseInt(e,16);if(isNaN(i)||i<0||i>65535){throw new Error("Invalid IPv6 address part")}t.push(i>>8&255);t.push(i&255);return t}),[])}static expandIPv6(t){if(!t.includes("::")){return t}const e=t.split("::");if(e.length>2){throw new Error("Invalid IPv6 address")}const i=e[0]?e[0].split(":"):[];const r=e[1]?e[1].split(":"):[];const s=8-(i.length+r.length);if(s<0){throw new Error("Invalid IPv6 address")}return[...i,...Array(s).fill("0"),...r].join(":")}static formatIPv6(t){const e=[];for(let i=0;i<16;i+=2){e.push((t[i]<<8|t[i+1]).toString(16))}return this.compressIPv6(e.join(":"))}static compressIPv6(t){const e=t.split(":");let i=-1;let r=0;let s=-1;let n=0;for(let t=0;t<e.length;t++){if(e[t]==="0"){if(s===-1){s=t}n++}else{if(n>r){i=s;r=n}s=-1;n=0}}if(n>r){i=s;r=n}if(r>1){const t=e.slice(0,i).join(":");const s=e.slice(i+r).join(":");return`${t}::${s}`}return t}static parseCIDR(t){const[e,i]=t.split("/");const r=parseInt(i,10);if(this.isIPv4(e)){if(r<0||r>32){throw new Error("Invalid IPv4 prefix length")}return[this.parseIPv4(e),r]}else{if(r<0||r>128){throw new Error("Invalid IPv6 prefix length")}return[this.parseIPv6(e),r]}}static decodeIP(t){if(t.length===64&&parseInt(t,16)===0){return"::/0"}if(t.length!==16){return t}const e=parseInt(t.slice(8),16).toString(2).split("").reduce(((t,e)=>t+ +e),0);let i=t.slice(0,8).replace(/(.{2})/g,(t=>`${parseInt(t,16)}.`));i=i.slice(0,-1);return`${i}/${e}`}static toString(t){const e=new Uint8Array(t);if(e.length===4){return Array.from(e).join(".")}if(e.length===16){return this.formatIPv6(e)}if(e.length===8||e.length===32){const t=e.length/2;const i=e.slice(0,t);const r=e.slice(t);const s=e.every((t=>t===0));if(s){return e.length===8?"0.0.0.0/0":"::/0"}const n=r.reduce(((t,e)=>t+(e.toString(2).match(/1/g)||[]).length),0);if(e.length===8){const t=Array.from(i).join(".");return`${t}/${n}`}else{const t=this.formatIPv6(i);return`${t}/${n}`}}return this.decodeIP(n.Convert.ToHex(t))}static fromString(t){if(t.includes("/")){const[e,i]=this.parseCIDR(t);const r=new Uint8Array(e.length);let s=i;for(let t=0;t<r.length;t++){if(s>=8){r[t]=255;s-=8}else if(s>0){r[t]=255<<8-s;s=0}}const n=new Uint8Array(e.length*2);n.set(e,0);n.set(r,e.length);return n.buffer}const e=this.isIPv4(t)?this.parseIPv4(t):this.parseIPv6(t);return new Uint8Array(e).buffer}}var Ei,Pi,Di;let bi=class t{constructor(t={}){Object.assign(this,t)}toString(){return this.bmpString||this.printableString||this.teletexString||this.universalString||this.utf8String||""}};gi([yi({type:Ne.TeletexString})],bi.prototype,"teletexString",void 0);gi([yi({type:Ne.PrintableString})],bi.prototype,"printableString",void 0);gi([yi({type:Ne.UniversalString})],bi.prototype,"universalString",void 0);gi([yi({type:Ne.Utf8String})],bi.prototype,"utf8String",void 0);gi([yi({type:Ne.BmpString})],bi.prototype,"bmpString",void 0);bi=gi([fi({type:Me.Choice})],bi);let Bi=class t extends bi{constructor(t={}){super(t);Object.assign(this,t)}toString(){return this.ia5String||(this.anyValue?n.Convert.ToHex(this.anyValue):super.toString())}};gi([yi({type:Ne.IA5String})],Bi.prototype,"ia5String",void 0);gi([yi({type:Ne.Any})],Bi.prototype,"anyValue",void 0);Bi=gi([fi({type:Me.Choice})],Bi);class Ii{constructor(t={}){this.type="";this.value=new Bi;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Ii.prototype,"type",void 0);gi([yi({type:Bi})],Ii.prototype,"value",void 0);let xi=Ei=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Ei.prototype)}};xi=Ei=gi([fi({type:Me.Set,itemType:Ii})],xi);let Ti=Pi=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Pi.prototype)}};Ti=Pi=gi([fi({type:Me.Sequence,itemType:xi})],Ti);let Oi=Di=class t extends Ti{constructor(t){super(t);Object.setPrototypeOf(this,Di.prototype)}};Oi=Di=gi([fi({type:Me.Sequence})],Oi);const Ri={fromASN:t=>wi.toString($e.fromASN(t)),toASN:t=>$e.toASN(wi.fromString(t))};class Mi{constructor(t={}){this.typeId="";this.value=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Mi.prototype,"typeId",void 0);gi([yi({type:Ne.Any,context:0})],Mi.prototype,"value",void 0);class Ni{constructor(t={}){this.partyName=new bi;Object.assign(this,t)}}gi([yi({type:bi,optional:true,context:0,implicit:true})],Ni.prototype,"nameAssigner",void 0);gi([yi({type:bi,context:1,implicit:true})],Ni.prototype,"partyName",void 0);let ki=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Mi,context:0,implicit:true})],ki.prototype,"otherName",void 0);gi([yi({type:Ne.IA5String,context:1,implicit:true})],ki.prototype,"rfc822Name",void 0);gi([yi({type:Ne.IA5String,context:2,implicit:true})],ki.prototype,"dNSName",void 0);gi([yi({type:Ne.Any,context:3,implicit:true})],ki.prototype,"x400Address",void 0);gi([yi({type:Oi,context:4,implicit:false})],ki.prototype,"directoryName",void 0);gi([yi({type:Ni,context:5})],ki.prototype,"ediPartyName",void 0);gi([yi({type:Ne.IA5String,context:6,implicit:true})],ki.prototype,"uniformResourceIdentifier",void 0);gi([yi({type:Ne.OctetString,context:7,implicit:true,converter:Ri})],ki.prototype,"iPAddress",void 0);gi([yi({type:Ne.ObjectIdentifier,context:8,implicit:true})],ki.prototype,"registeredID",void 0);ki=gi([fi({type:Me.Choice})],ki);const Ki="1.3.6.1.5.5.7";const Hi=`${Ki}.1`;const ji="2.5.29";var Ui;const Fi=`${Hi}.1`;class _i{constructor(t={}){this.accessMethod="";this.accessLocation=new ki;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],_i.prototype,"accessMethod",void 0);gi([yi({type:ki})],_i.prototype,"accessLocation",void 0);let Vi=Ui=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Ui.prototype)}};Vi=Ui=gi([fi({type:Me.Sequence,itemType:_i})],Vi);const Li=`${ji}.35`;class $i extends Ke{}class Gi{constructor(t={}){if(t){Object.assign(this,t)}}}gi([yi({type:$i,context:0,optional:true,implicit:true})],Gi.prototype,"keyIdentifier",void 0);gi([yi({type:ki,context:1,optional:true,implicit:true,repeated:"sequence"})],Gi.prototype,"authorityCertIssuer",void 0);gi([yi({type:Ne.Integer,context:2,optional:true,implicit:true,converter:Fe})],Gi.prototype,"authorityCertSerialNumber",void 0);const Wi=`${ji}.19`;class Qi{constructor(t={}){this.cA=false;Object.assign(this,t)}}gi([yi({type:Ne.Boolean,defaultValue:false})],Qi.prototype,"cA",void 0);gi([yi({type:Ne.Integer,optional:true})],Qi.prototype,"pathLenConstraint",void 0);var qi;let zi=qi=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,qi.prototype)}};zi=qi=gi([fi({type:Me.Sequence,itemType:ki})],zi);var Ji;const Zi=`${ji}.29`;let Xi=Ji=class t extends zi{constructor(t){super(t);Object.setPrototypeOf(this,Ji.prototype)}};Xi=Ji=gi([fi({type:Me.Sequence})],Xi);var Yi;const tr=`${ji}.32`;let er=class t{constructor(t={}){Object.assign(this,t)}toString(){return this.ia5String||this.visibleString||this.bmpString||this.utf8String||""}};gi([yi({type:Ne.IA5String})],er.prototype,"ia5String",void 0);gi([yi({type:Ne.VisibleString})],er.prototype,"visibleString",void 0);gi([yi({type:Ne.BmpString})],er.prototype,"bmpString",void 0);gi([yi({type:Ne.Utf8String})],er.prototype,"utf8String",void 0);er=gi([fi({type:Me.Choice})],er);class ir{constructor(t={}){this.organization=new er;this.noticeNumbers=[];Object.assign(this,t)}}gi([yi({type:er})],ir.prototype,"organization",void 0);gi([yi({type:Ne.Integer,repeated:"sequence"})],ir.prototype,"noticeNumbers",void 0);class rr{constructor(t={}){Object.assign(this,t)}}gi([yi({type:ir,optional:true})],rr.prototype,"noticeRef",void 0);gi([yi({type:er,optional:true})],rr.prototype,"explicitText",void 0);let sr=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.IA5String})],sr.prototype,"cPSuri",void 0);gi([yi({type:rr})],sr.prototype,"userNotice",void 0);sr=gi([fi({type:Me.Choice})],sr);class nr{constructor(t={}){this.policyQualifierId="";this.qualifier=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],nr.prototype,"policyQualifierId",void 0);gi([yi({type:Ne.Any})],nr.prototype,"qualifier",void 0);class or{constructor(t={}){this.policyIdentifier="";Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],or.prototype,"policyIdentifier",void 0);gi([yi({type:nr,repeated:"sequence",optional:true})],or.prototype,"policyQualifiers",void 0);let ar=Yi=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Yi.prototype)}};ar=Yi=gi([fi({type:Me.Sequence,itemType:or})],ar);const cr=`${ji}.20`;let ur=class t{constructor(t=0){this.value=t}};gi([yi({type:Ne.Integer})],ur.prototype,"value",void 0);ur=gi([fi({type:Me.Choice})],ur);const lr=`${ji}.27`;let pr=class t extends ur{};pr=gi([fi({type:Me.Choice})],pr);var hr;const dr=`${ji}.31`;var fr;(function(t){t[t["unused"]=1]="unused";t[t["keyCompromise"]=2]="keyCompromise";t[t["cACompromise"]=4]="cACompromise";t[t["affiliationChanged"]=8]="affiliationChanged";t[t["superseded"]=16]="superseded";t[t["cessationOfOperation"]=32]="cessationOfOperation";t[t["certificateHold"]=64]="certificateHold";t[t["privilegeWithdrawn"]=128]="privilegeWithdrawn";t[t["aACompromise"]=256]="aACompromise"})(fr||(fr={}));class yr extends ke{toJSON(){const t=[];const e=this.toNumber();if(e&fr.aACompromise){t.push("aACompromise")}if(e&fr.affiliationChanged){t.push("affiliationChanged")}if(e&fr.cACompromise){t.push("cACompromise")}if(e&fr.certificateHold){t.push("certificateHold")}if(e&fr.cessationOfOperation){t.push("cessationOfOperation")}if(e&fr.keyCompromise){t.push("keyCompromise")}if(e&fr.privilegeWithdrawn){t.push("privilegeWithdrawn")}if(e&fr.superseded){t.push("superseded")}if(e&fr.unused){t.push("unused")}return t}toString(){return`[${this.toJSON().join(", ")}]`}}let Sr=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ki,context:0,repeated:"sequence",implicit:true})],Sr.prototype,"fullName",void 0);gi([yi({type:xi,context:1,implicit:true})],Sr.prototype,"nameRelativeToCRLIssuer",void 0);Sr=gi([fi({type:Me.Choice})],Sr);class Ar{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Sr,context:0,optional:true})],Ar.prototype,"distributionPoint",void 0);gi([yi({type:yr,context:1,optional:true,implicit:true})],Ar.prototype,"reasons",void 0);gi([yi({type:ki,context:2,optional:true,repeated:"sequence",implicit:true})],Ar.prototype,"cRLIssuer",void 0);let Cr=hr=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,hr.prototype)}};Cr=hr=gi([fi({type:Me.Sequence,itemType:Ar})],Cr);var vr;let mr=vr=class t extends Cr{constructor(t){super(t);Object.setPrototypeOf(this,vr.prototype)}};mr=vr=gi([fi({type:Me.Sequence,itemType:Ar})],mr);const gr=`${ji}.28`;class wr{constructor(t={}){this.onlyContainsUserCerts=wr.ONLY;this.onlyContainsCACerts=wr.ONLY;this.indirectCRL=wr.ONLY;this.onlyContainsAttributeCerts=wr.ONLY;Object.assign(this,t)}}wr.ONLY=false;gi([yi({type:Sr,context:0,optional:true})],wr.prototype,"distributionPoint",void 0);gi([yi({type:Ne.Boolean,context:1,defaultValue:wr.ONLY,implicit:true})],wr.prototype,"onlyContainsUserCerts",void 0);gi([yi({type:Ne.Boolean,context:2,defaultValue:wr.ONLY,implicit:true})],wr.prototype,"onlyContainsCACerts",void 0);gi([yi({type:yr,context:3,optional:true,implicit:true})],wr.prototype,"onlySomeReasons",void 0);gi([yi({type:Ne.Boolean,context:4,defaultValue:wr.ONLY,implicit:true})],wr.prototype,"indirectCRL",void 0);gi([yi({type:Ne.Boolean,context:5,defaultValue:wr.ONLY,implicit:true})],wr.prototype,"onlyContainsAttributeCerts",void 0);const Er=`${ji}.21`;var Pr;(function(t){t[t["unspecified"]=0]="unspecified";t[t["keyCompromise"]=1]="keyCompromise";t[t["cACompromise"]=2]="cACompromise";t[t["affiliationChanged"]=3]="affiliationChanged";t[t["superseded"]=4]="superseded";t[t["cessationOfOperation"]=5]="cessationOfOperation";t[t["certificateHold"]=6]="certificateHold";t[t["removeFromCRL"]=8]="removeFromCRL";t[t["privilegeWithdrawn"]=9]="privilegeWithdrawn";t[t["aACompromise"]=10]="aACompromise"})(Pr||(Pr={}));let Dr=class t{constructor(t=Pr.unspecified){this.reason=Pr.unspecified;this.reason=t}toJSON(){return Pr[this.reason]}toString(){return this.toJSON()}};gi([yi({type:Ne.Enumerated})],Dr.prototype,"reason",void 0);Dr=gi([fi({type:Me.Choice})],Dr);var br;const Br=`${ji}.37`;let Ir=br=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,br.prototype)}};Ir=br=gi([fi({type:Me.Sequence,itemType:Ne.ObjectIdentifier})],Ir);const xr=`${ji}.54`;let Tr=class t{constructor(t=new ArrayBuffer(0)){this.value=t}};gi([yi({type:Ne.Integer,converter:Fe})],Tr.prototype,"value",void 0);Tr=gi([fi({type:Me.Choice})],Tr);const Or=`${ji}.24`;let Rr=class t{constructor(t){this.value=new Date;if(t){this.value=t}}};gi([yi({type:Ne.GeneralizedTime})],Rr.prototype,"value",void 0);Rr=gi([fi({type:Me.Choice})],Rr);var Mr;const Nr=`${ji}.18`;let kr=Mr=class t extends zi{constructor(t){super(t);Object.setPrototypeOf(this,Mr.prototype)}};kr=Mr=gi([fi({type:Me.Sequence})],kr);const Kr=`${ji}.15`;var Hr;(function(t){t[t["digitalSignature"]=1]="digitalSignature";t[t["nonRepudiation"]=2]="nonRepudiation";t[t["keyEncipherment"]=4]="keyEncipherment";t[t["dataEncipherment"]=8]="dataEncipherment";t[t["keyAgreement"]=16]="keyAgreement";t[t["keyCertSign"]=32]="keyCertSign";t[t["cRLSign"]=64]="cRLSign";t[t["encipherOnly"]=128]="encipherOnly";t[t["decipherOnly"]=256]="decipherOnly"})(Hr||(Hr={}));class jr extends ke{toJSON(){const t=this.toNumber();const e=[];if(t&Hr.cRLSign){e.push("crlSign")}if(t&Hr.dataEncipherment){e.push("dataEncipherment")}if(t&Hr.decipherOnly){e.push("decipherOnly")}if(t&Hr.digitalSignature){e.push("digitalSignature")}if(t&Hr.encipherOnly){e.push("encipherOnly")}if(t&Hr.keyAgreement){e.push("keyAgreement")}if(t&Hr.keyCertSign){e.push("keyCertSign")}if(t&Hr.keyEncipherment){e.push("keyEncipherment")}if(t&Hr.nonRepudiation){e.push("nonRepudiation")}return e}toString(){return`[${this.toJSON().join(", ")}]`}}var Ur;const Fr=`${ji}.30`;class _r{constructor(t={}){this.base=new ki;this.minimum=0;Object.assign(this,t)}}gi([yi({type:ki})],_r.prototype,"base",void 0);gi([yi({type:Ne.Integer,context:0,defaultValue:0,implicit:true})],_r.prototype,"minimum",void 0);gi([yi({type:Ne.Integer,context:1,optional:true,implicit:true})],_r.prototype,"maximum",void 0);let Vr=Ur=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Ur.prototype)}};Vr=Ur=gi([fi({type:Me.Sequence,itemType:_r})],Vr);class Lr{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Vr,context:0,optional:true,implicit:true})],Lr.prototype,"permittedSubtrees",void 0);gi([yi({type:Vr,context:1,optional:true,implicit:true})],Lr.prototype,"excludedSubtrees",void 0);const $r=`${ji}.36`;class Gr{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ne.Integer,context:0,implicit:true,optional:true,converter:Fe})],Gr.prototype,"requireExplicitPolicy",void 0);gi([yi({type:Ne.Integer,context:1,implicit:true,optional:true,converter:Fe})],Gr.prototype,"inhibitPolicyMapping",void 0);var Wr;const Qr=`${ji}.33`;class qr{constructor(t={}){this.issuerDomainPolicy="";this.subjectDomainPolicy="";Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],qr.prototype,"issuerDomainPolicy",void 0);gi([yi({type:Ne.ObjectIdentifier})],qr.prototype,"subjectDomainPolicy",void 0);let zr=Wr=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Wr.prototype)}};zr=Wr=gi([fi({type:Me.Sequence,itemType:qr})],zr);var Jr;const Zr=`${ji}.17`;let Xr=Jr=class t extends zi{constructor(t){super(t);Object.setPrototypeOf(this,Jr.prototype)}};Xr=Jr=gi([fi({type:Me.Sequence})],Xr);let Yr=class t{constructor(t={}){this.type="";this.values=[];Object.assign(this,t)}};gi([yi({type:Ne.ObjectIdentifier})],Yr.prototype,"type",void 0);gi([yi({type:Ne.Any,repeated:"set"})],Yr.prototype,"values",void 0);var ts;const es=`${ji}.9`;let is=ts=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ts.prototype)}};is=ts=gi([fi({type:Me.Sequence,itemType:Yr})],is);const rs=`${ji}.14`;class ss extends $i{}const ns=`${ji}.16`;class os{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ne.GeneralizedTime,context:0,implicit:true,optional:true})],os.prototype,"notBefore",void 0);gi([yi({type:Ne.GeneralizedTime,context:1,implicit:true,optional:true})],os.prototype,"notAfter",void 0);const as="1.2.840.113533.7.65.0";var cs;(function(t){t[t["keyUpdateAllowed"]=1]="keyUpdateAllowed";t[t["newExtensions"]=2]="newExtensions";t[t["pKIXCertificate"]=4]="pKIXCertificate"})(cs||(cs={}));class us extends ke{toJSON(){const t=[];const e=this.toNumber();if(e&cs.pKIXCertificate){t.push("pKIXCertificate")}if(e&cs.newExtensions){t.push("newExtensions")}if(e&cs.keyUpdateAllowed){t.push("keyUpdateAllowed")}return t}toString(){return`[${this.toJSON().join(", ")}]`}}class ls{constructor(t={}){this.entrustVers="";this.entrustInfoFlags=new us;Object.assign(this,t)}}gi([yi({type:Ne.GeneralString})],ls.prototype,"entrustVers",void 0);gi([yi({type:us})],ls.prototype,"entrustInfoFlags",void 0);var ps;const hs=`${Hi}.11`;let ds=ps=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ps.prototype)}};ds=ps=gi([fi({type:Me.Sequence,itemType:_i})],ds);class fs{constructor(t={}){this.algorithm="";Object.assign(this,t)}isEqual(t){return t instanceof fs&&t.algorithm==this.algorithm&&(t.parameters&&this.parameters&&n.isEqual(t.parameters,this.parameters)||t.parameters===this.parameters)}}gi([yi({type:Ne.ObjectIdentifier})],fs.prototype,"algorithm",void 0);gi([yi({type:Ne.Any,optional:true})],fs.prototype,"parameters",void 0);class ys{constructor(t={}){this.algorithm=new fs;this.subjectPublicKey=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:fs})],ys.prototype,"algorithm",void 0);gi([yi({type:Ne.BitString})],ys.prototype,"subjectPublicKey",void 0);let Ss=class t{constructor(t){if(t){if(typeof t==="string"||typeof t==="number"||t instanceof Date){const e=new Date(t);if(e.getUTCFullYear()>2049){this.generalTime=e}else{this.utcTime=e}}else{Object.assign(this,t)}}}getTime(){const t=this.utcTime||this.generalTime;if(!t){throw new Error("Cannot get time from CHOICE object")}return t}};gi([yi({type:Ne.UTCTime})],Ss.prototype,"utcTime",void 0);gi([yi({type:Ne.GeneralizedTime})],Ss.prototype,"generalTime",void 0);Ss=gi([fi({type:Me.Choice})],Ss);class As{constructor(t){this.notBefore=new Ss(new Date);this.notAfter=new Ss(new Date);if(t){this.notBefore=new Ss(t.notBefore);this.notAfter=new Ss(t.notAfter)}}}gi([yi({type:Ss})],As.prototype,"notBefore",void 0);gi([yi({type:Ss})],As.prototype,"notAfter",void 0);var Cs;let vs=class t{constructor(e={}){this.extnID="";this.critical=t.CRITICAL;this.extnValue=new Ke;Object.assign(this,e)}};vs.CRITICAL=false;gi([yi({type:Ne.ObjectIdentifier})],vs.prototype,"extnID",void 0);gi([yi({type:Ne.Boolean,defaultValue:vs.CRITICAL})],vs.prototype,"critical",void 0);gi([yi({type:Ke})],vs.prototype,"extnValue",void 0);let ms=Cs=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Cs.prototype)}};ms=Cs=gi([fi({type:Me.Sequence,itemType:vs})],ms);var gs;(function(t){t[t["v1"]=0]="v1";t[t["v2"]=1]="v2";t[t["v3"]=2]="v3"})(gs||(gs={}));class ws{constructor(t={}){this.version=gs.v1;this.serialNumber=new ArrayBuffer(0);this.signature=new fs;this.issuer=new Oi;this.validity=new As;this.subject=new Oi;this.subjectPublicKeyInfo=new ys;Object.assign(this,t)}}gi([yi({type:Ne.Integer,context:0,defaultValue:gs.v1})],ws.prototype,"version",void 0);gi([yi({type:Ne.Integer,converter:Fe})],ws.prototype,"serialNumber",void 0);gi([yi({type:fs})],ws.prototype,"signature",void 0);gi([yi({type:Oi})],ws.prototype,"issuer",void 0);gi([yi({type:As})],ws.prototype,"validity",void 0);gi([yi({type:Oi})],ws.prototype,"subject",void 0);gi([yi({type:ys})],ws.prototype,"subjectPublicKeyInfo",void 0);gi([yi({type:Ne.BitString,context:1,implicit:true,optional:true})],ws.prototype,"issuerUniqueID",void 0);gi([yi({type:Ne.BitString,context:2,implicit:true,optional:true})],ws.prototype,"subjectUniqueID",void 0);gi([yi({type:ms,context:3,optional:true})],ws.prototype,"extensions",void 0);class Es{constructor(t={}){this.tbsCertificate=new ws;this.signatureAlgorithm=new fs;this.signatureValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:ws})],Es.prototype,"tbsCertificate",void 0);gi([yi({type:fs})],Es.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ne.BitString})],Es.prototype,"signatureValue",void 0);class Ps{constructor(t={}){this.userCertificate=new ArrayBuffer(0);this.revocationDate=new Ss;Object.assign(this,t)}}gi([yi({type:Ne.Integer,converter:Fe})],Ps.prototype,"userCertificate",void 0);gi([yi({type:Ss})],Ps.prototype,"revocationDate",void 0);gi([yi({type:vs,optional:true,repeated:"sequence"})],Ps.prototype,"crlEntryExtensions",void 0);class Ds{constructor(t={}){this.signature=new fs;this.issuer=new Oi;this.thisUpdate=new Ss;Object.assign(this,t)}}gi([yi({type:Ne.Integer,optional:true})],Ds.prototype,"version",void 0);gi([yi({type:fs})],Ds.prototype,"signature",void 0);gi([yi({type:Oi})],Ds.prototype,"issuer",void 0);gi([yi({type:Ss})],Ds.prototype,"thisUpdate",void 0);gi([yi({type:Ss,optional:true})],Ds.prototype,"nextUpdate",void 0);gi([yi({type:Ps,repeated:"sequence",optional:true})],Ds.prototype,"revokedCertificates",void 0);gi([yi({type:vs,optional:true,context:0,repeated:"sequence"})],Ds.prototype,"crlExtensions",void 0);class bs{constructor(t={}){this.tbsCertList=new Ds;this.signatureAlgorithm=new fs;this.signature=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ds})],bs.prototype,"tbsCertList",void 0);gi([yi({type:fs})],bs.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ne.BitString})],bs.prototype,"signature",void 0);const Bs="1.2.840.10045.2.1";const Is="1.2.840.10045.4.1";const xs="1.2.840.10045.4.3.1";const Ts="1.2.840.10045.4.3.2";const Os="1.2.840.10045.4.3.3";const Rs="1.2.840.10045.4.3.4";function Ms(t){return new fs({algorithm:t})}Ms(Is);Ms(xs);Ms(Ts);Ms(Os);Ms(Rs);let Ns=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.ObjectIdentifier})],Ns.prototype,"fieldType",void 0);gi([yi({type:Ne.Any})],Ns.prototype,"parameters",void 0);Ns=gi([fi({type:Me.Sequence})],Ns);class ks extends Ke{}let Ks=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.OctetString})],Ks.prototype,"a",void 0);gi([yi({type:Ne.OctetString})],Ks.prototype,"b",void 0);gi([yi({type:Ne.BitString,optional:true})],Ks.prototype,"seed",void 0);Ks=gi([fi({type:Me.Sequence})],Ks);var Hs;(function(t){t[t["ecpVer1"]=1]="ecpVer1"})(Hs||(Hs={}));let js=class t{constructor(t={}){this.version=Hs.ecpVer1;Object.assign(this,t)}};gi([yi({type:Ne.Integer})],js.prototype,"version",void 0);gi([yi({type:Ns})],js.prototype,"fieldID",void 0);gi([yi({type:Ks})],js.prototype,"curve",void 0);gi([yi({type:ks})],js.prototype,"base",void 0);gi([yi({type:Ne.Integer,converter:Fe})],js.prototype,"order",void 0);gi([yi({type:Ne.Integer,optional:true})],js.prototype,"cofactor",void 0);js=gi([fi({type:Me.Sequence})],js);let Us=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.ObjectIdentifier})],Us.prototype,"namedCurve",void 0);gi([yi({type:Ne.Null})],Us.prototype,"implicitCurve",void 0);gi([yi({type:js})],Us.prototype,"specifiedCurve",void 0);Us=gi([fi({type:Me.Choice})],Us);class Fs{constructor(t={}){this.version=1;this.privateKey=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Fs.prototype,"version",void 0);gi([yi({type:Ke})],Fs.prototype,"privateKey",void 0);gi([yi({type:Us,context:0,optional:true})],Fs.prototype,"parameters",void 0);gi([yi({type:Ne.BitString,context:1,optional:true})],Fs.prototype,"publicKey",void 0);class _s{constructor(t={}){this.r=new ArrayBuffer(0);this.s=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer,converter:Fe})],_s.prototype,"r",void 0);gi([yi({type:Ne.Integer,converter:Fe})],_s.prototype,"s",void 0);const Vs="1.2.840.113549.1.1";const Ls=`${Vs}.1`;const $s=`${Vs}.7`;const Gs=`${Vs}.9`;const Ws=`${Vs}.10`;const Qs=`${Vs}.2`;const qs=`${Vs}.4`;const zs=`${Vs}.5`;const Js=`${Vs}.12`;const Zs=`${Vs}.13`;const Xs=`${Vs}.15`;const Ys=`${Vs}.16`;const tn="1.3.14.3.2.26";const en="2.16.840.1.101.3.4.2.4";const rn="2.16.840.1.101.3.4.2.1";const sn="2.16.840.1.101.3.4.2.2";const nn="2.16.840.1.101.3.4.2.3";const on="2.16.840.1.101.3.4.2.5";const an="2.16.840.1.101.3.4.2.6";const cn="1.2.840.113549.2.2";const un="1.2.840.113549.2.5";const ln=`${Vs}.8`;function pn(t){return new fs({algorithm:t,parameters:null})}pn(cn);pn(un);const hn=pn(tn);pn(en);pn(rn);pn(sn);pn(nn);pn(on);pn(an);const dn=new fs({algorithm:ln,parameters:mi.serialize(hn)});const fn=new fs({algorithm:Gs,parameters:mi.serialize($e.toASN(new Uint8Array([218,57,163,238,94,107,75,13,50,85,191,239,149,96,24,144,175,216,7,9]).buffer))});pn(Ls);pn(Qs);pn(qs);pn(zs);pn(Xs);pn(Ys);pn(Js);pn(Zs);pn(Xs);pn(Ys);class yn{constructor(t={}){this.hashAlgorithm=new fs(hn);this.maskGenAlgorithm=new fs({algorithm:ln,parameters:mi.serialize(hn)});this.pSourceAlgorithm=new fs(fn);Object.assign(this,t)}}gi([yi({type:fs,context:0,defaultValue:hn})],yn.prototype,"hashAlgorithm",void 0);gi([yi({type:fs,context:1,defaultValue:dn})],yn.prototype,"maskGenAlgorithm",void 0);gi([yi({type:fs,context:2,defaultValue:fn})],yn.prototype,"pSourceAlgorithm",void 0);new fs({algorithm:$s,parameters:mi.serialize(new yn)});class Sn{constructor(t={}){this.hashAlgorithm=new fs(hn);this.maskGenAlgorithm=new fs({algorithm:ln,parameters:mi.serialize(hn)});this.saltLength=20;this.trailerField=1;Object.assign(this,t)}}gi([yi({type:fs,context:0,defaultValue:hn})],Sn.prototype,"hashAlgorithm",void 0);gi([yi({type:fs,context:1,defaultValue:dn})],Sn.prototype,"maskGenAlgorithm",void 0);gi([yi({type:Ne.Integer,context:2,defaultValue:20})],Sn.prototype,"saltLength",void 0);gi([yi({type:Ne.Integer,context:3,defaultValue:1})],Sn.prototype,"trailerField",void 0);new fs({algorithm:Ws,parameters:mi.serialize(new Sn)});class An{constructor(t={}){this.digestAlgorithm=new fs;this.digest=new Ke;Object.assign(this,t)}}gi([yi({type:fs})],An.prototype,"digestAlgorithm",void 0);gi([yi({type:Ke})],An.prototype,"digest",void 0);var Cn;class vn{constructor(t={}){this.prime=new ArrayBuffer(0);this.exponent=new ArrayBuffer(0);this.coefficient=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer,converter:Fe})],vn.prototype,"prime",void 0);gi([yi({type:Ne.Integer,converter:Fe})],vn.prototype,"exponent",void 0);gi([yi({type:Ne.Integer,converter:Fe})],vn.prototype,"coefficient",void 0);let mn=Cn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Cn.prototype)}};mn=Cn=gi([fi({type:Me.Sequence,itemType:vn})],mn);class gn{constructor(t={}){this.version=0;this.modulus=new ArrayBuffer(0);this.publicExponent=new ArrayBuffer(0);this.privateExponent=new ArrayBuffer(0);this.prime1=new ArrayBuffer(0);this.prime2=new ArrayBuffer(0);this.exponent1=new ArrayBuffer(0);this.exponent2=new ArrayBuffer(0);this.coefficient=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer})],gn.prototype,"version",void 0);gi([yi({type:Ne.Integer,converter:Fe})],gn.prototype,"modulus",void 0);gi([yi({type:Ne.Integer,converter:Fe})],gn.prototype,"publicExponent",void 0);gi([yi({type:Ne.Integer,converter:Fe})],gn.prototype,"privateExponent",void 0);gi([yi({type:Ne.Integer,converter:Fe})],gn.prototype,"prime1",void 0);gi([yi({type:Ne.Integer,converter:Fe})],gn.prototype,"prime2",void 0);gi([yi({type:Ne.Integer,converter:Fe})],gn.prototype,"exponent1",void 0);gi([yi({type:Ne.Integer,converter:Fe})],gn.prototype,"exponent2",void 0);gi([yi({type:Ne.Integer,converter:Fe})],gn.prototype,"coefficient",void 0);gi([yi({type:mn,optional:true})],gn.prototype,"otherPrimeInfos",void 0);class wn{constructor(t={}){this.modulus=new ArrayBuffer(0);this.publicExponent=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer,converter:Fe})],wn.prototype,"modulus",void 0);gi([yi({type:Ne.Integer,converter:Fe})],wn.prototype,"publicExponent",void 0);var En,Pn;const Dn="1.3.6.1.4.1.18227.2.1";let bn=En=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,En.prototype)}};bn=En=gi([fi({type:Me.Sequence,itemType:fs})],bn);let Bn=Pn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Pn.prototype)}};Bn=Pn=gi([fi({type:Me.Sequence,itemType:Ne.BitString})],Bn);class In extends Ke{}let xn=class t{constructor(t={}){this.encryptionAlgorithm=new fs;this.encryptedData=new In;Object.assign(this,t)}};gi([yi({type:fs})],xn.prototype,"encryptionAlgorithm",void 0);gi([yi({type:In})],xn.prototype,"encryptedData",void 0);var Tn;var On;(function(t){t[t["v1"]=0]="v1"})(On||(On={}));class Rn extends Ke{}let Mn=Tn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Tn.prototype)}};Mn=Tn=gi([fi({type:Me.Sequence,itemType:Yr})],Mn);let Nn=class t{constructor(t={}){this.version=On.v1;this.privateKeyAlgorithm=new fs;this.privateKey=new Rn;Object.assign(this,t)}};gi([yi({type:Ne.Integer})],Nn.prototype,"version",void 0);gi([yi({type:fs})],Nn.prototype,"privateKeyAlgorithm",void 0);gi([yi({type:Rn})],Nn.prototype,"privateKey",void 0);gi([yi({type:Mn,implicit:true,context:0,optional:true})],Nn.prototype,"attributes",void 0);var kn;var Kn;(function(t){t[t["v1"]=0]="v1";t[t["v2"]=1]="v2"})(Kn||(Kn={}));let Hn=class t extends fs{};Hn=gi([fi({type:Me.Sequence})],Hn);let jn=class t{constructor(){this.version=Kn.v1;this.privateKeyAlgorithm=new fs;this.privateKey=new ArrayBuffer(0)}};gi([yi({type:Ne.Integer})],jn.prototype,"version",void 0);gi([yi({type:fs})],jn.prototype,"privateKeyAlgorithm",void 0);gi([yi({type:Ne.OctetString})],jn.prototype,"privateKey",void 0);gi([yi({type:Mn,context:0,implicit:true,optional:true})],jn.prototype,"attributes",void 0);gi([yi({type:Ne.BitString,context:1,implicit:true,optional:true})],jn.prototype,"publicKey",void 0);jn=gi([fi({type:Me.Sequence})],jn);let Un=class t extends jn{};Un=gi([fi({type:Me.Sequence})],Un);let Fn=kn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,kn.prototype)}};Fn=kn=gi([fi({type:Me.Sequence,itemType:jn})],Fn);var _n,Vn;const Ln="2.16.840.1.114027.80.4.1";let $n=class t extends fs{};$n=gi([fi({type:Me.Sequence})],$n);let Gn=_n=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,_n.prototype)}};Gn=_n=gi([fi({type:Me.Sequence,itemType:ys})],Gn);let Wn=Vn=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Vn.prototype)}};Wn=Vn=gi([fi({type:Me.Sequence,itemType:jn})],Wn);var Qn={exports:{}};var qn=Qn.exports;var zn;function Jn(){if(zn)return Qn.exports;zn=1;(function(t,e){!function(e,i){t.exports=i()}(qn,(function(){var t=1e3,e=6e4,i=36e5,r="millisecond",s="second",n="minute",o="hour",a="day",c="week",u="month",l="quarter",p="year",h="date",d="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,S={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],i=t%100;return"["+t+(e[(i-20)%10]||e[i]||e[0])+"]"}},A=function(t,e,i){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(i)+t},C={s:A,z:function(t){var e=-t.utcOffset(),i=Math.abs(e),r=Math.floor(i/60),s=i%60;return(e<=0?"+":"-")+A(r,2,"0")+":"+A(s,2,"0")},m:function t(e,i){if(e.date()<i.date())return-t(i,e);var r=12*(i.year()-e.year())+(i.month()-e.month()),s=e.clone().add(r,u),n=i-s<0,o=e.clone().add(r+(n?-1:1),u);return+(-(r+(i-s)/(n?s-o:o-s))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:u,y:p,w:c,d:a,D:h,h:o,m:n,s,ms:r,Q:l}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},v="en",m={};m[v]=S;var g="$isDayjsObject",w=function(t){return t instanceof b||!(!t||!t[g])},E=function t(e,i,r){var s;if(!e)return v;if("string"==typeof e){var n=e.toLowerCase();m[n]&&(s=n),i&&(m[n]=i,s=n);var o=e.split("-");if(!s&&o.length>1)return t(o[0])}else{var a=e.name;m[a]=e,s=a}return!r&&s&&(v=s),s||!r&&v},P=function(t,e){if(w(t))return t.clone();var i="object"==typeof e?e:{};return i.date=t,i.args=arguments,new b(i)},D=C;D.l=E,D.i=w,D.w=function(t,e){return P(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var b=function(){function S(t){this.$L=E(t.locale,null,true),this.parse(t),this.$x=this.$x||t.x||{},this[g]=true}var A=S.prototype;return A.parse=function(t){this.$d=function(t){var e=t.date,i=t.utc;if(null===e)return new Date(NaN);if(D.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(f);if(r){var s=r[2]-1||0,n=(r[7]||"0").substring(0,3);return i?new Date(Date.UTC(r[1],s,r[3]||1,r[4]||0,r[5]||0,r[6]||0,n)):new Date(r[1],s,r[3]||1,r[4]||0,r[5]||0,r[6]||0,n)}}return new Date(e)}(t),this.init()},A.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},A.$utils=function(){return D},A.isValid=function(){return!(this.$d.toString()===d)},A.isSame=function(t,e){var i=P(t);return this.startOf(e)<=i&&i<=this.endOf(e)},A.isAfter=function(t,e){return P(t)<this.startOf(e)},A.isBefore=function(t,e){return this.endOf(e)<P(t)},A.$g=function(t,e,i){return D.u(t)?this[e]:this.set(i,t)},A.unix=function(){return Math.floor(this.valueOf()/1e3)},A.valueOf=function(){return this.$d.getTime()},A.startOf=function(t,e){var i=this,r=!!D.u(e)||e,l=D.p(t),d=function(t,e){var s=D.w(i.$u?Date.UTC(i.$y,e,t):new Date(i.$y,e,t),i);return r?s:s.endOf(a)},f=function(t,e){return D.w(i.toDate()[t].apply(i.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),i)},y=this.$W,S=this.$M,A=this.$D,C="set"+(this.$u?"UTC":"");switch(l){case p:return r?d(1,0):d(31,11);case u:return r?d(1,S):d(0,S+1);case c:var v=this.$locale().weekStart||0,m=(y<v?y+7:y)-v;return d(r?A-m:A+(6-m),S);case a:case h:return f(C+"Hours",0);case o:return f(C+"Minutes",1);case n:return f(C+"Seconds",2);case s:return f(C+"Milliseconds",3);default:return this.clone()}},A.endOf=function(t){return this.startOf(t,false)},A.$set=function(t,e){var i,c=D.p(t),l="set"+(this.$u?"UTC":""),d=(i={},i[a]=l+"Date",i[h]=l+"Date",i[u]=l+"Month",i[p]=l+"FullYear",i[o]=l+"Hours",i[n]=l+"Minutes",i[s]=l+"Seconds",i[r]=l+"Milliseconds",i)[c],f=c===a?this.$D+(e-this.$W):e;if(c===u||c===p){var y=this.clone().set(h,1);y.$d[d](f),y.init(),this.$d=y.set(h,Math.min(this.$D,y.daysInMonth())).$d}else d&&this.$d[d](f);return this.init(),this},A.set=function(t,e){return this.clone().$set(t,e)},A.get=function(t){return this[D.p(t)]()},A.add=function(r,l){var h,d=this;r=Number(r);var f=D.p(l),y=function(t){var e=P(d);return D.w(e.date(e.date()+Math.round(t*r)),d)};if(f===u)return this.set(u,this.$M+r);if(f===p)return this.set(p,this.$y+r);if(f===a)return y(1);if(f===c)return y(7);var S=(h={},h[n]=e,h[o]=i,h[s]=t,h)[f]||1,A=this.$d.getTime()+r*S;return D.w(A,this)},A.subtract=function(t,e){return this.add(-1*t,e)},A.format=function(t){var e=this,i=this.$locale();if(!this.isValid())return i.invalidDate||d;var r=t||"YYYY-MM-DDTHH:mm:ssZ",s=D.z(this),n=this.$H,o=this.$m,a=this.$M,c=i.weekdays,u=i.months,l=i.meridiem,p=function(t,i,s,n){return t&&(t[i]||t(e,r))||s[i].slice(0,n)},h=function(t){return D.s(n%12||12,t,"0")},f=l||function(t,e,i){var r=t<12?"AM":"PM";return i?r.toLowerCase():r};return r.replace(y,(function(t,r){return r||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return D.s(e.$y,4,"0");case"M":return a+1;case"MM":return D.s(a+1,2,"0");case"MMM":return p(i.monthsShort,a,u,3);case"MMMM":return p(u,a);case"D":return e.$D;case"DD":return D.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return p(i.weekdaysMin,e.$W,c,2);case"ddd":return p(i.weekdaysShort,e.$W,c,3);case"dddd":return c[e.$W];case"H":return String(n);case"HH":return D.s(n,2,"0");case"h":return h(1);case"hh":return h(2);case"a":return f(n,o,true);case"A":return f(n,o,false);case"m":return String(o);case"mm":return D.s(o,2,"0");case"s":return String(e.$s);case"ss":return D.s(e.$s,2,"0");case"SSS":return D.s(e.$ms,3,"0");case"Z":return s}return null}(t)||s.replace(":","")}))},A.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},A.diff=function(r,h,d){var f,y=this,S=D.p(h),A=P(r),C=(A.utcOffset()-this.utcOffset())*e,v=this-A,m=function(){return D.m(y,A)};switch(S){case p:f=m()/12;break;case u:f=m();break;case l:f=m()/3;break;case c:f=(v-C)/6048e5;break;case a:f=(v-C)/864e5;break;case o:f=v/i;break;case n:f=v/e;break;case s:f=v/t;break;default:f=v}return d?f:D.a(f)},A.daysInMonth=function(){return this.endOf(u).$D},A.$locale=function(){return m[this.$L]},A.locale=function(t,e){if(!t)return this.$L;var i=this.clone(),r=E(t,e,true);return r&&(i.$L=r),i},A.clone=function(){return D.w(this.$d,this)},A.toDate=function(){return new Date(this.valueOf())},A.toJSON=function(){return this.isValid()?this.toISOString():null},A.toISOString=function(){return this.$d.toISOString()},A.toString=function(){return this.$d.toUTCString()},S}(),B=b.prototype;return P.prototype=B,[["$ms",r],["$s",s],["$m",n],["$H",o],["$W",a],["$M",u],["$y",p],["$D",h]].forEach((function(t){B[t[1]]=function(e){return this.$g(e,t[0],t[1])}})),P.extend=function(t,e){return t.$i||(t(e,b,P),t.$i=true),P},P.locale=E,P.isDayjs=w,P.unix=function(t){return P(1e3*t)},P.en=m[v],P.Ls=m,P.p={},P}))})(Qn);return Qn.exports}var Zn=Jn();var Xn=e(Zn);var Yn={exports:{}};var to=Yn.exports;var eo;function io(){if(eo)return Yn.exports;eo=1;(function(t,e){!function(e,i){t.exports=i()}(to,(function(){return function(t,e,i){t=t||{};var r=e.prototype,s={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function n(t,e,i,s){return r.fromToBase(t,e,i,s)}i.en.relativeTime=s,r.fromToBase=function(e,r,n,o,a){for(var c,u,l,p=n.$locale().relativeTime||s,h=t.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],d=h.length,f=0;f<d;f+=1){var y=h[f];y.d&&(c=o?i(e).diff(n,y.d,true):n.diff(e,y.d,true));var S=(t.rounding||Math.round)(Math.abs(c));if(l=c>0,S<=y.r||!y.r){S<=1&&f>0&&(y=h[f-1]);var A=p[y.l];a&&(S=a(""+S)),u="string"==typeof A?A.replace("%d",S):A(S,r,y.l,l);break}}if(r)return u;var C=l?p.future:p.past;return"function"==typeof C?C(u):C.replace("%s",u)},r.to=function(t,e){return n(t,e,this,true)},r.from=function(t,e){return n(t,e,this)};var o=function(t){return t.$u?i.utc():i()};r.toNow=function(t){return this.to(o(this),t)},r.fromNow=function(t){return this.from(o(this),t)}}}))})(Yn);return Yn.exports}var ro=io();var so=e(ro);
|
|
79
79
|
/**
|
|
80
80
|
* @license
|
|
81
81
|
* Copyright (c) Peculiar Ventures, LLC.
|
|
82
82
|
*
|
|
83
83
|
* This source code is licensed under the MIT license found in the
|
|
84
84
|
* LICENSE file in the root directory of this source tree.
|
|
85
|
-
*/Xn.extend(so);const no=t=>new Date(t).toUTCString();const oo=(t,e)=>{if(!t||!e){return""}const i=Xn(t);const r=Xn(e);return i.to(r,true)};const ao="Basic Information";const co="Subject Name";const uo="Issuer Name";const lo="Public Key Info";const po="Signature";const ho="Extensions";const fo="Miscellaneous";const yo="Download";const So="Serial Number";const Ao="Version";const Co="Validity";const vo="Issued";const mo="Expired";const go="Last Update";const wo="Next Update";const Eo="Algorithm";const Po="Named Curve";const Do="Exponent";const bo="Modulus";const Bo="Value";const Io="Valid";const xo="Revoked";const To="Issuer";const Oo="Name";const Ro="Public Key";const Mo="Fingerprint";const No="Fingerprints";const ko="Test URLs";const Ko="Certificate Details";const Ho="Holder";const jo="Digest Info";const Uo="Type";const
|
|
85
|
+
*/Xn.extend(so);const no=t=>new Date(t).toUTCString();const oo=(t,e)=>{if(!t||!e){return""}const i=Xn(t);const r=Xn(e);return i.to(r,true)};const ao="Basic Information";const co="Subject Name";const uo="Issuer Name";const lo="Public Key Info";const po="Signature";const ho="Extensions";const fo="Miscellaneous";const yo="Download";const So="Serial Number";const Ao="Version";const Co="Validity";const vo="Issued";const mo="Expired";const go="Last Update";const wo="Next Update";const Eo="Algorithm";const Po="Named Curve";const Do="Exponent";const bo="Modulus";const Bo="Value";const Io="Valid";const xo="Revoked";const To="Issuer";const Oo="Name";const Ro="Public Key";const Mo="Fingerprint";const No="Fingerprints";const ko="Test URLs";const Ko="Certificate Details";const Ho="Holder";const jo="Digest Info";const Uo="Type";const Fo="Revoked Certificates";const _o="Revocation Date";const Vo="Yes";const Lo="No";const $o="Only User Certificates";const Go="Only Attribute Certificates";const Wo="Only CA Certificates";const Qo="Indirect CRL";const qo="Only Reasons";const zo="CRL Entry Extensions";const Jo="Preview certificate";const Zo="View details";const Xo="Download options";var Yo={basicInformation:ao,subjectName:co,issuerName:uo,publicKeyInfo:lo,signature:po,extensions:ho,miscellaneous:fo,download:yo,"download.pem":"Download PEM","download.der":"Download DER",serialNumber:So,version:Ao,validity:Co,issued:vo,expired:mo,lastUpdate:go,nextUpdate:wo,algorithm:Eo,namedCurve:Po,exponent:Do,modulus:bo,value:Bo,valid:Io,revoked:xo,issuer:To,name:Oo,publicKey:Ro,fingerprint:Mo,fingerprints:No,testURLs:ko,certificateDetails:Ko,holder:Ho,digestInfo:jo,type:Uo,revokedCertificates:Fo,revocationDate:_o,yes:Vo,no:Lo,onlyUserCertificates:$o,onlyAttributeCertificates:Go,onlyCACertificates:Wo,indirectCRL:Qo,onlyReasons:qo,crlEntryExtensions:zo,previewCertificate:Jo,viewDetails:Zo,downloadOptions:Xo};
|
|
86
86
|
/**
|
|
87
87
|
* @license
|
|
88
88
|
* Copyright (c) Peculiar Ventures, LLC.
|
|
@@ -103,7 +103,7 @@ function t(t,e,i,r="application/octet-stream"){const s=new Blob([t],{type:r});if
|
|
|
103
103
|
*
|
|
104
104
|
* This source code is licensed under the MIT license found in the
|
|
105
105
|
* LICENSE file in the root directory of this source tree.
|
|
106
|
-
*/var na=undefined&&undefined.__classPrivateFieldSet||function(t,e,i,r,s){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!s)throw new TypeError("Private accessor was defined without a setter");if(typeof e==="function"?t!==e||!s:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?s.call(t,i):s?s.value=i:e.set(t,i),i};var oa=undefined&&undefined.__classPrivateFieldGet||function(t,e,i,r){if(i==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof e==="function"?t!==e||!r:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return i==="m"?r:i==="a"?r.call(t):r?r.value:e.get(t)};var aa;class ca{constructor(t){aa.set(this,new Oi);if(n.BufferSourceConverter.isBufferSource(t)){na(this,aa,Ai.parse(t,Oi),"f")}else{na(this,aa,t,"f")}}toJSON(){const t=[];oa(this,aa,"f").forEach((e=>e.forEach((e=>{t.push({type:e.type,name:sa[e.type],shortName:ra[e.type],value:e.value.toString()})}))));return t}}aa=new WeakMap;var ua;const la=`${Hi}.2`;var pa;(function(t){t[t["picture"]=0]="picture";t[t["handwrittenSignature"]=1]="handwrittenSignature"})(pa||(pa={}));let ha=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.Integer})],ha.prototype,"predefinedBiometricType",void 0);gi([yi({type:Ne.ObjectIdentifier})],ha.prototype,"biometricDataOid",void 0);ha=gi([fi({type:Me.Choice})],ha);class da{constructor(t={}){this.typeOfBiometricData=new ha;this.hashAlgorithm=new fs;this.biometricDataHash=new Ke;Object.assign(this,t)}}gi([yi({type:ha})],da.prototype,"typeOfBiometricData",void 0);gi([yi({type:fs})],da.prototype,"hashAlgorithm",void 0);gi([yi({type:Ke})],da.prototype,"biometricDataHash",void 0);gi([yi({type:Ne.IA5String,optional:true})],da.prototype,"sourceDataUri",void 0);let fa=ua=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ua.prototype)}};fa=ua=gi([fi({type:Me.Sequence,itemType:da})],fa);const ya=`${Ki}.11`;var Sa,Aa;const Ca=`${Hi}.3`;class va{constructor(){this.statementId="";this.statementInfo=new ArrayBuffer(0)}}gi([yi({type:Ne.ObjectIdentifier})],va.prototype,"statementId",void 0);gi([yi({type:Ne.Any,optional:true})],va.prototype,"statementInfo",void 0);const ma=`${ya}.2`;let ga=Sa=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Sa.prototype)}};ga=Sa=gi([fi({type:Me.Sequence,itemType:ki})],ga);class wa{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier,optional:true})],wa.prototype,"semanticsIdentifier",void 0);gi([yi({type:ga,optional:true})],wa.prototype,"nameRegistrationAuthorities",void 0);let Ea=Aa=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Aa.prototype)}};Ea=Aa=gi([fi({type:Me.Sequence,itemType:va})],Ea);let Pa=class t extends bi{};Pa=gi([fi({type:Me.Choice})],Pa);var Da;(function(t){t["M"]="M";t["F"]="F";t["m"]="m";t["f"]="f"})(Da||(Da={}));var ba;let Ba=ba=class t extends ar{constructor(t){super(t);Object.setPrototypeOf(this,ba.prototype)}};Ba=ba=gi([fi({type:Me.Sequence})],Ba);const Ia="1.3.6.1.4.1.311.21.7";class xa{constructor(t={}){this.templateID="";this.templateMajorVersion=0;this.templateMinorVersion=0;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],xa.prototype,"templateID",void 0);gi([yi({type:Ne.Integer})],xa.prototype,"templateMajorVersion",void 0);gi([yi({type:Ne.Integer})],xa.prototype,"templateMinorVersion",void 0);const Ta="1.3.6.1.4.1.311.20.2";class Oa{constructor(t={}){this.name="";Object.assign(this,t)}}gi([yi({type:Ne.Utf8String})],Oa.prototype,"name",void 0);let Ra=class t{constructor(t={}){Object.assign(this,t)}toString(){var t,e;return((t=this.name)===null||t===void 0?void 0:t.toString())||((e=this.spec)===null||e===void 0?void 0:e.name)||""}};gi([yi({type:bi})],Ra.prototype,"name",void 0);gi([yi({type:Oa})],Ra.prototype,"spec",void 0);Ra=gi([fi({type:Me.Choice})],Ra);const Ma="1.3.6.1.4.1.311.21.1";let Na=class t{constructor(){this.value=new ArrayBuffer(0)}toString(){const t=this.getVersion();return`V${t.certificateIndex}.${t.keyIndex}`}getVersion(){let t=new Uint8Array(this.value);if(this.value.byteLength<4){t=new Uint8Array(4);t.set(new Uint8Array(this.value),4-this.value.byteLength)}return{keyIndex:parseInt(n.Convert.ToHex(t.slice(0,2)),16),certificateIndex:parseInt(n.Convert.ToHex(t.slice(2)),16)}}};gi([yi({type:Ne.Integer,converter:_e})],Na.prototype,"value",void 0);Na=gi([fi({type:Me.Choice})],Na);let ka=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.NumericString})],ka.prototype,"numericString",void 0);gi([yi({type:Ne.PrintableString})],ka.prototype,"printableString",void 0);gi([yi({type:Ne.TeletexString})],ka.prototype,"teletexString",void 0);gi([yi({type:Ne.VideotexString})],ka.prototype,"videotexString",void 0);gi([yi({type:Ne.IA5String})],ka.prototype,"ia5String",void 0);gi([yi({type:Ne.GraphicString})],ka.prototype,"graphicString",void 0);gi([yi({type:Ne.VisibleString})],ka.prototype,"visibleString",void 0);gi([yi({type:Ne.GeneralString})],ka.prototype,"generalString",void 0);gi([yi({type:Ne.UniversalString})],ka.prototype,"universalString",void 0);gi([yi({type:Ne.BmpString})],ka.prototype,"bmpString",void 0);ka=gi([fi({type:Me.Choice})],ka);let Ka=class t{constructor(t=new ArrayBuffer(0)){this.value=t}};gi([yi({type:Ne.Any})],Ka.prototype,"value",void 0);Ka=gi([fi({type:Me.Choice})],Ka);var Ha;let ja=Ha=class t extends ms{constructor(t){super(t);Object.setPrototypeOf(this,Ha.prototype)}};ja=Ha=gi([fi({type:Me.Sequence})],ja);class Ua{constructor(t={}){this.keySpec=0;this.cspName="";this.signature=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Ua.prototype,"keySpec",void 0);gi([yi({type:Ne.BmpString})],Ua.prototype,"cspName",void 0);gi([yi({type:Ne.BitString})],Ua.prototype,"signature",void 0);var _a;let Fa=_a=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,_a.prototype)}};Fa=_a=gi([fi({type:Me.Sequence,itemType:Ne.Any})],Fa);var Va;let La=Va=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Va.prototype)}};La=Va=gi([fi({type:Me.Sequence,itemType:Ne.Any})],La);var $a;class Ga{constructor(t={}){this.name="";this.value="";Object.assign(this,t)}}gi([yi({type:Ne.BmpString})],Ga.prototype,"name",void 0);gi([yi({type:Ne.BmpString})],Ga.prototype,"value",void 0);let Wa=$a=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,$a.prototype)}};Wa=$a=gi([fi({type:Me.Sequence,itemType:Ga})],Wa);let Qa=class t extends Mi{};Qa=gi([fi({type:Me.Sequence})],Qa);let qa=class t extends Mi{};qa=gi([fi({type:Me.Sequence})],qa);let za=class t extends Es{};za=gi([fi({type:Me.Sequence})],za);class Ja{constructor(t={}){this.clientId=0;this.machineName="";this.userName="";this.processName="";Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Ja.prototype,"clientId",void 0);gi([yi({type:Ne.Utf8String})],Ja.prototype,"machineName",void 0);gi([yi({type:Ne.Utf8String})],Ja.prototype,"userName",void 0);gi([yi({type:Ne.Utf8String})],Ja.prototype,"processName",void 0);const Za="2.16.840.1.113730";const Xa=`${Za}.1`;let Ya=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],Ya.prototype,"value",void 0);Ya=gi([fi({type:Me.Choice})],Ya);let tc=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],tc.prototype,"value",void 0);tc=gi([fi({type:Me.Choice})],tc);let ec=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],ec.prototype,"value",void 0);ec=gi([fi({type:Me.Choice})],ec);let ic=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],ic.prototype,"value",void 0);ic=gi([fi({type:Me.Choice})],ic);const rc=`${Xa}.1`;var sc;(function(t){t[t["sslClient"]=1]="sslClient";t[t["sslServer"]=2]="sslServer";t[t["sMime"]=4]="sMime";t[t["objectSigning"]=8]="objectSigning";t[t["sslCa"]=32]="sslCa";t[t["sMimeCa"]=64]="sMimeCa";t[t["objectSigningCa"]=128]="objectSigningCa"})(sc||(sc={}));class nc extends ke{toJSON(){const t=this.toNumber();const e=[];if(t&sc.objectSigning){e.push("objectSigning")}if(t&sc.objectSigningCa){e.push("objectSigningCa")}if(t&sc.sMime){e.push("sMime")}if(t&sc.sMimeCa){e.push("sMimeCa")}if(t&sc.sslCa){e.push("sslCa")}if(t&sc.sslClient){e.push("sslClient")}if(t&sc.sslServer){e.push("sslServer")}return e}toString(){return`[${this.toJSON().join(", ")}]`}}const oc=`${Xa}.13`;let ac=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],ac.prototype,"value",void 0);ac=gi([fi({type:Me.Choice})],ac);let cc=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],cc.prototype,"value",void 0);cc=gi([fi({type:Me.Choice})],cc);let uc=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],uc.prototype,"value",void 0);uc=gi([fi({type:Me.Choice})],uc);const lc="1.3.6.1.4.1.52266.1";let pc=class t{constructor(t={}){this.leiCode="";Object.assign(this,t)}};gi([yi({type:Zt})],pc.prototype,"leiCode",void 0);gi([yi({type:Zt,context:0,optional:true})],pc.prototype,"leiRole",void 0);pc=gi([fi({type:Me.Sequence})],pc);let hc=class t{get text(){if(this.bmpString!==undefined){return this.bmpString}if(this.ia5String!==undefined){return this.ia5String}if(this.printableString!==undefined){return this.printableString}if(this.utf8String!==undefined){return this.utf8String}if(this.visibleString!==undefined){return this.visibleString}return undefined}set text(t){this.printableString=t}constructor(t){if(t){this.text=t}}};gi([yi({type:Ne.IA5String})],hc.prototype,"ia5String",void 0);gi([yi({type:Ne.VisibleString})],hc.prototype,"visibleString",void 0);gi([yi({type:Ne.BmpString})],hc.prototype,"bmpString",void 0);gi([yi({type:Ne.Utf8String})],hc.prototype,"utf8String",void 0);gi([yi({type:Ne.PrintableString})],hc.prototype,"printableString",void 0);hc=gi([fi({type:Me.Choice})],hc);let dc=class t extends hc{constructor(t){super();if(typeof t==="string"){this.text=t}else if(t instanceof pc){this.struct=t}}};gi([yi({type:pc})],dc.prototype,"struct",void 0);dc=gi([fi({type:Me.Choice})],dc);const fc="1.3.6.1.4.1.52266.2";let yc=class t extends hc{};yc=gi([fi({type:Me.Choice})],yc);class Sc{get position(){return this.offset}constructor(t){this.offset=0;this.view=n.BufferSourceConverter.toUint8Array(t)}read(t=1){const e=this.view.slice(this.offset,this.offset+t);this.offset=this.offset+e.length;return e}readByte(){const t=this.read();if(!t.length){throw new Error("End of stream")}return t[0]}readNumber(t){const e=this.read(t);const i=n.Convert.ToHex(e);return parseInt(i,16)}readEnd(){return this.read(this.view.length-this.offset)}reset(){this.offset=0}}class Ac{static createStream(t){const e=n.BufferSourceConverter.toUint8Array(t);return new Sc(e)}}var Cc;(function(t){t[t["certificateTimestamp"]=0]="certificateTimestamp";t[t["treeHash"]=1]="treeHash"})(Cc||(Cc={}));var vc;(function(t){t[t["none"]=0]="none";t[t["md5"]=1]="md5";t[t["sha1"]=2]="sha1";t[t["sha224"]=3]="sha224";t[t["sha256"]=4]="sha256";t[t["sha384"]=5]="sha384";t[t["sha512"]=6]="sha512"})(vc||(vc={}));var mc;(function(t){t[t["anonymous"]=0]="anonymous";t[t["rsa"]=1]="rsa";t[t["dsa"]=2]="dsa";t[t["ecdsa"]=3]="ecdsa"})(mc||(mc={}));class gc extends Ac{constructor(t){super();this.version=0;this.logId=new ArrayBuffer(32);this.timestamp=new Date;this.extensions=new ArrayBuffer(0);this.hashAlgorithm=0;this.signatureAlgorithm=0;this.signature=new ArrayBuffer(0);if(t){this.parse(t)}}parse(t){this.version=t.readByte();t.read(2);this.logId=n.BufferSourceConverter.toArrayBuffer(t.read(32));this.timestamp=new Date(t.readNumber(8));const e=t.readNumber(2);this.extensions=t.read(e).buffer;this.hashAlgorithm=t.readByte();this.signatureAlgorithm=t.readByte();this.signature=t.read(t.readNumber(2)).buffer}toJSON(){return{version:this.version,logId:n.Convert.ToHex(this.logId),timestamp:this.timestamp,extensions:n.Convert.ToBase64(this.extensions),hashAlgorithm:vc[this.hashAlgorithm]||"undefined",signatureAlgorithm:mc[this.signatureAlgorithm]||"undefined",signature:n.Convert.ToBase64(this.signature)}}}const wc="1.3.6.1.4.1.11129.2.4.2";class Ec extends Ke{constructor(){super(...arguments);this.items=[]}fromASN(t){super.fromASN(t);const e=new Sc(this.buffer);const i=e.readNumber(2);this.items=[];while(e.position<i){this.items.push(new gc(e))}return this}toJSON(){return this.items.map((t=>t.toJSON()))}}var Pc;(function(t){t[t["v1"]=1]="v1"})(Pc||(Pc={}));const Dc="1.2.840.113583.1.1.9.2";class bc{constructor(t={}){this.version=Pc.v1;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],bc.prototype,"version",void 0);const Bc="1.2.840.113583.1.1.9.1";class Ic{constructor(t={}){this.version=Pc.v1;this.location=new ki;this.requiresAuth=false;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Ic.prototype,"version",void 0);gi([yi({type:ki})],Ic.prototype,"location",void 0);gi([yi({type:Ne.Boolean,defaultValue:false,optional:true})],Ic.prototype,"requiresAuth",void 0);class xc{constructor(t={}){this.hashAlg=new fs;this.hashValue=new Ke;Object.assign(this,t)}}gi([yi({type:fs})],xc.prototype,"hashAlg",void 0);gi([yi({type:Ke})],xc.prototype,"hashValue",void 0);class Tc{constructor(t={}){this.mediaType="";this.logotypeHash=[];this.logotypeURI=[];Object.assign(this,t)}}gi([yi({type:Ne.IA5String})],Tc.prototype,"mediaType",void 0);gi([yi({type:xc,repeated:"sequence"})],Tc.prototype,"logotypeHash",void 0);gi([yi({type:Ne.IA5String,repeated:"sequence"})],Tc.prototype,"logotypeURI",void 0);var Oc;(function(t){t[t["mono"]=1]="mono";t[t["stereo"]=2]="stereo";t[t["quad"]=4]="quad"})(Oc||(Oc={}));class Rc{constructor(t={}){this.fileSize=0;this.playTime=0;this.channels=Oc.mono;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Rc.prototype,"fileSize",void 0);gi([yi({type:Ne.Integer})],Rc.prototype,"playTime",void 0);gi([yi({type:Ne.Integer})],Rc.prototype,"channels",void 0);gi([yi({type:Ne.Integer,implicit:true,context:3,optional:true})],Rc.prototype,"sampleRate",void 0);gi([yi({type:Ne.IA5String,implicit:true,context:4,optional:true})],Rc.prototype,"language",void 0);class Mc{constructor(t={}){this.audioDetails=new Tc;Object.assign(this,t)}}gi([yi({type:Tc})],Mc.prototype,"audioDetails",void 0);gi([yi({type:Rc,optional:true})],Mc.prototype,"audioInfo",void 0);let Nc=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.Integer,context:1,implicit:true})],Nc.prototype,"numBits",void 0);gi([yi({type:Ne.Integer,context:2,implicit:true})],Nc.prototype,"tableSize",void 0);Nc=gi([fi({type:Me.Choice})],Nc);var kc;(function(t){t[t["grayScale"]=0]="grayScale";t[t["color"]=1]="color"})(kc||(kc={}));class Kc{constructor(t={}){this.type=kc.color;this.fileSize=0;this.xSize=0;this.ySize=0;Object.assign(this,t)}}gi([yi({type:Ne.Integer,context:0,implicit:true,defaultValue:kc.color})],Kc.prototype,"type",void 0);gi([yi({type:Ne.Integer})],Kc.prototype,"fileSize",void 0);gi([yi({type:Ne.Integer})],Kc.prototype,"xSize",void 0);gi([yi({type:Ne.Integer})],Kc.prototype,"ySize",void 0);gi([yi({type:Nc})],Kc.prototype,"resolution",void 0);gi([yi({type:Ne.IA5String,context:4,implicit:true,optional:true})],Kc.prototype,"language",void 0);class Hc{constructor(t={}){this.imageDetails=new Tc;Object.assign(this,t)}}gi([yi({type:Tc})],Hc.prototype,"imageDetails",void 0);gi([yi({type:Kc,optional:true})],Hc.prototype,"imageInfo",void 0);class jc{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Hc,repeated:"sequence",optional:true})],jc.prototype,"image",void 0);gi([yi({type:Mc,repeated:"sequence",context:1,optional:true})],jc.prototype,"audio",void 0);class Uc{constructor(t={}){this.refStructHash=[];this.refStructURI=[];Object.assign(this,t)}}gi([yi({type:xc,repeated:"sequence"})],Uc.prototype,"refStructHash",void 0);gi([yi({type:Ne.IA5String,repeated:"sequence"})],Uc.prototype,"refStructURI",void 0);let _c=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:jc,implicit:true,context:0})],_c.prototype,"direct",void 0);gi([yi({type:Uc,implicit:true,context:1})],_c.prototype,"indirect",void 0);_c=gi([fi({type:Me.Choice})],_c);class Fc{constructor(t={}){this.logotypeType="";this.info=new _c;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Fc.prototype,"logotypeType",void 0);gi([yi({type:_c})],Fc.prototype,"info",void 0);class Vc{constructor(t={}){Object.assign(this,t)}}gi([yi({type:_c,context:0,repeated:"sequence",optional:true})],Vc.prototype,"communityLogos",void 0);gi([yi({type:_c,context:1,optional:true})],Vc.prototype,"issuerLogo",void 0);gi([yi({type:_c,context:2,optional:true})],Vc.prototype,"subjectLogo",void 0);gi([yi({type:Fc,context:3,repeated:"sequence",optional:true})],Vc.prototype,"otherLogos",void 0);const Lc="1.3.6.1.5.5.7.1.12";var $c,Gc,Wc;const Qc="1.3.6.1.5.5.7";const qc=`${Qc}.1`;let zc=$c=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,$c.prototype)}};zc=$c=gi([fi({type:Me.Sequence,itemType:Ne.IA5String})],zc);class Jc{constructor(t={}){this.claim="";this.permitted=[];Object.assign(this,t)}}gi([yi({type:Ne.IA5String})],Jc.prototype,"claim",void 0);gi([yi({type:Ne.Utf8String,repeated:"sequence"})],Jc.prototype,"permitted",void 0);let Zc=Gc=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Gc.prototype)}};Zc=Gc=gi([fi({type:Me.Sequence,itemType:Jc})],Zc);class Xc{constructor(t={}){Object.assign(this,t)}}gi([yi({type:zc,optional:true,context:0})],Xc.prototype,"mustInclude",void 0);gi([yi({type:Zc,optional:true,context:1})],Xc.prototype,"permittedValues",void 0);const Yc=`${qc}.26`;class tu{constructor(){this.start="";this.count=2}}gi([yi({type:Ne.IA5String})],tu.prototype,"start",void 0);gi([yi({type:Ne.Integer})],tu.prototype,"count",void 0);let eu=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.IA5String,context:0})],eu.prototype,"spc",void 0);gi([yi({type:tu,context:1})],eu.prototype,"range",void 0);gi([yi({type:Ne.IA5String,context:2})],eu.prototype,"one",void 0);eu=gi([fi({type:Me.Choice})],eu);let iu=Wc=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Wc.prototype)}};iu=Wc=gi([fi({type:Me.Sequence,itemType:eu})],iu);var ru;const su="1.3.6.1.4.1.11129.2.1.17";var nu;(function(t){t[t["verified"]=0]="verified";t[t["selfSigned"]=1]="selfSigned";t[t["unverified"]=2]="unverified";t[t["failed"]=3]="failed"})(nu||(nu={}));class ou{constructor(t={}){this.verifiedBootKey=new Ke;this.deviceLocked=false;this.verifiedBootState=nu.verified;Object.assign(this,t)}}gi([yi({type:Ke})],ou.prototype,"verifiedBootKey",void 0);gi([yi({type:Ne.Boolean})],ou.prototype,"deviceLocked",void 0);gi([yi({type:Ne.Enumerated})],ou.prototype,"verifiedBootState",void 0);gi([yi({type:Ke,optional:true})],ou.prototype,"verifiedBootHash",void 0);let au=ru=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ru.prototype)}};au=ru=gi([fi({type:Me.Set,itemType:Ne.Integer})],au);class cu{constructor(t={}){Object.assign(this,t)}}gi([yi({context:1,type:au,optional:true})],cu.prototype,"purpose",void 0);gi([yi({context:2,type:Ne.Integer,optional:true})],cu.prototype,"algorithm",void 0);gi([yi({context:3,type:Ne.Integer,optional:true})],cu.prototype,"keySize",void 0);gi([yi({context:5,type:au,optional:true})],cu.prototype,"digest",void 0);gi([yi({context:6,type:au,optional:true})],cu.prototype,"padding",void 0);gi([yi({context:10,type:Ne.Integer,optional:true})],cu.prototype,"ecCurve",void 0);gi([yi({context:200,type:Ne.Integer,optional:true})],cu.prototype,"rsaPublicExponent",void 0);gi([yi({context:203,type:au,optional:true})],cu.prototype,"mgfDigest",void 0);gi([yi({context:303,type:Ne.Null,optional:true})],cu.prototype,"rollbackResistance",void 0);gi([yi({context:305,type:Ne.Null,optional:true})],cu.prototype,"earlyBootOnly",void 0);gi([yi({context:400,type:Ne.Integer,optional:true})],cu.prototype,"activeDateTime",void 0);gi([yi({context:401,type:Ne.Integer,optional:true})],cu.prototype,"originationExpireDateTime",void 0);gi([yi({context:402,type:Ne.Integer,optional:true})],cu.prototype,"usageExpireDateTime",void 0);gi([yi({context:405,type:Ne.Integer,optional:true})],cu.prototype,"usageCountLimit",void 0);gi([yi({context:503,type:Ne.Null,optional:true})],cu.prototype,"noAuthRequired",void 0);gi([yi({context:504,type:Ne.Integer,optional:true})],cu.prototype,"userAuthType",void 0);gi([yi({context:505,type:Ne.Integer,optional:true})],cu.prototype,"authTimeout",void 0);gi([yi({context:506,type:Ne.Null,optional:true})],cu.prototype,"allowWhileOnBody",void 0);gi([yi({context:507,type:Ne.Null,optional:true})],cu.prototype,"trustedUserPresenceRequired",void 0);gi([yi({context:508,type:Ne.Null,optional:true})],cu.prototype,"trustedConfirmationRequired",void 0);gi([yi({context:509,type:Ne.Null,optional:true})],cu.prototype,"unlockedDeviceRequired",void 0);gi([yi({context:600,type:Ne.Null,optional:true})],cu.prototype,"allApplications",void 0);gi([yi({context:601,type:Ke,optional:true})],cu.prototype,"applicationId",void 0);gi([yi({context:701,type:Ne.Integer,optional:true})],cu.prototype,"creationDateTime",void 0);gi([yi({context:702,type:Ne.Integer,optional:true})],cu.prototype,"origin",void 0);gi([yi({context:703,type:Ne.Null,optional:true})],cu.prototype,"rollbackResistant",void 0);gi([yi({context:704,type:ou,optional:true})],cu.prototype,"rootOfTrust",void 0);gi([yi({context:705,type:Ne.Integer,optional:true})],cu.prototype,"osVersion",void 0);gi([yi({context:706,type:Ne.Integer,optional:true})],cu.prototype,"osPatchLevel",void 0);gi([yi({context:709,type:Ke,optional:true})],cu.prototype,"attestationApplicationId",void 0);gi([yi({context:710,type:Ke,optional:true})],cu.prototype,"attestationIdBrand",void 0);gi([yi({context:711,type:Ke,optional:true})],cu.prototype,"attestationIdDevice",void 0);gi([yi({context:712,type:Ke,optional:true})],cu.prototype,"attestationIdProduct",void 0);gi([yi({context:713,type:Ke,optional:true})],cu.prototype,"attestationIdSerial",void 0);gi([yi({context:714,type:Ke,optional:true})],cu.prototype,"attestationIdImei",void 0);gi([yi({context:715,type:Ke,optional:true})],cu.prototype,"attestationIdMeid",void 0);gi([yi({context:716,type:Ke,optional:true})],cu.prototype,"attestationIdManufacturer",void 0);gi([yi({context:717,type:Ke,optional:true})],cu.prototype,"attestationIdModel",void 0);gi([yi({context:718,type:Ne.Integer,optional:true})],cu.prototype,"vendorPatchLevel",void 0);gi([yi({context:719,type:Ne.Integer,optional:true})],cu.prototype,"bootPatchLevel",void 0);gi([yi({context:720,type:Ne.Null,optional:true})],cu.prototype,"deviceUniqueAttestation",void 0);gi([yi({context:723,type:Ke,optional:true})],cu.prototype,"attestationIdSecondImei",void 0);gi([yi({context:724,type:Ke,optional:true})],cu.prototype,"moduleHash",void 0);var uu;(function(t){t[t["software"]=0]="software";t[t["trustedEnvironment"]=1]="trustedEnvironment";t[t["strongBox"]=2]="strongBox"})(uu||(uu={}));var lu;(function(t){t[t["KM2"]=1]="KM2";t[t["KM3"]=2]="KM3";t[t["KM4"]=3]="KM4";t[t["KM4_1"]=4]="KM4_1";t[t["keyMint1"]=100]="keyMint1";t[t["keyMint2"]=200]="keyMint2";t[t["keyMint3"]=300]="keyMint3";t[t["keyMint4"]=400]="keyMint4"})(lu||(lu={}));class pu{constructor(t={}){this.attestationVersion=lu.KM4;this.attestationSecurityLevel=uu.software;this.keymasterVersion=0;this.keymasterSecurityLevel=uu.software;this.attestationChallenge=new Ke;this.uniqueId=new Ke;this.softwareEnforced=new cu;this.teeEnforced=new cu;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],pu.prototype,"attestationVersion",void 0);gi([yi({type:Ne.Enumerated})],pu.prototype,"attestationSecurityLevel",void 0);gi([yi({type:Ne.Integer})],pu.prototype,"keymasterVersion",void 0);gi([yi({type:Ne.Enumerated})],pu.prototype,"keymasterSecurityLevel",void 0);gi([yi({type:Ke})],pu.prototype,"attestationChallenge",void 0);gi([yi({type:Ke})],pu.prototype,"uniqueId",void 0);gi([yi({type:cu})],pu.prototype,"softwareEnforced",void 0);gi([yi({type:cu})],pu.prototype,"teeEnforced",void 0);class hu{constructor(t={}){this.attestationVersion=lu.keyMint4;this.attestationSecurityLevel=uu.software;this.keyMintVersion=0;this.keyMintSecurityLevel=uu.software;this.attestationChallenge=new Ke;this.uniqueId=new Ke;this.softwareEnforced=new cu;this.hardwareEnforced=new cu;Object.assign(this,t)}toLegacyKeyDescription(){return new pu({attestationVersion:this.attestationVersion,attestationSecurityLevel:this.attestationSecurityLevel,keymasterVersion:this.keyMintVersion,keymasterSecurityLevel:this.keyMintSecurityLevel,attestationChallenge:this.attestationChallenge,uniqueId:this.uniqueId,softwareEnforced:this.softwareEnforced,teeEnforced:this.hardwareEnforced})}static fromLegacyKeyDescription(t){return new hu({attestationVersion:t.attestationVersion,attestationSecurityLevel:t.attestationSecurityLevel,keyMintVersion:t.keymasterVersion,keyMintSecurityLevel:t.keymasterSecurityLevel,attestationChallenge:t.attestationChallenge,uniqueId:t.uniqueId,softwareEnforced:t.softwareEnforced,hardwareEnforced:t.teeEnforced})}}gi([yi({type:Ne.Integer})],hu.prototype,"attestationVersion",void 0);gi([yi({type:Ne.Enumerated})],hu.prototype,"attestationSecurityLevel",void 0);gi([yi({type:Ne.Integer})],hu.prototype,"keyMintVersion",void 0);gi([yi({type:Ne.Enumerated})],hu.prototype,"keyMintSecurityLevel",void 0);gi([yi({type:Ke})],hu.prototype,"attestationChallenge",void 0);gi([yi({type:Ke})],hu.prototype,"uniqueId",void 0);gi([yi({type:cu})],hu.prototype,"softwareEnforced",void 0);gi([yi({type:cu})],hu.prototype,"hardwareEnforced",void 0);var du;let fu=class t extends cu{};fu=gi([fi({type:Me.Choice})],fu);let yu=du=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,du.prototype)}findProperty(t){const e=this.find((e=>t in e));if(e){return e[t]}return undefined}};yu=du=gi([fi({type:Me.Sequence,itemType:fu})],yu);class Su{get keyMintVersion(){return this.keymasterVersion}set keyMintVersion(t){this.keymasterVersion=t}get keyMintSecurityLevel(){return this.keymasterSecurityLevel}set keyMintSecurityLevel(t){this.keymasterSecurityLevel=t}get hardwareEnforced(){return this.teeEnforced}set hardwareEnforced(t){this.teeEnforced=t}constructor(t={}){this.attestationVersion=lu.KM4;this.attestationSecurityLevel=uu.software;this.keymasterVersion=0;this.keymasterSecurityLevel=uu.software;this.attestationChallenge=new Ke;this.uniqueId=new Ke;this.softwareEnforced=new yu;this.teeEnforced=new yu;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Su.prototype,"attestationVersion",void 0);gi([yi({type:Ne.Enumerated})],Su.prototype,"attestationSecurityLevel",void 0);gi([yi({type:Ne.Integer})],Su.prototype,"keymasterVersion",void 0);gi([yi({type:Ne.Enumerated})],Su.prototype,"keymasterSecurityLevel",void 0);gi([yi({type:Ke})],Su.prototype,"attestationChallenge",void 0);gi([yi({type:Ke})],Su.prototype,"uniqueId",void 0);gi([yi({type:yu})],Su.prototype,"softwareEnforced",void 0);gi([yi({type:yu})],Su.prototype,"teeEnforced",void 0);let Au=class t extends Su{constructor(t={}){if("keymasterVersion"in t&&!("keyMintVersion"in t)){t.keyMintVersion=t.keymasterVersion}if("keymasterSecurityLevel"in t&&!("keyMintSecurityLevel"in t)){t.keyMintSecurityLevel=t.keymasterSecurityLevel}if("teeEnforced"in t&&!("hardwareEnforced"in t)){t.hardwareEnforced=t.teeEnforced}super(t)}};Au=gi([fi({type:Me.Sequence})],Au);class Cu{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ne.OctetString})],Cu.prototype,"packageName",void 0);gi([yi({type:Ne.Integer})],Cu.prototype,"version",void 0);class vu{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Cu,repeated:"set"})],vu.prototype,"packageInfos",void 0);gi([yi({type:Ne.OctetString,repeated:"set"})],vu.prototype,"signatureDigests",void 0);var mu=undefined&&undefined.__decorate||function(t,e,i,r){var s=arguments.length,n=s<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,o;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")n=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)if(o=t[a])n=(s<3?o(n):s>3?o(e,i,n):o(e,i))||n;return s>3&&n&&Object.defineProperty(e,i,n),n};const gu="2.23.140.3.1";class wu{constructor(t={}){Object.assign(this,t)}}mu([yi({type:Ne.PrintableString})],wu.prototype,"registrationSchemeIdentifier",void 0);mu([yi({type:Ne.PrintableString})],wu.prototype,"registrationCountry",void 0);mu([yi({type:Ne.PrintableString,optional:true,context:0,implicit:true})],wu.prototype,"registrationStateOrProvince",void 0);mu([yi({type:Ne.Utf8String})],wu.prototype,"registrationReference",void 0);
|
|
106
|
+
*/var na=undefined&&undefined.__classPrivateFieldSet||function(t,e,i,r,s){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!s)throw new TypeError("Private accessor was defined without a setter");if(typeof e==="function"?t!==e||!s:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?s.call(t,i):s?s.value=i:e.set(t,i),i};var oa=undefined&&undefined.__classPrivateFieldGet||function(t,e,i,r){if(i==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof e==="function"?t!==e||!r:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return i==="m"?r:i==="a"?r.call(t):r?r.value:e.get(t)};var aa;class ca{constructor(t){aa.set(this,new Oi);if(n.BufferSourceConverter.isBufferSource(t)){na(this,aa,Ai.parse(t,Oi),"f")}else{na(this,aa,t,"f")}}toJSON(){const t=[];oa(this,aa,"f").forEach((e=>e.forEach((e=>{t.push({type:e.type,name:sa[e.type],shortName:ra[e.type],value:e.value.toString()})}))));return t}}aa=new WeakMap;var ua;const la=`${Hi}.2`;var pa;(function(t){t[t["picture"]=0]="picture";t[t["handwrittenSignature"]=1]="handwrittenSignature"})(pa||(pa={}));let ha=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.Integer})],ha.prototype,"predefinedBiometricType",void 0);gi([yi({type:Ne.ObjectIdentifier})],ha.prototype,"biometricDataOid",void 0);ha=gi([fi({type:Me.Choice})],ha);class da{constructor(t={}){this.typeOfBiometricData=new ha;this.hashAlgorithm=new fs;this.biometricDataHash=new Ke;Object.assign(this,t)}}gi([yi({type:ha})],da.prototype,"typeOfBiometricData",void 0);gi([yi({type:fs})],da.prototype,"hashAlgorithm",void 0);gi([yi({type:Ke})],da.prototype,"biometricDataHash",void 0);gi([yi({type:Ne.IA5String,optional:true})],da.prototype,"sourceDataUri",void 0);let fa=ua=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ua.prototype)}};fa=ua=gi([fi({type:Me.Sequence,itemType:da})],fa);const ya=`${Ki}.11`;var Sa,Aa;const Ca=`${Hi}.3`;class va{constructor(){this.statementId="";this.statementInfo=new ArrayBuffer(0)}}gi([yi({type:Ne.ObjectIdentifier})],va.prototype,"statementId",void 0);gi([yi({type:Ne.Any,optional:true})],va.prototype,"statementInfo",void 0);const ma=`${ya}.2`;let ga=Sa=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Sa.prototype)}};ga=Sa=gi([fi({type:Me.Sequence,itemType:ki})],ga);class wa{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier,optional:true})],wa.prototype,"semanticsIdentifier",void 0);gi([yi({type:ga,optional:true})],wa.prototype,"nameRegistrationAuthorities",void 0);let Ea=Aa=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Aa.prototype)}};Ea=Aa=gi([fi({type:Me.Sequence,itemType:va})],Ea);let Pa=class t extends bi{};Pa=gi([fi({type:Me.Choice})],Pa);var Da;(function(t){t["M"]="M";t["F"]="F";t["m"]="m";t["f"]="f"})(Da||(Da={}));var ba;let Ba=ba=class t extends ar{constructor(t){super(t);Object.setPrototypeOf(this,ba.prototype)}};Ba=ba=gi([fi({type:Me.Sequence})],Ba);const Ia="1.3.6.1.4.1.311.21.7";class xa{constructor(t={}){this.templateID="";this.templateMajorVersion=0;this.templateMinorVersion=0;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],xa.prototype,"templateID",void 0);gi([yi({type:Ne.Integer})],xa.prototype,"templateMajorVersion",void 0);gi([yi({type:Ne.Integer})],xa.prototype,"templateMinorVersion",void 0);const Ta="1.3.6.1.4.1.311.20.2";class Oa{constructor(t={}){this.name="";Object.assign(this,t)}}gi([yi({type:Ne.Utf8String})],Oa.prototype,"name",void 0);let Ra=class t{constructor(t={}){Object.assign(this,t)}toString(){var t,e;return((t=this.name)===null||t===void 0?void 0:t.toString())||((e=this.spec)===null||e===void 0?void 0:e.name)||""}};gi([yi({type:bi})],Ra.prototype,"name",void 0);gi([yi({type:Oa})],Ra.prototype,"spec",void 0);Ra=gi([fi({type:Me.Choice})],Ra);const Ma="1.3.6.1.4.1.311.21.1";let Na=class t{constructor(){this.value=new ArrayBuffer(0)}toString(){const t=this.getVersion();return`V${t.certificateIndex}.${t.keyIndex}`}getVersion(){let t=new Uint8Array(this.value);if(this.value.byteLength<4){t=new Uint8Array(4);t.set(new Uint8Array(this.value),4-this.value.byteLength)}return{keyIndex:parseInt(n.Convert.ToHex(t.slice(0,2)),16),certificateIndex:parseInt(n.Convert.ToHex(t.slice(2)),16)}}};gi([yi({type:Ne.Integer,converter:Fe})],Na.prototype,"value",void 0);Na=gi([fi({type:Me.Choice})],Na);let ka=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.NumericString})],ka.prototype,"numericString",void 0);gi([yi({type:Ne.PrintableString})],ka.prototype,"printableString",void 0);gi([yi({type:Ne.TeletexString})],ka.prototype,"teletexString",void 0);gi([yi({type:Ne.VideotexString})],ka.prototype,"videotexString",void 0);gi([yi({type:Ne.IA5String})],ka.prototype,"ia5String",void 0);gi([yi({type:Ne.GraphicString})],ka.prototype,"graphicString",void 0);gi([yi({type:Ne.VisibleString})],ka.prototype,"visibleString",void 0);gi([yi({type:Ne.GeneralString})],ka.prototype,"generalString",void 0);gi([yi({type:Ne.UniversalString})],ka.prototype,"universalString",void 0);gi([yi({type:Ne.BmpString})],ka.prototype,"bmpString",void 0);ka=gi([fi({type:Me.Choice})],ka);let Ka=class t{constructor(t=new ArrayBuffer(0)){this.value=t}};gi([yi({type:Ne.Any})],Ka.prototype,"value",void 0);Ka=gi([fi({type:Me.Choice})],Ka);var Ha;let ja=Ha=class t extends ms{constructor(t){super(t);Object.setPrototypeOf(this,Ha.prototype)}};ja=Ha=gi([fi({type:Me.Sequence})],ja);class Ua{constructor(t={}){this.keySpec=0;this.cspName="";this.signature=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Ua.prototype,"keySpec",void 0);gi([yi({type:Ne.BmpString})],Ua.prototype,"cspName",void 0);gi([yi({type:Ne.BitString})],Ua.prototype,"signature",void 0);var Fa;let _a=Fa=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Fa.prototype)}};_a=Fa=gi([fi({type:Me.Sequence,itemType:Ne.Any})],_a);var Va;let La=Va=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Va.prototype)}};La=Va=gi([fi({type:Me.Sequence,itemType:Ne.Any})],La);var $a;class Ga{constructor(t={}){this.name="";this.value="";Object.assign(this,t)}}gi([yi({type:Ne.BmpString})],Ga.prototype,"name",void 0);gi([yi({type:Ne.BmpString})],Ga.prototype,"value",void 0);let Wa=$a=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,$a.prototype)}};Wa=$a=gi([fi({type:Me.Sequence,itemType:Ga})],Wa);let Qa=class t extends Mi{};Qa=gi([fi({type:Me.Sequence})],Qa);let qa=class t extends Mi{};qa=gi([fi({type:Me.Sequence})],qa);let za=class t extends Es{};za=gi([fi({type:Me.Sequence})],za);class Ja{constructor(t={}){this.clientId=0;this.machineName="";this.userName="";this.processName="";Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Ja.prototype,"clientId",void 0);gi([yi({type:Ne.Utf8String})],Ja.prototype,"machineName",void 0);gi([yi({type:Ne.Utf8String})],Ja.prototype,"userName",void 0);gi([yi({type:Ne.Utf8String})],Ja.prototype,"processName",void 0);const Za="2.16.840.1.113730";const Xa=`${Za}.1`;let Ya=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],Ya.prototype,"value",void 0);Ya=gi([fi({type:Me.Choice})],Ya);let tc=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],tc.prototype,"value",void 0);tc=gi([fi({type:Me.Choice})],tc);let ec=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],ec.prototype,"value",void 0);ec=gi([fi({type:Me.Choice})],ec);let ic=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],ic.prototype,"value",void 0);ic=gi([fi({type:Me.Choice})],ic);const rc=`${Xa}.1`;var sc;(function(t){t[t["sslClient"]=1]="sslClient";t[t["sslServer"]=2]="sslServer";t[t["sMime"]=4]="sMime";t[t["objectSigning"]=8]="objectSigning";t[t["sslCa"]=32]="sslCa";t[t["sMimeCa"]=64]="sMimeCa";t[t["objectSigningCa"]=128]="objectSigningCa"})(sc||(sc={}));class nc extends ke{toJSON(){const t=this.toNumber();const e=[];if(t&sc.objectSigning){e.push("objectSigning")}if(t&sc.objectSigningCa){e.push("objectSigningCa")}if(t&sc.sMime){e.push("sMime")}if(t&sc.sMimeCa){e.push("sMimeCa")}if(t&sc.sslCa){e.push("sslCa")}if(t&sc.sslClient){e.push("sslClient")}if(t&sc.sslServer){e.push("sslServer")}return e}toString(){return`[${this.toJSON().join(", ")}]`}}const oc=`${Xa}.13`;let ac=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],ac.prototype,"value",void 0);ac=gi([fi({type:Me.Choice})],ac);let cc=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],cc.prototype,"value",void 0);cc=gi([fi({type:Me.Choice})],cc);let uc=class t{constructor(t){this.value="";if(t){this.value=t}}};gi([yi({type:Ne.IA5String})],uc.prototype,"value",void 0);uc=gi([fi({type:Me.Choice})],uc);const lc="1.3.6.1.4.1.52266.1";let pc=class t{constructor(t={}){this.leiCode="";Object.assign(this,t)}};gi([yi({type:Zt})],pc.prototype,"leiCode",void 0);gi([yi({type:Zt,context:0,optional:true})],pc.prototype,"leiRole",void 0);pc=gi([fi({type:Me.Sequence})],pc);let hc=class t{get text(){if(this.bmpString!==undefined){return this.bmpString}if(this.ia5String!==undefined){return this.ia5String}if(this.printableString!==undefined){return this.printableString}if(this.utf8String!==undefined){return this.utf8String}if(this.visibleString!==undefined){return this.visibleString}return undefined}set text(t){this.printableString=t}constructor(t){if(t){this.text=t}}};gi([yi({type:Ne.IA5String})],hc.prototype,"ia5String",void 0);gi([yi({type:Ne.VisibleString})],hc.prototype,"visibleString",void 0);gi([yi({type:Ne.BmpString})],hc.prototype,"bmpString",void 0);gi([yi({type:Ne.Utf8String})],hc.prototype,"utf8String",void 0);gi([yi({type:Ne.PrintableString})],hc.prototype,"printableString",void 0);hc=gi([fi({type:Me.Choice})],hc);let dc=class t extends hc{constructor(t){super();if(typeof t==="string"){this.text=t}else if(t instanceof pc){this.struct=t}}};gi([yi({type:pc})],dc.prototype,"struct",void 0);dc=gi([fi({type:Me.Choice})],dc);const fc="1.3.6.1.4.1.52266.2";let yc=class t extends hc{};yc=gi([fi({type:Me.Choice})],yc);class Sc{get position(){return this.offset}constructor(t){this.offset=0;this.view=n.BufferSourceConverter.toUint8Array(t)}read(t=1){const e=this.view.slice(this.offset,this.offset+t);this.offset=this.offset+e.length;return e}readByte(){const t=this.read();if(!t.length){throw new Error("End of stream")}return t[0]}readNumber(t){const e=this.read(t);const i=n.Convert.ToHex(e);return parseInt(i,16)}readEnd(){return this.read(this.view.length-this.offset)}reset(){this.offset=0}}class Ac{static createStream(t){const e=n.BufferSourceConverter.toUint8Array(t);return new Sc(e)}}var Cc;(function(t){t[t["certificateTimestamp"]=0]="certificateTimestamp";t[t["treeHash"]=1]="treeHash"})(Cc||(Cc={}));var vc;(function(t){t[t["none"]=0]="none";t[t["md5"]=1]="md5";t[t["sha1"]=2]="sha1";t[t["sha224"]=3]="sha224";t[t["sha256"]=4]="sha256";t[t["sha384"]=5]="sha384";t[t["sha512"]=6]="sha512"})(vc||(vc={}));var mc;(function(t){t[t["anonymous"]=0]="anonymous";t[t["rsa"]=1]="rsa";t[t["dsa"]=2]="dsa";t[t["ecdsa"]=3]="ecdsa"})(mc||(mc={}));class gc extends Ac{constructor(t){super();this.version=0;this.logId=new ArrayBuffer(32);this.timestamp=new Date;this.extensions=new ArrayBuffer(0);this.hashAlgorithm=0;this.signatureAlgorithm=0;this.signature=new ArrayBuffer(0);if(t){this.parse(t)}}parse(t){this.version=t.readByte();t.read(2);this.logId=n.BufferSourceConverter.toArrayBuffer(t.read(32));this.timestamp=new Date(t.readNumber(8));const e=t.readNumber(2);this.extensions=t.read(e).buffer;this.hashAlgorithm=t.readByte();this.signatureAlgorithm=t.readByte();this.signature=t.read(t.readNumber(2)).buffer}toJSON(){return{version:this.version,logId:n.Convert.ToHex(this.logId),timestamp:this.timestamp,extensions:n.Convert.ToBase64(this.extensions),hashAlgorithm:vc[this.hashAlgorithm]||"undefined",signatureAlgorithm:mc[this.signatureAlgorithm]||"undefined",signature:n.Convert.ToBase64(this.signature)}}}const wc="1.3.6.1.4.1.11129.2.4.2";class Ec extends Ke{constructor(){super(...arguments);this.items=[]}fromASN(t){super.fromASN(t);const e=new Sc(this.buffer);const i=e.readNumber(2);this.items=[];while(e.position<i){this.items.push(new gc(e))}return this}toJSON(){return this.items.map((t=>t.toJSON()))}}var Pc;(function(t){t[t["v1"]=1]="v1"})(Pc||(Pc={}));const Dc="1.2.840.113583.1.1.9.2";class bc{constructor(t={}){this.version=Pc.v1;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],bc.prototype,"version",void 0);const Bc="1.2.840.113583.1.1.9.1";class Ic{constructor(t={}){this.version=Pc.v1;this.location=new ki;this.requiresAuth=false;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Ic.prototype,"version",void 0);gi([yi({type:ki})],Ic.prototype,"location",void 0);gi([yi({type:Ne.Boolean,defaultValue:false,optional:true})],Ic.prototype,"requiresAuth",void 0);class xc{constructor(t={}){this.hashAlg=new fs;this.hashValue=new Ke;Object.assign(this,t)}}gi([yi({type:fs})],xc.prototype,"hashAlg",void 0);gi([yi({type:Ke})],xc.prototype,"hashValue",void 0);class Tc{constructor(t={}){this.mediaType="";this.logotypeHash=[];this.logotypeURI=[];Object.assign(this,t)}}gi([yi({type:Ne.IA5String})],Tc.prototype,"mediaType",void 0);gi([yi({type:xc,repeated:"sequence"})],Tc.prototype,"logotypeHash",void 0);gi([yi({type:Ne.IA5String,repeated:"sequence"})],Tc.prototype,"logotypeURI",void 0);var Oc;(function(t){t[t["mono"]=1]="mono";t[t["stereo"]=2]="stereo";t[t["quad"]=4]="quad"})(Oc||(Oc={}));class Rc{constructor(t={}){this.fileSize=0;this.playTime=0;this.channels=Oc.mono;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Rc.prototype,"fileSize",void 0);gi([yi({type:Ne.Integer})],Rc.prototype,"playTime",void 0);gi([yi({type:Ne.Integer})],Rc.prototype,"channels",void 0);gi([yi({type:Ne.Integer,implicit:true,context:3,optional:true})],Rc.prototype,"sampleRate",void 0);gi([yi({type:Ne.IA5String,implicit:true,context:4,optional:true})],Rc.prototype,"language",void 0);class Mc{constructor(t={}){this.audioDetails=new Tc;Object.assign(this,t)}}gi([yi({type:Tc})],Mc.prototype,"audioDetails",void 0);gi([yi({type:Rc,optional:true})],Mc.prototype,"audioInfo",void 0);let Nc=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.Integer,context:1,implicit:true})],Nc.prototype,"numBits",void 0);gi([yi({type:Ne.Integer,context:2,implicit:true})],Nc.prototype,"tableSize",void 0);Nc=gi([fi({type:Me.Choice})],Nc);var kc;(function(t){t[t["grayScale"]=0]="grayScale";t[t["color"]=1]="color"})(kc||(kc={}));class Kc{constructor(t={}){this.type=kc.color;this.fileSize=0;this.xSize=0;this.ySize=0;Object.assign(this,t)}}gi([yi({type:Ne.Integer,context:0,implicit:true,defaultValue:kc.color})],Kc.prototype,"type",void 0);gi([yi({type:Ne.Integer})],Kc.prototype,"fileSize",void 0);gi([yi({type:Ne.Integer})],Kc.prototype,"xSize",void 0);gi([yi({type:Ne.Integer})],Kc.prototype,"ySize",void 0);gi([yi({type:Nc})],Kc.prototype,"resolution",void 0);gi([yi({type:Ne.IA5String,context:4,implicit:true,optional:true})],Kc.prototype,"language",void 0);class Hc{constructor(t={}){this.imageDetails=new Tc;Object.assign(this,t)}}gi([yi({type:Tc})],Hc.prototype,"imageDetails",void 0);gi([yi({type:Kc,optional:true})],Hc.prototype,"imageInfo",void 0);class jc{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Hc,repeated:"sequence",optional:true})],jc.prototype,"image",void 0);gi([yi({type:Mc,repeated:"sequence",context:1,optional:true})],jc.prototype,"audio",void 0);class Uc{constructor(t={}){this.refStructHash=[];this.refStructURI=[];Object.assign(this,t)}}gi([yi({type:xc,repeated:"sequence"})],Uc.prototype,"refStructHash",void 0);gi([yi({type:Ne.IA5String,repeated:"sequence"})],Uc.prototype,"refStructURI",void 0);let Fc=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:jc,implicit:true,context:0})],Fc.prototype,"direct",void 0);gi([yi({type:Uc,implicit:true,context:1})],Fc.prototype,"indirect",void 0);Fc=gi([fi({type:Me.Choice})],Fc);class _c{constructor(t={}){this.logotypeType="";this.info=new Fc;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],_c.prototype,"logotypeType",void 0);gi([yi({type:Fc})],_c.prototype,"info",void 0);class Vc{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Fc,context:0,repeated:"sequence",optional:true})],Vc.prototype,"communityLogos",void 0);gi([yi({type:Fc,context:1,optional:true})],Vc.prototype,"issuerLogo",void 0);gi([yi({type:Fc,context:2,optional:true})],Vc.prototype,"subjectLogo",void 0);gi([yi({type:_c,context:3,repeated:"sequence",optional:true})],Vc.prototype,"otherLogos",void 0);const Lc="1.3.6.1.5.5.7.1.12";var $c,Gc,Wc;const Qc="1.3.6.1.5.5.7";const qc=`${Qc}.1`;let zc=$c=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,$c.prototype)}};zc=$c=gi([fi({type:Me.Sequence,itemType:Ne.IA5String})],zc);class Jc{constructor(t={}){this.claim="";this.permitted=[];Object.assign(this,t)}}gi([yi({type:Ne.IA5String})],Jc.prototype,"claim",void 0);gi([yi({type:Ne.Utf8String,repeated:"sequence"})],Jc.prototype,"permitted",void 0);let Zc=Gc=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Gc.prototype)}};Zc=Gc=gi([fi({type:Me.Sequence,itemType:Jc})],Zc);class Xc{constructor(t={}){Object.assign(this,t)}}gi([yi({type:zc,optional:true,context:0})],Xc.prototype,"mustInclude",void 0);gi([yi({type:Zc,optional:true,context:1})],Xc.prototype,"permittedValues",void 0);const Yc=`${qc}.26`;class tu{constructor(){this.start="";this.count=2}}gi([yi({type:Ne.IA5String})],tu.prototype,"start",void 0);gi([yi({type:Ne.Integer})],tu.prototype,"count",void 0);let eu=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ne.IA5String,context:0})],eu.prototype,"spc",void 0);gi([yi({type:tu,context:1})],eu.prototype,"range",void 0);gi([yi({type:Ne.IA5String,context:2})],eu.prototype,"one",void 0);eu=gi([fi({type:Me.Choice})],eu);let iu=Wc=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Wc.prototype)}};iu=Wc=gi([fi({type:Me.Sequence,itemType:eu})],iu);var ru;const su="1.3.6.1.4.1.11129.2.1.17";var nu;(function(t){t[t["verified"]=0]="verified";t[t["selfSigned"]=1]="selfSigned";t[t["unverified"]=2]="unverified";t[t["failed"]=3]="failed"})(nu||(nu={}));class ou{constructor(t={}){this.verifiedBootKey=new Ke;this.deviceLocked=false;this.verifiedBootState=nu.verified;Object.assign(this,t)}}gi([yi({type:Ke})],ou.prototype,"verifiedBootKey",void 0);gi([yi({type:Ne.Boolean})],ou.prototype,"deviceLocked",void 0);gi([yi({type:Ne.Enumerated})],ou.prototype,"verifiedBootState",void 0);gi([yi({type:Ke,optional:true})],ou.prototype,"verifiedBootHash",void 0);let au=ru=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ru.prototype)}};au=ru=gi([fi({type:Me.Set,itemType:Ne.Integer})],au);class cu{constructor(t={}){Object.assign(this,t)}}gi([yi({context:1,type:au,optional:true})],cu.prototype,"purpose",void 0);gi([yi({context:2,type:Ne.Integer,optional:true})],cu.prototype,"algorithm",void 0);gi([yi({context:3,type:Ne.Integer,optional:true})],cu.prototype,"keySize",void 0);gi([yi({context:5,type:au,optional:true})],cu.prototype,"digest",void 0);gi([yi({context:6,type:au,optional:true})],cu.prototype,"padding",void 0);gi([yi({context:10,type:Ne.Integer,optional:true})],cu.prototype,"ecCurve",void 0);gi([yi({context:200,type:Ne.Integer,optional:true})],cu.prototype,"rsaPublicExponent",void 0);gi([yi({context:203,type:au,optional:true})],cu.prototype,"mgfDigest",void 0);gi([yi({context:303,type:Ne.Null,optional:true})],cu.prototype,"rollbackResistance",void 0);gi([yi({context:305,type:Ne.Null,optional:true})],cu.prototype,"earlyBootOnly",void 0);gi([yi({context:400,type:Ne.Integer,optional:true})],cu.prototype,"activeDateTime",void 0);gi([yi({context:401,type:Ne.Integer,optional:true})],cu.prototype,"originationExpireDateTime",void 0);gi([yi({context:402,type:Ne.Integer,optional:true})],cu.prototype,"usageExpireDateTime",void 0);gi([yi({context:405,type:Ne.Integer,optional:true})],cu.prototype,"usageCountLimit",void 0);gi([yi({context:503,type:Ne.Null,optional:true})],cu.prototype,"noAuthRequired",void 0);gi([yi({context:504,type:Ne.Integer,optional:true})],cu.prototype,"userAuthType",void 0);gi([yi({context:505,type:Ne.Integer,optional:true})],cu.prototype,"authTimeout",void 0);gi([yi({context:506,type:Ne.Null,optional:true})],cu.prototype,"allowWhileOnBody",void 0);gi([yi({context:507,type:Ne.Null,optional:true})],cu.prototype,"trustedUserPresenceRequired",void 0);gi([yi({context:508,type:Ne.Null,optional:true})],cu.prototype,"trustedConfirmationRequired",void 0);gi([yi({context:509,type:Ne.Null,optional:true})],cu.prototype,"unlockedDeviceRequired",void 0);gi([yi({context:600,type:Ne.Null,optional:true})],cu.prototype,"allApplications",void 0);gi([yi({context:601,type:Ke,optional:true})],cu.prototype,"applicationId",void 0);gi([yi({context:701,type:Ne.Integer,optional:true})],cu.prototype,"creationDateTime",void 0);gi([yi({context:702,type:Ne.Integer,optional:true})],cu.prototype,"origin",void 0);gi([yi({context:703,type:Ne.Null,optional:true})],cu.prototype,"rollbackResistant",void 0);gi([yi({context:704,type:ou,optional:true})],cu.prototype,"rootOfTrust",void 0);gi([yi({context:705,type:Ne.Integer,optional:true})],cu.prototype,"osVersion",void 0);gi([yi({context:706,type:Ne.Integer,optional:true})],cu.prototype,"osPatchLevel",void 0);gi([yi({context:709,type:Ke,optional:true})],cu.prototype,"attestationApplicationId",void 0);gi([yi({context:710,type:Ke,optional:true})],cu.prototype,"attestationIdBrand",void 0);gi([yi({context:711,type:Ke,optional:true})],cu.prototype,"attestationIdDevice",void 0);gi([yi({context:712,type:Ke,optional:true})],cu.prototype,"attestationIdProduct",void 0);gi([yi({context:713,type:Ke,optional:true})],cu.prototype,"attestationIdSerial",void 0);gi([yi({context:714,type:Ke,optional:true})],cu.prototype,"attestationIdImei",void 0);gi([yi({context:715,type:Ke,optional:true})],cu.prototype,"attestationIdMeid",void 0);gi([yi({context:716,type:Ke,optional:true})],cu.prototype,"attestationIdManufacturer",void 0);gi([yi({context:717,type:Ke,optional:true})],cu.prototype,"attestationIdModel",void 0);gi([yi({context:718,type:Ne.Integer,optional:true})],cu.prototype,"vendorPatchLevel",void 0);gi([yi({context:719,type:Ne.Integer,optional:true})],cu.prototype,"bootPatchLevel",void 0);gi([yi({context:720,type:Ne.Null,optional:true})],cu.prototype,"deviceUniqueAttestation",void 0);gi([yi({context:723,type:Ke,optional:true})],cu.prototype,"attestationIdSecondImei",void 0);gi([yi({context:724,type:Ke,optional:true})],cu.prototype,"moduleHash",void 0);var uu;(function(t){t[t["software"]=0]="software";t[t["trustedEnvironment"]=1]="trustedEnvironment";t[t["strongBox"]=2]="strongBox"})(uu||(uu={}));var lu;(function(t){t[t["KM2"]=1]="KM2";t[t["KM3"]=2]="KM3";t[t["KM4"]=3]="KM4";t[t["KM4_1"]=4]="KM4_1";t[t["keyMint1"]=100]="keyMint1";t[t["keyMint2"]=200]="keyMint2";t[t["keyMint3"]=300]="keyMint3";t[t["keyMint4"]=400]="keyMint4"})(lu||(lu={}));class pu{constructor(t={}){this.attestationVersion=lu.KM4;this.attestationSecurityLevel=uu.software;this.keymasterVersion=0;this.keymasterSecurityLevel=uu.software;this.attestationChallenge=new Ke;this.uniqueId=new Ke;this.softwareEnforced=new cu;this.teeEnforced=new cu;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],pu.prototype,"attestationVersion",void 0);gi([yi({type:Ne.Enumerated})],pu.prototype,"attestationSecurityLevel",void 0);gi([yi({type:Ne.Integer})],pu.prototype,"keymasterVersion",void 0);gi([yi({type:Ne.Enumerated})],pu.prototype,"keymasterSecurityLevel",void 0);gi([yi({type:Ke})],pu.prototype,"attestationChallenge",void 0);gi([yi({type:Ke})],pu.prototype,"uniqueId",void 0);gi([yi({type:cu})],pu.prototype,"softwareEnforced",void 0);gi([yi({type:cu})],pu.prototype,"teeEnforced",void 0);class hu{constructor(t={}){this.attestationVersion=lu.keyMint4;this.attestationSecurityLevel=uu.software;this.keyMintVersion=0;this.keyMintSecurityLevel=uu.software;this.attestationChallenge=new Ke;this.uniqueId=new Ke;this.softwareEnforced=new cu;this.hardwareEnforced=new cu;Object.assign(this,t)}toLegacyKeyDescription(){return new pu({attestationVersion:this.attestationVersion,attestationSecurityLevel:this.attestationSecurityLevel,keymasterVersion:this.keyMintVersion,keymasterSecurityLevel:this.keyMintSecurityLevel,attestationChallenge:this.attestationChallenge,uniqueId:this.uniqueId,softwareEnforced:this.softwareEnforced,teeEnforced:this.hardwareEnforced})}static fromLegacyKeyDescription(t){return new hu({attestationVersion:t.attestationVersion,attestationSecurityLevel:t.attestationSecurityLevel,keyMintVersion:t.keymasterVersion,keyMintSecurityLevel:t.keymasterSecurityLevel,attestationChallenge:t.attestationChallenge,uniqueId:t.uniqueId,softwareEnforced:t.softwareEnforced,hardwareEnforced:t.teeEnforced})}}gi([yi({type:Ne.Integer})],hu.prototype,"attestationVersion",void 0);gi([yi({type:Ne.Enumerated})],hu.prototype,"attestationSecurityLevel",void 0);gi([yi({type:Ne.Integer})],hu.prototype,"keyMintVersion",void 0);gi([yi({type:Ne.Enumerated})],hu.prototype,"keyMintSecurityLevel",void 0);gi([yi({type:Ke})],hu.prototype,"attestationChallenge",void 0);gi([yi({type:Ke})],hu.prototype,"uniqueId",void 0);gi([yi({type:cu})],hu.prototype,"softwareEnforced",void 0);gi([yi({type:cu})],hu.prototype,"hardwareEnforced",void 0);var du;let fu=class t extends cu{};fu=gi([fi({type:Me.Choice})],fu);let yu=du=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,du.prototype)}findProperty(t){const e=this.find((e=>t in e));if(e){return e[t]}return undefined}};yu=du=gi([fi({type:Me.Sequence,itemType:fu})],yu);class Su{get keyMintVersion(){return this.keymasterVersion}set keyMintVersion(t){this.keymasterVersion=t}get keyMintSecurityLevel(){return this.keymasterSecurityLevel}set keyMintSecurityLevel(t){this.keymasterSecurityLevel=t}get hardwareEnforced(){return this.teeEnforced}set hardwareEnforced(t){this.teeEnforced=t}constructor(t={}){this.attestationVersion=lu.KM4;this.attestationSecurityLevel=uu.software;this.keymasterVersion=0;this.keymasterSecurityLevel=uu.software;this.attestationChallenge=new Ke;this.uniqueId=new Ke;this.softwareEnforced=new yu;this.teeEnforced=new yu;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Su.prototype,"attestationVersion",void 0);gi([yi({type:Ne.Enumerated})],Su.prototype,"attestationSecurityLevel",void 0);gi([yi({type:Ne.Integer})],Su.prototype,"keymasterVersion",void 0);gi([yi({type:Ne.Enumerated})],Su.prototype,"keymasterSecurityLevel",void 0);gi([yi({type:Ke})],Su.prototype,"attestationChallenge",void 0);gi([yi({type:Ke})],Su.prototype,"uniqueId",void 0);gi([yi({type:yu})],Su.prototype,"softwareEnforced",void 0);gi([yi({type:yu})],Su.prototype,"teeEnforced",void 0);let Au=class t extends Su{constructor(t={}){if("keymasterVersion"in t&&!("keyMintVersion"in t)){t.keyMintVersion=t.keymasterVersion}if("keymasterSecurityLevel"in t&&!("keyMintSecurityLevel"in t)){t.keyMintSecurityLevel=t.keymasterSecurityLevel}if("teeEnforced"in t&&!("hardwareEnforced"in t)){t.hardwareEnforced=t.teeEnforced}super(t)}};Au=gi([fi({type:Me.Sequence})],Au);class Cu{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ne.OctetString})],Cu.prototype,"packageName",void 0);gi([yi({type:Ne.Integer})],Cu.prototype,"version",void 0);class vu{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Cu,repeated:"set"})],vu.prototype,"packageInfos",void 0);gi([yi({type:Ne.OctetString,repeated:"set"})],vu.prototype,"signatureDigests",void 0);var mu=undefined&&undefined.__decorate||function(t,e,i,r){var s=arguments.length,n=s<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,i):r,o;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")n=Reflect.decorate(t,e,i,r);else for(var a=t.length-1;a>=0;a--)if(o=t[a])n=(s<3?o(n):s>3?o(e,i,n):o(e,i))||n;return s>3&&n&&Object.defineProperty(e,i,n),n};const gu="2.23.140.3.1";class wu{constructor(t={}){Object.assign(this,t)}}mu([yi({type:Ne.PrintableString})],wu.prototype,"registrationSchemeIdentifier",void 0);mu([yi({type:Ne.PrintableString})],wu.prototype,"registrationCountry",void 0);mu([yi({type:Ne.PrintableString,optional:true,context:0,implicit:true})],wu.prototype,"registrationStateOrProvince",void 0);mu([yi({type:Ne.Utf8String})],wu.prototype,"registrationReference",void 0);
|
|
107
107
|
/**
|
|
108
108
|
* @license
|
|
109
109
|
* Copyright (c) Peculiar Ventures, LLC.
|
|
@@ -117,14 +117,14 @@ function t(t,e,i,r="application/octet-stream"){const s=new Blob([t],{type:r});if
|
|
|
117
117
|
*
|
|
118
118
|
* This source code is licensed under the MIT license found in the
|
|
119
119
|
* LICENSE file in the root directory of this source tree.
|
|
120
|
-
*/const Iu={[
|
|
120
|
+
*/const Iu={[Fi]:Vi,[Li]:Gi,[Wi]:Qi,[Zi]:Xi,[tr]:ar,[dr]:Cr,"2.5.29.46":Cr,[gr]:wr,[Er]:Dr,[Br]:Ir,[xr]:Tr,[Or]:Rr,[Nr]:kr,[Kr]:jr,[Fr]:Lr,[$r]:Gr,[Qr]:zr,[Zr]:Xr,[es]:is,[rs]:ss,[Ca]:Ea,[Ia]:xa,[Ta]:Ra,[oc]:ac,[rc]:nc,[Ma]:Na,[wc]:Ec,[lc]:dc,[fc]:yc,[Bc]:Ic,[Dc]:bc,[ns]:os,[as]:ls,"2.16.724.1.2.2.4.1":fa,[la]:fa,[Lc]:Vc,[Yc]:iu,[hs]:ds,[cr]:ur,[lr]:pr,[su]:Su,[gu]:wu};class xu extends Bu{getAsnExtnValue(){return this.asn.extnValue.buffer}constructor(t){super(t,vs);const e=this.getAsnExtnValue();try{const t=Iu[this.asn.extnID];if(t){this.value=Ai.parse(e,t)}else{console.warn(`Didn't detect parser for "${this.asn.extnID}" extension.`);this.value=n.Convert.ToHex(e)}}catch(t){console.error(`Error parse "${this.asn.extnID}" extension:`,t.message);this.value=n.Convert.ToHex(e)}}}
|
|
121
121
|
/**
|
|
122
122
|
* @license
|
|
123
123
|
* Copyright (c) Peculiar Ventures, LLC.
|
|
124
124
|
*
|
|
125
125
|
* This source code is licensed under the MIT license found in the
|
|
126
126
|
* LICENSE file in the root directory of this source tree.
|
|
127
|
-
*/const Tu="-{5}";const Ou="\\n";const Ru=`[^${Ou}]+`;const Mu=`${Tu}BEGIN (${Ru}(?=${Tu}))${Tu}`;const Nu=`${Tu}END \\1${Tu}`;const ku="\\n";const Ku=`[^:${Ou}]+`;const Hu=`(?:[^${Ou}]+${ku}(?: +[^${Ou}]+${ku})*)`;const ju="[a-zA-Z0-9=+/]+";const Uu=`(?:${ju}${ku})+`;const
|
|
127
|
+
*/const Tu="-{5}";const Ou="\\n";const Ru=`[^${Ou}]+`;const Mu=`${Tu}BEGIN (${Ru}(?=${Tu}))${Tu}`;const Nu=`${Tu}END \\1${Tu}`;const ku="\\n";const Ku=`[^:${Ou}]+`;const Hu=`(?:[^${Ou}]+${ku}(?: +[^${Ou}]+${ku})*)`;const ju="[a-zA-Z0-9=+/]+";const Uu=`(?:${ju}${ku})+`;const Fu=`${Mu}${ku}(?:((?:${Ku}: ${Hu})+))?${ku}?(${Uu})${Nu}`;class _u{static isPem(t){return typeof t==="string"&&new RegExp(Fu,"g").test(t.replace(/\r/g,""))}static decodeWithHeaders(t){t=t.replace(/\r/g,"");const e=new RegExp(Fu,"g");const i=[];let r=null;while(r=e.exec(t)){const t=r[3].replace(new RegExp(`[${Ou}]+`,"g"),"");const e={type:r[1],headers:[],rawData:n.Convert.FromBase64(t)};const s=r[2];if(s){const t=s.split(new RegExp(ku,"g"));let i=null;for(const r of t){const[t,s]=r.split(/:(.*)/);if(s===undefined){if(!i){throw new Error("Cannot parse PEM string. Incorrect header value")}i.value+=t.trim()}else{if(i){e.headers.push(i)}i={key:t,value:s.trim()}}}if(i){e.headers.push(i)}}i.push(e)}return i}static decode(t){const e=this.decodeWithHeaders(t);return e.map((t=>t.rawData))}static encode(t,e){if(Array.isArray(t)){const i=new Array;if(e){t.forEach((t=>{if(!n.BufferSourceConverter.isBufferSource(t)){throw new TypeError("Cannot encode array of BufferSource in PEM format. Not all items of the array are BufferSource")}i.push(this.encodeStruct({type:e,rawData:n.BufferSourceConverter.toArrayBuffer(t)}))}))}else{t.forEach((t=>{if(!("type"in t)){throw new TypeError("Cannot encode array of IPemStruct in PEM format. Not all items of the array are PemStrut")}i.push(this.encodeStruct(t))}))}return i.join("\n")}if(!e){throw new Error("Required argument 'tag' is missed")}return this.encodeStruct({type:e,rawData:n.BufferSourceConverter.toArrayBuffer(t)})}static encodeStruct(t){var e;const i=t.type.toLocaleUpperCase();const r=[];r.push(`-----BEGIN ${i}-----`);if((e=t.headers)===null||e===void 0?void 0:e.length){for(const e of t.headers){r.push(`${e.key}: ${e.value}`)}r.push("")}const s=n.Convert.ToBase64(t.rawData);let o;let a=0;const c=Array();while(a<s.length){if(s.length-a<64){o=s.substring(a)}else{o=s.substring(a,a+64);a+=64}if(o.length!==0){c.push(o);if(o.length<64){break}}else{break}}r.push(...c);r.push(`-----END ${i}-----`);return r.join("\n")}}_u.CertificateTag="CERTIFICATE";_u.CrlTag="CRL";_u.CertificateRequestTag="CERTIFICATE REQUEST";_u.AttributeCertificateTag="ATTRIBUTE CERTIFICATE";
|
|
128
128
|
/**
|
|
129
129
|
* @license
|
|
130
130
|
* Copyright (c) Peculiar Ventures, LLC.
|
|
@@ -138,5 +138,5 @@ function t(t,e,i,r="application/octet-stream"){const s=new Blob([t],{type:r});if
|
|
|
138
138
|
*
|
|
139
139
|
* This source code is licensed under the MIT license found in the
|
|
140
140
|
* LICENSE file in the root directory of this source tree.
|
|
141
|
-
*/const $u=t=>{if(Fu.isPem(t)){return Fu.decode(t)[0]}if(n.Convert.isHex(t)){return n.Convert.FromHex(t)}if(n.Convert.isBase64(t)){return n.Convert.FromBase64(t)}if(n.Convert.isBase64Url(t)){return n.Convert.FromBase64Url(t)}return n.Convert.FromBinary(t)};const Gu=async(t,e)=>{const i=Lu.get();if(i.subtle){return i.subtle.digest(t,e)}return undefined};class Wu{constructor(t={}){this.acIssuer=new ki;this.acSerial=0;this.attrs=[];Object.assign(this,t)}}gi([yi({type:ki})],Wu.prototype,"acIssuer",void 0);gi([yi({type:Ne.Integer})],Wu.prototype,"acSerial",void 0);gi([yi({type:Yr,repeated:"sequence"})],Wu.prototype,"attrs",void 0);var Qu;let qu=Qu=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Qu.prototype)}};qu=Qu=gi([fi({type:Me.Sequence,itemType:Ne.ObjectIdentifier})],qu);class zu{constructor(t={}){this.permitUnSpecified=true;Object.assign(this,t)}}gi([yi({type:Ne.Integer,optional:true})],zu.prototype,"pathLenConstraint",void 0);gi([yi({type:qu,implicit:true,context:0,optional:true})],zu.prototype,"permittedAttrs",void 0);gi([yi({type:qu,implicit:true,context:1,optional:true})],zu.prototype,"excludedAttrs",void 0);gi([yi({type:Ne.Boolean,defaultValue:true})],zu.prototype,"permitUnSpecified",void 0);class Ju{constructor(t={}){this.issuer=new zi;this.serial=new ArrayBuffer(0);this.issuerUID=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:zi})],Ju.prototype,"issuer",void 0);gi([yi({type:Ne.Integer,converter:_e})],Ju.prototype,"serial",void 0);gi([yi({type:Ne.BitString,optional:true})],Ju.prototype,"issuerUID",void 0);var Zu;(function(t){t[t["publicKey"]=0]="publicKey";t[t["publicKeyCert"]=1]="publicKeyCert";t[t["otherObjectTypes"]=2]="otherObjectTypes"})(Zu||(Zu={}));class Xu{constructor(t={}){this.digestedObjectType=Zu.publicKey;this.digestAlgorithm=new fs;this.objectDigest=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Enumerated})],Xu.prototype,"digestedObjectType",void 0);gi([yi({type:Ne.ObjectIdentifier,optional:true})],Xu.prototype,"otherObjectTypeID",void 0);gi([yi({type:fs})],Xu.prototype,"digestAlgorithm",void 0);gi([yi({type:Ne.BitString})],Xu.prototype,"objectDigest",void 0);class Yu{constructor(t={}){Object.assign(this,t)}}gi([yi({type:zi,optional:true})],Yu.prototype,"issuerName",void 0);gi([yi({type:Ju,context:0,implicit:true,optional:true})],Yu.prototype,"baseCertificateID",void 0);gi([yi({type:Xu,context:1,implicit:true,optional:true})],Yu.prototype,"objectDigestInfo",void 0);let tl=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ki,repeated:"sequence"})],tl.prototype,"v1Form",void 0);gi([yi({type:Yu,context:0,implicit:true})],tl.prototype,"v2Form",void 0);tl=gi([fi({type:Me.Choice})],tl);class el{constructor(t={}){this.notBeforeTime=new Date;this.notAfterTime=new Date;Object.assign(this,t)}}gi([yi({type:Ne.GeneralizedTime})],el.prototype,"notBeforeTime",void 0);gi([yi({type:Ne.GeneralizedTime})],el.prototype,"notAfterTime",void 0);class il{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ju,implicit:true,context:0,optional:true})],il.prototype,"baseCertificateID",void 0);gi([yi({type:zi,implicit:true,context:1,optional:true})],il.prototype,"entityName",void 0);gi([yi({type:Xu,implicit:true,context:2,optional:true})],il.prototype,"objectDigestInfo",void 0);var rl;(function(t){t[t["v2"]=1]="v2"})(rl||(rl={}));class sl{constructor(t={}){this.version=rl.v2;this.holder=new il;this.issuer=new tl;this.signature=new fs;this.serialNumber=new ArrayBuffer(0);this.attrCertValidityPeriod=new el;this.attributes=[];Object.assign(this,t)}}gi([yi({type:Ne.Integer})],sl.prototype,"version",void 0);gi([yi({type:il})],sl.prototype,"holder",void 0);gi([yi({type:tl})],sl.prototype,"issuer",void 0);gi([yi({type:fs})],sl.prototype,"signature",void 0);gi([yi({type:Ne.Integer,converter:_e})],sl.prototype,"serialNumber",void 0);gi([yi({type:el})],sl.prototype,"attrCertValidityPeriod",void 0);gi([yi({type:Yr,repeated:"sequence"})],sl.prototype,"attributes",void 0);gi([yi({type:Ne.BitString,optional:true})],sl.prototype,"issuerUniqueID",void 0);gi([yi({type:ms,optional:true})],sl.prototype,"extensions",void 0);class nl{constructor(t={}){this.acinfo=new sl;this.signatureAlgorithm=new fs;this.signatureValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:sl})],nl.prototype,"acinfo",void 0);gi([yi({type:fs})],nl.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ne.BitString})],nl.prototype,"signatureValue",void 0);var ol;(function(t){t[t["unmarked"]=1]="unmarked";t[t["unclassified"]=2]="unclassified";t[t["restricted"]=4]="restricted";t[t["confidential"]=8]="confidential";t[t["secret"]=16]="secret";t[t["topSecret"]=32]="topSecret"})(ol||(ol={}));class al extends ke{}class cl{constructor(t={}){this.type="";this.value=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier,implicit:true,context:0})],cl.prototype,"type",void 0);gi([yi({type:Ne.Any,implicit:true,context:1})],cl.prototype,"value",void 0);class ul{constructor(t={}){this.policyId="";this.classList=new al(ol.unclassified);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],ul.prototype,"policyId",void 0);gi([yi({type:al,defaultValue:new al(ol.unclassified)})],ul.prototype,"classList",void 0);gi([yi({type:cl,repeated:"set"})],ul.prototype,"securityCategories",void 0);class ll{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ke})],ll.prototype,"cotets",void 0);gi([yi({type:Ne.ObjectIdentifier})],ll.prototype,"oid",void 0);gi([yi({type:Ne.Utf8String})],ll.prototype,"string",void 0);class pl{constructor(t={}){this.values=[];Object.assign(this,t)}}gi([yi({type:zi,implicit:true,context:0,optional:true})],pl.prototype,"policyAuthority",void 0);gi([yi({type:ll,repeated:"sequence"})],pl.prototype,"values",void 0);var hl;class dl{constructor(t={}){this.targetCertificate=new Ju;Object.assign(this,t)}}gi([yi({type:Ju})],dl.prototype,"targetCertificate",void 0);gi([yi({type:ki,optional:true})],dl.prototype,"targetName",void 0);gi([yi({type:Xu,optional:true})],dl.prototype,"certDigestInfo",void 0);let fl=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ki,context:0,implicit:true})],fl.prototype,"targetName",void 0);gi([yi({type:ki,context:1,implicit:true})],fl.prototype,"targetGroup",void 0);gi([yi({type:dl,context:2,implicit:true})],fl.prototype,"targetCert",void 0);fl=gi([fi({type:Me.Choice})],fl);let yl=hl=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,hl.prototype)}};yl=hl=gi([fi({type:Me.Sequence,itemType:fl})],yl);var Sl;let Al=Sl=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Sl.prototype)}};Al=Sl=gi([fi({type:Me.Sequence,itemType:yl})],Al);class Cl{constructor(t={}){Object.assign(this,t)}}gi([yi({type:zi,implicit:true,context:0,optional:true})],Cl.prototype,"roleAuthority",void 0);gi([yi({type:ki,implicit:true,context:1})],Cl.prototype,"roleName",void 0);class vl{constructor(t={}){this.service=new ki;this.ident=new ki;Object.assign(this,t)}}gi([yi({type:ki})],vl.prototype,"service",void 0);gi([yi({type:ki})],vl.prototype,"ident",void 0);gi([yi({type:Ke,optional:true})],vl.prototype,"authInfo",void 0);const ml="0.4.0.9496";const gl=`${ml}.6`;let wl=class t{constructor(t={}){this.codeAuthority=new ki;this.codeId=new ki;this.shortName="";this.shortDescription="";Object.assign(this,t)}};gi([yi({type:ki,context:0})],wl.prototype,"codeAuthority",void 0);gi([yi({type:ki,context:1})],wl.prototype,"codeId",void 0);gi([yi({type:Ne.Utf8String,context:2})],wl.prototype,"shortName",void 0);gi([yi({type:Ne.Utf8String,context:3})],wl.prototype,"shortDescription",void 0);wl=gi([fi({type:Me.Sequence})],wl);let El=class t extends Oi{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};El=gi([fi({type:Me.Sequence})],El);const Pl=`${ml}.1`;let Dl=class t extends El{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};Dl=gi([fi({type:Me.Sequence})],Dl);const bl=`${ml}.2`;let Bl=class t extends El{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};Bl=gi([fi({type:Me.Sequence})],Bl);const Il=`${ml}.3`;let xl=class t extends El{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};xl=gi([fi({type:Me.Sequence})],xl);const Tl=`${ml}.4`;let Ol=class t extends El{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};Ol=gi([fi({type:Me.Sequence})],Ol);const Rl=`${ml}.8`;let Ml=class t{constructor(t={}){this.location="";this.base=0;this.degree=0;Object.assign(this,t)}toString(){return`${this.base} x 10^${this.degree} ${this.location}`}};gi([yi({type:Ne.PrintableString})],Ml.prototype,"location",void 0);gi([yi({type:Ne.Integer})],Ml.prototype,"base",void 0);gi([yi({type:Ne.Integer})],Ml.prototype,"degree",void 0);Ml=gi([fi({type:Me.Sequence})],Ml);const Nl=`${ml}.9`;let kl=class t{constructor(t={}){this.stars5=0;this.stars4=0;this.stars3=0;this.stars2=0;this.stars1=0;Object.assign(this,t)}};gi([yi({type:Ne.Integer})],kl.prototype,"stars5",void 0);gi([yi({type:Ne.Integer})],kl.prototype,"stars4",void 0);gi([yi({type:Ne.Integer})],kl.prototype,"stars3",void 0);gi([yi({type:Ne.Integer})],kl.prototype,"stars2",void 0);gi([yi({type:Ne.Integer})],kl.prototype,"stars1",void 0);kl=gi([fi({type:Me.Sequence})],kl);const Kl=`${ml}.5`;let Hl=class t{constructor(t={}){this.DNBvsDNO=new ke(0);this.DNBvsDNT=new ke(0);this.DNOvsDNT=new ke(0);Object.assign(this,t)}};gi([yi({type:ke,context:0})],Hl.prototype,"DNBvsDNO",void 0);gi([yi({type:ke,context:1})],Hl.prototype,"DNBvsDNT",void 0);gi([yi({type:ke,context:2})],Hl.prototype,"DNOvsDNT",void 0);Hl=gi([fi({type:Me.Sequence})],Hl);const jl=`${ml}.7`;let Ul=class t{constructor(t={}){this.assessmentAuthority=new ki;this.assessmentRef=new ki;this.assessmentLocation=new ki;this.dataStorageTerritory="";this.description="";Object.assign(this,t)}};gi([yi({type:ki,context:0})],Ul.prototype,"assessmentAuthority",void 0);gi([yi({type:ki,context:1})],Ul.prototype,"assessmentRef",void 0);gi([yi({type:ki,context:2})],Ul.prototype,"assessmentLocation",void 0);gi([yi({type:Ne.PrintableString,context:3})],Ul.prototype,"dataStorageTerritory",void 0);gi([yi({type:Ne.Utf8String,context:4})],Ul.prototype,"description",void 0);Ul=gi([fi({type:Me.Sequence})],Ul);class _l{constructor(t={}){this.issuer=new Oi;this.serialNumber=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Oi})],_l.prototype,"issuer",void 0);gi([yi({type:Ne.Integer,converter:_e})],_l.prototype,"serialNumber",void 0);let Fl=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ss,context:0,implicit:true})],Fl.prototype,"subjectKeyIdentifier",void 0);gi([yi({type:_l})],Fl.prototype,"issuerAndSerialNumber",void 0);Fl=gi([fi({type:Me.Choice})],Fl);var Vl;(function(t){t[t["v0"]=0]="v0";t[t["v1"]=1]="v1";t[t["v2"]=2]="v2";t[t["v3"]=3]="v3";t[t["v4"]=4]="v4";t[t["v5"]=5]="v5"})(Vl||(Vl={}));let Ll=class t extends fs{};Ll=gi([fi({type:Me.Sequence})],Ll);let $l=class t extends fs{};$l=gi([fi({type:Me.Sequence})],$l);let Gl=class t extends fs{};Gl=gi([fi({type:Me.Sequence})],Gl);let Wl=class t extends fs{};Wl=gi([fi({type:Me.Sequence})],Wl);let Ql=class t extends fs{};Ql=gi([fi({type:Me.Sequence})],Ql);let ql=class t extends fs{};ql=gi([fi({type:Me.Sequence})],ql);class zl{constructor(t={}){this.attrType="";this.attrValues=[];Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],zl.prototype,"attrType",void 0);gi([yi({type:Ne.Any,repeated:"set"})],zl.prototype,"attrValues",void 0);var Jl;class Zl{constructor(t={}){this.version=Vl.v0;this.sid=new Fl;this.digestAlgorithm=new Ll;this.signatureAlgorithm=new $l;this.signature=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Zl.prototype,"version",void 0);gi([yi({type:Fl})],Zl.prototype,"sid",void 0);gi([yi({type:Ll})],Zl.prototype,"digestAlgorithm",void 0);gi([yi({type:zl,repeated:"set",context:0,implicit:true,optional:true})],Zl.prototype,"signedAttrs",void 0);gi([yi({type:$l})],Zl.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ke})],Zl.prototype,"signature",void 0);gi([yi({type:zl,repeated:"set",context:1,implicit:true,optional:true})],Zl.prototype,"unsignedAttrs",void 0);let Xl=Jl=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Jl.prototype)}};Xl=Jl=gi([fi({type:Me.Set,itemType:Zl})],Xl);let Yl=class t extends Ss{};Yl=gi([fi({type:Me.Choice})],Yl);let tp=class t extends Zl{};tp=gi([fi({type:Me.Sequence})],tp);var ep;class ip{constructor(t={}){this.otherCertFormat="";this.otherCert=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],ip.prototype,"otherCertFormat",void 0);gi([yi({type:Ne.Any})],ip.prototype,"otherCert",void 0);let rp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Es})],rp.prototype,"certificate",void 0);gi([yi({type:nl,context:2,implicit:true})],rp.prototype,"v2AttrCert",void 0);gi([yi({type:ip,context:3,implicit:true})],rp.prototype,"other",void 0);rp=gi([fi({type:Me.Choice})],rp);let sp=ep=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ep.prototype)}};sp=ep=gi([fi({type:Me.Set,itemType:rp})],sp);class np{constructor(t={}){this.contentType="";this.content=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],np.prototype,"contentType",void 0);gi([yi({type:Ne.Any,context:0})],np.prototype,"content",void 0);let op=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ke})],op.prototype,"single",void 0);gi([yi({type:Ne.Any})],op.prototype,"any",void 0);op=gi([fi({type:Me.Choice})],op);class ap{constructor(t={}){this.eContentType="";Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],ap.prototype,"eContentType",void 0);gi([yi({type:op,context:0,optional:true})],ap.prototype,"eContent",void 0);let cp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ke,context:0,implicit:true,optional:true})],cp.prototype,"value",void 0);gi([yi({type:Ke,converter:Ge,context:0,implicit:true,optional:true,repeated:"sequence"})],cp.prototype,"constructedValue",void 0);cp=gi([fi({type:Me.Choice})],cp);class up{constructor(t={}){this.contentType="";this.contentEncryptionAlgorithm=new Wl;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],up.prototype,"contentType",void 0);gi([yi({type:Wl})],up.prototype,"contentEncryptionAlgorithm",void 0);gi([yi({type:cp,optional:true})],up.prototype,"encryptedContent",void 0);class lp{constructor(t={}){this.keyAttrId="";Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],lp.prototype,"keyAttrId",void 0);gi([yi({type:Ne.Any,optional:true})],lp.prototype,"keyAttr",void 0);var pp;class hp{constructor(t={}){this.subjectKeyIdentifier=new ss;Object.assign(this,t)}}gi([yi({type:ss})],hp.prototype,"subjectKeyIdentifier",void 0);gi([yi({type:Ne.GeneralizedTime,optional:true})],hp.prototype,"date",void 0);gi([yi({type:lp,optional:true})],hp.prototype,"other",void 0);let dp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:hp,context:0,implicit:true,optional:true})],dp.prototype,"rKeyId",void 0);gi([yi({type:_l,optional:true})],dp.prototype,"issuerAndSerialNumber",void 0);dp=gi([fi({type:Me.Choice})],dp);class fp{constructor(t={}){this.rid=new dp;this.encryptedKey=new Ke;Object.assign(this,t)}}gi([yi({type:dp})],fp.prototype,"rid",void 0);gi([yi({type:Ke})],fp.prototype,"encryptedKey",void 0);let yp=pp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,pp.prototype)}};yp=pp=gi([fi({type:Me.Sequence,itemType:fp})],yp);class Sp{constructor(t={}){this.algorithm=new fs;this.publicKey=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:fs})],Sp.prototype,"algorithm",void 0);gi([yi({type:Ne.BitString})],Sp.prototype,"publicKey",void 0);let Ap=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ss,context:0,implicit:true,optional:true})],Ap.prototype,"subjectKeyIdentifier",void 0);gi([yi({type:Sp,context:1,implicit:true,optional:true})],Ap.prototype,"originatorKey",void 0);gi([yi({type:_l,optional:true})],Ap.prototype,"issuerAndSerialNumber",void 0);Ap=gi([fi({type:Me.Choice})],Ap);class Cp{constructor(t={}){this.version=Vl.v3;this.originator=new Ap;this.keyEncryptionAlgorithm=new Gl;this.recipientEncryptedKeys=new yp;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Cp.prototype,"version",void 0);gi([yi({type:Ap,context:0})],Cp.prototype,"originator",void 0);gi([yi({type:Ke,context:1,optional:true})],Cp.prototype,"ukm",void 0);gi([yi({type:Gl})],Cp.prototype,"keyEncryptionAlgorithm",void 0);gi([yi({type:yp})],Cp.prototype,"recipientEncryptedKeys",void 0);let vp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ss,context:0,implicit:true})],vp.prototype,"subjectKeyIdentifier",void 0);gi([yi({type:_l})],vp.prototype,"issuerAndSerialNumber",void 0);vp=gi([fi({type:Me.Choice})],vp);class mp{constructor(t={}){this.version=Vl.v0;this.rid=new vp;this.keyEncryptionAlgorithm=new Gl;this.encryptedKey=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],mp.prototype,"version",void 0);gi([yi({type:vp})],mp.prototype,"rid",void 0);gi([yi({type:Gl})],mp.prototype,"keyEncryptionAlgorithm",void 0);gi([yi({type:Ke})],mp.prototype,"encryptedKey",void 0);class gp{constructor(t={}){this.keyIdentifier=new Ke;Object.assign(this,t)}}gi([yi({type:Ke})],gp.prototype,"keyIdentifier",void 0);gi([yi({type:Ne.GeneralizedTime,optional:true})],gp.prototype,"date",void 0);gi([yi({type:lp,optional:true})],gp.prototype,"other",void 0);class wp{constructor(t={}){this.version=Vl.v4;this.kekid=new gp;this.keyEncryptionAlgorithm=new Gl;this.encryptedKey=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],wp.prototype,"version",void 0);gi([yi({type:gp})],wp.prototype,"kekid",void 0);gi([yi({type:Gl})],wp.prototype,"keyEncryptionAlgorithm",void 0);gi([yi({type:Ke})],wp.prototype,"encryptedKey",void 0);class Ep{constructor(t={}){this.version=Vl.v0;this.keyEncryptionAlgorithm=new Gl;this.encryptedKey=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Ep.prototype,"version",void 0);gi([yi({type:ql,context:0,optional:true})],Ep.prototype,"keyDerivationAlgorithm",void 0);gi([yi({type:Gl})],Ep.prototype,"keyEncryptionAlgorithm",void 0);gi([yi({type:Ke})],Ep.prototype,"encryptedKey",void 0);class Pp{constructor(t={}){this.oriType="";this.oriValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Pp.prototype,"oriType",void 0);gi([yi({type:Ne.Any})],Pp.prototype,"oriValue",void 0);let Dp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:mp,optional:true})],Dp.prototype,"ktri",void 0);gi([yi({type:Cp,context:1,implicit:true,optional:true})],Dp.prototype,"kari",void 0);gi([yi({type:wp,context:2,implicit:true,optional:true})],Dp.prototype,"kekri",void 0);gi([yi({type:Ep,context:3,implicit:true,optional:true})],Dp.prototype,"pwri",void 0);gi([yi({type:Pp,context:4,implicit:true,optional:true})],Dp.prototype,"ori",void 0);Dp=gi([fi({type:Me.Choice})],Dp);var bp;let Bp=bp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,bp.prototype)}};Bp=bp=gi([fi({type:Me.Set,itemType:Dp})],Bp);var Ip;class xp{constructor(t={}){this.otherRevInfoFormat="";this.otherRevInfo=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],xp.prototype,"otherRevInfoFormat",void 0);gi([yi({type:Ne.Any})],xp.prototype,"otherRevInfo",void 0);let Tp=class t{constructor(t={}){this.other=new xp;Object.assign(this,t)}};gi([yi({type:xp,context:1,implicit:true})],Tp.prototype,"other",void 0);Tp=gi([fi({type:Me.Choice})],Tp);let Op=Ip=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Ip.prototype)}};Op=Ip=gi([fi({type:Me.Set,itemType:Tp})],Op);class Rp{constructor(t={}){Object.assign(this,t)}}gi([yi({type:sp,context:0,implicit:true,optional:true})],Rp.prototype,"certs",void 0);gi([yi({type:Op,context:1,implicit:true,optional:true})],Rp.prototype,"crls",void 0);var Mp;let Np=Mp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Mp.prototype)}};Np=Mp=gi([fi({type:Me.Set,itemType:zl})],Np);class kp{constructor(t={}){this.version=Vl.v0;this.recipientInfos=new Bp;this.encryptedContentInfo=new up;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],kp.prototype,"version",void 0);gi([yi({type:Rp,context:0,implicit:true,optional:true})],kp.prototype,"originatorInfo",void 0);gi([yi({type:Bp})],kp.prototype,"recipientInfos",void 0);gi([yi({type:up})],kp.prototype,"encryptedContentInfo",void 0);gi([yi({type:Np,context:1,implicit:true,optional:true})],kp.prototype,"unprotectedAttrs",void 0);var Kp;let Hp=Kp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Kp.prototype)}};Hp=Kp=gi([fi({type:Me.Set,itemType:Ll})],Hp);class jp{constructor(t={}){this.version=Vl.v0;this.digestAlgorithms=new Hp;this.encapContentInfo=new ap;this.signerInfos=new Xl;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],jp.prototype,"version",void 0);gi([yi({type:Hp})],jp.prototype,"digestAlgorithms",void 0);gi([yi({type:ap})],jp.prototype,"encapContentInfo",void 0);gi([yi({type:sp,context:0,implicit:true,optional:true})],jp.prototype,"certificates",void 0);gi([yi({type:Op,context:1,implicit:true,optional:true})],jp.prototype,"crls",void 0);gi([yi({type:Xl})],jp.prototype,"signerInfos",void 0);var Up;class _p{constructor(t={}){this.attrId="";this.attrValues=[];Object.assign(t)}}gi([yi({type:Ne.ObjectIdentifier})],_p.prototype,"attrId",void 0);gi([yi({type:Ne.Any,repeated:"set"})],_p.prototype,"attrValues",void 0);let Fp=Up=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Up.prototype)}};Fp=Up=gi([fi({type:Me.Sequence,itemType:_p})],Fp);var Vp;let Lp=Vp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Vp.prototype)}};Lp=Vp=gi([fi({type:Me.Sequence,itemType:np})],Lp);class $p{constructor(t={}){this.certId="";this.certValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],$p.prototype,"certId",void 0);gi([yi({type:Ne.Any,context:0})],$p.prototype,"certValue",void 0);class Gp{constructor(t={}){this.crlId="";this.crltValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Gp.prototype,"crlId",void 0);gi([yi({type:Ne.Any,context:0})],Gp.prototype,"crltValue",void 0);let Wp=class t extends Nn{};Wp=gi([fi({type:Me.Sequence})],Wp);let Qp=class t extends xn{};Qp=gi([fi({type:Me.Sequence})],Qp);class qp{constructor(t={}){this.secretTypeId="";this.secretValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],qp.prototype,"secretTypeId",void 0);gi([yi({type:Ne.Any,context:0})],qp.prototype,"secretValue",void 0);class zp{constructor(t={}){this.mac=new An;this.macSalt=new Ke;this.iterations=1;Object.assign(this,t)}}gi([yi({type:An})],zp.prototype,"mac",void 0);gi([yi({type:Ke})],zp.prototype,"macSalt",void 0);gi([yi({type:Ne.Integer,defaultValue:1})],zp.prototype,"iterations",void 0);class Jp{constructor(t={}){this.version=3;this.authSafe=new np;this.macData=new zp;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Jp.prototype,"version",void 0);gi([yi({type:np})],Jp.prototype,"authSafe",void 0);gi([yi({type:zp,optional:true})],Jp.prototype,"macData",void 0);var Zp;class Xp{constructor(t={}){this.bagId="";this.bagValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Xp.prototype,"bagId",void 0);gi([yi({type:Ne.Any,context:0})],Xp.prototype,"bagValue",void 0);gi([yi({type:_p,repeated:"set",optional:true})],Xp.prototype,"bagAttributes",void 0);let Yp=Zp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Zp.prototype)}};Yp=Zp=gi([fi({type:Me.Sequence,itemType:Xp})],Yp);var th,eh,ih;const rh="1.2.840.113549.1.9";const sh=`${rh}.2`;const nh=`${rh}.7`;const oh=`${rh}.14`;let ah=class t extends bi{constructor(t={}){super(t)}toString(){return this.ia5String||super.toString()}};gi([yi({type:Ne.IA5String})],ah.prototype,"ia5String",void 0);ah=gi([fi({type:Me.Choice})],ah);let ch=class t extends np{};ch=gi([fi({type:Me.Sequence})],ch);let uh=class t extends Jp{};uh=gi([fi({type:Me.Sequence})],uh);let lh=class t extends xn{};lh=gi([fi({type:Me.Sequence})],lh);let ph=class t{constructor(t=""){this.value=t}toString(){return this.value}};gi([yi({type:Ne.IA5String})],ph.prototype,"value",void 0);ph=gi([fi({type:Me.Choice})],ph);let hh=class t extends ah{};hh=gi([fi({type:Me.Choice})],hh);let dh=class t extends bi{};dh=gi([fi({type:Me.Choice})],dh);let fh=class t{constructor(t=new Date){this.value=t}};gi([yi({type:Ne.GeneralizedTime})],fh.prototype,"value",void 0);fh=gi([fi({type:Me.Choice})],fh);let yh=class t extends bi{};yh=gi([fi({type:Me.Choice})],yh);let Sh=class t{constructor(t="M"){this.value=t}toString(){return this.value}};gi([yi({type:Ne.PrintableString})],Sh.prototype,"value",void 0);Sh=gi([fi({type:Me.Choice})],Sh);let Ah=class t{constructor(t=""){this.value=t}toString(){return this.value}};gi([yi({type:Ne.PrintableString})],Ah.prototype,"value",void 0);Ah=gi([fi({type:Me.Choice})],Ah);let Ch=class t extends Ah{};Ch=gi([fi({type:Me.Choice})],Ch);let vh=class t extends bi{};vh=gi([fi({type:Me.Choice})],vh);let mh=class t{constructor(t=""){this.value=t}toString(){return this.value}};gi([yi({type:Ne.ObjectIdentifier})],mh.prototype,"value",void 0);mh=gi([fi({type:Me.Choice})],mh);let gh=class t extends Ss{};gh=gi([fi({type:Me.Choice})],gh);let wh=class t{constructor(t=0){this.value=t}toString(){return this.value.toString()}};gi([yi({type:Ne.Integer})],wh.prototype,"value",void 0);wh=gi([fi({type:Me.Choice})],wh);let Eh=class t extends Zl{};Eh=gi([fi({type:Me.Sequence})],Eh);let Ph=class t extends bi{};Ph=gi([fi({type:Me.Choice})],Ph);let Dh=th=class t extends ms{constructor(t){super(t);Object.setPrototypeOf(this,th.prototype)}};Dh=th=gi([fi({type:Me.Sequence})],Dh);let bh=eh=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,eh.prototype)}};bh=eh=gi([fi({type:Me.Set,itemType:zl})],bh);let Bh=class t{constructor(t=""){this.value=t}toString(){return this.value}};gi([yi({type:Ne.BmpString})],Bh.prototype,"value",void 0);Bh=gi([fi({type:Me.Choice})],Bh);let Ih=class t extends fs{};Ih=gi([fi({type:Me.Sequence})],Ih);let xh=ih=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ih.prototype)}};xh=ih=gi([fi({type:Me.Sequence,itemType:Ih})],xh);var Th;let Oh=Th=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Th.prototype)}};Oh=Th=gi([fi({type:Me.Sequence,itemType:Yr})],Oh);class Rh{constructor(t={}){this.version=0;this.subject=new Oi;this.subjectPKInfo=new ys;this.attributes=new Oh;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Rh.prototype,"version",void 0);gi([yi({type:Oi})],Rh.prototype,"subject",void 0);gi([yi({type:ys})],Rh.prototype,"subjectPKInfo",void 0);gi([yi({type:Oh,implicit:true,context:0})],Rh.prototype,"attributes",void 0);class Mh{constructor(t={}){this.certificationRequestInfo=new Rh;this.signatureAlgorithm=new fs;this.signature=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Rh})],Mh.prototype,"certificationRequestInfo",void 0);gi([yi({type:fs})],Mh.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ne.BitString})],Mh.prototype,"signature",void 0);export{jp as $,Bu as A,sh as B,Es as C,o as D,xu as E,nh as F,Nl as G,Rl as H,Ml as I,jl as J,gl as K,Kl as L,Tl as M,ca as N,Il as O,Fu as P,bl as Q,wn as R,Pl as S,Hl as T,hh as U,kl as V,Ul as W,Mh as X,ia as Y,no as Z,sa as _,oo as a,op as a0,Ke as a1,sp as a2,rp as a3,np as a4,Oi as a5,Dr as a6,Rr as a7,Xi as a8,Mi as a9,Lr as aA,xa as aB,Ra as aC,Na as aD,Ea as aE,ac as aF,nc as aG,yc as aH,dc as aI,Ic as aJ,bc as aK,is as aL,os as aM,ls as aN,fa as aO,Vc as aP,iu as aQ,Gr as aR,zr as aS,ur as aT,wr as aU,Su as aV,wu as aW,er as aa,rr as ab,Ni as ac,gi as ad,yi as ae,Ne as af,fi as ag,Me as ah,vi as ai,ma as aj,wa as ak,_e as al,vu as am,ou as an,au as ao,jr as ap,Qi as aq,Ir as ar,ss as as,Gi as at,Cr as au,Vi as av,ds as aw,Xr as ax,ar as ay,Ec as az,n as b,$u as c,t as d,mi as e,Us as f,Ls as g,Ln as h,Bs as i,Gn as j,Dn as k,Bn as l,bn as m,Gu as n,nl as o,bs as p,Yr as q,Ai as r,Dh as s,Ph as t,wl as u,Ol as v,xl as w,Bl as x,Dl as y,oh as z};
|
|
142
|
-
//# sourceMappingURL=p-
|
|
141
|
+
*/const $u=t=>{if(_u.isPem(t)){return _u.decode(t)[0]}if(n.Convert.isHex(t)){return n.Convert.FromHex(t)}if(n.Convert.isBase64(t)){return n.Convert.FromBase64(t)}if(n.Convert.isBase64Url(t)){return n.Convert.FromBase64Url(t)}return n.Convert.FromBinary(t)};const Gu=async(t,e)=>{const i=Lu.get();if(i.subtle){return i.subtle.digest(t,e)}return undefined};class Wu{constructor(t={}){this.acIssuer=new ki;this.acSerial=0;this.attrs=[];Object.assign(this,t)}}gi([yi({type:ki})],Wu.prototype,"acIssuer",void 0);gi([yi({type:Ne.Integer})],Wu.prototype,"acSerial",void 0);gi([yi({type:Yr,repeated:"sequence"})],Wu.prototype,"attrs",void 0);var Qu;let qu=Qu=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Qu.prototype)}};qu=Qu=gi([fi({type:Me.Sequence,itemType:Ne.ObjectIdentifier})],qu);class zu{constructor(t={}){this.permitUnSpecified=true;Object.assign(this,t)}}gi([yi({type:Ne.Integer,optional:true})],zu.prototype,"pathLenConstraint",void 0);gi([yi({type:qu,implicit:true,context:0,optional:true})],zu.prototype,"permittedAttrs",void 0);gi([yi({type:qu,implicit:true,context:1,optional:true})],zu.prototype,"excludedAttrs",void 0);gi([yi({type:Ne.Boolean,defaultValue:true})],zu.prototype,"permitUnSpecified",void 0);class Ju{constructor(t={}){this.issuer=new zi;this.serial=new ArrayBuffer(0);this.issuerUID=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:zi})],Ju.prototype,"issuer",void 0);gi([yi({type:Ne.Integer,converter:Fe})],Ju.prototype,"serial",void 0);gi([yi({type:Ne.BitString,optional:true})],Ju.prototype,"issuerUID",void 0);var Zu;(function(t){t[t["publicKey"]=0]="publicKey";t[t["publicKeyCert"]=1]="publicKeyCert";t[t["otherObjectTypes"]=2]="otherObjectTypes"})(Zu||(Zu={}));class Xu{constructor(t={}){this.digestedObjectType=Zu.publicKey;this.digestAlgorithm=new fs;this.objectDigest=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.Enumerated})],Xu.prototype,"digestedObjectType",void 0);gi([yi({type:Ne.ObjectIdentifier,optional:true})],Xu.prototype,"otherObjectTypeID",void 0);gi([yi({type:fs})],Xu.prototype,"digestAlgorithm",void 0);gi([yi({type:Ne.BitString})],Xu.prototype,"objectDigest",void 0);class Yu{constructor(t={}){Object.assign(this,t)}}gi([yi({type:zi,optional:true})],Yu.prototype,"issuerName",void 0);gi([yi({type:Ju,context:0,implicit:true,optional:true})],Yu.prototype,"baseCertificateID",void 0);gi([yi({type:Xu,context:1,implicit:true,optional:true})],Yu.prototype,"objectDigestInfo",void 0);let tl=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ki,repeated:"sequence"})],tl.prototype,"v1Form",void 0);gi([yi({type:Yu,context:0,implicit:true})],tl.prototype,"v2Form",void 0);tl=gi([fi({type:Me.Choice})],tl);class el{constructor(t={}){this.notBeforeTime=new Date;this.notAfterTime=new Date;Object.assign(this,t)}}gi([yi({type:Ne.GeneralizedTime})],el.prototype,"notBeforeTime",void 0);gi([yi({type:Ne.GeneralizedTime})],el.prototype,"notAfterTime",void 0);class il{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ju,implicit:true,context:0,optional:true})],il.prototype,"baseCertificateID",void 0);gi([yi({type:zi,implicit:true,context:1,optional:true})],il.prototype,"entityName",void 0);gi([yi({type:Xu,implicit:true,context:2,optional:true})],il.prototype,"objectDigestInfo",void 0);var rl;(function(t){t[t["v2"]=1]="v2"})(rl||(rl={}));class sl{constructor(t={}){this.version=rl.v2;this.holder=new il;this.issuer=new tl;this.signature=new fs;this.serialNumber=new ArrayBuffer(0);this.attrCertValidityPeriod=new el;this.attributes=[];Object.assign(this,t)}}gi([yi({type:Ne.Integer})],sl.prototype,"version",void 0);gi([yi({type:il})],sl.prototype,"holder",void 0);gi([yi({type:tl})],sl.prototype,"issuer",void 0);gi([yi({type:fs})],sl.prototype,"signature",void 0);gi([yi({type:Ne.Integer,converter:Fe})],sl.prototype,"serialNumber",void 0);gi([yi({type:el})],sl.prototype,"attrCertValidityPeriod",void 0);gi([yi({type:Yr,repeated:"sequence"})],sl.prototype,"attributes",void 0);gi([yi({type:Ne.BitString,optional:true})],sl.prototype,"issuerUniqueID",void 0);gi([yi({type:ms,optional:true})],sl.prototype,"extensions",void 0);class nl{constructor(t={}){this.acinfo=new sl;this.signatureAlgorithm=new fs;this.signatureValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:sl})],nl.prototype,"acinfo",void 0);gi([yi({type:fs})],nl.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ne.BitString})],nl.prototype,"signatureValue",void 0);var ol;(function(t){t[t["unmarked"]=1]="unmarked";t[t["unclassified"]=2]="unclassified";t[t["restricted"]=4]="restricted";t[t["confidential"]=8]="confidential";t[t["secret"]=16]="secret";t[t["topSecret"]=32]="topSecret"})(ol||(ol={}));class al extends ke{}class cl{constructor(t={}){this.type="";this.value=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier,implicit:true,context:0})],cl.prototype,"type",void 0);gi([yi({type:Ne.Any,implicit:true,context:1})],cl.prototype,"value",void 0);class ul{constructor(t={}){this.policyId="";this.classList=new al(ol.unclassified);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],ul.prototype,"policyId",void 0);gi([yi({type:al,defaultValue:new al(ol.unclassified)})],ul.prototype,"classList",void 0);gi([yi({type:cl,repeated:"set"})],ul.prototype,"securityCategories",void 0);class ll{constructor(t={}){Object.assign(this,t)}}gi([yi({type:Ke})],ll.prototype,"cotets",void 0);gi([yi({type:Ne.ObjectIdentifier})],ll.prototype,"oid",void 0);gi([yi({type:Ne.Utf8String})],ll.prototype,"string",void 0);class pl{constructor(t={}){this.values=[];Object.assign(this,t)}}gi([yi({type:zi,implicit:true,context:0,optional:true})],pl.prototype,"policyAuthority",void 0);gi([yi({type:ll,repeated:"sequence"})],pl.prototype,"values",void 0);var hl;class dl{constructor(t={}){this.targetCertificate=new Ju;Object.assign(this,t)}}gi([yi({type:Ju})],dl.prototype,"targetCertificate",void 0);gi([yi({type:ki,optional:true})],dl.prototype,"targetName",void 0);gi([yi({type:Xu,optional:true})],dl.prototype,"certDigestInfo",void 0);let fl=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ki,context:0,implicit:true})],fl.prototype,"targetName",void 0);gi([yi({type:ki,context:1,implicit:true})],fl.prototype,"targetGroup",void 0);gi([yi({type:dl,context:2,implicit:true})],fl.prototype,"targetCert",void 0);fl=gi([fi({type:Me.Choice})],fl);let yl=hl=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,hl.prototype)}};yl=hl=gi([fi({type:Me.Sequence,itemType:fl})],yl);var Sl;let Al=Sl=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Sl.prototype)}};Al=Sl=gi([fi({type:Me.Sequence,itemType:yl})],Al);class Cl{constructor(t={}){Object.assign(this,t)}}gi([yi({type:zi,implicit:true,context:0,optional:true})],Cl.prototype,"roleAuthority",void 0);gi([yi({type:ki,implicit:true,context:1})],Cl.prototype,"roleName",void 0);class vl{constructor(t={}){this.service=new ki;this.ident=new ki;Object.assign(this,t)}}gi([yi({type:ki})],vl.prototype,"service",void 0);gi([yi({type:ki})],vl.prototype,"ident",void 0);gi([yi({type:Ke,optional:true})],vl.prototype,"authInfo",void 0);const ml="0.4.0.9496";const gl=`${ml}.6`;let wl=class t{constructor(t={}){this.codeAuthority=new ki;this.codeId=new ki;this.shortName="";this.shortDescription="";Object.assign(this,t)}};gi([yi({type:ki,context:0})],wl.prototype,"codeAuthority",void 0);gi([yi({type:ki,context:1})],wl.prototype,"codeId",void 0);gi([yi({type:Ne.Utf8String,context:2})],wl.prototype,"shortName",void 0);gi([yi({type:Ne.Utf8String,context:3})],wl.prototype,"shortDescription",void 0);wl=gi([fi({type:Me.Sequence})],wl);let El=class t extends Oi{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};El=gi([fi({type:Me.Sequence})],El);const Pl=`${ml}.1`;let Dl=class t extends El{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};Dl=gi([fi({type:Me.Sequence})],Dl);const bl=`${ml}.2`;let Bl=class t extends El{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};Bl=gi([fi({type:Me.Sequence})],Bl);const Il=`${ml}.3`;let xl=class t extends El{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};xl=gi([fi({type:Me.Sequence})],xl);const Tl=`${ml}.4`;let Ol=class t extends El{constructor(t){super(t);Object.setPrototypeOf(this,Oi.prototype)}};Ol=gi([fi({type:Me.Sequence})],Ol);const Rl=`${ml}.8`;let Ml=class t{constructor(t={}){this.location="";this.base=0;this.degree=0;Object.assign(this,t)}toString(){return`${this.base} x 10^${this.degree} ${this.location}`}};gi([yi({type:Ne.PrintableString})],Ml.prototype,"location",void 0);gi([yi({type:Ne.Integer})],Ml.prototype,"base",void 0);gi([yi({type:Ne.Integer})],Ml.prototype,"degree",void 0);Ml=gi([fi({type:Me.Sequence})],Ml);const Nl=`${ml}.9`;let kl=class t{constructor(t={}){this.stars5=0;this.stars4=0;this.stars3=0;this.stars2=0;this.stars1=0;Object.assign(this,t)}};gi([yi({type:Ne.Integer})],kl.prototype,"stars5",void 0);gi([yi({type:Ne.Integer})],kl.prototype,"stars4",void 0);gi([yi({type:Ne.Integer})],kl.prototype,"stars3",void 0);gi([yi({type:Ne.Integer})],kl.prototype,"stars2",void 0);gi([yi({type:Ne.Integer})],kl.prototype,"stars1",void 0);kl=gi([fi({type:Me.Sequence})],kl);const Kl=`${ml}.5`;let Hl=class t{constructor(t={}){this.DNBvsDNO=new ke(0);this.DNBvsDNT=new ke(0);this.DNOvsDNT=new ke(0);Object.assign(this,t)}};gi([yi({type:ke,context:0})],Hl.prototype,"DNBvsDNO",void 0);gi([yi({type:ke,context:1})],Hl.prototype,"DNBvsDNT",void 0);gi([yi({type:ke,context:2})],Hl.prototype,"DNOvsDNT",void 0);Hl=gi([fi({type:Me.Sequence})],Hl);const jl=`${ml}.7`;let Ul=class t{constructor(t={}){this.assessmentAuthority=new ki;this.assessmentRef=new ki;this.assessmentLocation=new ki;this.dataStorageTerritory="";this.description="";Object.assign(this,t)}};gi([yi({type:ki,context:0})],Ul.prototype,"assessmentAuthority",void 0);gi([yi({type:ki,context:1})],Ul.prototype,"assessmentRef",void 0);gi([yi({type:ki,context:2})],Ul.prototype,"assessmentLocation",void 0);gi([yi({type:Ne.PrintableString,context:3})],Ul.prototype,"dataStorageTerritory",void 0);gi([yi({type:Ne.Utf8String,context:4})],Ul.prototype,"description",void 0);Ul=gi([fi({type:Me.Sequence})],Ul);class Fl{constructor(t={}){this.issuer=new Oi;this.serialNumber=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Oi})],Fl.prototype,"issuer",void 0);gi([yi({type:Ne.Integer,converter:Fe})],Fl.prototype,"serialNumber",void 0);let _l=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ss,context:0,implicit:true})],_l.prototype,"subjectKeyIdentifier",void 0);gi([yi({type:Fl})],_l.prototype,"issuerAndSerialNumber",void 0);_l=gi([fi({type:Me.Choice})],_l);var Vl;(function(t){t[t["v0"]=0]="v0";t[t["v1"]=1]="v1";t[t["v2"]=2]="v2";t[t["v3"]=3]="v3";t[t["v4"]=4]="v4";t[t["v5"]=5]="v5"})(Vl||(Vl={}));let Ll=class t extends fs{};Ll=gi([fi({type:Me.Sequence})],Ll);let $l=class t extends fs{};$l=gi([fi({type:Me.Sequence})],$l);let Gl=class t extends fs{};Gl=gi([fi({type:Me.Sequence})],Gl);let Wl=class t extends fs{};Wl=gi([fi({type:Me.Sequence})],Wl);let Ql=class t extends fs{};Ql=gi([fi({type:Me.Sequence})],Ql);let ql=class t extends fs{};ql=gi([fi({type:Me.Sequence})],ql);class zl{constructor(t={}){this.attrType="";this.attrValues=[];Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],zl.prototype,"attrType",void 0);gi([yi({type:Ne.Any,repeated:"set"})],zl.prototype,"attrValues",void 0);var Jl;class Zl{constructor(t={}){this.version=Vl.v0;this.sid=new _l;this.digestAlgorithm=new Ll;this.signatureAlgorithm=new $l;this.signature=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Zl.prototype,"version",void 0);gi([yi({type:_l})],Zl.prototype,"sid",void 0);gi([yi({type:Ll})],Zl.prototype,"digestAlgorithm",void 0);gi([yi({type:zl,repeated:"set",context:0,implicit:true,optional:true})],Zl.prototype,"signedAttrs",void 0);gi([yi({type:$l})],Zl.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ke})],Zl.prototype,"signature",void 0);gi([yi({type:zl,repeated:"set",context:1,implicit:true,optional:true})],Zl.prototype,"unsignedAttrs",void 0);let Xl=Jl=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Jl.prototype)}};Xl=Jl=gi([fi({type:Me.Set,itemType:Zl})],Xl);let Yl=class t extends Ss{};Yl=gi([fi({type:Me.Choice})],Yl);let tp=class t extends Zl{};tp=gi([fi({type:Me.Sequence})],tp);var ep;class ip{constructor(t={}){this.otherCertFormat="";this.otherCert=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],ip.prototype,"otherCertFormat",void 0);gi([yi({type:Ne.Any})],ip.prototype,"otherCert",void 0);let rp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Es})],rp.prototype,"certificate",void 0);gi([yi({type:nl,context:2,implicit:true})],rp.prototype,"v2AttrCert",void 0);gi([yi({type:ip,context:3,implicit:true})],rp.prototype,"other",void 0);rp=gi([fi({type:Me.Choice})],rp);let sp=ep=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ep.prototype)}};sp=ep=gi([fi({type:Me.Set,itemType:rp})],sp);class np{constructor(t={}){this.contentType="";this.content=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],np.prototype,"contentType",void 0);gi([yi({type:Ne.Any,context:0})],np.prototype,"content",void 0);let op=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ke})],op.prototype,"single",void 0);gi([yi({type:Ne.Any})],op.prototype,"any",void 0);op=gi([fi({type:Me.Choice})],op);class ap{constructor(t={}){this.eContentType="";Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],ap.prototype,"eContentType",void 0);gi([yi({type:op,context:0,optional:true})],ap.prototype,"eContent",void 0);let cp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:Ke,context:0,implicit:true,optional:true})],cp.prototype,"value",void 0);gi([yi({type:Ke,converter:Ge,context:0,implicit:true,optional:true,repeated:"sequence"})],cp.prototype,"constructedValue",void 0);cp=gi([fi({type:Me.Choice})],cp);class up{constructor(t={}){this.contentType="";this.contentEncryptionAlgorithm=new Wl;Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],up.prototype,"contentType",void 0);gi([yi({type:Wl})],up.prototype,"contentEncryptionAlgorithm",void 0);gi([yi({type:cp,optional:true})],up.prototype,"encryptedContent",void 0);class lp{constructor(t={}){this.keyAttrId="";Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],lp.prototype,"keyAttrId",void 0);gi([yi({type:Ne.Any,optional:true})],lp.prototype,"keyAttr",void 0);var pp;class hp{constructor(t={}){this.subjectKeyIdentifier=new ss;Object.assign(this,t)}}gi([yi({type:ss})],hp.prototype,"subjectKeyIdentifier",void 0);gi([yi({type:Ne.GeneralizedTime,optional:true})],hp.prototype,"date",void 0);gi([yi({type:lp,optional:true})],hp.prototype,"other",void 0);let dp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:hp,context:0,implicit:true,optional:true})],dp.prototype,"rKeyId",void 0);gi([yi({type:Fl,optional:true})],dp.prototype,"issuerAndSerialNumber",void 0);dp=gi([fi({type:Me.Choice})],dp);class fp{constructor(t={}){this.rid=new dp;this.encryptedKey=new Ke;Object.assign(this,t)}}gi([yi({type:dp})],fp.prototype,"rid",void 0);gi([yi({type:Ke})],fp.prototype,"encryptedKey",void 0);let yp=pp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,pp.prototype)}};yp=pp=gi([fi({type:Me.Sequence,itemType:fp})],yp);class Sp{constructor(t={}){this.algorithm=new fs;this.publicKey=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:fs})],Sp.prototype,"algorithm",void 0);gi([yi({type:Ne.BitString})],Sp.prototype,"publicKey",void 0);let Ap=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ss,context:0,implicit:true,optional:true})],Ap.prototype,"subjectKeyIdentifier",void 0);gi([yi({type:Sp,context:1,implicit:true,optional:true})],Ap.prototype,"originatorKey",void 0);gi([yi({type:Fl,optional:true})],Ap.prototype,"issuerAndSerialNumber",void 0);Ap=gi([fi({type:Me.Choice})],Ap);class Cp{constructor(t={}){this.version=Vl.v3;this.originator=new Ap;this.keyEncryptionAlgorithm=new Gl;this.recipientEncryptedKeys=new yp;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Cp.prototype,"version",void 0);gi([yi({type:Ap,context:0})],Cp.prototype,"originator",void 0);gi([yi({type:Ke,context:1,optional:true})],Cp.prototype,"ukm",void 0);gi([yi({type:Gl})],Cp.prototype,"keyEncryptionAlgorithm",void 0);gi([yi({type:yp})],Cp.prototype,"recipientEncryptedKeys",void 0);let vp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:ss,context:0,implicit:true})],vp.prototype,"subjectKeyIdentifier",void 0);gi([yi({type:Fl})],vp.prototype,"issuerAndSerialNumber",void 0);vp=gi([fi({type:Me.Choice})],vp);class mp{constructor(t={}){this.version=Vl.v0;this.rid=new vp;this.keyEncryptionAlgorithm=new Gl;this.encryptedKey=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],mp.prototype,"version",void 0);gi([yi({type:vp})],mp.prototype,"rid",void 0);gi([yi({type:Gl})],mp.prototype,"keyEncryptionAlgorithm",void 0);gi([yi({type:Ke})],mp.prototype,"encryptedKey",void 0);class gp{constructor(t={}){this.keyIdentifier=new Ke;Object.assign(this,t)}}gi([yi({type:Ke})],gp.prototype,"keyIdentifier",void 0);gi([yi({type:Ne.GeneralizedTime,optional:true})],gp.prototype,"date",void 0);gi([yi({type:lp,optional:true})],gp.prototype,"other",void 0);class wp{constructor(t={}){this.version=Vl.v4;this.kekid=new gp;this.keyEncryptionAlgorithm=new Gl;this.encryptedKey=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],wp.prototype,"version",void 0);gi([yi({type:gp})],wp.prototype,"kekid",void 0);gi([yi({type:Gl})],wp.prototype,"keyEncryptionAlgorithm",void 0);gi([yi({type:Ke})],wp.prototype,"encryptedKey",void 0);class Ep{constructor(t={}){this.version=Vl.v0;this.keyEncryptionAlgorithm=new Gl;this.encryptedKey=new Ke;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Ep.prototype,"version",void 0);gi([yi({type:ql,context:0,optional:true})],Ep.prototype,"keyDerivationAlgorithm",void 0);gi([yi({type:Gl})],Ep.prototype,"keyEncryptionAlgorithm",void 0);gi([yi({type:Ke})],Ep.prototype,"encryptedKey",void 0);class Pp{constructor(t={}){this.oriType="";this.oriValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Pp.prototype,"oriType",void 0);gi([yi({type:Ne.Any})],Pp.prototype,"oriValue",void 0);let Dp=class t{constructor(t={}){Object.assign(this,t)}};gi([yi({type:mp,optional:true})],Dp.prototype,"ktri",void 0);gi([yi({type:Cp,context:1,implicit:true,optional:true})],Dp.prototype,"kari",void 0);gi([yi({type:wp,context:2,implicit:true,optional:true})],Dp.prototype,"kekri",void 0);gi([yi({type:Ep,context:3,implicit:true,optional:true})],Dp.prototype,"pwri",void 0);gi([yi({type:Pp,context:4,implicit:true,optional:true})],Dp.prototype,"ori",void 0);Dp=gi([fi({type:Me.Choice})],Dp);var bp;let Bp=bp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,bp.prototype)}};Bp=bp=gi([fi({type:Me.Set,itemType:Dp})],Bp);var Ip;class xp{constructor(t={}){this.otherRevInfoFormat="";this.otherRevInfo=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],xp.prototype,"otherRevInfoFormat",void 0);gi([yi({type:Ne.Any})],xp.prototype,"otherRevInfo",void 0);let Tp=class t{constructor(t={}){this.other=new xp;Object.assign(this,t)}};gi([yi({type:xp,context:1,implicit:true})],Tp.prototype,"other",void 0);Tp=gi([fi({type:Me.Choice})],Tp);let Op=Ip=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Ip.prototype)}};Op=Ip=gi([fi({type:Me.Set,itemType:Tp})],Op);class Rp{constructor(t={}){Object.assign(this,t)}}gi([yi({type:sp,context:0,implicit:true,optional:true})],Rp.prototype,"certs",void 0);gi([yi({type:Op,context:1,implicit:true,optional:true})],Rp.prototype,"crls",void 0);var Mp;let Np=Mp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Mp.prototype)}};Np=Mp=gi([fi({type:Me.Set,itemType:zl})],Np);class kp{constructor(t={}){this.version=Vl.v0;this.recipientInfos=new Bp;this.encryptedContentInfo=new up;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],kp.prototype,"version",void 0);gi([yi({type:Rp,context:0,implicit:true,optional:true})],kp.prototype,"originatorInfo",void 0);gi([yi({type:Bp})],kp.prototype,"recipientInfos",void 0);gi([yi({type:up})],kp.prototype,"encryptedContentInfo",void 0);gi([yi({type:Np,context:1,implicit:true,optional:true})],kp.prototype,"unprotectedAttrs",void 0);var Kp;let Hp=Kp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Kp.prototype)}};Hp=Kp=gi([fi({type:Me.Set,itemType:Ll})],Hp);class jp{constructor(t={}){this.version=Vl.v0;this.digestAlgorithms=new Hp;this.encapContentInfo=new ap;this.signerInfos=new Xl;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],jp.prototype,"version",void 0);gi([yi({type:Hp})],jp.prototype,"digestAlgorithms",void 0);gi([yi({type:ap})],jp.prototype,"encapContentInfo",void 0);gi([yi({type:sp,context:0,implicit:true,optional:true})],jp.prototype,"certificates",void 0);gi([yi({type:Op,context:1,implicit:true,optional:true})],jp.prototype,"crls",void 0);gi([yi({type:Xl})],jp.prototype,"signerInfos",void 0);var Up;class Fp{constructor(t={}){this.attrId="";this.attrValues=[];Object.assign(t)}}gi([yi({type:Ne.ObjectIdentifier})],Fp.prototype,"attrId",void 0);gi([yi({type:Ne.Any,repeated:"set"})],Fp.prototype,"attrValues",void 0);let _p=Up=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Up.prototype)}};_p=Up=gi([fi({type:Me.Sequence,itemType:Fp})],_p);var Vp;let Lp=Vp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Vp.prototype)}};Lp=Vp=gi([fi({type:Me.Sequence,itemType:np})],Lp);class $p{constructor(t={}){this.certId="";this.certValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],$p.prototype,"certId",void 0);gi([yi({type:Ne.Any,context:0})],$p.prototype,"certValue",void 0);class Gp{constructor(t={}){this.crlId="";this.crltValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Gp.prototype,"crlId",void 0);gi([yi({type:Ne.Any,context:0})],Gp.prototype,"crltValue",void 0);let Wp=class t extends Nn{};Wp=gi([fi({type:Me.Sequence})],Wp);let Qp=class t extends xn{};Qp=gi([fi({type:Me.Sequence})],Qp);class qp{constructor(t={}){this.secretTypeId="";this.secretValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],qp.prototype,"secretTypeId",void 0);gi([yi({type:Ne.Any,context:0})],qp.prototype,"secretValue",void 0);class zp{constructor(t={}){this.mac=new An;this.macSalt=new Ke;this.iterations=1;Object.assign(this,t)}}gi([yi({type:An})],zp.prototype,"mac",void 0);gi([yi({type:Ke})],zp.prototype,"macSalt",void 0);gi([yi({type:Ne.Integer,defaultValue:1})],zp.prototype,"iterations",void 0);class Jp{constructor(t={}){this.version=3;this.authSafe=new np;this.macData=new zp;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Jp.prototype,"version",void 0);gi([yi({type:np})],Jp.prototype,"authSafe",void 0);gi([yi({type:zp,optional:true})],Jp.prototype,"macData",void 0);var Zp;class Xp{constructor(t={}){this.bagId="";this.bagValue=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Ne.ObjectIdentifier})],Xp.prototype,"bagId",void 0);gi([yi({type:Ne.Any,context:0})],Xp.prototype,"bagValue",void 0);gi([yi({type:Fp,repeated:"set",optional:true})],Xp.prototype,"bagAttributes",void 0);let Yp=Zp=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Zp.prototype)}};Yp=Zp=gi([fi({type:Me.Sequence,itemType:Xp})],Yp);var th,eh,ih;const rh="1.2.840.113549.1.9";const sh=`${rh}.2`;const nh=`${rh}.7`;const oh=`${rh}.14`;let ah=class t extends bi{constructor(t={}){super(t)}toString(){return this.ia5String||super.toString()}};gi([yi({type:Ne.IA5String})],ah.prototype,"ia5String",void 0);ah=gi([fi({type:Me.Choice})],ah);let ch=class t extends np{};ch=gi([fi({type:Me.Sequence})],ch);let uh=class t extends Jp{};uh=gi([fi({type:Me.Sequence})],uh);let lh=class t extends xn{};lh=gi([fi({type:Me.Sequence})],lh);let ph=class t{constructor(t=""){this.value=t}toString(){return this.value}};gi([yi({type:Ne.IA5String})],ph.prototype,"value",void 0);ph=gi([fi({type:Me.Choice})],ph);let hh=class t extends ah{};hh=gi([fi({type:Me.Choice})],hh);let dh=class t extends bi{};dh=gi([fi({type:Me.Choice})],dh);let fh=class t{constructor(t=new Date){this.value=t}};gi([yi({type:Ne.GeneralizedTime})],fh.prototype,"value",void 0);fh=gi([fi({type:Me.Choice})],fh);let yh=class t extends bi{};yh=gi([fi({type:Me.Choice})],yh);let Sh=class t{constructor(t="M"){this.value=t}toString(){return this.value}};gi([yi({type:Ne.PrintableString})],Sh.prototype,"value",void 0);Sh=gi([fi({type:Me.Choice})],Sh);let Ah=class t{constructor(t=""){this.value=t}toString(){return this.value}};gi([yi({type:Ne.PrintableString})],Ah.prototype,"value",void 0);Ah=gi([fi({type:Me.Choice})],Ah);let Ch=class t extends Ah{};Ch=gi([fi({type:Me.Choice})],Ch);let vh=class t extends bi{};vh=gi([fi({type:Me.Choice})],vh);let mh=class t{constructor(t=""){this.value=t}toString(){return this.value}};gi([yi({type:Ne.ObjectIdentifier})],mh.prototype,"value",void 0);mh=gi([fi({type:Me.Choice})],mh);let gh=class t extends Ss{};gh=gi([fi({type:Me.Choice})],gh);let wh=class t{constructor(t=0){this.value=t}toString(){return this.value.toString()}};gi([yi({type:Ne.Integer})],wh.prototype,"value",void 0);wh=gi([fi({type:Me.Choice})],wh);let Eh=class t extends Zl{};Eh=gi([fi({type:Me.Sequence})],Eh);let Ph=class t extends bi{};Ph=gi([fi({type:Me.Choice})],Ph);let Dh=th=class t extends ms{constructor(t){super(t);Object.setPrototypeOf(this,th.prototype)}};Dh=th=gi([fi({type:Me.Sequence})],Dh);let bh=eh=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,eh.prototype)}};bh=eh=gi([fi({type:Me.Set,itemType:zl})],bh);let Bh=class t{constructor(t=""){this.value=t}toString(){return this.value}};gi([yi({type:Ne.BmpString})],Bh.prototype,"value",void 0);Bh=gi([fi({type:Me.Choice})],Bh);let Ih=class t extends fs{};Ih=gi([fi({type:Me.Sequence})],Ih);let xh=ih=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,ih.prototype)}};xh=ih=gi([fi({type:Me.Sequence,itemType:Ih})],xh);var Th;let Oh=Th=class t extends vi{constructor(t){super(t);Object.setPrototypeOf(this,Th.prototype)}};Oh=Th=gi([fi({type:Me.Sequence,itemType:Yr})],Oh);class Rh{constructor(t={}){this.version=0;this.subject=new Oi;this.subjectPKInfo=new ys;this.attributes=new Oh;Object.assign(this,t)}}gi([yi({type:Ne.Integer})],Rh.prototype,"version",void 0);gi([yi({type:Oi})],Rh.prototype,"subject",void 0);gi([yi({type:ys})],Rh.prototype,"subjectPKInfo",void 0);gi([yi({type:Oh,implicit:true,context:0})],Rh.prototype,"attributes",void 0);class Mh{constructor(t={}){this.certificationRequestInfo=new Rh;this.signatureAlgorithm=new fs;this.signature=new ArrayBuffer(0);Object.assign(this,t)}}gi([yi({type:Rh})],Mh.prototype,"certificationRequestInfo",void 0);gi([yi({type:fs})],Mh.prototype,"signatureAlgorithm",void 0);gi([yi({type:Ne.BitString})],Mh.prototype,"signature",void 0);export{jp as $,Bu as A,sh as B,Es as C,o as D,xu as E,nh as F,Nl as G,Rl as H,Ml as I,jl as J,gl as K,Kl as L,Tl as M,ca as N,Il as O,_u as P,bl as Q,wn as R,Pl as S,Hl as T,hh as U,kl as V,Ul as W,Mh as X,ia as Y,no as Z,sa as _,oo as a,op as a0,Ke as a1,sp as a2,rp as a3,np as a4,Oi as a5,Dr as a6,Rr as a7,Xi as a8,Mi as a9,Lr as aA,xa as aB,Ra as aC,Na as aD,Ea as aE,ac as aF,nc as aG,yc as aH,dc as aI,Ic as aJ,bc as aK,is as aL,os as aM,ls as aN,fa as aO,Vc as aP,iu as aQ,Gr as aR,zr as aS,ur as aT,wr as aU,Su as aV,wu as aW,er as aa,rr as ab,Ni as ac,gi as ad,yi as ae,Ne as af,fi as ag,Me as ah,vi as ai,ma as aj,wa as ak,Fe as al,vu as am,ou as an,au as ao,jr as ap,Qi as aq,Ir as ar,ss as as,Gi as at,Cr as au,Vi as av,ds as aw,Xr as ax,ar as ay,Ec as az,n as b,$u as c,t as d,mi as e,Us as f,Ls as g,Ln as h,Bs as i,Gn as j,Dn as k,Bn as l,bn as m,Gu as n,nl as o,bs as p,Yr as q,Ai as r,Dh as s,Ph as t,wl as u,Ol as v,xl as w,Bl as x,Dl as y,oh as z};
|
|
142
|
+
//# sourceMappingURL=p-PeMaLTUD.js.map
|