-
Notifications
You must be signed in to change notification settings - Fork 31
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
security: Avoid using buggy atty crate #45
Conversation
Switches to newer `is-terminal` crate instead. This functionality is also availible on the nightly Rust stdlib as a `std::io::IsTerminal` trait. Avoids RUSTSEC-2021-0145 (softprops/atty#50) Fixes slog-rs/slog#319 Based on the information in the vulnerability database, I don't consider this a particularly serious bug. > In practice however, the pointer won't be unaligned unless a custom global allocator is used.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, thanks!
|
That appears to be an unrelated issue. You can work around this issue by downgrading
|
Yes. Unfortunately cargo's dependency resolver doesn't respect Rust MSRV requirements :/ |
Hello! Just wondering if @Techcable I can help moving this PR forward. I'd like this PR merged because it's starting to give me GitHub dependabot warnings. Obviously I can just dismiss them (the atty issue cannot actually be exploited in my project) but I also like the slog-term crate, so if you want me to take over this PR and fix the once-cell issues I can do that. |
This doesn't quite work even with the once_cell issues fixed - https://github.com/sunfishcode/is-terminal/blob/main/Cargo.toml depends on rustix which depends on bitflags 2.3.3, which also has edition = 2021 (https://github.com/bitflags/bitflags/blob/main/Cargo.toml). This might need an MSRV bump - is_terminal has an MSRV of 1.63 and that's the lowest bump I could make work. #47 makes that bump on top of these commits. |
Bump MSRV to 1.63 Supersedes my PR #45
Merged #47, which supersedes this PR. |
Switches to newer
is-terminal
crate instead.This functionality is also availible on the nightly Rust stdlib as a
std::io::IsTerminal
trait.Avoids RUSTSEC-2021-0145 (softprops/atty#50)
Fixes slog-rs/slog#319
Based on the information in the vulnerability database, I don't consider this a particularly serious bug.