Crate aarch64_dit

Crate aarch64_dit 

Source
Expand description

§RustCrypto: AArch64 Data-Independent Timing (DIT)

Crate Docs Build Status Apache 2.0/MIT Licensed MSRV

Wrappers for enabling/disabling the Data-Independent Timing feature of modern AArch64 CPUs which can be used to help ensure that instructions take a constant amount of time regardless of input data, thus preventing potential information leaks via timing sidechannels.

Documentation

§Minimum Supported Rust Version

Rust 1.61 or newer.

In the future, we reserve the right to change MSRV (i.e. MSRV is out-of-scope for this crate’s SemVer guarantees), however when we do it will be accompanied by a minor version bump.

§License

Licensed under either of:

at your option.

§Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

§Usage

use aarch64_dit::Dit;

let dit = Dit::init();
assert!(!dit.is_enabled());
let _guard = dit.enable();
assert!(dit.is_enabled());

Structs§

Dit
Data-Independent Timing: support for enabling features of AArch64 CPUs which improve constant-time operation.
Guard
RAII guard which returns DIT to its previous state when dropped.