Skip to content

Commit 84b0737

Browse files
authored
Merge pull request #3570 from joske/audit
chore: add audit.toml to ignore known unmaintained crates
2 parents 73d6398 + b8550fe commit 84b0737

4 files changed

Lines changed: 51 additions & 221 deletions

File tree

.cargo/audit.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[advisories]
2+
ignore = [
3+
# As the rust community considers the paste crate 'done', we can safely ignore this warning.
4+
# see https://users.rust-lang.org/t/paste-alternatives/126787/2
5+
"RUSTSEC-2024-0436",
6+
]

.circleci/config.yml

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -400,16 +400,33 @@ jobs:
400400
steps:
401401
- checkout
402402
- setup_environment:
403-
cache_key: v3.3.1-rust-1.83.0--cache
403+
cache_key: v3.3.1-rust-1.83.0-machete-cache
404404
- run:
405405
name: Check for unused dependencies
406-
no_output_timeout: 35m
406+
no_output_timeout: 10m
407407
command: |
408408
cargo install cargo-machete@0.7.0
409409
cargo machete
410410
- clear_environment:
411411
cache_key: v3.3.1-rust-1.83.0-machete-cache
412412

413+
check-cargo-audit:
414+
docker:
415+
- image: cimg/rust:1.83.0 # Attention - Change the MSRV in Cargo.toml and rust-toolchain as well
416+
resource_class: << pipeline.parameters.medium >>
417+
steps:
418+
- checkout
419+
- setup_environment:
420+
cache_key: v3.3.1-rust-1.83.0-cargo-audit-cache
421+
- run:
422+
name: Check for security vulnerabilities
423+
no_output_timeout: 10m
424+
command: |
425+
cargo install cargo-audit@0.21.2 --locked
426+
cargo audit -D warnings
427+
- clear_environment:
428+
cache_key: v3.3.1-rust-1.83.0-cargo-audit-cache
429+
413430
check-clippy:
414431
docker:
415432
- image: cimg/rust:1.83.0 # Attention - Change the MSRV in Cargo.toml and rust-toolchain as well
@@ -466,6 +483,7 @@ workflows:
466483
- check-fmt
467484
- check-clippy
468485
- check-unused-dependencies
486+
- check-cargo-audit
469487
- devnet-test
470488

471489
windows-workflow:

0 commit comments

Comments
 (0)