-
Notifications
You must be signed in to change notification settings - Fork 63
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
Add kpro_auth_backend:auth/8 to support passing handshake vsn #102
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. I agree that passing the version in a map would be more future safe so I think we can go for that option. Let @zmstone have a look as well before you merge as he is more familiar with the code.
I think this is good. |
To be clear, are we in favor of add |
f926080
to
e79df05
Compare
Sorry. I meant this current impl looks good. |
@zmstone sounds good. I think all changes that need to be made have been made, but let me know if other wise. Will squash and merge on your approval. |
released 4.1.0 |
This PR changes
kpro_auth_backend
to exportauth/8
vsauth/7
to support passing the handshake version to a callback module.auth/8
will check to seeCallbackModule
exportsauth/7
, if it does notauth/6
on the callback module will be called for backwards compat.As for the placement of the handshake vsn arg in function head, no strong feelings. I would even go so far as to suggest passing a map or a record to the callback module, but that doesn't have to be done in this PR either, unless we're open to the idea and would like to avoid future churn. An example of what the might look like can be seen here :
https://github.com/kafka4beam/brod_gssapi/blob/51be03dcbcaa48cd77edcda3e8e75ca5e20123e8/src/brod_gssapi.erl#L94
. However, we'd want to support aprivate
key where callback modules can stuff in k/vs relevant to their context.