Checklist
Legend: đ Must have, âī¸ Should have, đ Nice to have, âšī¸ Info
Manage dependencies
- đ Transitive dependencies number is minimized by selecting only the required features (DEPS-FEATURES)
- đ Dependencies are vetted (DEPS-ASSESS)
-
đ Dependencies are reviewed using
cargo vet
(DEPS-VET) - đ Known vulnerabilities and unmaintained crates are regularly checked (DEPS-VULNS)
- đ Dependencies are kept up-to-date (DEPS-UPDATES)
Maintain a crate
-
Sources of binary programs include necessary information to make the builds consistent
-
đ The
Cargo.lock
file is committed to your repository (when developing binary programs) (MAINTAIN-LOCK) -
đ The
rust-toolchain.toml
file is committed to your repository (when developing binary programs) (MAINTAIN-TOOLCHAIN)
-
đ The
- đ Crate features allow to only include transitive dependencies required for a given use case (MAINTAIN-FEATURES)
-
Maintaining a
-sys
crate building C/C++ code- âī¸ Provide flags to control the behavior (MAINTAIN-SRCFLAG) { #MAINTAIN-SRCFLAG }
-
âī¸ Use a dedicated
-src
crate (MAINTAIN-SRCCRATE) { #MAINTAIN-SRCCRATE }
- đ Known vulnerabilities are reported to RustSec (MAINTAIN-VULNS)
-
Publication access to crates.io is secured
- đ The GitHub accounts owning the crates have 2FA enabled (MAINTAIN-CRATESIO2FA)
- đ All tokens have limited rights (MAINTAIN-CRATESIOTKN)
- âī¸ Apply code security best practices (MAINTAIN-CODESEC)
Build for production
- đ Build uses a trusted toolchain (BUILD-TOOLCHAIN)
-
đ Build uses
--locked
for reproducibility (BUILD-LOCKED) - đ Build is fully reproducible (BUILD-REPRODUCIBLE)
- âī¸ Build environment is ephemeral and isolated (BUILD-ISOLATED)
-
âī¸ Build uses
cargo auditable
to embed dependencies information (BUILD-AUDITABLE) - đ Built binaries are signed (BUILD-SIGN)
- âšī¸ Build produces a Software Bill of Materials (BUILD-SBOM)
Run in production
- âī¸ Production artifacts are regularly checked for vulnerabilities (PROD-AUDIT)