[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-devel] [bug #37969] SYN packet dropped as short packet in tcp_inpu

From: Riccardo Manfrin
Subject: [lwip-devel] [bug #37969] SYN packet dropped as short packet in tcp_input function
Date: Fri, 21 Dec 2012 12:56:04 +0000
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:14.0) Gecko/20100101 Firefox/14.0.1


                 Summary: SYN packet dropped as short packet in tcp_input
                 Project: lwIP - A Lightweight TCP/IP stack
            Submitted by: riccardomanfrin
            Submitted on: Fri 21 Dec 2012 12:56:02 PM GMT
                Category: TCP
                Severity: 3 - Normal
              Item Group: Faulty Behaviour
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: 
            lwIP version: 1.4.0



I'm integrating lwIP 1.4.0 in a NXP LPC cortex m3. I'm not using an operating

I'm experiencing a drop on TCP SYN packets in tcp_input.c at this point (in
tcp_input function):

  /* Move the payload pointer in the pbuf so that it points to the
     TCP data instead of the TCP header. */
  hdrlen = TCPH_HDRLEN(tcphdr);
  if(pbuf_header(p, -(hdrlen * 4))){
    /* drop short packets */
    LWIP_DEBUGF(TCP_INPUT_DEBUG, ("tcp_input: short packetn"));

In short the (increment_magnitude <= p->len) check fails as the increment is
by 40 bytes and p->len is 30. Actually, the packet is 40 bytes long but
splitted in to pbufs chunks (30+10). 

I wonder if this is the usual way of processing the SYN but I would expect the
SYN/ACK message to be sent in these cases.

As I drop the packet, the accept callback is not invoked and consequently I
cannot enstablish the TCP connection.

Riccardo Manfrin


Reply to this item at:


  Message sent via/by Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]