diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-11-04 22:02:02 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-11-04 22:08:59 +0100 |
commit | aeaca3816c2677bfdb16cbc6bc55c259ed5028ff (patch) | |
tree | b3f4e856e626e118c01db5282e47947b97163a05 | |
parent | b1f213a83ae8d4fe3fa83a145fdbe6da7fd36a90 (diff) | |
parent | 1c736bedd9891501960ebac0f7c05eb60225e947 (diff) | |
download | ffmpeg-aeaca3816c2677bfdb16cbc6bc55c259ed5028ff.tar.gz |
Merge commit '1c736bedd9891501960ebac0f7c05eb60225e947'
* commit '1c736bedd9891501960ebac0f7c05eb60225e947':
omadec: check GEOB sizes against buffer size
Conflicts:
libavformat/omadec.c
See: e74fa25cb9f29aee8a36df0c8e492f8bafdbe4a0
See: 91e72e35141f590c38985ad0ae3453a4e9e86b8a
Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavformat/omadec.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/libavformat/omadec.c b/libavformat/omadec.c index 4017db3f2b..d18d61c208 100644 --- a/libavformat/omadec.c +++ b/libavformat/omadec.c @@ -232,9 +232,8 @@ static int decrypt_init(AVFormatContext *s, ID3v2ExtraMeta *em, uint8_t *header) av_log(s, AV_LOG_ERROR, "Invalid encryption header\n"); return AVERROR_INVALIDDATA; } - if ( OMA_ENC_HEADER_SIZE + oc->k_size + oc->e_size + oc->i_size + 8 > geob->datasize - || OMA_ENC_HEADER_SIZE + 48 > geob->datasize - ) { + if (OMA_ENC_HEADER_SIZE + oc->k_size + oc->e_size + oc->i_size + 8 > geob->datasize || + OMA_ENC_HEADER_SIZE + 48 > geob->datasize) { av_log(s, AV_LOG_ERROR, "Too little GEOB data\n"); return AVERROR_INVALIDDATA; } |