tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jonathan Eric Miller" <jemil...@uchicago.edu>
Subject Re: JNDIRealm authentication
Date Wed, 12 Jun 2002 19:23:50 GMT
Oh yeah, one other thing. I haven't tested this with Apache HTTP Server. I'm
just using Tomcat in standalone mode. I think it may work the same way if
you're using mod_webapp, but, you might want to test it in standalone mode
first to rule out any kind of problems that might be introduced if you're
using Apache HTTP Server on the front end.

Jon

----- Original Message -----
From: "Jonathan Eric Miller" <jemiller@uchicago.edu>
To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
Sent: Wednesday, June 12, 2002 2:20 PM
Subject: Re: JNDIRealm authentication


> Josh,
>
> You also need to put something similar to the following in your web.xml
> file. i.e. the stuff you put in server.xml, just tells Tomcat where to
> authenticate. The stuff in web.xml, tells Tomcat what resources are
> protected and what roles are required in order to access a particular
> resource. I have this in my conf/web.xml and as far as I can tell, it
makes
> it so that it prompts for a password for any resource that is located on
the
> server. If it's just a servlet that you are protecting, I think you should
> be able to put this in the web.xml file for that context. The Servlet 2.3
> spec defines the format of the web.xml file. You can find it at
> http://java.sun.com under the Servlets section.
>
> <security-constraint>
>  <web-resource-collection>
>   <web-resource-name>myresource</web-resource-name>
>   <url-pattern>/*</url-pattern>
>  </web-resource-collection>
>  <auth-constraint>
>   <role-name>myrole</role-name>
>  </auth-constraint>
> </security-constraint>
> <login-config>
>  <auth-method>BASIC</auth-method>
>  <realm-name>myrealm</realm-name>
> </login-config>
>
> Jon
>
> ----- Original Message -----
> From: "Josh Fenlason" <jfenlason@ptc.com>
> To: "Tomcat" <tomcat-user@jakarta.apache.org>
> Sent: Wednesday, June 12, 2002 1:18 PM
> Subject: JNDIRealm authentication
>
>
> > I'm trying to do LDAP authentication with Tomcat 4.1.3.  I've read
through
> > the how to docs on Tomcat's site,
> >
>
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/realm-howto.html#JNDIRealm,
> > and tried to follow the example.  My site loads fine, but I never get an
> > authentication prompt when I enter my site.  If anyone could sees
anything
> > wrong with my <Realm/> or has any ideas of where else I should need to
> > change things, I would greatly appreciate it.  Thanks.
> > ,
> > Josh.
> >
> > Here's what I entered for the Realm element in
> > <tomcat4.1.3_home>/conf/server.xml
> >
> > <Realm className="org.apache.catalina.realm.JNDIRealm"
> >     connectionName="ou=People,ou=jfenlason_r62DC,ou=jfenlason,l=Arden
> > Hills,o=Bethel"
> >     connectionPassword="secret"
> >     connectionURL="ldap://corvette.mn.ptc.com:389"
> >     roleName="oid"
> >     roleSearch="(uniqueMember={0})"
> >     userPassword="userPassword"
> >
userPattern="oid={0},ou=People,ou=jfenlason_r62DC,ou=jfenlason,l=Arden
> > Hills,o=Bethel"
> >     debug="99"/>
> >
> > Here's the AuthLDAPURL that works with Apache1 doing the authentication
> >
>
ldap://corvette.mn.ptc.com:389/ou=People,ou=jfenlason_r62DC,ou=jfenlason,l=A
> > rden Hills,o=Bethel"
> >
> >
> > --
> > To unsubscribe, e-mail:
> <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail:
> <mailto:tomcat-user-help@jakarta.apache.org>
> >
>
>
> --
> To unsubscribe, e-mail:
<mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:tomcat-user-help@jakarta.apache.org>
>


--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>


Mime
View raw message