Skip to content

Bluetooth: L2CAP: signalling response fixes

Siwei Zhang stable 7 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest posting 2/23 patches 0 repliesNew
  2. v4 posting 1/23 patches 1 replyApplied
  3. v3 posting 2/23 patches 4 repliesSuperseded
Earlier versions · 4
VersionPostedPatchesRepliesStatus
v3 posting 1/23 patches1 replySuperseded
v2 posting 2/23 patches0 repliesSuperseded
v2 posting 1/23 patches3 repliesSuperseded
v13 patches1 replySuperseded

Changes in v4 from the cover letter

- Patch 2: set CONF_CONNECT_PEND in l2cap_send_create_chan_req(), so the Create Channel Response is no longer dropped and an outgoing AMP channel does not hang in BT_CONNECT.
https://lore.kernel.org/stable/[email protected]/

Patches in v4 posting 2/2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3Bluetooth: L2CAP: Reject signalling responses in invalid statesnet/bluetooth/l2cap_core.c+19 -10 replies
2/3Bluetooth: L2CAP: Only accept connection responses to outstanding requestsnet/bluetooth/l2cap_core.c+30 -30 replies
3/3Bluetooth: L2CAP: Ignore connection responses with wrong identnet/bluetooth/l2cap_core.c+4 -40 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v4 yet.

Read the v4 thread

Cover letter [PATCH 5.10.y v4 0/3] Bluetooth: L2CAP: signalling response fixes

Backports of

6320736af7dc ("Bluetooth: L2CAP: Reject signalling responses in invalid states") a518b9a9ef6e ("Bluetooth: L2CAP: Only accept connection responses to outstanding requests")

which failed to apply to the 5.10-stable tree:

https://lore.kernel.org/stable/[email protected]/
https://lore.kernel.org/stable/[email protected]/

Patch 3 is a9f9eeb5344f ("Bluetooth: L2CAP: Ignore connection responses with wrong ident"), which tightens the check added by patch 2 and only applies on top of it.

The series goes on top of the three L2CAP patches already queued for 5.10.y:

c1398cf11b31 ("Bluetooth: L2CAP: Reject mode changes on connected channels") c5ebb0245fe9 ("Bluetooth: L2CAP: Reject invalid TxWindow in configuration requests") 226fa3b676cb ("Bluetooth: L2CAP: Use default TxWindow for zero socket option")

5.10.y still has AMP and A2MP, which upstream removed in e7b02296fb40 ("Bluetooth: Remove BT_HS"). Patch 2 sets CONF_CONNECT_PEND in l2cap_send_create_chan_req(), so the response to an AMP Create Channel Request still passes the new check. Apart from that line, the patches only carry the upstream changes, with context adjusted as described at the top of each commit message.

Changes in v4:
- Patch 2: set CONF_CONNECT_PEND in l2cap_send_create_chan_req(), so the Create Channel Response is no longer dropped and an outgoing AMP channel does not hang in BT_CONNECT.
https://lore.kernel.org/stable/[email protected]/

Changes in v3:
- Drop the AMP and A2MP changes from all three patches. They are not upstream and did not get the maintainer ack asked for in the v2 review.
https://lore.kernel.org/stable/[email protected]/

Changes in v2:
- Patch 2: a2mp_discover_rsp() now pulls the payload of an unsolicited Discover Response before returning, so a2mp_chan_recv_cb() does not parse it as the next A2MP command header. Dropped again in v3 with the other AMP changes.
https://lore.kernel.org/stable/[email protected]/

v3: https://lore.kernel.org/stable/[email protected]/
v2: https://lore.kernel.org/stable/[email protected]/
v1: https://lore.kernel.org/stable/[email protected]/

Jinwang Li (1):
Bluetooth: L2CAP: Ignore connection responses with wrong ident

Siwei Zhang (2):
Bluetooth: L2CAP: Reject signalling responses in invalid states
Bluetooth: L2CAP: Only accept connection responses to outstanding
requests

 net/bluetooth/l2cap_core.c | 49 ++++++++++++++++++++++++++++++++++++--
 1 file changed, 47 insertions(+), 2 deletions(-)
Signature · 1 line
2.56.0