@peculiar/certificates-viewer 3.7.0 → 3.9.0

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.
Files changed (63) hide show
  1. package/dist/cjs/{certification_request-00bbfbc5.js → certification_request-b9ac73f2.js} +443 -431
  2. package/dist/cjs/{crl-de4e196b.js → crl-57727a07.js} +6 -6
  3. package/dist/cjs/{download-a97f4cb2.js → download-93f7b773.js} +9 -5
  4. package/dist/cjs/index.cjs.js +1 -1
  5. package/dist/cjs/{l10n-17c96aba.js → l10n-ddc7cff9.js} +1 -1
  6. package/dist/cjs/{miscellaneous-30c4aded.js → miscellaneous-07184a47.js} +210 -67
  7. package/dist/cjs/peculiar-attribute-certificate-viewer_3.cjs.entry.js +7 -5
  8. package/dist/cjs/peculiar-button-split_4.cjs.entry.js +2 -2
  9. package/dist/cjs/peculiar-certificate-decoder.cjs.entry.js +5 -5
  10. package/dist/cjs/peculiar-certificate-viewer.cjs.entry.js +5 -5
  11. package/dist/cjs/peculiar-certificates-viewer.cjs.entry.js +4 -4
  12. package/dist/cjs/{x509_certificate-2af9b990.js → x509_certificate-da0fc87d.js} +4 -4
  13. package/dist/collection/components/certificate-details-parts/extensions/biometric_syntax_extension.js +10 -9
  14. package/dist/collection/components/certificate-details-parts/extensions/certificate_policies_extension.js +24 -24
  15. package/dist/collection/components/certificate-details-parts/extensions/certificate_transparency_extension.js +11 -10
  16. package/dist/collection/components/certificate-details-parts/extensions/extended_key_usage_extension.js +6 -2
  17. package/dist/collection/components/certificate-details-parts/extensions/info_access_syntax_extension.js +7 -6
  18. package/dist/collection/components/certificate-details-parts/extensions/qc_statements_extension.js +37 -6
  19. package/dist/collection/components/certificate-details-parts/extensions/subject_directory_attributes_extension.js +7 -6
  20. package/dist/collection/components/certificate-details-parts/public_key.js +5 -8
  21. package/dist/collection/components/csr-viewer/csr-viewer.js +2 -0
  22. package/dist/collection/constants/oids.js +15 -13
  23. package/dist/collection/crypto/crl.js +1 -1
  24. package/dist/collection/crypto/csr.js +1 -1
  25. package/dist/collection/crypto/provider.js +2 -1
  26. package/dist/collection/crypto/x509_attribute_certificate.js +1 -1
  27. package/dist/collection/crypto/x509_certificate.js +1 -1
  28. package/dist/collection/utils/download_from_buffer.js +9 -5
  29. package/dist/esm/{certification_request-8cc9d070.js → certification_request-db83dd19.js} +23 -17
  30. package/dist/esm/{crl-f43a95b7.js → crl-34288843.js} +6 -6
  31. package/dist/esm/{download-67ac9120.js → download-91511aeb.js} +9 -5
  32. package/dist/esm/index.js +1 -1
  33. package/dist/esm/{l10n-a68d5748.js → l10n-d48f35ff.js} +1 -1
  34. package/dist/esm/{miscellaneous-b74d9eae.js → miscellaneous-ee8e1994.js} +210 -67
  35. package/dist/esm/peculiar-attribute-certificate-viewer_3.entry.js +7 -5
  36. package/dist/esm/peculiar-button-split_4.entry.js +2 -2
  37. package/dist/esm/peculiar-certificate-decoder.entry.js +5 -5
  38. package/dist/esm/peculiar-certificate-viewer.entry.js +5 -5
  39. package/dist/esm/peculiar-certificates-viewer.entry.js +4 -4
  40. package/dist/esm/{x509_certificate-0fdd28aa.js → x509_certificate-1acb3564.js} +4 -4
  41. package/dist/peculiar/index.esm.js +1 -1
  42. package/dist/peculiar/p-08aba71b.js +69 -0
  43. package/dist/peculiar/p-0f7868b1.js +11 -0
  44. package/dist/peculiar/{p-167fd2db.entry.js → p-2f213160.entry.js} +2 -2
  45. package/dist/peculiar/{p-c72f8e8f.js → p-3c4e4245.js} +6 -6
  46. package/dist/peculiar/{p-ea9a6317.js → p-48a620ff.js} +5 -5
  47. package/dist/peculiar/p-711b4e1e.js +18 -0
  48. package/dist/peculiar/{p-0868020d.entry.js → p-81ae1305.entry.js} +1 -1
  49. package/dist/peculiar/{p-4e9318fb.entry.js → p-81d33fb4.entry.js} +1 -1
  50. package/dist/peculiar/{p-05337212.entry.js → p-9bfd4f58.entry.js} +1 -1
  51. package/dist/peculiar/{p-893659f4.entry.js → p-df53fbcc.entry.js} +1 -1
  52. package/dist/peculiar/{p-fec9d812.js → p-ec250cc4.js} +1 -1
  53. package/dist/peculiar/peculiar.esm.js +1 -1
  54. package/dist/types/constants/oids.d.ts +2 -0
  55. package/dist/types/crypto/crl.d.ts +1 -1
  56. package/dist/types/crypto/csr.d.ts +1 -1
  57. package/dist/types/crypto/x509_attribute_certificate.d.ts +1 -1
  58. package/dist/types/crypto/x509_certificate.d.ts +1 -1
  59. package/dist/types/interface.d.ts +1 -0
  60. package/package.json +3 -2
  61. package/dist/peculiar/p-45336b4f.js +0 -69
  62. package/dist/peculiar/p-cff9655c.js +0 -18
  63. package/dist/peculiar/p-ec8787ed.js +0 -11
@@ -2,9 +2,9 @@
2
2
  * © Peculiar Ventures https://peculiarventures.com/ - MIT License
3
3
  */
4
4
  import { h } from './index-bbd484d9.js';
