Skip to content

Remediate Axios CVEs by upgrading to 1.18.1 and removing vulnerable transitive path - #547

Merged
rogene-bcgov merged 3 commits into
masterfrom
copilot/fix-trivy-axios-cves
Jun 25, 2026
Merged

rogene-bcgov merged 3 commits into
masterfrom
copilot/fix-trivy-axios-cves

Conversation

Copilot AI commented Jun 23, 2026 •

Copy link
Copy Markdown
Contributor

Trivy flagged multiple HIGH CVEs on axios@0.21.4 in the client dependency graph. This PR removes all 0.21.4 references from the client lock graph by upgrading Axios and eliminating the transitive source that kept the vulnerable version pinned.

  • Dependency remediation

    • Upgraded client direct dependency from axios@^0.21.1 to axios@1.18.1.
    • Added npm override to enforce axios@1.18.1 resolution in the dependency tree.
    • Refreshed client/package-lock.json to reflect upgraded Axios artifacts.
  • Transitive vulnerability source removal

    • Removed lite-server and concurrently dev dependencies, which introduced localtunnel and retained axios@0.21.4 in lock metadata.
    • Updated start script to run react-scripts start directly.
    • Removed obsolete server script tied to lite-server.
  • Files updated

    • client/package.json
    • client/package-lock.json
{
  "dependencies": {
    "axios": "1.18.1"
  },
  "overrides": {
    "axios": "1.18.1"
  },
  "scripts": {
    "start": "react-scripts start"
  }
}

Thanks for the PR!

After merge, new images are deployed and promoted to DEV:

Copilot AI changed the title [WIP] Fix Trivy reported CVEs for axios 0.21.4 Remediate Axios CVEs by upgrading to 1.18.1 and removing vulnerable transitive path Jun 23, 2026
Copilot AI requested a review from rogene-bcgov June 23, 2026 23:01
@rogene-bcgov
rogene-bcgov requested a review from Copilot June 23, 2026 23:01
@rogene-bcgov
rogene-bcgov marked this pull request as ready for review June 23, 2026 23:02

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR remediates Trivy-reported HIGH CVEs by upgrading the client’s Axios dependency to 1.18.1 and removing dev dependencies that were retaining the vulnerable axios@0.21.4 in the lockfile graph.

Changes:

  • Upgrade axios from ^0.21.1 to 1.18.1 and add an npm override to enforce resolution.
  • Remove lite-server and concurrently (and simplify the start script to run react-scripts start directly).
  • Regenerate client/package-lock.json to eliminate axios@0.21.4 and related transitive entries.

Reviewed changes

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

File Description
client/package.json Pins Axios to 1.18.1, adds overrides, and removes dev tooling/scripts that pulled in vulnerable transitive deps.
client/package-lock.json Updates the resolved dependency graph to reflect Axios 1.18.1 and removal of lite-server/concurrently transitive chain.

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

Comment thread client/package.json Resolved
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@rogene-bcgov

Copy link
Copy Markdown
Collaborator

All tests good. Merging this now.

@rogene-bcgov
rogene-bcgov merged commit caafb4b into master Jun 25, 2026
15 of 16 checks passed
@sonarqubecloud

Copy link
Copy Markdown

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.

3 participants