Android security tags, read closely by Lightrion

CVE-2026-59002 AI-generated analysis

platform/frameworks/base, services/usb (UsbDeviceManager, UsbHandler / UsbHandlerHal timeout handling)

AI-generated: written from the bulletin and the fixing diffs by claude-fable-5-1, then checked against the code by claude-opus-5-5 (2 corrections). Verify against the commit before relying on it.

Adds a lock-screen check to the two USB function-switch timeout handlers in UsbDeviceManager. When the screen is locked, the recovery path now sets UsbManager.FUNCTION_NONE (charging only) instead of the user's default unlocked USB functions (mScreenUnlockedFunctions).

Root cause

In services/usb/java/com/android/server/usb/UsbDeviceManager.java, two handlers recovered from a USB HAL function-switch timeout by unconditionally calling setEnabledFunctions(mScreenUnlockedFunctions, false, operationId): the MSG_SET_FUNCTIONS_TIMEOUT handler (when msg.arg1 != 1) and the MSG_FUNCTION_SWITCH_TIMEOUT handler (when mCurrentFunctions != UsbManager.FUNCTION_ACCESSORY). mScreenUnlockedFunctions holds the default USB configuration the user chose in Developer Options (for example PTP, MIDI, UVC or RNDIS). Neither handler consulted mScreenLocked, so a timeout while the device was locked would enable a data-transfer USB function without user interaction. The commit message calls this a follow-up to an incomplete fix for CVE-2024-43085.

How the fix works

Completeness

Behavior changes

Per major

Unknowns

Back to November 2026 · Findings