tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tom Drake" <...@pobox.com>
Subject Re: Programmatic login with Tomcat 4.0.1
Date Fri, 04 Jan 2002 17:22:51 GMT
Sergei:

Do you need to programmatically log in as a 'client' (e.g.
from a different JVM)?

If so, you will need to open an HttpUrlConnection with a url
that points to an appropriate page on your tomcat server.

Apache SOAP provides a nicelittle Http Tunneling tool that will
help you discover the details of what you need to send to Tomcat
(over an HTTP connection). Download Apache SOAP from
xml.apache.org. You don't need to 'install' it. The following
link explains how to use this tool:
   http://xml.apache.org/soap/docs/index.html

Start the tunnel gui, point your brower at it, and 'login' to your
web site. The tunnel gui will display all request and response
data. All that's left is to write code that sends the same
data that your browser did, and that knows how to deal with
the responses coming from tomcat.

Regards,

Tom Drake


----- Original Message -----
From: "Sergei Batiuk" <Sergei.Batiuk@Damen-Okean.com>
To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
Sent: Friday, January 04, 2002 5:48 AM
Subject: RE: Programmatic login with Tomcat 4.0.1


| Well, but what about programmatic login, i. e. something like
|
|   Context ctx = new InitialContext();
|   UserManager um = ( UserManager )ctx.lookup( "java:comp/UserManager" );
|   um.login( login, password );
|
| Does Tomcat have an API similar to this? The thing is I have a login form
on
| my first page, where a user should login to access protected functions
(they
| are not displayed by default, and become available only after a user has
| logged in).
|
| -----Original Message-----
| From: Ing. Gabriel Gajdos [mailto:Gabriel.Gajdos@ses.sk]
| Sent: Friday, January 04, 2002 3:24 PM
| To: tomcat-user@jakarta.apache.org
| Subject: RE: Programmatic login with Tomcat 4.0.1
|
|
| If you use BASIC authentication, user/password are contained in the
| "Authorization" HTTP 1.1 Header (in Base64 encoded form).
| Never tried, but should work when supplying correct data into your HTTP
| request (including headers).
|
| | How do I programmatically login into TC 4.0.1?
| |
| | Sincirely,
| | Sergei Batiuk.
|
|
| --
| To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
| For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
| Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>
|
|
|
| --
| To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
| For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
| Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>
|
|
|


--
To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>


Mime
View raw message