Skip to content

[PW_SID:1078865] Bluetooth: hci_event: fix potential UAF in SSP passkey handlers#3465

Open
BluezTestBot wants to merge 1 commit intoworkflowfrom
1078865
Open

[PW_SID:1078865] Bluetooth: hci_event: fix potential UAF in SSP passkey handlers#3465
BluezTestBot wants to merge 1 commit intoworkflowfrom
1078865

Conversation

@BluezTestBot
Copy link
Copy Markdown
Owner

hci_conn lookup and field access must be covered by hdev lock in
hci_user_passkey_notify_evt() and hci_keypress_notify_evt(), otherwise
the connection can be freed concurrently.

Extend the hci_dev_lock critical section to cover all conn usage in both
handlers.

Keep the existing keypress notification behavior unchanged by routing
the early exits through a common unlock path.

Cc: stable@vger.kernel.org
Signed-off-by: Shuvam Pandey shuvampandey1@gmail.com


net/bluetooth/hci_event.c | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)

hci_conn lookup and field access must be covered by hdev lock in
hci_user_passkey_notify_evt() and hci_keypress_notify_evt(), otherwise
the connection can be freed concurrently.

Extend the hci_dev_lock critical section to cover all conn usage in both
handlers.

Keep the existing keypress notification behavior unchanged by routing
the early exits through a common unlock path.

Cc: stable@vger.kernel.org
Signed-off-by: Shuvam Pandey <shuvampandey1@gmail.com>
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

CheckPatch
Desc: Run checkpatch.pl script
Duration: 0.49 seconds
Result: PENDING

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

GitLint
Desc: Run gitlint
Duration: 0.28 seconds
Result: PENDING

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

SubjectPrefix
Desc: Check subject contains "Bluetooth" prefix
Duration: 0.26 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

BuildKernel
Desc: Build Kernel for Bluetooth
Duration: 25.88 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

CheckAllWarning
Desc: Run linux kernel with all warning enabled
Duration: 28.13 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

CheckSparse
Desc: Run sparse tool with linux kernel
Duration: 27.57 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

BuildKernel32
Desc: Build 32bit Kernel for Bluetooth
Duration: 24.83 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunnerSetup
Desc: Setup kernel and bluez for test-runner
Duration: 567.22 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_l2cap-tester
Desc: Run l2cap-tester with test-runner
Duration: 27.70 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_iso-tester
Desc: Run iso-tester with test-runner
Duration: 37.67 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_bnep-tester
Desc: Run bnep-tester with test-runner
Duration: 6.40 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_mgmt-tester
Desc: Run mgmt-tester with test-runner
Duration: 113.44 seconds
Result: FAIL
Output:

Total: 494, Passed: 489 (99.0%), Failed: 1, Not Run: 4

Failed Test Cases
Read Exp Feature - Success                           Failed       0.107 seconds

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_rfcomm-tester
Desc: Run rfcomm-tester with test-runner
Duration: 9.37 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_sco-tester
Desc: Run sco-tester with test-runner
Duration: 14.29 seconds
Result: FAIL
Output:

WARNING: possible circular locking dependency detected
BUG: sleeping function called from invalid context at net/core/sock.c:3782
Total: 30, Passed: 30 (100.0%), Failed: 0, Not Run: 0

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_ioctl-tester
Desc: Run ioctl-tester with test-runner
Duration: 10.35 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_mesh-tester
Desc: Run mesh-tester with test-runner
Duration: 11.48 seconds
Result: FAIL
Output:

Total: 10, Passed: 8 (80.0%), Failed: 2, Not Run: 0

Failed Test Cases
Mesh - Send cancel - 1                               Timed out    1.860 seconds
Mesh - Send cancel - 2                               Timed out    1.992 seconds

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_smp-tester
Desc: Run smp-tester with test-runner
Duration: 8.62 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

TestRunner_userchan-tester
Desc: Run userchan-tester with test-runner
Duration: 6.77 seconds
Result: PASS

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

IncrementalBuild
Desc: Incremental build with the patches in the series
Duration: 0.64 seconds
Result: PENDING

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants