]> Git Repo - qemu.git/commit
es1370: check total frame count against current frame
authorPrasad J Pandit <[email protected]>
Thu, 14 May 2020 20:06:08 +0000 (01:36 +0530)
committerGerd Hoffmann <[email protected]>
Mon, 25 May 2020 09:30:03 +0000 (11:30 +0200)
commit369ff955a8497988d079c4e3fa1e93c2570c1c69
treea02079395fdc2abbbc3caf94645e902ea31c9153
parentfea8f3ed739536fca027cf56af7f5576f37ef9cd
es1370: check total frame count against current frame

A guest user may set channel frame count via es1370_write()
such that, in es1370_transfer_audio(), total frame count
'size' is lesser than the number of frames that are processed
'cnt'.

    int cnt = d->frame_cnt >> 16;
    int size = d->frame_cnt & 0xffff;

if (size < cnt), it results in incorrect calculations leading
to OOB access issue(s). Add check to avoid it.

Reported-by: Ren Ding <[email protected]>
Reported-by: Hanqing Zhao <[email protected]>
Signed-off-by: Prasad J Pandit <[email protected]>
Message-id: 20200514200608.1744203[email protected]
Signed-off-by: Gerd Hoffmann <[email protected]>
hw/audio/es1370.c
This page took 0.025659 seconds and 4 git commands to generate.