src/chromium/adding-third-party-crates/reviews-and-audits.md
Adding new libraries is subject to Chromium's standard policies, but of course also subject to security review. As you may be bringing in not just a single crate but also transitive dependencies, there may be a substantial amount of code to review. On the other hand, safe Rust code can have limited negative side effects. How should you review it?
Over time Chromium aims to move to a process based around cargo vet.
Meanwhile, for each new crate addition, we are checking for the following:
build.rs or procedural macros,
work out what they're for. Are they compatible with the way Chromium is
normally built?cd third-party/rust/chromium_crates_io; cargo audit to check for known
vulnerabilities (first you'll need to cargo install cargo-audit, which
ironically involves downloading lots of dependencies from the internet2)unsafe code is good enough for the Rule of Twofs or net APIsThese are just guidelines --- work with reviewers from [email protected]
to work out the right way to become confident of the crate.