You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Francesco Pasqualini <fr...@gmail.com> on 2015/08/08 20:24:05 UTC

help: need mod_cgi.so win32 fixed

Hi to all,

Can someone help me ?

I have a httpd in production on windows affected by this problem:

https://bz.apache.org/bugzilla/show_bug.cgi?id=46751#c4

Can someone compile for me a fixed (john proposal) version of mod_cgi.so ?

I contacted john without success.

./httpd.exe -v
Server version: Apache/2.2.22 (Win32)
Server built:   Jan 28 2012 11:16:39




thanks

Francesco

Re: help: need mod_cgi.so win32 fixed

Posted by Francesco Pasqualini <fr...@gmail.com>.
Thanks
I just found a temporary work around putting in sitecustomize.pl the
following:


BEGIN{
if($ENV{"ProgramFiles(x86)"} ne "C:\\Program Files (x86)"){
$ENV{ProgramFiles} = "C:\\Program Files";
$ENV{"ProgramFiles(x86)"} = "C:\\Program Files (x86)";
$ENV{ProgramFilesW6432} = "C:\\Program Files";
$ENV{CommonProgramFiles} = "C:\\Program Files\\Common Files";
$ENV{"CommonProgramFiles(x86)"} = "C:\\Program Files (x86)\\Common Files";
$ENV{CommonProgramFilesW6432} = "C:\\Program Files\\Common Files";
exec { $^X } $^X, $0, @ARGV;
};
}






On Sat, Aug 8, 2015 at 8:33 PM, Eric Covener <co...@gmail.com> wrote:

> On Sat, Aug 8, 2015 at 2:24 PM, Francesco Pasqualini <fr...@gmail.com>
> wrote:
> > Hi to all,
> >
> > Can someone help me ?
> >
> > I have a httpd in production on windows affected by this problem:
> >
> > https://bz.apache.org/bugzilla/show_bug.cgi?id=46751#c4
> >
> > Can someone compile for me a fixed (john proposal) version of mod_cgi.so
> ?
>
> That patch doesn't change mod_cgi, you need a new httpd.exe or
> libhttpd.lib (not sure what goes where on Windows). Might have more
> luck on ApacheLounge with a test build of the entire server.
>

Re: help: need mod_cgi.so win32 fixed

Posted by Francesco Pasqualini <fr...@gmail.com>.
In apache httpd windows setup the compiled modules go as .so files in the
$root/modules directory.

So to install/update a module we have to just compile/recompile it and put
the .so file in $root/modules

My problem is that I don't have a build setup and it take too long to build
and configure one just to fix a few lines

thanks

Francesco

On Sun, Aug 9, 2015 at 5:46 AM, Eric Covener <co...@gmail.com> wrote:

> On Sat, Aug 8, 2015 at 9:58 PM, Francesco Pasqualini <fr...@gmail.com>
> wrote:
> > I confirm that the patch changes mod_cgi
> >
> > infact mod_cgi.c calls the function ap_create_environment in
> util_script.c:
> >
> > env = ap_create_environment(r->pool, r->subprocess_env);
> >
> > so applying the patch to util_script.c, recompiling mod_cgi.c and
> installing
> > mod_cgi.so under the $root/modules dir will do the trick
>
> I'm no Windows expert, but I don't see how you can expect an updated
> ap_create_environment() to be used that way. I already tried to
> explain why in my first response.
>

Re: help: need mod_cgi.so win32 fixed

Posted by Eric Covener <co...@gmail.com>.
On Sat, Aug 8, 2015 at 9:58 PM, Francesco Pasqualini <fr...@gmail.com> wrote:
> I confirm that the patch changes mod_cgi
>
> infact mod_cgi.c calls the function ap_create_environment in util_script.c:
>
> env = ap_create_environment(r->pool, r->subprocess_env);
>
> so applying the patch to util_script.c, recompiling mod_cgi.c and installing
> mod_cgi.so under the $root/modules dir will do the trick

