9003 Commits

Author SHA1 Message Date
Reinhard Tartler
96ca078b22 Check validity of channels & samplerate.
This may be security relevant.
Based on 2 patches by chrome.

backport r19975 by michael




Originally committed as revision 22658 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-03-24 19:35:30 +00:00
Reinhard Tartler
4fb58ecea8 bump LIBAVCODEC_VERSION_MICRO for addition of the lock manager API
As discussed with Diego, we'll go for bumping micro in 0.5 and will
consider adding a RELEASEVERSION macro for trunk and 0.6 seperatly


Originally committed as revision 22087 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-27 10:01:45 +00:00
Reinhard Tartler
8e2149d7df fix the remaining ogv segfaults from issue 1240.
First commit:

Make decode_init fail if the huffman tables are invalid and thus init_vlc fails.
Otherwise this will crash during decoding because the vlc tables are NULL.
Partially fixes ogv/smclock.ogv.1.101.ogv from issue 1240.

backport r19355 by reimar

Second commit:

Add extra validation checks to ff_vorbis_len2vlc.
They should not be necessary, but it seems like a reasonable precaution.

r19374 by reimar


Originally committed as revision 22076 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-26 14:32:27 +00:00
Reinhard Tartler
9d9f1ecfaa Make sure we dont read over the end.
Fixes issue1237.

backport r19322 by michael


Originally committed as revision 22074 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-26 10:56:46 +00:00
Reinhard Tartler
53b90bb25e backport libx264.c from trunk
now compiles with x264 API versions 65 up to 85

patch prepared by darkshikari


Originally committed as revision 22042 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-24 22:40:10 +00:00
Reinhard Tartler
26f74e832b cosmetics: K&R coding style, prettyprinting
backported r20083 by diego

This commit does not introduce functional changes.  It was applied in
order to faciliate reviewing the proposed libx264.c backport



Originally committed as revision 21832 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-15 12:45:14 +00:00
Reinhard Tartler
9593c80062 Fix crash in MLP decoder due to integer overflow.
Probably only DoS, init_get_bits sets buffer to NULL, thus causing a
NULL-dereference directly after.

backport r21426 by reimar


Originally committed as revision 21759 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-11 21:03:30 +00:00
Reinhard Tartler
48b98cdc67 Make sure the block array is of the correct size.
This might have been exploitable.

backported r18393 by michael



Originally committed as revision 21758 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-11 20:57:49 +00:00
Reinhard Tartler
9d442d2d7d Fix crash when max_ref_frames was out of range.
This might have been exploitable.
Fixes first crash of issue840.

backport r18388 by michael


Originally committed as revision 21757 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-11 16:22:59 +00:00
Reinhard Tartler
afc97d4735 reverting objected hunks from previous commit
as discussed with diego on irc, the spurious newline deletion and the
LIBAVCODEC_VERSION_MINOR bump are being reverted based on comments on
ffmpeg-cvslog by ramiro, uoti and michael.

See http://comments.gmane.org/gmane.comp.video.ffmpeg.cvs/28112 for the
full context.


Originally committed as revision 21755 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-11 11:52:59 +00:00
Reinhard Tartler
e5bea45df7 Add a lock manager API to libavcodec.
Allows an application to register a callback that manages mutexes
on behalf of FFmpeg.
With this callback registered FFmpeg is fully thread safe.

backport r19025 by andoma

NB: This is a feature backport with little regression potential. It was
requested at FOSDEM 2010 by ben@geexbox.org for use by geexbox and the
enna mediacenter in the upcoming debian/squeeze and ubuntu/lucid
release.

Approved by DonDiego on #ffmpeg-devel


Originally committed as revision 21731 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 20:28:42 +00:00
Google Chrome
9e3935dfd8 Check submap indexes.
10_vorbis_submap_indexes.patch by chrome.
I am applying this even though Reimar had some comments to improve it as it fixes
a serious security issue and I do not want to leave such things unfixed.

backport r20001 by michael


