[Snyk] Fix for 3 vulnerabilities - #70
Conversation
The following vulnerabilities are fixed with an upgrade: - https://snyk.io/vuln/SNYK-JS-MULTER-15365916 - https://snyk.io/vuln/SNYK-JS-MULTER-15365918 - https://snyk.io/vuln/SNYK-JS-NESTJSCORE-15365922
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request aims to enhance the security posture of the project by upgrading key NestJS dependencies to resolve identified high-severity vulnerabilities. The changes primarily involve updating package versions to incorporate the necessary security patches, ensuring the application benefits from the latest fixes. Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request updates @nestjs/core and @nestjs/platform-express to fix three security vulnerabilities. However, a critical issue exists: the pnpm-lock.yaml file has not been updated. This will prevent the new package versions from being installed, leaving the vulnerabilities unresolved. Please run pnpm install to update the lock file and commit the changes to ensure the fixes are applied.
Note: Security Review has been skipped due to the limited scope of the PR.
| "@nestjs/core": "^11.1.14", | ||
| "@nestjs/event-emitter": "^3.0.1", | ||
| "@nestjs/microservices": "^11.1.13", | ||
| "@nestjs/platform-express": "^11.1.13", | ||
| "@nestjs/platform-express": "^11.1.15", |
There was a problem hiding this comment.
The pnpm-lock.yaml file has not been updated to reflect the version changes in package.json. As noted in the pull request description, this is a critical oversight because the old, vulnerable package versions will still be used during installation. To resolve this and apply the security fixes, please run pnpm install and commit the updated pnpm-lock.yaml file.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 625adb4d19
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| "@nestjs/core": "^11.1.14", | ||
| "@nestjs/event-emitter": "^3.0.1", | ||
| "@nestjs/microservices": "^11.1.13", | ||
| "@nestjs/platform-express": "^11.1.13", | ||
| "@nestjs/platform-express": "^11.1.15", |
There was a problem hiding this comment.
Update lockfile after dependency version bumps
This change bumps @nestjs/core and @nestjs/platform-express in package.json but does not update pnpm-lock.yaml, which still pins 11.1.13; in this repo, CI runs pnpm install --frozen-lockfile in .github/workflows/ci.yml (for example lines 63 and 112), and pnpm install --help states --frozen-lockfile will "fail if an update is needed," so the workflow will fail and the vulnerable locked versions remain in use until the lockfile is regenerated and committed.
Useful? React with 👍 / 👎.
|
| "@nestjs/core": "^11.1.14", | ||
| "@nestjs/event-emitter": "^3.0.1", | ||
| "@nestjs/microservices": "^11.1.13", | ||
| "@nestjs/platform-express": "^11.1.13", | ||
| "@nestjs/platform-express": "^11.1.15", |
There was a problem hiding this comment.
Lockfile not updated — security fixes won't take effect
The pnpm-lock.yaml was NOT updated as part of this PR. pnpm uses the lockfile for deterministic, reproducible installs. Because pnpm-lock.yaml still pins both packages to 11.1.13:
'@nestjs/core@11.1.13': ...
'@nestjs/platform-express@11.1.13': ...
Running pnpm install (or any CI/CD install step) will continue to resolve and install the vulnerable versions, completely bypassing the package.json bumps introduced here. The three high-severity vulnerabilities (SNYK-JS-MULTER-15365916, SNYK-JS-MULTER-15365918, SNYK-JS-NESTJSCORE-15365922) will therefore not be remediated until the lockfile is regenerated.
Before merging, run:
pnpm update @nestjs/core @nestjs/platform-express
and commit the updated pnpm-lock.yaml.
Prompt To Fix With AI
This is a comment left during a code review.
Path: package.json
Line: 72-75
Comment:
**Lockfile not updated — security fixes won't take effect**
The `pnpm-lock.yaml` was NOT updated as part of this PR. pnpm uses the lockfile for deterministic, reproducible installs. Because `pnpm-lock.yaml` still pins both packages to `11.1.13`:
```
'@nestjs/core@11.1.13': ...
'@nestjs/platform-express@11.1.13': ...
```
Running `pnpm install` (or any CI/CD install step) will continue to resolve and install the **vulnerable** versions, completely bypassing the `package.json` bumps introduced here. The three high-severity vulnerabilities (`SNYK-JS-MULTER-15365916`, `SNYK-JS-MULTER-15365918`, `SNYK-JS-NESTJSCORE-15365922`) will therefore **not** be remediated until the lockfile is regenerated.
Before merging, run:
```
pnpm update @nestjs/core @nestjs/platform-express
```
and commit the updated `pnpm-lock.yaml`.
How can I resolve this? If you propose a fix, please make it concise.
Snyk has created this PR to fix 3 vulnerabilities in the pnpm dependencies of this project.
Snyk changed the following file(s):
package.jsonVulnerabilities that will be fixed with an upgrade:
SNYK-JS-MULTER-15365916
SNYK-JS-MULTER-15365918
SNYK-JS-NESTJSCORE-15365922
Important
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
👩💻 Set who automatically gets assigned
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic
Learn how to fix vulnerabilities with free interactive lessons:
🦉 Incorrect Authorization