aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorent Thoumie <flz@FreeBSD.org>2008-01-23 12:16:42 +0000
committerFlorent Thoumie <flz@FreeBSD.org>2008-01-23 12:16:42 +0000
commitfefc957d19a15cfec76dcc95c6f4fb714b7a5936 (patch)
tree804951e2eaa17d922f60577e3e6478962b9c9a5d
parenta77a287dffad44dcf0afa10ce504d82f35ddd6e5 (diff)
downloadports-fefc957d19a15cfec76dcc95c6f4fb714b7a5936.tar.gz
ports-fefc957d19a15cfec76dcc95c6f4fb714b7a5936.zip
Notes
-rw-r--r--x11-fonts/libXfont/Makefile2
-rw-r--r--x11-fonts/libXfont/files/patch-CVE-2008-000624
2 files changed, 25 insertions, 1 deletions
diff --git a/x11-fonts/libXfont/Makefile b/x11-fonts/libXfont/Makefile
index 5e57f7cf2fff..685b241a56f1 100644
--- a/x11-fonts/libXfont/Makefile
+++ b/x11-fonts/libXfont/Makefile
@@ -7,7 +7,7 @@
PORTNAME= libXfont
PORTVERSION= 1.3.1
-PORTREVISION= 1
+PORTREVISION= 2
PORTEPOCH= 1
CATEGORIES= x11-fonts
diff --git a/x11-fonts/libXfont/files/patch-CVE-2008-0006 b/x11-fonts/libXfont/files/patch-CVE-2008-0006
new file mode 100644
index 000000000000..95f7b2f28019
--- /dev/null
+++ b/x11-fonts/libXfont/files/patch-CVE-2008-0006
@@ -0,0 +1,24 @@
+diff --git src/bitmap/pcfread.c src/bitmap/pcfread.c
+index fd41849..c5db255 100644
+--- src/bitmap/pcfread.c
++++ src/bitmap/pcfread.c
+@@ -588,6 +588,9 @@ pcfReadFont(FontPtr pFont, FontFilePtr file,
+ pFont->info.lastRow = pcfGetINT16(file, format);
+ pFont->info.defaultCh = pcfGetINT16(file, format);
+ if (IS_EOF(file)) goto Bail;
++ if (pFont->info.firstCol > pFont->info.lastCol ||
++ pFont->info.firstRow > pFont->info.lastRow ||
++ pFont->info.lastCol-pFont->info.firstCol > 255) goto Bail;
+
+ nencoding = (pFont->info.lastCol - pFont->info.firstCol + 1) *
+ (pFont->info.lastRow - pFont->info.firstRow + 1);
+@@ -726,6 +729,9 @@ pcfReadFontInfo(FontInfoPtr pFontInfo, FontFilePtr file)
+ pFontInfo->lastRow = pcfGetINT16(file, format);
+ pFontInfo->defaultCh = pcfGetINT16(file, format);
+ if (IS_EOF(file)) goto Bail;
++ if (pFontInfo->firstCol > pFontInfo->lastCol ||
++ pFontInfo->firstRow > pFontInfo->lastRow ||
++ pFontInfo->lastCol-pFontInfo->firstCol > 255) goto Bail;
+
+ nencoding = (pFontInfo->lastCol - pFontInfo->firstCol + 1) *
+ (pFontInfo->lastRow - pFontInfo->firstRow + 1);