04 Jan, 2006

6 commits

  • The CCID should be notified of packet reception only when a packet is
    valid. Therefore, the ACK vector needs to be processed before
    notifying the CCID. Also, the CCID might need information provided by
    the ACK vector.

    Signed-off-by: Andrea Bittau
    Signed-off-by: Arnaldo Carvalho de Melo
    Signed-off-by: David S. Miller

    Andrea Bittau
     
  • If ACK vectors are used, each packet with an ACK should contain an ACK
    vector. The only exception currently is response packets. It
    probably is not a good idea to store ACK vector state before the
    connection is completed (to help protect from syn floods).

    Signed-off-by: Andrea Bittau
    Signed-off-by: Arnaldo Carvalho de Melo
    Signed-off-by: David S. Miller

    Andrea Bittau
     
  • When packets are received, the connection is either in DCCP_OPEN
    [fast-path] or it isn't. If it's not [e.g. DCCP_PARTOPEN] upper
    layers will perform sanity checks and parse options. If it is in
    DCCP_OPEN, dccp_rcv_established() will do it. It is important not to
    re-parse options in dccp_rcv_established() when it is not called from
    the fast-path. Else, fore example, the ack vector will be added twice
    and the CCID will see the packet twice.

    The solution is to always enfore sanity checks from the upper layers.
    When packets arrive in the fast-path, sanity checks will be performed
    before calling dccp_rcv_established().

    Note(acme): I rewrote the patch to achieve the same result but keeping
    dccp_rcv_established with the previous semantics and having it split
    into __dccp_rcv_established, that doesn't does do any sanity check,
    code in state != DCCP_OPEN use this lighter version as they already do
    the sanity checks.

    Signed-off-by: Andrea Bittau
    Signed-off-by: Arnaldo Carvalho de Melo
    Signed-off-by: David S. Miller

    Andrea Bittau
     
  • As DCCP needs to be called in the same spots.

    Now we have a member in inet_sock (is_icsk), set at sock creation time from
    struct inet_protosw->flags (if INET_PROTOSW_ICSK is set, like for TCP and
    DCCP) to see if a struct sock instance is a inet_connection_sock for places
    like the ones in ip_sockglue.c (v4 and v6) where we previously were looking if
    sk_type was SOCK_STREAM, that is insufficient because we now use the same code
    for DCCP, that has sk_type SOCK_DCCP.

    Signed-off-by: Arnaldo Carvalho de Melo
    Signed-off-by: David S. Miller

    Arnaldo Carvalho de Melo
     
  • Basically exports a similar set of functions as the one exported by
    the non-AF specific TCP code.

    In the process moved some non-AF specific code from dccp_v4_connect to
    dccp_connect_init and moved the checksum verification from
    dccp_invalid_packet to dccp_v4_rcv, so as to use it in dccp_v6_rcv
    too.

    Signed-off-by: Arnaldo Carvalho de Melo
    Signed-off-by: David S. Miller

    Arnaldo Carvalho de Melo
     
  • And make the core DCCP code AF agnostic, just like TCP, now its time
    to work on net/dccp/ipv6.c, we are close to the end!

    Signed-off-by: Arnaldo Carvalho de Melo
    Signed-off-by: David S. Miller

    Arnaldo Carvalho de Melo
     

11 Oct, 2005

1 commit


18 Sep, 2005

1 commit


17 Sep, 2005

1 commit


14 Sep, 2005

2 commits


09 Sep, 2005

1 commit


30 Aug, 2005

12 commits