Skip to content

SECBUG-240 Fix out-of-bounds reads (backport to 4.15-stable)#326

Merged
jamis merged 2 commits intomongodb:4.15-stablefrom
jamis:secbug-240-backport
Apr 2, 2024
Merged

SECBUG-240 Fix out-of-bounds reads (backport to 4.15-stable)#326
jamis merged 2 commits intomongodb:4.15-stablefrom
jamis:secbug-240-backport

Conversation

@jamis
Copy link
Contributor

@jamis jamis commented Mar 28, 2024

Using strlen may result in reading beyond the end of the buffer (if the buffer is not null-terminated). For this reason, we should avoid using strlen and prefer a more explicit approach that also takes into account the size of the buffer.

(Backport of #325)

jamis and others added 2 commits March 28, 2024 13:53
* final tweaks for BSON 5 release

* SECBUG-240 strlen might read beyond end of buffer

* ruby 2.6 isn't supported

* nix 2.6
@jamis jamis requested a review from comandeo-mongo March 28, 2024 20:05
@jamis jamis merged commit dfbb4ed into mongodb:4.15-stable Apr 2, 2024
@jamis jamis deleted the secbug-240-backport branch April 2, 2024 14:11
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.

2 participants