@jsenv/https-local 3.2.0 → 3.2.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jsenv/https-local",
3
- "version": "3.2.0",
3
+ "version": "3.2.2",
4
4
  "description": "A programmatic way to generate locally trusted certificates",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -27,7 +27,6 @@
27
27
  "/src/"
28
28
  ],
29
29
  "scripts": {
30
- "test": "node ./scripts/test/test.mjs",
31
30
  "performance": "node --expose-gc ./scripts/performance/performance.mjs --local --log",
32
31
  "test:start-node-server": "node ./scripts/certificate/start_node_server.mjs",
33
32
  "ca:install": "node ./scripts/certificate/install_ca.mjs",
@@ -41,7 +40,7 @@
41
40
  "hosts:ensure-localhost-mappings": "node ./scripts/hosts/ensure_localhost_mappings.mjs"
42
41
  },
43
42
  "dependencies": {
44
- "@jsenv/filesystem": "4.10.2",
43
+ "@jsenv/filesystem": "4.10.3",
45
44
  "@jsenv/humanize": "1.2.8",
46
45
  "@jsenv/urls": "2.5.2",
47
46
  "command-exists": "1.2.9",
@@ -326,13 +326,13 @@ export const uninstallCertificateAuthority = async ({
326
326
  const rootCertificateCommonName = attributeDescriptionFromAttributeArray(
327
327
  rootCertificateForgeObject.subject.attributes,
328
328
  ).commonName;
329
- const { removeCertificateFromTrustStores } =
330
- await importPlatformMethods();
331
- await removeCertificateFromTrustStores({
329
+ const platformMethods = await importPlatformMethods();
330
+ await platformMethods.executeTrustQuery({
332
331
  logger,
333
- certificate: rootCertificate,
334
- certificateFileUrl: rootCertificateFileInfo.url,
335
332
  certificateCommonName: rootCertificateCommonName,
333
+ certificateFileUrl: rootCertificateFileInfo.url,
334
+ certificate: rootCertificate,
335
+ verb: "REMOVE_TRUST",
336
336
  });
337
337
  }
338
338
  filesToRemove.push(rootCertificateFileInfo.url);
@@ -58,10 +58,10 @@ const commandHandlers = {
58
58
  tryToUpdatesHostsFile: true,
59
59
  });
60
60
  },
61
- install: async ({ tryToTrust }) => {
61
+ install: async ({ trust }) => {
62
62
  await installCertificateAuthority({
63
- tryToTrust,
64
- NSSDynamicInstall: tryToTrust,
63
+ tryToTrust: trust,
64
+ NSSDynamicInstall: trust,
65
65
  });
66
66
  },
67
67
  uninstall: async () => {