{"id":13472283,"url":"https://github.com/model-checking/kani","last_synced_at":"2025-05-12T13:21:45.925Z","repository":{"id":37069126,"uuid":"351882164","full_name":"model-checking/kani","owner":"model-checking","description":"Kani Rust Verifier","archived":false,"fork":false,"pushed_at":"2025-05-05T13:33:42.000Z","size":34562,"stargazers_count":2536,"open_issues_count":523,"forks_count":111,"subscribers_count":24,"default_branch":"main","last_synced_at":"2025-05-05T14:47:11.888Z","etag":null,"topics":["model-checking","rust","verification"],"latest_commit_sha":null,"homepage":"https://model-checking.github.io/kani","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/model-checking.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE-APACHE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":".github/SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-03-26T18:49:50.000Z","updated_at":"2025-05-05T13:31:01.000Z","dependencies_parsed_at":"2022-07-12T16:13:43.920Z","dependency_job_id":"8bd3d65f-d1b6-43c0-9056-7d86a126a99c","html_url":"https://github.com/model-checking/kani","commit_stats":{"total_commits":1057,"total_committers":38,"mean_commits":27.81578947368421,"dds":0.7634815515610218,"last_synced_commit":"939a29f204e7593f6d3e895ea3af035bba518ca9"},"previous_names":[],"tags_count":62,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/model-checking%2Fkani","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/model-checking%2Fkani/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/model-checking%2Fkani/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/model-checking%2Fkani/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/model-checking","download_url":"https://codeload.github.com/model-checking/kani/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253148081,"owners_count":21861704,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["model-checking","rust","verification"],"created_at":"2024-07-31T16:00:53.533Z","updated_at":"2025-05-12T13:21:45.898Z","avatar_url":"https://github.com/model-checking.png","language":"Rust","readme":"![](./kani-logo.png)\n[![Kani regression](https://github.com/model-checking/kani/actions/workflows/kani.yml/badge.svg)](https://github.com/model-checking/kani/actions/workflows/kani.yml)\n[![Nightly: CBMC Latest](https://github.com/model-checking/kani/actions/workflows/cbmc-latest.yml/badge.svg)](https://github.com/model-checking/kani/actions/workflows/cbmc-latest.yml)\n\nThe Kani Rust Verifier is a bit-precise model checker for Rust.\n\nKani is particularly useful for verifying unsafe code blocks in Rust, where the \"[unsafe superpowers](https://doc.rust-lang.org/stable/book/ch19-01-unsafe-rust.html#unsafe-superpowers)\" are unchecked by the compiler.\n___\nKani verifies:\n * Memory safety (e.g., null pointer dereferences)\n * User-specified assertions (i.e., `assert!(...)`)\n * The absence of panics (e.g., `unwrap()` on `None` values)\n * The absence of some types of unexpected behavior (e.g., arithmetic overflows)\n\n## Installation\n\nTo install the latest version of Kani ([Rust 1.58+; Linux or Mac](https://model-checking.github.io/kani/install-guide.html)), run:\n\n```bash\ncargo install --locked kani-verifier\ncargo kani setup\n```\n\nSee [the installation guide](https://model-checking.github.io/kani/install-guide.html) for more details.\n\n## How to use Kani\n\nSimilar to testing, you write a harness, but with Kani you can check all possible values using `kani::any()`:\n\n```rust\nuse my_crate::{function_under_test, meets_specification, precondition};\n\n#[kani::proof]\nfn check_my_property() {\n   // Create a nondeterministic input\n   let input = kani::any();\n\n   // Constrain it according to the function's precondition\n   kani::assume(precondition(input));\n\n   // Call the function under verification\n   let output = function_under_test(input);\n\n   // Check that it meets the specification\n   assert!(meets_specification(input, output));\n}\n```\n\nKani will then try to prove that all valid inputs produce acceptable outputs, without panicking or executing unexpected behavior.\nOtherwise Kani will generate a trace that points to the failure.\nWe recommend following [the tutorial](https://model-checking.github.io/kani/kani-tutorial.html) to learn more about how to use Kani.\n\n## GitHub Action\n\nUse Kani in your CI with `model-checking/kani-github-action@VERSION`. See the\n[GitHub Action section in the Kani\nbook](https://model-checking.github.io/kani/install-github-ci.html)\nfor details.\n\n## Security\nSee [SECURITY](https://github.com/model-checking/kani/security/policy) for more information.\n\n## Contributing\nIf you are interested in contributing to Kani, please take a look at [the developer documentation](https://model-checking.github.io/kani/dev-documentation.html).\n\n## License\n### Kani\nKani is distributed under the terms of both the MIT license and the Apache License (Version 2.0).\n\nSee [LICENSE-APACHE](LICENSE-APACHE) and [LICENSE-MIT](LICENSE-MIT) for details.\n\n### Rust\nKani contains code from the Rust project.\nRust is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0), with portions covered by various BSD-like licenses.\n\nSee [the Rust repository](https://github.com/rust-lang/rust) for details.\n","funding_links":[],"categories":["Projects","Rust","Programming Languages"],"sub_categories":["Verification"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmodel-checking%2Fkani","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmodel-checking%2Fkani","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmodel-checking%2Fkani/lists"}