Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(deps): update dependency fastify to v4.10.2 [security] #841

Merged
merged 1 commit into from
Aug 21, 2023

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Mar 27, 2023

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
fastify (source) 4.4.0 -> 4.10.2 age adoption passing confidence

GitHub Vulnerability Alerts

CVE-2022-39288

Impact

An attacker can send an invalid Content-Type header that can cause the application to crash, leading to a possible Denial of Service attack. Only the v4.x line is affected.

(This was updated: upon a close inspection, v3.x is not affected after all).

Patches

Yes, update to > v4.8.0.

Workarounds

You can reject the malicious content types before the body parser enters in action.

  const badNames = Object.getOwnPropertyNames({}.__proto__)
  fastify.addHook('onRequest', async (req, reply) => {
    for (const badName of badNames) {
      if (req.headers['content-type'].indexOf(badName) > -1) {
        reply.code(415)
        throw new Error('Content type not supported')
      }
    }
  })

References

See the HackerOne report #​1715536

For more information

Fastify security policy

CVE-2022-41919

Impact

The attacker can use the incorrect Content-Type to bypass the Pre-Flight checking of fetch. fetch() requests with Content-Type’s essence as "application/x-www-form-urlencoded", "multipart/form-data", or "text/plain", could potentially be used to invoke routes that only accepts application/json content type, thus bypassing any CORS protection, and therefore they could lead to a Cross-Site Request Forgery attack.

Patches

For 4.x users, please update to at least 4.10.2
For 3.x users, please update to at least 3.29.4

Workarounds

Implement Cross-Site Request Forgery protection using @fastify/csrf.

References

Check out the HackerOne report: https://hackerone.com/reports/1763832.

For more information

Fastify security policy


Release Notes

fastify/fastify (fastify)

v4.10.2

Compare Source

⚠️ Security Release ⚠️

Full Changelog: fastify/fastify@v4.10.1...v4.10.2

v4.10.1

Compare Source

What's Changed

New Contributors

Full Changelog: fastify/fastify@v4.10.0...v4.10.1

v4.10.0

Compare Source

What's Changed

New Contributors

Full Changelog: fastify/fastify@v4.9.2...v4.10.0

v4.9.2

Compare Source

What's Changed

Full Changelog: fastify/fastify@v4.9.1...v4.9.2

v4.9.1

Compare Source

What's Changed

New Contributors

Full Changelog: fastify/fastify@v4.9.0...v4.9.1

v4.9.0

Compare Source

What's Changed

New Contributors

Full Changelog: fastify/fastify@v4.8.1...v4.9.0

v4.8.1

Compare Source

⚠️ Security Release ⚠️

This release fixes GHSA-455w-c45v-86rg for the v4.x line.
This is a HIGH vulnerability that can lead to a crash, resulting in a total loss of availability.
The CVE for this vulnerability is CVE-2022-39288.

Full Changelog: fastify/fastify@v4.8.0...v4.8.1

v4.8.0

Compare Source

What's Changed

New Contributors

Full Changelog: fastify/fastify@v4.7.0...v4.8.0

v4.7.0

Compare Source

What's Changed

New Contributors

Full Changelog: fastify/fastify@v4.6.0...v4.7.0

v4.6.0

Compare Source

What's Changed

New Contributors

Full Changelog: fastify/fastify@v4.5.3...v4.6.0

v4.5.3

Compare Source

What's Changed

Full Changelog: fastify/fastify@v4.5.2...v4.5.3

v4.5.2

Compare Source

What's Changed

Full Changelog: fastify/fastify@v4.5.1...v4.5.2

v4.5.1

Compare Source

What's Changed

Full Changelog: fastify/fastify@v4.5.0...v4.5.1

v4.5.0

Compare Source

What's Changed

New Contributors

Full Changelog: fastify/fastify@v4.4.0...v4.5.0


Configuration

📅 Schedule: Branch creation - "" in timezone Asia/Tokyo, Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

@renovate renovate bot added the renovate label Mar 27, 2023
@renovate renovate bot force-pushed the renovate/npm-fastify-vulnerability branch from efef835 to 7b48f16 Compare August 19, 2023 15:12
@codecov-commenter
Copy link

codecov-commenter commented Aug 19, 2023

Codecov Report

Merging #841 (8645181) into master (19a5e32) will not change coverage.
Report is 1 commits behind head on master.
The diff coverage is n/a.

❗ Current head 8645181 differs from pull request most recent head 403f24b. Consider uploading reports for the commit 403f24b to get more accurate results

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

@@           Coverage Diff           @@
##           master     #841   +/-   ##
=======================================
  Coverage   57.66%   57.66%           
=======================================
  Files          27       27           
  Lines        3413     3413           
  Branches      272      272           
=======================================
  Hits         1968     1968           
  Misses       1445     1445           

@renovate renovate bot force-pushed the renovate/npm-fastify-vulnerability branch 18 times, most recently from 915caa6 to d85a311 Compare August 21, 2023 12:42
@renovate renovate bot force-pushed the renovate/npm-fastify-vulnerability branch from d85a311 to 483c29f Compare August 21, 2023 12:50
@teppeis teppeis merged commit 715ab0c into master Aug 21, 2023
5 checks passed
@teppeis teppeis deleted the renovate/npm-fastify-vulnerability branch August 21, 2023 13:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants