how to turn off session cookies

2005-09-28 Thread Fredrik Wendt
One-liner: How do you turn session cookies off, server side?


Hi!

Nowadays it's illegal to use cookies on web sites in sweden, without
informing the visitor that it's done and why, what cookie is etc. Since
I don't have any use of a session nor am interested in adding a page
saying we use cookies for no reason to the site in question, I'm
(after googling) wondering:

How do you turn session cookies off, server side?

In Tomcat 3.3, this could be done as seen on
http://jakarta.apache.org/tomcat/tomcat-3.3-doc/serverxml.html#SessionId
but I've failed to find out where this option has moved.


Thanks in advance,

Fredrik Wendt


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



RE: What to put into JAVA_HOME on Windows xp

2005-09-26 Thread Jan Fredrik Fallsen
your java home is C:\jsdk1\Àppserver\jdk

-Original Message-
From: Arthur D'Alessandro [mailto:[EMAIL PROTECTED] 
Sent: 26. september 2005 00:16
To: Tomcat Users List
Subject: Re: What to put into JAVA_HOME on Windows xp

Move it up one level, in your case:
C:\JDK1.4\AppServer\jdk

 On 9/25/05, Markus Hapke [EMAIL PROTECTED] wrote:

 Hello,

 I just installed tomcat 5.0.28 successfully.

 Then tested the samples in
 C:\TOMCAT\webapps\jsp-examples\jsp2 - they worked.

 Thed tried to test a .jsp of my own- getting the error msg in the
 MS Internet-Explorer:
 === BEGIN of error Msg 
 HTTP Status 500 -

 type Exception report

 message

 description The server encountered an internal error () that prevented it
 from fulfilling this request.

 exception

 org.apache.jasper.JasperException: Unable to compile class for
 JSP
 org.apache.jasper.compiler.DefaultErrorHandler.javacError(
 DefaultErrorHandler.java:97)
 org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java
 :346)
 org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:414)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:472)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:451)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
 org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java
 :511)
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java
 :295)
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:802)


 root cause

 Unable to find a javac compiler;
 com.sun.tools.javac.Main is not on the classpath.
 Perhaps JAVA_HOME does not point to the
 JDK
 org.apache.tools.ant.taskdefs.compilers.CompilerAdapterFactory.getCompiler
 (CompilerAdapterFactory.java:106)
 org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:935)
 org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:764)
 org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:382)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:472)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:451)
 org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
 org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java
 :511)
 org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java
 :295)
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
 javax.servlet.http.HttpServlet.service(HttpServlet.java:802)


 note The full stack trace of the root cause is available in the Apache
 Tomcat/5.0.28 logs.
 === END of error Msg= ==

 I set the environment entry of JAVA_HOME to
 C:\JDK1.4\AppServer\jdk\bin

 Is that correct?

 OK, nobody of you could know where I have my J2EE (1.4) :
 it is 'mounted' under:
 C:\JDK1.4\AppServer
 and i can find the javac.exe under: C:\JDK1.4\AppServer\jdk\bin

 Is my entry of the JAVA_HOME correct?

 Is there another error?

 Thanx in advance, Markus

 --
 ,,

 5 GB Mailbox, 50 FreeSMS http://www.gmx.net/de/go/promail
 +++ GMX - die erste Adresse für Mail, Message, More +++

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




--
-Art D'Alessandro


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



RE: How to start Tomcat using differnt JRE

2005-09-22 Thread Jan Fredrik Fallsen
You must change the JAVA_HOME in system variables

-Original Message-
From: lanna august [mailto:[EMAIL PROTECTED] 
Sent: 23. september 2005 07:16
To: tomcat-user@jakarta.apache.org
Subject: How to start Tomcat using differnt JRE

Hi sorry for sending this twice, but I am using new
email program and it kinda flipped out when I first
sent it, was not sure it went through the first time.

Hello 

I have searched far and wide but no luck so thought i
try here.

I have a Red Hat ES V4 Linux Server that has 3
different versions of JDK and JRE on it.  They each
are being used for different projects.  One of the
versions is 1.5 JDK and JRE.  I need to install now
Tomcat 5.5.9 on the server and I must have it use the
1.5 JRE when it starts up.  Unfortunatly the systems
global JDK and JRE are set to the 1.3 Version of Java
and this I cannot change it must remain.

I thought awhile ago I came across mention of how to
start up the Tomcat server and tell it what JRE to be
using.  But I don't remember exactly.

Can anyone help?

I tried making a Tomcat user and placing the Tomcat
server in this Tomcat users directory.  Then setting
the JAVA_HOME in this Tomcat users .bash_profile  to
point to the 1.5 directory.  I then log into the
Tomcat user and run the command java -version.  I get
back 1.3.

I thought there was a place in one of the config files
to point it at what the JAVA_HOME or JRE_HOME was?

or some kind of command I type at startup on the linux
box?

any help much appreciated.





__ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.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: Please take my address out of your mailing list !

2005-09-16 Thread Jan Fredrik Fallsen
place the url below in the to field and send it

[EMAIL PROTECTED]

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 
Sent: 16. september 2005 08:40
To: Tomcat Users List
Subject: Please take my address out of your mailing list !

Dear who-ever

every day I get more than 50 mails from people I don't know. I don't even
know, what  tomcat means (is it a plane?).

COULD YOU PLEASE TAKE MY NAME OUT OF YOUR DISTRIBUTION LIST?

Thank you very much!

francesca villa hänni
_
The information transmitted is intended only for the person or entity to
which it is addressed and may contain confidential and/or privileged
material.  Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by persons or
entities other than the intended recipient is prohibited.   If you received
this in error, please contact the sender and delete the material from any
computer.


-
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: running tomcat on port 80

2005-06-21 Thread Fredrik Liden
Shouldn't be any problems. Are you sure there are not other programs
bound to 80?

Try netstat -a in the dos window.

-Original Message-
From: Tony Smith [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, June 21, 2005 9:47 AM
To: tomcat-user@jakarta.apache.org
Subject: running tomcat on port 80

Hi, Can I run Tomcat 5.0 on port 80? I do not want my
visitor have to type the port number. 

After setting 80
as port number in the server.xml and starting tomcat,
I got the following error message:

SEVERE: Error starting endpoint
java.net.BindException:permission denied:80

Thanks,





 
Yahoo! Sports 
Rekindle the Rivalries. Sign up for Fantasy Football 
http://football.fantasysports.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: IE 20 session cookies limitation

2005-05-13 Thread Fredrik Liden
How about passing the session ids in the url like you woud do if the
user had cookies disabled?

-Original Message-
From: Rick Wong [mailto:[EMAIL PROTECTED] 
Sent: Friday, May 13, 2005 11:42 AM
To: tomcat-user@jakarta.apache.org
Subject: IE 20 session cookies limitation


Hi,

I am using Tomcat 5.0.26.  I have 20+ web applications hooked up with 
single-sign-on.  Each web application generates a JESSIONID session 
cookie with a different path, and shares a single JSESSIONIDSSO.

When testing my suite of applications, I notice that IE consistently 
drops my login after accessing the 20th web application within a 
session.  I did some research and learned about RFC 2109 where HTTP 
agents should support a minimum of 20 session cookies per domain.  That 
appears to be just what IE does.  The following Microsoft knowledgebase 
article explains that: 
http://support.microsoft.com/default.aspx?scid=kb;EN-US;306070.  I 
suspect JSESSIONIDSSO was the oldest cookie, and was the first to get 
dropped by IE when reaching over 20 session cookies.  Firefox does not 
have this problem.

Knowing that I cannot easily refactor the application suite to make less

number of web application ( 19), I am wondering if anyone else has this

problem, and if and how I might work around this IE limitation.

Thanks,
--
Rick

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



Strange error

2005-05-11 Thread Fredrik Liden
Does anyone have any idea what this error means?
I'm using jdk 1.5, tomcat 5.5.9 and intellij.

Thanks!

Connected to server
ERROR [/]: Session event listener threw exception
java.lang.NullPointerException
 at
org.objectstyle.cayenne.conf.WebApplicationListener.sessionCreated(WebAp
plicationListener.java:125)
 at
org.apache.catalina.session.StandardSession.tellNew(StandardSession.java
:379)
 at
org.apache.catalina.session.StandardSession.setId(StandardSession.java:3
51)
 at
org.apache.catalina.session.ManagerBase.createSession(ManagerBase.java:7
87)
 at
org.apache.catalina.session.StandardManager.createSession(StandardManage
r.java:290)
 at
org.apache.catalina.connector.Request.doGetSession(Request.java:2206)
 at org.apache.catalina.connector.Request.getSession(Request.java:2017)
 at
org.apache.catalina.connector.RequestFacade.getSession(RequestFacade.jav
a:822)
 at
org.apache.catalina.connector.RequestFacade.getSession(RequestFacade.jav
a:833)
 at
org.apache.jasper.runtime.PageContextImpl._initialize(PageContextImpl.ja
va:148)
 at
org.apache.jasper.runtime.PageContextImpl.initialize(PageContextImpl.jav
a:123)
 at
org.apache.jasper.runtime.JspFactoryImpl.internalGetPageContext(JspFacto
ryImpl.java:104)
 at
org.apache.jasper.runtime.JspFactoryImpl.getPageContext(JspFactoryImpl.j
ava:61)
 at org.apache.jsp.Login_jsp._jspService(org.apache.jsp.Login_jsp:35)
 at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
 at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.ja
va:322)
 at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
 at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
 at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:252)
 at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:173)
 at irf.filters.FrontFilter.doFilter(FrontFilter.java:51)
 at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:202)
 at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:173)
 at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:213)
 at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:178)
 at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:126)
 at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:105)
 at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:107)
 at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:1
