Skip to content

chore: resolve open dependabot security alerts - #253

Open
jonathannorris wants to merge 4 commits into
mainfrom
chore/dependabot-alerts
Open

chore: resolve open dependabot security alerts#253
jonathannorris wants to merge 4 commits into
mainfrom
chore/dependabot-alerts

Conversation

@jonathannorris

@jonathannorris jonathannorris commented Jun 29, 2026

Copy link
Copy Markdown
Member

Summary

Resolved 9 open Dependabot security alerts in test/angular-integration by upgrading vulnerable dependencies.

Dependabot Alerts Resolved

Alert Package Severity Fix
#60 fast-uri high Bumped override to ^3.1.4 (fixes host confusion via literal backslash authority delimiter)
#59 fast-uri high Bumped override to ^3.1.4 (fixes host confusion via failed IDN canonicalization)
#57 vite high Bumped to ^6.4.3 in devDependencies and overrides
#58 vite medium Bumped to ^6.4.3 in devDependencies and overrides
#56 @babel/core low Added @babel/core: ^7.29.6 override (transitive via @angular/compiler-cli)
#54 @angular/core high Upgraded Angular from 19.x to 20.3.25 (no patch exists for 19.x line)
#55 @angular/common high Upgraded Angular from 19.x to 20.3.25 (no patch exists for 19.x line)
#53 @angular/common high Upgraded Angular from 19.x to 20.3.25 (no patch exists for 19.x line)
#52 @angular/compiler medium Upgraded Angular from 19.x to 20.3.25 (no patch exists for 19.x line)

The Angular 19.x vulnerabilities have no patch in the 19.x line; the advisories are fixed in Angular 20.3.25+. The integration test suite has been upgraded to Angular 20 accordingly, along with compatible versions of @openfeature/angular-sdk (1.3.1), @angular/compiler-cli, @analogjs/vitest-angular, and TypeScript (~5.8.0, required by Angular 20). fast-uri (transitive via ajv/@angular-devkit) is pinned via override to ^3.1.4.

All 58 integration tests pass after the upgrades.

