#[non_exhaustive]pub struct Config { /* private fields */ }Expand description
RSA accelerator configuration.
The default is the most secure: constant time on and search acceleration off. The ESP32 has
neither option, so its Config is empty.
Implementations§
Source§impl Config
impl Config
Sourcepub fn with_constant_time(self, constant_time: bool) -> Self
pub fn with_constant_time(self, constant_time: bool) -> Self
Assign the given value to the constant_time field.
Sourcepub fn constant_time(&self) -> bool
pub fn constant_time(&self) -> bool
Constant time operation for modular exponentiation.
Turning it off makes modular exponentiation faster for an exponent with many 0 bits, and exposes the exponent to timing-based side-channel attacks. Turn it off only for a public exponent, such as when verifying a signature.
Default value: true.
Sourcepub fn with_search_acceleration(self, search_acceleration: bool) -> Self
pub fn with_search_acceleration(self, search_acceleration: bool) -> Self
Assign the given value to the search_acceleration field.
Sourcepub fn search_acceleration(&self) -> bool
pub fn search_acceleration(&self) -> bool
Search acceleration for modular exponentiation.
Turning it on makes modular exponentiation faster by skipping the exponent’s bits above its most significant set bit, and exposes the exponent’s length. Turn it on only for a public exponent, such as when verifying a signature.
Default value: false.
Trait Implementations§
impl Copy for Config
unstable only.impl Eq for Config
unstable only.impl StructuralPartialEq for Config
unstable only.Auto Trait Implementations§
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnsafeUnpin for Config
impl UnwindSafe for Config
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
clone_to_uninit)