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  linux-hardening  linux-cve-announce  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:   Fri, 2 Feb 2018 07:34:45 -0500
From:   Neil Horman <nhorman@...driver.com>
To:     Tommi Rantala <tt.rantala@...il.com>
Cc:     Tommi Rantala <tommi.t.rantala@...ia.com>,
        Vlad Yasevich <vyasevich@...il.com>,
        linux-sctp@...r.kernel.org,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        Marcelo Ricardo Leitner <marcelo.leitner@...il.com>
Subject: Re: sctp netns "unregister_netdevice: waiting for lo to become free.
 Usage count = 1"

On Thu, Feb 01, 2018 at 10:41:27PM +0200, Tommi Rantala wrote:
> 2018-02-01 21:23 GMT+02:00 Neil Horman <nhorman@...driver.com>:
> > No, I can't say I saw the patch on the list.  Can you resend it?
> 
> Here's the patch again, sending from gmail this time.
> 
> The previous mail is now also at spinics, dunno what happened.
> https://www.spinics.net/lists/linux-sctp/msg07005.html
> 
> 
> From b94c037d27e36a3053e6862b7e7da5f07f2f5597 Mon Sep 17 00:00:00 2001
> From: Tommi Rantala <tommi.t.rantala@...ia.com>
> Date: Wed, 31 Jan 2018 11:24:31 +0000
> Subject: [PATCH] sctp: fix dst leak in sctp_v4_get_dst
> 
> Fix dst reference leak in sctp_v4_get_dst() introduced in commit
> 410f03831 ("sctp: add routing output fallback"):
> 
> When walking the address_list, successive ip_route_output_key() calls
> may return the same rt->dst with the reference incremented on each call.
> 
> The code would not decrement the dst refcount when the dst pointer was
> identical from the previous iteration, causing the dst leak.
> 
> Testcase:
>   ip netns add TEST
>   ip netns exec TEST ip link set lo up
>   ip link add dummy0 type dummy
>   ip link add dummy1 type dummy
>   ip link add dummy2 type dummy
>   ip link set dev dummy0 netns TEST
>   ip link set dev dummy1 netns TEST
>   ip link set dev dummy2 netns TEST
>   ip netns exec TEST ip addr add 192.168.1.1/24 dev dummy0
>   ip netns exec TEST ip link set dummy0 up
>   ip netns exec TEST ip addr add 192.168.1.2/24 dev dummy1
>   ip netns exec TEST ip link set dummy1 up
>   ip netns exec TEST ip addr add 192.168.1.3/24 dev dummy2
>   ip netns exec TEST ip link set dummy2 up
>   ip netns exec TEST sctp_test -H 192.168.1.2 -P 20002 -h 192.168.1.1
> -p 20000 -s -B 192.168.1.3
>   ip netns del TEST
> 
Patch looks good, but if you could please submit it with the proper title in a
separate thread so it gets davem's attention properly, I'd appreciate it.
Additional points if you update it to include the ipv6 fixes :)
Neil

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