How to Distinguish between a reset packet and a normal packet - Networking

This is a discussion on How to Distinguish between a reset packet and a normal packet - Networking ; How Distinguish between a Reset Packet and a normal Data or Ack or Request packet....

+ Reply to Thread
Results 1 to 5 of 5

Thread: How to Distinguish between a reset packet and a normal packet

  1. How to Distinguish between a reset packet and a normal packet

    How Distinguish between a Reset Packet and a normal Data or Ack or
    Request packet.


  2. Re: How to Distinguish between a reset packet and a normal packet

    On Thu, 22 Mar 2007 21:09:45 -0700, sairam wrote:

    > How Distinguish between a Reset Packet and a normal Data or Ack or
    > Request packet.


    That's a pretty vague question. In what context? What protocol are you
    talking about?

    If you're talking about TCP, in a reset packet, the RST bit in the header
    is set. In an Ack packet the ACK bit is set.

    Dan


  3. Re: How to Distinguish between a reset packet and a normal packet


    Dan N wrote:
    > On Thu, 22 Mar 2007 21:09:45 -0700, sairam wrote:
    >
    > > How Distinguish between a Reset Packet and a normal Data or Ack or
    > > Request packet.

    >
    > That's a pretty vague question. In what context? What protocol are you
    > talking about?
    >
    > If you're talking about TCP, in a reset packet, the RST bit in the header
    > is set. In an Ack packet the ACK bit is set.
    >
    > Dan


    Iam talking in the sense of programming, when received a packet in my
    program it strips off all the header content, then how can I know the
    packet is a RST packet

    Sairam


  4. Re: How to Distinguish between a reset packet and a normal packet

    sairam wrote:
    > Dan N wrote:
    >> On Thu, 22 Mar 2007 21:09:45 -0700, sairam wrote:
    >>
    >>> How Distinguish between a Reset Packet and a normal Data or Ack or
    >>> Request packet.

    >> That's a pretty vague question. In what context? What protocol are you
    >> talking about?
    >>
    >> If you're talking about TCP, in a reset packet, the RST bit in the header
    >> is set. In an Ack packet the ACK bit is set.
    >>
    >> Dan

    >
    > Iam talking in the sense of programming, when received a packet in my
    > program it strips off all the header content, then how can I know the
    > packet is a RST packet


    http://www.networksorcery.com/enp/protocol/tcp.htm

    You just have to check if the RST bit (which is, i think, the 142 bit
    in the tcp header) is 1 or 0.

    Matthias


  5. Re: How to Distinguish between a reset packet and a normal packet

    On Fri, 23 Mar 2007 03:14:47 -0700, sairam wrote:

    > Iam talking in the sense of programming, when received a packet in my
    > program it strips off all the header content, then how can I know the
    > packet is a RST packet


    You should think in terms of a stream of data, not in terms of the
    underlying protocol. When you get a read of zero bytes, then you know
    that the stream has ended. The applications level doesn't know about
    reset packets.

    Dan


+ Reply to Thread