SECURITY:

Fix a directory traversal vulnerability. (CVE-2007-4131)
This commit is contained in:
naddy 2007-09-01 21:05:21 +00:00
parent eb4770dc84
commit c1ff722c4b
2 changed files with 18 additions and 2 deletions

View File

@ -1,9 +1,9 @@
# $OpenBSD: Makefile,v 1.44 2007/08/25 19:49:01 naddy Exp $
# $OpenBSD: Makefile,v 1.45 2007/09/01 21:05:21 naddy Exp $
COMMENT= GNU version of the traditional tape archiver
DISTNAME= tar-1.18
PKGNAME= g${DISTNAME}
PKGNAME= g${DISTNAME}p0
CATEGORIES= archivers
HOMEPAGE= http://www.gnu.org/software/tar/

View File

@ -0,0 +1,16 @@
$OpenBSD: patch-src_names_c,v 1.1 2007/09/01 21:05:21 naddy Exp $
--- src/names.c.orig Wed Jun 27 15:30:32 2007
+++ src/names.c Sat Sep 1 21:58:57 2007
@@ -1012,11 +1012,10 @@ contains_dot_dot (char const *name)
if (p[0] == '.' && p[1] == '.' && (ISSLASH (p[2]) || !p[2]))
return 1;
- do
+ while (! ISSLASH (*p))
{
if (! *p++)
return 0;
}
- while (! ISSLASH (*p));
}
}