Android security tags, read closely by Lightrion

CVE-2026-58857 AI-generated analysis

platform/frameworks/av, drm/libmediadrm (CryptoHal AIDL and HIDL wrappers)

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.

Reworks CryptoHalAidl::decrypt and CryptoHalHidl::decrypt (and CryptoHalAidl::getKeyHandle on Android 17) in libmediadrm so the plugin pointer is copied into a local strong reference while mLock is held, the Autolock is explicitly scoped instead of manually unlocked, and the HAL IPC is dispatched on the local reference with a null check.

Root cause

In CryptoHalAidl::decrypt and CryptoHalHidl::decrypt, a Mutex::Autolock on mLock was taken at function entry, the input validation ran, then mLock.unlock() was called manually and the IPC was issued through the member pointer mPlugin (and mPluginV1_2 in the HIDL path). Because the lock was released before the dispatch, destroyPlugin() could concurrently reset mPlugin, so the call could go through a freed or null plugin (per the commit message). In addition, the Autolock destructor unlocked mLock again at scope exit after the manual unlock, producing a double unlock. The same manual-unlock pattern existed in CryptoHalAidl::getKeyHandle on Android 17.

How the fix works

Completeness

Behavior changes

Per major

Unknowns

Back to November 2026 · Findings