Skip to content

Update gix version - #455

Open
PuercoPop wants to merge 2 commits into
Canop:mainfrom
PuercoPop:update-gix
Open

Update gix version#455
PuercoPop wants to merge 2 commits into
Canop:mainfrom
PuercoPop:update-gix

Conversation

@PuercoPop

Copy link
Copy Markdown

Hi, thanks for bacon 🐽 .

The version of the indirect dependency gix-date has a security advisory open
against it. See https://rustsec.org/advisories/RUSTSEC-2025-0140. Update to the
latest gix version so that we depend on version of gix-date that doesn't have
any advisory open against it.

$ cargo audit
    Fetching advisory database from `https://github.com/RustSec/advisory-db.git`
      Loaded 1190 security advisories (from /home/puercopop/.cargo/advisory-db)
    Updating crates.io index
    Scanning Cargo.lock for vulnerabilities (380 crate dependencies)
Crate:     gix-date
Version:   0.10.5
Title:     Non-utf8 String can be created with `TimeBuf::as_str`
Date:      2025-12-29
ID:        RUSTSEC-2025-0140
URL:       https://rustsec.org/advisories/RUSTSEC-2025-0140
Solution:  Upgrade to >=0.12.0
[...]
error: 1 vulnerability found!
warning: 1 allowed warning found

Had to enable the sha1 feature for git as part of the update. The rationale is in the commit message.

Afterwards cargo audit only lists the warning about the paste crate being unmaintained.

The version of the indirect dependency gix-date has a security advisory open
against it. See https://rustsec.org/advisories/RUSTSEC-2025-0140. Update to the
latest gix version so that we depend on version of gix-date that doesn't have
any advisory open against it.

```
$ cargo audit
    Fetching advisory database from `https://github.com/RustSec/advisory-db.git`
      Loaded 1190 security advisories (from /home/puercopop/.cargo/advisory-db)
    Updating crates.io index
    Scanning Cargo.lock for vulnerabilities (380 crate dependencies)
Crate:     gix-date
Version:   0.10.5
Title:     Non-utf8 String can be created with `TimeBuf::as_str`
Date:      2025-12-29
ID:        RUSTSEC-2025-0140
URL:       https://rustsec.org/advisories/RUSTSEC-2025-0140
Solution:  Upgrade to >=0.12.0
[...]
error: 1 vulnerability found!
warning: 1 allowed warning found
```
The new version of gix requires to either enable the sha1 or sha256 feature
flags. The default is sha1, but we disable the default features. Enable it.

```
error: Please set either the `sha1` or the `sha256` feature flag
  --> /home/puercopop/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/gix-hash-0.26.0/src/lib.rs:32:1
   |
32 | compile_error!("Please set either the `sha1` or the `sha256` feature flag");
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
``
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 this pull request may close these issues.

1 participant