Skip to content

Conversation

@omarkj
Copy link

@omarkj omarkj commented Jan 26, 2026

Add a new strictAuthMethod configuration option to enforce that clients must specify their authentication method. When enabled, authentication requests without an explicit method will immediately fail with "Authentication method missing" instead of attempting to authenticate with all configured providers.

This improves security by preventing unintended authentication fallback behaviour when operators want to require specific authentication methods for their deployment.

Main Issue: #25184

  • doc
  • doc-required
  • doc-not-needed
  • doc-complete

…tion method

Add a new strictAuthMethod configuration option to enforce that clients
must specify their authentication method. When enabled, authentication
requests without an explicit method will immediately fail with
"Authentication method missing" instead of attempting to authenticate
with all configured providers.

This improves security by preventing unintended authentication fallback
behavior when operators want to require specific authentication methods
for their deployment.
@github-actions
Copy link

@omarkj Please add the following content to your PR description and select a checkbox:

- [ ] `doc` <!-- Your PR contains doc changes -->
- [ ] `doc-required` <!-- Your PR changes impact docs and you will update later -->
- [ ] `doc-not-needed` <!-- Your PR changes do not impact docs -->
- [ ] `doc-complete` <!-- Docs have been already added -->

@github-actions github-actions bot added doc-not-needed Your PR changes do not impact docs and removed doc-label-missing labels Jan 26, 2026
Copy link
Member

@nodece nodece left a comment

Choose a reason for hiding this comment

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

LGTM. We just need a PIP for this one before we merge, because this is an important change.

@lhotari
Copy link
Member

lhotari commented Jan 27, 2026

Thanks for the contribution @omarkj. Yes, a PIP would be useful in documenting the change.

Some questions:

  1. does this require also a similar change for
  • the Pulsar binary protocol?
  • the Pulsar Proxy?
  1. Since the client can specify the authentication method, how does this improve security?
  • Just wondering if it be useful to limit authentication methods for a particular "advertised listener"?
    • Pulsar broker can bind to multiple addresses/ports and limiting the authentication method for an external port binding could be an useful addition

@omarkj
Copy link
Author

omarkj commented Jan 27, 2026

I will get a PIP out if relevant.

@lhotari Regarding your questions:

  1. does this require also a similar change for
  • the Pulsar binary protocol?

I believe the Pulsar Protocol authentication only tries the specified authentication provider unlike the HTTP authentication which iterates through all available providers if none is specified.

  • the Pulsar Proxy?

This is a good point, if the proxy is authenticating HTTP requests then yes, might be useful there.

  1. Since the client can specify the authentication method, how does this improve security?

This should make it harder to probe the system for possibly misconfigured authentication providers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc-not-needed Your PR changes do not impact docs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants