Struct schannel::crypt_prov::AcquireOptions
source · pub struct AcquireOptions { /* private fields */ }
Expand description
A builder for CryptProv
s.
Implementations§
source§impl AcquireOptions
impl AcquireOptions
sourcepub fn new() -> AcquireOptions
pub fn new() -> AcquireOptions
Returns a new builder with default settings.
sourcepub fn container(&mut self, container: &str) -> &mut AcquireOptions
pub fn container(&mut self, container: &str) -> &mut AcquireOptions
Sets the name for this key container.
This should not be set if verify_context
is set.
sourcepub fn provider(&mut self, provider: &str) -> &mut AcquireOptions
pub fn provider(&mut self, provider: &str) -> &mut AcquireOptions
Sets the name of the CSP to be used.
sourcepub fn verify_context(&mut self, verify_context: bool) -> &mut AcquireOptions
pub fn verify_context(&mut self, verify_context: bool) -> &mut AcquireOptions
If set, private keys will not be accessible or persisted.
sourcepub fn new_keyset(&mut self, new_keyset: bool) -> &mut AcquireOptions
pub fn new_keyset(&mut self, new_keyset: bool) -> &mut AcquireOptions
If set, the container will be created.
sourcepub fn machine_keyset(&mut self, machine_keyset: bool) -> &mut AcquireOptions
pub fn machine_keyset(&mut self, machine_keyset: bool) -> &mut AcquireOptions
If set, the container will be stored as a machine rather than user keys.
sourcepub fn silent(&mut self, silent: bool) -> &mut AcquireOptions
pub fn silent(&mut self, silent: bool) -> &mut AcquireOptions
If set, an error will be returned if user intervention is required rather than displaying a dialog.
sourcepub fn acquire(&self, type_: ProviderType) -> Result<CryptProv>
pub fn acquire(&self, type_: ProviderType) -> Result<CryptProv>
Acquires a container.
Trait Implementations§
source§impl Default for AcquireOptions
impl Default for AcquireOptions
source§fn default() -> AcquireOptions
fn default() -> AcquireOptions
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl RefUnwindSafe for AcquireOptions
impl Send for AcquireOptions
impl Sync for AcquireOptions
impl Unpin for AcquireOptions
impl UnwindSafe for AcquireOptions
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more