tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sugata Sen Mazumdar" <s_s...@vsnl.net>
Subject Re: SSL Redirect To Port 80
Date Wed, 11 Jul 2001 11:27:49 GMT
Dear Jim,
I'm Sugata. I do not have any clue regarding yr query and so am sorry that I
cannot be of any help.But I'm having a problem since a month and am writing
to u since I'm using the same system ( Tomcat 3.2.1 standalone on Windiws
98 ). Here goes :

java error in database access
>
>
>
> i have been facing a problem in tomcat which i could not
> solve may be due to being a "first time user" . i will be
> pleased if u could tell me the source of this problem.
> i have a login page where the user enters username and
> password in 2 text fields(user & pwd).the form action leads
> to login.jsp file.if both are found in the table "login"
> located in Oracle8.0.4(personal edition), then the user is
> greeted by his username. else error msg is shown.when i used
> JdbcOdbcDriver the output was as expected.but immediately
> after the output page was displayed,an illegal operation
> msgbox was shown by java.this error does not occur
> sometimes.but whenever i stop tomcat and restart it,and acces
> my login page the error appears again.the error looks like
> the following:
>
> [
> JAVA caused an invalid page fault in
> module <unknown> at 0000:08412f90.
> Registers:
> EAX=083105d8 CS=0177 EIP=08412f90 EFLGS=00010297
> EBX=08310908 SS=017f ESP=050dfd2c EBP=050dfd4c
> ECX=00000000 DS=017f ESI=08310140 FS=3ca7
> EDX=08310140 ES=017f EDI=00000000 GS=0000
> Bytes at CS:EIP:
>
> Stack dump:
> 1f7025d1 004151d0 00000000 01950000 007b1ec0 00679470
> 00000000 00000000 050dfda4 1f702505 08310140 00000000
> 00000010 019512e8 007b1ec0 50472958
> ]
> my classpath has tomcat_home,java_home,and
> c:\jdk1.2.2\lib\tools.jar set appropriately
> i am using Windows98 machine with 64mb ram,433mhz and with
> initial memory set to 3072(thru dos window properties--memory tab).
>
> i have tried in debugging by putting System.out.println()
> statements but to no avail.
>
> i am enclosing the login.jsp file i used.
> eagerly awaiting ur comments.
>
> login.jsp:
>
> <%@ page session="true"
> import="java.sql.*,sun.jdbc.odbc.*,java.io.*" %>
>
>
> <%
> String s1=request.getParameter("user");
> String s2=request.getParameter("pwd");
> String upwd=null;
> try{
>
> if(s1.length()==8 && s2.length()==6)
> {
>    System.out.println("loading driver");
> Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
>        System.out.println("creating connection");
> Connection
> con=DriverManager.getConnection("jdbc:odbc:login","scott","tiger");
>        System.out.println("creating statement");
> Statement stmt=con.createStatement();
>
>        System.out.println("executing query");
> ResultSet rs=stmt.executeQuery("select
> password from login where username='"+ s1+"'");
>        System.out.println("checking if rs is null");
> if(rs!=null)
>    {
>                System.out.println("while rs exists");
>            while(rs.next())
>            {
>
> System.out.println("retrieving password");
>                upwd=rs.getString("password");
>            }
>    }
>        System.out.println("closing connection");
>    con.close();
>            System.out.println("checking if upwd is null");
>        if(upwd!=null)
>        {
>                System.out.println("checking if
> upwd=s2");
>            if(s2.equals(upwd))
>            {
>                    System.out.println("if
> upwd=s2");
>
> out.println("Welcome Back to this site "+s1);
>            }
>
>
>            else
>            {
>                    System.out.println("if
> upwd not equal to s2");
>                out.println("Incorrect
> password");
>            }
>
>        }
>     else
>        {
>                System.out.println("if upwd is
> null");
>            out.println("Incorrect
> username ");
>        }
>
>
>
>
>
>
> }
> else
> {
>        System.out.println("if entered
> username/password are not valid");
>    out.println("Invalid no. of characters in username/password");
> }
> }
> catch(Exception ex){System.out.println("inside catch"+ex);}
> System.out.println("end of jsp");
>
> %>

----- Original Message -----
From: Jim Prior <Jim_Prior@PacBell.Net>
To: Tomcat <tomcat-user@jakarta.apache.org>
Sent: Wednesday, July 11, 2001 10:26 AM
Subject: SSL Redirect To Port 80


> Hi,
>
> I'm running Tomcat 3.2.1 standalone on Windows 98.
>
> Using a "normal" HTTP connector, I can enter http://server/ on my browser
> and be successfully redirected to http://server/index.html
>
> However, if I use SSL, https://server/ will be redirected to port 80
rather
> than 443.  If I use https://server/index.html I connect (via SSL at port
> 443) no problem.
>
> The best clue I've found on the archive is:
>
> http://w4.metronet.com/~wjm/tomcat/2000/Sep/msg00576.html
>
> But, the "secure" parameter doesn't have any effect.
>
> Any suggestions as to where I should look next?
>
> IATY.
>
>
>


Mime
View raw message