Closed renovate[bot] closed 3 months ago
[!IMPORTANT]
Auto Review Skipped
Bot user detected.
To trigger a single review, invoke the
@coderabbitai review
command.
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
This PR contains the following updates:
^6.0.0
->^7.0.0
GitHub Vulnerability Alerts
CVE-2024-31999
Impact
At the end of the request handling, it will encrypt all data in the session with a secret key and attach the ciphertext as a cookie value with the defined cookie name. After that, the session on the server side is destroyed. When an encrypted cookie with matching session name is provided with subsequent requests, it will decrypt the ciphertext to get the data. The plugin then creates a new session with the data in the ciphertext. Thus theoretically the web instance is still accessing the data from a server-side session, but technically that session is generated solely from a user provided cookie (which is assumed to be non-craftable because it is encrypted with a secret key not known to the user).
The issue exists in the session removal process. In the delete function of the code, when the session is deleted, it is marked for deletion. However, if an attacker could gain access to the cookie, they could keep using it forever.
Patches
Fixed in 56d66642ecc633cff0606927601e81cdac361370. Update to v7.3.0.
Workarounds
Include a "last update" field in the session, and treat "old sessions" as expired. Make sure to configure your cookie as "http only".
References
Release Notes
fastify/fastify-secure-session (@fastify/secure-session)
### [`v7.3.0`](https://togithub.com/fastify/fastify-secure-session/releases/tag/v7.3.0) [Compare Source](https://togithub.com/fastify/fastify-secure-session/compare/v7.1.0...v7.3.0) #### :warning: Security Release :warning: Fixes https://github.com/fastify/fastify-secure-session/security/advisories/GHSA-9wwp-q7wq-jx35 #### What's Changed - Update the file name of the key in README.md for consistency by [@acro5piano](https://togithub.com/acro5piano) in [https://github.com/fastify/fastify-secure-session/pull/215](https://togithub.com/fastify/fastify-secure-session/pull/215) - build(deps-dev): bump tsd from 0.30.7 to 0.31.0 by [@dependabot](https://togithub.com/dependabot) in [https://github.com/fastify/fastify-secure-session/pull/221](https://togithub.com/fastify/fastify-secure-session/pull/221) #### New Contributors - [@acro5piano](https://togithub.com/acro5piano) made their first contribution in [https://github.com/fastify/fastify-secure-session/pull/215](https://togithub.com/fastify/fastify-secure-session/pull/215) **Full Changelog**: https://github.com/fastify/fastify-secure-session/compare/v7.2.0...v7.3.0 ### [`v7.1.0`](https://togithub.com/fastify/fastify-secure-session/releases/tag/v7.1.0) [Compare Source](https://togithub.com/fastify/fastify-secure-session/compare/v7.0.0...v7.1.0) #### What's Changed - add .touch() method by [@Momy93](https://togithub.com/Momy93) in [https://github.com/fastify/fastify-secure-session/pull/198](https://togithub.com/fastify/fastify-secure-session/pull/198) #### New Contributors - [@Momy93](https://togithub.com/Momy93) made their first contribution in [https://github.com/fastify/fastify-secure-session/pull/198](https://togithub.com/fastify/fastify-secure-session/pull/198) **Full Changelog**: https://github.com/fastify/fastify-secure-session/compare/v7.0.0...v7.1.0 ### [`v7.0.0`](https://togithub.com/fastify/fastify-secure-session/releases/tag/v7.0.0) [Compare Source](https://togithub.com/fastify/fastify-secure-session/compare/v6.2.0...v7.0.0) #### What's Changed - build(deps): bump [@fastify/cookie](https://togithub.com/fastify/cookie) from 8.3.0 to 9.0.4 by [@dependabot](https://togithub.com/dependabot) in [https://github.com/fastify/fastify-secure-session/pull/194](https://togithub.com/fastify/fastify-secure-session/pull/194) - fix: broken link by [@Zamiell](https://togithub.com/Zamiell) in [https://github.com/fastify/fastify-secure-session/pull/195](https://togithub.com/fastify/fastify-secure-session/pull/195) #### New Contributors - [@Zamiell](https://togithub.com/Zamiell) made their first contribution in [https://github.com/fastify/fastify-secure-session/pull/195](https://togithub.com/fastify/fastify-secure-session/pull/195) **Full Changelog**: https://github.com/fastify/fastify-secure-session/compare/v6.2.0...v7.0.0 ### [`v6.2.0`](https://togithub.com/fastify/fastify-secure-session/releases/tag/v6.2.0) [Compare Source](https://togithub.com/fastify/fastify-secure-session/compare/v6.1.0...v6.2.0) #### What's Changed - ci: only trigger on pushes to main branches by [@Fdawgs](https://togithub.com/Fdawgs) in [https://github.com/fastify/fastify-secure-session/pull/188](https://togithub.com/fastify/fastify-secure-session/pull/188) - build(deps-dev): bump [@types/node](https://togithub.com/types/node) from 18.16.5 to 20.1.0 by [@dependabot](https://togithub.com/dependabot) in [https://github.com/fastify/fastify-secure-session/pull/189](https://togithub.com/fastify/fastify-secure-session/pull/189) - chore: use isArray and isBuffer by [@is2ei](https://togithub.com/is2ei) in [https://github.com/fastify/fastify-secure-session/pull/191](https://togithub.com/fastify/fastify-secure-session/pull/191) - pass the secret to fastify cookie if directly registered by [@gurgunday](https://togithub.com/gurgunday) in [https://github.com/fastify/fastify-secure-session/pull/193](https://togithub.com/fastify/fastify-secure-session/pull/193) #### New Contributors - [@gurgunday](https://togithub.com/gurgunday) made their first contribution in [https://github.com/fastify/fastify-secure-session/pull/193](https://togithub.com/fastify/fastify-secure-session/pull/193) **Full Changelog**: https://github.com/fastify/fastify-secure-session/compare/v6.1.0...v6.2.0 ### [`v6.1.0`](https://togithub.com/fastify/fastify-secure-session/releases/tag/v6.1.0) [Compare Source](https://togithub.com/fastify/fastify-secure-session/compare/v6.0.0...v6.1.0) #### What's Changed - fix: 134 document genkey without npx by [@davideroffo](https://togithub.com/davideroffo) in [https://github.com/fastify/fastify-secure-session/pull/180](https://togithub.com/fastify/fastify-secure-session/pull/180) - chore(.gitignore): add bun lockfile by [@Fdawgs](https://togithub.com/Fdawgs) in [https://github.com/fastify/fastify-secure-session/pull/181](https://togithub.com/fastify/fastify-secure-session/pull/181) - build(deps-dev): bump tsd from 0.25.0 to 0.26.0 by [@dependabot](https://togithub.com/dependabot) in [https://github.com/fastify/fastify-secure-session/pull/182](https://togithub.com/fastify/fastify-secure-session/pull/182) - build(deps-dev): bump tsd from 0.26.1 to 0.27.0 by [@dependabot](https://togithub.com/dependabot) in [https://github.com/fastify/fastify-secure-session/pull/183](https://togithub.com/fastify/fastify-secure-session/pull/183) - build(deps-dev): bump tsd from 0.27.0 to 0.28.0 by [@dependabot](https://togithub.com/dependabot) in [https://github.com/fastify/fastify-secure-session/pull/185](https://togithub.com/fastify/fastify-secure-session/pull/185) - Fix maxAge time example by [@michalzalobny](https://togithub.com/michalzalobny) in [https://github.com/fastify/fastify-secure-session/pull/184](https://togithub.com/fastify/fastify-secure-session/pull/184) - add support for custom session key and multiple sessions by [@jsprw](https://togithub.com/jsprw) in [https://github.com/fastify/fastify-secure-session/pull/186](https://togithub.com/fastify/fastify-secure-session/pull/186) #### New Contributors - [@davideroffo](https://togithub.com/davideroffo) made their first contribution in [https://github.com/fastify/fastify-secure-session/pull/180](https://togithub.com/fastify/fastify-secure-session/pull/180) - [@michalzalobny](https://togithub.com/michalzalobny) made their first contribution in [https://github.com/fastify/fastify-secure-session/pull/184](https://togithub.com/fastify/fastify-secure-session/pull/184) - [@jsprw](https://togithub.com/jsprw) made their first contribution in [https://github.com/fastify/fastify-secure-session/pull/186](https://togithub.com/fastify/fastify-secure-session/pull/186) **Full Changelog**: https://github.com/fastify/fastify-secure-session/compare/v6.0.0...v6.1.0Configuration
π Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).
π¦ Automerge: Disabled by config. Please merge this manually once you are satisfied.
β» Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
π Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.