5
- import { l as l10n, a as dateShort } from './l10n-a68d5748.js';
6
- import { b as build } from './download-67ac9120.js';
7
- import { _ as OIDs, $ as Name, a3 as OtherName, u as AsnParser, a4 as DisplayText, a5 as UserNotice, a6 as EDIPartyName, a7 as AsnIntegerArrayBufferConverter, a8 as KeyUsage, a9 as BasicConstraints, aa as ExtendedKeyUsage, ab as SubjectKeyIdentifier, ac as AuthorityKeyIdentifier, ad as CRLDistributionPoints, ae as AuthorityInfoAccessSyntax, af as SubjectInfoAccessSyntax, ag as SubjectAlternativeName, ah as CertificatePolicies, ai as CertificateTransparency, aj as NameConstraints, ak as CertificateTemplate, al as EnrollCertTypeChoice, am as CaVersion, an as QCStatements, ao as NetscapeComment, ap as NetscapeCertType, aq as LeiRole, ar as LeiChoice, as as Timestamp, at as ArchiveRevInfo, a0 as CRLReason, au as SubjectDirectoryAttributes, av as PrivateKeyUsagePeriod, aw as EntrustVersionInfo, ax as BiometricSyntax, ay as LogotypeExtn, az as TNAuthorizationList, aA as PolicyConstraints, aB as PolicyMappings, aC as CRLNumber, aD as IssuingDistributionPoint } from './certification_request-8cc9d070.js';
5
+ import { l as l10n, a as dateShort } from './l10n-d48f35ff.js';
6
+ import { b as build } from './download-91511aeb.js';
7
+ import { _ as OIDs, $ as Name, a3 as OtherName, u as AsnParser, a4 as DisplayText, a5 as UserNotice, a6 as EDIPartyName, a7 as __decorate, a8 as AsnProp, a9 as AsnPropTypes, aa as AsnType, ab as AsnTypeTypes, ac as AsnArray, ad as id_qcs_pkixQCSyntax_v2, ae as SemanticsInformation, af as AsnIntegerArrayBufferConverter, ag as KeyUsage, ah as BasicConstraints, ai as ExtendedKeyUsage, aj as SubjectKeyIdentifier, ak as AuthorityKeyIdentifier, al as CRLDistributionPoints, am as AuthorityInfoAccessSyntax, an as SubjectInfoAccessSyntax, ao as SubjectAlternativeName, ap as CertificatePolicies, aq as CertificateTransparency, ar as NameConstraints, as as CertificateTemplate, at as EnrollCertTypeChoice, au as CaVersion, av as QCStatements, aw as NetscapeComment, ax as NetscapeCertType, ay as LeiRole, az as LeiChoice, aA as Timestamp, aB as ArchiveRevInfo, a0 as CRLReason, aC as SubjectDirectoryAttributes, aD as PrivateKeyUsagePeriod, aE as EntrustVersionInfo, aF as BiometricSyntax, aG as LogotypeExtn, aH as TNAuthorizationList, aI as PolicyConstraints, aJ as PolicyMappings, aK as CRLNumber, aL as IssuingDistributionPoint } from './certification_request-db83dd19.js';
8
8
 
9
9
  /**
10
10
  * @license
@@ -120,9 +120,8 @@ const BasicInformation = (props) => {
120
120
  * LICENSE file in the root directory of this source tree.
121
121
  */
122
122
  function getPublicKeyModulus(publicKey) {
123
- var _a;
124
- if ((_a = publicKey.params) === null || _a === void 0 ? void 0 : _a['modulus']) {
125
- let length = publicKey.params['modulus'].byteLength;
123
+ if ('modulus' in publicKey.params) {
124
+ let length = publicKey.params.modulus.byteLength;
126
125
  if (length % 2) {
127
126
  length -= 1;
128
127
  }
@@ -131,9 +130,8 @@ function getPublicKeyModulus(publicKey) {
131
130
  return null;
132
131
  }
133
132
  function getPublicKeyExponent(publicKey) {
134
- var _a;
135
- if ((_a = publicKey.params) === null || _a === void 0 ? void 0 : _a['publicExponent']) {
136
- return publicKey.params['publicExponent'].byteLength === 3
133
+ if ('publicExponent' in publicKey.params) {
134
+ return publicKey.params.publicExponent.byteLength === 3
137
135
  ? 65537
138
136
  : 3;
139
137
  }
@@ -145,10 +143,9 @@ const PublicKey = (props) => {
145
143
  return null;
146
144
  }
147
145
  function renderKeyDetails(key) {
148
- var _a;
149
146
  return [
150
147
  h(RowValue, { name: l10n.getString('algorithm'), value: getStringByOID(key.algorithm) }),
151
- h(RowValue, { name: l10n.getString('namedCurve'), value: getStringByOID((_a = key.params) === null || _a === void 0 ? void 0 : _a['namedCurve']) }),
148
+ h(RowValue, { name: l10n.getString('namedCurve'), value: getStringByOID('namedCurve' in key.params ? key.params.namedCurve : undefined) }),
152
149
  h(RowValue, { name: l10n.getString('exponent'), value: getPublicKeyExponent(key) }),
153
150
  h(RowValue, { name: l10n.getString('modulus'), value: getPublicKeyModulus(key) }),
154
151
  h(RowValue, { name: l10n.getString('value'), value: build.Convert.ToHex(key.value), monospace: true, collapse: true }),
@@ -294,7 +291,11 @@ const BasicConstraintsExtension = (props) => {
294
291
  */
295
292
  const ExtendedKeyUsageExtension = (props) => {
296
293
  const { extension } = props;
297
- return (h(BasicExtension, { extension: extension }, extension.value.map((usage, arrayIndex) => (h(RowValue, { name: `Purpose #${arrayIndex + 1}`, value: getStringByOID(usage) })))));
294
+ return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
295
+ h(RowValue, { name: "Purposes:", value: "" }),
296
+ extension.value.map((usage) => (h(TableRowTable, null,
297
+ h(RowValue, { name: "Purpose", value: getStringByOID(usage) })))),
298
+ ])));
298
299
  };
299
300
 
300
301
  /**
@@ -440,11 +441,12 @@ const CRLDistributionPointsExtension = (props) => {
440
441
  */
441
442
  const InfoAccessSyntaxExtension = (props) => {
442
443
  const { extension } = props;
443
- return (h(BasicExtension, { extension: extension }, extension.value.map((description, arrayIndex) => ([
444
- h(RowValue, { name: `Description #${arrayIndex + 1}`, value: "" }),
445
- h(RowValue, { name: "Method", value: getStringByOID(description.accessMethod) }),
446
- h(GeneralNamePart, Object.assign({ generalName: description.accessLocation }, props)),
447
- ]))));
444
+ return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
445
+ h(RowValue, { name: "Descriptions:", value: "" }),
446
+ extension.value.map((description) => (h(TableRowTable, null,
447
+ h(RowValue, { name: "Method", value: getStringByOID(description.accessMethod) }),
448
+ h(GeneralNamePart, Object.assign({ generalName: description.accessLocation }, props))))),
449
+ ])));
448
450
  };
