RE: Production Settings

2005-10-06 Thread Pitre, Russell
Yup!!  That was vague, sorry about that.  I am particularly interested
in recommended production settings for server.xml and
TOMCAT_HOME/conf/web.xml such as the fork setting for jsp compilation.



Russ

-Original Message-
From: Arup Vidyerthy [mailto:[EMAIL PROTECTED] 
Sent: Thursday, October 06, 2005 9:24 AM
To: 'Tomcat Users List'
Subject: RE: Production Settings

This is vague!! Recommended production settings for what exactly...? I
would
think it varies from application to application. 

-Original Message-----
From: Pitre, Russell [mailto:[EMAIL PROTECTED] 
Sent: 06 October 2005 14:21
To: tomcat-user@jakarta.apache.org
Subject: Production Settings

Does anyone know where I can find documentation on recommended
production
setting for Windows environment?  I tried googling for some information
but
I did not come back with much.


Thanks in advance

Russ

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



___ 
To help you stay safe and secure online, we've developed the all new
Yahoo! Security Centre. http://uk.security.yahoo.com

-
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]



Production Settings

2005-10-06 Thread Pitre, Russell
Does anyone know where I can find documentation on recommended
production setting for Windows environment?  I tried googling for some
information but I did not come back with much.


Thanks in advance

Russ

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



JSTL Question

2005-08-09 Thread Pitre, Russell
Hello All-

I'm running Tomcat 5.0.24 and using the jstl libs from apache.  

I have two versions of a jsp below.  The difference between the two is
the taglib declaration.  The top one works and the bottom one doesn't.
Can someone enlighten me as to why this is?  It seems like the bottom
one does not handle the expression language.


WORKS

<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt"; %>



 
This is my JSP page. 


  

  


===
DOES NOT WORK
===
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core"; %>



 
This is my JSP page. 


  

  


I Received the following error:

"According to TLD or attribute directive in tag file, attribute value
does not accept any expressions"


Thanks 
Russ

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



response.setHeader "Contect-Encoding"

2004-08-12 Thread Pitre, Russell
Hello All-

Is it possible to set response header "Content-Encoding" to "gzip" in a
JSP.  I know it's possible in a servlet and I thought a jsp is more or
less a servlet.  The OutputStream is a JSPWriter rather than a
Printwriter and I'm not sure how deal with this.

I tried searching google for some code examples but no luck.  I will
appreciate any help you can give me.


String encoding = request.getHeader("Accept-Encoding");
System.out.println("# Encoding: " + encoding);
   
if (encoding != null && encoding.indexOf("gzip") != -1) {
OutputStream out1 = response.getOutputStream();
out = new PrintWriter(new GZIPOutputStream(out1), false);
response.setHeader("Content-Encoding" , "gzip");
} else {
out = response.getWriter();
}

ERROR:
C:\JAVA\jakarta-tomcat-5.0.24\work\Catalina\localhost\_\org\apache\jsp\f
axing\sent_005ffaxes_jsp.java:122: incompatible types
found   : java.io.PrintWriter
required: javax.servlet.jsp.JspWriter
   out = new PrintWriter(new GZIPOutputStream(out1), false);

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



RE: Authentification against NT Domain Controller

2004-04-18 Thread Pitre, Russell
Try taking a look at this http://jcifs.samba.org/

Look into using the NTLM authentication filter.  You'll achieve single-on 
authentication and when you need to grab the user's username, you can use this:

String username = ((HttpServletRequest)request).getRemoteUser();


Russ-

-Original Message-
From: Frank Schaare [mailto:[EMAIL PROTECTED] 
Sent: Sunday, April 18, 2004 6:01 AM
To: [EMAIL PROTECTED]
Subject: Authentification against NT Domain Controller

Hi,

we´re building an Intranet application running on Tomcat 4.1.30 (Client 
OS is Win2K). It would be very suitable to authentificate the users 
against the NT Domain Controller to avoid a second login.

I searched this ML and Google but did not find very much about this theme.

There is a SourceForce Project called NTDCRealm which seems to fit our 
needs, but has absolutely no documentation.

Probably, we need to nest a custom NTDCRealm Tag in our WebApp context. 
To learn, how to do this, i searched the Tomcat documentation 
(http://jakarta.apache.org/tomcat/tomcat-4.1-doc/realm-howto.html#Standard%20Realm%20Implementations)
and again, there is a gap:

"It is also possible to write your own Realm implementation, and 
integrate it with Tomcat 4. However, doing this is beyond the scope of 
this document. See (FIXME - reference to developer stuff) for more 
information."

Here are my questions:

Does this reference to developer stuff exist anywhere ?
Does anyone ever made the NTDCRealm to work ?
Does anyone knows another (documentatet) Implementation of NT 
authentification ?

Any hints, links, documents about this theme are warmly welcome.

-
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]



RE: Filter chain

2004-03-12 Thread Pitre, Russell
Thanx, I must have over looked it ;)

-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
Sent: Friday, March 12, 2004 10:44 AM
To: Tomcat Users List
Subject: RE: Filter chain


Hi,

>Is it possible to specify the sequence of filters being processed by
the
>container?  I have a checksession filter that throws a "user" object
>into the session and a second filter will gather statistics on
>requestsI want the checksession filter to be processed first

The Servlet Spec is your friend.  From SRC.6.2.4:
"The order the container uses in building the chain of filters to be
applied for a
particular request URI is as follows:
1. First, the  matching filter mappings in the same order
that these
elements appear in the deployment descriptor.
2. Next, the  matching filter mappings in the same order
that
these elements appear in the deployment descriptor."

There is more in that section if you're interested.

Yoav Shapira



This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential,
proprietary and/or privileged.  This e-mail is intended only for the
individual(s) to whom it is addressed, and may not be saved, copied,
printed, disclosed or used by anyone else.  If you are not the(an)
intended recipient, please immediately delete this e-mail from your
computer system and notify the sender.  Thank you.


-
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]



Filter chain

2004-03-12 Thread Pitre, Russell
Is it possible to specify the sequence of filters being processed by the
container?  I have a checksession filter that throws a "user" object
into the session and a second filter will gather statistics on
requestsI want the checksession filter to be processed first

 

 

Thanx

Russ



RE: jcifs and security realm discussion.

2004-01-22 Thread Pitre, Russell
I guess what I'm trying to ask after thinking about it moreHow would
I go about writing my own Realm to manage authorization.because I
already have the authentication (single sign-on) piece through using
jcifs.I'm not sure where to start I want to call isUserInRole()
and have tomcat check Active Directory and a Database (the intranet is
another interface for an application that we have that has a fat client
and this application uses a database for storing info)i was hoping
to get a little insight into how  I can code a realm for just the
authorization piece.


Thanx
Russ






-Original Message-----
From: Pitre, Russell 
Sent: Thursday, January 22, 2004 9:32 AM
To: [EMAIL PROTECTED]
Subject: jcifs and security realm discussion.

Hello all-

 

