Skip to content

Enhancement: Introduce SASLMechanism Type to Avoid Case Sensitivity Issues #1744

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
seeun0210 opened this issue Mar 15, 2025 · 0 comments · May be fixed by #1745
Open

Enhancement: Introduce SASLMechanism Type to Avoid Case Sensitivity Issues #1744

seeun0210 opened this issue Mar 15, 2025 · 0 comments · May be fixed by #1745

Comments

@seeun0210
Copy link

seeun0210 commented Mar 15, 2025

Is your feature request related to a problem? Please describe.
There is currently no dedicated type provided for the mechanism, which leads to confusion regarding case sensitivity. For example, when using the SHA-SCRAM-512 mechanism, specifying it in uppercase resulted in an authorization error.

Describe the solution you'd like
I propose to introduce a dedicated type (e.g., SASLMechanism) for the mechanism field in KafkaJS. This change would enforce valid mechanism values and prevent case sensitivity issues. Alternatively, updating the documentation to specify that the mechanism must be provided in lowercase could also resolve the issue. Links to similar solutions in other Kafka clients or relevant KIPs would be valuable references.

Additional context
I encountered an authorization error when the mechanism was specified in uppercase, but switching to lowercase resolved the issue. This enhancement would help prevent similar errors in the future and improve overall type safety.
use type

@seeun0210 seeun0210 linked a pull request Mar 15, 2025 that will close this issue
5 tasks
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 a pull request may close this issue.

1 participant