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

Fix CVE-2023-38497 for beta 1.72.0 #12442

Merged
merged 4 commits into from
Aug 3, 2023

Commits on Jul 29, 2023

  1. test: verify permissions bits are preserved when unpacking

    This is not secure and will be fixed in the next commit.
    weihanglo committed Jul 29, 2023
    Configuration menu
    Copy the full SHA
    d8c62e6 View commit details
    Browse the repository at this point in the history

Commits on Aug 3, 2023

  1. fix: respect umask when unpacking .crate files

    Without this, an attacker can leverage globally writable files buried
    in the `.crate` file. After a user downloaded and unpacked the file,
    the attacker can then write malicous code to the downloaded sources.
    weihanglo committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    a40a0aa View commit details
    Browse the repository at this point in the history
  2. fix: clear cache for old .cargo-ok format

    In 1.71, `.cargo-ok` changed to contain a JSON `{ v: 1 }` to indicate
    the version of it. A failure of parsing will result in a heavy-hammer
    approach that unpacks the `.crate` file again. This is in response to a
    security issue that the unpacking didn't respect umask on Unix systems.
    weihanglo committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    b05657d View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    6aa9859 View commit details
    Browse the repository at this point in the history