Hi,
It's in the HTTP RFC (2616 I believe is the RFC number, google for it).

Yoav Shapira
Millennium Research Informatics


>-----Original Message-----
>From: Jerry Miernik [mailto:[EMAIL PROTECTED]
>Sent: Thursday, June 10, 2004 3:03 PM
>To: Tomcat Users List
>Subject: Works! RE: 2nd inquiry: how to - programmatically -
authenticate
>oneself as Tomcat manager?
>
>  Jake,
>  This works! How did you come to know that?
>  Is there a doc I should have read to know?
>  Thanks,
>  Jerry.
>
>
>-----Original Message-----
>From: Jacob Kjome [mailto:[EMAIL PROTECTED]
>Sent: Thursday, June 10, 2004 1:44 PM
>To: Tomcat Users List
>Subject: Re: 2nd inquiry: how to - programmatically - authenticate
oneself
>as Tomcat manager?
>
>Quoting Bill Barker <[EMAIL PROTECTED]>:
>> 1)  Assuming boring system encodings, and something to do Base64
>encoding:
>>    String creds = username+":"+password;
>>    String b64creds = Base64Util.encode(creds.getBytes());
>>    tmc.addRequestProperty("Authorization","Basic "+b64creds);
>>
>> 2) Not with Basic.  You might be able to rig something with Form.
>>
>
>That's not true.  You can do:
>
>http://username:[EMAIL PROTECTED]/
>
>so:
>
>URL tomcatMgr =
>     new
>URL("http://manager:[EMAIL PROTECTED]:8080/manager/undeploy?path=/an
y");
>
>Jake
>
>>
>> "Jerry Miernik" <[EMAIL PROTECTED]> wrote in message
>> news:[EMAIL PROTECTED]
>exchange.amer.unity.cisco.com...
>>   The question is related to undeploying a webapplication
>>   from a Java code. A connection to tomcat manager using
>>   ....
>>   URL tomcatMgr =
>>     new URL("http://localhost:8080/manager/undeploy?path=/any";);
>>   URLConnection tmc = tomcatMgr.openConnection();
>>   ....
>>
>>   results in:
>>   java.io.IOException:Server returned HTTP response code: 401
>>
>>   The questions:
>>   1. Is there a way to deliver - programmatically - username
>>      and password for the undeploy to take effect?
>>
>>   2. Could the username and password be parameters in the
>>      undeploy request? Or an earlier request?
>>
>>   3. This Java program is trying to undeploy itself, inside
>>      a jspInit() method. Is this technically possible?
>>      (do not see why not, except for the problem with user
>>       name and password).
>>
>>   Thanks,
>>   Jerry.
>>
>> ---------------------------------------------------------------------
>> 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]




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]

Reply via email to