You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@sling.apache.org by Günther Schmidt <gu...@web.de> on 2012/05/09 04:01:17 UTC
Re: Trying to post via HttpClient - SOLVED
Hi,
as it turns out HTTPPosts to Apache Sling require preemptive
authentication, which the HttpClients 4x (Apache Http Components) do not
do or provide out of the box.
You can have a look here:
http://mail-archives.apache.org/mod_mbox/sling-users/201005.mbox/%3CAANLkTilM7xCnjubIfU-QsuRpINR-Kt8AAyLpz6c3trDZ@mail.gmail.com%3E
which points out the problem
and here for the workaround
http://hc.apache.org/httpcomponents-client-ga/tutorial/html/authentication.html#d5e1031
I applied this solution and it now works.
Günther