449
451
 
450
452
  /**
@@ -468,30 +470,30 @@ const SubjectAlternativeNameExtension = (props) => {
468
470
  */
469
471
  const CertificatePoliciesExtension = (props) => {
470
472
  const { extension } = props;
471
- return (h(BasicExtension, { extension: extension }, extension.value.map((policy, arrayIndex) => {
472
- var _a;
473
- return ([
474
- h(RowValue, { name: `Policy #${arrayIndex + 1}`, value: "" }),
475
- h(RowValue, { name: "ID", value: getStringByOID(policy.policyIdentifier) }),
476
- (_a = policy.policyQualifiers) === null || _a === void 0 ? void 0 : _a.map((qualifierInfo, indexInfo) => {
477
- const data = [
478
- h(RowValue, { name: `Qualifier #${arrayIndex + 1}.${indexInfo + 1}`, value: "" }),
479
- h(RowValue, { name: "ID", value: getStringByOID(qualifierInfo.policyQualifierId) }),
480
- ];
481
- if (qualifierInfo.policyQualifierId === '1.3.6.1.5.5.7.2.1') {
482
- const value = AsnParser.parse(qualifierInfo.qualifier, DisplayText);
483
- data.push(h(RowValue, { name: "Value", value: value.toString() }));
484
- }
485
- if (qualifierInfo.policyQualifierId === '1.3.6.1.5.5.7.2.2') {
486
- const value = AsnParser.parse(qualifierInfo.qualifier, UserNotice);
487
- if (value.explicitText) {
488
- data.push(h(RowValue, { name: "Value", value: value.explicitText.toString() }));
473
+ return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
474
+ h(RowValue, { name: "Policies:", value: "" }),
475
+ extension.value.map((policy) => (h(TableRowTable, null,
476
+ h(RowValue, { name: "Policy ID", value: getStringByOID(policy.policyIdentifier) }),
477
+ policy.policyQualifiers && Boolean(policy.policyQualifiers.length) && ([
478
+ h(RowValue, { name: "Qualifiers:", value: "" }),
479
+ policy.policyQualifiers.map((qualifierInfo) => {
480
+ const data = [
481
+ h(RowValue, { name: "Qualifier ID", value: getStringByOID(qualifierInfo.policyQualifierId) }),
482
+ ];
483
+ if (qualifierInfo.policyQualifierId === '1.3.6.1.5.5.7.2.1') {
484
+ const value = AsnParser.parse(qualifierInfo.qualifier, DisplayText);
485
+ data.push(h(RowValue, { name: "Value", value: value.toString() }));
489
486
  }
490
- }
491
- return data;
492
- }),
493
- ]);
494
- })));
487
+ if (qualifierInfo.policyQualifierId === '1.3.6.1.5.5.7.2.2') {
488
+ const value = AsnParser.parse(qualifierInfo.qualifier, UserNotice);
489
+ if (value.explicitText) {
490
+ data.push(h(RowValue, { name: "Value", value: value.explicitText.toString() }));
491
+ }
492
+ }
493
+ return (h(TableRowTable, null, data));
494
+ }),
495
+ ])))),
496
+ ])));
495
497
  };
496
498
 
497
499
  /**
@@ -589,15 +591,16 @@ const logs = {
589
591
  */
590
592
  const CertificateTransparencyExtension = (props) => {
591
593
  const { extension } = props;
592
- return (h(BasicExtension, { extension: extension }, extension.value.toJSON().map((signedCertificateTimestamp, arrayIndex) => ([
593
- h(RowValue, { name: `SCT #${arrayIndex + 1}`, value: "" }),
594
- h(RowValue, { name: "Version", value: signedCertificateTimestamp.version + 1 }),
595
- h(RowValue, { name: "Log Operator", value: logs[signedCertificateTimestamp.logId] || signedCertificateTimestamp.logId }),
596
- h(RowValue, { name: "Log Key ID", value: signedCertificateTimestamp.logId, monospace: true }),
597
- h(RowValue, { name: "Timestamp", value: dateShort(signedCertificateTimestamp.timestamp) }),
598
- h(RowValue, { name: "Signature Algorithm", value: `${signedCertificateTimestamp.hashAlgorithm} ${signedCertificateTimestamp.signatureAlgorithm}`.toUpperCase() }),
599
- h(RowValue, { name: "Signature", value: signedCertificateTimestamp.signature, monospace: true }),
600
- ]))));
594
+ return (h(BasicExtension, { extension: extension }, Boolean(extension.value.items.length) && ([
595
+ h(RowValue, { name: "Signed Certificate Timestamps:", value: "" }),
596
+ extension.value.toJSON().map((signedCertificateTimestamp) => (h(TableRowTable, null,
597
+ h(RowValue, { name: "Version", value: signedCertificateTimestamp.version + 1 }),
598
+ h(RowValue, { name: "Log Operator", value: logs[signedCertificateTimestamp.logId] || signedCertificateTimestamp.logId }),
599
+ h(RowValue, { name: "Log Key ID", value: signedCertificateTimestamp.logId, monospace: true }),
600
+ h(RowValue, { name: "Timestamp", value: dateShort(signedCertificateTimestamp.timestamp) }),
601
+ h(RowValue, { name: "Signature Algorithm", value: `${signedCertificateTimestamp.hashAlgorithm} ${signedCertificateTimestamp.signatureAlgorithm}`.toUpperCase() }),
602
+ h(RowValue, { name: "Signature", value: signedCertificateTimestamp.signature, monospace: true })))),
603
+ ])));
601
604
  };
