Joshua Slive [Sat, 27 Oct 2001 22:22:00 +0000 (22:22 +0000)]
Fix some broken links, change to the simplest possible example, and add a
couple notes to give hints to people running servers behind port-forwarding
firewalls.
Jeff Trawick [Sat, 27 Oct 2001 14:01:13 +0000 (14:01 +0000)]
make shared libraries executable so they work on HP-UX
(I'm not sure that this logic for copying DSOs will survive
in the libtool scheme; I'm putting this 1.3 fix in just in
case.)
Fix RedirectMatch handling to properly handle URLs with host portions.
Previously, we would segfault if no path is specified (case 1 below).
We would also ignore any host and scheme portion of the URL (which is
how we specify it on daedalus), so restore that capability.
The query strings will still not be escaped (standards cops can
determine if this is correct behavior).
The following directives now work as expected:
RedirectMatch /jakarta1(.*) http://jakarta.apache.org$1
RedirectMatch /jakarta2(.*) http://jakarta.apache.org/dist$1
RedirectMatch /jakarta3(.*) http://jakarta.apache.org/dist$1?bar=foo
RedirectMatch /jakarta4(.*) http://jakarta.apache.org/dist$1?bar=foo#spaz
Greg Ames [Fri, 26 Oct 2001 15:40:04 +0000 (15:40 +0000)]
prevent seg faults in mod_status trying to access vhost structures from
the former generation, after a restart. It happens mostly when the MPM has
threads.
Aaron Bannert [Wed, 24 Oct 2001 17:20:44 +0000 (17:20 +0000)]
Two more mod_so configure-time fixes:
- Treat --enable-so=yes as "static" (this includes --enable-so, etc).
- An explicit --enable-so=shared issues an error.
Put in a note about the last condition that I'm not as sure how to fix:
If the user doesn't explicitly request mod_so, but instead gives a
mass-enable parameter like --enable-modules=most or
--enable-mods-shared=most then it is still possible to enable a bunch
of modules while mod_so itself is not buildable (ie no APR_HAS_DSO or
other build dependency failure).
Aaron Bannert [Tue, 23 Oct 2001 23:13:27 +0000 (23:13 +0000)]
If the user explicitly requests --enable-so, --enable-so=yes,
--enable-so=static, or --enable-so=shared but APR_HAS_DSO is
not defined on their system, then it is a fatal error.
Tested on Solaris, but I think it should work everywhere else.
Feel free to change the error message to something
better/more descriptive/etc.
Bill Stoddard [Tue, 23 Oct 2001 17:13:26 +0000 (17:13 +0000)]
Win32: Track and display "Parent Server Generation:" in
mod_status output. The generation will be bumped at
server graceful restart, when the child process exits
by hitting MaxRequestsPerChild or if the child
process exits abnormally. [Bill Stoddard]
Cliff Woolley [Tue, 23 Oct 2001 09:41:54 +0000 (09:41 +0000)]
Fix a segfault seen on daedalus earlier this evening. All that was happening
was that we forgot to check whether ctx->bb was empty, so when we pulled the
first bucket, it would be the sentinel, and we'd segfault trying to apr_bucket_read
the sentinel.
Jeff Trawick [Mon, 22 Oct 2001 13:04:12 +0000 (13:04 +0000)]
Fix some bungling of the remote port in rfc1413.c so that
IdentityCheck retrieves the proper user id instead of failing
and thus always returning "nobody."
Submitted by: Dick Streefland <Dick.Streefland@xs4all.nl>
Reviewed by: Jeff Trawick
Simplified mod_env's directives to behave as most directives are
expected, in that UnsetEnv will not unset a SetEnv and PassEnv
directive following that UnsetEnv within the same container.
Also provides a runtime startup warning if a PassEnv configured
environment value is undefined.
Restrict by content type and encoding before we go and try to drag in some
text to merge as headers and footers to autoindex pages. This will escape
index.gif from a bold attempt to use IndexHeader index ;)
Also pass in the args to the subrequest, for anyone trying to decode what
the user is looking at. A great example of this coming up.
Canonicalize all absolute <Directory > sections, not simply those that
fail to end in a '/'. Slash test is afterwords, once we've canonicalized
any '\' and other aliases to '/'.
Oh, don't you love buffer overflows?
We need to allocate storage space for the terminating NULL AND the extra /
we may tack on to the string at some point.
How in the hell the stars were aligned for this to corrupt newv via the
strcat at line 580 is unknown.
Aaron Bannert [Fri, 19 Oct 2001 23:36:55 +0000 (23:36 +0000)]
The worker MPM is now completely ported to APR's new lock API. It
uses native APR types for thread mutexes, cross-process mutexes,
and condition variables. Who's next?
Aaron Bannert [Fri, 19 Oct 2001 23:32:43 +0000 (23:32 +0000)]
Use the APR's new OS-specific proc mutex accessors -- they are used
here to set permissions on SysV Semaphores. MPMs will be modified to
call this new function as they are ported to the new APR lock API.
Bill Stoddard [Fri, 19 Oct 2001 21:11:03 +0000 (21:11 +0000)]
Win32: ap_max_requests_per_child should not be a local static in mpm_winnt.c.
This was preventing the MaxRequestsPerChild config directive from working
properly.
Handle MaxRequestsPerChild a bit more sanely. When MaxRequestsPerChild is hit,
the child signals an event that causes the main child thread to signal the parent
to restart.
Hey, we tagged 2.0.26. =)
We're now waiting for it to be discarded or we need to bump the tag on
server/core.c. And, we need to fix the proc_wait thing to someone's
satisfaction.
Remove all references to the Port directive and replace it with
appropriate links to the Listen directive.
If I had known that so many files had the Port directive in it, I would
have bundled this up as one big commit. *sigh* I just kept looking
and finding new files, fixing, and committing. So, this should be the
rest of them for now.
Aaron Bannert [Wed, 17 Oct 2001 21:34:29 +0000 (21:34 +0000)]
Gets VPATH builds working again. The problem was that apr.h is generated
by autoconf and then placed in the builddir, not the srcdir (which we
didn't notice until we tried to do VPATH). When cpp couldn't find apr.h
we would decide not to build mod_so, which is kinda bad.
Now we include both paths when we test for APR_HAS_DSO and everyone is happy.
Aaron Bannert [Wed, 17 Oct 2001 16:29:37 +0000 (16:29 +0000)]
Fully convert worker's fdqueue to the new APR lock API:
- Mutexes and Condition Variables from APR are now used instead of
direct (non-portable) calls to pthread.
Still need to fully APRize these routines, particularly the return
values. In many cases a failed lock or cond var call will simply return
FD_QUEUE_FAILURE. This should obviously instead return the appropriate
APR error code.
Joshua Slive [Wed, 17 Oct 2001 15:57:04 +0000 (15:57 +0000)]
I certainly see the advantage of having SSL split out into another file.
And indeed, that is the way that I would do it for my own server. But
the default config file is really there for beginners, not for advanced
users. Having multiple config files is bad for beginners because it
makes it difficult to answer questions like "where do I put this config
directive?" It also makes it more difficult to move a specific configuration
from one server to another. Finally, it is just overall more intimidating
to be faced with a bunch of files to edit, rather than one file that
controls everything.
Having said that, it does look like the overall feeling is that at least
SSL should be split out, and I won't object (strongly).
Bill Stoddard [Wed, 17 Oct 2001 15:51:22 +0000 (15:51 +0000)]
Win32: Deprecate ap_start_shutdown/ap_start_restart in favor of ap_signal_parent(enum).
This simplifies the code a bit for some more MPM cleanup work forthcoming.
Jim Jagielski [Wed, 17 Oct 2001 15:32:22 +0000 (15:32 +0000)]
Not sure if the number of directives in a normal proxy setup would
warrant needing a whole separate config file. I see such break outs
as pretty much dependent on the number of lines it adds to
httpd.conf... with SSL it makes sense. With proxy, well, I'm not
sure. To be honest, though, breaking out both won't trouble me
a bit, but this is my pref.
PR:
Obtained from:
Submitted by:
Reviewed by:
Ken Coar [Wed, 17 Oct 2001 14:50:48 +0000 (14:50 +0000)]
The argument that this is a reversion to the httpd/access/srm
multifile scenario is bogus, IMHO; the problem with those
was that their purposes were not clear, nor were the orders
of invocation. Putting massive (or tiny but uncommon) chunks
of easily self-contained special-function directives into
separate files simplifies the basic configuration and doesn't
revert to either of the trinity-file complaints, since these
would need to be explicitly invoked with an Include directive.
Aaron Bannert [Wed, 17 Oct 2001 00:59:18 +0000 (00:59 +0000)]
First pass at converting worker MPM to APR's new lock API. This converts
the APR_INTRAPROCESS locks into lightweight, non-nested apr_thread_mutex_t
locks.
It is absolutely invalid practice to test 'prot' bits to determine if a
file is readable. The only acceptable means of testing readability is to
open it for reading, due to discrepancies between permissions, DACLs and
SACLS. Even Linux hackers are gonna need to learn that lesson if they
plan to do any DOD or Gov work once DACL-enhanced Linux is adopted.