lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 13 Jun 2017 07:33:40 -0400
From:   Jamal Hadi Salim <jhs@...atatu.com>
To:     Lorenzo Colitti <lorenzo@...gle.com>
Cc:     David Miller <davem@...emloft.net>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        mrv@...atatu.com, hadi@...atatu.com
Subject: Re: [PATCH net-next 1/1] net: reflect mark on tcp syn ack packets

On 17-06-12 08:34 PM, Lorenzo Colitti wrote:
> On Sun, Jun 11, 2017 at 8:58 PM, Jamal Hadi Salim <jhs@...atatu.com> wrote:
>>> Maybe this should both be "inet_request_mark()"?

> As David says, the tcp_fwmark_accept sysctl is not really appropriate
> for synack packets - what it does is ensure that when a connection is
> accepted, sk->sk_mark is set to the mark of the incoming skb.
> 
> I think the correct behaviour here is to to honour the
> ip_fwmark_reflect sysctl instead, and if it's enabled, make the synack
> mark be the same as the the incoming syn mark.
> 

Ok, so in the patch I sent then change this:

+       if (sock_net(sk)->ipv4.sysctl_tcp_fwmark_accept)
+               skb->mark = ireq->ir_mark;

to:

+       if (sock_net(sk)->ipv4.fwmark_reflect)
+               skb->mark = ireq->ir_mark;

correct?

cheers,
jamal

Powered by blists - more mailing lists