Android security tags, read closely by Lightrion

CVE-2024-34736 AI-generated analysis

platform/frameworks/av, media/libmediaplayerservice (StagefrightRecorder, MediaRecorder video encoder setup)

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 (6 corrections). Verify against the commit before relying on it.

StagefrightRecorder::setupVideoEncoder now forces zero B-layers (bLayers = 0) in the temporal-layering "ts-schema" when the audio source is AUDIO_SOURCE_MIC and the video source is VIDEO_SOURCE_SURFACE, which disables B-frame layering for the screen-recorder-with-microphone use case.

Root cause

In media/libmediaplayerservice/StagefrightRecorder.cpp, setupVideoEncoder() works out the number of temporal layers (tsLayers) from the expected playback frame rate. When tsLayers > 1 it always requests up to two B-layers (bLayers = min(2, tsLayers - 1)) through the "ts-schema" format key "android.generic.<pLayers>+<bLayers>", and it sets "android._prefer-b-frames". The commit message says that screen recording (VIDEO_SOURCE_SURFACE) with microphone audio (AUDIO_SOURCE_MIC) does not play with audio and video in sync when B-frames are enabled. The material does not show how this maps to the bulletin's "ID" (information disclosure) classification.

How the fix works

Completeness

Behavior changes

Per major

Unknowns

Back to August 2024 · Findings