Check out http://www.mail-archive.com/[EMAIL PROTECTED]/ for a
lot of already resolved issues regarding Realms for Tomcat with Slide. There
is a weird thing about auth:ing against slide namespace (When Domain.xml is
read properly) using the sliderealm because users are added using a certain
namespace property.

Anyways. You can just recompile the servlet and use the Domain.init()-method
to load a Domain.xml from a specific URL. (Such as C:\Doman.xml etc.) to
avoid path-issues. Put it in the servlets config-params and load it from the
servlet configuration to make it more general after compile.

The reason it complains when you use sliderealm is because sliderealm uses
the slide domain/namespace and (I believe?) UserDatabaseRealm has no idea of
what slide even is so doesn't care about it. Since Domain.xml isn't loaded
it crashes and burns...

You can have several Realms and just set up one for your specific servlet.
See the configuration example at jakarta.apache.org/slide/ for an example of
how to use a slide-domain in your servlet-config file after you have
properly set up the sliderealm. Note that you need to have a few catalina
classes and such in common/lib for the sliderealm to work properly. (See
more in the above URL).

Going away for a week, hope this helps in any way.

Sincerely, Peder

----- Original Message -----
From: "Michael Oliver" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Saturday, June 28, 2003 10:12 PM
Subject: Re: Slide-Admin


> Ok more trial and error.  Here is what I did.
>
> First trying to get the SlideRealm included.
>
> Moved slide-catalinawrapper.jar to the server\lib directory of tomcat.
>
> Then I modified the tomcat server.xml
>
> after:
> <Realm className="org.apache.catalina.realm.UserDatabaseRealm" debug="0"
> resourceName="UserDatabase" validate="true"/>
>
> added:
> <Realm className="wrappers.catalina.SlideRealm" debug="0"
> resourceName="SlideDatabase" validate="true"/>
>
> when I restart tomcat I get:
>
> stderr
>
> INFO: Initializing Coyote HTTP/1.1 on port 8080
> java.lang.reflect.InvocationTargetException
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> at java.lang.reflect.Method.invoke(Unknown Source)
> at
>
org.apache.catalina.startup.BootstrapService.start(BootstrapService.java:245
)
> at
>
org.apache.catalina.startup.BootstrapService.main(BootstrapService.java:307)
> Caused by: org.apache.slide.common.DomainInitializationFailedError: Domain
> initialization error : Domain.xml (The system cannot find the file
> specified)
> at org.apache.slide.common.Domain.selfInit(Domain.java:733)
> at org.apache.slide.common.Domain.accessNamespace(Domain.java:266)
> at wrappers.catalina.SlideRealm.start(SlideRealm.java:219)
> at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1173)
> at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:347)
> at
org.apache.catalina.core.StandardService.start(StandardService.java:497)
> at org.apache.catalina.core.StandardServer.start(StandardServer.java:2189)
> at
>
org.apache.catalina.startup.CatalinaService.start(CatalinaService.java:271)
>
> When I comment out the element with the SlideRealm, tomcat starts with no
> error and Slide-Admin works.
>
> Why does it find Domain.xml in the bin directory with only the
> UserDatabaseRealm but not with the SlideRealm?
>
> Michael Oliver
> CTO/Matrix Intermedia
> 7391 S. Bullrider Ave.
> Tucson, AZ 85747
> Office (520)574-1150
> Cell (518)378-6154
>
>
> K.C. Baltz said:
> > I'll take a swing at some of these.
> >
> > Michael Oliver wrote:
> >
> >>Amplification - I have Tomcat 4.1 and Slide-Admin doesn't find
> >> Domain.xml when I have Tomcat running as a service...Problem 1 and
> >> question 1 how can I get Slide and Slide-Admin working on Tomcat 4.1
> >> when it is running as a service on Win2k AS?
> >>
> > In one of your servlets, try creating a file without specifying a
> > directory.  Then, search for that filename in Explorer.  It should be
> > created in the same place Tomcat is going to look for Domain.xml.
> >
> >
> >>Question three - I have just the UserDatabaseRealm configured now and
> >> root user with root role setup in Tomcat and I can access Slide-Admin
> >>ok....however all accesses to the WebDAV show transactions in the
> >> stdout for user/Guest no matter how I connect.  I tried MS WebFolders
> >> and it didn't challenge me for username and password and I tried the
> >> WebDrive client setup with root username and password, but still all
> >> activity in stdout shows users/guest.  Is this because I dont' have the
> >> slide-realm configured in Tomcat?
> >>
> >>
> > I don't think Slide will handle prompting for login.  Try protecting
> > your app with standard web.xml security configuration options.
> >
> >>Question four - if I can have more than one realm in Tomcat 4.1 then
> >> how do I do that?  I tried adding it to server.xml but it throws and
> >> exception that it couldn't find wrappers.calalina.slideRealm even
> >> though I have the jars in the common/lib directory.
> >>
> >>
> > Put Realm classes in server/lib.
> >
> > K.C.
> >
> >
> > --------------------------------------------------------------------- To
> > unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to