httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eugene <httpd.subscr...@infosatgeomatica.com>
Subject Re[2]: [users@httpd] Bug 21242 Trailing character renders pages with code
Date Fri, 03 Sep 2004 19:46:29 GMT
Hello Laurent, in your {DocumentRoot} create ROOT folder, inside put
your index.jsp, then in ROOT folder create WEB-INF folder and put
inside file web.xml which contains this:
<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE web-app
    PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
    "http://java.sun.com/dtd/web-app_2_3.dtd">

<web-app>
  <display-name>My Root or Whatever</display-name>
  <description>
     My Root or Whatever.
  </description>
</web-app>

So now you have: {DocumentRoot}/ROOT/WEB-INF/web.xml
Your root for jsp's pages is {DocumentRoot}/ROOT/ now.

Then delete all this stuff with <Directory>
Location should be configured like this:
    <Location "/*.jsp">
       JkUriSet worker ajp13:localhost:8009
    </Location>
    <Location "/*.jspx">
      JkUriSet worker ajp13:localhost:8009
    </Location>
    <Location "/*.do">
       JkUriSet worker ajp13:localhost:8009
    </Location>

Also its important to configure your workers2.properties:
[shm]
file=/usr/server/apache/logs/jk2.shm
size=1048576

[lb:lb]

[status:]
info=Status worker, displays runtime information.
debug=0
disabled=0

# -- Channels -- #
[channel.socket:localhost:8009]
info=Forward to a local TCPIP socket.
port=8009
host=127.0.0.1
group=ajp13:localhost:8009

# -- Workers -- #
[ajp13:localhost:8009]
info=Ajp13 worker using a local channel.
channel=channel.socket:localhost:8009

[uri:/*.jsp]
group=ajp13:localhost:8009
[uri:/*.jspx]
group=ajp13:localhost:8009
[uri:/*.do]
group=ajp13:localhost:8009


Friday, September 3, 2004, 12:09:02 PM, you wrote:

> Quoting Joshua Slive <jslive@gmail.com>:

>> Just for the rest of the list who has no idea what we're talking
>> about, this was a followup to the following bug report:
>> http://issues.apache.org/bugzilla/show_bug.cgi?id=21242

> Right! Sorry, should have done that!

> I've got one more question, though. I'm quite happy with the result (no more
> source code shown), except for one detail: the DirectoryIndex value is not used
> anymore.

> Here is the config again, I did a small correction on the LocationMatch:

>   <LocationMatch "/.*\.jsp$">
>     JkUriSet worker ajp13:localhost:8009
>   </LocationMatch>

>   <Directory "C:/path">
>     DirectoryIndex index.jsp
>     Options None
>     AllowOverride None
>     Order allow,deny
>     Deny from all

>     <FilesMatch "\.(css|png|html|js)$">
>       Allow from all
>     </FilesMatch>
>   </Directory>

> So, if I connect to http://host/path/index.jsp, it works, but http://host/path/
> returns a 403.
> Logical, but is there a way to allow the DirectoryIndex to work without doing an
> Allow from all in the Directory?
> I tried with Files, FilesMatch.
> Maybe with a redirect, but that seems to be an ugly solution?

>> I'm really not an expert in this area, but it does appear to me that
>> mod_jk2 is really abusing the apache api and doing things in some
>> funny ways.

> Possible. I did regret choosing it over mod_jk. But at the time, it was
> announced as a better connector, more adapted to Apache 2, the next generation.
> I haven't had time to start testing mod_jk instead. I'm afraid it would take too
> long, for little gain.

>> I believe there is some work ongoing to make a connector that will be
>> better integrated into apache httpd.  I hope that will help avoid
>> stuff like this in the future.

> I'll try it if possible! If better integration also means better documentation,
> I'm all for it!

> Thanks,

> Laurent



-- 
Best regards,
 Eugene                            mailto:httpd.subscribe@infosatgeomatica.com


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message