602
605
 
603
606
  /**
@@ -658,6 +661,116 @@ const CaVersionExtension = (props) => {
658
661
  h(RowValue, { name: "Key Index", value: version.keyIndex })));
659
662
  };
660
663
 
664
+ var PdsLocations_1, QcEuPDS_1, QcType_1, QcCClegislation_1;
665
+ let Iso4217CurrencyCode = class Iso4217CurrencyCode {
666
+ constructor(value) {
667
+ if (typeof value === "string") {
668
+ this.alphabetic = value;
669
+ }
670
+ else if (typeof value === "number") {
671
+ this.numeric = value;
672
+ }
673
+ }
674
+ };
675
+ __decorate([
676
+ AsnProp({ type: AsnPropTypes.PrintableString })
677
+ ], Iso4217CurrencyCode.prototype, "alphabetic", void 0);
678
+ __decorate([
679
+ AsnProp({ type: AsnPropTypes.PrintableString })
680
+ ], Iso4217CurrencyCode.prototype, "numeric", void 0);
681
+ Iso4217CurrencyCode = __decorate([
682
+ AsnType({ type: AsnTypeTypes.Choice })
683
+ ], Iso4217CurrencyCode);
684
+ class MonetaryValue {
685
+ constructor(params = {}) {
686
+ this.currency = new Iso4217CurrencyCode();
687
+ this.amount = 0;
688
+ this.exponent = 0;
689
+ Object.assign(this, params);
690
+ }
691
+ }
692
+ __decorate([
693
+ AsnProp({ type: Iso4217CurrencyCode })
694
+ ], MonetaryValue.prototype, "currency", void 0);
695
+ __decorate([
696
+ AsnProp({ type: AsnPropTypes.Integer })
697
+ ], MonetaryValue.prototype, "amount", void 0);
698
+ __decorate([
699
+ AsnProp({ type: AsnPropTypes.Integer })
700
+ ], MonetaryValue.prototype, "exponent", void 0);
701
+ let QcEuLimitValue = class QcEuLimitValue extends MonetaryValue {
702
+ };
703
+ QcEuLimitValue = __decorate([
704
+ AsnType({ type: AsnTypeTypes.Sequence })
705
+ ], QcEuLimitValue);
706
+ let QcEuRetentionPeriod = class QcEuRetentionPeriod {
707
+ constructor(value = 0) {
708
+ this.value = value;
709
+ }
710
+ };
711
+ __decorate([
712
+ AsnProp({ type: AsnPropTypes.Integer })
713
+ ], QcEuRetentionPeriod.prototype, "value", void 0);
714
+ QcEuRetentionPeriod = __decorate([
715
+ AsnType({ type: AsnTypeTypes.Choice })
716
+ ], QcEuRetentionPeriod);
717
+ let PdsLocation = class PdsLocation {
718
+ constructor(params = {}) {
719
+ this.url = "";
720
+ this.language = "";
721
+ Object.assign(this, params);
722
+ }
723
+ };
724
+ __decorate([
725
+ AsnProp({ type: AsnPropTypes.IA5String })
726
+ ], PdsLocation.prototype, "url", void 0);
727
+ __decorate([
728
+ AsnProp({ type: AsnPropTypes.PrintableString })
729
+ ], PdsLocation.prototype, "language", void 0);
730
+ PdsLocation = __decorate([
731
+ AsnType({ type: AsnTypeTypes.Sequence })
732
+ ], PdsLocation);
733
+ let PdsLocations = PdsLocations_1 = class PdsLocations extends AsnArray {
734
+ constructor(items) {
735
+ super(items);
736
+ Object.setPrototypeOf(this, PdsLocations_1.prototype);
737
+ }
738
+ };
739
+ PdsLocations = PdsLocations_1 = __decorate([
740
+ AsnType({ type: AsnTypeTypes.Sequence, itemType: PdsLocation })
741
+ ], PdsLocations);
742
+ let QcEuPDS = QcEuPDS_1 = class QcEuPDS extends PdsLocations {
743
+ constructor(items) {
744
+ super(items);
745
+ Object.setPrototypeOf(this, QcEuPDS_1.prototype);
746
+ }
747
+ };
748
+ QcEuPDS = QcEuPDS_1 = __decorate([
749
+ AsnType({ type: AsnTypeTypes.Sequence, itemType: PdsLocation })
750
+ ], QcEuPDS);
751
+ let QcType = QcType_1 = class QcType extends AsnArray {
752
+ constructor(items) {
753
+ super(items);
754
+ Object.setPrototypeOf(this, QcType_1.prototype);
755
+ }
756
+ };
757
+ QcType = QcType_1 = __decorate([
758
+ AsnType({ type: AsnTypeTypes.Sequence, itemType: AsnPropTypes.ObjectIdentifier })
759
+ ], QcType);
760
+ let QcCClegislation = QcCClegislation_1 = class QcCClegislation extends AsnArray {
761
+ constructor(items) {
762
+ super(items);
763
+ Object.setPrototypeOf(this, QcCClegislation_1.prototype);
764
+ }
765
+ };
766
+ QcCClegislation = QcCClegislation_1 = __decorate([
767
+ AsnType({ type: AsnTypeTypes.Sequence, itemType: AsnPropTypes.PrintableString })
768
+ ], QcCClegislation);
769
+ const id_etsi_qcs = "0.4.0.1862.1";
770
+ const id_etsi_qcs_qcRetentionPeriod = `${id_etsi_qcs}.3`;
771
+ const id_etsi_qcs_qcPDS = `${id_etsi_qcs}.5`;
772
+ const id_etsi_qcs_qcType = `${id_etsi_qcs}.6`;
773
+
661
774
  /**
662
775
  * @license
663
776
  * Copyright (c) Peculiar Ventures, LLC.
@@ -667,11 +780,39 @@ const CaVersionExtension = (props) => {
667
780
  */
