Skip to content

Fix #3244: http-sink does not send the Authorization header of the incoming message - #3245

Open
davsclaus wants to merge 2 commits into
apache:mainfrom
davsclaus:ci-issue-3244
Open

davsclaus wants to merge 2 commits into
apache:mainfrom
davsclaus:ci-issue-3244

Conversation

@davsclaus

Copy link
Copy Markdown
Contributor

Fixes #3244.

http-sink sent an Authorization or Proxy-Authorization header that was already on the message, so behind webhook-source the credential of the caller went on to the target service, and with a login configured on the Kamelet the header of the message was sent instead of that login.

Changes

  • http-sink removes Authorization and Proxy-Authorization from the message before the call, next to the headers it already removes (CamelHttpUri, ...). The login comes only from authUsername/authPassword, authBearerToken or the OAuth 2 options.
  • The description says so, and points to the http component for a token that differs for each message.

Tests

  • HttpSinkAuthorizationTest runs http-sink against a local server with both headers on the message: without a login nothing is sent, and with a preemptive Basic login the configured login is sent. Both fail on main (the server gets Bearer caller-token).
  • ./mvnw clean install passes.

Upgrade

A flow that set Authorization before http-sink on purpose now uses the login options, or the http component. To be added to the upgrade notes (#3190).

Claude Code on behalf of Claus Ibsen

🤖 Generated with Claude Code

davsclaus and others added 2 commits November 18, 2026 22:34
…the incoming message

http-sink removes the Authorization and Proxy-Authorization headers of
the message before the call, so a credential that came with the message
is not sent on, and the login configured on the Kamelet is not replaced
by it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Claus Ibsen <claus.ibsen@gmail.com>
Signed-off-by: Claus Ibsen <claus.ibsen@gmail.com>

# Conflicts:
#	kamelets/http-sink.kamelet.yaml
#	library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
#	library/camel-kamelets/src/main/resources/kamelets/http-sink.kamelet.yaml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

http-sink: do not send the Authorization header of the incoming message, the login comes from the options

1 participant