Syko9000 wrote:
Syko9000 wrote:

Daniel Fournier wrote:

Syko9000 wrote:

How do I download a page using SSL? in side a program using XPCOM or something similar... not from the browser

I'm hoping that is possible

TIA

Syko

You can use nsIXMLHTTPRequest interface:
<http://lxr.mozilla.org/seamonkey/source/extensions/xmlextras/base/public/nsIXMLHttpRequest.idl>


and send your SSL headers directly, if you know how to process them.

Daniel

is there another way of doing this? because, I'm sending a 'PROPFIND / HTTP/1.1' and I get back an 'HTTP/1.1 302 Object Moved' which is fine... but the XMLHttpRequest Object then takes it upon itself to request it again from the new location... but it requests using GET... not PROPFIND ... unless there is a way to stop that ... I need a different way

TIA

Syko


and it changed the user-agent and re-added all the useless (in this context) headers.... seems like a really stupid way for it to be acting


Syko



Mozilla's HTTP implementation conforms with the non-standard, but widely implemented behavior, that the HTTP request method "should be" GET when following a 302. To force Mozilla to preserve the original request method, the server can send a 307 instead of a 302. That is, of course, only an option if you have control over the server/site.

As for the headers not being added back in... that is reasonably a bug in the implementation. The HTTP layer should preserve the request headers from the original request. I've filed bug 216828 for this issue.

As for being able to disable the auto-redirect behavior when using XMLHttpRequest, it doesn't look like there is a solution there. If however you are using the Mozilla Networking Library (aka Necko) directly, then there is a way to disable the auto-redirect behavior.

Darin


Reply via email to