pub struct SessionBind {
pub host_key: KeyData,
pub session_id: Vec<u8>,
pub signature: Signature,
pub is_forwarding: bool,
}
Expand description
session-bind@openssh.com
message extension.
This message extension allows an SSH client to bind an agent connection to a particular SSH session.
Note: This is an OpenSSH-specific extension to the agent protocol.
Described in OpenSSH PROTOCOL.agent § 1
Fields§
§host_key: KeyData
Server host public key.
session_id: Vec<u8>
Hash derived from the initial key exchange.
signature: Signature
Server’s signature of the session identifier using the private hostkey.
is_forwarding: bool
Flag indicating whether this connection should be bound for user authentication or forwarding.
Implementations§
Source§impl SessionBind
impl SessionBind
Sourcepub fn verify_signature(&self) -> Result<(), ProtoError>
pub fn verify_signature(&self) -> Result<(), ProtoError>
Verify the server’s signature of the session identifier
using the public host_key
.
When an agent receives [a
session-bind@openssh.com
message], it will verify the signature.
Described in OpenSSH PROTOCOL.agent § 1
Trait Implementations§
Source§impl Clone for SessionBind
impl Clone for SessionBind
Source§fn clone(&self) -> SessionBind
fn clone(&self) -> SessionBind
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 SessionBind
impl Debug for SessionBind
Source§impl Decode for SessionBind
impl Decode for SessionBind
Source§impl Encode for SessionBind
impl Encode for SessionBind
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 MessageExtension for SessionBind
impl MessageExtension for SessionBind
Source§impl PartialEq for SessionBind
impl PartialEq for SessionBind
impl StructuralPartialEq for SessionBind
Auto Trait Implementations§
impl Freeze for SessionBind
impl RefUnwindSafe for SessionBind
impl Send for SessionBind
impl Sync for SessionBind
impl Unpin for SessionBind
impl UnwindSafe for SessionBind
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