You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Paul Summers <pa...@gmail.com> on 2004/11/05 17:07:33 UTC

authentication in virtual host redirecting to wrong index.jsp

I've just setup a new website as a subdomain of my primary website. My
server setup contains Apache fronting Tomcat 4.x on a Unix server. I'm
directing all traffic that goes to the Apache webserver to the Tomcat
server and setting up my subdomains in the server.xml file. This all
works fine except that the application on my subdomain uses form
authentication and after a successful login, the redirect goes to the
default Tomcat index.jsp file rather than the default index.jsp file
for the application as its supposed to. The index.jsp page for the app
is in the root dir of the app folder.

If I don't configure the app as a subdomain, it works fine but as soon
as I change the config to use the subdomain, it redirects to the wrong
page.

Some other info: 
Struts-based
Jdk 1.4
MySQL db

Below is the server.xml host config for my subdomain:

<Host name="securecoin.outernett.com" debug="0"
appBase="webapps/securecoin"  unpackWARs="true" autoDeploy="true">
                <Logger
className="org.apache.catalina.logger.FileLogger" directory="logs" 
prefix="localhost_log." suffix=".txt" timestamp="true"/>
				
	<!-- context resources for application -->
                <Context path="" docBase="" debug="999"
reloadable="true" crossContext="true">

                

                    <Realm
className="org.apache.catalina.realm.JDBCRealm" debug="999"
                            driverName="com.mysql.jdbc.Driver"
                           
connectionURL="jdbc:mysql://localhost:3306/myapp?user=dbUname&amp;password=dbpass"
                            userTable="userTable"
userNameCol="usernameField" userCredCol="password"
                            userRoleTable="userRoleTable"
roleNameCol="userRoleField"/>
                </Context>
				
</Host>
****************************************
And my web.xml auth config:
    <!-- Define the Login Configuration for this Application -->
    <login-config>
        <auth-method>FORM</auth-method>
        <realm-name>Secure Coin Invoice Application</realm-name>
        <form-login-config>
            <form-login-page>/login/login.jsp</form-login-page>
            <form-error-page>/login/error.jsp</form-error-page>
        </form-login-config>
    </login-config>

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


RE: Tomcat not starting...Tomcat4.1.30

Posted by "Filip Hanik (lists)" <de...@hanik.com>.
look at all the logs files, there is always something in there,
if you are running on windows, go to the bin directory in a dos prompt and
type "catalina.bat run"
and see why its failing,

and also, get yourself a version control system, that way you won't lose
data :)

Filip

-----Original Message-----
From: Shilpa Nalgonda [mailto:snalgonda@mypublisher.com]
Sent: Sunday, November 07, 2004 12:07 PM
To: Tomcat Users List
Subject: Tomcat not starting...Tomcat4.1.30


Hi My Tomcat instance is so badly messed up , i am not able to start it...at
all...while i was redeploying my app , it gave me some email related classes
not found error...so i copied all the relevant jar into Tomcat/common/lib
directory...Then it gave me some other other, so to eliminate the problem, i
removed those jars from common/lib and thats it..from then on Tomcat is not
starting...nothing in logs...and says exception starting up...i tried so
many things but the console is not coming up...I just dowmloaded new Tomcat
version in other diretory, did not uninstall the old one , even the new
Tomcat is coming up.. do i have to uninstall the old one before the new
install?...i am afraid that i loose all my old stuff.



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.786 / Virus Database: 532 - Release Date: 10/29/2004

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.786 / Virus Database: 532 - Release Date: 10/29/2004


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


Tomcat not starting...Tomcat4.1.30

Posted by Shilpa Nalgonda <sn...@mypublisher.com>.
Hi My Tomcat instance is so badly messed up , i am not able to start it...at
all...while i was redeploying my app , it gave me some email related classes
not found error...so i copied all the relevant jar into Tomcat/common/lib
directory...Then it gave me some other other, so to eliminate the problem, i
removed those jars from common/lib and thats it..from then on Tomcat is not
starting...nothing in logs...and says exception starting up...i tried so
many things but the console is not coming up...I just dowmloaded new Tomcat
version in other diretory, did not uninstall the old one , even the new
Tomcat is coming up.. do i have to uninstall the old one before the new
install?...i am afraid that i loose all my old stuff.



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