Skip to content

Beautiful Open-Source Form Builder

Upgrade node-forge and retire obsolete audit exception (#1358)

Julien Nahumcd0b82241b12
diff --git a/README.md b/README.md
index a6f9ce04d..9dccd33f1 100644
--- a/README.md
+++ b/README.md
@@ -90,6 +90,8 @@ Nuxt Content uses the native `node:sqlite` connector, including on Amplify's Nod
The executable npm audit policy is in [scripts/npm-exceptions.json](scripts/npm-exceptions.json). Dependabot checks Composer, client npm packages, and GitHub Actions weekly, with up to three open version-update PRs per ecosystem. Compatible application updates are grouped; major application dependency updates remain separate except for the coordinated VueUse packages. GitHub Actions updates are grouped together. Security update handling is unchanged.
+The lock requires node-forge 1.4.1 or newer. Its former RSA-verification exception has been removed; dated exceptions for other packages remain enforced.
+
## Date fields
Clearing a date with a click, Enter, or Space keeps the calendar closed. Reopen it to choose another date.
diff --git a/client/package-lock.json b/client/package-lock.json
index 3539e3986..ebf83e837 100644
--- a/client/package-lock.json
+++ b/client/package-lock.json
@@ -16618,9 +16618,9 @@
}
},
"node_modules/node-forge": {
- "version": "1.4.0",
- "resolved": "https://registry.npmjs.org/node-forge/-/node-forge-1.4.0.tgz",
- "integrity": "sha512-LarFH0+6VfriEhqMMcLX2F7SwSXeWwnEAJEsYm5QKWchiVYVvJyV9v7UDvUv+w5HO23ZpQTXDv/GxdDdMyOuoQ==",
+ "version": "1.4.1",
+ "resolved": "https://registry.npmjs.org/node-forge/-/node-forge-1.4.1.tgz",
+ "integrity": "sha512-w5/MfWaeMrpR/5ba6fZyAUTLSuE6aYz7H/3cYrqwZEmf5eQS3IaaLgJt4MBv7HglGFWmV22K8h4U18RJQmw/ow==",
"license": "(BSD-3-Clause OR GPL-2.0)",
"engines": {
"node": ">= 6.13.0"
diff --git a/scripts/check-security-versions.mjs b/scripts/check-security-versions.mjs
index 8e5d3ecd6..718653dc5 100644
--- a/scripts/check-security-versions.mjs
+++ b/scripts/check-security-versions.mjs
@@ -23,7 +23,7 @@ for (const [name, minimum] of Object.entries({
const version = php.packages.find((pkg) => pkg.name === name)?.version
assert.ok(version && atLeast(version, minimum), `${name} must be >= ${minimum}, received ${version}`)
}
-for (const [name, minimum] of Object.entries({ nuxt: '4.6.2', '@nuxt/devtools': '3.4.4', vitest: '5.0.5', 'happy-dom': '21.0.4', katex: '0.18.2' })) {
+for (const [name, minimum] of Object.entries({ nuxt: '4.6.2', '@nuxt/devtools': '3.4.4', vitest: '5.0.5', 'happy-dom': '21.0.4', katex: '0.18.2', 'node-forge': '1.4.1' })) {
const entries = Object.entries(npm.packages).filter(([path]) => path.endsWith(`node_modules/${name}`))
assert.ok(entries.length, `Missing ${name}`)
for (const [path, pkg] of entries) {
diff --git a/scripts/npm-exceptions.json b/scripts/npm-exceptions.json
index 3fc56ce28..beeeab151 100644
--- a/scripts/npm-exceptions.json
+++ b/scripts/npm-exceptions.json
@@ -10,7 +10,6 @@
"listhen",
"micromatch",
"nitropack",
- "node-forge",
"nuxt",
"nuxt-site-config",
"nuxtseo-shared",
@@ -30,19 +29,6 @@
"reason": "Untrusted brace patterns are not forwarded to Nitro glob tooling by application routes. No patched upstream release; review again before expiry.",
"upstreamLatest": "3.0.3"
},
- {
- "package": "node-forge",
- "advisory": "https://github.com/advisories/GHSA-86w9-cpqp-85rv",
- "version": "1.4.0",
- "severity": "high",
- "nodes": [
- "node_modules/node-forge"
- ],
- "reviewed": "2026-10-23",
- "expires": "2026-11-06",
- "reason": "Transitive listhen certificate tooling; no application RSA verification path found. Runtime infrastructure must be validated separately.",
- "upstreamLatest": "1.4.0"
- },
{
"package": "quill",
"advisory": "https://github.com/advisories/GHSA-v3m3-f69x-jf25",
diff --git a/scripts/tests/dependency-security.test.mjs b/scripts/tests/dependency-security.test.mjs
index 221f0f7e6..eecc73ef3 100644
--- a/scripts/tests/dependency-security.test.mjs
+++ b/scripts/tests/dependency-security.test.mjs
@@ -116,11 +116,28 @@ test('release readiness fails for failed, skipped, cancelled or missing prerequi
test('resolves the actual Nuxt/Nitro/builders and site-config cycles to reviewed roots', () => {
const report = JSON.parse(readFileSync(new URL('./fixtures/npm-audit-reviewed-cycles.json', import.meta.url)))
const actualLock = { packages: Object.fromEntries(policy.exceptions.flatMap(entry => entry.nodes.map(node => [node, { version: entry.version }]))) }
- assert.equal(evaluateNpmAudit(report, actualLock, policy, '2026-10-23').acceptedAdvisories.length, 3)
+ assert.equal(evaluateNpmAudit(report, actualLock, policy, '2026-10-23').acceptedAdvisories.length, 2)
report.vulnerabilities.nuxt.via.push({ name: 'nuxt', url: 'https://github.com/advisories/NEW', severity: 'critical' })
assert.throws(() => evaluateNpmAudit(report, actualLock, policy, '2026-10-23'), /Unreviewed advisory/)
})
+test('rejects the retired node-forge advisory instead of accepting its former exception', () => {
+ const report = {
+ auditReportVersion: 2,
+ metadata: { vulnerabilities: { total: 2 } },
+ vulnerabilities: {
+ 'node-forge': {
+ severity: 'high',
+ nodes: ['node_modules/node-forge'],
+ via: [{ name: 'node-forge', severity: 'high', url: 'https://github.com/advisories/GHSA-86w9-cpqp-85rv' }],
+ },
+ nuxt: { severity: 'high', nodes: ['node_modules/nuxt'], via: ['node-forge'] },
+ },
+ }
+ const vulnerableLock = { packages: { 'node_modules/node-forge': { version: '1.4.0' } } }
+ assert.throws(() => evaluateNpmAudit(report, vulnerableLock, policy, '2026-10-27'), /Unreviewed affected package: node-forge/)
+})
+
test('Amplify also audits both scopes before building, including direct cloud builds', () => {
const amplify = parse(readFileSync(new URL('../../amplify.yml', import.meta.url), 'utf8'))
const preBuild = amplify.frontend.phases.preBuild.commands
diff --git a/scripts/tests/fixtures/npm-audit-reviewed-cycles.json b/scripts/tests/fixtures/npm-audit-reviewed-cycles.json
index 9c45689b6..5f4ae6d6e 100644
--- a/scripts/tests/fixtures/npm-audit-reviewed-cycles.json
+++ b/scripts/tests/fixtures/npm-audit-reviewed-cycles.json
@@ -5,9 +5,9 @@
"info": 0,
"low": 1,
"moderate": 0,
- "high": 14,
+ "high": 12,
"critical": 0,
- "total": 15
+ "total": 13
},
"dependencies": {
"prod": 952,
@@ -90,15 +90,6 @@
"node_modules/globby"
]
},
- "listhen": {
- "severity": "high",
- "via": [
- "node-forge"
- ],
- "nodes": [
- "node_modules/listhen"
- ]
- },
"micromatch": {
"severity": "high",
"via": [
@@ -111,26 +102,12 @@
"nitropack": {
"severity": "high",
"via": [
- "globby",
- "listhen"
+ "globby"
],
"nodes": [
"node_modules/nitropack"
]
},
- "node-forge": {
- "severity": "high",
- "via": [
- {
- "name": "node-forge",
- "url": "https://github.com/advisories/GHSA-86w9-cpqp-85rv",
- "severity": "high"
- }
- ],
- "nodes": [
- "node_modules/node-forge"
- ]
- },
"nuxt": {
"severity": "high",
"via": [