Skip to content
New issue

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

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

Already on GitHub? # to your account

simple-slab: index() allows out-of-bound read and remove() has off-by-one error #376

Merged
merged 1 commit into from
Sep 4, 2020

Conversation

Qwaz
Copy link
Contributor

@Qwaz Qwaz commented Sep 4, 2020

Slab::index() does not perform the boundary checking, which leads to out-of-bound read access. Slab::remove() copies an element from an invalid address due to off-by-one error, resulting in memory leakage and uninitialized memory drop.

Original issue report: nathansizemore/simple-slab#2

title = "`index()` allows out-of-bound read and `remove()` has off-by-one error"
url = "https://github.com/nathansizemore/simple-slab/issues/2"
description = """
`Slab::index()` does not perform the boundary checking, which leads to out-of-bound read access. `Slab::remove()` copies an element from an invalid address due to off-by-one error, resulting in memory leakage and uninitialized memory drop.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line is too long. Do we have tidy guideline about this ?

@Shnatsel Shnatsel merged commit 4947069 into rustsec:master Sep 4, 2020
@Qwaz Qwaz deleted the 0013-simple-slab branch January 13, 2021 16:38
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants