From 0d6a144061635f33ed462a4a59fa54c98029cb97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Kope=C4=8Dek?= Date: Tue, 16 Feb 2010 22:27:13 +0000 Subject: [PATCH] - fixed no valid sudoers sources found (#558875) --- sudo-1.7.2p2-emptyincldir.patch | 38 +++++++++++++++++++++++++++++++++ sudo.spec | 8 ++++++- 2 files changed, 45 insertions(+), 1 deletion(-) create mode 100644 sudo-1.7.2p2-emptyincldir.patch diff --git a/sudo-1.7.2p2-emptyincldir.patch b/sudo-1.7.2p2-emptyincldir.patch new file mode 100644 index 0000000..fbab43e --- /dev/null +++ b/sudo-1.7.2p2-emptyincldir.patch @@ -0,0 +1,38 @@ +diff -up sudo-1.7.2p2/toke.c.empty sudo-1.7.2p2/toke.c +--- sudo-1.7.2p2/toke.c.empty 2010-02-16 23:13:23.000000000 +0100 ++++ sudo-1.7.2p2/toke.c 2010-02-16 23:17:57.000000000 +0100 +@@ -1421,6 +1421,7 @@ __unused static const char rcsid[] = "$S + #endif /* lint */ + + extern YYSTYPE yylval; ++extern int parse_error; + int sudolineno = 1; + char *sudoers; + static int sawspace = 0; +@@ -1880,7 +1881,7 @@ YY_RULE_SETUP + LEXTRACE("INCLUDEDIR\n"); + + /* Push current buffer and switch to include file */ +- if (!push_includedir(path)) ++ if (!push_includedir(path) && parse_error) + yyterminate(); + } + YY_BREAK +@@ -3369,7 +3370,7 @@ switch_dir(stack, dirpath) + + if (!(dir = opendir(dirpath))) { + yyerror(dirpath); +- return(FALSE); ++ return(NULL); + } + while ((dent = readdir(dir))) { + /* Ignore files that end in '~' or have a '.' in them. */ +@@ -3494,7 +3495,7 @@ _push_include(path, isdir) + } + if (isdir) { + if (!(path = switch_dir(&istack[idepth], path))) { +- yyerror(path); ++ /* yyerror(path); */ + return(FALSE); + } + if ((fp = open_sudoers(path, FALSE, &keepopen)) == NULL) { diff --git a/sudo.spec b/sudo.spec index aa6b460..f5efbd6 100644 --- a/sudo.spec +++ b/sudo.spec @@ -1,7 +1,7 @@ Summary: Allows restricted root access for specified users Name: sudo Version: 1.7.2p2 -Release: 4%{?dist} +Release: 5%{?dist} License: BSD Group: Applications/System URL: http://www.courtesan.com/sudo/ @@ -35,6 +35,8 @@ Patch6: sudo-1.7.2p1-audit.patch Patch7: sudo-1.7.2p2-loopsegv3.patch # audit related Makefile.in and configure.in corrections Patch8: sudo-1.7.2p2-libaudit.patch +# no valid sudoers sources found (#558875) +Patch9: sudo-1.7.2p2-emptyincldir.patch %description Sudo (superuser do) allows a system administrator to give certain @@ -57,6 +59,7 @@ on many different machines. %patch6 -p1 -b .audit %patch7 -p1 -b .loopsegv3 %patch8 -p1 -b .libaudit +%patch9 -p1 -b .emptyincldir %build # handle newer autoconf @@ -147,6 +150,9 @@ rm -rf $RPM_BUILD_ROOT /bin/chmod 0440 /etc/sudoers || : %changelog +* Tue Feb 16 2010 Daniel Kopecek - 1.7.2p2-5 +- fixed no valid sudoers sources found (#558875) + * Wed Feb 10 2010 Daniel Kopecek - 1.7.2p2-4 - audit related Makefile.in and configure.in corrections - added --with-audit configure option