pub struct RelayConn { /* private fields */ }Expand description
One inbound SMB client being relayed: instead of answering the NTLM challenge with our own fixed value (capture), we hand the victim’s Type1 out to the caller, relay back the target’s Type2, and surrender the victim’s Type3 — so the caller can complete an authenticated session to a third-party target as the victim.
Implementations§
Source§impl RelayConn
impl RelayConn
pub fn new(stream: TcpStream) -> Self
Sourcepub async fn recv_type1(&mut self) -> Result<Vec<u8>>
pub async fn recv_type1(&mut self) -> Result<Vec<u8>>
Handle NEGOTIATE and the first SESSION_SETUP; return the victim’s NTLM Type1.
Sourcepub async fn send_challenge(&mut self, type2: &[u8]) -> Result<()>
pub async fn send_challenge(&mut self, type2: &[u8]) -> Result<()>
Relay the target’s Type2 challenge back to the victim.
Sourcepub async fn recv_type3(&mut self) -> Result<Vec<u8>>
pub async fn recv_type3(&mut self) -> Result<Vec<u8>>
Receive the victim’s Type3 (computed over the target’s challenge).
Auto Trait Implementations§
impl !Freeze for RelayConn
impl RefUnwindSafe for RelayConn
impl Send for RelayConn
impl Sync for RelayConn
impl Unpin for RelayConn
impl UnsafeUnpin for RelayConn
impl UnwindSafe for RelayConn
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