Rust Unsafe Review

Review, justify or remove unsafe code and FFI in Rust: require a written safety contract on every unsafe block (invariants relied on, who upholds them, why they hold here), shrink each block to one operation behind a safe API, ask first whether safe code or a vetted crate does the job, then test under Miri, loom and a sanitizer build, and check FFI boundaries for null and lifetime assumptions, ownership transfer, panics unwinding across extern "C" and manual Send and Sync impls. Use for "review this unsafe block", "is this transmute sound", "can we avoid unsafe here", "audit our FFI bindings", "we implement Send and Sync manually", "undefined behaviour in Rust". Not for general diff review (code-review), threat classes (security-review) or crash dumps from a binary (native-core-dump-analysis).

greenblacked Updated
The twenty-nine plugins: coding, family, gamedev, operations, delivery, security, manager, personal, career, design, llm, data, techdocs, assurance, client-apps

File contents

greenblacked/AI commit cc9c6924c1

Frequently asked questions

npx get-skill add greenblacked/rust-unsafe-review