I am really puzzled right now and was hoping you all could shed some
light onto me.  I am developing a corporate intranet.  I have jcifs ntlm
http filter ( http://jcifs.samba.org/ ) working for me and all seems to
be working fine.  I can call getRemoteUser() and get the domain and
username for the user.  Which is great, I can use the username to tie
into AD and get that persons security groups to determine access to
certain job specific functions on the intranet (btw, all clients are
IE). But, I'm concerned.  My question does not really have to do with
jcifs but with security realms. I ultimately want to
isUserInRole("role") within my jsp's to determine access (I think).  But
I'm confused as to go about implementing such a scheme.  I was thinking
that I may have to write a custom realm but I'm not sure if this is the
right way to go about it.

 

With jcifs I can use the username from getRemoteUser() and use that to
lookup which security groups that user is member and determine my access
this way.  But I'm really skeptical of this scenario.  

 

 

Does anyone have any suggestions or ideas for my situation?

 

 

Thanx in advance

Russ


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



jcifs and security realm discussion.

2004-01-22 Thread Pitre, Russell
Hello all-

 

I am really puzzled right now and was hoping you all could shed some
light onto me.  I am developing a corporate intranet.  I have jcifs ntlm
http filter ( http://jcifs.samba.org/ ) working for me and all seems to
be working fine.  I can call getRemoteUser() and get the domain and
username for the user.  Which is great, I can use the username to tie
into AD and get that persons security groups to determine access to
certain job specific functions on the intranet (btw, all clients are
IE). But, I'm concerned.  My question does not really have to do with
jcifs but with security realms. I ultimately want to
isUserInRole("role") within my jsp's to determine access (I think).  But
I'm confused as to go about implementing such a scheme.  I was thinking
that I may have to write a custom realm but I'm not sure if this is the
right way to go about it.

 

With jcifs I can use the username from getRemoteUser() and use that to
lookup which security groups that user is member and determine my access
this way.  But I'm really skeptical of this scenario.  

 

 

Does anyone have any suggestions or ideas for my situation?

 

 

Thanx in advance

Russ



RE: Tomcat-Apache Security

2003-12-17 Thread Pitre, Russell
I have this book and I like it.The java security manager is a little
over my head at this point in my Tomcat experiencesI'm sure I'll
pick it up soon.the chapters on the Realms are really good as well
as the second or third chapter on file security...I found it pretty
straight forward and to the point.One thing I would of liked to have
seen more of is programmatic application security..Overall, its
definitely worth having IMHO

Cheers
Russ




-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, December 17, 2003 9:05 AM
To: Tomcat Users List
Subject: RE: Tomcat-Apache Security


Howdy,
Maybe google or a book like this:
http://www.programming123.com/detail/apache/apache_1861008309.html

In the future, you might want to think about security before setting up
a production environment ;)

Yoav Shapira
Millennium ChemInformatics


>-Original Message-
>From: Joaquin Corchero [mailto:[EMAIL PROTECTED]
>Sent: Wednesday, December 17, 2003 4:53 AM
>To: Tomcat Users List
>Subject: Tomcat-Apache Security
>
>Good morning.
>
>I'm new in Tomcat-Apache administration and I just created a production
>environment, but I need some guidelines to give securtity to my web
>applications.
>
>Can anyone give me some url's where I can find information about it?
>
>Thank you very much.



This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential,
proprietary and/or privileged.  This e-mail is intended only for the
individual(s) to whom it is addressed, and may not be saved, copied,
printed, disclosed or used by anyone else.  If you are not the(an)
intended recipient, please immediately delete this e-mail from your
computer system and notify the sender.  Thank you.


-
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]



RE: Tomcat 5 Clustering

2003-12-16 Thread Pitre, Russell
Okwill do...should I post them here or offline.Maybe others will
be able to benefit from our conversation


Russ

-Original Message-
From: Filip Hanik [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, December 16, 2003 3:17 PM
To: Tomcat Users List
Subject: Re: Tomcat 5 Clustering

hmm, on your console or in your log, are the systems finding each other,
ie, do you have multicast enabled and do the nodes actually connect to
each
other?
send the logs from a clean run, ie stop, delete logs, start, send logs
Filip
- Original Message -
From: "Pitre, Russell" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Tuesday, December 16, 2003 12:08 PM
Subject: RE: Tomcat 5 Clustering


Hi Filip-

Sorry, while being caught up in the problem statement..I forgot to
mention that I'm using Microsoft Network Load Balancing services for
load balancing and failover detectionagain my apologies

When I do pull the plugI am redirected to the working node...and
when I try getAttribute("myAttribute") on that same session (never
closed the browser) the session or session attribute  is no longer
obtainable...


Russ





-Original Message-
From: Filip Hanik [mailto:[EMAIL PROTECTED]
Sent: Tuesday, December 16, 2003 2:13 PM
To: Tomcat Users List
Subject: Re: Tomcat 5 Clustering

download a load balancer

balance.sourceforge.net or a perl balancer called "pen" (google)

the shut down one tomcat, after initial access, the system will fail
over.

pulling the network cable without any other failure has not yet been
handled
as a failure scenario

Filip

- Original Message -
From: "Pitre, Russell" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Tuesday, December 16, 2003 10:37 AM
Subject: Tomcat 5 Clustering


Hello All:



Please excuse my ignorance, I'm trying to achieve clustering with Tomcat
5I've read the following in the Tomcat 5 documentation:


=

To run session replication in your Tomcat 5 container, the following
steps should be completed:
-->All your session attributes must implement java.io.Serializable


===



Okay. I've completed all the other steps (uncomment the 
element along with the , and added the  in
web.xml)I'm trying to code a simple object that implements
java.io.Serializable to store in a session and here it is.



package com.shawmut.session;

import java.io.Serializable;



public class SerializeSession implements Serializable {



public static String testString  = "";



public void setString(String stringValue){

this.testString = stringValue;

}

public String getString(){

return this.testString;

}

}



ok.Now I want to put this in the session.



<%

if(session.getAttribute("ss")== null){

SerializeSession ss = new SerializeSession();

ss.setString("Booo! And I created my
session on Tomcat 1 Node");

session.setAttribute("ss", ss);

}

%>









Whats going on here?.I unplug the patch cord ( docs says it's a bad
idea) from one of the boxes and hit a jsp on the working node that does
the following..and the session doesn't carry over to the working
node



<%

if(session.getAttribute("ss")!= null){

SerializeSession ss2 =
(SerializeSession)session.getAttribute("ss");

%>

SESSION:<%=ss2.getString()%>



<%

}

%>







Basically what I'm looking for is an example of serializing session
attributes as noted above Any Help here will be greatly
appreciated..





Russ









-
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]


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



RE: Tomcat 5 Clustering

2003-12-16 Thread Pitre, Russell
Hi Filip-

Sorry, while being caught up in the problem statement..I forgot to
mention that I'm using Microsoft Network Load Balancing services for
load balancing and failover detectionagain my apologies

When I do pull the plugI am redirected to the working node...and
when I try getAttribute("myAttribute") on that same session (never
closed the browser) the session or session attribute  is no longer
obtainable...


Russ





-Original Message-
From: Filip Hanik [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, December 16, 2003 2:13 PM
To: Tomcat Users List
Subject: Re: Tomcat 5 Clustering

download a load balancer

balance.sourceforge.net or a perl balancer called "pen" (google)

the shut down one tomcat, after initial access, the system will fail
over.

pulling the network cable without any other failure has not yet been
handled
as a failure scenario

Filip

- Original Message -----
From: "Pitre, Russell" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Tuesday, December 16, 2003 10:37 AM
Subject: Tomcat 5 Clustering


Hello All:



Please excuse my ignorance, I'm trying to achieve clustering with Tomcat
5I've read the following in the Tomcat 5 documentation:


=

To run session replication in your Tomcat 5 container, the following
steps should be completed:
-->All your session attributes must implement java.io.Serializable


===



Okay. I've completed all the other steps (uncomment the 
element along with the , and added the  in
web.xml)I'm trying to code a simple object that implements
java.io.Serializable to store in a session and here it is.



package com.shawmut.session;

import java.io.Serializable;



public class SerializeSession implements Serializable {



public static String testString  = "";



public void setString(String stringValue){

this.testString = stringValue;

}

public String getString(){

return this.testString;

}

}



ok.Now I want to put this in the session.



<%

if(session.getAttribute("ss")== null){

SerializeSession ss = new SerializeSession();

ss.setString("Booo! And I created my
session on Tomcat 1 Node");

session.setAttribute("ss", ss);

}

%>









Whats going on here?.I unplug the patch cord ( docs says it's a bad
idea) from one of the boxes and hit a jsp on the working node that does
the following..and the session doesn't carry over to the working
node



<%

if(session.getAttribute("ss")!= null){

SerializeSession ss2 =
(SerializeSession)session.getAttribute("ss");

%>

SESSION:<%=ss2.getString()%>



<%

}

%>







Basically what I'm looking for is an example of serializing session
attributes as noted above Any Help here will be greatly
appreciated..





Russ









-
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]



RE: How do i run 2 tomcats on the same server and using jk2?

2003-12-16 Thread Pitre, Russell
You also need to edit your worker.properties file...

worker.list=tomcatWorker
worker.tomcatWorker.port=8009
worker.tomcatWorker.host=172.20.94.244
worker.tomcatWorker.type=ajp13


Russ

-Original Message-
From: yuval [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, December 16, 2003 1:57 PM
To: Tomcat Users List
Subject: How do i run 2 tomcats on the same server and using jk2?

Hi,

I installed 2 Tomcats on the same server and they both work on on port
8080
and the second on 8081
I also define one to listen for the jk2 on 8009 and the second on 8010
but
only the first one is working

What do i need to do in the registry and in the IIS in order to make the
second work also?


Regards,

Yuval


-
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]



Tomcat 5 Clustering

2003-12-16 Thread Pitre, Russell
Hello All:

 

Please excuse my ignorance, I'm trying to achieve clustering with Tomcat
5I've read the following in the Tomcat 5 documentation:


=

To run session replication in your Tomcat 5 container, the following
steps should be completed:
-->All your session attributes must implement java.io.Serializable 


===

 

Okay. I've completed all the other steps (uncomment the 
element along with the , and added the  in
web.xml)I'm trying to code a simple object that implements
java.io.Serializable to store in a session and here it is.

 

package com.shawmut.session;

import java.io.Serializable;

 

public class SerializeSession implements Serializable {



public static String testString  = "";

 

public void setString(String stringValue){

this.testString = stringValue;

}

public String getString(){

return this.testString;

}

}

 

ok.Now I want to put this in the session.

 

<%

if(session.getAttribute("ss")== null){

SerializeSession ss = new SerializeSession();

ss.setString("Booo! And I created my
session on Tomcat 1 Node");

session.setAttribute("ss", ss);

}

%>

 

 

 

 

Whats going on here?.I unplug the patch cord ( docs says it's a bad
idea) from one of the boxes and hit a jsp on the working node that does
the following..and the session doesn't carry over to the working
node

 

<%

if(session.getAttribute("ss")!= null){

SerializeSession ss2 =
(SerializeSession)session.getAttribute("ss");

%>

SESSION:<%=ss2.getString()%>

 

<%

}   

%>

 

 

 

Basically what I'm looking for is an example of serializing session
attributes as noted above Any Help here will be greatly
appreciated..

 

 

Russ

 

 

 



RE: Manager Valve

2003-12-15 Thread Pitre, Russell
I'm sure you have and I don't want to sound patronizing, but are both pc's on the same 
network you specified (allow="xxx.xxx.xxx.*")





-Original Message-
From: Pedro Garcia [mailto:[EMAIL PROTECTED] 
Sent: Monday, December 15, 2003 5:01 PM
To: Tomcat Users List
Subject: Re: Manager Valve


Well, that works fine... but a new question arrives to my mind:
why, when using a valve for a context it works well in one OS and not in 
another?
This is what is happening:
i put a valve tag in one of my contexts (). When trying to access the corresponding web 
application from my computer running Linux Red Hat i get the following
"message
description _Access to the specified resource () has been forbidden."
_
but if i access the same web application from a computer running 
WindowsXP it works well.

Can somebody help me?

Thanks!


Pitre, Russell wrote:

>Ahhvery nice..i was ripping my hair out, I used
>everything but a comma.Thank you..
>
>Filter eh?  Good idea...which is more secure? 
>
>
>Russ
>
>
>
>-Original Message-
>From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
>Sent: Monday, December 15, 2003 4:27 PM
>To: Tomcat Users List
>Subject: RE: Manager Valve
>
>
>Howdy,
>You can use comma-separated address in the allow list of the
>RemoteAddressValve.
>
>Of course you can also write your own Filter and map it to /* in the
>manager app's web.xml.
>
>Yoav Shapira
>Millennium ChemInformatics
>
>
>  
>
>>-Original Message-
>>From: Pitre, Russell [mailto:[EMAIL PROTECTED]
>>Sent: Monday, December 15, 2003 4:26 PM
>>To: Tomcat Users List
>>Subject: Manager Valve
>>
>>How can I restrict access to my manager app to only TWO ip
>>
>>
>addresses
>  
>
>>When I go into the admin app to add a valve for an ip address other
>>
>>
>than
>  
>
>>127.0.0.1 or add multiple ip addresses to a single valvei get the
>>following error:
>>
>>==
>>Validation Errors:
>>
>>-Allow is invalid.  Need to include the admin's IP address.
>>==
>>
>>Any help greatly appreciated.
>>
>>Russ
>>
>>
>>
>>
>>
>>
>>-
>>To unsubscribe, e-mail: [EMAIL PROTECTED]
>>For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>
>
>
>
>This e-mail, including any attachments, is a confidential business
>communication, and may contain information that is confidential,
>proprietary and/or privileged.  This e-mail is intended only for the
>individual(s) to whom it is addressed, and may not be saved, copied,
>printed, disclosed or used by anyone else.  If you are not the(an)
>intended recipient, please immediately delete this e-mail from your
>computer system and notify the sender.  Thank you.
>
>
>-
>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]
>
>
>  
>

-- 
---
| Pedro A García Medina   |
| Groove Media|
| emailto: [EMAIL PROTECTED] |
| Tel: 6211072|
|--



-
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]



RE: Manager Valve

2003-12-15 Thread Pitre, Russell
Ahhvery nice..i was ripping my hair out, I used
everything but a comma.Thank you..

Filter eh?  Good idea...which is more secure? 


Russ



-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
Sent: Monday, December 15, 2003 4:27 PM
To: Tomcat Users List
Subject: RE: Manager Valve


Howdy,
You can use comma-separated address in the allow list of the
RemoteAddressValve.

Of course you can also write your own Filter and map it to /* in the
manager app's web.xml.

Yoav Shapira
Millennium ChemInformatics


>-Original Message-
>From: Pitre, Russell [mailto:[EMAIL PROTECTED]
>Sent: Monday, December 15, 2003 4:26 PM
>To: Tomcat Users List
>Subject: Manager Valve
>
>How can I restrict access to my manager app to only TWO ip
addresses
>
>When I go into the admin app to add a valve for an ip address other
than
>127.0.0.1 or add multiple ip addresses to a single valvei get the
>following error:
>
>==
>Validation Errors:
>
>-Allow is invalid.  Need to include the admin's IP address.
>==
>
>Any help greatly appreciated.
>
>Russ
>
>
>
>
>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential,
proprietary and/or privileged.  This e-mail is intended only for the
individual(s) to whom it is addressed, and may not be saved, copied,
printed, disclosed or used by anyone else.  If you are not the(an)
intended recipient, please immediately delete this e-mail from your
computer system and notify the sender.  Thank you.


-
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]



Manager Valve

2003-12-15 Thread Pitre, Russell
How can I restrict access to my manager app to only TWO ip addresses

When I go into the admin app to add a valve for an ip address other than
127.0.0.1 or add multiple ip addresses to a single valvei get the
following error:

==
Validation Errors:

-Allow is invalid.  Need to include the admin's IP address.
==

Any help greatly appreciated.

Russ






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



RE: Tomcat 4.1.29 Clustering

2003-12-13 Thread Pitre, Russell
Thank you Filip.I will take a look at this and see if I can get it
to work.


Russ

 
-Original Message-
From: Filip Hanik [mailto:[EMAIL PROTECTED] 
Sent: Friday, December 12, 2003 1:48 PM
To: Tomcat Users List
Subject: Re: Tomcat 4.1.29 Clustering

http://cvs.apache.org/~fhanik/


- Original Message - 
From: "Pitre, Russell" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Thursday, December 11, 2003 1:18 PM
Subject: Tomcat 4.1.29 Clustering


Hello All,  

 

I think this may be a question for Filip.I am testing a network load
balancing and tomcat clustering configuration
(InMemorySessionReplication)..Here's my setup:

 

I have two servers both of which have IIS 5 and Tomcat 4.1.29 installed.
I am using Microsoft Network Load Balancing Services to do my front end
load balancing/failover detection in front of the two IIS web
serversI implemented the JK2 connector between IIS and Tomcat on
both of the boxes.  NLB services and the JK2 Connector setup are working
great!  I downloaded tomcat-javagroups.jar and javagroups.jar and put
them in my /server/lib directory.I also have the following in webapp
 element:

 




 

I copied and pasted the above from here:
http://www.theserverside.com/resources/article.jsp?l=Tomcat

 

When I start up Tomcat I see the EXPECTED error that the
InSessionMemoryReplication mbean is not found.   Cool.

 

I can access static content no problem such as an html page but, when I
go to access .jsp page I receive the following error in the localhost
log.

 

2003-12-11 15:55:56 JspFactoryImpl: Exception initializing page context

java.lang.NullPointerException

at
org.apache.catalina.session.InMemoryReplicationManager.createSession(InM
emoryReplicationManager.java:212)

at
org.apache.catalina.session.InMemoryReplicationManager.createSession(InM
emoryReplicationManager.java:242)

at
org.apache.coyote.tomcat4.CoyoteRequest.doGetSession(CoyoteRequest.java:
1882)

 

 

 

I'm not sure what to make of thisI know I need to make all of my
session attributes implement java.io.Serializable..But, I haven't
even put anything into my session yetI'm just accessing a jsp
that is bare bones with just a simple "hello" string..

 

 

Any Ideas?

 

 

 



-
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]



Tomcat 4.1.29 Clustering

2003-12-11 Thread Pitre, Russell
Hello All,  

 

I think this may be a question for Filip.I am testing a network load
balancing and tomcat clustering configuration
(InMemorySessionReplication)..Here's my setup:

 

I have two servers both of which have IIS 5 and Tomcat 4.1.29 installed.
I am using Microsoft Network Load Balancing Services to do my front end
load balancing/failover detection in front of the two IIS web
serversI implemented the JK2 connector between IIS and Tomcat on
both of the boxes.  NLB services and the JK2 Connector setup are working
great!  I downloaded tomcat-javagroups.jar and javagroups.jar and put
them in my /server/lib directory.I also have the following in webapp
 element:

 




 

I copied and pasted the above from here:
http://www.theserverside.com/resources/article.jsp?l=Tomcat

 

When I start up Tomcat I see the EXPECTED error that the
InSessionMemoryReplication mbean is not found.   Cool.

 

I can access static content no problem such as an html page but, when I
go to access .jsp page I receive the following error in the localhost
log.

 

2003-12-11 15:55:56 JspFactoryImpl: Exception initializing page context

java.lang.NullPointerException

at
org.apache.catalina.session.InMemoryReplicationManager.createSession(InM
emoryReplicationManager.java:212)

at
org.apache.catalina.session.InMemoryReplicationManager.createSession(InM
emoryReplicationManager.java:242)

at
org.apache.coyote.tomcat4.CoyoteRequest.doGetSession(CoyoteRequest.java:
1882)

 

 

 

I'm not sure what to make of thisI know I need to make all of my
session attributes implement java.io.Serializable..But, I haven't
even put anything into my session yetI'm just accessing a jsp
that is bare bones with just a simple "hello" string..

 

 

Any Ideas?

 

 

 



RE: jsp page with enctype="MULTIPART/FORM-DATA"

2003-12-11 Thread Pitre, Russell
This should help you out.I tested it and worked like a charm!

http://www.onjava.com/pub/a/onjava/2003/06/25/commons.html?page=3



Russ



-Original Message-
From: FTP Admin [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, December 10, 2003 4:29 PM
To: Tomcat Users List
Subject: jsp page with enctype="MULTIPART/FORM-DATA"

Hi,

Hi there,

when I add the following: enctype="MULTIPART/FORM-DATA"

in a FORM element in a jsp page, then the values of the FORM parameters 
doesn't get propagated to the action servelet The servlet receives 
nulls only!!! If i skip the enctype="MULTIPART/FORM-DATA" in the FORM, 
everything (the parameters do retain their values!) works fine! Any 
explanation???

I need this modification in order to include file upload capabilities 
into my servlet!

Thanks


-
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]



[OFF-TOPIC] Tomcat web hosting

2003-12-08 Thread Pitre, Russell
Hello All-

 

Sorry to bother you with another one of my questions..

 

Can anyone suggest a good and inexpensive web hosting service that
provides tomcat and mySQL support??

 

 

Russ



RE: [POLL] Logging

2003-11-21 Thread Pitre, Russell
Hi Everyone,  thanx for helping me decide to which logging api to usewhich 
is log4j...when i try to use the logger i get this message on the console window...
 
log4j:WARN No appenders could be found for logger (com.pitre.servlet.SetupServlet).
log4j:WARN Please initialize the log4j system properly.
 
I have the log4j jar file in my WEB-INF/lib directory and my logging.properties file 
in the classes directory.   I "configured" the logger  with the properties file as 
such...the logging.properties seems to be loading fine..at least it can find the 
properties filemy webapp is deployed by way of ant and a war file
 
InputStream in = getClass().getClassLoader().getResourceAsStream("logging.properties");
   props.load(in);
   String watch = System.getProperty("LOGGING.WATCH");
   if(watch != null && watch.equalsIgnoreCase("TRUE")){
PropertyConfigurator.configureAndWatch(watch);
System.out.println("Watch logging.properties every 60 seconds for changes");
   }else{
PropertyConfigurator.configure(props);
System.out.println("Not watching logging.properties for changes");
   }
 
And here is my logging.properties file.

log4j.rootLogger=debug, R
log4j.appender.R=org.apache.log4j.ConsoleAppender
log4j.appender.R.layout=org.apache.log4j.SimpleLayout
 
 
I'm baffled
 
Russ
 
 
 
 
-Original Message- 
From: Adam Hardy [mailto:[EMAIL PROTECTED] 
Sent: Fri 11/21/2003 5:23 AM 
To: Tomcat Users List 
Cc: 
Subject: Re: [POLL] Logging



2. Java.util.Logging

Purely because it's part of the sdk and meets my logging requirements. I
did use log4j before, but since I decided I should know
java.util.logging, I stuck with it after learning how to use it.

Adam

-
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]

[POLL] Logging

2003-11-20 Thread Pitre, Russell
I need to use a robbust logging api for my webapp that I'm building, so
I decided I would cast a poll to get census of what everyone prefers


Logging, Which do you prefer?

1. Log4j
2. Java.util.Logging
3. Other



Russ


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



RE: reading properties file....

2003-11-19 Thread Pitre, Russell
Rock on!  I will give that a try.

 
Thanx Gary




-Original Message-
From: Gary Hardy [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, November 19, 2003 1:52 PM
To: Tomcat Users List
Subject: Re: reading properties file

Russ:

In general, if application.properties is in your classes dir

ResourceBundle rez = ResourceBundle.getBundle("application");

Put that in your singleton class. Then you could:

MySingleton.accessMySingleton().getRez().getString("a_prop");

Then go nuts and write a taglib to access MySingleton properties.

gary...

> From: "Pitre, Russell" <[EMAIL PROTECTED]>
> Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]>
> Date: Wed, 19 Nov 2003 13:13:19 -0500
> To: <[EMAIL PROTECTED]>
> Subject: reading properties file
> 
> Hi all,
> 
> Trying to read a properties file for my web appI have a singleton
class
> that reads my properties file and sets my properties the first time
the class
> is called..It reads the file fine, but after the singleton gets
loaded and
> i go to a jsp page that hasnt' been compiled yet i recieve this
error(at
> the bottom).here's how i'm reading the propeties
file...the error
> is really wierd...when tomcat spits out the error, usually there's a
carriage
> return after each exception that is thrown.but thats not the
> case...wierdness...does anyone have any insight to my
situation, I'm
> especially interested in how to read a properties file correctlymy
> properties file is located in the "classes" directory (is this a good
idea?)
> and my webapp gets deployed as a .war file...
> 
> InitProps.java
> ===
>  System.out.println(" Server Initilization
> ##");
> 
> Properties props = new Properties();
>  InputStream in =
>
getClass().getClassLoader().getResourceAsStream("application.properties"
);
> 
>  props.load(in);
>  System.setProperties(props);
>  in.close();
>  System.out.println("# Done
> ##");
> =
> 
> 
> 
> Error:
> =
> java.lang.NullPointerExceptionnull  at
> java.io.Writer.write(Writer.java:126)nullat java.io.PrintWriter
> .newLine(PrintWriter.java:254)null  at
> java.io.PrintWriter.println(PrintWriter.java:405)nullat java.io
> .PrintWriter.println(PrintWriter.java:516)null  at
> org.apache.catalina.logger.LoggerBase.log(LoggerBase.java:2
> 90)null at 
>
org.apache.coyote.tomcat4.CoyoteAdapter.log(CoyoteAdapter.java:655)null
> at org.apache.coyote.t
> omcat4.CoyoteAdapter.service(CoyoteAdapter.java:230)nullat
> org.apache.coyote.http11.Http11Processor.pr
> ocess(Http11Processor.java:601)null at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.pro
> cessConnection(Http11Protocol.java:392)null at
> org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEnd
> point.java:565)null at
>
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool
.java:
> 619)n
> ull at java.lang.Thread.run(Thread.java:534)nullNov 19, 2003
1:03:38 PM
> org.apache.coyote.http11.Http11Pro
> cessor process
>
===
> 
> 
> 
> Thanx
> Russ
> 
> 


-
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]



reading properties file....

2003-11-19 Thread Pitre, Russell
Hi all,
 
Trying to read a properties file for my web appI have a singleton class that reads 
my properties file and sets my properties the first time the class is called..It 
reads the file fine, but after the singleton gets loaded and i go to a jsp page that 
hasnt' been compiled yet i recieve this error(at the bottom).here's how i'm 
reading the propeties file...the error is really wierd...when tomcat spits out 
the error, usually there's a carriage return after each exception that is 
thrown.but thats not the case...wierdness...does anyone have any insight 
to my situation, I'm especially interested in how to read a properties file 
correctlymy properties file is located in the "classes" directory (is this a good 
idea?) and my webapp gets deployed as a .war file...
 
InitProps.java
===
   System.out.println(" Server Initilization 
##");
  
  Properties props = new Properties();
   InputStream in = 
getClass().getClassLoader().getResourceAsStream("application.properties");
  
   props.load(in);
   System.setProperties(props);
   in.close();
   System.out.println("# Done 
##");
=
 
 
 
Error:
=
java.lang.NullPointerExceptionnull  at java.io.Writer.write(Writer.java:126)null   
 at java.io.PrintWriter
.newLine(PrintWriter.java:254)null  at 
java.io.PrintWriter.println(PrintWriter.java:405)nullat java.io
.PrintWriter.println(PrintWriter.java:516)null  at 
org.apache.catalina.logger.LoggerBase.log(LoggerBase.java:2
90)null at org.apache.coyote.tomcat4.CoyoteAdapter.log(CoyoteAdapter.java:655)null 
 at org.apache.coyote.t
omcat4.CoyoteAdapter.service(CoyoteAdapter.java:230)nullat 
org.apache.coyote.http11.Http11Processor.pr
ocess(Http11Processor.java:601)null at 
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.pro
cessConnection(Http11Protocol.java:392)null at 
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEnd
point.java:565)null at 
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)n
ull at java.lang.Thread.run(Thread.java:534)nullNov 19, 2003 1:03:38 PM 
org.apache.coyote.http11.Http11Pro
cessor process
===
 
 
 
Thanx
Russ
 


RE: What is a good dev-enviroment for servlet/tomcat?

2003-10-08 Thread Pitre, Russell
That's a good question, and I'd like to add a question too.

How do you setup a server so that if you had 3 developers...each one has
their own instance of tomcat running at the same time??


Russ

-Original Message-
From: joe udder [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, October 08, 2003 1:58 PM
To: [EMAIL PROTECTED]
Subject: What is a good dev-enviroment for servlet/tomcat?

Hello.

I am thinking of how I can improve my "development enviroment" when
doing my 
webapps.
Until now, I've used a handcrafted "build.xml" to make my webapp, and
then 
the usual

_
Tired of spam? Get advanced junk mail protection with MSN 8. 
http://join.msn.com/?page=features/junkmail


-
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]



RE: Tomcat and Active Directory / 2003

2003-10-08 Thread Pitre, Russell
This is my realm setup in my server.xml config

ldap://[domain controller]:389"
userBase="OU=Users,OU=Shawmut,DC=[domain],DC=com"
userSearch="(sAMAccountName={0})"
userRoleName="member"
roleBase="OU=Users,OU=Shawmut,DC=[domain],DC=com"
roleName="memberOf"
roleSearch="(memberOf=CN=tomcat,CN=Users,DC=shawmut,DC=com)"
connectionName="CN=Administrator,CN=Users,DC=shawmut,DC=com"
connectionPassword="[password]"
roleSubtree="true"
userSubtree="true"/>

hope this helps


Russ





-Original Message-
From: Matt Fury [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, October 08, 2003 1:03 PM
To: Tomcat Users List
Subject: Re: Tomcat and Active Directory / 2003

Hey Thanks for the reply.

Tried all those to no avail. :-/ I did see the Tomcat
realm how-to but I was wondering if there were issues
because it is Micro$oft we're trying to connect to and
its 2003. Who knows, their "standard" ldap may not be
standard.

-Matt


--- Yann Cébron <[EMAIL PROTECTED]> wrote:
> Two guesses:
> 
> * Did you try using the IP-address instead or use
> the FQDN for
> connectionURL, maybe there's something wrong w/ DNS?
> 
> * Try w/o MD5 and see if it works then.
> 
> >   roleSubtree="True"
> 
> typo - or shouldn't this be "true"
> 
> I guess you already found the documentation here:
>
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/realm-howto.html#JNDIRealm
> 
> HTH,
> Yann
> 
> > BTW: I am using 4.1.27 on Windows 2000 and we're
> > trying to connect to a Windows 2003 AD. Has this
> > changed at all?
> >
> > here is the error trace:
> >
> > Catalina.start: LifecycleException:  Exception
> opening
> > directory server connecti
> > on:  javax.naming.CommunicationException:
> > localhost:389 [Root exception is java.
> > net.ConnectException: Connection refused: connect]
> > LifecycleException:  Exception opening directory
> > server connection:  javax.namin
> > g.CommunicationException: localhost:389 [Root
> > exception is java.net.ConnectExcep
> > tion: Connection refused: connect]
> >
> > It keeps saying localhost:389 and I clearly don't
> have
> > it in the Realm. Here is my setup.
> >
> >  className="org.apache.catalina.realm.JNDIRealm"
> >   debug="99"
> >   connectionName="cn=TomcatRole,dc=vo,dc=net"
> >   connectionPassword="***"
> >   connectionURL="ldap://orlmsdc001:389";
> >   digest="MD5"
> >   roleBase="dc=roles,dc=vo,dc=net"
> >   roleName="cn"
> >   roleSearch="(uniqueMember={0})"
> >   roleSubtree="True"
> >   userPassword="***"
> >   userPattern="cn={0},dc=vacationsonly,dc=net"  />
> >
> >
> >
> > --- Matt Fury <[EMAIL PROTECTED]> wrote:
> > > Hi All,
> > >
> > > I've been trying for several weeks to compile
> > > information on Tomcat and Active Directory
> through
> > > LDAP. I can't quite get all the information I
> need
> > > and
> > > I am hoping someone has a link to what needs to
> be
> > > done. I want to use the Realms in Tomcat but I
> can't
> > > seem to connect properly. For some reason it
> seems
> > > to
> > > keep trying to connect to localhost even though
> its
> > > not specified.
> > >
> > > Also, does SSL NEED to be implemented in order
> to
> > > get
> > > this to work? I will be doing AD connectivity
> > > through
> > > LAN only.
> > >
> > > Thanks.
> > >
> > > -Matt
> > >
> > >
> >
>
-
> > > 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]


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



RE: [OFF TOPIC] Version Control

2003-09-24 Thread Pitre, Russell
The Client as well as a cvs server.




-Original Message-
From: Phillip Qin [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, September 24, 2003 11:48 AM
To: 'Tomcat Users List'
Subject: RE: [OFF TOPIC] Version Control

I think what he really needs is a CVS client. Eclipse and NetBeans both
integrate the CVS client.

-Original Message-
From: Robert Priest [mailto:[EMAIL PROTECTED] 
Sent: September 24, 2003 11:16 AM
To: 'Tomcat Users List'
Subject: RE: [OFF TOPIC] Version Control

I would try WinCvs for a beginner.

Yes tortoise intergrates with explorer, but I find that WinCvs is more
flexible.

-Original Message-
From: Ralph Einfeldt [mailto:[EMAIL PROTECTED]
Sent: Wednesday, September 24, 2003 11:14 AM
To: Tomcat Users List
Subject: RE: [OFF TOPIC] Version Control


CVS has a gui interface. (Even more than one)

http://www.wincvs.org/
http://www-csr.bessy.de/control/Soft/tkCVS/
http://www.tortoisecvs.org/

For a more complete overview see:
http://www.cvshome.org/dev/addons.html


> -Original Message-
> From: Pitre, Russell [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, September 24, 2003 5:02 PM
> To: [EMAIL PROTECTED]
> Subject: [OFF TOPIC] Version Control
> 
> 
> Sorry for the Off topic question
> 
> I'm looking for suggestions for a free version control system.  I've
> tried cvs before.but, the learning curve is really steep for
> me...i'd rather go with something that has a gui interface. 
> 
> 
> Thanx in advance
> 
> -
> 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]

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



[OFF TOPIC] Version Control

2003-09-24 Thread Pitre, Russell
Sorry for the Off topic question

I'm looking for suggestions for a free version control system.  I've
tried cvs before.but, the learning curve is really steep for
me...i'd rather go with something that has a gui interface. 


Thanx in advance

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



RE: Tomcat and Initial Naming

2003-09-17 Thread Pitre, Russell
Thanx Yoav,  

Great!  The latter is exactly what I want to do.So when I want to
use the properties after they have been bound, I would do something
like:

InitialContext ctx = new InitialContext();

Object obj = (Object)ctx.lookup("java:/comp/env/myJndiRef");


Or something to that affect..

Is there a best practice for this?  I would like to see all of my app
config stuff in one XML file..so when I deploy the app between
(dev --> staging --> production) it goes smoothly without having to
rewrite any classes. 

Russ



-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, September 17, 2003 8:51 AM
To: Tomcat Users List
Subject: RE: Tomcat and Initial Naming


Howdy,
The java:/comp/env context is special in that it's defined by the
servlet specification is the location for "environment" properties
defined in the server.  So whatever you define in server.xml/web.xml
will go in that context.

A servlet container is not required by the spec to give you runtime
write permission to that context.  In practice, however, nearly all do.

You have two options roughly, one's easier but doesn't allow XML, and
the other is the opposite:

1. Instead of an XML file for your webapp, name the file jndi.properties
and place it in WEB-INF/classes.  It will be automatically available in
your environment context.

2. If you want to use an XML file, you need to parse it yourself and use
Context#bind(...) or Context#addToEnvironment(...) to populate the
naming context with your properties.

Yoav Shapira
Millennium ChemInformatics


>-Original Message-
>From: Pitre, Russell [mailto:[EMAIL PROTECTED]
>Sent: Tuesday, September 16, 2003 6:15 PM
>To: Tomcat Users List
>Subject: Tomcat and Initial Naming
>
>I'm trying to understand naming contexts and their implementations in
>tomcat.looking at the code below, we lookup the jndi resource
>"jdbc/test"  When tomcat starts up, it parses the server.xml
file.It
>finds:
>
>
>   type="javax.sql.DataSource"/>
>   
>   
>   factory
>   org.apache.commons.
>
>dbcp.BasicDataSourceFactory
>   
>   .
>   .
>   .
>Tomcat looks at this and adds a name value pair to a naming
>context.My question is about this naming context tomcat
has..How
>can I add a name value pair to this same context?.and how can I
make
>a reference to that value?   Would I access it the sameway in the code
>below?  (("java:/comp/env/"myRefernceName") or ("java:/") ) I want to
>add other values to this same contextMy basic idea is to have an
xml
>file with all of the properties for my webappand I want to lookup
>these properties using jndi.my reason for this is I want to be able
>to lookup certain application specific properties (i.e. ldap stuff,
jdbc
>stuff, constants, and such.and I know about adding jdbc, and ldap
>res-ref in the server.xml) much like a myApp.properties file..Any
>ideas?  Does this question make sense..
>
>
>
>
>try {
>   Context ctx = new InitialContext();
>
>   if (ctx == null)
>   throw new Exception("Boom - No Context");
>
>   DataSource ds =
>(DataSource)ctx.lookup("java:comp/env/jdbc/test");
>
>   out.println ("DATASOURCE: " + ds);
>
>   conn = ds.getConnection();
>
>   .
>   .
>   .
>   }catch{..
>
>
>Thanx in advance
>Russ
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential,
proprietary and/or privileged.  This e-mail is intended only for the
individual(s) to whom it is addressed, and may not be saved, copied,
printed, disclosed or used by anyone else.  If you are not the(an)
intended recipient, please immediately delete this e-mail from your
computer system and notify the sender.  Thank you.


-
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]



RE: tomcat==root

2003-09-17 Thread Pitre, Russell
Sorry, just a test to see if my emails are getting through!

-Original Message-
From: P.van Kemenade [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, September 17, 2003 7:09 AM
To: Tomcat Users List
Subject: tomcat==root

Hi

I found out that we run our tomcat as user root, and in
plain jsp I'm able to trash /etc/passwd :-)

what is the advised setup for a tomcat server that
is shared by several users (contexts) and runs
some virtual domains ?

thanks,
*pike

==
Aoccdrnig to rscheearch at Cmabrigde Uinervtisy,
it deosn't mttaer in waht oredr the ltteers in a wrod are, the olny
iprmoetnt tihng is taht the frist and lsat ltteer be at the rghit pclae.
The rset can be a total mses and you can sitll
raed it wouthit porbelm. Tihs is bcuseae the huamn mnid deos not
raed ervey lteter by istlef, but the wrod as a wlohe.


-
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]



Context and naming

2003-09-17 Thread Pitre, Russell
I'm trying to understand naming contexts and their implementations in
tomcat.looking at the code below, we lookup the jndi resource
"jdbc/test"  When tomcat starts up, it parses the server.xml file.It
finds:





factory
org.apache.commons. 

dbcp.BasicDataSourceFactory

.
.
.
Tomcat looks at this and adds a name value pair to a naming
context.My question is about this naming context that tomcat
has..How can I add a name value pair to this same context?.and
then how can I make a reference to that value?   Would I access it in
the same way the code below does?  (("java:/comp/env/"myRefernceName")
or ("java:/myReferenceName") ) I want to add other values to this very
same contextMy basic idea is to have an xml file with all of the
properties for my webapp.. My webapp will read this config.xml file when
tomcat starts the application..this part will be another question
:)..and I want to lookup these properties using jndi.my reason
for this is I want to be able to lookup certain application specific
properties (i.e. ldap stuff, jdbc stuff, constants, and such.and I
know about adding jdbc, and ldap res-ref in the server.xml) much like a
myApp.properties file..Any ideas?  Does this question make
sense..


 

try {
Context ctx = new InitialContext();

if (ctx == null)
throw new Exception("Boom - No Context");

DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/test");

out.println ("DATASOURCE: " + ds);

conn = ds.getConnection();

.
.
.
}catch{..   


Thanx in advance
Russ



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



Tomcat and Naming

2003-09-17 Thread Pitre, Russell
I'm trying to understand naming contexts and their implementations in
tomcat.looking at the code below, we lookup the jndi resource
"jdbc/test"  When tomcat starts up, it parses the server.xml file.It
finds:





factory
org.apache.commons. 

dbcp.BasicDataSourceFactory

.
.
.
Tomcat looks at this and adds a name value pair to a naming
context.My question is about this naming context that tomcat
has..How can I add a name value pair to this same context?.and
then how can I make a reference to that value?   Would I access it in
the same way the code below does?  (("java:/comp/env/"myRefernceName")
or ("java:/myReferenceName") ) I want to add other values to this very
same contextMy basic idea is to have an xml file with all of the
properties for my webapp.. My webapp will read this config.xml file when
tomcat starts the application..this part will be another question
:)..and I want to lookup these properties using jndi.my reason
for this is I want to be able to lookup certain application specific
properties (i.e. ldap stuff, jdbc stuff, constants, and such.and I
know about adding jdbc, and ldap res-ref in the server.xml) much like a
myApp.properties file..Any ideas?  Does this question make
sense..


 

try {
Context ctx = new InitialContext();

if (ctx == null)
throw new Exception("Boom - No Context");

DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/test");

out.println ("DATASOURCE: " + ds);

conn = ds.getConnection();

.
.
.
}catch{..   


Thanx in advance
Russ

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



Tomcat and Naming Context

2003-09-16 Thread Pitre, Russell
I'm trying to understand naming contexts and their implementations in
tomcat.looking at the code below, we lookup the jndi resource
"jdbc/test"  When tomcat starts up, it parses the server.xml file.It
finds:





factory
org.apache.commons. 

dbcp.BasicDataSourceFactory

.
.
.
Tomcat looks at this and adds a name value pair to a naming
context.My question is about this naming context that tomcat
has..How can I add a name value pair to this same context?.and
then how can I make a reference to that value?   Would I access it in
the same way the code below does?  (("java:/comp/env/"myRefernceName")
or ("java:/myReferenceName") ) I want to add other values to this very
same contextMy basic idea is to have an xml file with all of the
properties for my webapp.. My webapp will read this config.xml file when
tomcat starts the application..this part will be another question
:)..and I want to lookup these properties using jndi.my reason
for this is I want to be able to lookup certain application specific
properties (i.e. ldap stuff, jdbc stuff, constants, and such.and I
know about adding jdbc, and ldap res-ref in the server.xml) much like a
myApp.properties file..Any ideas?  Does this question make
sense..


 

try {
Context ctx = new InitialContext();

if (ctx == null)
throw new Exception("Boom - No Context");

DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/test");

out.println ("DATASOURCE: " + ds);

conn = ds.getConnection();

.
.
.
}catch{..   


Thanx in advance
Russ

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



Tomcat and Initial Naming

2003-09-16 Thread Pitre, Russell


I'm trying to understand naming contexts and their implementations in
tomcat.looking at the code below, we lookup the jndi resource
"jdbc/test"  When tomcat starts up, it parses the server.xml file.It
finds:





factory
org.apache.commons. 

dbcp.BasicDataSourceFactory

.
.
.
Tomcat looks at this and adds a name value pair to a naming
context.My question is about this naming context tomcat has..How
can I add a name value pair to this same context?.and how can I make
a reference to that value?   Would I access it the sameway in the code
below?  (("java:/comp/env/"myRefernceName") or ("java:/") ) I want to
add other values to this same contextMy basic idea is to have an xml
file with all of the properties for my webapp.. My webapp will read this
config.xml file when tomcat starts the application..this part will
be another question :)..and I want to lookup these properties using
jndi.my reason for this is I want to be able to lookup certain
application specific properties (i.e. ldap stuff, jdbc stuff, constants,
and such.and I know about adding jdbc, and ldap res-ref in the
server.xml) much like a myApp.properties file..Any ideas?  Does this
question make sense..


 

try {
Context ctx = new InitialContext();

if (ctx == null)
throw new Exception("Boom - No Context");

DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/test");

out.println ("DATASOURCE: " + ds);

conn = ds.getConnection();

.
.
.
}catch{..   


Thanx in advance
Russ

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



Tomcat and Initial Naming

2003-09-16 Thread Pitre, Russell
I'm trying to understand naming contexts and their implementations in
tomcat.looking at the code below, we lookup the jndi resource
"jdbc/test"  When tomcat starts up, it parses the server.xml file.It
finds:





factory
org.apache.commons. 

dbcp.BasicDataSourceFactory

.
.
.
Tomcat looks at this and adds a name value pair to a naming
context.My question is about this naming context tomcat has..How
can I add a name value pair to this same context?.and how can I make
a reference to that value?   Would I access it the sameway in the code
below?  (("java:/comp/env/"myRefernceName") or ("java:/") ) I want to
add other values to this same contextMy basic idea is to have an xml
file with all of the properties for my webappand I want to lookup
these properties using jndi.my reason for this is I want to be able
to lookup certain application specific properties (i.e. ldap stuff, jdbc
stuff, constants, and such.and I know about adding jdbc, and ldap
res-ref in the server.xml) much like a myApp.properties file..Any
ideas?  Does this question make sense..


 

try {
Context ctx = new InitialContext();

if (ctx == null)
throw new Exception("Boom - No Context");

DataSource ds =
(DataSource)ctx.lookup("java:comp/env/jdbc/test");

out.println ("DATASOURCE: " + ds);

conn = ds.getConnection();

.
.
.
}catch{..   


Thanx in advance
Russ

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



Custom Resource Factory

2003-09-10 Thread Pitre, Russell
Does anyone know where I can find additional information on building a
custom resource factory other than this?

 

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-resources-howto.htm
l

 

I'm looking to build a resource factory that will give me a reference to
another class that will make LDAP queries.

 

 

 

Any help would be appreciated

 

Russ

 

 

 



RE: Active Directory Single Sign-On

2003-09-10 Thread Pitre, Russell
It sounds like we should come up with a de facto way of achieving SSO with Tomcat and 
NTLM (since there is plenty of M$ workstations out there).Which leads me to 
believe that a lot of people could very well benefit from this.. I'm required to 
implement this for our intranet application which I have found to be the most common 
need for such an implementation..

I will investigate further into these methods and report back with any comments, 
suggestions, and if I need any further help (which will probably be the 
case).After which, I will try to get some documentation..

Any thoughts, suggestions, comments?


Cheers
Russ



-Original Message-
From: Allen Hadden [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, September 10, 2003 6:36 AM
To: Tomcat Users List
Subject: RE: Active Directory Single Sign-On

> -Original Message-
> From: Endre Stølsvik [mailto:[EMAIL PROTECTED] 
> Sent: Wednesday, September 10, 2003 3:45 AM
> To: Tomcat Users List
> Subject: Re: Active Directory Single Sign-On
> 
> 
> | Tim mentioned the use of the JCIFS library.  I don't think 
> that'd work 
> | either since it'd need to run on the same machine as the browser, 
> | which doesn't seem right.  Or perhaps I'm missing 
> something.  Now if 
> | Tomcat supported Windows SSO using JCIFS, then that's a different 
> | story.  I don't think it does though (and I'm sure someone will 
> | correct me if I'm wrong :)).
> 
> You're missing something. I'm correcting you! It works. We've 
> done it with our portal engine..!
> 

OK, right.  Thanks for the correction.  Very good work, those JCIFS guys.  Sorry for 
the misinformation (and for doubting Tim).

To summarize, there are three ways to do the SSO:

   1. Use IIS to front Tomcat using the ISAPI redirector
   2. Use the JCIFS filter to do the authentication
   3. Use low-level JCIFS calls to implement the authentication yourself

#2 seems like the preferred approach, unless there is a reason you can't tie yourself 
to the   2.3 servlet spec.  It looks like someone recently added an NtlmServlet class 
to JCIFS, which would provide a fourth method to achieve SSO (and wouldn't require a 
2.3 servlet container).

In all cases, there is no "password" being passed from the browser to the web server.  
Also, you'll have to figure out the best way to do authorization.  You could 
definitely use JNDI to query the ActiveDirectory for authorization information.  But 
does JCIFS provide anything that might help authorization?  For example, does it pass 
a list of groups the user is in as a request attribute?  That'd be nice (a quick look 
at the docs didn't reveal anything).

Allen

-
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]



RE: Active Directory Single Sign-On

2003-09-09 Thread Pitre, Russell
Okay, Checked it out, can I use this API to grab the username and
password with a .jsp or servlet off the NT machine.and then pass it
to Tomcat so it then can look up users in Active Directory?  

I want security to be container managed.So I need to 

1.)  Grab the username and password 
2.)  Post it to the login form (action="j_security_check")
3.)  Tomcat will connect to Active Directory  (JNDI)
4.)  Tomcat will redirect to the original page called...


Does this make sense to everyone?  




-Original Message-
From: Tim Funk [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, September 09, 2003 4:17 PM
To: Tomcat Users List
Subject: Re: Active Directory Single Sign-On

I think you are looking for NTLM authentication which was done by the
samba 
folks. See http://jcifs.samba.org/

-Tim

Pitre, Russell wrote:

> Hey All-
> 
>  
> 
> Finally Finally, Finally, I figured out how to authenticate to Active
> Directory...(code below minus the login form).now to go
further,
> I would like to implement Single Sign-On.somehow we would need to
> retrieve the user's name and password off their NT machine and use
them
> to automatically post the form..does anyone have any suggestions?
> 
>  
> 
> Also, I was able to see in the log that it enumerates the groups of
the
> user,  but It didn't find the "Domain Users"
> group.h.anyone know why?  I see the security group in
AD
> Comp & Users.. 
> 
>  
> 
> 
> 
>  
> 
> 
> 
> 
> 
> ..stuff
> 
> ..stuff
> 
> .stuff 
> 
>  
> 
>  
> debug="99"
> 
> connectionURL="ldap://[Domain Controller]:389"
> 
>  
> userBase="OU=Users,OU=Shawmut,DC=[Domain],DC=com"
> 
> userSearch="(sAMAccountName={0})"
> 
> userRoleName="member"
> 
>  
> roleBase="OU=Users,OU=Shawmut,DC=[Domain],DC=com"
> 
> roleName="memberOf"
> 
>  
> roleSearch="(memberOf=CN=tomcat,CN=Users,DC=[Domain],DC=com)"
> 
>  
> connectionName="CN=Administrator,CN=Users,DC=[Domain],DC=com"
> 
> connectionPassword="[password]"
> 
> roleSubtree="true"
> 
> userSubtree="true"/>
> 
> 
> 
>  
> 
>  
> 
> 
> 
>  
> 
> 
> 
> Show Tracker
Security
> Constraint
> 
> 
> 
>  
> Protected Area
> 
>  
> /*
> 
> 
> 
> 
> 
>  
> CN=Alloffice,OU=SDC,OU=Email Distribution
> Lists,OU=Groups,OU=Shawmut,DC=[Domain],DC=com
> 
> 
> 
> 
> 
>  
> 
> 
> 
> FORM
> 
> Show Tracker
> Authentication Area
> 
> 
> 
>  
> /login.jsp
> 
>  
> /error.jsp
> 
> 
> 
> 
> 
>  
> 
>  
> 
>  
> 
> 


-
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]



Active Directory Single Sign-On

2003-09-09 Thread Pitre, Russell
Hey All-

 

Finally Finally, Finally, I figured out how to authenticate to Active
Directory...(code below minus the login form).now to go further,
I would like to implement Single Sign-On.somehow we would need to
retrieve the user's name and password off their NT machine and use them
to automatically post the form..does anyone have any suggestions?

 

Also, I was able to see in the log that it enumerates the groups of the
user,  but It didn't find the "Domain Users"
group.h.anyone know why?  I see the security group in AD
Comp & Users.. 

 



 





..stuff

..stuff

.stuff 

 

ldap://[Domain Controller]:389"

 
userBase="OU=Users,OU=Shawmut,DC=[Domain],DC=com"

userSearch="(sAMAccountName={0})"

userRoleName="member"

 
roleBase="OU=Users,OU=Shawmut,DC=[Domain],DC=com"

roleName="memberOf"

 
roleSearch="(memberOf=CN=tomcat,CN=Users,DC=[Domain],DC=com)"

 
connectionName="CN=Administrator,CN=Users,DC=[Domain],DC=com"

connectionPassword="[password]"

roleSubtree="true"

userSubtree="true"/>



 

 



 



Show Tracker Security
Constraint



 
Protected Area

 
/*





 
CN=Alloffice,OU=SDC,OU=Email Distribution
Lists,OU=Groups,OU=Shawmut,DC=[Domain],DC=com





 



FORM

Show Tracker
Authentication Area



 
/login.jsp

 
/error.jsp





 

 

 



RE: Newbie:web application

2003-09-04 Thread Pitre, Russell
ROFL 




-Original Message-
From: John Turner [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 29, 2003 11:57 AM
To: Tomcat Users List
Subject: Re: Newbie:web application



ROFL

Shapira, Yoav wrote:

> Howdy,
> Thank you for the clear instructions ;)  I believe I have a fairly 
> firm grasp on webapp structure as well as the rest of tomcat ;)  But 
> I'm sure the original poster whose question I answered will find your 
> response beneficial.
> 
> Yoav Shapira
> Millennium ChemInformatics
> 
> 
> 
>>-Original Message-
>>From: Schalk [mailto:[EMAIL PROTECTED]
>>Sent: Friday, August 29, 2003 11:30 AM
>>To: 'Tomcat Users List'
>>Subject: RE: Newbie:web application
>>
>>
>>
>>Yoav
>>
>>Ok, first your webapp folder structure:
>>Tomcat/webapps/myApp
>>Tomcat/webapps/myApp/WEB-INF/ Tomcat/webapps/myApp/WEB-INF/classes/  #

>>ALL class files go here Tomcat/webapps/myApp/WEB-INF/lib/  # All .jar 
>>files goes here Tomcat/webapps/myApp/WEB-INF/web.xml  # This is your 
>>deployment
> 
> descriptor
> 



-
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]



RE: Tomcat and multiple processors

2003-09-04 Thread Pitre, Russell
Hey people..


Where can i find more information on the web about this subject,
specifically setting up multiple jvm's tied to it's respective tomcat
installation?  Doesn't have to include multiple processors

I'm very interested in this subject, basically, just curious as to how
it all works  :)


Thanx in advance!
Russ




-Original Message-
From: John Turner [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 04, 2003 4:16 PM
To: Tomcat Users List
Subject: Re: Tomcat and multiple processors


Matt Raible wrote:

> 1.  Does it support multiple processors?  We have a Tomcat instance in

> production on a NT box with 4 processors, but Tomcat only seems to use

> one. Does the 1.4.2 JVM support MP?

Yes, at least on Sun hardware with Solaris 8, and Intel hardware with RH
Linux 7.x (duals only...we don't have quads).  Don't know about Windows.

> 2.  We have IIS on the front end, and we are currently not able to 
> migrate to Apache.  We'd like to use the connectors (jk or jk2) to do 
> load-balancing and failover.  Do these connectors provide the support 
> we need?  Should be use a clustering architecture like JavaSpaces
> (http://www.onjava.com/lpt/a/2422) instead?

The connectors can load balance, but unfortunately the IIS versions are
sort of a crapshoot in my mind.

> 3.  We plan on deploying 42+ applications to a number of Tomcat 
> servers. Since each application will support 1 customer - I think it's

> a good idea to have 1 app -> 1 tomcat - so if Tomcat crashes, it only 
> affects that customer
> - rather than all customers.  I've heard of setting up a CATALINA_BASE
to
> share Tomcat's core files, and then setup webapps directories for each
> customer.  Does this sound reasonable?  Have have others done
something like
> this?

I agree with Yoav. All the way back with Tomcat 3.1 we had ours setup
this way:

1 virtual host = 1 Tomcat instance = 1 VM = 1 application

We've had a couple dozen set up like this for a long time, works like a
charm.  I prefer this over using CATALINA_BASE, as I can treat each
virtual host separately from any other, including giving each different
JVM memory settings, etc.  Admittedly, we're an ASP, so we can dictate
how many web apps go with each virtual host, but I would think having
completely separate Tomcat instances would make sense in most real
production environments.  The only thing you "lose" with multiple Tomcat
instances is disk space, and disk is cheap.

John






-
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]



RE: War Development w/ JNDI Datasources

2003-08-18 Thread Pitre, Russell
Ah cool.didn't realize that.nicethats good to know.



Thanx Guys




-Original Message-
From: John Turner [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 18, 2003 12:50 PM
To: Tomcat Users List
Subject: Re: War Development w/ JNDI Datasources



http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/context.html

Anything in  can go in a file outside server.xml, in 
the Host's appBase.  Tomcat will pick it up automatically.

You name the file app.xml, so if your webapp is myApp, you would put a 
file called myApp.xml in the Host's appBase, and the contents of that 
file would be the Context element.

The admin and manager Contexts/apps use this method, so every Tomcat 
install has an example.

John

Pitre, Russell wrote:
> Which file is this?  I'd like to read up on it
> 
> "put application specifics in context configuration files."
> 
> 
> 
> Russ
> 
> 
> 
> -Original Message-
> From: Jacob Kjome [mailto:[EMAIL PROTECTED]
> Sent: Monday, August 18, 2003 10:40 AM
> To: Tomcat Users List
> Subject: Re: War Development w/ JNDI Datasources
> 
> 
> 
> You can always specify it in a separate context configuration file. 
> Keep the server.xml generic and put application specifics in context
> configuration files.
> 
> Jake
> 
> At 08:47 AM 8/18/2003 -0500, you wrote:
> 
>>Hi All,
>>
>>We are currently developing an application and using CVS to manage our
>>source code.  Our goal is to be able to pull down the project off of 
>>CVS and with a single Ant target, get the application up and running
on
> 
> 
>>a local install of Tomcat.
>>
>>The problem that has risen is that our DataSources are specified in
>>JNDI (the server.xml in the {CATALINA_HOME}/conf) and is not something

>>that we can feasibly park in CVS.
>>
>>Is there a way to get the DataSources specified without modifying the
>>server.xml? Or, should we be making an ANT target that loads a second 
>>instance of tomcat using a project specific server.xml, much like what

>>Cactus describes?
>>
>>Many Thanks,
>>Jacob
>>
>>-
>>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]
> 



-
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]



RE: War Development w/ JNDI Datasources

2003-08-18 Thread Pitre, Russell
Which file is this?  I'd like to read up on it

"put application specifics in context configuration files."



Russ



-Original Message-
From: Jacob Kjome [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 18, 2003 10:40 AM
To: Tomcat Users List
Subject: Re: War Development w/ JNDI Datasources



You can always specify it in a separate context configuration file.
Keep 
the server.xml generic and put application specifics in context 
configuration files.

Jake

At 08:47 AM 8/18/2003 -0500, you wrote:
>Hi All,
>
>We are currently developing an application and using CVS to manage our 
>source code.  Our goal is to be able to pull down the project off of 
>CVS and with a single Ant target, get the application up and running on

>a local install of Tomcat.
>
>The problem that has risen is that our DataSources are specified in 
>JNDI (the server.xml in the {CATALINA_HOME}/conf) and is not something 
>that we can feasibly park in CVS.
>
>Is there a way to get the DataSources specified without modifying the 
>server.xml? Or, should we be making an ANT target that loads a second 
>instance of tomcat using a project specific server.xml, much like what 
>Cactus describes?
>
>Many Thanks,
>Jacob
>
>-
>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]



OFF TOPIC: Book suggestion.

2003-08-14 Thread Pitre, Russell
Sorry for the off topic question, but I feel this list could benefit
from the responses to this question (if they get answered)..

 

 

Does anyone know of any good books on design patterns concerning MVC and
Java and the like.Here's one by the gang of four but it was
published in 1995...I would like to find one that is more
current..anyone have any suggestions?

 

http://www.amazon.com/exec/obidos/ASIN/0201633612/qid=1060790696/sr=2-1/
ref=sr_2_1/103-2315139-4279867

 

 

 

Thanx-

Russ



RE: Off Topic: List Server for Tomcat

2003-07-29 Thread Pitre, Russell
I guess its not a requirement.I'll take a look into it


thanx




-Original Message-
From: Eric J. Pinnell [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 29, 2003 10:35 AM
To: Tomcat Users List
Subject: RE: Off Topic: List Server for Tomcat


Hi,

Is java a requirement?  You could save yourself a lot of time and
troubles not reinventing the wheel.  Majordomo has been around
forever...

-e

On Tue, 29 Jul 2003, Pitre, Russell wrote:

> I think this is what i'm looking forexcept, its written in 
> PerlI would like an implementation in Java instead.
>
> Thanx
>
> Russ
>
>
>
> -Original Message-
> From: Rick Roberts [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, July 29, 2003 10:34 AM
> To: Tomcat Users List
> Subject: Re: Off Topic: List Server for Tomcat
>
>
> Majordomo?
>
> http://www.greatcircle.com/majordomo/
>
>
> Pitre, Russell wrote:
> > Hello All,
> >
> > This may be off topic.  I need a quick fix for an office politics 
> > problem which involves a list server.  Does anyone know of a free 
> > list
>
> > server for Tomcat?  Time is an issue here, so writing one is not 
> > really an option..Thanx in advance..
> >
> >
> > Thanx
> >
> > 
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> --
> ***
> * Rick Roberts*
> * Advanced Information Technologies, Inc. *
> ***
>
>
> -
> 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]


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



RE: Off Topic: List Server for Tomcat

2003-07-29 Thread Pitre, Russell
What does this tomcat list  use for a list server?





-Original Message-
From: Rick Roberts [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 29, 2003 10:34 AM
To: Tomcat Users List
Subject: Re: Off Topic: List Server for Tomcat


Majordomo?

http://www.greatcircle.com/majordomo/


Pitre, Russell wrote:
> Hello All,
> 
> This may be off topic.  I need a quick fix for an office politics 
> problem which involves a list server.  Does anyone know of a free list

> server for Tomcat?  Time is an issue here, so writing one is not 
> really an option..Thanx in advance..
> 
> 
> Thanx
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-- 
***
* Rick Roberts*
* Advanced Information Technologies, Inc. *
***


-
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]



RE: Off Topic: List Server for Tomcat

2003-07-29 Thread Pitre, Russell
I think this is what i'm looking forexcept, its written in PerlI
would like an implementation in Java instead.

Thanx

Russ



-Original Message-
From: Rick Roberts [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 29, 2003 10:34 AM
To: Tomcat Users List
Subject: Re: Off Topic: List Server for Tomcat


Majordomo?

http://www.greatcircle.com/majordomo/


Pitre, Russell wrote:
> Hello All,
> 
> This may be off topic.  I need a quick fix for an office politics 
> problem which involves a list server.  Does anyone know of a free list

> server for Tomcat?  Time is an issue here, so writing one is not 
> really an option..Thanx in advance..
> 
> 
> Thanx
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-- 
***
* Rick Roberts*
* Advanced Information Technologies, Inc. *
***


-
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]



Off Topic: List Server for Tomcat

2003-07-29 Thread Pitre, Russell
Hello All,

This may be off topic.  I need a quick fix for an office politics
problem which involves a list server.  Does anyone know of a free list
server for Tomcat?  Time is an issue here, so writing one is not really
an option..Thanx in advance..


Thanx

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



RE: Running Tomcat as Windows Service

2003-07-09 Thread Pitre, Russell
I used this to create my nt service.

"%CATALINA_HOME%\bin\tomcat.exe" -install Tomcat
%JAVA_HOME%\jre\bin\server\jvm.dll"
-Djava.class.path="%CATALINA_HOME%\bin\bootstrap.jar;%JAVA_HOME%\lib\too
ls.jar" -Dcatalina.home="%CATALINA_HOME%" -start
org.apache.catalina.startup.BootstrapService -params start -stop
org.apache.catalina.startup.BootstrapService -params stop -out
"%CATALINA_HOME%"\logs\stdout.log -err "%CATALINA_HOME%"\logs\stderr.log


Russ

-Original Message-
From: Hamidene, Anis Ben [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, July 09, 2003 10:32 AM
To: [EMAIL PROTECTED]
Subject: Running Tomcat as Windows Service


Hi,

I want to install Tomcat 4.1.2 as windows service. My servlets should
connect to another server over SSl-Connection. I did install tomcat as a
service, but when my client connects to the servlet, tomcat hangs
down,and I have to restart the service manually. If I start Tomcat using
the batch file , everything works fine. Is it better to use JavaService?
The problem happens especially when running the whole thing in a Citrix
environment. 

 

Please help a.s.a.p. Yours anis


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



RE: Tomcat 5.0.3 on W2K Pro - need to use system classpath

2003-07-09 Thread Pitre, Russell
Does anyone know when the T5 will come out with a final release?





-Original Message-
From: Norris Shelton [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, July 09, 2003 8:29 AM
To: Tomcat Users List
Subject: Tomcat 5.0.3 on W2K Pro - need to use system classpath


I currently run TC 4.1.12.  There are several files defined on a network
share that we have to use.  With 4.1.12, I edit the setclasspath file to
append to the classpath instead of replacing.  I also have to add
servlet.jar to the classpath because looks like it does not get there
automatically.  I start via bin/catalina.bat with "start" as a
parameter.

I tried this w/5.0.3 with no luck.  It looks like I could do what I am
used to doing and include common/lib/servlet-api.jar and
common/lib/jsp-api.jar, but no luck.  I still get
exceptions:

javax.servlet.ServletException:
javax.servlet.jsp.tagext.TagAttributeInfo.(Ljava/lang/String;ZLjav
a/lang/String;ZZ)V

It looks like everything is not loaded.  Any ideas?

=

Norris Shelton
Software Engineer
Sun Certified Java 1.1 Programmer
Appriss, Inc.
ICQ# 26487421
AIM NorrisEShelton
YIM norrisshelton


__
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com

-
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]



RE: performance

2003-07-08 Thread Pitre, Russell
I think the link may be broken.I couldn't connect


Russ

-Original Message-
From: Reynir Hübner [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 08, 2003 3:23 PM
To: Tomcat Users List
Subject: RE: performance


Hi, 

I suggest a good reading of the webpage : 
http://www.javaperformancetuning.com/tips/j2ee_srvlt.shtml

-reynir.


> -Original Message-
> From: Mark F [mailto:[EMAIL PROTECTED]
> Sent: 8. júlí 2003 18:35
> To: Tomcat Users List
> Subject: performance
> 
> 
> Running Tomcat 4.0.6 on Solaris 8
> 
> Interested in improving performance, any tips or information
> would be appreciated.  Also any tips or information on 
> exactly how to use JSPC to improve performance would be 
> great.  I've found a lot by searching but I don't exactly 
> know how to use what I've found.
> 
> -Mark
> 

-
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]



Help!

2003-07-01 Thread Pitre, Russell
I'm running TC 4.1.24/ J2SDK 1.4 on Win2k Pro workstationI've
created a simple webapp to test form-based authentication against Active
Directory...I've had absolutely no luck...Has anyone had any
luck with this?  Any information would be greatly appreciated...code
snippets?

I had a little assistance with this website:
http://www.java-internals.com/code/jndi_realm.html

Where the snippet has "userRoleName="member"I'm not sure if that's a
security group in Active Directory or what...
...androleName="cn"..whats this?..


THanx
Russ.







ldap://[DOMAIN CONTROLLER]:389"

userBase="OU=Users,OU=Shawmut,DC=[DOMAIN],DC=com"
userSearch="(userPrincipalName={0})"
userRoleName="member"
roleBase="OU=Users,OU=Shawmut,DC=shawmut,DC=com"
roleName="cn"
roleSearch="(member={0})"

connectionName="CN=[user],OU=Users,OU=Shawmut,DC=[DOMAIN],DC=com"
connectionPassword="[password]"
roleSubtree="true"
userSubtree="true"/>








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



RE: FORM-based ldap authentication problem

2003-07-01 Thread Pitre, Russell
i'll give a shot..thanx sooo much.


take care and good lucki wish i could be more of a help to you



Russ

-Original Message-
From: Maurice Coyle - Sun Microsystems Ireland [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 01, 2003 1:07 PM
To: [EMAIL PROTECTED]
Subject: RE: FORM-based ldap authentication problem


by all means.  there's 4 basic steps to this:

1. in server.xml paste the following (replace  with the url
of the 
ldap server and you'll probably have to change the userBase bit too) to
tell 
tomcat where to go to authenticate:


 


2. in web.xml, right at the end paste the following (add 
tags for 
whicever other types of files you want protected):


   
tracker
*.jsp
GET
POST
   
   
 
 *
   



  FORM
  ldapRealm
  
  /login.jsp
  /login_error.jsp
  


3. create login.jsp and login_error.jsp and put them in the web-app's
document 
root

login.jsp must include the form with the j_* fields as in the skeleton
form 
below:


LDAP Authentication

Enter UserId


Enter Password





login_error.jsp can be as simple as:



The system was not able to log you in.


  

4. when you've successfully logged in, to get the name of the user who's
logged 
in, use String user = request.getRemoteUser();


hope this helps,
maurice


> Mailing-List: contact [EMAIL PROTECTED]; run by 
> ezmlm
> List-Unsubscribe: <mailto:[EMAIL PROTECTED]>
> List-Subscribe: <mailto:[EMAIL PROTECTED]>
> List-Help: <mailto:[EMAIL PROTECTED]>
> List-Post: <mailto:[EMAIL PROTECTED]>
> List-Id: "Tomcat Users List" 
> Delivered-To: mailing list [EMAIL PROTECTED]
> X-MimeOLE: Produced By Microsoft Exchange V6.0.6375.0
> content-class: urn:content-classes:message
> Subject: RE: FORM-based ldap authentication problem
> Date: Tue, 1 Jul 2003 12:52:46 -0400
> X-MS-Has-Attach: 
> X-MS-TNEF-Correlator: 
> Thread-Topic: FORM-based ldap authentication problem
> Thread-Index: AcM/8O7x+q8RZHTaQ5mM0xzRg5mCtAAACyJA
> From: "Pitre, Russell" <[EMAIL PROTECTED]>
> To: "Tomcat Users List" <[EMAIL PROTECTED]>, "Maurice
Coyle - Sun 
Microsystems Ireland" <[EMAIL PROTECTED]>
> X-OriginalArrivalTime: 01 Jul 2003 16:52:46.0869 (UTC)
FILETIME=[32D05C50:01C33FF1]
> X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N
> Content-Transfer-Encoding: 8bit
> X-MIME-Autoconverted: from quoted-printable to 8bit by
dub-mail1.Ireland.Sun.COM id h61GrEh10906
> 
> I've been trying to get form-based ldap authentication workingbut 
> no luck.do you think i could see some sample code?
> 
> 
> 
> Russ
> 
> -Original Message-
> From: Maurice Coyle - Sun Microsystems Ireland 
> [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, July 01, 2003 12:50 PM
> To: [EMAIL PROTECTED]
> Subject: FORM-based ldap authentication problem
> 
> 
> hi all,
> i've implemented form-based ldap authentication on my tomcat server.  
> it works fine in general but from time to time when i enter my ldap 
> username and password, i get a blank page with j_security_check in the

> location field.  if i
> reload the page, i get the login_error.jsp page and upon reloading the
> page one 
> further time, i am logged in successfully.
> 
> this is the exact sequence whenever there is a problem with the 
> authentication, i can reload the page 3 times and i get accepted.
> 
> does anyone have a clue what's the cause and if there's a solution?
> 
> appreciate any help,
> maurice
> 
> 
> -
> 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]


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



RE: FORM-based ldap authentication problem

2003-07-01 Thread Pitre, Russell
I've been trying to get form-based ldap authentication workingbut no
luck.do you think
i could see some sample code?



Russ

-Original Message-
From: Maurice Coyle - Sun Microsystems Ireland [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 01, 2003 12:50 PM
To: [EMAIL PROTECTED]
Subject: FORM-based ldap authentication problem


hi all,
i've implemented form-based ldap authentication on my tomcat server.  it
works 
fine in general but from time to time when i enter my ldap username and 
password, i get a blank page with j_security_check in the location
field.  if i 
reload the page, i get the login_error.jsp page and upon reloading the
page one 
further time, i am logged in successfully.

this is the exact sequence whenever there is a problem with the
authentication, 
i can reload the page 3 times and i get accepted.

does anyone have a clue what's the cause and if there's a solution?

appreciate any help,
maurice


-
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]



RE: JNDI and Active Directory.....

2003-06-26 Thread Pitre, Russell
I also referenced this site..

http://www.java-internals.com/code/jndi_realm.html


Thanx again




-Original Message-
From: Pitre, Russell 
Sent: Thursday, June 26, 2003 4:10 PM
To: Tomcat Users List
Subject: RE: JNDI and Active Directory.


Also,  prior to setting up my webapp to use Active Directory, I had the
webapp successfully authenticating to a JDBC realm.  

-Original Message-
From: Pitre, Russell 
Sent: Thursday, June 26, 2003 4:05 PM
To: [EMAIL PROTECTED]
Subject: JNDI and Active Directory.


I'm trying to setup my webapp to authenticate to Active Directory. After
searching and googling I still cannot resolve my problem.  I've created
a user named tomcatuser and security group called tomcat in the Users
container.  I've put my logon in that group tomcat and no success
logging into the webapp.  Any help or direction would be very
appreciated...

 

 

 

Server.xml:

 

 

ldap://server:389";

userBase="CN=Users,dc=[domain],dc=com"

userSearch="(userPrincipalName={0})"

userRoleName="member"

roleBase="CN=Users,dc=[domain],dc=com"

roleName="cn"

roleSearch="(member={0})"

 
connectionName="CN=tomcatuser,CN=Users,DC=[domain],DC=com"

connectionPassword="sinner"

roleSubtree="true"

userSubtree="true"/>

 

Web.xml

 



Show Tracker Security
Constraint



 
Protected Area

 
/*





 
tomcat





 



FORM

Show Tracker
Authentication Area



 
/login.jsp

 
/error.jsp







Registered
users

tomcat



 

 

 


-
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]



RE: JNDI and Active Directory.....

2003-06-26 Thread Pitre, Russell
Also,  prior to setting up my webapp to use Active Directory, I had the
webapp successfully authenticating to a JDBC realm.  

-Original Message-
From: Pitre, Russell 
Sent: Thursday, June 26, 2003 4:05 PM
To: [EMAIL PROTECTED]
Subject: JNDI and Active Directory.


I'm trying to setup my webapp to authenticate to Active Directory. After
searching and googling I still cannot resolve my problem.  I've created
a user named tomcatuser and security group called tomcat in the Users
container.  I've put my logon in that group tomcat and no success
logging into the webapp.  Any help or direction would be very
appreciated...

 

 

 

Server.xml:

 

 

ldap://server:389";

userBase="CN=Users,dc=[domain],dc=com"

userSearch="(userPrincipalName={0})"

userRoleName="member"

roleBase="CN=Users,dc=[domain],dc=com"

roleName="cn"

roleSearch="(member={0})"

 
connectionName="CN=tomcatuser,CN=Users,DC=[domain],DC=com"

connectionPassword="sinner"

roleSubtree="true"

userSubtree="true"/>

 

Web.xml

 



Show Tracker Security
Constraint



 
Protected Area

 
/*





 
tomcat





 



FORM

Show Tracker
Authentication Area



 
/login.jsp

 
/error.jsp







Registered
users

tomcat



 

 

 


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



JNDI and Active Directory.....

2003-06-26 Thread Pitre, Russell
I'm trying to setup my webapp to authenticate to Active Directory. After
searching and googling I still cannot resolve my problem.  I've created
a user named tomcatuser and security group called tomcat in the Users
container.  I've put my logon in that group tomcat and no success
logging into the webapp.  Any help or direction would be very
appreciated...

 

 

 

Server.xml:

 

 

ldap://server:389";

userBase="CN=Users,dc=[domain],dc=com"

userSearch="(userPrincipalName={0})"

userRoleName="member"

roleBase="CN=Users,dc=[domain],dc=com"

roleName="cn"

roleSearch="(member={0})"

 
connectionName="CN=tomcatuser,CN=Users,DC=[domain],DC=com"

connectionPassword="sinner"

roleSubtree="true"

userSubtree="true"/>

 

Web.xml

 



Show Tracker Security
Constraint



 
Protected Area

 
/*





 
tomcat





 



FORM

Show Tracker
Authentication Area



 
/login.jsp

 
/error.jsp







Registered
users

tomcat



 

 

 



form login

2003-06-06 Thread Pitre, Russell

I know this has been asked beforeso please direct me to any
documentations or faq's..I also searched and couldn't come
up with anything..so here's it goes

===
HTTP Status 400 - Invalid direct reference to form login page

type Status report
message Invalid direct reference to form login page
description The request sent by the client was syntactically incorrect
(Invalid direct reference to form login page).

===

I receive the above error when directly going to the login form in my
webapp rather than being redirected to the login form when trying to
access a protected resource..My goal here is to have the login form
on the home page and have the user login at his/her leisureand yet
still take advantage of tomcat security handling of protected pages and
directories..what is the best practice for this situation?
Thanx in advance.


Thanx
Russ


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



RE: WEB.xml portablility

2003-06-06 Thread Pitre, Russell
Thank you!   


Russ

-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 06, 2003 11:55 AM
To: Tomcat Users List
Subject: RE: WEB.xml portablility



Howdy,
The server.xml is not part of the .war file.  Its contents do not move
along magically.

If you depend on environment entries in your web.xml, you will always
need the server configuration modified to supply those environment
entries to your web application.  This is true when moving from a dev
tomcat server to a production one in the same company.  It's also true
when selling a webapp to someone who may run it on any other servlet
specification 2.3 compliant server.

Yoav Shapira
Millennium ChemInformatics


>-Original Message-
>From: Pitre, Russell [mailto:[EMAIL PROTECTED]
>Sent: Friday, June 06, 2003 10:49 AM
>To: Tomcat Users List
>Subject: WEB.xml portablility
>
>
>If I make changes that are specific to my web-app in the server.xml
file
>like jndi, mail resources, and my context paramsand i also make the

>necesarry configurations in my web.xml file..Now, I bundle up my
app
>into a war fileand then go to deploy the web-app on another tomcat 
>boxwill  i have to edit the server.xml file manually on the target 
>tomcat box?  or will the configurations move along with the .war 
>file???
>
>
>Any insight is appreciated...
>
>
>regards,
>russ
>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential,
proprietary and/or privileged.  This e-mail is intended only for the
individual(s) to whom it is addressed, and may not be saved, copied,
printed, disclosed or used by anyone else.  If you are not the(an)
intended recipient, please immediately delete this e-mail from your
computer system and notify the sender.  Thank you.


-
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]



WEB.xml portablility

2003-06-06 Thread Pitre, Russell

If I make changes that are specific to my web-app in the server.xml file
like jndi, mail resources, and my context paramsand i also make the
necesarry configurations in my web.xml file..Now, I bundle up my app
into a war fileand then go to deploy the web-app on another tomcat
boxwill  i have to edit the server.xml file manually on the target
tomcat box?  or will the configurations move along with the .war
file???


Any insight is appreciated...


regards,
russ


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



RE: Tomcat JDBC problem

2003-06-06 Thread Pitre, Russell
I definitely new to all this stuff but i was able to successfully use
the driver

here's what i did...

1.. Put mysql-connector-java-3.0.8-stable-bin.jarin
CATALINA_HOME\common\lib
2.. Didn't worry about setting the classpath for it...
3.. Server.xml stuff



username

tomcat



password

sinner




driverClassName

com.mysql.jdbc.Driver




url

jdbc:mysql://localhost/tomcatbook?autoReconnect=true



4.  Web.xml stuff


DB Connection
jdbc/Show
javax.sql.DataSource
Container





Hope this helps!


Regards,
Russ


-Original Message-
From: Jason Lanpher [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 05, 2003 11:38 AM
To: 'Tomcat Users List'
Subject: RE: Tomcat JDBC problem


Yes I am using com.mysql.jdbc.Driver

Here is the rest of the version numbers of the system.

RedHat 7.2 system
MySQL  3.56
Java   1.4.1_02
JDBC/MySQL 3.08





Jason Lanpher
 
[EMAIL PROTECTED]
 
http://www.stealthnetworking.com
 

Remember there are only 10 types of people in this world.  Those who
understand Binary and those who don't.

 


-Original Message-
From: Pitre, Russell [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 05, 2003 10:25 AM
To: Tomcat Users List
Subject: RE: Tomcat JDBC problem


are you using   "com.mysql.jdbc.Driver"?




-Original Message-
From: Jason Lanpher [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 05, 2003 11:08 AM
To: 'Tomcat Users List'
Subject: Tomcat JDBC problem


Hi all,

I am having a problem making the MySQL JDBC driver version 3
work with Tomcat correctly.  I had previously used MySQL JDBC driver
version 1 and developed a couple of programs to access my MySQL
database.  The programs worked just fine with this version of the
driver.  When I went to upgrade to the newest version of the MySQL JDBC
driver I get errors in my programs saying there is an error before the
beginning of the result set.  I am wondering if I am not installing the
driver correctly.  All I did for the JDBC driver version 1 was to place
the jar file in CATALINA_HOME/common/lib  I also made a CLASSPATH
variable and referenced the package.  Since this worked I thought the it
should still work for the JDBC driver version 3.  But for some reason it
does not.

Does anybody have any experience setting up JDBC driver 2 or 3
for MySQL that could give me a few tips on installation.

Thanks in advance,

Jason Lanpher
 
[EMAIL PROTECTED]
 
http://www.stealthnetworking.com
 


 




-
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]


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



Returning a Resultset...........best practice question

2003-06-06 Thread Pitre, Russell
Running:  Tomcat 4.1.24,  JSDK 1.4.0_03

 

I'm writing a class to return a resultSet to use in a JSP page or at
least i think thats what i want to do. Whats the best practice to return
that resultset.As the class is written below, when i try to iterate
through the resultset in the jsp page i get a NullPointerException which
i understand because i closed the connection before returningIf i
take out all the code in the finally section i can iterate through the
data no problembut thats not a good idea to leave connections
open...instead of returning a resultset should i return some other
type such as an Array with all the data. How should i return the data?
How can I alter my code for best practice.



==
package foo;

import javax.naming.*;
import javax.sql.*;
import java.sql.*;

public class DBTest{

String foo = "Not Connected";
String bar = "Not";

public ResultSet getUser(){

Connection conn = null;
Statement stmt = null; //Or preparedStatement if needed
ResultSet rs = null;

try{
Context ctx = new InitialContext();
if(ctx == null)
throw new Exception("Boom - No Context");

DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/Show");
if(ds != null){
conn = ds.getConnection();

if(conn != null){
foo = "Got Connection " + conn.toString();
stmt = conn.createStatement();
rs = stmt.executeQuery("SELECT * FROM user");

if(rs.next()){
foo=rs.getString("login");
bar=rs.getString("password");
}

}
}


}catch(Exception e){
e.printStackTrace();
}finally{

// Always make sure result sets and statements are closed,
// and the connection is returned to the pool.
if(rs != null){
try{
rs.close();
}catch(SQLException e){;}
rs=null;
}
if(stmt != null){
try{stmt.close();}catch(SQLException e){;}
stmt=null;
}
if(conn != null){
try{conn.close();}catch(SQLException e){;}
conn=null;
}

}
return rs; 
}

public String getFoo(){return foo;}
public String getBar(){return bar;}

 

 

 

 



RE: Tomcat JDBC problem

2003-06-06 Thread Pitre, Russell
are you using   "com.mysql.jdbc.Driver"?




-Original Message-
From: Jason Lanpher [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 05, 2003 11:08 AM
To: 'Tomcat Users List'
Subject: Tomcat JDBC problem


Hi all,

I am having a problem making the MySQL JDBC driver version 3
work with Tomcat correctly.  I had previously used MySQL JDBC driver
version 1 and developed a couple of programs to access my MySQL
database.  The programs worked just fine with this version of the
driver.  When I went to upgrade to the newest version of the MySQL JDBC
driver I get errors in my programs saying there is an error before the
beginning of the result set.  I am wondering if I am not installing the
driver correctly.  All I did for the JDBC driver version 1 was to place
the jar file in CATALINA_HOME/common/lib  I also made a CLASSPATH
variable and referenced the package.  Since this worked I thought the it
should still work for the JDBC driver version 3.  But for some reason it
does not.

Does anybody have any experience setting up JDBC driver 2 or 3
for MySQL that could give me a few tips on installation.

Thanks in advance,

Jason Lanpher
 
[EMAIL PROTECTED]
 
http://www.stealthnetworking.com
 


 




-
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]



RE: Web.xml File

2003-06-05 Thread Pitre, Russell
Ok. .thats what i thoughtthanks a lot.

I'm sure i'll have more Q's...

Regards,
Russ



-Original Message-
From: Jason Bainbridge [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, June 04, 2003 5:28 PM
To: Tomcat Users List
Subject: Re: Web.xml File


Yes it does matter, you should review your web.xml to ensure it follows
the 
order mentioned in the error.

Regards,
-- 
Jason Bainbridge
http://jblinux.org

On Thu, 5 Jun 2003 05:06, Pitre, Russell wrote:
> Does the order of parameters in your web.xml file matter...?
>
> I'm getting this error in stderr.log file.what could this mean?
>
>
> INFO: Initializing Coyote HTTP/1.1 on port 8080
> Jun 4, 2003 4:57:08 PM org.apache.commons.digester.Digester error
> SEVERE: Parse Error at line 56 column 12: The content of element type 
> "web-app" must match
> "(icon?,display-name?,description?,distributable?,context-param*,filte
> r*
>
,filter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mim
>
e-mapping*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,reso
>
urce-ref*,security-constraint*,login-config?,security-role*,env-entry*,e
> jb-ref*,ejb-local-ref*)".
> org.xml.sax.SAXParseException: The content of element type "web-app"
> must match
>
"(icon?,display-name?,description?,distributable?,context-param*,filter*
>
,filter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mim
>
e-mapping*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,reso
>
urce-ref*,security-constraint*,login-config?,security-role*,env-entry*,e
> jb-ref*,ejb-local-ref*)".
>
>
>
> -
> 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]



Web.xml File

2003-06-05 Thread Pitre, Russell
Does the order of parameters in your web.xml file matter...?   

I'm getting this error in stderr.log file.what could this mean?


INFO: Initializing Coyote HTTP/1.1 on port 8080
Jun 4, 2003 4:57:08 PM org.apache.commons.digester.Digester error
SEVERE: Parse Error at line 56 column 12: The content of element type
"web-app" must match
"(icon?,display-name?,description?,distributable?,context-param*,filter*
,filter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mim
e-mapping*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,reso
urce-ref*,security-constraint*,login-config?,security-role*,env-entry*,e
jb-ref*,ejb-local-ref*)".
org.xml.sax.SAXParseException: The content of element type "web-app"
must match
"(icon?,display-name?,description?,distributable?,context-param*,filter*
,filter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mim
e-mapping*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,reso
urce-ref*,security-constraint*,login-config?,security-role*,env-entry*,e
jb-ref*,ejb-local-ref*)".



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



RE: Connecting IIS 5.0 to Tomcat 4.1.24?

2003-06-04 Thread Pitre, Russell
Here's a good link as well...

http://www.onjava.com/pub/a/onjava/2002/12/18/tomcat.html



Russ

-Original Message-
From: Dominic Parry [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, June 03, 2003 3:02 PM
To: Tomcat Users List
Subject: Re: Connecting IIS 5.0 to Tomcat 4.1.24?

Hi David

I have exactly that configuration working :). Here are my configs:

[HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta Isapi
Redirector\2.0]
"serverRoot"="C:\\Program Files\\Apache Group\\Tomcat 4.1"
"extensionUri"="/jakarta/isapi_redirector2.dll"
"workersFile"="C:\\Program Files\\Apache Group\\Tomcat
4.1\\conf\\workers2.properties"
"logLevel"="DEBUG"

workers2.properties:

[shm]
file=C:\Program Files\Apache Group\Tomcat 4.1\logs\shm.file
size=1048576

[channel.socket:127.0.0.1:8009]
info=Ajp13 forwarding over socket
tomcatId=localhost:8009

# Map the Tomcat examples webapp to the Web server uri space
[uri:/examples/*]
info=Map the whole webapp

My jk2.properties is empty because I just wanted to use the defaults as
I'm not running anything special on it.

Other things to note:

1) In the IIS console:

Make sure that the jakarta virtual folder points to the location of
the isapi_redirector.dll file. It should also have execute
permissions.

2) Check that the event viewer has no errors generated by the connector
when you restart IIS.

3) I had to give permissions on the folder containing
isapi_redirector.dll to the IUSR_[your host name here] account.

4) Believe it or not, I had to reboot winXP, as a last resort, but it
worked. I think it's because of the order in which the services are
loaded.
 
Hope this helps!

Dom

  - Original Message - 
  From: David Legg 
  To: '[EMAIL PROTECTED]' 
  Sent: Tuesday, June 03, 2003 7:25 PM
  Subject: Connecting IIS 5.0 to Tomcat 4.1.24?


  I'm trying to set up the latest release of Tomcat (4.1.24) on a W2K
server
  running IIS 5.0.  Tomcat is happily running as a service and
responding to
  web requests on port 8080.  I'm using the tomcat-4.1.24-LE-jdk14.zip
and
  I've installed Java 1.4.1_02

  Has anyone managed to get IIS to talk to this version of Tomcat?

  Following hints in the Tomcat documentation I've tried installing JK2
  version 2.0.2 but without success.  For simplicity I've tried hooking
up the
  /examples context.  http://localhost:8080/examples/jsp works fine but
  http://localhost/examples/jsp gives me a 404 error.

  The registry file contains: -

[HKEY_LOCAL_MACHINE\SOFTWARE\Apache Software Foundation\Jakarta
Isapi
  Redirector\2.0]
"serverRoot"="c:\\tomcat4"
"extensionUri"="/jakarta/isapi_redirector2.dll"
"workersFile"="c:\\tomcat4\\conf\\workers2.properties"
"logLevel"="INFO"

  The jk2.properties file contains: -

# The default port is 8009 but you can use another one
channelSocket.port=8009

  The workers2.properties files contains: -

[channel.socket:localhost:8009]
info=Forwarding over socket connection to local tomcat instance.
host=localhost
port=8009

[ajp13:localhost:8009]
info=Ajp13 worker, connects to tomcat instance using AJP 1.3
protocol.
channel=channel.socket:localhost:8009

[uri:/examples/*]
info=JSP examples
context=/examples

  I've configured several versions of Tomcat over the years and am
getting
  used to spending a couple of weeks tinkering with it each time :-)
I'd love
  to hear from anyone who has got it working.

  Regards,

  David Legg
  Webmaster - 3Dlabs
  http://www.3dlabs.com
  mailto:[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]



form login

2003-06-04 Thread Pitre, Russell
I know this has been asked beforeso please direct me to any
documentations or faq's..I also searched and couldn't come
up with anything..so here's it goes

===
HTTP Status 400 - Invalid direct reference to form login page

type Status report
message Invalid direct reference to form login page
description The request sent by the client was syntactically incorrect
(Invalid direct reference to form login page).

===

I receive the above error when directly going to the login form in my
webapp rather than being redirected to the login form when trying to
access a protected resource..My goal here is to have the login form
on the home page and have the user login at his/her leisureand yet
still take advantage of tomcat security handling of protected pages and
directories..what is the best practice for this situation?
Thanx in advance.


Thanx
Russ


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



RE: beginner Tomcat and ant question.............

2003-06-04 Thread Pitre, Russell
Ok, I'm officially going crazy..somehow my issue has been
resolvedI took your suggestions J- and it worked outThanx a
lot.I appreciate it.

Thanx
Russ

-Original Message-
From: Pitre, Russell 
Sent: Tuesday, June 03, 2003 11:35 AM
To: Tomcat Users List
Subject: RE: beginner Tomcat and ant question.

That's what I was looking for too.but here's where it's failing at
during compile time...the build file was actually taken from
tomcat-docs/appdev/sample...i then changed the Catalina.home
property..so...i'm not sure whats up...





-Original Message-
From: Jason Bainbridge [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, June 03, 2003 11:23 AM
To: Tomcat Users List
Subject: Re: beginner Tomcat and ant question.

On Tue, 3 Jun 2003 22:56, Pitre, Russell wrote:
> BUILD FAILED
> fileC:/jakarta-tomcat-4.1.24/webapps/Show-tracker/build.xml:268:
> C:\jakarta-tom
> cat-4.1.24\webapps\Show-tracker\{catalina.home}\common\endorsed not
> found.
>
> I have the variable setup right in the build.xml file:"I THINK"
> 

I'd say you are missing a $ sign before {catalina.home} where it is
being 
referenced in your build.xml to create the above path so it isn't being 
parsed as a variable.

Regards,
-- 
Jason Bainbridge
KDE Web Team - http://kde.org 
[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]


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



RE: beginner Tomcat and ant question.............

2003-06-04 Thread Pitre, Russell
That's what I was looking for too.but here's where it's failing at
during compile time...the build file was actually taken from
tomcat-docs/appdev/sample...i then changed the Catalina.home
property..so...i'm not sure whats up...





-Original Message-
From: Jason Bainbridge [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, June 03, 2003 11:23 AM
To: Tomcat Users List
Subject: Re: beginner Tomcat and ant question.

On Tue, 3 Jun 2003 22:56, Pitre, Russell wrote:
> BUILD FAILED
> fileC:/jakarta-tomcat-4.1.24/webapps/Show-tracker/build.xml:268:
> C:\jakarta-tom
> cat-4.1.24\webapps\Show-tracker\{catalina.home}\common\endorsed not
> found.
>
> I have the variable setup right in the build.xml file:"I THINK"
> 

I'd say you are missing a $ sign before {catalina.home} where it is
being 
referenced in your build.xml to create the above path so it isn't being 
parsed as a variable.

Regards,
-- 
Jason Bainbridge
KDE Web Team - http://kde.org 
[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]



beginner Tomcat and ant question.............

2003-06-04 Thread Pitre, Russell
Sorry to bother everyone with these types of questionsbut i'm
killing myself over this..

This is a beginner question since i am still a beginner...I'm developing
a web-app and using ant as a build tooli keep getting 

BUILD FAILED
fileC:/jakarta-tomcat-4.1.24/webapps/Show-tracker/build.xml:268:
C:\jakarta-tom
cat-4.1.24\webapps\Show-tracker\{catalina.home}\common\endorsed not
found.

I have the variable setup right in the build.xml file:"I THINK"



My directory structure is:
c:\jakarta-tomcat-4.1.24\webapps\Show-tracker\
   \src
   \web
   \web\WEB-INF
   \build.xml

Whats going with this?



thanx
Russ

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