668
781
  const QCStatementsExtension = (props) => {
669
782
  const { extension } = props;
670
- return (h(BasicExtension, { extension: extension }, extension.value.map((statement, arrayIndex) => ([
671
- h(RowValue, { name: `Statement #${arrayIndex + 1}`, value: "" }),
672
- h(RowValue, { name: "ID", value: getStringByOID(statement.statementId) }),
673
- h(RowValue, { name: "Info", value: statement.statementInfo.byteLength ? build.Convert.ToHex(statement.statementInfo) : null, monospace: true }),
674
- ]))));
783
+ function renderStatementInfo(statementId, statementInfo) {
784
+ if (!statementInfo.byteLength) {
785
+ return null;
786
+ }
787
+ if (statementId === id_qcs_pkixQCSyntax_v2) {
788
+ const semanticsInformation = AsnParser.parse(statementInfo, SemanticsInformation);
789
+ return (h(RowValue, { name: "Semantics Identifier", value: getStringByOID(semanticsInformation.semanticsIdentifier) }));
790
+ }
791
+ if (statementId === id_etsi_qcs_qcType) {
792
+ const qcTypes = AsnParser.parse(statementInfo, QcType);
793
+ return (h(RowValue, { name: "QC Types", value: qcTypes.map((type) => getStringByOID(type)).join(', ') }));
794
+ }
795
+ if (statementId === id_etsi_qcs_qcRetentionPeriod) {
796
+ const retentionPeriod = AsnParser.parse(statementInfo, QcEuRetentionPeriod);
797
+ return (h(RowValue, { name: "Retention Period", value: `${retentionPeriod.value} years` }));
798
+ }
799
+ if (statementId === id_etsi_qcs_qcPDS) {
800
+ const pdsLocations = AsnParser.parse(statementInfo, PdsLocations);
801
+ return ([
802
+ h(RowValue, { name: "PDS Locations:", value: "" }),
803
+ pdsLocations.map((location) => (h(TableRowTable, null,
804
+ h(RowValue, { name: "URL", value: location.url }),
805
+ h(RowValue, { name: "Language", value: location.language })))),
806
+ ]);
807
+ }
808
+ return (h(RowValue, { name: "Info", value: build.Convert.ToHex(statementInfo), monospace: true }));
809
+ }
810
+ return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
811
+ h(RowValue, { name: "Statements:", value: "" }),
812
+ extension.value.map((statement) => (h(TableRowTable, null,
813
+ h(RowValue, { name: "Statement ID", value: getStringByOID(statement.statementId) }),
814
+ renderStatementInfo(statement.statementId, statement.statementInfo)))),
815
+ ])));
675
816
  };
676
817
 
677
818
  /**
@@ -787,11 +928,12 @@ function getAttributeValue(attribute) {
787
928
  */
788
929
  const SubjectDirectoryAttributesExtension = (props) => {
789
930
  const { extension } = props;
790
- return (h(BasicExtension, { extension: extension }, extension.value.map((attribute, arrayIndex) => ([
791
- h(RowValue, { name: `Attribute #${arrayIndex + 1}`, value: "" }),
792
- h(RowValue, { name: "Type", value: getStringByOID(attribute.type) }),
793
- h(RowValue, { name: "Value", value: getAttributeValue(attribute) }),
794
- ]))));
931
+ return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
932
+ h(RowValue, { name: "Attributes:", value: "" }),
933
+ extension.value.map((attribute) => (h(TableRowTable, null,
934
+ h(RowValue, { name: "Type", value: getStringByOID(attribute.type) }),
935
+ h(RowValue, { name: "Value", value: getAttributeValue(attribute) })))),
936
+ ])));
795
937
  };
796
938
 
797
939
  /**
@@ -844,14 +986,15 @@ const EntrustVersionInfoExtension = (props) => {
844
986
  */
845
987
  const BiometricSyntaxExtension = (props) => {
846
988
  const { extension } = props;
847
- return (h(BasicExtension, { extension: extension }, extension.value.map((data, arrayIndex) => ([
848
- h(RowValue, { name: `Biometric #${arrayIndex + 1}`, value: "" }),
849
- h(RowValue, { name: "OID", value: getStringByOID(data.typeOfBiometricData.biometricDataOid) }),
850
- h(RowValue, { name: "Type", value: data.typeOfBiometricData.predefinedBiometricType }),
851
- h(RowValue, { name: "Algorithm", value: getStringByOID(data.hashAlgorithm.algorithm) }),
852
- h(RowValue, { name: "Hash", value: build.Convert.ToHex(data.biometricDataHash.buffer), monospace: true }),
853
- h(RowValue, { name: "Source Uri", value: data.sourceDataUri }),
854
- ]))));
989
+ return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
990
+ h(RowValue, { name: "Biometrics:", value: "" }),
991
+ extension.value.map((data) => (h(TableRowTable, null,
992
+ h(RowValue, { name: "OID", value: getStringByOID(data.typeOfBiometricData.biometricDataOid) }),
993
+ h(RowValue, { name: "Type", value: data.typeOfBiometricData.predefinedBiometricType }),
994
+ h(RowValue, { name: "Algorithm", value: getStringByOID(data.hashAlgorithm.algorithm) }),
995
+ h(RowValue, { name: "Hash", value: build.Convert.ToHex(data.biometricDataHash.buffer), monospace: true }),
996
+ h(RowValue, { name: "Source Uri", value: data.sourceDataUri })))),
997
+ ])));
855
998
  };
856
999
 
857
1000
  /**
@@ -2,11 +2,11 @@
2
2
  * © Peculiar Ventures https://peculiarventures.com/ - MIT License
3
3
  */
4
4
  import { h, r as registerInstance, H as Host } from './index-bbd484d9.js';
