1 --- mod_fcgid-2.3.6/modules/fcgid/fcgid_proc_unix.c.orig 2011-01-03 17:25:28.000000000 +0100
2 +++ mod_fcgid-2.3.6/modules/fcgid/fcgid_proc_unix.c 2011-01-03 17:26:27.000000000 +0100
4 const char *execuser, *execgroup;
7 - if (!ap_unixd_config.suexec_enabled) {
8 + //if (!ap_unixd_config.suexec_enabled) {
10 return apr_proc_create(newproc, progname, args, env, attr, p);
15 ap_unix_identity_t ugid;
17 - if (!ap_unixd_config.suexec_enabled
18 + //if (!ap_unixd_config.suexec_enabled
20 || (procinfo->uid == (uid_t) - 1
21 && procinfo->gid == (gid_t) - 1)) {
22 return apr_proc_create(newproc, progname, args, env, attr, p);
24 * 1. Unlink the socket when the process exits
25 * 2. (suexec mode only, in the child cleanup) Switch to the configured uid
27 - if (ap_unixd_config.suexec_enabled) {
28 + //if (ap_unixd_config.suexec_enabled) {
30 apr_pool_cleanup_register(procnode->proc_pool,
31 procnode, socket_file_cleanup,
37 - if (ap_unixd_config.suexec_enabled) {
38 + //if (ap_unixd_config.suexec_enabled) {
40 /* Prior to creating the child process, a child cleanup was registered
41 * to switch the uid in the child. No-op the child cleanup for this
42 * pool so that it won't run again as other child processes are created.
44 /* su as root before sending signal, for suEXEC */
47 - if (ap_unixd_config.suexec_enabled && seteuid(0) != 0) {
48 + //if (ap_unixd_config.suexec_enabled && seteuid(0) != 0) {
49 + if (0 && seteuid(0) != 0) {
51 /* can't gain privileges to send signal (should not occur); do NOT
52 * proceed, as something is broken with current identity
56 rv = apr_proc_kill(&(procnode->proc_id), sig);
57 - if (ap_unixd_config.suexec_enabled && seteuid(ap_unixd_config.user_id) != 0) {
58 + //if (ap_unixd_config.suexec_enabled && seteuid(ap_unixd_config.user_id) != 0) {
59 + if (0 && seteuid(ap_unixd_config.user_id) != 0) {
60 /* can't drop privileges after signalling (should not occur); do NOT
61 * proceed any further as euid(0)!