@peculiar/certificates-viewer 3.7.0 → 3.8.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.
- package/dist/cjs/{certification_request-00bbfbc5.js → certification_request-6eb7ef37.js} +438 -428
- package/dist/cjs/{crl-de4e196b.js → crl-75106e2e.js} +1 -1
- package/dist/cjs/{miscellaneous-30c4aded.js → miscellaneous-0eade914.js} +203 -57
- package/dist/cjs/peculiar-attribute-certificate-viewer_3.cjs.entry.js +3 -3
- package/dist/cjs/peculiar-certificate-decoder.cjs.entry.js +3 -3
- package/dist/cjs/peculiar-certificate-viewer.cjs.entry.js +3 -3
- package/dist/cjs/peculiar-certificates-viewer.cjs.entry.js +2 -2
- package/dist/cjs/{x509_certificate-2af9b990.js → x509_certificate-9e7652cf.js} +1 -1
- package/dist/collection/components/certificate-details-parts/extensions/biometric_syntax_extension.js +10 -9
- package/dist/collection/components/certificate-details-parts/extensions/certificate_policies_extension.js +24 -24
- package/dist/collection/components/certificate-details-parts/extensions/certificate_transparency_extension.js +11 -10
- package/dist/collection/components/certificate-details-parts/extensions/extended_key_usage_extension.js +6 -2
- package/dist/collection/components/certificate-details-parts/extensions/info_access_syntax_extension.js +7 -6
- package/dist/collection/components/certificate-details-parts/extensions/qc_statements_extension.js +37 -6
- package/dist/collection/components/certificate-details-parts/extensions/subject_directory_attributes_extension.js +7 -6
- package/dist/collection/constants/oids.js +14 -13
- package/dist/esm/{certification_request-8cc9d070.js → certification_request-4adeae0c.js} +18 -14
- package/dist/esm/{crl-f43a95b7.js → crl-2857d300.js} +1 -1
- package/dist/esm/{miscellaneous-b74d9eae.js → miscellaneous-91256fd3.js} +203 -57
- package/dist/esm/peculiar-attribute-certificate-viewer_3.entry.js +3 -3
- package/dist/esm/peculiar-certificate-decoder.entry.js +3 -3
- package/dist/esm/peculiar-certificate-viewer.entry.js +3 -3
- package/dist/esm/peculiar-certificates-viewer.entry.js +2 -2
- package/dist/esm/{x509_certificate-0fdd28aa.js → x509_certificate-e7b4d8d1.js} +1 -1
- package/dist/peculiar/{p-ec8787ed.js → p-05f4713f.js} +2 -2
- package/dist/peculiar/{p-4e9318fb.entry.js → p-22d8ae9c.entry.js} +1 -1
- package/dist/peculiar/{p-167fd2db.entry.js → p-40808c02.entry.js} +1 -1
- package/dist/peculiar/{p-05337212.entry.js → p-5fb5f008.entry.js} +1 -1
- package/dist/peculiar/p-77121cf7.js +69 -0
- package/dist/peculiar/{p-0868020d.entry.js → p-7de0bfb3.entry.js} +1 -1
- package/dist/peculiar/{p-c72f8e8f.js → p-b44dc7c9.js} +5 -5
- package/dist/peculiar/{p-ea9a6317.js → p-e7518804.js} +2 -2
- package/dist/peculiar/peculiar.esm.js +1 -1
- package/dist/types/constants/oids.d.ts +1 -0
- package/package.json +3 -2
- package/dist/peculiar/p-45336b4f.js +0 -69
|
@@ -10,14 +10,15 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import { h } from '@stencil/core';
|
|
12
12
|
import { getStringByOID } from '../../../utils';
|
|
13
|
-
import { RowValue } from '../row';
|
|
13
|
+
import { RowValue, TableRowTable } from '../row';
|
|
14
14
|
import { BasicExtension } from './basic_extension';
|
|
15
15
|
import { getAttributeValue } from './attribute_value';
|
|
16
16
|
export const SubjectDirectoryAttributesExtension = (props) => {
|
|
17
17
|
const { extension } = props;
|
|
18
|
-
return (h(BasicExtension, { extension: extension }, extension.value.
|
|
19
|
-
h(RowValue, { name:
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
18
|
+
return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
|
|
19
|
+
h(RowValue, { name: "Attributes:", value: "" }),
|
|
20
|
+
extension.value.map((attribute) => (h(TableRowTable, null,
|
|
21
|
+
h(RowValue, { name: "Type", value: getStringByOID(attribute.type) }),
|
|
22
|
+
h(RowValue, { name: "Value", value: getAttributeValue(attribute) })))),
|
|
23
|
+
])));
|
|
23
24
|
};
|
|
@@ -309,17 +309,18 @@ export const OIDs = {
|
|
|
309
309
|
'0.4.0.127.0.7.3.1.6': 'Bsi List Content Description',
|
|
310
310
|
'0.4.0.127.0.7.3.2.1': 'Bsi Security Object',
|
|
311
311
|
'0.4.0.127.0.7.3.2.2': 'Bsi Black List',
|
|
312
|
-
'0.4.0.1862': '
|
|
313
|
-
'0.4.0.1862.1': '
|
|
314
|
-
'0.4.0.1862.1.1': '
|
|
315
|
-
'0.4.0.1862.1.2': '
|
|
316
|
-
'0.4.0.1862.1.3': '
|
|
317
|
-
'0.4.0.1862.1.4': '
|
|
318
|
-
'0.4.0.1862.1.5': '
|
|
319
|
-
'0.4.0.1862.1.6': '
|
|
320
|
-
'0.4.0.1862.1.6.1': '
|
|
321
|
-
'0.4.0.1862.1.6.2': '
|
|
322
|
-
'0.4.0.1862.1.6.3': '
|
|
312
|
+
'0.4.0.1862': 'ETSI QCS Profile',
|
|
313
|
+
'0.4.0.1862.1': 'ETSI QCS',
|
|
314
|
+
'0.4.0.1862.1.1': 'ETSI QCS Compliance',
|
|
315
|
+
'0.4.0.1862.1.2': 'ETSI QCS Limit Value',
|
|
316
|
+
'0.4.0.1862.1.3': 'ETSI QCS Retention Period',
|
|
317
|
+
'0.4.0.1862.1.4': 'ETSI QCS SSCD',
|
|
318
|
+
'0.4.0.1862.1.5': 'ETSI QCS PDS',
|
|
319
|
+
'0.4.0.1862.1.6': 'ETSI QC Type',
|
|
320
|
+
'0.4.0.1862.1.6.1': 'ETSI QC Type eSign',
|
|
321
|
+
'0.4.0.1862.1.6.2': 'ETSI QC Type eSeal',
|
|
322
|
+
'0.4.0.1862.1.6.3': 'ETSI QC Type Web',
|
|
323
|
+
'0.4.0.194121.1.2': 'ETSI QCS Semantics ID Legal',
|
|
323
324
|
'0.4.0.194112.1.0': 'QCP Natural Person',
|
|
324
325
|
'0.4.0.194112.1.1': 'QCP Legal Person',
|
|
325
326
|
'0.4.0.194112.1.2': 'QCP Natural QSCD',
|
|
@@ -1335,8 +1336,8 @@ export const OIDs = {
|
|
|
1335
1336
|
'1.3.6.1.5.5.7.10.5': 'Role',
|
|
1336
1337
|
'1.3.6.1.5.5.7.10.6': 'Wlan SSID',
|
|
1337
1338
|
'1.3.6.1.5.5.7.11': 'Personal Data',
|
|
1338
|
-
'1.3.6.1.5.5.7.11.1': '
|
|
1339
|
-
'1.3.6.1.5.5.7.11.2': '
|
|
1339
|
+
'1.3.6.1.5.5.7.11.1': 'PKIX QC Syntax V1',
|
|
1340
|
+
'1.3.6.1.5.5.7.11.2': 'PKIX QC Syntax V2',
|
|
1340
1341
|
'1.3.6.1.5.5.7.14.2': 'Resource Certificate Policy',
|
|
1341
1342
|
'1.3.6.1.5.5.7.20': 'Logo',
|
|
1342
1343
|
'1.3.6.1.5.5.7.20.1': 'Logo Loyalty',
|
|
@@ -342,17 +342,18 @@ const OIDs = {
|
|
|
342
342
|
'0.4.0.127.0.7.3.1.6': 'Bsi List Content Description',
|
|
343
343
|
'0.4.0.127.0.7.3.2.1': 'Bsi Security Object',
|
|
344
344
|
'0.4.0.127.0.7.3.2.2': 'Bsi Black List',
|
|
345
|
-
'0.4.0.1862': '
|
|
346
|
-
'0.4.0.1862.1': '
|
|
347
|
-
'0.4.0.1862.1.1': '
|
|
348
|
-
'0.4.0.1862.1.2': '
|
|
349
|
-
'0.4.0.1862.1.3': '
|
|
350
|
-
'0.4.0.1862.1.4': '
|
|
351
|
-
'0.4.0.1862.1.5': '
|
|
352
|
-
'0.4.0.1862.1.6': '
|
|
353
|
-
'0.4.0.1862.1.6.1': '
|
|
354
|
-
'0.4.0.1862.1.6.2': '
|
|
355
|
-
'0.4.0.1862.1.6.3': '
|
|
345
|
+
'0.4.0.1862': 'ETSI QCS Profile',
|
|
346
|
+
'0.4.0.1862.1': 'ETSI QCS',
|
|
347
|
+
'0.4.0.1862.1.1': 'ETSI QCS Compliance',
|
|
348
|
+
'0.4.0.1862.1.2': 'ETSI QCS Limit Value',
|
|
349
|
+
'0.4.0.1862.1.3': 'ETSI QCS Retention Period',
|
|
350
|
+
'0.4.0.1862.1.4': 'ETSI QCS SSCD',
|
|
351
|
+
'0.4.0.1862.1.5': 'ETSI QCS PDS',
|
|
352
|
+
'0.4.0.1862.1.6': 'ETSI QC Type',
|
|
353
|
+
'0.4.0.1862.1.6.1': 'ETSI QC Type eSign',
|
|
354
|
+
'0.4.0.1862.1.6.2': 'ETSI QC Type eSeal',
|
|
355
|
+
'0.4.0.1862.1.6.3': 'ETSI QC Type Web',
|
|
356
|
+
'0.4.0.194121.1.2': 'ETSI QCS Semantics ID Legal',
|
|
356
357
|
'0.4.0.194112.1.0': 'QCP Natural Person',
|
|
357
358
|
'0.4.0.194112.1.1': 'QCP Legal Person',
|
|
358
359
|
'0.4.0.194112.1.2': 'QCP Natural QSCD',
|
|
@@ -1368,8 +1369,8 @@ const OIDs = {
|
|
|
1368
1369
|
'1.3.6.1.5.5.7.10.5': 'Role',
|
|
1369
1370
|
'1.3.6.1.5.5.7.10.6': 'Wlan SSID',
|
|
1370
1371
|
'1.3.6.1.5.5.7.11': 'Personal Data',
|
|
1371
|
-
'1.3.6.1.5.5.7.11.1': '
|
|
1372
|
-
'1.3.6.1.5.5.7.11.2': '
|
|
1372
|
+
'1.3.6.1.5.5.7.11.1': 'PKIX QC Syntax V1',
|
|
1373
|
+
'1.3.6.1.5.5.7.11.2': 'PKIX QC Syntax V2',
|
|
1373
1374
|
'1.3.6.1.5.5.7.14.2': 'Resource Certificate Policy',
|
|
1374
1375
|
'1.3.6.1.5.5.7.20': 'Logo',
|
|
1375
1376
|
'1.3.6.1.5.5.7.20.1': 'Logo Loyalty',
|
|
@@ -9141,6 +9142,8 @@ BiometricSyntax = BiometricSyntax_1 = __decorate([
|
|
|
9141
9142
|
AsnType({ type: AsnTypeTypes.Sequence, itemType: BiometricData })
|
|
9142
9143
|
], BiometricSyntax);
|
|
9143
9144
|
|
|
9145
|
+
const id_qcs = `${id_pkix$1}.11`;
|
|
9146
|
+
|
|
9144
9147
|
var NameRegistrationAuthorities_1, QCStatements_1;
|
|
9145
9148
|
const id_pe_qcStatements = `${id_pe$1}.3`;
|
|
9146
9149
|
class QCStatement {
|
|
@@ -9155,6 +9158,7 @@ __decorate([
|
|
|
9155
9158
|
__decorate([
|
|
9156
9159
|
AsnProp({ type: AsnPropTypes.Any, optional: true })
|
|
9157
9160
|
], QCStatement.prototype, "statementInfo", void 0);
|
|
9161
|
+
const id_qcs_pkixQCSyntax_v2 = `${id_qcs}.2`;
|
|
9158
9162
|
let NameRegistrationAuthorities = NameRegistrationAuthorities_1 = class NameRegistrationAuthorities extends AsnArray {
|
|
9159
9163
|
constructor(items) {
|
|
9160
9164
|
super(items);
|
|
@@ -12019,4 +12023,4 @@ __decorate([
|
|
|
12019
12023
|
AsnProp({ type: AsnPropTypes.BitString })
|
|
12020
12024
|
], CertificationRequest.prototype, "signature", void 0);
|
|
12021
12025
|
|
|
12022
|
-
export { Name$1 as $, AsnData as A, id_InsuranceValue as B, Certificate as C, id_WebGDPR as D, Extension as E, id_ActivityDescription as F, ActivityDescription as G, id_TypeRelationship as H, InsuranceValue as I, id_DomainNameTechnicalOperator as J, DomainNameTechnicalOperator as K, id_DomainNameOwner as L, DomainNameOwner as M, Name as N, id_DomainNameLegalRepresentative as O, DomainNameLegalRepresentative as P, id_DomainNameBeneficiary as Q, RSAPublicKey as R, DomainNameBeneficiary as S, TypeRelationship as T, UnstructuredName as U, ValuationRanking as V, WebGDPR as W, AttributeCertificate as X, CertificationRequest as Y, CertificateList as Z, OIDs as _, isX509Pem as a, CRLReason as a0, InvalidityDate as a1, CertificateIssuer as a2, OtherName as a3, DisplayText as a4, UserNotice as a5, EDIPartyName as a6,
|
|
12026
|
+
export { Name$1 as $, AsnData as A, id_InsuranceValue as B, Certificate as C, id_WebGDPR as D, Extension as E, id_ActivityDescription as F, ActivityDescription as G, id_TypeRelationship as H, InsuranceValue as I, id_DomainNameTechnicalOperator as J, DomainNameTechnicalOperator as K, id_DomainNameOwner as L, DomainNameOwner as M, Name as N, id_DomainNameLegalRepresentative as O, DomainNameLegalRepresentative as P, id_DomainNameBeneficiary as Q, RSAPublicKey as R, DomainNameBeneficiary as S, TypeRelationship as T, UnstructuredName as U, ValuationRanking as V, WebGDPR as W, AttributeCertificate as X, CertificationRequest as Y, CertificateList as Z, OIDs as _, isX509Pem as a, CRLReason as a0, InvalidityDate as a1, CertificateIssuer as a2, OtherName as a3, DisplayText as a4, UserNotice as a5, EDIPartyName as a6, __decorate as a7, AsnProp as a8, AsnPropTypes as a9, Timestamp as aA, ArchiveRevInfo as aB, SubjectDirectoryAttributes as aC, PrivateKeyUsagePeriod as aD, EntrustVersionInfo as aE, BiometricSyntax as aF, LogotypeExtn as aG, TNAuthorizationList as aH, PolicyConstraints as aI, PolicyMappings as aJ, CRLNumber as aK, IssuingDistributionPoint as aL, AsnType as aa, AsnTypeTypes as ab, AsnArray as ac, id_qcs_pkixQCSyntax_v2 as ad, SemanticsInformation as ae, AsnIntegerArrayBufferConverter as af, KeyUsage as ag, BasicConstraints as ah, ExtendedKeyUsage as ai, SubjectKeyIdentifier as aj, AuthorityKeyIdentifier as ak, CRLDistributionPoints as al, AuthorityInfoAccessSyntax as am, SubjectInfoAccessSyntax as an, SubjectAlternativeName as ao, CertificatePolicies as ap, CertificateTransparency as aq, NameConstraints as ar, CertificateTemplate as as, EnrollCertTypeChoice as at, CaVersion as au, QCStatements as av, NetscapeComment as aw, NetscapeCertType as ax, LeiRole as ay, LeiChoice as az, isPkcs10Pem as b, isX509AttributePem as c, isX509CRLPem as d, certificateRawToBuffer as e, AsnConvert as f, id_ecPublicKey as g, ECParameters as h, isPem as i, id_rsaEncryption as j, id_composite_key as k, CompositePublicKey as l, id_alg_composite as m, CompositeSignatureValue as n, CompositeParams as o, hexFormat as p, base64Format as q, getCertificateThumbprint as r, Attribute$1 as s, id_pkcs9_at_extensionRequest as t, AsnParser as u, ExtensionRequest as v, id_pkcs9_at_unstructuredName as w, id_pkcs9_at_challengePassword as x, ChallengePassword as y, id_ValuationRanking as z };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* © Peculiar Ventures https://peculiarventures.com/ - MIT License
|
|
3
3
|
*/
|
|
4
|
-
import { A as AsnData, s as Attribute$1, t as id_pkcs9_at_extensionRequest, u as AsnParser, v as ExtensionRequest, E as Extension, f as AsnConvert, w as id_pkcs9_at_unstructuredName, U as UnstructuredName, x as id_pkcs9_at_challengePassword, y as ChallengePassword, z as id_ValuationRanking, V as ValuationRanking, B as id_InsuranceValue, I as InsuranceValue, D as id_WebGDPR, W as WebGDPR, F as id_ActivityDescription, G as ActivityDescription, H as id_TypeRelationship, T as TypeRelationship, J as id_DomainNameTechnicalOperator, K as DomainNameTechnicalOperator, L as id_DomainNameOwner, M as DomainNameOwner, O as id_DomainNameLegalRepresentative, P as DomainNameLegalRepresentative, Q as id_DomainNameBeneficiary, S as DomainNameBeneficiary, e as certificateRawToBuffer, X as AttributeCertificate, r as getCertificateThumbprint, p as hexFormat, q as base64Format, Y as CertificationRequest, N as Name, g as id_ecPublicKey, h as ECParameters, j as id_rsaEncryption, R as RSAPublicKey, Z as CertificateList } from './certification_request-
|
|
4
|
+
import { A as AsnData, s as Attribute$1, t as id_pkcs9_at_extensionRequest, u as AsnParser, v as ExtensionRequest, E as Extension, f as AsnConvert, w as id_pkcs9_at_unstructuredName, U as UnstructuredName, x as id_pkcs9_at_challengePassword, y as ChallengePassword, z as id_ValuationRanking, V as ValuationRanking, B as id_InsuranceValue, I as InsuranceValue, D as id_WebGDPR, W as WebGDPR, F as id_ActivityDescription, G as ActivityDescription, H as id_TypeRelationship, T as TypeRelationship, J as id_DomainNameTechnicalOperator, K as DomainNameTechnicalOperator, L as id_DomainNameOwner, M as DomainNameOwner, O as id_DomainNameLegalRepresentative, P as DomainNameLegalRepresentative, Q as id_DomainNameBeneficiary, S as DomainNameBeneficiary, e as certificateRawToBuffer, X as AttributeCertificate, r as getCertificateThumbprint, p as hexFormat, q as base64Format, Y as CertificationRequest, N as Name, g as id_ecPublicKey, h as ECParameters, j as id_rsaEncryption, R as RSAPublicKey, Z as CertificateList } from './certification_request-4adeae0c.js';
|
|
5
5
|
import { b as build, D as Download } from './download-67ac9120.js';
|
|
6
6
|
import { d as dateDiff } from './l10n-a68d5748.js';
|
|
7
7
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
import { h } from './index-bbd484d9.js';
|
|
5
5
|
import { l as l10n, a as dateShort } from './l10n-a68d5748.js';
|
|
6
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
|
|
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-4adeae0c.js';
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* @license
|
|
@@ -294,7 +294,11 @@ const BasicConstraintsExtension = (props) => {
|
|
|
294
294
|
*/
|
|
295
295
|
const ExtendedKeyUsageExtension = (props) => {
|
|
296
296
|
const { extension } = props;
|
|
297
|
-
return (h(BasicExtension, { extension: extension }, extension.value.
|
|
297
|
+
return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
|
|
298
|
+
h(RowValue, { name: "Purposes:", value: "" }),
|
|
299
|
+
extension.value.map((usage) => (h(TableRowTable, null,
|
|
300
|
+
h(RowValue, { name: "Purpose", value: getStringByOID(usage) })))),
|
|
301
|
+
])));
|
|
298
302
|
};
|
|
299
303
|
|
|
300
304
|
/**
|
|
@@ -440,11 +444,12 @@ const CRLDistributionPointsExtension = (props) => {
|
|
|
440
444
|
*/
|
|
441
445
|
const InfoAccessSyntaxExtension = (props) => {
|
|
442
446
|
const { extension } = props;
|
|
443
|
-
return (h(BasicExtension, { extension: extension }, extension.value.
|
|
444
|
-
h(RowValue, { name:
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
447
|
+
return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
|
|
448
|
+
h(RowValue, { name: "Descriptions:", value: "" }),
|
|
449
|
+
extension.value.map((description) => (h(TableRowTable, null,
|
|
450
|
+
h(RowValue, { name: "Method", value: getStringByOID(description.accessMethod) }),
|
|
451
|
+
h(GeneralNamePart, Object.assign({ generalName: description.accessLocation }, props))))),
|
|
452
|
+
])));
|
|
448
453
|
};
|
|
449
454
|
|
|
450
455
|
/**
|
|
@@ -468,30 +473,30 @@ const SubjectAlternativeNameExtension = (props) => {
|
|
|
468
473
|
*/
|
|
469
474
|
const CertificatePoliciesExtension = (props) => {
|
|
470
475
|
const { extension } = props;
|
|
471
|
-
return (h(BasicExtension, { extension: extension }, extension.value.
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
h(RowValue, { name:
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
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() }));
|
|
476
|
+
return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
|
|
477
|
+
h(RowValue, { name: "Policies:", value: "" }),
|
|
478
|
+
extension.value.map((policy) => (h(TableRowTable, null,
|
|
479
|
+
h(RowValue, { name: "Policy ID", value: getStringByOID(policy.policyIdentifier) }),
|
|
480
|
+
policy.policyQualifiers && Boolean(policy.policyQualifiers.length) && ([
|
|
481
|
+
h(RowValue, { name: "Qualifiers:", value: "" }),
|
|
482
|
+
policy.policyQualifiers.map((qualifierInfo) => {
|
|
483
|
+
const data = [
|
|
484
|
+
h(RowValue, { name: "Qualifier ID", value: getStringByOID(qualifierInfo.policyQualifierId) }),
|
|
485
|
+
];
|
|
486
|
+
if (qualifierInfo.policyQualifierId === '1.3.6.1.5.5.7.2.1') {
|
|
487
|
+
const value = AsnParser.parse(qualifierInfo.qualifier, DisplayText);
|
|
488
|
+
data.push(h(RowValue, { name: "Value", value: value.toString() }));
|
|
489
489
|
}
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
490
|
+
if (qualifierInfo.policyQualifierId === '1.3.6.1.5.5.7.2.2') {
|
|
491
|
+
const value = AsnParser.parse(qualifierInfo.qualifier, UserNotice);
|
|
492
|
+
if (value.explicitText) {
|
|
493
|
+
data.push(h(RowValue, { name: "Value", value: value.explicitText.toString() }));
|
|
494
|
+
}
|
|
495
|
+
}
|
|
496
|
+
return (h(TableRowTable, null, data));
|
|
497
|
+
}),
|
|
498
|
+
])))),
|
|
499
|
+
])));
|
|
495
500
|
};
|
|
496
501
|
|
|
497
502
|
/**
|
|
@@ -589,15 +594,16 @@ const logs = {
|
|
|
589
594
|
*/
|
|
590
595
|
const CertificateTransparencyExtension = (props) => {
|
|
591
596
|
const { extension } = props;
|
|
592
|
-
return (h(BasicExtension, { extension: extension }, extension.value.
|
|
593
|
-
h(RowValue, { name:
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
597
|
+
return (h(BasicExtension, { extension: extension }, Boolean(extension.value.items.length) && ([
|
|
598
|
+
h(RowValue, { name: "Signed Certificate Timestamps:", value: "" }),
|
|
599
|
+
extension.value.toJSON().map((signedCertificateTimestamp) => (h(TableRowTable, null,
|
|
600
|
+
h(RowValue, { name: "Version", value: signedCertificateTimestamp.version + 1 }),
|
|
601
|
+
h(RowValue, { name: "Log Operator", value: logs[signedCertificateTimestamp.logId] || signedCertificateTimestamp.logId }),
|
|
602
|
+
h(RowValue, { name: "Log Key ID", value: signedCertificateTimestamp.logId, monospace: true }),
|
|
603
|
+
h(RowValue, { name: "Timestamp", value: dateShort(signedCertificateTimestamp.timestamp) }),
|
|
604
|
+
h(RowValue, { name: "Signature Algorithm", value: `${signedCertificateTimestamp.hashAlgorithm} ${signedCertificateTimestamp.signatureAlgorithm}`.toUpperCase() }),
|
|
605
|
+
h(RowValue, { name: "Signature", value: signedCertificateTimestamp.signature, monospace: true })))),
|
|
606
|
+
])));
|
|
601
607
|
};
|
|
602
608
|
|
|
603
609
|
/**
|
|
@@ -658,6 +664,116 @@ const CaVersionExtension = (props) => {
|
|
|
658
664
|
h(RowValue, { name: "Key Index", value: version.keyIndex })));
|
|
659
665
|
};
|
|
660
666
|
|
|
667
|
+
var PdsLocations_1, QcEuPDS_1, QcType_1, QcCClegislation_1;
|
|
668
|
+
let Iso4217CurrencyCode = class Iso4217CurrencyCode {
|
|
669
|
+
constructor(value) {
|
|
670
|
+
if (typeof value === "string") {
|
|
671
|
+
this.alphabetic = value;
|
|
672
|
+
}
|
|
673
|
+
else if (typeof value === "number") {
|
|
674
|
+
this.numeric = value;
|
|
675
|
+
}
|
|
676
|
+
}
|
|
677
|
+
};
|
|
678
|
+
__decorate([
|
|
679
|
+
AsnProp({ type: AsnPropTypes.PrintableString })
|
|
680
|
+
], Iso4217CurrencyCode.prototype, "alphabetic", void 0);
|
|
681
|
+
__decorate([
|
|
682
|
+
AsnProp({ type: AsnPropTypes.PrintableString })
|
|
683
|
+
], Iso4217CurrencyCode.prototype, "numeric", void 0);
|
|
684
|
+
Iso4217CurrencyCode = __decorate([
|
|
685
|
+
AsnType({ type: AsnTypeTypes.Choice })
|
|
686
|
+
], Iso4217CurrencyCode);
|
|
687
|
+
class MonetaryValue {
|
|
688
|
+
constructor(params = {}) {
|
|
689
|
+
this.currency = new Iso4217CurrencyCode();
|
|
690
|
+
this.amount = 0;
|
|
691
|
+
this.exponent = 0;
|
|
692
|
+
Object.assign(this, params);
|
|
693
|
+
}
|
|
694
|
+
}
|
|
695
|
+
__decorate([
|
|
696
|
+
AsnProp({ type: Iso4217CurrencyCode })
|
|
697
|
+
], MonetaryValue.prototype, "currency", void 0);
|
|
698
|
+
__decorate([
|
|
699
|
+
AsnProp({ type: AsnPropTypes.Integer })
|
|
700
|
+
], MonetaryValue.prototype, "amount", void 0);
|
|
701
|
+
__decorate([
|
|
702
|
+
AsnProp({ type: AsnPropTypes.Integer })
|
|
703
|
+
], MonetaryValue.prototype, "exponent", void 0);
|
|
704
|
+
let QcEuLimitValue = class QcEuLimitValue extends MonetaryValue {
|
|
705
|
+
};
|
|
706
|
+
QcEuLimitValue = __decorate([
|
|
707
|
+
AsnType({ type: AsnTypeTypes.Sequence })
|
|
708
|
+
], QcEuLimitValue);
|
|
709
|
+
let QcEuRetentionPeriod = class QcEuRetentionPeriod {
|
|
710
|
+
constructor(value = 0) {
|
|
711
|
+
this.value = value;
|
|
712
|
+
}
|
|
713
|
+
};
|
|
714
|
+
__decorate([
|
|
715
|
+
AsnProp({ type: AsnPropTypes.Integer })
|
|
716
|
+
], QcEuRetentionPeriod.prototype, "value", void 0);
|
|
717
|
+
QcEuRetentionPeriod = __decorate([
|
|
718
|
+
AsnType({ type: AsnTypeTypes.Choice })
|
|
719
|
+
], QcEuRetentionPeriod);
|
|
720
|
+
let PdsLocation = class PdsLocation {
|
|
721
|
+
constructor(params = {}) {
|
|
722
|
+
this.url = "";
|
|
723
|
+
this.language = "";
|
|
724
|
+
Object.assign(this, params);
|
|
725
|
+
}
|
|
726
|
+
};
|
|
727
|
+
__decorate([
|
|
728
|
+
AsnProp({ type: AsnPropTypes.IA5String })
|
|
729
|
+
], PdsLocation.prototype, "url", void 0);
|
|
730
|
+
__decorate([
|
|
731
|
+
AsnProp({ type: AsnPropTypes.PrintableString })
|
|
732
|
+
], PdsLocation.prototype, "language", void 0);
|
|
733
|
+
PdsLocation = __decorate([
|
|
734
|
+
AsnType({ type: AsnTypeTypes.Sequence })
|
|
735
|
+
], PdsLocation);
|
|
736
|
+
let PdsLocations = PdsLocations_1 = class PdsLocations extends AsnArray {
|
|
737
|
+
constructor(items) {
|
|
738
|
+
super(items);
|
|
739
|
+
Object.setPrototypeOf(this, PdsLocations_1.prototype);
|
|
740
|
+
}
|
|
741
|
+
};
|
|
742
|
+
PdsLocations = PdsLocations_1 = __decorate([
|
|
743
|
+
AsnType({ type: AsnTypeTypes.Sequence, itemType: PdsLocation })
|
|
744
|
+
], PdsLocations);
|
|
745
|
+
let QcEuPDS = QcEuPDS_1 = class QcEuPDS extends PdsLocations {
|
|
746
|
+
constructor(items) {
|
|
747
|
+
super(items);
|
|
748
|
+
Object.setPrototypeOf(this, QcEuPDS_1.prototype);
|
|
749
|
+
}
|
|
750
|
+
};
|
|
751
|
+
QcEuPDS = QcEuPDS_1 = __decorate([
|
|
752
|
+
AsnType({ type: AsnTypeTypes.Sequence, itemType: PdsLocation })
|
|
753
|
+
], QcEuPDS);
|
|
754
|
+
let QcType = QcType_1 = class QcType extends AsnArray {
|
|
755
|
+
constructor(items) {
|
|
756
|
+
super(items);
|
|
757
|
+
Object.setPrototypeOf(this, QcType_1.prototype);
|
|
758
|
+
}
|
|
759
|
+
};
|
|
760
|
+
QcType = QcType_1 = __decorate([
|
|
761
|
+
AsnType({ type: AsnTypeTypes.Sequence, itemType: AsnPropTypes.ObjectIdentifier })
|
|
762
|
+
], QcType);
|
|
763
|
+
let QcCClegislation = QcCClegislation_1 = class QcCClegislation extends AsnArray {
|
|
764
|
+
constructor(items) {
|
|
765
|
+
super(items);
|
|
766
|
+
Object.setPrototypeOf(this, QcCClegislation_1.prototype);
|
|
767
|
+
}
|
|
768
|
+
};
|
|
769
|
+
QcCClegislation = QcCClegislation_1 = __decorate([
|
|
770
|
+
AsnType({ type: AsnTypeTypes.Sequence, itemType: AsnPropTypes.PrintableString })
|
|
771
|
+
], QcCClegislation);
|
|
772
|
+
const id_etsi_qcs = "0.4.0.1862.1";
|
|
773
|
+
const id_etsi_qcs_qcRetentionPeriod = `${id_etsi_qcs}.3`;
|
|
774
|
+
const id_etsi_qcs_qcPDS = `${id_etsi_qcs}.5`;
|
|
775
|
+
const id_etsi_qcs_qcType = `${id_etsi_qcs}.6`;
|
|
776
|
+
|
|
661
777
|
/**
|
|
662
778
|
* @license
|
|
663
779
|
* Copyright (c) Peculiar Ventures, LLC.
|
|
@@ -667,11 +783,39 @@ const CaVersionExtension = (props) => {
|
|
|
667
783
|
*/
|
|
668
784
|
const QCStatementsExtension = (props) => {
|
|
669
785
|
const { extension } = props;
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
786
|
+
function renderStatementInfo(statementId, statementInfo) {
|
|
787
|
+
if (!statementInfo.byteLength) {
|
|
788
|
+
return null;
|
|
789
|
+
}
|
|
790
|
+
if (statementId === id_qcs_pkixQCSyntax_v2) {
|
|
791
|
+
const semanticsInformation = AsnParser.parse(statementInfo, SemanticsInformation);
|
|
792
|
+
return (h(RowValue, { name: "Semantics Identifier", value: getStringByOID(semanticsInformation.semanticsIdentifier) }));
|
|
793
|
+
}
|
|
794
|
+
if (statementId === id_etsi_qcs_qcType) {
|
|
795
|
+
const qcTypes = AsnParser.parse(statementInfo, QcType);
|
|
796
|
+
return (h(RowValue, { name: "QC Types", value: qcTypes.map((type) => getStringByOID(type)).join(', ') }));
|
|
797
|
+
}
|
|
798
|
+
if (statementId === id_etsi_qcs_qcRetentionPeriod) {
|
|
799
|
+
const retentionPeriod = AsnParser.parse(statementInfo, QcEuRetentionPeriod);
|
|
800
|
+
return (h(RowValue, { name: "Retention Period", value: `${retentionPeriod.value} years` }));
|
|
801
|
+
}
|
|
802
|
+
if (statementId === id_etsi_qcs_qcPDS) {
|
|
803
|
+
const pdsLocations = AsnParser.parse(statementInfo, PdsLocations);
|
|
804
|
+
return ([
|
|
805
|
+
h(RowValue, { name: "PDS Locations:", value: "" }),
|
|
806
|
+
pdsLocations.map((location) => (h(TableRowTable, null,
|
|
807
|
+
h(RowValue, { name: "URL", value: location.url }),
|
|
808
|
+
h(RowValue, { name: "Language", value: location.language })))),
|
|
809
|
+
]);
|
|
810
|
+
}
|
|
811
|
+
return (h(RowValue, { name: "Info", value: build.Convert.ToHex(statementInfo), monospace: true }));
|
|
812
|
+
}
|
|
813
|
+
return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
|
|
814
|
+
h(RowValue, { name: "Statements:", value: "" }),
|
|
815
|
+
extension.value.map((statement) => (h(TableRowTable, null,
|
|
816
|
+
h(RowValue, { name: "Statement ID", value: getStringByOID(statement.statementId) }),
|
|
817
|
+
renderStatementInfo(statement.statementId, statement.statementInfo)))),
|
|
818
|
+
])));
|
|
675
819
|
};
|
|
676
820
|
|
|
677
821
|
/**
|
|
@@ -787,11 +931,12 @@ function getAttributeValue(attribute) {
|
|
|
787
931
|
*/
|
|
788
932
|
const SubjectDirectoryAttributesExtension = (props) => {
|
|
789
933
|
const { extension } = props;
|
|
790
|
-
return (h(BasicExtension, { extension: extension }, extension.value.
|
|
791
|
-
h(RowValue, { name:
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
934
|
+
return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
|
|
935
|
+
h(RowValue, { name: "Attributes:", value: "" }),
|
|
936
|
+
extension.value.map((attribute) => (h(TableRowTable, null,
|
|
937
|
+
h(RowValue, { name: "Type", value: getStringByOID(attribute.type) }),
|
|
938
|
+
h(RowValue, { name: "Value", value: getAttributeValue(attribute) })))),
|
|
939
|
+
])));
|
|
795
940
|
};
|
|
796
941
|
|
|
797
942
|
/**
|
|
@@ -844,14 +989,15 @@ const EntrustVersionInfoExtension = (props) => {
|
|
|
844
989
|
*/
|
|
845
990
|
const BiometricSyntaxExtension = (props) => {
|
|
846
991
|
const { extension } = props;
|
|
847
|
-
return (h(BasicExtension, { extension: extension }, extension.value.
|
|
848
|
-
h(RowValue, { name:
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
992
|
+
return (h(BasicExtension, { extension: extension }, Boolean(extension.value.length) && ([
|
|
993
|
+
h(RowValue, { name: "Biometrics:", value: "" }),
|
|
994
|
+
extension.value.map((data) => (h(TableRowTable, null,
|
|
995
|
+
h(RowValue, { name: "OID", value: getStringByOID(data.typeOfBiometricData.biometricDataOid) }),
|
|
996
|
+
h(RowValue, { name: "Type", value: data.typeOfBiometricData.predefinedBiometricType }),
|
|
997
|
+
h(RowValue, { name: "Algorithm", value: getStringByOID(data.hashAlgorithm.algorithm) }),
|
|
998
|
+
h(RowValue, { name: "Hash", value: build.Convert.ToHex(data.biometricDataHash.buffer), monospace: true }),
|
|
999
|
+
h(RowValue, { name: "Source Uri", value: data.sourceDataUri })))),
|
|
1000
|
+
])));
|
|
855
1001
|
};
|
|
856
1002
|
|
|
857
1003
|
/**
|
|
@@ -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-
|
|
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-4adeae0c.js';
|
|
6
6
|
import { b as build } from './download-67ac9120.js';
|
|
7
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-
|
|
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-
|
|
8
|
+
import { X as X509AttributeCertificate, a as CRL, C as CSR } from './crl-2857d300.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-91256fd3.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, 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-
|
|
5
|
+
import { i as isPem, a as isX509Pem, b as isPkcs10Pem, c as isX509AttributePem, d as isX509CRLPem } from './certification_request-4adeae0c.js';
|
|
6
6
|
import './l10n-a68d5748.js';
|
|
7
7
|
import './download-67ac9120.js';
|
|
8
|
-
import { X as X509Certificate } from './x509_certificate-
|
|
9
|
-
import { X as X509AttributeCertificate, C as CSR, a as CRL } from './crl-
|
|
8
|
+
import { X as X509Certificate } from './x509_certificate-e7b4d8d1.js';
|
|
9
|
+
import { X as X509AttributeCertificate, C as CSR, a as CRL } from './crl-2857d300.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-
|
|
6
|
-
import './certification_request-
|
|
5
|
+
import { X as X509Certificate } from './x509_certificate-e7b4d8d1.js';
|
|
6
|
+
import './certification_request-4adeae0c.js';
|
|
7
7
|
import './download-67ac9120.js';
|
|
8
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-
|
|
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-91256fd3.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,8 +2,8 @@
|
|
|
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-
|
|
6
|
-
import { _ as OIDs } from './certification_request-
|
|
5
|
+
import { X as X509Certificate } from './x509_certificate-e7b4d8d1.js';
|
|
6
|
+
import { _ as OIDs } from './certification_request-4adeae0c.js';
|
|
7
7
|
import './download-67ac9120.js';
|
|
8
8
|
import { l as l10n } from './l10n-a68d5748.js';
|
|
9
9
|
|
|
@@ -1,7 +1,7 @@
|
|
|
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-
|
|
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-4adeae0c.js';
|
|
5
5
|
import { b as build, D as Download } from './download-67ac9120.js';
|
|
6
6
|
import { d as dateDiff } from './l10n-a68d5748.js';
|
|
7
7
|
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* © Peculiar Ventures https://peculiarventures.com/ - MIT License
|
|
3
3
|
*/
|
|
4
|
-
import{A as t,e as s,C as r,N as e,E as i,f as n,g as o,h as a,j as h,R as u,k as c,l as
|
|
4
|
+
import{A as t,e as s,C as r,N as e,E as i,f as n,g as o,h as a,j as h,R as u,k as c,l as m,m as f,n as l,o as g,p,q as E,r as b}from"./p-b44dc7c9.js";import{b as C,D as A}from"./p-cff9655c.js";import{d}from"./p-fec9d812.js";
|
|
5
5
|
/**
|
|
6
6
|
* @license
|
|
7
7
|
* Copyright (c) Peculiar Ventures, LLC.
|
|
8
8
|
*
|
|
9
9
|
* This source code is licensed under the MIT license found in the
|
|
10
10
|
* LICENSE file in the root directory of this source tree.
|
|
11
|
-
*/class
|
|
11
|
+
*/class w extends t{constructor(t){super(s(t),r),this.thumbprints={},this.type="X.509 Certificate";const{tbsCertificate:i}=this.asn;this.serialNumber=C.Convert.ToHex(i.serialNumber),this.subject=new e(i.subject).toJSON(),this.issuer=new e(i.issuer).toJSON(),this.version=i.version+1;const n=i.validity.notBefore.utcTime||i.validity.notBefore.generalTime;if(!n)throw new Error("Cannot get 'notBefore' value");this.notBefore=n;const o=i.validity.notAfter.utcTime||i.validity.notAfter.generalTime;if(!o)throw new Error("Cannot get 'notAfter' value");this.notAfter=o,this.validity=d(this.notBefore,this.notAfter)}parseExtensions(){const{tbsCertificate:t}=this.asn;t.extensions&&(this.extensions=t.extensions.map((t=>new i(n.serialize(t)))))}getPublicKeyInfo(t){const{subjectPublicKey:s,algorithm:r}=t;let e;return r.algorithm===o&&r.parameters&&(e=n.parse(r.parameters,a)),r.algorithm===h&&(e=n.parse(s,u)),r.algorithm===c&&(e=n.parse(s,m),e=e.map((t=>this.getPublicKeyInfo(t)))),{params:e,value:n.serialize(t),algorithm:r.algorithm}}get publicKey(){return this.getPublicKeyInfo(this.asn.tbsCertificate.subjectPublicKeyInfo)}get signature(){const{signatureValue:t,signatureAlgorithm:s}=this.asn;let r;if(s.algorithm===f){const e=n.parse(t,l);r=n.parse(s.parameters,g).map(((t,s)=>Object.assign(Object.assign({},t),{value:e[s]})))}return{params:r,value:t,algorithm:s.algorithm}}exportAsBase64(){return C.Convert.ToBase64(this.raw)}exportAsHexFormatted(){return p(C.Convert.ToHex(this.raw))}exportAsPemFormatted(){return`-----BEGIN CERTIFICATE-----\n${E(this.exportAsBase64())}\n-----END CERTIFICATE-----`}async getThumbprint(t="SHA-1"){try{const s=await b(t,this.raw);s&&(this.thumbprints[t.name||t]=C.Convert.ToHex(s))}catch(t){console.error("Error thumbprint get:",t)}}get commonName(){if(!this.subject)return"";for(let t=0;t<this.subject.length;t+=1){const s=this.subject[t];if("CN"===s.shortName||"E"===s.shortName||"O"===s.shortName)return s.value}return""}get issuerCommonName(){if(!this.issuer)return"";for(let t=0;t<this.issuer.length;t+=1){const s=this.issuer[t];if("CN"===s.shortName)return s.value;if("E"===s.shortName)return s.value}return""}get isRoot(){return JSON.stringify(this.issuer)===JSON.stringify(this.subject)}subjectToString(){return this.subject?this.subject.map((t=>`${t.shortName}=${t.value}`)).join(", "):""}issuerToString(){return this.issuer?this.issuer.map((t=>`${t.shortName}=${t.value}`)).join(", "):""}downloadAsPEM(t){A.cert.asPEM(this.exportAsPemFormatted(),t||this.commonName)}downloadAsDER(t){A.cert.asDER(this.exportAsHexFormatted(),t||this.commonName)}}export{w as X}
|