5
- import { _ as OIDs, $ as Name, G as ActivityDescription, W as WebGDPR, I as InsuranceValue, T as TypeRelationship, V as ValuationRanking, U as UnstructuredName, y as ChallengePassword, a0 as CRLReason, a1 as InvalidityDate, a2 as CertificateIssuer } from './certification_request-8cc9d070.js';
6
- import { b as build } from './download-67ac9120.js';
7
- import { l as l10n, a as dateShort } from './l10n-a68d5748.js';
8
- import { X as X509AttributeCertificate, a as CRL, C as CSR } from './crl-f43a95b7.js';
9
- import { g as getStringByOID, R as RowValue, G as GeneralNamePart, a as RowTitle, T as TableRowTable, B as BasicInformation, S as Signature, b as Thumbprints, c as getLEILink, d as getDNSNameLink, e as getIPAddressLink, E as Extensions, M as Miscellaneous, I as IssuerName, f as SubjectName, P as PublicKey } from './miscellaneous-b74d9eae.js';
5
+ import { _ as OIDs, $ as Name, G as ActivityDescription, W as WebGDPR, I as InsuranceValue, T as TypeRelationship, V as ValuationRanking, U as UnstructuredName, y as ChallengePassword, a0 as CRLReason, a1 as InvalidityDate, a2 as CertificateIssuer } from './certification_request-db83dd19.js';
6
+ import { b as build } from './download-91511aeb.js';
7
+ import { l as l10n, a as dateShort } from './l10n-d48f35ff.js';
8
+ import { X as X509AttributeCertificate, a as CRL, C as CSR } from './crl-34288843.js';
9
+ import { g as getStringByOID, R as RowValue, G as GeneralNamePart, a as RowTitle, T as TableRowTable, B as BasicInformation, S as Signature, b as Thumbprints, c as getLEILink, d as getDNSNameLink, e as getIPAddressLink, E as Extensions, M as Miscellaneous, I as IssuerName, f as SubjectName, P as PublicKey } from './miscellaneous-ee8e1994.js';
10
10
 
11
11
  /**
12
12
  * @license
@@ -510,7 +510,9 @@ const CsrViewer = class {
510
510
  constructor(hostRef) {
511
511
  registerInstance(this, hostRef);
512
512
  this.isDecodeInProcess = true;
513
+ // eslint-disable-next-line class-methods-use-this
513
514
  this.getAuthKeyIdParentLink = (value) => value;
515
+ // eslint-disable-next-line class-methods-use-this
514
516
  this.getAuthKeyIdSiblingsLink = (value) => value;
515
517
  this.getSubjectKeyIdChildrenLink = (value) => {
516
518
  var _a;
@@ -2,8 +2,8 @@
2
2
  * © Peculiar Ventures https://peculiarventures.com/ - MIT License
3
3
  */
4
4
  import { r as registerInstance, h, H as Host, g as getElement } from './index-bbd484d9.js';
5
- import { l as l10n, a as dateShort } from './l10n-a68d5748.js';
6
- import './download-67ac9120.js';
5
+ import { l as l10n, a as dateShort } from './l10n-d48f35ff.js';
6
+ import './download-91511aeb.js';
7
7
 
8
8
  const buttonSplitCss = ":host{-webkit-box-sizing:border-box;box-sizing:border-box}:host *,:host *:before,:host *:after{-webkit-box-sizing:inherit;box-sizing:inherit}:host{display:inline-block;vertical-align:top;position:relative;white-space:nowrap;font-size:0}.button_split_icon{width:7px;height:5px;display:inline-block;vertical-align:middle}.button_split_with_icon{width:25px;border-bottom-left-radius:0;border-top-left-radius:0}.button_split_with_icon.m_open::part(base):before{position:fixed;width:100%;height:100%;top:0;left:0;content:\"\"}.button_split_action{width:100%}.button_split_container{position:absolute;bottom:calc(100% + 1px);left:0;width:100%;border-radius:2px;-webkit-box-shadow:0px -2px 1px rgb(var(--pv-color-light-rgb)), 0px 0px 10px rgba(var(--pv-color-dark-rgb), 0.0241168);box-shadow:0px -2px 1px rgb(var(--pv-color-light-rgb)), 0px 0px 10px rgba(var(--pv-color-dark-rgb), 0.0241168);z-index:1}.button_split>peculiar-button:first-of-type::part(base){border-top-right-radius:0;border-bottom-right-radius:0}.button_split>peculiar-button:last-of-type::part(base){border-top-left-radius:0;border-bottom-left-radius:0}.button_split>peculiar-button:not(:first-child){margin-left:-1px}";
9
9
 
@@ -2,11 +2,11 @@
2
2
  * © Peculiar Ventures https://peculiarventures.com/ - MIT License
3
3
  */
4
4
  import { r as registerInstance, c as createEvent, h, H as Host } from './index-bbd484d9.js';
5
- import { i as isPem, a as isX509Pem, b as isPkcs10Pem, c as isX509AttributePem, d as isX509CRLPem } from './certification_request-8cc9d070.js';
6
- import './l10n-a68d5748.js';
7
- import './download-67ac9120.js';
8
- import { X as X509Certificate } from './x509_certificate-0fdd28aa.js';
9
- import { X as X509AttributeCertificate, C as CSR, a as CRL } from './crl-f43a95b7.js';
5
+ import { i as isPem, a as isX509Pem, b as isPkcs10Pem, c as isX509AttributePem, d as isX509CRLPem } from './certification_request-db83dd19.js';
6
+ import './l10n-d48f35ff.js';
7
+ import './download-91511aeb.js';
8
+ import { X as X509Certificate } from './x509_certificate-1acb3564.js';
9
+ import { X as X509AttributeCertificate, C as CSR, a as CRL } from './crl-34288843.js';
10
10
 
11
11
  /**
12
12
  * @license
@@ -2,11 +2,11 @@
2
2
  * © Peculiar Ventures https://peculiarventures.com/ - MIT License
3
3
  */
4
4
  import { r as registerInstance, h, H as Host } from './index-bbd484d9.js';
5
- import { X as X509Certificate } from './x509_certificate-0fdd28aa.js';
6
- import './certification_request-8cc9d070.js';
7
- import './download-67ac9120.js';
8
- import './l10n-a68d5748.js';
9
- import { B as BasicInformation, f as SubjectName, I as IssuerName, P as PublicKey, S as Signature, b as Thumbprints, E as Extensions, c as getLEILink, d as getDNSNameLink, e as getIPAddressLink, M as Miscellaneous } from './miscellaneous-b74d9eae.js';
5
+ import { X as X509Certificate } from './x509_certificate-1acb3564.js';
6
+ import './certification_request-db83dd19.js';
7
+ import './download-91511aeb.js';
8
+ import './l10n-d48f35ff.js';
9
+ import { B as BasicInformation, f as SubjectName, I as IssuerName, P as PublicKey, S as Signature, b as Thumbprints, E as Extensions, c as getLEILink, d as getDNSNameLink, e as getIPAddressLink, M as Miscellaneous } from './miscellaneous-ee8e1994.js';
10
10
 
