pub struct SmartcardKey {
pub id: String,
pub pin: SecretString,
}
Expand description
Pointer to a key in a hardware token, along with an optional PIN.
This structure is sent in a Request::AddSmartcardKey
(SSH_AGENTC_ADD_SMARTCARD_KEY
) message.
Described in draft-miller-ssh-agent-14 § 3.2
Fields§
§id: String
An opaque identifier for the hardware token
Note: the interpretation of “id” is not defined by the protocol, but is left solely up to the agent.
pin: SecretString
An optional password to unlock the key
Trait Implementations§
Source§impl Clone for SmartcardKey
impl Clone for SmartcardKey
Source§fn clone(&self) -> SmartcardKey
fn clone(&self) -> SmartcardKey
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for SmartcardKey
impl Debug for SmartcardKey
Source§impl Decode for SmartcardKey
impl Decode for SmartcardKey
Source§impl Encode for SmartcardKey
impl Encode for SmartcardKey
Source§fn encoded_len(&self) -> Result<usize>
fn encoded_len(&self) -> Result<usize>
Get the length of this type encoded in bytes, prior to Base64 encoding.
Source§fn encode(&self, writer: &mut impl Writer) -> Result<()>
fn encode(&self, writer: &mut impl Writer) -> Result<()>
Encode this value using the provided
Writer
.Source§fn encoded_len_prefixed(&self) -> Result<usize, Error>
fn encoded_len_prefixed(&self) -> Result<usize, Error>
Return the length of this type after encoding when prepended with a
uint32
length prefix.Source§fn encode_prefixed(&self, writer: &mut impl Writer) -> Result<(), Error>
fn encode_prefixed(&self, writer: &mut impl Writer) -> Result<(), Error>
Encode this value, first prepending a
uint32
length prefix
set to Encode::encoded_len
.Source§impl PartialEq for SmartcardKey
impl PartialEq for SmartcardKey
Auto Trait Implementations§
impl Freeze for SmartcardKey
impl RefUnwindSafe for SmartcardKey
impl Send for SmartcardKey
impl Sync for SmartcardKey
impl Unpin for SmartcardKey
impl UnwindSafe for SmartcardKey
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