Struct rshijack::net::Connection[][src]

pub struct Connection {
    pub src: SocketAddr,
    pub dst: SocketAddr,
    pub seq: Arc<Mutex<u32>>,
    pub ack: Arc<Mutex<u32>>,
}

Fields

src: SocketAddrdst: SocketAddrseq: Arc<Mutex<u32>>ack: Arc<Mutex<u32>>

Implementations

impl Connection[src]

pub fn new(src: SocketAddr, dst: SocketAddr, seq: u32, ack: u32) -> Connection[src]

pub fn bump_seq(&self, inc: u32)[src]

pub fn set_ack(&self, ack: u32)[src]

pub fn get_seq(&self) -> u32[src]

pub fn get_ack(&self) -> u32[src]

pub fn sendtcp(
    &mut self,
    tx: &mut TransportSender,
    flags: u16,
    data: &[u8]
) -> Result<()>
[src]

pub fn ack(
    &mut self,
    tx: &mut TransportSender,
    ack: u32,
    data: &[u8]
) -> Result<()>
[src]

pub fn reset(&mut self, tx: &mut TransportSender) -> Result<()>[src]

Trait Implementations

impl Clone for Connection[src]

impl Debug for Connection[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.