11
11
  const certificateViewerCss = ":host{-webkit-box-sizing:border-box;box-sizing:border-box}:host *,:host *:before,:host *:after{-webkit-box-sizing:inherit;box-sizing:inherit}:host{display:block;width:100%;word-wrap:break-word;position:relative;min-width:280px;min-height:300px;background:white;background:rgba(var(--pv-color-light-rgb), 1)}th,td{border:none}table{width:100%;margin-bottom:30px;border-spacing:0;border-collapse:collapse}table table{margin-bottom:0}table .title td{border-color:rgba(209, 213, 217, 0.5);border-color:rgba(var(--pv-color-grey_3-rgb), 0.5);padding-top:60px;padding-bottom:15px;border-bottom-width:1px;border-bottom-style:solid}table td:first-child{padding-left:30px;width:130px;padding-right:10px}table td:last-child{padding-right:30px;width:calc(100% - 130px)}table td{vertical-align:top;padding-top:5px;padding-bottom:5px}table td.vertical_align_middle{vertical-align:middle}table .title:first-child td{padding-top:15px}table .title+tr td{padding-top:15px}table td.monospace{max-width:0}table .divider{padding-top:15px;padding-bottom:15px}.divider .bg_fill{background-color:rgba(209, 213, 217, 0.5);background-color:rgba(var(--pv-color-grey_3-rgb), 0.5)}table tr:last-child .divider{padding-top:0;opacity:0}.divider span{display:block;height:1px}.status_wrapper{min-height:inherit;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}.interaction_text{padding:15px 0;width:300px;margin:auto;text-align:center}@media (max-width: 900px){table,tr,td{display:block}table td:last-child,table td:first-child{padding-right:15px;padding-left:15px;width:100%}table .title+tr td{padding-top:5px}table .title+tr td:first-child{padding-top:15px}table td.monospace{width:100%;max-width:none}}:host([data-view=mobile]) table,:host([data-view=mobile]) tr,:host([data-view=mobile]) td{display:block}:host([data-view=mobile]) table td:last-child,:host([data-view=mobile]) table td:first-child{padding-right:15px;padding-left:15px;width:100%}:host([data-view=mobile]) table .title+tr td{padding-top:5px}:host([data-view=mobile]) table .title+tr td:first-child{padding-top:15px}:host([data-view=mobile]) table td.monospace{width:100%;max-width:none}";
12
12
 
@@ -2,10 +2,10 @@
2
2
  * © Peculiar Ventures https://peculiarventures.com/ - MIT License
3
3
  */
4
4
  import { r as registerInstance, c as createEvent, h, H as Host } from './index-bbd484d9.js';
5
- import { X as X509Certificate } from './x509_certificate-0fdd28aa.js';
6
- import { _ as OIDs } from './certification_request-8cc9d070.js';
7
- import './download-67ac9120.js';
8
- import { l as l10n } from './l10n-a68d5748.js';
5
+ import { X as X509Certificate } from './x509_certificate-1acb3564.js';
6
+ import { _ as OIDs } from './certification_request-db83dd19.js';
7
+ import './download-91511aeb.js';
8
+ import { l as l10n } from './l10n-d48f35ff.js';
9
9
 
