There are 2 updates, 2 comments.
 
 
XWiki Platform / cid:jira-generated-image-avatar-78d72093-c104-43e7-a0b2-bd7f3d6ca4d1 XWIKI-21879 Open

Force preemptive authentication in $xwiki.getURLContent()

 
View issue   ยท   Add comment
 

2 updates

 
cid:jira-generated-image-avatar-4d38a6eb-f83f-4d5f-b994-674439241f9d Changes by Thomas Mortagne on 15/Nov/24 09:24
 
Summary: Force preemptive authentication in $xwiki.getURLContent() does not forward credentials
Issue Type: Bug Improvement
 
 

2 comments

 
cid:jira-generated-image-avatar-4d38a6eb-f83f-4d5f-b994-674439241f9d Thomas Mortagne on 15/Nov/24 09:23
 

So I am pretty sure that the Apache HttpClient ignores the credentials given.

I don't think it ignores them, but by default the HTTP client is sending the credentials when asked for them (when getting a 401).

What you seems to want (and what you apparently did in the pull request) is to force preemptive authentication.

 
cid:jira-generated-image-avatar-4d38a6eb-f83f-4d5f-b994-674439241f9d Thomas Mortagne on 15/Nov/24 09:25
 
bq. So I am pretty sure that the Apache HttpClient ignores the credentials given.

I don't think it ignores them, but by default the HTTP client is sending the credentials when asked for them (when getting a
[ 401 |https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/401] ).

What you seems to want (and what you apparently did in the pull request) is to force preemptive authentication.