[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4c553acb-027c-01ba-2593-b8edd75e4fbd@gmail.com>
Date: Thu, 17 Jan 2019 17:02:34 -0800
From: Eric Dumazet <eric.dumazet@...il.com>
To: Stanislav Fomichev <sdf@...gle.com>, netdev@...r.kernel.org
Cc: davem@...emloft.net, ast@...nel.org, daniel@...earbox.net
Subject: Re: [PATCH bpf-next 0/5] add bpf cgroup hooks that trigger on socket
close
On 01/17/2019 04:41 PM, Stanislav Fomichev wrote:
> Currently, we have BPF_CGROUP_INET_SOCK_CREATE hook that triggers on
> socket creation and there is no way to know when the socket is being
> closed. Add new set of hooks BPF_CGROUP_INET{4,6}_SOCK_RELEASE
> that trigger when the socket is closed.
>
Are these hooks enough to capture a disconnect() operation ?
A socket can be reused (different flows) without inet_release() being ever called.
> Initial intended usecase is to cleanup statistics after POST{4,6}_BIND.
> Hooks have read-only access to all fields of struct bpf_sock.
>
> First patch adds hooks, the rest of the patches add uapi and tests to make
> sure these hooks work.
>
Powered by blists - more mailing lists