Skip to content

Negotiate/NTML, only enable to allowed origins - #23012

Closed
icing wants to merge 2 commits into
curl:masterfrom
icing:negotiate-only-allowed
Closed

icing wants to merge 2 commits into
curl:masterfrom
icing:negotiate-only-allowed

Conversation

@icing

@icing icing commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

Restrict Negotiate/NTML to only "allowed" origins, irregardless of where credentials are sourced from.

Restrict Negotiate/NTML to only "allowed" origins, irregardless
of where credentials are sourced from.
@github-actions github-actions Bot added the HTTP label Sep 21, 2026
@bagder
bagder requested a balanced review from Copilot September 21, 2026 12:20

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

The new security boundary lacks cross-origin regression coverage for both authentication methods.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 1 Medium severity

Open (1)
What changed in this PR

Restricts origin Negotiate and NTLM authentication to explicitly allowed hosts, preventing credential forwarding across redirects.

Changes:

  • Guards Negotiate and NTLM header generation by origin authorization.
  • Marks blocked authentication attempts complete.
File Description
lib/​http.c Enforces origin checks for Negotiate and NTLM authentication.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread lib/http.c
Comment on lines +694 to +695
(!proxy && !Curl_checkheaders(data, STRCONST("Authorization")) &&
Curl_auth_allowed_to_host(data))) {
@bagder bagder closed this in 557a52f Sep 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

3 participants