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

Update rust crate lru #5132

Closed
mreynolds389 opened this issue Jan 24, 2022 · 3 comments
Closed

Update rust crate lru #5132

mreynolds389 opened this issue Jan 24, 2022 · 3 comments
Assignees
Labels
security Security Issue
Milestone

Comments

@mreynolds389
Copy link
Contributor

Issue Description

A CVE was discovered in the Rust create lru that 389-ds-base was using.

CVE-2021-45720 389-ds-base: bundled lru: Use after free in lru crate

https://bugzilla.redhat.com/show_bug.cgi?id=2044430

@mreynolds389 mreynolds389 added the security Security Issue label Jan 24, 2022
@mreynolds389 mreynolds389 added this to the 1.4.3 milestone Jan 24, 2022
@mreynolds389 mreynolds389 self-assigned this Jan 24, 2022
@mreynolds389 mreynolds389 changed the title Update rust create lru Update rust crate lru Jan 24, 2022
mreynolds389 added a commit to mreynolds389/389-ds-base that referenced this issue Jan 24, 2022
Description:

A CVE was discovered in the Rust create lru that
389-ds-base was using.  CVE-2021-45720  bundled
lru: Use after free in lru crate

https://bugzilla.redhat.com/show_bug.cgi?id=2044430

relates: 389ds#5132

Reviewed by: ?
mreynolds389 added a commit that referenced this issue Jan 24, 2022
Description:

A CVE was discovered in the Rust create lru that
389-ds-base was using.  CVE-2021-45720  bundled
lru: Use after free in lru crate

https://bugzilla.redhat.com/show_bug.cgi?id=2044430

relates: #5132

Reviewed by: ?
mreynolds389 added a commit that referenced this issue Jan 24, 2022
Description:

A CVE was discovered in the Rust create lru that
389-ds-base was using.  CVE-2021-45720  bundled
lru: Use after free in lru crate

https://bugzilla.redhat.com/show_bug.cgi?id=2044430

relates: #5132

Reviewed by: ?
mreynolds389 added a commit that referenced this issue Jan 24, 2022
Description:

A CVE was discovered in the Rust create lru that
389-ds-base was using.  CVE-2021-45720  bundled
lru: Use after free in lru crate

https://bugzilla.redhat.com/show_bug.cgi?id=2044430

relates: #5132

Reviewed by: ?
@vashirov
Copy link
Member

vashirov commented Jan 25, 2022

I'm doing builds for EPEL8 and I ran into problems with concread and lru crates:
>=concread-0.2.21 requires rust-1.56+ which is not available in el8.5 (will be in el8.6).
concread-0.2.20 has a dependency on the vulnerable version of lru.

So we either have a broken build or a vulnerable one.

I have a silly patch that changes edition in Cargo.toml for concread to 2018 and updates checksums. But I'm open to other suggestions.

@mreynolds389
Copy link
Contributor Author

I'm doing builds for EPEL8 and I ran into problems with concread and lru crates: >=concread-0.2.21 requires rust-1.56+ which is not available in el8.5 (will be in el8.6). concread-0.2.20 has a dependency on the vulnerable version of lru.

So we either have a broken build or a vulnerable one.

We have to leave it vulnerable in EPEL I suspect, as it needs to be fixed in Fedora where the original CVE was found.

I have a silly patch that changes edition in Cargo.toml for concread to 2018 and updates checksums. But I'm open to other suggestions.

Not sure what else we can do besides wait for el8.6 (or el9?). I did see that we had pinned the version to 0.2.20, but I thought that was for RHEL, not EPEL. What is this patch you have, can we see it?

@vashirov
Copy link
Member

Here's the patch: https://src.fedoraproject.org/rpms/389-ds-base/blob/stable/f/concread-use-2018-edition.patch
I'm fighting with MBS currently, there is a build in progress: https://release-engineering.github.io/mbs-ui/module/13724 So hopefully we can release a fixed version in EPEL.

vashirov referenced this issue Jan 26, 2022
Bug Description: an update to concread changed how the cache was
constructed and how stats are used.

Fix Description: Update to adapt to these changes. Additionally
this update has a number of performance improvements.

fixes: #5046

Author: William Brown <william@blackhats.net.au>

Review by: @vashirov, @droideck
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
security Security Issue
Projects
None yet
Development

No branches or pull requests

2 participants