48)
 at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:85
6)
 at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processC
onnection(Http11Protocol.java:744)
 at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint
.java:527)
 at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollow
erWorkerThread.java:80)
 at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool
.java:684)
 at java.lang.Thread.run(Thread.java:595)

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



RE: Expression Languange not working for me

2005-04-25 Thread Fredrik Liden
Check your web.xml file to make sure you're using the 2.4 dtd and not
2.3 or lower.

Fredrik

-Original Message-
From: Franklin Phan [mailto:[EMAIL PROTECTED] 
Sent: Monday, April 25, 2005 6:04 PM
To: tomcat-user@jakarta.apache.org
Subject: Expression Languange not working for me


I am running Tomcat 4.1.18 and 5.0.x.
I tried the following HTML and JSP using EL, and am not getting the
correct response from either Tomcat version.

I have the following HTML:

html
body
form action=TestBean.jsp
Name: input type=text name=namebr

input type=submit
/form
/body
/html



And the following JSP:

%@ page isELIgnored =false %
html
body
Request param name is: ${param.name} br

/body
/html



Regardless of what I type in the Name box in the HTML page, the response
is always:

Request param name is: ${param.name}


What is wrong?
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]



RE: Expression Languange not working for me

2005-04-25 Thread Fredrik Liden
Try this:

web-app version=2.4
 xmlns=http://java.sun.com/xml/ns/j2ee;
 xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
 xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd; 

/web-app

