aspose file tools*
The moose likes General Computing and the fly likes Can I?? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » General Computing
Bookmark "Can I??" Watch "Can I??" New topic
Author

Can I??

Nasser Aboobaker
Ranch Hand

Joined: Dec 06, 2000
Posts: 104
Hi,
I have a password protected folder in my webserver. Can I pass the password while calling a file from that folder through http?
Operating system. windows2000
Thanks
Nazer
SJ Adnams
Ranch Hand

Joined: Sep 28, 2001
Posts: 925
oh yes,
cant remember exactly, but you need base64 encode the username and password and stick a colon ':' between the two. Then set a header field with this value.
Can't remember the header name? you know google don't you??
Nasser Aboobaker
Ranch Hand

Joined: Dec 06, 2000
Posts: 104
Hi,
Thanks Lee.
Can some one be more specific with this?
Nazer
SJ Adnams
Ranch Hand

Joined: Sep 28, 2001
Posts: 925
GET /MyPages/MySecret/file.txt HTTP/1.0\r\n
Authenticate: base64-encoded-string\r\n
where base64-encoded-string = "user:pass" encoded as base64 (no quotes)
[ September 13, 2002: Message edited by: Simon Lee ]
Nasser Aboobaker
Ranch Hand

Joined: Dec 06, 2000
Posts: 104
Thanks Lee.
Nazer
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Can I??