10
10
  const certificatesViewerCss = ":host{-webkit-box-sizing:border-box;box-sizing:border-box}:host *,:host *:before,:host *:after{-webkit-box-sizing:inherit;box-sizing:inherit}:host{display:block;width:100%;word-wrap:break-word;min-width:280px;overflow:auto;position:relative;background:white;background:rgba(var(--pv-color-light-rgb), 1)}table{width:100%;table-layout:fixed;border-collapse:collapse;border-spacing:0}table thead{background-color:rgba(53, 132, 247, 0.07);background-color:rgba(var(--pv-color-primary-rgb), 0.07)}table tr td{vertical-align:middle}table tbody tr:not(.expanded_summary){cursor:pointer}table tr{border-color:#d1d5d9;border-color:rgba(var(--pv-color-grey_3-rgb), 1)}table th{padding:15px 10px;border-width:1px;border-style:solid;border-color:#d1d5d9;border-color:rgba(var(--pv-color-grey_3-rgb), 1)}table td{padding:8px 10px;border-width:1px;border-style:solid;border-color:#d1d5d9;border-color:rgba(var(--pv-color-grey_3-rgb), 1)}table .col_issuer,table .col_name,table .col_public_key{width:16%}table .col_actions,table .col_tests{width:18%}table.m_extra .col_issuer,table.m_extra .col_name,table.m_extra .col_public_key{width:12%}table.m_extra .col_actions,table.m_extra .col_tests{width:17%}table tr.expanded td:not(:last-child){border-right-color:transparent}table tr.expanded td{border-bottom-color:transparent}.expanded{border-bottom-color:transparent;background-color:rgba(53, 132, 247, 0.04);background-color:rgba(var(--pv-color-primary-rgb), 0.04)}table tr.expanded_summary{background-color:rgba(53, 132, 247, 0.04);background-color:rgba(var(--pv-color-primary-rgb), 0.04)}table tr.expanded_summary td{vertical-align:top;padding:10px 20px 26px}@-webkit-keyframes fadeIn{0%{opacity:0.001}100%{opacity:1}}@keyframes fadeIn{0%{opacity:0.001}100%{opacity:1}}.modal_wrapper{position:fixed;top:0;left:0;width:100%;height:100%;z-index:1;overflow:auto;text-align:center;-webkit-animation:fadeIn 200ms;animation:fadeIn 200ms;padding:30px 10px}.modal_wrapper:before{display:inline-block;vertical-align:middle;width:0;height:100%;content:\"\"}.modal_backdrop{background:rgba(42, 49, 52, 0.5);background:rgba(var(--pv-color-dark-rgb), 0.5);z-index:-1;position:fixed;top:0;right:0;bottom:0;left:0}.modal_container{position:relative;display:inline-block;vertical-align:middle;width:100%;max-width:900px;text-align:left;border-radius:3px;overflow:hidden;background-color:white;background-color:rgba(var(--pv-color-light-rgb), 1);height:100%}.modal_title{background-color:rgba(53, 132, 247, 0.07);background-color:rgba(var(--pv-color-primary-rgb), 0.07);border-color:#d1d5d9;border-color:rgba(var(--pv-color-grey_3-rgb), 1);border-bottom-width:1px;border-bottom-style:solid;padding:20px 60px 16px 20px;position:relative;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;height:60px}.modal_content{height:calc(100% - 60px);overflow-y:auto}.modal_close{cursor:pointer;border:none;background-color:transparent;position:absolute;top:0;bottom:0;right:0;padding:0 12px;-webkit-transition:opacity 100ms;transition:opacity 100ms;outline:none}.modal_close:hover{opacity:0.6}.modal_close svg{fill:#2a3134;fill:rgba(var(--pv-color-dark-rgb), 1)}.button_table_action{margin:2px}.mobile_title{display:none}.status_wrapper{height:85px;text-align:center;pointer-events:none}.search_section{background-color:rgba(53, 132, 247, 0.07);background-color:rgba(var(--pv-color-primary-rgb), 0.07);border-color:#d1d5d9;border-color:rgba(var(--pv-color-grey_3-rgb), 1);height:50px;padding:10px;border-width:1px 1px 0 1px;border-style:solid}.input_search{height:100%;width:100%;border-radius:3px;border-width:1px;border-style:solid;padding:0 14px;font-size:12px;outline:none;border-color:#d1d5d9;border-color:rgba(var(--pv-color-grey_3-rgb), 1);color:#2a3134;color:rgba(var(--pv-color-dark-rgb), 1)}.input_search::-webkit-input-placeholder{color:#d1d5d9;color:rgba(var(--pv-color-grey_3-rgb), 1)}.input_search::-moz-placeholder{color:#d1d5d9;color:rgba(var(--pv-color-grey_3-rgb), 1)}.input_search:-ms-input-placeholder{color:#d1d5d9;color:rgba(var(--pv-color-grey_3-rgb), 1)}.input_search::-ms-input-placeholder{color:#d1d5d9;color:rgba(var(--pv-color-grey_3-rgb), 1)}.input_search::placeholder{color:#d1d5d9;color:rgba(var(--pv-color-grey_3-rgb), 1)}.loading_container{position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(42, 49, 52, 0.3);background:rgba(var(--pv-color-dark-rgb), 0.3);display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.align_center{text-align:center}@media (hover: hover){table tbody tr:not(.expanded_summary):hover{background-color:rgba(53, 132, 247, 0.04);background-color:rgba(var(--pv-color-primary-rgb), 0.04)}}@media (max-width: 900px){table,tbody,tr,td{display:block}thead{display:none}tr{padding:0 15px;border-width:1px;border-style:solid}tr:not(:first-child){margin-top:-1px}tr:not(.expanded_summary) td:first-child{border:none !important}table td{padding-left:0;padding-right:0;border-width:1px 0 0 0 !important;border-color:rgba(209, 213, 217, 0.5);border-color:rgba(var(--pv-color-grey_3-rgb), 0.5)}table tr.expanded_summary td{padding:15px 0}.mobile_title{display:inline-block;width:90px;vertical-align:middle}.modal_title{padding:17px 60px 17px 15px}.content{display:inline-block;width:calc(100% - 90px);vertical-align:middle;text-align:left}.expanded_summary{border-top-color:transparent;padding-bottom:10px}.expanded_summary td:before{content:none}.status_wrapper{height:266px;display:table-cell}.search_section{height:60px;padding:15px}.align_center{text-align:inherit}}";
11
11
 
@@ -1,9 +1,9 @@
1
1
  /*!
2
2
  * © Peculiar Ventures https://peculiarventures.com/ - MIT License
3
3
  */
4
- import { A as AsnData, e as certificateRawToBuffer, C as Certificate, N as Name, E as Extension, f as AsnConvert, g as id_ecPublicKey, h as ECParameters, j as id_rsaEncryption, R as RSAPublicKey, k as id_composite_key, l as CompositePublicKey, m as id_alg_composite, n as CompositeSignatureValue, o as CompositeParams, p as hexFormat, q as base64Format, r as getCertificateThumbprint } from './certification_request-8cc9d070.js';
5
- import { b as build, D as Download } from './download-67ac9120.js';
6
- import { d as dateDiff } from './l10n-a68d5748.js';
4
+ import { A as AsnData, e as certificateRawToBuffer, C as Certificate, N as Name, E as Extension, f as AsnConvert, g as id_ecPublicKey, h as ECParameters, j as id_rsaEncryption, R as RSAPublicKey, k as id_composite_key, l as CompositePublicKey, m as id_alg_composite, n as CompositeSignatureValue, o as CompositeParams, p as hexFormat, q as base64Format, r as getCertificateThumbprint } from './certification_request-db83dd19.js';
5
+ import { b as build, D as Download } from './download-91511aeb.js';
6
+ import { d as dateDiff } from './l10n-d48f35ff.js';
7
7
 
8
8
  /**
9
9
  * @license
@@ -93,7 +93,7 @@ class X509Certificate extends AsnData {
93
93
  try {
94
94
  const thumbprint = await getCertificateThumbprint(algorithm, this.raw);
95
95
  if (thumbprint) {
96
- this.thumbprints[algorithm['name'] || algorithm] = build.Convert.ToHex(thumbprint);
96
+ this.thumbprints[algorithm] = build.Convert.ToHex(thumbprint);
97
97
  }
98
98
  }
99
99
  catch (error) {
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * © Peculiar Ventures https://peculiarventures.com/ - MIT License
3
3
  */
4
- export{D as Download,d as downloadFromBuffer}from"./p-cff9655c.js";
4
+ export{D as Download,d as downloadFromBuffer}from"./p-711b4e1e.js";