phonet: refcount leak in pep_sock_accep
Subsystems (3)
PATCH 1/1 phonet: refcount leak in pep_sock_accep
From: Hangyu Hua <[email protected]>
commit bcd0f9335332 ("phonet: refcount leak in pep_sock_accep") upstream.
sock_hold(sk) is invoked in pep_sock_accept(), but __sock_put(sk) is not invoked in subsequent failure branches(pep_accept_conn() != 0).
--- net/phonet/pep.c | 1 + 1 file changed, 1 insertion(+)
net/phonet/pep.c +1 -0
@@ -881,6 +881,7 @@ static struct sock *pep_sock_accept(struct sock *sk, int flags, int *errp, err =pep_accept_conn (newsk, skb);if (err) { +__sock_put (sk);sock_put (newsk); newsk =NULL ; goto drop;
Signature · 1 line
2.27.0
Greg KH
maintainerQuoted 8 lines · Aayush Agarwal
From: Hangyu Hua <[email protected]>
commit
bcd0f9335332("phonet: refcount leak inpep_sock_accep") upstream.
sock_hold(sk)is invoked inpep_sock_accept(), but__sock_put(sk)is not invoked in subsequent failurebranches(pep_accept_conn() != 0).
Quoted 7 lines
Signed-off-by Hangyu Hua <[email protected]>Signed-off-by Jakub Kicinski <[email protected]>Signed-off-by Aayush Agarwal <[email protected]>--- net/phonet/pep.c | 1 + 1 file changed, 1 insertion(+)
What about releases 5.15.y, 5.10.y, 5.4.y, and 4.19.y? Is this also relevant for those trees?
thanks,
greg k-h
Re: [External] : Re: [PATCH 4.14] phonet: refcount leak in pep_sock_accep
Quoted 16 lines · Greg KH
Quoted 8 lines · Aayush Agarwal
From: Hangyu Hua <[email protected]>
commit
bcd0f9335332("phonet: refcount leak inpep_sock_accep") upstream.
sock_hold(sk)is invoked inpep_sock_accept(), but__sock_put(sk)is not invoked in subsequent failurebranches(pep_accept_conn() != 0).Quoted 7 lines
Signed-off-by Hangyu Hua <[email protected]>Signed-off-by Jakub Kicinski <[email protected]>Signed-off-by Aayush Agarwal <[email protected]>--- net/phonet/pep.c | 1 + 1 file changed, 1 insertion(+)
Quoted 6 lines
What about releases 5.15.y, 5.10.y, 5.4.y, and 4.19.y? Is this also relevant for those trees?
thanks,
greg k-h
It's relevant for all currently supported stable releases: 4.4.y, 4.9.y, 4.14.y, 4.19.y, 5.4.y, 5.10.y, 5.15.y . I missed adding the tag "Cc: [email protected] #4.4+". Should I send the patch again?
Greg KH
maintainerRe: [External] : Re: [PATCH 4.14] phonet: refcount leak in pep_sock_accep
Quoted 21 lines · On Fri, Jan 07, 2022 at 10:24:53PM +0530, [email protected] wrote:
Quoted 19 lines · Greg KH
Quoted 8 lines · Aayush Agarwal
From: Hangyu Hua <[email protected]>
commit
bcd0f9335332("phonet: refcount leak inpep_sock_accep") upstream.
sock_hold(sk)is invoked inpep_sock_accept(), but__sock_put(sk)is not invoked in subsequent failurebranches(pep_accept_conn() != 0).Quoted 7 lines
Signed-off-by Hangyu Hua <[email protected]>Signed-off-by Jakub Kicinski <[email protected]>Signed-off-by Aayush Agarwal <[email protected]>--- net/phonet/pep.c | 1 + 1 file changed, 1 insertion(+)What about releases 5.15.y, 5.10.y, 5.4.y, and 4.19.y? Is this also relevant for those trees?
Quoted 7 lines
Quoted 3 lines
thanks,
greg k-h
It's relevant for all currently supported stable releases: 4.4.y, 4.9.y, 4.14.y, 4.19.y, 5.4.y, 5.10.y, 5.15.y . I missed adding the tag "Cc:
[email protected] #4.4+". Should I send the patch again?
No need, I've queued it up everywhere now, thanks!
greg k-h