I'm no Windows expert, but I don't see how you can expect an updated
ap_create_environment() to be used that way. I already tried to
explain why in my first response.

Re: help: need mod_cgi.so win32 fixed

Posted by Jeff Trawick <tr...@gmail.com>.
On Sat, Aug 8, 2015 at 9:58 PM, Francesco Pasqualini <fr...@gmail.com>
wrote:

> Hi Eric,
> I confirm that the patch changes mod_cgi
>
> infact mod_cgi.c calls the function ap_create_environment in
> util_script.c:
>
> env = ap_create_environment(r->pool, r->subprocess_env);
>
> so applying the patch to util_script.c, recompiling mod_cgi.c and
> installing mod_cgi.so under the $root/modules dir will do the trick
>

No, util_script code is not included in individual modules; it is compiled
into the main httpd core, which on Windows is largely in libhttpd.dll.

There are a number of ways that httpd can be built on Windows (largely
based on the Microsoft compiler version and 32-bit vs. 64-bit but also
based on SDK level and support libraries).  The provider of your httpd
build would need to compile a new version for you in order to avoid
compatibility problems.



>
>
> thanks
>
> Francesco
>
> On Sat, Aug 8, 2015 at 8:33 PM, Eric Covener <co...@gmail.com> wrote:
>
>> On Sat, Aug 8, 2015 at 2:24 PM, Francesco Pasqualini <fr...@gmail.com>
>> wrote:
>> > Hi to all,
>> >
>> > Can someone help me ?
>> >
>> > I have a httpd in production on windows affected by this problem:
>> >
>> > https://bz.apache.org/bugzilla/show_bug.cgi?id=46751#c4
>> >
>> > Can someone compile for me a fixed (john proposal) version of
>> mod_cgi.so ?
>>
>> That patch doesn't change mod_cgi, you need a new httpd.exe or
>> libhttpd.lib (not sure what goes where on Windows). Might have more
>> luck on ApacheLounge with a test build of the entire server.
>>
>
>


-- 
Born in Roswell... married an alien...
http://emptyhammock.com/

Re: help: need mod_cgi.so win32 fixed

Posted by Francesco Pasqualini <fr...@gmail.com>.
Hi Eric,
I confirm that the patch changes mod_cgi

infact mod_cgi.c calls the function ap_create_environment in util_script.c:

env = ap_create_environment(r->pool, r->subprocess_env);

so applying the patch to util_script.c, recompiling mod_cgi.c and
installing mod_cgi.so under the $root/modules dir will do the trick


thanks

Francesco

On Sat, Aug 8, 2015 at 8:33 PM, Eric Covener <co...@gmail.com> wrote:

> On Sat, Aug 8, 2015 at 2:24 PM, Francesco Pasqualini <fr...@gmail.com>
> wrote:
> > Hi to all,
> >
> > Can someone help me ?
> >
> > I have a httpd in production on windows affected by this problem:
> >
> > https://bz.apache.org/bugzilla/show_bug.cgi?id=46751#c4
> >
> > Can someone compile for me a fixed (john proposal) version of mod_cgi.so
> ?
>
> That patch doesn't change mod_cgi, you need a new httpd.exe or
> libhttpd.lib (not sure what goes where on Windows). Might have more
> luck on ApacheLounge with a test build of the entire server.
>

Re: help: need mod_cgi.so win32 fixed

Posted by Eric Covener <co...@gmail.com>.
On Sat, Aug 8, 2015 at 2:24 PM, Francesco Pasqualini <fr...@gmail.com> wrote:
> Hi to all,
>
> Can someone help me ?
>
> I have a httpd in production on windows affected by this problem:
>
> https://bz.apache.org/bugzilla/show_bug.cgi?id=46751#c4
>
> Can someone compile for me a fixed (john proposal) version of mod_cgi.so ?

That patch doesn't change mod_cgi, you need a new httpd.exe or
libhttpd.lib (not sure what goes where on Windows). Might have more
luck on ApacheLounge with a test build of the entire server.