async fn reply(&mut self, error: &ReplyError) -> Result<()> {
        let reply = &[
            consts::SOCKS5_VERSION,
            error.as_u8(), // transform the error into byte code
            0x00,          // reserved
            1,             // address type (ipv4, v6, domain)
            127,           // ip
            0,
            0,
            1,
            0, // port
            0,
        ];
        debug!("reply error to be written: {:?}", &reply);

        self.inner
            .write(reply)
            .await
            .context("Can't write the reply!")?;

        self.inner.flush().await.context("Can't flush the reply!")?;

        Ok(())
    }
/// Reply to the client with the correct reply code according to the RFC.
Reply to the client with the correct reply code according to the RFC.
Reply to the client with the correct reply code according to the RFC .
async fn reply(&mut self, error: &ReplyError) -> Result<()> {
        let reply = &[
            consts::SOCKS5_VERSION,
            error.as_u8(), // transform the error into byte code
            0x00,          // reserved
            1,             // address type (ipv4, v6, domain)
            127,           // ip
            0,
            0,
            1,
            0, // port
            0,
        ];
        debug!("reply error to be written: {:?}", &reply);
        self.inner
            .write(reply)
            .await
            .context("Can't write the reply!")?;
        self.inner.flush().await.context("Can't flush the reply!")?;
        Ok(())
    }
async fn reply ( & mut self , error : & ReplyError ) -> Result < ( ) > { let reply = & [ consts :: SOCKS5_VERSION , error . as_u8 ( ) , // transform the error into byte code 0x00 , // reserved 1 , // address type (ipv4, v6, domain) 127 , // ip 0 , 0 , 1 , 0 , // port 0 , ] ; debug ! ( " " reply ) ; self . inner . write ( reply ) . await . context ( " " ) ? ; self . inner . flush ( ) . await . context ( " " ) ? ; Ok ( ( ) ) }
Reply to the client with the correct reply code according to the RFC.
Reply to the client with the correct reply code according to the RFC .
&mut self
error
&ReplyError
&mut self
error
&ReplyError