Address security vulnerabilities in transitive dependencies and docs updates - #273
Conversation
0521c1a to
9b07d61
Compare
There was a problem hiding this comment.
Pull request overview
This PR updates the extension’s development toolchain dependencies (TypeScript, VSCE, VS Code test tooling, and type packages) and removes deprecated TSLint usage, with the goal of restoring a green build and reducing security/deprecation risk.
Changes:
- Updated several
devDependencies(TypeScript,@vscode/vsce,@vscode/test-electron,@types/*) and regeneratedpackage-lock.json. - Removed the legacy
tslint:disabledirective fromextension.ts. - Added explicit
contents: readjob permissions to the GitHub Actions CI workflow.
Reviewed changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| package.json | Bumps dev tooling dependencies and adds a js-yaml override. |
| package-lock.json | Regenerated lockfile reflecting updated tooling dependency tree. |
| extension.ts | Removes obsolete TSLint directive comment. |
| .github/workflows/ci.yml | Adds job-level contents: read permissions for CI jobs. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 4 changed files in this pull request and generated no new comments.
Suppressed comments (3)
.github/workflows/ci.yml:30
- The build job still uses Node 20.x, but the updated dev toolchain now includes packages that declare Node >=22 (e.g. @vscode/test-electron@3.0.0, and transitive deps like undici@8.9.0). This is likely to break
npm ci/npx vsce packagein CI, or at least produce engine-related failures.
Either pin devDependencies to Node-20-compatible versions, or update the CI Node version to match the new dependency requirements.
permissions:
contents: read
strategy:
matrix:
node-version: [20.x]
package.json:43
@vscode/test-electronwas bumped to 3.0.0, but the resolved package in package-lock.json declaresengines.node >=22. If this repo/tooling is intended to keep building on Node 20.x (as CI currently does), this upgrade will likely make installs or test tooling fail.
Consider either (a) keeping @vscode/test-electron on a Node-20-compatible major, or (b) moving the repo’s build/test toolchain to Node 22+ (and aligning @types/node accordingly).
"typescript": "5.7.2",
"@vscode/vsce": "3.9.2",
"@vscode/test-electron": "3.0.0"
package.json:48
- The new
overridesare forcing major-version upgrades that conflict with the semver ranges declared by your transitive dependencies (e.g. markdown-it depends onlinkify-it: ^5.0.2, but the lock resolves linkify-it 6.1.0; other deps requestjs-yaml: ^4.1.1, but the lock resolves js-yaml 5.2.2). Overriding outside the supported major can cause subtle runtime failures in tooling (vsce/markdown rendering/config loading), and makes future dependency updates harder.
Prefer upgrading the direct dependents to versions that accept the newer majors, or keep overrides within the major versions those packages declare support for.
"overrides": {
"js-yaml": "5.2.2",
"linkify-it": "6.1.0",
"undici": "8.9.0"
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 4 changed files in this pull request and generated no new comments.
Suppressed comments (1)
.github/workflows/ci.yml:30
- The build job still uses Node 20.x, but the updated tooling now pulls in packages that declare Node >=22 (e.g., @vscode/test-electron@3.0.0 in package-lock.json has engines.node ">=22" and undici@8.9.0 has engines.node ">=22.19.0"). This can cause installs or build tooling (npx vsce package) to fail or behave inconsistently depending on local/CI Node version.
Update the CI Node version to a Node 22.19+ release (or alternatively revert the dependency upgrades to Node-20-compatible versions).
permissions:
contents: read
strategy:
matrix:
node-version: [22.x]
57eb1e0 to
f957081
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 4 changed files in this pull request and generated no new comments.
Suppressed comments (3)
.github/workflows/ci.yml:30
- CI uses
node-version: [22.x], but the lockfile now includes packages with stricter engine requirements (e.g.undici@8.9.0requires Node>=22.19.0). Using a floating22.xcan pick a 22 release that’s below 22.19, which may cause install/runtime issues. Consider pinning the CI Node version to at least22.19.x(or whatever minimum you intend to support) to match the dependency engine constraints.
node-version: [22.x]
package.json:49
- The new top-level
overridesforce major-version jumps that are outside the ranges declared by dependents in the lockfile (e.g.markdown-itdepends onlinkify-it: ^5.0.2butlinkify-itis forced to6.1.0;cheeriodepends onundici: ^7.19.0butundiciis forced to8.9.0). This can break assumptions about compatibility and makes future dependency upgrades harder to reason about. Prefer using versions that satisfy declared ranges (or upgrade the dependents to versions that officially support the newer major), and scope overrides as narrowly as possible.
"overrides": {
"js-yaml": "5.2.2",
"undici": "8.9.0"
},
"extensionDependencies": [
package.json:43
- The dependency upgrades effectively raise the required Node version for dev/build tooling:
@vscode/test-electron@3.0.0declaresengines.node: >=22(see lockfile), and some@azure/*transitive deps used by@vscode/vsce@3.9.2declare>=22.0.0. This conflicts with the PR description calling out “Node.js 20 LTS type definitions” and may surprise developers still on Node 20. Please clarify the supported Node version and align the repo metadata accordingly (e.g., update@types/node/docs/CI pin) so installs and builds are predictable.
"@types/node": "20.17.15",
"@types/vscode": "1.83.3",
"path": "0.12.7",
"typescript": "5.7.2",
"@vscode/vsce": "3.9.2",
"@vscode/test-electron": "3.0.0"
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 4 changed files in this pull request and generated no new comments.
Suppressed comments (1)
.github/workflows/ci.yml:30
- The workflow sets Node.js to
22.x, but the updated dependency tree includesundici@8.9.0which declares an engine requirement ofnode >=22.19.0(seepackage-lock.jsonentry). Using a broad22.xrange can select a Node 22 release below 22.19.0 and failnpm ci/tool execution. Pin the CI Node version to at least 22.19.0 (or a 22.19.x range) to match the dependency engines constraint.
strategy:
matrix:
node-version: [22.x]
f957081 to
dc8072c
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.
Suppressed comments (1)
package.json:41
- The devDependency versions for
@types/vscodeand@vscode/test-electronare using caret ranges, which contradicts the PR description's stated policy of exact version pinning. Also,@types/vscodeis set to ^1.125.0 while engines.vscode is ^1.83.0; using typings for a much newer VS Code version undermines type-safety for the declared engine range and can hide accidental usage of APIs not available in 1.83.x.
"@types/node": "20.17.15",
"@types/vscode": "^1.125.0",
"@vscode/test-electron": "^3.1.0",
"@vscode/vsce": "3.9.2",
f79d6eb to
0244458
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.
Suppressed comments (2)
.github/workflows/ci.yml:31
- CI now runs on Node 22.19.0, which conflicts with the PR description framing
@types/nodeas “Node.js 20 LTS type definitions”. Given package-lock.json now includes dependencies requiring Node >=22 (and undici requires >=22.19.0), consider updating the PR description and/or making the required Node version explicit for contributors (e.g., via package.json engines.node, .nvmrc, or documentation).
strategy:
matrix:
node-version: [22.19.0]
steps:
package.json:41
- PR description says
@vscode/test-electronwas updated to 3.0.0, but package.json pins it to 3.1.0 (and package-lock.json matches 3.1.0). Please align the description with the actual version, or adjust the dependency versions if 3.0.0 was intended.
"@vscode/test-electron": "3.1.0",
"@vscode/vsce": "3.9.2",
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 4 out of 5 changed files in this pull request and generated no new comments.
Suppressed comments (6)
- Same issue here: “tomorrow” is relative and will become wrong. Use an explicit date.
- ⏳ **1 alert pending** (fast-uri - available tomorrow Aug 15)
package.json:44
- This dependency update effectively raises the minimum Node.js version needed for dev tooling (e.g.,
@vscode/test-electronnow declares node >=22 in package-lock). Consider declaring a Node engine requirement in package.json so local installs/builds fail fast with a clear message instead of cryptic runtime/tool errors.
"devDependencies": {
"@types/node": "20.17.15",
"@types/vscode": "1.83.3",
"@vscode/test-electron": "3.1.0",
"@vscode/vsce": "3.9.2",
"path": "0.12.7",
"typescript": "5.7.2"
},
package.json:41
- PR description says
@vscode/test-electronis updated to 3.0.0, but package.json pins it to 3.1.0. Please align the PR description with the actual version (or adjust the dependency if 3.0.0 was intended).
"@types/node": "20.17.15",
"@types/vscode": "1.83.3",
"@vscode/test-electron": "3.1.0",
"@vscode/vsce": "3.9.2",
- The document title is branch-specific, which will be inaccurate once merged (and makes the file harder to reuse/refer to later). Consider using a stable title keyed to the ticket/PR purpose instead.
- Avoid relative time wording like “tomorrow” in a committed document; it becomes incorrect immediately after the date changes. Prefer a specific date or a policy-based statement.
| **fast-uri** | HIGH | Host confusion via backslash authority introducer | 3.1.5 or 4.1.2 | July 31, 2026 | **Aug 14-15, 2026** (tomorrow) |
- This line uses relative time (“tomorrow”), which will quickly become stale/confusing in the repo history. Prefer an explicit date.
This issue also appears on line 185 of the same file.
⏳ Remaining fix (fast-uri) will be available tomorrow
4ad84f1 to
f0c62aa
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 4 out of 5 changed files in this pull request and generated no new comments.
Suppressed comments (4)
- This alert row says
@tootallnate/onceis still an indirect dependency, but@tootallnate/onceis no longer present in package-lock.json after this update. Update the summary so it reflects the current lockfile state (and doesn't incorrectly claim an unresolved Dependabot alert).
| #23 | @tootallnate/once | LOW | Aug 7, 2026 | ⚠️ Indirect dependency of @vscode/vsce |
- The suggested fast-uri override snippet replaces the entire "overrides" object, which would accidentally drop the other security overrides already required in this PR. Update the snippet to show adding fast-uri alongside the existing overrides.
```json
"overrides": {
"fast-uri": "3.1.5"
}
* The verified package tree header uses `chef@2.2.14`, but package.json currently declares version 2.2.15 (and the lockfile should match). Update the snippet so it reflects the current package version.
chef@2.2.14
</details>
9fb4ec6 to
801bcca
Compare
801bcca to
993803b
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 2 changed files in this pull request and generated no new comments.
Suppressed comments (1)
package.json:51
- The override pins
undicito 8.9.0, but the resulting lockfile entry declaresengines.node: >=22.19.0(see package-lock.json around the undici entry). CI currently installs dependencies on Node 20.x (.github/workflows/ci.yml:26), so this override can introduce engine incompatibility warnings or break build/packaging depending on how undici/its consumers behave on Node 20. Either bump the project/CI Node version to >=22.19.0 or select anundiciversion that is both patched and compatible with the project’s Node 20 toolchain.
"overrides": {
"js-yaml": "5.2.2",
"undici": "8.9.0",
"markdown-it": "15.0.0",
"linkify-it": "6.1.0",
"brace-expansion": "5.0.9"
993803b to
801bcca
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 4 changed files in this pull request and generated no new comments.
Suppressed comments (2)
package.json:42
- PR description states "No direct dependency version changes" and a minimal "only overrides" approach, but this diff also upgrades multiple direct devDependencies (e.g., @vscode/vsce, @vscode/test-electron, typescript). This is a scope/communication mismatch and also changes the required Node toolchain (e.g., @vscode/test-electron@3.1.0 requires Node >=22). Consider either splitting the PR (overrides-only vs toolchain upgrades) or updating the PR description/title to reflect these direct upgrades and the Node version bump.
"@types/node": "20.17.15",
"@types/vscode": "1.83.3",
"@vscode/test-electron": "3.1.0",
"@vscode/vsce": "3.9.2",
"path": "0.12.7",
.github/workflows/ci.yml:30
- CI pins Node to an exact patch version. Since the dependency tree now requires Node >=22.19.0, using a semver range (e.g., 22.19.x) keeps the minimum while still picking up security/bugfix patch updates automatically.
node-version: [22.19.0]
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 4 out of 5 changed files in this pull request and generated no new comments.
Suppressed comments (2)
package.json:50
- These overrides force major versions that don't satisfy some dependents' declared semver ranges (e.g.,
@vscode/vscerequires markdown-it ^14.1.0 and cheerio requires undici ^7.19.0; package-lock.json:628 and :1144). Prefer overriding to patched versions that remain within the existing major ranges to reduce breakage risk while still addressing the vulnerabilities.
"js-yaml": "5.2.2",
"undici": "8.9.0",
"markdown-it": "15.0.0",
"linkify-it": "6.1.0",
"brace-expansion": "5.0.9"
package.json:43
- PR description claims "No direct dependency version changes", but this PR updates several direct devDependencies here (e.g., @vscode/test-electron, @vscode/vsce, typescript). Either update the PR description to clarify that direct devDependencies are being upgraded, or revert these direct version bumps if they’re out of scope for the stated goal.
"@vscode/test-electron": "3.1.0",
"@vscode/vsce": "3.9.2",
"path": "0.12.7",
"typescript": "5.7.2"
Changes: - Update npm dependencies with security overrides for transitive packages - Add Cookstyle version enforcement (minimum 8.6.10) for consistent linting - Update CI workflow to use Node.js 22.19.0 for compatibility - Simplify README documentation to essential information only Security fixes via npm overrides: - js-yaml@5.2.2: Fixes quadratic CPU consumption - undici@8.9.0: Fixes multiple disclosure and injection issues - markdown-it@15.0.0: Fixes DoS in smartquotes rule - linkify-it@6.1.0: Fixes DoS via mailto validator - brace-expansion@5.0.9: Fixes DoS in glob expansion All package versions comply with HAR security policy (14-day minimum release age). Extension improvements: - Automatic Cookstyle version detection with user-friendly warnings - Better error handling for missing Chef Workstation installations - Support for both Chef Workstation 25 and 26 path detection Signed-off-by: nikhil2611 <ngupta@progress.com>
4e7d5a0 to
abbeac7
Compare
Overview
This PR addresses security vulnerabilities in transitive dependencies by adding npm overrides to enforce patched versions.
Changes
Added
overridessection in package.json to enforce secure versions of transitive dependencies:HAR Security Compliance
All package versions meet HAR security policy requirements:
Test Results
npm run vscode:prepublishImpact