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

Vulnerability in cbindgen due to dependency on an old clap release #899

Closed
NuLL3rr0r opened this issue Nov 10, 2023 · 2 comments · Fixed by #912
Closed

Vulnerability in cbindgen due to dependency on an old clap release #899

NuLL3rr0r opened this issue Nov 10, 2023 · 2 comments · Fixed by #912

Comments

@NuLL3rr0r
Copy link

NuLL3rr0r commented Nov 10, 2023

Simply running the following produces:

$ cargo audit

Crate:     atty
Version:   0.2.14
Warning:   unsound
Title:     Potential unaligned read
Date:      2021-07-04
ID:        RUSTSEC-2021-0145
URL:       https://rustsec.org/advisories/RUSTSEC-2021-0145
Dependency tree:
atty 0.2.14
└── clap 3.2.25
    └── cbindgen 0.26.0
        └── mylib 0.0.0-git
            └── myguiapp 0.0.0-git

warning: 1 allowed warning found

It seems newer clap won't rely on atty. And also the advisory URL states:

atty is Unmaintained
A Pull Request with a fix has been provided over a year ago but the maintainer seems to be unreachable.

Last release of atty was almost 3 years ago.

Please bump to a version without dependency on atty.

@NuLL3rr0r
Copy link
Author

NuLL3rr0r commented Nov 10, 2023

According to clap's changelog v4.0.27 is the first release without atty as a dependency:

4.0.27 - 2022-11-24

Features
- Have Arg::value_parser accept Vec<impl Into<PossibleValue>>
- Implement Display and FromStr for ColorChoice

Fixes
- Remove soundness issue by switching from atty to is-terminal

@diligence5087
Copy link

Duplicate of #880 .

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 a pull request may close this issue.

2 participants