-Original Message-
From: Franklin Phan [mailto:[EMAIL PROTECTED] 
Sent: Monday, April 25, 2005 6:24 PM
To: Tomcat Users List
Subject: Re: Expression Languange not working for me


This is what my web.xml file contains:

?xml version=1.0 encoding=ISO-8859-1?

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

web-app
/web-app

What do I change?



Fredrik Liden wrote:

 Check your web.xml file to make sure you're using the 2.4 dtd and not 
 2.3 or lower.
 
 Fredrik
 
 -Original Message-
 From: Franklin Phan [mailto:[EMAIL PROTECTED]
 Sent: Monday, April 25, 2005 6:04 PM
 To: tomcat-user@jakarta.apache.org
 Subject: Expression Languange not working for me
 
 
 I am running Tomcat 4.1.18 and 5.0.x.
 I tried the following HTML and JSP using EL, and am not getting the 
 correct response from either Tomcat version.
 
 I have the following HTML:
 
 html
 body
 form action=TestBean.jsp
 Name: input type=text name=namebr
 
 input type=submit
 /form
 /body
 /html
 
 
 
 And the following JSP:
 
 %@ page isELIgnored =false %
 html
 body
 Request param name is: ${param.name} br
 
 /body
 /html
 
 
 
 Regardless of what I type in the Name box in the HTML page, the 
 response is always:
 
 Request param name is: ${param.name}
 
 
 What is wrong?
 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]



RE: Expression Languange not working for me

2005-04-25 Thread Fredrik Liden
Are you able to correctly view the Expression Language examples that
comes with Tomcat 5.0?
If so look at those web.xml files to make sure you have the same web-app
attributes.

Right now it could be some caching that prevents you from seeing the
correct result.
Try creating a new jsp from scratch and do it again.

-Original Message-
From: Franklin Phan [mailto:[EMAIL PROTECTED] 
Sent: Monday, April 25, 2005 6:34 PM
To: Tomcat Users List
Subject: Re: Expression Languange not working for me


It doesn't help.  I'm still getting the same result.

My current web.xml:

?xml version=1.0 encoding=ISO-8859-1?

web-app version=2.4
  xmlns=http://java.sun.com/xml/ns/j2ee;
  xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
  xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee
  http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd; 

/web-app




Fredrik Liden wrote:

 Try this:
 
 web-app version=2.4
  xmlns=http://java.sun.com/xml/ns/j2ee;
  xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
  xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee
 http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd; 
 
 /web-app
 
 -Original Message-
 From: Franklin Phan [mailto:[EMAIL PROTECTED]
 Sent: Monday, April 25, 2005 6:24 PM
 To: Tomcat Users List
 Subject: Re: Expression Languange not working for me
 
 
 This is what my web.xml file contains:
 
 ?xml version=1.0 encoding=ISO-8859-1?
 
 !DOCTYPE web-app
  PUBLIC -//Sun Microsystems, Inc.//DTD Web Application 2.3//EN
  http://java.sun.com/dtd/web-app_2_3.dtd;
 
 web-app
 /web-app
 
 What do I change?
 
 
 
 Fredrik Liden wrote:
 
 
Check your web.xml file to make sure you're using the 2.4 dtd and not
2.3 or lower.

Fredrik

-Original Message-
From: Franklin Phan [mailto:[EMAIL PROTECTED]
Sent: Monday, April 25, 2005 6:04 PM
To: tomcat-user@jakarta.apache.org
Subject: Expression Languange not working for me


I am running Tomcat 4.1.18 and 5.0.x.
I tried the following HTML and JSP using EL, and am not getting the
correct response from either Tomcat version.

I have the following HTML:

html
body
form action=TestBean.jsp
Name: input type=text name=namebr

input type=submit
/form
/body
/html



And the following JSP:

%@ page isELIgnored =false %
html
body
Request param name is: ${param.name} br

/body
/html



Regardless of what I type in the Name box in the HTML page, the
response is always:

Request param name is: ${param.name}


What is wrong?
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]



Filtering remote host access from web.xml

2005-04-11 Thread Fredrik Jonson
Hello,

I want to limit access to a specific servlet based on the requesting clients 
host name and address. I'm aware of the RemoteHostValve, but as I understand 
the specification it can only be used by editing the server.xml file, and I 
would prefer to have a method to control it in the web.xml file.

Basically, what I'd need is a RemoteHostFilter, but i find no reference to a 
such a creature. Of course I could write one myself, but I cannot imagine that 
no one have had this problem before me.

So, what is a good approach on this?

(I'm using tomcat 4.1.31)

regards,
--
Fredrik Jonson


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



Filtering remote host access in web.xml

2005-04-11 Thread Fredrik Jonson
Hello,

I want to limit access to a specific servlet based on the requesting clients 
host name and address. I'm aware of the RemoteHostValve, but as I understand 
the specification it can only be used by editing the server.xml file, and I 
would prefer to have a method to control it in the web.xml file.

Basically, what I'd need is a RemoteHostFilter, but i find no reference to a 
such a creature. Of course I could write one myself, but I cannot imagine that 
no one have had this problem before me.

So, what is a good approach on this?

regards,
--
Fredrik Jonson


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



Tomcat 3 and Tomcat 5 on JDK 1.3 and JDK 1.5 respectively

2005-04-01 Thread Fredrik Liden
Does anyone know if this configuration is possible on one computer?

The reason for the two different JDKs is that I'm guessing that Tomcat
3.23 isn't compatible with jdk 1.5 or even 1.4 or is it? So I guess the
question is if it's in Catalinas startup config files it's possible to
specify different JAVA_HOMEs.

Anyone have any experience with running different versions like this?
Any input would be appreciated.

Fredrik

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



Address localhost:8080 already in use

2005-03-23 Thread Fredrik Liden
Here is a big problem that I've run into so many times.
I run start tomcat.
And then by accident I start it again while it is running.
After that I can't shut it down again. And if I try to run it it says
the address is in use. Have someone found any solution to this problem?

Any suggestions would be appreciated.

/Fredrik

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



RE: Address localhost:8080 already in use

2005-03-23 Thread Fredrik Liden
I killed the java processes that were bound to 8080 but there must be a
better way. I'm sure I'm not the only one that accidentally tried to
start tomcat 2 times.

-Original Message-
From: Folashade Adeyosoye [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, March 23, 2005 4:42 PM
To: 'Tomcat Users List'
Subject: RE: Address localhost:8080 already in use

Reboot !

-Original Message-
From: Fredrik Liden [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, March 23, 2005 7:30 PM
To: Tomcat Users List
Subject: Address localhost:8080 already in use

Here is a big problem that I've run into so many times.
I run start tomcat.
And then by accident I start it again while it is running.
After that I can't shut it down again. And if I try to run it it says
the address is in use. Have someone found any solution to this problem?

Any suggestions would be appreciated.

/Fredrik

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



Help configure ServletFilter

2005-03-16 Thread Fredrik Liden
Does anyone know how to configure a ServletFilter to only respond to
JSPs and Servlets? 

If I set it to everything using * it triggers for all the images as
well.

Thanks!

/Fredrik

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



JDBC Realm by-passing login page using a link

2005-03-10 Thread Fredrik Liden
Is it possible to pass login info in a link and then based on this
information set the JDBC realm status to logged in?

In other words is it possible to trigger the authentication manually in
a filter?

Thanks!

/Fredrik

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



RE: How to run servlet for every 30 minutes in Tomcat 4.1.30

2004-12-21 Thread Fredrik Liden
Check out QuartzScheduler from Open Symphony it's easy to configure within 
Tomcat.

Fredrik 

-Original Message-
From: pandu yelamanchili [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, December 21, 2004 9:58 AM
To: [EMAIL PROTECTED]
Subject: Re: How to run servlet for every 30 minutes in Tomcat 4.1.30


I would say it should be avoided at all if possible using threads. Since as 
we know in case of threads, there is not much management you can do. Also in 
my experience i have seen it is very easy for them to get out of control . 
So if there are any other alternatives, They should be explored first before 
threads.

I am not sure if Tomcat supports MBeans, But I remeber in JBOss, you could 
create MBeans and schedule them in the container.

Pandu

From: Jorge Sopena [EMAIL PROTECTED]
Reply-To: Tomcat Users List [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Subject: Re: How to run servlet for every 30 minutes in Tomcat 4.1.30
Date: Tue, 21 Dec 2004 18:58:23 +0100

Why is bad using own threads inside web application?
Aren't all the servlet request actually a thread in Tomcat?
I can't find a reason why it's so bad solution.
In that way, you manage to have a single and independent application.

Maybe I don't know some thread behaviour in Tomcat...

Jorge.


Allistair Crossley wrote:

myself and ben have suggested the most appropriate methods for doing 
this.
Ben mentions WGET http://www.gnu.org/software/wget/wget.html which can be 
added to a *basic* script hooked up to a cron with an interval of whatever 
you like.

you really ought to get rid of threads and thread sleeps inside web
application code.

Allistair.



-Original Message-
From: Jorge Sopena [mailto:[EMAIL PROTECTED]
Sent: 21 December 2004 17:15
To: Tomcat Users List
Subject: Re: How to run servlet for every 30 minutes in Tomcat 4.1.30


Hi,
I'm having a similar problem in my application.
I've got several servlets called by the users. Every requets save 
some
information in DB, that has to be sent to another server later and in a 
compress format.
So I need sth similar toShilpa is asking, a process which runs every  X 
minutes to recover the information and send it to the Server.

My solution to this problem was to implement a 
ServletContextListener
inside Tomcat.
When Tomcat starts my application the contextInitialized method is 
called, and then a thread is started to do the task explained above.
I use Thread.sleep(step) to wait for the next execution.

I didn't find anyway to set a timer for a servlet, and I didn't like 
the
option of creating an external script .

Any other  suggestions to solver this problem?

Thanks

Jorge


Ben Souther wrote:



On Tue, 2004-12-21 at 11:28, Allistair Crossley wrote:




no, and I believe doing so it bad practice. use some OS

controlled timer like cron to issue a HTTP call to your servlet. I 
once
wrote a shell script that calls a http address on the local machine but 
cannot remember how ;) if you are using oracle then you can setup this 
timer thread inside the database itself. don't add a thread into your web 
application.






I concur. It's certainly possible to write a treaded java object 
that fires a command every so often but there would be no point in 
making that object a servlet (servlets exist to answer client 
requests). It's also, IMHO, more aggravation than it's worth to 
manage your own daemon threads in a webapp.

It would take all of 2 minutes to write a timer with crontab and 
wget that could call your servlet whenever you want.



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










FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE
---
QAS Ltd.
Developers of QuickAddress Software
a href=http://www.qas.com;www.qas.com/a
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT


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





-- ==
Jorge Sopena Torres
SIDSA
(Semiconductores Investigación y Diseño, S.A.)

Parque Tecnológico de Madrid
c/ Torres Quevedo, nº 1
28760 TRES CANTOS (Madrid) (SPAIN)

Phone : +34 91 803 5052
Fax:+34 91 803 9557

e-mail: [EMAIL PROTECTED]
URL: http://www.sidsa.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: MYSQL Authentication

2004-12-20 Thread Fredrik Liden
Hey M,

Yes it does using JDBCRealm. Instructions are here:
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/realm-howto.html#JDBCRea
lm

-Fredrik


-Original Message-
From: Michael Hamilton [mailto:[EMAIL PROTECTED] 
Sent: Monday, December 20, 2004 10:56 AM
To: Tomcat Users List
Subject: MYSQL Authentication


I have a servlet that I do custom authentication with on the backend,
but I want to move this MYSQL authentication into Tomcat. Does Tomcat
support user authentication from a database?

-M


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



Undeploying without using manager?

2004-12-14 Thread Fredrik Jonson
Hello, 

I would like to stop and undeploy a webapp without restarting 
tomcat, and without using the manager application. Preferablely 
using a command line tool. How can I do that? 

I'm using tomcat 4.1.29. 

-- 
Fredrik Jonson


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


Re: Undeploying without using manager?

2004-12-14 Thread Fredrik Jonson
On 2004-12-14, Shapira, Yoav [EMAIL PROTECTED] wrote:

  I would like to stop and undeploy a webapp without restarting
  tomcat, and without using the manager application.

 You can use the Manager through Ant, as illustrated in the Manager
 how-to doc.  But if really don't want to use the Manager at all, and
 don't want to restart Tomcat, go write your own undeployment mechanism.

In this case, the manager app isn't installed at all (security 
precaution), I probably should have mentioned that. And writing 
my own deployment mechanism seems like way over my head right now. 
At lest I know I haven't missed anything obvious. 

Thanks for the input.
-- 
Fredrik Jonson


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


RE: Tomcat Requirements?

2004-11-29 Thread Fredrik Liden
Hi Chris,

That's a pretty general question.
It depends on what apps you are running. The number of users. Then there
could be various bottlenecks and memory leaks. 

I'm not sure if Tomcat 5 still have a memory leak but I recall other
people having problems in this area before. Why don't you go through the
performance section of the Tomcat documents and change the settings for
debugging, and servlet reloading that could affect performance. 
I'd still recommend getting a gig of memory. Especially with the raid
thing going on.

Fredrik


-Original Message-
From: Chris Cherrett [mailto:[EMAIL PROTECTED] 
Sent: Monday, November 29, 2004 11:43 AM
To: Tomcat Users List
Subject: Tomcat Requirements?


I have a client who is claiming that my software is slowing down. I
cannot 
determine why this would be. He is running the following:

P3 - 450 with 360MB of RAM
with 2 IDE - 7200 RPM drives mirrored Raid 1 with Win2k

I have found that any client running a faster system works great. Do you
have 
any suggestions as to how to speed things up on this hardware
configuration? 
example increase memory allocated to Tomcat.

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]



RE: Tomcat will not run JSPs

2004-08-26 Thread Fredrik Liden
Go to google:

Search for setting java_home click the first link in the result link.
Follow step-by-step instructions. 

Once you get passed the step of setting the paths you'll no doubt
encounter tons of problems and questions. Make sure to read the basic
tutorials and search the archive for the same questions. If you can't
find the answer after looking in those two places please feel free to
post your questions.

Let's keep this list somewhat relevant shall we.

Fredrik

-Original Message-
From: Nelson, Jerry W, Contractor 146CF, SCB
[mailto:[EMAIL PROTECTED] 
Sent: Thursday, August 26, 2004 5:24 PM
To: 'Tomcat Users List'
Subject: RE: Tomcat will not run JSPs


I completely romoved EVERTHING that has anything to do with Java and
reinstalled J2SDK1.4.2_05 and JRE1.4.2_05 and reinstalled
jakarta-tomcat-5.0.27.  When I reinstalled jakarta, all it asked for was
a directory for the JVM, nothing for home directory OR the location of
javac. I still get an error 500 stating that it can't find javac.  How
can I tell this STUPID program where it is???  I know javac existed in
the following
directory: C:\jsdk1.4.2_05\bin.  There has got to be a way to tell
Tomcat where to find the file!

//SIGNED//
 
Jerry Nelson

-Original Message-
From: Wendy Smoak [mailto:[EMAIL PROTECTED]
Sent: Thursday, August 26, 2004 4:47 PM
To: Tomcat Users List
Subject: Re: Tomcat will not run JSPs


From: Nelson, Jerry W
 What's the syntax??  JAVA_HOME is nowhere to be found in System 
 Vaiables.

You have to add it if you want it to be there.  Go back to your
installation instructions for the JDK, it should explain everything you
need to set up. Until you've got the JDK properly installed, Tomcat
doesn't have a chance of working right.  Are you able to compile and run
'HelloWorld' from the command line?

To answer your question, (assuming you're on Windows,) it will be
something like...

U:\echo %JAVA_HOME%
c:\j2sdk1.5.0

You can set it from the command line as well, just:

U:\set JAVA_HOME=c:\whereever\the\jdk\lives

That will go away when you close the command window.  You could probably
also set it in the batch file that starts Tomcat, but other things that
use Java will be looking for JAVA_HOME, might as well set it once and
forget it.

-- 
Wendy Smoak


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



Possible to retrieve ServletContext from any class used in the web application??

2004-07-12 Thread Fredrik Liden
Hi,

Does anyone know if it's possible to retrieve the ServletContext from
any class (like a helper class) that is being used in the Web app, even
though the request object is not being passed to the object?

Any ideas would be greatly appreciated.

/Fredrik

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



Tomcat 4.1.30 + SSL = Problems

2004-07-08 Thread Fredrik Liden
I followed the instructions on the tomcat SSL Config page.
I generated the .keystore file using changeit password.

When I go to the test page http://localhost:8443/ I see  5 squares up in
the left corner and that's it. Anyone encountered this?? I'm not sure
how to proceed.

I'm using Jdk 1.4.1 so I shouldn't have to download the JSSE files
according to the instructions.

Anyone please!

/Fredrik


Tomcat 5.0.12: Proxy with mod_proxy and HttpConnector not possible?

2003-10-19 Thread Fredrik Håård
Hi,
I've been working with Tomcat for a while and just migrated my webapps to 
my Debian box. Since I'm, already running Apache I thought it a good idea 
to use Apache as a proxy for Tomcat, and for simplicity I settled for the 
solution specified at this address:

http://jakarta.apache.org/tomcat/tomcat-5.0-doc/proxy-howto.html

However, when trying this solution I get a ClassNotFoundException (from 
catalina.out):

Catalina.start: java.lang.ClassNotFoundException: 
org.apache.catalina.connector.http.HttpConnector

Furthermore, when reading up on Tomcat documentation, 
org.apache.catalina.connector.http does no longer seem to exist in Tomcat 
5. I tried googling for the exception and for Tomcat 5 and mod_proxy, but 
ended up with nothing useful.

So, is the documentation out of synch and I should use JK2, or did I miss 
something?

If I have to use JK, can you point me to a good reference source, the link 
in the Tomcat docs seem broken - at least I end up at the Jakarta binary 
distributions.

Fredrik
--
fredrik at haard dot se
/~\
\ / Join the ASCII ribbon
x  campaign against HTML email
/ \ 

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


Re: Servlet mapping for root directory in a webapp?

2003-08-14 Thread Fredrik Jonson
Following up to myself here... 

On Thu, 7 Aug 2003, Fredrik Jonson wrote:

 I'm trying to get tomcat (from sun's jwsdp1.2) to do a default mapping. 
 
 I (and a lot of other people, apparently =) have tried:
 
 servlet-mapping
 servlet-nameMainView/servlet-name
 url-pattern//url-pattern
 /servlet-mapping

Today I changed it to:

 servlet-mapping
 servlet-nameMainView/servlet-name
 url-pattern/index.html/url-pattern
 /servlet-mapping

And, as I understand it, tomcat(?) returns that servlet mapping for
requests for the root catalog. Well, it is a kind of workaround, but
since it works well enough I'll just accept that and continue. 

But if anyone know more about the magic behind it all, I'd be very
greatful for a thorough explanation of how and why it works. 

TIA  regards, 
-- 
Fredrik Jonson


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



Servlet mapping for root directory in a webapp?

2003-08-07 Thread Fredrik Jonson
Hello, 

I'm trying to get tomcat (from sun's jwsdp1.2) to do a default mapping. 

Ie, in my webbapp /stuff/ I want to get a servlet to serve the root 
page. As I understand it there is a default servlet that serves 
static content, I do not want to replace that one, but only load a
specific servlet for the root url for my webapp.

I (and a lot of other people, apparently =) have tried:

servlet-mapping
servlet-nameMainView/servlet-name
url-pattern//url-pattern
/servlet-mapping

as I found it on a lot of search results, but as I understand it
that pattern is already taken by the default servlet. It doesn't
work.

I have had little succes searching google, and the documentation for 
solutions. Is it at all possible, or does everyone just use a dummy
index.html in the root directory and forwards the users to the real
content serving servlet? 

TIA
-- 
Fredrik Jonson


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



SV: Global DataSource

2003-03-12 Thread Fredrik Larsson
Hi again.

I just solved my problem with global datasources in Tomcat.
Instead of putting my Resource name= and ResourceParams in
GlobalNamingResources/GlobalNamingResources (which gave me lot's of
trouble and exceptions) I put it in the DefaultContext/DefaultContext
and removed resource-ref from my web.xml.

I don't know if this is a neat solution but hey, it works. :-)

/Fredrik

-Ursprungligt meddelande-
Från: Fredrik Larsson [mailto:[EMAIL PROTECTED]
Skickat: den 11 mars 2003 14:39
Till: [EMAIL PROTECTED]
Ämne: Global DataSource


Hi all.

I'm trying to set up a global DataSource on my Tomcat 4.1.18 standalone to
be available to all of my applications installed on the server.

But... I just can't get this to work. I've been following the instructions
in the tomcat documentation but it doesn't help.

I can start the server without any problems and view the global datasource
in the Administration Tool but as soon as I'm trying to access the
datasource from a servlet i get the following exception:
java.sql.SQLException: Cannot load JDBC driver class 'null'.

I've tried to set up the datasource for just one application context and
that works... but that's not what I want.

Another thing is that when I'm trying to view the datasources for one
specific application-context that should use this global datasource I get
this exception:
org.apache.jasper.JasperException: Exception retrieving attribute
'driverClassName'

Has anyone got a clue?

Thanks!
/Fredrik


This is what my conf-files look like:

SERVER.XML
  GlobalNamingResources

Resource   name=jdbc/MyDB
auth=Container
type=javax.sql.DataSource/

ResourceParams name=jdbc/MyDB
parameter
namefactory/name
valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
/parameter

parameter
namemaxActive/name
value100/value
/parameter

parameter
namemaxIdle/name
value30/value
/parameter

parameter
namemaxWait/name
value1/value
/parameter

parameter
nameusername/name
valuemyusername/value
/parameter
parameter
namepassword/name
value/value
/parameter

parameter
namedriverClassName/name
valueorg.gjt.mm.mysql.Driver/value
/parameter

parameter
nameurl/name
valuejdbc:mysql://localhost:3306/mydb/value
/parameter
/ResourceParams

  /GlobalNamingResources

WEB.XML
resource-ref
descriptionDB Connection/description
res-ref-namejdbc/MyDB/res-ref-name
res-typejavax.sql.DataSource/res-type
res-authContainer/res-auth
/resource-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]



Global DataSource

2003-03-11 Thread Fredrik Larsson
Hi all.

I'm trying to set up a global DataSource on my Tomcat 4.1.18 standalone to
be available to all of my applications installed on the server.

But... I just can't get this to work. I've been following the instructions
in the tomcat documentation but it doesn't help.

I can start the server without any problems and view the global datasource
in the Administration Tool but as soon as I'm trying to access the
datasource from a servlet i get the following exception:
java.sql.SQLException: Cannot load JDBC driver class 'null'.

I've tried to set up the datasource for just one application context and
that works... but that's not what I want.

Another thing is that when I'm trying to view the datasources for one
specific application-context that should use this global datasource I get
this exception:
org.apache.jasper.JasperException: Exception retrieving attribute
'driverClassName'

Has anyone got a clue?

Thanks!
/Fredrik


This is what my conf-files look like:

SERVER.XML
  GlobalNamingResources

Resource   name=jdbc/MyDB
auth=Container
type=javax.sql.DataSource/

ResourceParams name=jdbc/MyDB
parameter
namefactory/name
valueorg.apache.commons.dbcp.BasicDataSourceFactory/value
/parameter

parameter
namemaxActive/name
value100/value
/parameter

parameter
namemaxIdle/name
value30/value
/parameter

parameter
namemaxWait/name
value1/value
/parameter

parameter
nameusername/name
valuemyusername/value
/parameter
parameter
namepassword/name
value/value
/parameter

parameter
namedriverClassName/name
valueorg.gjt.mm.mysql.Driver/value
/parameter

parameter
nameurl/name
valuejdbc:mysql://localhost:3306/mydb/value
/parameter
/ResourceParams

  /GlobalNamingResources

WEB.XML
resource-ref
descriptionDB Connection/description
res-ref-namejdbc/MyDB/res-ref-name
res-typejavax.sql.DataSource/res-type
res-authContainer/res-auth
/resource-ref


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



SV: Global DataSource

2003-03-11 Thread Fredrik Larsson
I just tried to install the 4.1.21 beta but it didn't help.

Thanks anyway.

/Fredrik

-Ursprungligt meddelande-
Från: Klaasjan Brand [mailto:[EMAIL PROTECTED]
Skickat: den 11 mars 2003 16:26
Till: Tomcat Users List
Ämne: Re: Global DataSource


On Tue, 2003-03-11 at 14:39, Fredrik Larsson wrote:
 Hi all.
 I can start the server without any problems and view the global datasource
 in the Administration Tool but as soon as I'm trying to access the
 datasource from a servlet i get the following exception:
 java.sql.SQLException: Cannot load JDBC driver class 'null'.

 I've tried to set up the datasource for just one application context and
 that works... but that's not what I want.

I had lots of trouble with JNDI datasources too; it seems there's been
done some work on this:
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16316

I'd try the 4.1.21 beta to see if it still gives trouble...

Klaasjan


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



SV: Global DataSource

2003-03-11 Thread Fredrik Larsson
Hi Pratt.

No, I'm doing the look-up from a utility class used by my Action class
(org.apache.struts.action.Action)

/Fredrik

-Ursprungligt meddelande-
Från: Tomcat-RND [mailto:[EMAIL PROTECTED]
Skickat: den 11 mars 2003 17:55
Till: Tomcat Users List
Ämne: Re: Global DataSource


Hi,

Are looking up the data source in a load-on-startup servlet?

Regards,
Pratt.


- Original Message -
From: Fredrik Larsson [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Tuesday, March 11, 2003 9:46 PM
Subject: SV: Global DataSource


 I just tried to install the 4.1.21 beta but it didn't help.

 Thanks anyway.

 /Fredrik

 -Ursprungligt meddelande-
 Från: Klaasjan Brand [mailto:[EMAIL PROTECTED]
 Skickat: den 11 mars 2003 16:26
 Till: Tomcat Users List
 Ämne: Re: Global DataSource


 On Tue, 2003-03-11 at 14:39, Fredrik Larsson wrote:
  Hi all.
  I can start the server without any problems and view the global
datasource
  in the Administration Tool but as soon as I'm trying to access the
  datasource from a servlet i get the following exception:
  java.sql.SQLException: Cannot load JDBC driver class 'null'.
 
  I've tried to set up the datasource for just one application context and
  that works... but that's not what I want.

 I had lots of trouble with JNDI datasources too; it seems there's been
 done some work on this:
 http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16316

 I'd try the 4.1.21 beta to see if it still gives trouble...

 Klaasjan


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



Security manager, velocity and logging - access denied

2003-02-09 Thread Fredrik Jonson
Hello, 

I'm a tomcat newbie running debian and trying to use tomcat 4.0.3-3woody2 
and velocity-1.3.1-rc2. So far I haven't managed all that well. =)

If I disable the java security manager everything works fine. But I 
kinda figure that the security manager is there to serve a purpose.
I would really like to have it activaded and not less strict than
necessary.

When I enable it I get the following error, probably caused by the
combination of some automatic(?) logging in velocity that haven't got
the correct access rights in catalina.policy:

  Apache Tomcat/4.0.3 - HTTP Status 500 - Internal Server Error
exception
javax.servlet.ServletException: Error initializing Velocity: 
  java.lang.Exception: Unable to configure AvalonLogSystem: 
java.security.AccessControlException: access denied
(java.io.FilePermission /var/lib/tomcat4/webapps/ROOT read)
at org.apache.velocity.servlet.VelocityServlet.initVelocity(
 VelocityServlet.java:236)
[snippage]  

I have tried random (doh!) changes in the policy, but without much luck. 
I'll be greatful to get some hints... What are good default grants for 
webapps using velocity?

TIA  regards, 
-- 
Fredrik Jonson
[EMAIL PROTECTED]


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




Question/problem with AJP13Connector for Tomcat + IPlanet + SSL.

2002-08-27 Thread Fredrik Lagerblad


Hi All.

I'm in a project where we use IPlanet Web Server 4.1 together with Tomcat
4.0.4 using SSL, connecting them together with the nsapi_redirector and the
AJP13 Connector.

Initally we just couldn't get it to work using SSL, the AJPConnector stated
in the log that it couldn't convert the certificate supplied by the web
server.

After a lot of digging in the Connector's code, and modifying it to log
more, I found the problem. 
The supplied certificate came as base64-encoded (PEM) to the AJP13Connector,
but it seemed to expect a DER-encoded one.
(org.apache.ajp.RequestHandler.java:347, also see the snippet below)

Since it uses the standard X509 CertificateFactory, which seem NOT (?!) to
support PEM/base64-encoded certificates, it failed to create the
certificate, and hence not putting it in the request.

I was able to solve it by modifying the implementation of the certificate
conversion routine: 
first I simply check whether the certificate seem to be base64-encoded, and
if so decode it before letting the standard code generate the certificate.


With that little patch to the tomcat-ajp.jar, everything now works fine. 
(I was also able to overcome the problem by adding a new Security Provider,
that could decode PEM X509-certificates, but that's not a viable solution)

So my question is: is this a bug in the Connector (i.e. the RequestHandler
class) that it cannot handle base64-encoded certificates, or is it IPlanet
(or the nsapi_redirector) that is supplying the certificate in the
wrong(base64) format ??

Has anyone else experienced this ??

I'd really prefer not having to supply my own patch to Tomcat with every
distribution of our system, so any input or suggestions are welcome.



Best regards,
Fredrik.



[org.apache.ajp.RequestHandler.java:]
[...]

// Transform the string into certificate.
String certString = msg.getString();
byte[] certData = certString.getBytes();
ByteArrayInputStream bais = new ByteArrayInputStream(certData);
 
// Fill the first element.
X509Certificate jsseCerts[] = null;
try {
CertificateFactory cf =
 CertificateFactory.getInstance(X.509);
 X509Certificate cert = (X509Certificate)
 cf.generateCertificate(bais);
 jsseCerts =  new X509Certificate[1];
 jsseCerts[0] = cert;
   } catch(java.security.cert.CertificateException e) {
   log(Certificate convertion failed + e );
   }
 
   req.setAttribute(javax.servlet.request.X509Certificate, jsseCerts); 

[...]


   Fredrik Lagerblad
   AU-System AB
   Box 47612,117 94 Stockholm
   Tel. +46-8-5791 1114, Mobil +46-70-305 1114
   Fax. +46-8-19 33 22
   [EMAIL PROTECTED]
   http://www.ausystem.se
 
 

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




Restarting Tomcat Every After Every Update?

2002-08-16 Thread fredrik

Hello,

Do I need to restart tomcat every time I update a class/bean?
This is so frustrating!

/Fredrik

-Original Message-
From: Lihn, Steve [mailto:[EMAIL PROTECTED]]
Sent: Friday, August 16, 2002 1:06 PM
To: 'Tomcat Users List'
Subject: RE: new install - JSP failed.


Thanks.
I mistakenly installed the Java Runtime instead of the SDK.

  Steve Lihn

 -Original Message-
 From: Durham David Cntr 805CSS/SCBE 
 [mailto:[EMAIL PROTECTED]]
 Sent: Friday, August 16, 2002 2:28 PM
 To: Tomcat Users List
 Subject: RE: new install - JSP failed.
 
 
 Did you install the j2sdk ??  Is java_home set?
 
  -Original Message-
  From: Lihn, Steve [mailto:[EMAIL PROTECTED]]
  Sent: Friday, August 16, 2002 12:18 PM
  To: 'Tomcat Users List'
  Subject: new install - JSP failed.
  
  
  Hi,
  I am new to this mailing list and new to Tomcat.
  I just installed the Tomcat 4.0 on my PC.
  It works basically. Servlet also works.
  But the JSP samples are all failing. Does any body know 
 what I missed?
  
  Error like:
  
  Apache Tomcat/4.0.4 - HTTP Status 500 - Internal Server Error
  
  --
  --
  
  
  type Exception report
  
  message Internal Server Error
  
  description The server encountered an internal error 
  (Internal Server Error)
  that prevented it from fulfilling this request.
  
  exception 
  
  javax.servlet.ServletException: sun/tools/javac/Main
  at 
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:481)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
  at
  org.apache.catalina.core.ApplicationFilterChain.internalDoFilt
  er(Application
  FilterChain.java:247)
  at
  org.apache.catalina.core.ApplicationFilterChain.doFilter(Appli
  cationFilterCh
  ain.java:193)
  at
  org.apache.catalina.core.StandardWrapperValve.invoke(StandardW
  rapperValve.ja
  va:243)
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  66)
  at
  org.apache.catalina.core.StandardPipeline.invoke(StandardPipel
  ine.java:472)
  at
  
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
  at
  org.apache.catalina.core.StandardContextValve.invoke(StandardC
  ontextValve.ja
  va:190)
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  66)
  at
  org.apache.catalina.authenticator.AuthenticatorBase.invoke(Aut
  henticatorBase
  .java:475)
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  64)
  at
  org.apache.catalina.valves.CertificatesValve.invoke(Certificat
  esValve.java:2
  46)
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  64)
  at
  org.apache.catalina.core.StandardPipeline.invoke(StandardPipel
  ine.java:472)
  at
  
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
  at
  org.apache.catalina.core.StandardContext.invoke(StandardContex
  t.java:2347)
  at
  org.apache.catalina.core.StandardHostValve.invoke(StandardHost
  Valve.java:180
  )
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  66)
  at
  org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDi
  spatcherValve.
  java:170)
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  64)
  at
  org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReport
  Valve.java:170
  )
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  64)
  at
  org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValv
  e.java:468)
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  64)
  at
  org.apache.catalina.core.StandardPipeline.invoke(StandardPipel
  ine.java:472)
  at
  
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
  at
  org.apache.catalina.core.StandardEngineValve.invoke(StandardEn
  gineValve.java
  :174)
  at
  org.apache.catalina.core.StandardPipeline.invokeNext(StandardP
  ipeline.java:5
  66)
  at
  org.apache.catalina.core.StandardPipeline.invoke(StandardPipel
  ine.java:472)
  at
  
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
  at
  org.apache.catalina.connector.http.HttpProcessor.process(HttpP
  rocessor.java:
  1027)
  at
  org.apache.catalina.connector.http.HttpProcessor.run(HttpProce
  ssor.java:1125
  )
  at java.lang.Thread.run(Unknown Source)
  
  
  root cause 
  
  java.lang.NoClassDefFoundError: sun/tools/javac/Main
  at
  org.apache.jasper.compiler.SunJavaCompiler.compile(SunJavaComp
  iler.java:136)
  at 
  org.apache.jasper.compiler.Compiler.compile(Compiler.java:272)
  at 
  org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:548)
  at
  org.apache.jasper.servlet.JspServlet

Re: Tomcat and static content

2002-07-07 Thread Fredrik Viklund

Kapil Sharma wrote:

 I have got a problem. I am using apache 1.3.26+tomcat 1.3.1. Is there
 any way to know that apache is serving all static content like
 .html/.gif/.jpeg? My virtual host (in apache) is running very slow and
 images are breaking..

I would try these things: (Bear in mind that I am a OpenBSD user and Tomcat
beginner, so this may be completely out of range.

1. Find the problem. Go directly to Tomcat (using its network port), without
passing through the Apache server. If this is faster, the problem is on the
Apache side, if it's still slow, the problem is on the Tomcat side.

2. If the problem is on Tomcat: Are the static pages also parsed by Tomcat. It
should be possible to set some extensions as static content and send them through
the server without parsing them for JSP code etc. I think this is defined in your
web.xml file. (I *said* I'm a beginner:-)

3. Anyway, if the problem can't be fixed in Tomcat, you could set your Apache to
forward only URL:s that end in .jsp to Tomcat.
I use URL rewriting to forward any http://jsp.my.server.com/url.html url to
http://my.server.com:8080/url.html
In that case you do the same, it is easy:
Modify your your Apache httpd.conf under the virutal hosts section for the Tomcat
server:
 RewriteEngine On
 RewriteCondition %{HTTP:Authorization} ^(.*)
 RewriteRule ^(.*\.jsp) http://your.server:8080$1
[e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l,P]

Then Authorization line is only needed if you are using logins or other features
that use HTTP authorization.
The last line is
 RewriteRule ^(.*) (etcetera)
if you want to forward everything to port 8080.

You will of course need to do LoadModule rewrite_module
/usr/lib/apache/modules/mod_rewrite.so or similar earlier in your httpd.conf,
but that is covered elsewhere in the Apache documentation.

Good luck.

/Fredrik




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




Tomcat and WebDAV compatability

2002-07-06 Thread Fredrik Viklund

I have tested Tomcat 4.x with some webdav clients and had some
depressing results.
I can't get it to work with either DreamWeaver or GoLive.

Basically, my question is Is it Tomcat, GoLive and DreamWeaver or
myself that is not supporting WebDAV properly?

* Macromedia Dreamweaver MX: Accessing the webdav directory, it is
*really* slow (Dreamweaver virtually hangs) but after a while the file
list is acquired to Dreamweaver.

* Adobe GoLive 6.0: Basically works but has some pecularities
For all(?) folders it reports the an error: Date and time operations
cannot be performed on this resource. with the description Server
Error: The date and time string (last modified) sent by the server for
resource /test/ is not in ISO8601- or RFC0822-format.. In practice
browsing files and folders works fine.
As soon as a file has been opened or locked/checked-out, it becomes
impossible to write to it unlock it again, because of HTTP Status 423 -
Locked. Trying to unlock a file only tells me that it is already locked
and can't be accessed.

* DAV Explorer: Can't list folder contents. Reading the log file I can
decode that Tomcat claims support for dav version 1 and 2 and the lock
and unlock methods but DAV explorer still can't make anything out of the
information sent from Tomcat.

* Windows 2000 web folders: Works fine

* Litmus (Webdav server protocol compliance test suite): Tomcat passes
12 out of the 13 tests in stage 1. The test that fails is
mkcol_with_body and the failure report is MKCOL with weird body must
fail (RFC2518:8.3.1).

I have tried this using Tomcat-4.0.4/JDK-1.4.0 on Windows 2000 and
Tomcat-4.1.3-beta/JDK-1.3.1 on OpenBSD and get the same results. (Using
a Zope server worked fine with all clients.)

After doing some Googling, I found the following explanation at
http://faqchest.dynhost.com/prgm/tomcat-l/tmct-01/tmct-0111/tmct-04/tmct01110721_30463.html

Subject: Re: Tomcat's WebDAV
From: Remy Maucherat
Date: Wed, 7 Nov 2001 13:08:30 -0800
 Lock/Unlock doesn't seem to be working for me. I can list, add and
remove
 files without a problem, with Web Folders, DAVExplorer, Adobe GoLive
and Cadaver.

 But if I LOCK a file I won't be able to unlock it. All UNLOCK queries
return
 with '423 Locked'. Very weird, I already knew the file was locked
:-).
The UNLOCK will fail unless the client is correctly submitting the
lock-token. One particularity of Tomcat is that is only returns the
real
lock-token in the answer to the original lock request. Many clients
don't
like this, although the behavior is correct (servers are allowed to
obsfucate lock-tokens returned by a PROPFIND).

MS Office and the Slide client should beahave correctly. I know DAV
Explorer
does not. Many other clients may behave ok.

I tried using the Tomcat-Slide package instead, but that proved to be a
really hard task and I never got even read access via WebDAV.
I guess it would be easier if I had an experienced Slide-manager around
:-)

/Fredrik
j

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




Building mod_webapp from sources with Apache 2

2002-04-13 Thread Fredrik Westermarck

Hi!

I have been browsing around all of the Jakarta-site (including the CVS) 
for instructions on how to build mod_webapp 
(jakarta-tomcat-connectors-4.0.2-01) from source with Apache 2.0.x.

All of the documentation I have found so far only covers how to build 
mod_webapp with Apache 1.3.x.

Are there any instructions on how to build mod_webapp with Apache 2.0.x?

Regards,
Fredrik Westermarck


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Folders/Files hidden in Linux but visible through Tomcat/Browser

2002-02-20 Thread Fredrik Liden

Help!

I can't see folder and files that start with a certain word in Linux. There
is no . (dot) in the name.

However, when I run tomcat the folder/files are in the directory where it is
supposed to be.
The files are there but they are invisible.

Is this a virus? Please someone.

[EMAIL PROTECTED]

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: reading content in WEB-INF

2002-02-19 Thread Fredrik Westermarck

Max Z. wrote:
 I am storing a file in the WEB-INF directory and I need to access it with a
 servlet, how would I get to it?
 

Use:

InputStream is =
  getServletContext().getResourceAsStream(/WEB-INF/your.file);


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: JNDIRealm

2002-02-01 Thread Fredrik Westermarck

On Sat, 2 Feb 2002, John Holman wrote:

 Have the proposal been approved by the Tomcat developers, and are there
 any people working on this issue?
 Similar proposals are in the draft functional specification for the JNDI
 realm, and I submitted a patch to the tomcat-dev list earlier today
 that implements the required functionality.

Great!

 You are more than welcome to try it, if you get the chance.

Yes, I'll try it out as soon as possible. I have to setup my
environment so that I can build tomcat from sources first.

-- 
---
Fredrik WestermarckSystemutvecklare/IT-avdelningen
Mälardalens högskola   Tel   +46-21-103162
Box 883Fax   +46-21-101636
721 23 VästeråsEpost [EMAIL PROTECTED]
---


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: JNDIRealm

2002-01-29 Thread Fredrik Westermarck

John Holman wrote:
 
 JNDIRealm works by retrieving the password from the directory server and
 comparing it explicitly with the value given by
 the user. Unfortunately AFAIK this mode of operation will not work with
 eDirectory.

Reading the Realm HOWTO again made me realize that... Why would anyone
want the Realm to get the password from the server instead of doing a
simple LDAP bind?

 There have been proposals (e.g. from me) to enhance JNDIRealm to allow it
 to authenticate the user by binding to the directory server, in the same
 way as auth_ldap. This should work with eDirectory, but isn't available yet.

Have the proposal been approved by the Tomcat developers, and are there
any people working on this issue?

-- 
Fredrik Westermarck

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




JNDIRealm

2002-01-28 Thread Fredrik Westermarck

Hi!

We are going to upgrade to Tomcat and are investigating how to implement
user authentication. Currently we are using the authentication that is
offered in Apache with auth_ldap.

Since Tomcat offers an authentication mechanism (Realms) we would like
to use that functionality. However since we are using Novell NDS
(eDriectory) to store our users and have several NDS servers, we would
like to have Tomcat to authenticate a user against one or more of the
NDS servers. Is this possible?

As far as I can see the JNDIRealm can only handle a single server to
authenticate users against.

-- 
Fredrik Westermarck

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Upgrading from JServ/Apache to Tomcat/Apache

2002-01-15 Thread Fredrik Westermarck

Hi!

We have been using JServ/Apache for a long long time. Since JServ is not
supported anymore we need to upgrade to Tomcat/Apache to be able to use
JSPs.

We want to keep our existing URLs (/servlet/) and have the possibility
to have JSPs in the htdocs folder. We want the following mappings:

/servlet/ - Tomcat
/*.jsp- Tomcat
All of the rest should be served by Apache as defined in httpd.conf.

Question: Which combination of Tomcat/Apache module can be used to
achieve this?
Tomcat 3.2/3.3/4.0? mod_jk/mod_webapp?

-- 
---
Fredrik Westermarck
---

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Jakarta NT SERVICE--- logout USER

2001-12-10 Thread Fredrik Henriksson

JDK1.3.1 has a switch (-Xrs) that, at least by its description, looks like
it would solve the problem.

/Fredrik
- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, December 10, 2001 3:43 PM
Subject: RE: Jakarta NT SERVICE--- logout USER


 This isnt a config issue this is a sun JDK (1.3) issue I had heard that
1.4
 resolves this, try looking there...

 -Original Message-
 From: Catalin [mailto:[EMAIL PROTECTED]]
 Sent: Monday, December 10, 2001 2:55 PM
 To: [EMAIL PROTECTED]
 Subject: Jakarta NT SERVICE--- logout USER


 Hello to everybody!


 I have a jakarta-tomcat-3.3m4 on a Win2k system and I have a problem:
 every times one user of Operating System logout, the service it
 stoppes.:-(
 Where do I need to modify the config so that will not be happens any
 more??

 Thanks!!



 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]

 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: PROBLEMS INSTALLING TOMCAT

2001-11-28 Thread Fredrik Henriksson

My humble guess is that the extra ';' at the end of TOMCAT_HOME and
JAVA_HOME would screw things up.

/Fredrik
- Original Message -
From: Alan Scott [EMAIL PROTECTED]
To: Tomcat Users List [EMAIL PROTECTED]
Sent: Wednesday, November 28, 2001 9:18 PM
Subject: Re: PROBLEMS INSTALLING TOMCAT


 what exactly is the error?
 did you try localhost:8080 or 127.0.0.1:8080 in the web browser?

 if you get a web page then the install went as it should...

 At 03:59 PM 11/28/2001 -0800, you wrote:
 Hello,
 
 
 I installed the jakarta-tomcat-3.3m4 on a win 98 machine.
 I installed jdk1.3.1 in c:\\jdk1.3.1
 I installed the server in c:\\jakarta
 This are my settings from autoexec.bat:
 
 set

path=c:\apache;C:\jdk1.3.1;C:\jdk1.3.1\bin;C:\jdk1.3.1\lib;c:\jakarta;C:\ja
karta\lib\common\servlet.jar
 set JAVA_HOME=C:\jdk1.3.1;
 set TOMCAT_HOME=c:\jakarta;
 SET CLASSPATH=C:\JDK1.3.1
 
 
 
 
 Tahnksfor your answering!!
 
 
 --
 Best regards,
   Catalin  mailto:[EMAIL PROTECTED]
 
 
 
 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]


 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Wrap an HttpServletRequest

2001-11-14 Thread Fredrik Westermarck

Martin van den Bemt wrote:
 
 Pas the request object to that servlet eg
 BlahServlet servlet = new BlahServlet();
 servlet.execute(req, resp);

Why not get a RequestDispatcher and forward (or include) to the other
servlet?

..
  RequestDispatcher rd = request.getRequestDispatcher(pathToServlet);
  rd.forward(request, response); // or rd.include(request, response)
..

Use the setAttribute()-method in the servlet that handles the original
request to add the extra parameters. Then use getAttribute() in the
servlet that you forwarded or included to read the extra parameters.

-- 
Fredrik Westermarck

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Logout with basic autorization

2001-11-14 Thread Fredrik Westermarck

kevin ritter wrote:
 
 Can anyone one verify if this is really the case, that is, to logout with
 BASIC authentication you have to close the browser window? This seems to be
 a little goofy. Are there any work arounds?

The troubles of revoking user credentials when using HTTP-authentication
is documented in the HTTP/1.1 specification (probably 1.0) under
http://www.w3.org/Protocols/rfc2616/rfc2616-sec15.html#sec15.6.

The only reliable way of logging out when you have been authenticated
(if using HTTP-authentication) is to close _all_ of your browser
windows.

-- 
Fredrik Westermarck

--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Images in Tomcat

2001-07-18 Thread Fredrik Liden

I have a navigationbar that changes images when the user moves the mouse
over it.
This navigationbar works and looks normal when viewed on my own computer.
But when I run it through the server the images won't work properly. It
looks pretty messed up to be exact. Anyone know how to get around this?

I'm running Tomcat as a standalone webserver/servletengine

/Fredrik



error 404 R

2001-07-17 Thread Fredrik Liden

Hello, does anyone know why I keep getting the following messages?
I can't find any path in my files that looks like the ones below.
can it bring down the server?
 
I'm using tomcat standalone.
Any feedback would be appreciated
 
2001-07-03 09:48:31 - Ctx( /examples ): 404 R( /examples +
/html/html/Images/RWS
LOGO.gif + null) null
2001-07-03 09:48:38 - Ctx( /examples ): 404 R( /examples +
/html/Images/RWSLOGO.
gif + null) null
2001-07-03 09:48:55 - Ctx( /examples ): 404 R( /examples +
/html/Images/RWSLOGO.
gif + null) null  



error 400 R

2001-07-17 Thread Fredrik Liden

Ctx(  ): 400 R( /) null

I keep getting a LOT of this message.

and sometimes that messages is followed by

- PoolTcpEndpoint: Endpoint ServerSocket[addr=0.0.0.0/0.0.0.
0,port=0,localport=8080] ignored exception: java.net.SocketException:
Connection
 reset by peer - java.net.SocketException: Connection reset by peer
at java.net.PlainSocketImpl.socketAccept(Native Method)
at java.net.PlainSocketImpl.accept(PlainSocketImpl.java, Compiled
Code)
at java.net.ServerSocket.implAccept(ServerSocket.java, Compiled
Code)
at java.net.ServerSocket.accept(ServerSocket.java, Compiled Code)
at
org.apache.tomcat.service.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoin
t.java, Compiled Code)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java,
 Compiled Code)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java
, Compiled Code)
at java.lang.Thread.run(Thread.java, Compiled Code)
 

Does anyone know what causes it? I'd like to see something else on the
output screen besides these error messages. I have the default Serve.xml
settings. Everything is relative to the example folder.

/Fredrik



404 R

2001-07-03 Thread Fredrik Liden

Hello, does anyone know why I keep getting the following messages?
I can't find any path in my files that looks like the ones below.
can it bring down the server?
 
I'm using tomcat standalone.
Any feedback would be appreciated
 
2001-07-03 09:48:31 - Ctx( /examples ): 404 R( /examples +
/html/html/Images/RWS
LOGO.gif + null) null
2001-07-03 09:48:38 - Ctx( /examples ): 404 R( /examples +
/html/Images/RWSLOGO.
gif + null) null
2001-07-03 09:48:55 - Ctx( /examples ): 404 R( /examples +
/html/Images/RWSLOGO.
gif + null) null  



Determining if Tomcat is running

2001-07-02 Thread Fredrik Liden

hey all,

Is it possible to determine if Tomcat is running?

I'm using Tomcat as a standalone server.
Occasionally Tomcat goes down and the page will not display. It's just gets
stuck.
Is there some way I can redirect a user if the servletEngine goes down?

Any suggestions would be greatly appreciated



RE: Determining if Tomcat is running

2001-07-02 Thread Fredrik Liden

I'm not really familiar with Linux or the ps command.
Could you give a short description of what this does:

ps -aux --cols 500 |grep $TOMCAT_HOME

Thanks!

-Original Message-
From: Tim O'Neil [mailto:[EMAIL PROTECTED]]
Sent: Monday, July 02, 2001 4:15 PM
To: [EMAIL PROTECTED]
Subject: Re: Determining if Tomcat is running


At 03:36 PM 7/2/2001, you wrote:

Probably not foolproof, but off the top of my head:

  ps -aux --cols 500 |grep $TOMCAT_HOME

ps aux --- BSD options. You'll want ef for
SysV variants like Linux.

I KNOW, Linux isn't a sys V kernel, but the ports,
like ps seem to be.



Jsp question

2001-06-28 Thread Fredrik Liden

Let's say I have multiple forms on a page.

Does anyone know if I can retrive the name of the form that was submitted
using the request object? or if there is any other way to find out.

Thanks!

Fredrik



Internal Servlet Error

2001-06-20 Thread Fredrik Liden

Hello I created a .jsp file that worked fine on JSWDK

Recently I upgraded to Tomcat 3.2.2 and now when I click on the JSP file I
get the following message:

Internal Servlet Error:

org.apache.jasper.JasperException: Unable to compile class for JSPerror:
Can't write:
/usr/local/jakarta-tomcat-3.2.2/work/localhost_8080%2Fexamples/html/html/For
ms/_0002fhtml_0002fhtml_0002fForms_0002fForms_0002ejspForms_jsp_2.class
Note:
/usr/local/jakarta-tomcat-3.2.2/work/localhost_8080%2Fexamples/_0002fhtml_00
02fhtml_0002fForms_0002fForms_0002ejspForms_jsp_2.java uses or overrides a
deprecated API.  Recompile with -deprecation for details.
1 error, 1 warning


How can I recompile a jsp file and find out what I need to modify?

Thanks

Fredrik



Custom Error Document

2000-10-31 Thread Fredrik Stenberg

Is it possible to redirect to a custom error page when recieving an Error
500 from Tomcat?

Eg. something equal to Apache's ErrorDocument directive.

/Fred



RE: Custom Error Document

2000-10-31 Thread Fredrik Stenberg

I am using apache but I can not get it to serve my custom Error

I have included the:

ErrorDocument 500 "The server made a boo boo.
in my httpd but still I only get the stack-trace from tomcat with Error: 500

/Fred

 -Original Message-
 From: Sergio Stateri Jr [SMTP:[EMAIL PROTECTED]]
 Sent: den 31 oktober 2000 12:34
 To:   [EMAIL PROTECTED]
 Subject:  RES: Custom Error Document
 
 Yes, but only if there's a web server calling Tomcat (Apache). Put the
 ErrorDocument command in Apache's httpd.conf :
 
 VirtualHost 192.168.0.13:80
 ServerName www.fotoptica.com.br
 DirectoryIndex index.jsp index.html
 ApJServMount / ajpv12://192.168.0.13:8007
 ErrorDocument 500 /erros/error500.html
 /VirtualHost
 
 
 
 Sergio Stateri Jr
 [EMAIL PROTECTED]
 Tesla Tecnologia
 Sao Paulo (SP) Brazil
 
 -Mensagem original-
 De: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]Em nome de Fredrik Stenberg
 Enviada em: Terça-feira, 31 de Outubro de 2000 07:04
 Para: '[EMAIL PROTECTED]'
 Assunto: Custom Error Document
 
 Is it possible to redirect to a custom error page when receiving an Error
 500 from Tomcat?
 
 Eg. something equal to Apache's ErrorDocument directive.
 
 /Fred
 ___
 tomcat-users mailing list
 [EMAIL PROTECTED]
 https://mailman.real-time.com/mailman/listinfo/tomcat-users