X-Git-Url: https://git.tld-linux.org/?p=packages%2Fapache.git;a=blobdiff_plain;f=apache-suexec_fcgi.patch;h=ae5578c7f1e0b4997ace3b1ea07c5c3ab7dcc420;hp=3201f3dc7cac896c4b71bcce65226ced78912c4f;hb=3174ace842691bfb2ea7af0c53406a7f2a71dc80;hpb=c3e95d0c9b16c078ef127fb45c1d45dc0c039b3c diff --git a/apache-suexec_fcgi.patch b/apache-suexec_fcgi.patch index 3201f3d..ae5578c 100644 --- a/apache-suexec_fcgi.patch +++ b/apache-suexec_fcgi.patch @@ -1,6 +1,7 @@ ---- httpd-2.4.1/support/suexec.c.orig 2011-07-13 21:11:21.000000000 +0200 -+++ httpd-2.4.1/support/suexec.c 2012-02-22 00:26:17.549340557 +0100 -@@ -234,6 +234,21 @@ +diff -urNp httpd-2.4.4.orig/support/suexec.c httpd-2.4.4/support/suexec.c +--- httpd-2.4.4.orig/support/suexec.c 2012-12-03 16:33:42.000000000 +0000 ++++ httpd-2.4.4/support/suexec.c 2013-07-11 11:49:54.250178570 +0000 +@@ -240,6 +240,21 @@ static void clean_env(void) environ = cleanenv; } @@ -22,7 +23,7 @@ int main(int argc, char *argv[]) { int userdir = 0; /* ~userdir flag */ -@@ -249,6 +264,7 @@ +@@ -255,6 +270,7 @@ int main(int argc, char *argv[]) char dwd[AP_MAXPATH]; /* docroot working directory */ struct passwd *pw; /* password entry holder */ struct group *gr; /* group entry holder */ @@ -30,7 +31,7 @@ struct stat dir_info; /* directory info holder */ struct stat prg_info; /* program info holder */ -@@ -369,8 +385,23 @@ +@@ -375,8 +391,23 @@ int main(int argc, char *argv[]) } else { if ((pw = getpwuid(atoi(target_uname))) == NULL) { @@ -56,7 +57,7 @@ } } -@@ -549,20 +580,24 @@ +@@ -555,20 +586,24 @@ int main(int argc, char *argv[]) } /* @@ -67,11 +68,11 @@ - (gid != dir_info.st_gid) || - (uid != prg_info.st_uid) || - (gid != prg_info.st_gid)) { -- log_err("target uid/gid (%ld/%ld) mismatch " -- "with directory (%ld/%ld) or program (%ld/%ld)\n", -- uid, gid, -- dir_info.st_uid, dir_info.st_gid, -- prg_info.st_uid, prg_info.st_gid); +- log_err("target uid/gid (%lu/%lu) mismatch " +- "with directory (%lu/%lu) or program (%lu/%lu)\n", +- (unsigned long)uid, (unsigned long)gid, +- (unsigned long)dir_info.st_uid, (unsigned long)dir_info.st_gid, +- (unsigned long)prg_info.st_uid, (unsigned long)prg_info.st_gid); - exit(120); + * If not called as suexec.fcgi error out if the target + * name/group is different from the name/group of the cwd @@ -82,11 +83,11 @@ + (gid != dir_info.st_gid) || + (uid != prg_info.st_uid) || + (gid != prg_info.st_gid)) { -+ log_err("target uid/gid (%ld/%ld) mismatch " -+ "with directory (%ld/%ld) or program (%ld/%ld)\n", -+ uid, gid, -+ dir_info.st_uid, dir_info.st_gid, -+ prg_info.st_uid, prg_info.st_gid); ++ log_err("target uid/gid (%lu/%lu) mismatch " ++ "with directory (%lu/%lu) or program (%lu/%lu)\n", ++ (unsigned long)uid, (unsigned long)gid, ++ (unsigned long)dir_info.st_uid, (unsigned long)dir_info.st_gid, ++ (unsigned long)prg_info.st_uid, (unsigned long)prg_info.st_gid); + exit(120); + } }