Skip to content

[Snyk] Security upgrade firebase-functions from 3.24.1 to 7.3.2 - #428

Open
caniszczyk wants to merge 1 commit into
mainfrom
snyk-fix-39581f7583c48257d41bd45245870389
Open

[Snyk] Security upgrade firebase-functions from 3.24.1 to 7.3.2#428
caniszczyk wants to merge 1 commit into
mainfrom
snyk-fix-39581f7583c48257d41bd45245870389

Conversation

@caniszczyk

Copy link
Copy Markdown

snyk-top-banner

Snyk has created this PR to fix 2 vulnerabilities in the npm dependencies of this project.

Snyk changed the following file(s):

  • builders/testdata/nodejs/functions/firebase_multiple_functions/package.json

Vulnerabilities that will be fixed with an upgrade:

Issue Score
medium severity Uncaught Exception
SNYK-JS-QS-19432019
  738  
medium severity Allocation of Resources Without Limits or Throttling
SNYK-JS-QS-19432017
  708  

Breaking Change Risk

Merge Risk: High

Notice: This assessment is enhanced by AI.


Important

  • Check the changes in this PR to ensure they won't cause issues with your project.
  • Max score is 1000. Note that the real score may have changed since the PR was raised.
  • This PR was automatically created by Snyk using the credentials of a real user.

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.

For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic


Learn how to fix vulnerabilities with free interactive lessons:

🦉 Allocation of Resources Without Limits or Throttling
🦉 Uncaught Exception

…ackage.json to reduce vulnerabilities

The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-JS-QS-19432019
- https://snyk.io/vuln/SNYK-JS-QS-19432017
@caniszczyk

Copy link
Copy Markdown
Author

Merge Risk: High

This is a major version upgrade with multiple significant, mandatory breaking changes. The upgrade from v3 to v7 crosses several major versions (v4, v5, v6, v7), each introducing critical changes that require a full migration effort.

Key Breaking Changes:

  • Migration from 1st Gen to 2nd Gen API: The most significant change, introduced in v4.0.0, is the move from the 1st generation API to the 2nd generation. This requires rewriting all function definitions with new, modular imports.

    • Before (v3.x): const functions = require("firebase-functions");
    • After (v4.x+): const {onRequest} = require("firebase-functions/v2/https");
  • Node.js Runtime Deprecations: Support for older Node.js versions has been dropped incrementally.

    • v4.0.0 dropped support for Node.js 8, 10, and 12.
    • v7.0.0 dropped support for Node.js 16.
      Your project must be running on a supported Node.js version (e.g., 18, 20, or newer).
  • Configuration Removal: The functions.config() API for environment variables was deprecated in v6 and completely removed in v7.0.0. You must migrate to using parameterized configuration with the params module and Secret Manager.

  • Dependency Updates: This upgrade requires updating peer dependencies like firebase-admin and firebase-functions-test to their latest versions to ensure compatibility.

Source: Official Migration Guide, Release Notes

Recommendation: This is a high-effort migration that requires a complete rewrite and thorough testing of all Cloud Functions. Do not merge this upgrade without allocating time to follow the official migration guide and update all function code, Node.js runtime, and environment variable configurations.

Notice 🤖: This content was augmented using artificial intelligence. AI-generated content may contain errors and should be reviewed for accuracy before use.

@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

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