Originally committed as revision 21730 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:59:11 +00:00
Google Chrome
4f5ee3f87b Check begin/end/partition_size.
23_vorbis_sane_partition.patch by chrome.
Also this should be better documented but i prefer not to leave potential
security issues open due to missing documentation.

r19996 by michael


Originally committed as revision 21729 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:54:42 +00:00
Google Chrome
736d36b792 Check res_setup->books.
15_more_residue_book_indexes.patch by chrome.

r19992 by michael


Originally committed as revision 21728 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:52:27 +00:00
Google Chrome
dc5cc27d5a Check masterbook index and subclass book index.
14_floor_masterbook_index.patch by chrome

r19991 by michael


Originally committed as revision 21727 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:50:47 +00:00
Google Chrome
eb70d77e1e Add checks for per-packet mode indexes and per-header mode mapping indexes.
12_vorbis_mode_indexes.patch by chrome
maybe exploitable

r19990 by michael


Originally committed as revision 21726 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:49:28 +00:00
Google Chrome
b8ec4c49bd Check classbook value.
11_vorbis_residue_book_index.patch by chrome.

r19989 by michael


Originally committed as revision 21725 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:47:42 +00:00
Google Chrome
49487dfd78 Fix book_idx check.
25_vorbis_floor0_index.patch by chrome.

backport r19984 by michael


Originally committed as revision 21724 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:46:22 +00:00
Google Chrome
0d3f25eb48 Sanity checks for magnitude and angle.
26_vorbis_mag_angle_index.patch by chrome

backport r19983 by michael


Originally committed as revision 21723 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:45:16 +00:00
Google Chrome
9ef13f70f4 = -> == typo.
27_vorbis_residue_loop_error.patch by chrome

backport r19982 by michael


Originally committed as revision 21722 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:44:06 +00:00
Reinhard Tartler
beb0dc5f36 Check dimensions against 0 too.
39_vorbis_zero_dims.patch from chrome

backport r19976 by michael


Originally committed as revision 21721 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:42:30 +00:00
Reinhard Tartler
f3fd428697 Make sure that all memory allocations succeed.
Based on 28_theora_malloc_checks.patch from the Google Chrome team.

backport r20008 by melanson


Originally committed as revision 21720 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:31:04 +00:00
Google Chrome
8811fe6987 Fix init_get_bits() buffer size.
18_fix_theora_header_bit_len.patch by chrome

backport r19993 by michael


Originally committed as revision 21719 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:26:47 +00:00
Reinhard Tartler
3835603e7e Set data_size to 0 to avoid having it uninitialized.
based on 31_mp3_outlen.patch by chrome.

backported r19988 by michael


Originally committed as revision 21718 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:22:19 +00:00
Reinhard Tartler
4b360ee2ca Check data_size in decode_frame_mp3on4().
backported r19987 by michael


Originally committed as revision 21717 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:20:25 +00:00
Reinhard Tartler
ab546a7463 check data_size in decode_frame()
backported r19986 by michael




Originally committed as revision 21716 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:09:12 +00:00
Reinhard Tartler
acac7858bd Check num_units_in_tick/time_scale to be valid and within the range we support.
based on a patch by chrome

backported r19979 by michael




Originally committed as revision 21715 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 19:02:39 +00:00
Reinhard Tartler
c42640b200 Fix a possibly exploitable buffer overflow.
backported r18640 by michael



Originally committed as revision 21712 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 18:55:41 +00:00
Reinhard Tartler
7d061cfe17 fix aac playback regression
Discussed at http://comments.gmane.org/gmane.comp.video.ffmpeg.devel/103768

related reports:
 - http://bugs.debian.org/540729
 - https://roundup.ffmpeg.org/roundup/ffmpeg/issue800



Originally committed as revision 21706 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-09 17:36:18 +00:00
Reinhard Tartler
478394bab7 backport configure bits for cpu runtime detection for libpostproc and libswscale
Originally committed as revision 21611 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-02 20:30:20 +00:00
Reinhard Tartler
a9785f58c6 backport symbol versioning patch
Originally committed as revision 21595 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2010-02-01 16:00:09 +00:00
Diego Biurrun
44b20d1d74 Fix OpenCORE build: Do not use new AVPacket infrastructure from trunk.
Originally committed as revision 19134 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2009-06-07 22:41:11 +00:00
Diego Biurrun
9ad437eafb Merge OpenCORE AMR support from trunk.
Originally committed as revision 19133 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2009-06-07 20:14:56 +00:00
Diego Biurrun
4fcef88c4d Merge recent libamr changes from trunk, as preparation for OpenCORE support.
Originally committed as revision 19131 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2009-06-07 16:14:50 +00:00
Diego Biurrun
a4d8ebfaa1 Merge GPL --> LGPL conversion of AC-3 decoder from trunk.
Originally committed as revision 18915 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2009-05-23 12:58:44 +00:00
Diego Biurrun
b0b57fa13b Merge replacement of MPEG group reference DCT code.
Originally committed as revision 18492 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
2009-04-13 10:23:10 +00:00
Diego Biurrun
12dd57fd29 cosmetics: Reformat long_names so that "DPCM" comes first.
Originally committed as revision 17721 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-02 06:01:32 +00:00
Diego Biurrun
fd75cedd15 cosmetics: Reformat long_names so that "ADPCM" comes first.
Originally committed as revision 17720 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-02 05:55:03 +00:00
Diego Biurrun
655463b9eb cosmetics: Reformat long_names so that "PCM" comes first.
Originally committed as revision 17719 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-02 05:45:44 +00:00
Diego Biurrun
7eb2d654a2 small spelling/grammar fixes
Originally committed as revision 17718 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-02 05:41:55 +00:00
Diego Biurrun
326b554ccf xvmc works with MPEG-2 as well as MPEG-1, note this in the codec long_name.
Originally committed as revision 17717 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-02 05:20:00 +00:00
Diego Biurrun
0ffbc258aa Change a bunch of codec long_names to be more consistent and descriptive.
Originally committed as revision 17716 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-02 05:18:33 +00:00
Justin Ruggles
68dddf53ff Add some missing codecs and update names to match the codec long_name
or vice-versa.

Originally committed as revision 17706 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-02 02:25:31 +00:00
Måns Rullgård
09096c9fad RA144: work around gcc bug/oddity on ARM
This should not make any difference, yet some gcc versions on ARM
produce incorrect output without this fix.

Approved by Vitor.

Originally committed as revision 17698 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-01 23:41:39 +00:00
Måns Rullgård
db794291a2 SVQ3: Fix decoding with A32_BITSTREAM_READER
svq3_decode_slice_header() modifies the buffer used by the bitstream
reader.  Some of the bitstream readers cache a few bytes of data, which
must be flushed after such a modification.  Calling skip_bits_long(gb, 0)
achieves this.

Originally committed as revision 17680 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-01 12:11:07 +00:00
Måns Rullgård
4cd19f6e78 ARM: fix missing MUL16() return type
Originally committed as revision 17679 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-01 12:11:02 +00:00
Vitor Sessak
8d2544bd1b Reindent after last commit
Originally committed as revision 17678 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-01 11:16:57 +00:00
Vitor Sessak
9e27e0d4f8 Do not read uninitialized buffer, no matter if it will be multiplied by
zero later. This should fix some valgrind warnings and hopefully FATE
ra144 test on ARM.

Originally committed as revision 17677 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-01 11:14:21 +00:00
Reimar Döffinger
d819b41ba1 Remove unused variable in mpeg_mc_decode_init
Originally committed as revision 17676 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-01 09:14:20 +00:00
Michael Niedermayer
47cd974ae5 Do not set low_delay if has_b_frames has been set before init()
this will be needed once the parser can figure out has_b_frames
in av_find_stream_info().

Originally committed as revision 17673 to svn://svn.ffmpeg.org/ffmpeg/trunk
2009-03-01 03:13:04 +00:00