- vite ^6.4.2 -> ^6.4.3 (medium/high, alerts #57 #58)
- @babel/core transitive -> ^7.29.6 via override (low, alert #56)
- @angular/common, @angular/core, @angular/compiler 19.x -> 20.3.25 (high/medium, alerts #52 #53 #54 #55)

Signed-off-by: Jonathan Norris <jonathan.norris@dynatrace.com>
@coderabbitai

coderabbitai Bot commented Jun 29, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The generated Go client is refreshed, including renamed enum identifiers, removed bearer-auth declarations, manifest capability response headers, and parsing changes. Angular integration dependencies, development tooling, and package overrides are also upgraded.

Changes

Generated API client

Layer / File(s) Summary
Client contracts and generated declarations
internal/api/client/sync_client.gen.go
The generated client updates generator metadata, removes bearer-auth declarations, renames manifest value-type constants, and refreshes generated model, interface, request, and method comments.
Response wrappers and capability headers
internal/api/client/sync_client.gen.go
Successful manifest response wrappers expose X-Manifest-Capabilities, and parsers bind the header for the relevant 200 and 201 responses.

Angular integration tooling

Layer / File(s) Summary
Angular integration dependency updates
test/angular-integration/package.json
Angular, OpenFeature SDK, TypeScript, Vite, test tooling, and selected dependency overrides are upgraded.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant HTTPResponse
  participant ResponseParser
  participant RuntimeBinder
  participant ResponseWrapper
  HTTPResponse->>ResponseParser: return successful manifest response and capability header
  ResponseParser->>RuntimeBinder: bind X-Manifest-Capabilities
  RuntimeBinder->>ResponseWrapper: populate status-specific headers
Loading
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the dependency security alert cleanup and matches the main change.
Description check ✅ Passed The description directly matches the dependency upgrades and Dependabot alert fixes in the changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the Angular integration test project dependencies to address outstanding Dependabot security alerts by upgrading Angular/Vite and related tooling, plus adding targeted npm overrides.

Changes:

  • Upgraded Angular dependencies from 19.2.25 to 20.3.25 and aligned Angular-related dev tooling (@angular/compiler-cli, typescript).
  • Bumped Vite from 6.4.2 to 6.4.3 (including an override) and refreshed the lockfile accordingly.
  • Added an override for @babel/core to address a transitive vulnerability.

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated 3 comments.

File Description
test/angular-integration/package.json Updates Angular/Vite/TypeScript versions and adds @babel/core override to resolve security alerts.
test/angular-integration/package-lock.json Regenerates the lockfile to reflect the dependency upgrades and new overrides.
Files not reviewed (1)
  • test/angular-integration/package-lock.json: Generated file

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread test/angular-integration/package-lock.json
Comment thread test/angular-integration/package.json
Comment thread test/angular-integration/package.json Outdated
Address Copilot review feedback on PR #253: @openfeature/angular-sdk
1.3.1 requires @openfeature/web-sdk ^1.9.0 as a peer dependency, but
package.json still allowed ^1.7.3. Bump the declared range to match
and regenerate the lockfile.

Signed-off-by: Jonathan Norris <jonathan.norris@dynatrace.com>
@jonathannorris
jonathannorris marked this pull request as ready for review July 6, 2026 14:24
@jonathannorris
jonathannorris enabled auto-merge July 6, 2026 14:24
- fast-uri ^3.1.2 -> ^3.1.4 (high, alert #59: host confusion via failed IDN canonicalization)
- fast-uri ^3.1.2 -> ^3.1.4 (high, alert #60: host confusion via literal backslash authority delimiter)

Signed-off-by: Jonathan Norris <jonathan.norris@dynatrace.com>
@jonathannorris
jonathannorris marked this pull request as draft July 27, 2026 14:09
auto-merge was automatically disabled July 27, 2026 14:09

Pull request was converted to draft

Signed-off-by: Jonathan Norris <jonathan.norris@dynatrace.com>
@jonathannorris
jonathannorris marked this pull request as ready for review July 27, 2026 17:43
@jonathannorris
jonathannorris enabled auto-merge July 27, 2026 17:43

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
internal/api/client/sync_client.gen.go (1)

797-905: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Add regression tests for X-Manifest-Capabilities parsing.

Cover each success status with the header present and absent, and verify that non-success responses do not populate the success-header wrapper. This protects the new public response contract from generator or parser regressions.

Also applies to: 932-988, 1015-1064, 1091-1154, 1322-1339, 1398-1413, 1464-1480, 1544-1562

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@internal/api/client/sync_client.gen.go` around lines 797 - 905, Add
regression tests for the response parsing paths associated with
GetOpenfeatureV0ManifestResponse and the other affected response types, covering
every success status with X-Manifest-Capabilities present and absent. Assert the
header value is populated only when present, and verify non-success responses
leave the success-header wrapper unset. Reuse the existing generated-client test
patterns to cover all listed affected endpoints.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@test/angular-integration/package.json`:
- Line 36: Update the fast-uri dependency entry in the test Angular integration
package manifest from the caret range to the exact version 3.1.4. If this
project tracks dependency resolution in a lockfile, regenerate or update it so
the locked fast-uri version remains exactly 3.1.4.

---

Nitpick comments:
In `@internal/api/client/sync_client.gen.go`:
- Around line 797-905: Add regression tests for the response parsing paths
associated with GetOpenfeatureV0ManifestResponse and the other affected response
types, covering every success status with X-Manifest-Capabilities present and
absent. Assert the header value is populated only when present, and verify
non-success responses leave the success-header wrapper unset. Reuse the existing
generated-client test patterns to cover all listed affected endpoints.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 4a5a9502-deff-459c-b1ef-5c81ee8e998e

📥 Commits

Reviewing files that changed from the base of the PR and between 784196c and 54c1c6f.

⛔ Files ignored due to path filters (1)
  • test/angular-integration/package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (2)
  • internal/api/client/sync_client.gen.go
  • test/angular-integration/package.json

"@babel/core": "^7.29.6",
"esbuild": "^0.28.1",
"fast-uri": "^3.1.2",
"fast-uri": "^3.1.4",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔒 Security & Privacy | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== package manifest =="
cat -n test/angular-integration/package.json | sed -n '1,80p'

echo
echo "== lockfile fast-uri entries =="
if [ -f test/angular-integration/package-lock.json ]; then
  rg -n '"fast-uri"|"node_modules/fast-uri"|version' test/angular-integration/package-lock.json | head -120
fi

echo
echo "== any fast-uri mentions =="
rg -n '"fast-uri"|fast-uri' test/angular-integration || true

echo
echo "== npm semver semantic check =="
node - <<'JS'
const semver = require('semver');
const semverLib = require('semver');
console.log('available:', typeof semver, !!semverLib);
if (semver && semverLib) {
  console.log('3.1.4 satisfies ^3.1.4:', semverLib.satisfies('3.1.4', '^3.1.4'));
  console.log('3.2.0 satisfies ^3.1.4:', semverLib.satisfies('3.2.0', '^3.1.4'));
  console.log('3.1.4 satisfies 3.1.4:', semverLib.satisfies('3.1.4', '3.1.4'));
  console.log('3.2.0 satisfies 3.1.4:', semverLib.satisfies('3.2.0', '3.1.4'));
}
JS

Repository: open-feature/cli

Length of output: 6849


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== fast-uri lockfile block =="
sed -n '2430,2470p' test/angular-integration/package-lock.json

echo
echo "== deterministic semver ranges =="
node - <<'JS'
const { satisfies } = require('semver');
for (const [version,.range] of [
  ['3.1.4', '^3.1.4'],
  ['3.2.0', '^3.1.4'],
  ['3.1.4', '3.1.4'],
  ['3.2.0', '3.1.4'],
]) {
  console.log(`${version} satisfies ${range}: ${satisfies(version, range)}`);
}
JS

Repository: open-feature/cli

Length of output: 2176


Pin fast-uri exactly to 3.1.4.

"^3.1.4" still allows later 3.x releases, so the manifest can diverge from the stated 3.1.4 constraint; use "3.1.4" and update the lockfile if exact reproducibility is required.

Proposed fix
-    "fast-uri": "^3.1.4",
+    "fast-uri": "3.1.4",
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"fast-uri": "^3.1.4",
"fast-uri": "3.1.4",
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/angular-integration/package.json` at line 36, Update the fast-uri
dependency entry in the test Angular integration package manifest from the caret
range to the exact version 3.1.4. If this project tracks dependency resolution
in a lockfile, regenerate or update it so the locked fast-uri version remains
exactly 3.1.4.

Source: MCP tools

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants