aboutsummaryrefslogtreecommitdiff
path: root/audio
diff options
context:
space:
mode:
authorSimon L. B. Nielsen <simon@FreeBSD.org>2005-01-15 11:47:51 +0000
committerSimon L. B. Nielsen <simon@FreeBSD.org>2005-01-15 11:47:51 +0000
commit2aeb55fbe5ccb25024921bd4d7e9a7cca2761851 (patch)
tree634cf8eac3b55bd58804d71752223074f6778538 /audio
parent2b6fa4039f4fc03f39170c7b4784a649689bdbc6 (diff)
downloadports-2aeb55fbe5ccb25024921bd4d7e9a7cca2761851.tar.gz
ports-2aeb55fbe5ccb25024921bd4d7e9a7cca2761851.zip
Fix buffer overflow vulnerability.
VuXML: http://vuxml.FreeBSD.org/3cc84400-6576-11d9-a9e7-0001020eed82.html Obtained from: Debian Approved by: maintainer, erwin (mentor)
Notes
Notes: svn path=/head/; revision=126499
Diffstat (limited to 'audio')
-rw-r--r--audio/mpg123/Makefile2
-rw-r--r--audio/mpg123/files/patch-CAN-2004-099130
2 files changed, 31 insertions, 1 deletions
diff --git a/audio/mpg123/Makefile b/audio/mpg123/Makefile
index 0ab03e713c4b..41aacb5bd752 100644
--- a/audio/mpg123/Makefile
+++ b/audio/mpg123/Makefile
@@ -7,7 +7,7 @@
PORTNAME= mpg123
PORTVERSION= 0.59r
-PORTREVISION= 16
+PORTREVISION= 17
CATEGORIES= audio ipv6
MASTER_SITES= http://www.mpg123.de/mpg123/ \
http://www-ti.informatik.uni-tuebingen.de/~hippm/mpg123/
diff --git a/audio/mpg123/files/patch-CAN-2004-0991 b/audio/mpg123/files/patch-CAN-2004-0991
new file mode 100644
index 000000000000..4269a17466a0
--- /dev/null
+++ b/audio/mpg123/files/patch-CAN-2004-0991
@@ -0,0 +1,30 @@
+--- common.c.orig 2003/01/29 19:22:48 1.4
++++ common.c 2005/01/01 19:21:47 1.5
+@@ -343,9 +343,12 @@
+ fr->mpeg25 = 1;
+ }
+
+- if (!param.tryresync || !oldhead) {
+- /* If "tryresync" is true, assume that certain
+- parameters do not change within the stream! */
++ if (!param.tryresync || !oldhead ||
++ (((oldhead>>19)&0x3) ^ ((newhead>>19)&0x3))) {
++ /* If "tryresync" is false, assume that certain
++ parameters do not change within the stream!
++ Force an update if lsf or mpeg25 settings
++ have changed. */
+ fr->lay = 4-((newhead>>17)&3);
+ if( ((newhead>>10)&0x3) == 0x3) {
+ fprintf(stderr,"Stream error\n");
+Index: debian/mpg123/layer2.c
+--- layer2.c.orig Tue Sep 7 14:32:13 2004
++++ layer2.c Sat Jan 1 20:21:47 2005
+@@ -240,7 +240,7 @@
+ { alloc_0, alloc_1, alloc_2, alloc_3 , alloc_4 };
+ static int sblims[5] = { 27 , 30 , 8, 12 , 30 };
+
+- if(fr->lsf)
++ if(fr->sampling_frequency >= 3) /* Or equivalent: (fr->lsf == 1) */
+ table = 4;
+ else
+ table = translate[fr->sampling_frequency][2-fr->stereo][fr->bitrate_index];