You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Playing 8-byte IV content after 16-byte IV content on a single instance of ExoPlayer results in a garbled video.
Reproduction steps
Let's assuming we have 2 DASH content items: one with 16-byte IV and the second with 8-byte IV.
Create an instance of ExoPlayerImpl and play both items in order on a single ExoPlayerImpl instance.
I.e.
a) prepare the 16-byte IV item
b) play it
c) stop
d) prepare the 8-byte IV item
Here the playback breaks.
Link to test content
Was observed on a proprietary content.
A full bug report captured from the device
N/A
Version of ExoPlayer being used
2.9.4 and 2.10.6
Device(s) and version(s) of Android being used
Was observed on many devices. For example on FireTv 4K stick.
NOTE: Location of the issue in the code:
The com.google.android.exoplayer2.source.SampleQueue.readEncryptionData()
method allocates buffer.cryptoInfo.iv if one is not already allocated.
However, if buffer.cryptoInfo.iv is already allocated and contains an old IV, the array is not cleaned.
So, if ivSize in readData(offset, buffer.cryptoInfo.iv, ivSize) is smaller than it was for the previous IVs
we get a wrong value for IV
The text was updated successfully, but these errors were encountered:
CryptoInfo.iv length is always 16. When the actual initialization vector
is shorter, zero out the trailing bytes.
Issue: #6982
PiperOrigin-RevId: 295575845
Thanks for the clear issue report. This has always been broken (!), so I guess your use case isn't a particularly common one :). It should be fixed by the change above; please let us know if you still see any issues.
CryptoInfo.iv length is always 16. When the actual initialization vector
is shorter, zero out the trailing bytes.
Issue: #6982
PiperOrigin-RevId: 295575845
Issue description
Playing 8-byte IV content after 16-byte IV content on a single instance of ExoPlayer results in a garbled video.
Reproduction steps
Let's assuming we have 2 DASH content items: one with 16-byte IV and the second with 8-byte IV.
Create an instance of ExoPlayerImpl and play both items in order on a single ExoPlayerImpl instance.
I.e.
a) prepare the 16-byte IV item
b) play it
c) stop
d) prepare the 8-byte IV item
Here the playback breaks.
Link to test content
Was observed on a proprietary content.
A full bug report captured from the device
N/A
Version of ExoPlayer being used
2.9.4 and 2.10.6
Device(s) and version(s) of Android being used
Was observed on many devices. For example on FireTv 4K stick.
NOTE: Location of the issue in the code:
The com.google.android.exoplayer2.source.SampleQueue.readEncryptionData()
method allocates buffer.cryptoInfo.iv if one is not already allocated.
However, if buffer.cryptoInfo.iv is already allocated and contains an old IV, the array is not cleaned.
So, if ivSize in readData(offset, buffer.cryptoInfo.iv, ivSize) is smaller than it was for the previous IVs
we get a wrong value for IV
The text was updated successfully, but these errors were encountered: