-
Notifications
You must be signed in to change notification settings - Fork 150
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 callback SASL_CB_SERVER_CHANNEL_BINDING #824
Conversation
@GuidoKiener: I only discover this PR today! :) No three possibilities? cc: @cyrusimap team, @aamelnikov. |
|
The patches look OK but I think the example should be attached in a doc or README or something. The usage is not at all obvious without the example. |
I agree that an example or good README is always helpful. I also did not find a real SCRAM example in this repo with openssl and real channel binding like "tls-unique". Since I got no feedback about this patch for five months, I thought that nobody is interested in this security extension. Line 445 in 0310178
Does it work for you when I provide this example within two weeks? |
That would be great, thank you very much! |
8950de5
to
7632d01
Compare
Provide a callback function to change the channel binding type of servers (e.g. "tls-server-end-point" instead of "tls-unique") during authentication of secure mechanisms like GS2-KRB5-PLUS or SCRAM-SHA-256-PLUS. The callback is used by the plugins SCRAM and GS2 when the desired binding type of the client does not match the binding type set with property SASL_CHANNEL_BINDING. A server can check the requested type of channel binding and overwrite the current channel binding data with the property SASL_CHANNEL_BINDING before the authentication proceeds. Issue cyrusimap#823 Signed-off-by: Guido Kiener <[email protected]>
7632d01
to
019ebb4
Compare
With the callback SASL_CB_SERVER_CHANNEL_BINDING a server can change the channel binding data to the desired channel binding type of the client. sample/client.c Select the option -d or -D to use the channel binding type "tls-server-end-point". Or select the option -c or -C to use the channel binding type "tls-unique". Options -C or -D force client and server to use channel binding. sample/server.c select option -c to activate channel binding type "tls-unique". Option -C forces clients to use channel binding. Via callback "my_select_binding" the server changes the binding type to "tls-server-end-point" if required. Note that client/server must use the binding type: - "tls-exporter" for TLS 1.3 - "tls-unique" for TLS 1.2 - "tls-server-end-point" works for TLS 1.2 and 1.3 Issue cyrusimap#823 Signed-off-by: Guido Kiener <[email protected]>
019ebb4
to
2835cc1
Compare
@hyc , @quanah : A sample code is now provided. Here is an output when the client selects option -D with type 'tls-server-end-point':
Does it solve your issue #800 ? |
Thank you very much! We will look at this as soon as we can, real life having some impact atm. |
@quanah: Can you look this PR? |
@hyc: Can you look/merge this PR? Note that @GuidoKiener has updated this PR after @aamelnikov comments. Thanks in advance. |
Thanks to @hyc for your verification! Dear @cyrusimap team, @brong, @marclaporte, @rsto, @elliefm, @ksmurchison, @wolfsage, @dilyanpalauzov, .. Who can confirm and merge? @quanah has left the team, I suppose, nothing since several months. @GuidoKiener has done a lot of work and needs to finish the support into cyrus-imapd which is linked to cyrus-sasl. Note: Debian 13 (every 2 years) will arrive soon, the new version (2.20) must be created before the freeze. cc: @aamelnikov. |
@hyc: Thanks a lot for all your reviews, and merging! :) @GuidoKiener: What are next steps? |
@hyc: Thank you very much for merging.
@Neustradamus: Next steps are to revise my example for cyrus-imapd.
We should continue this discussion in cyrus-imapd #4191 and I will close this issue as soon as cyrus-sasl 2.2.0 is released. |
@GuidoKiener, @hyc: I think it is needed to look asap before 2.2.0 to have a perfect version and see cyrus-imapd too. It will be nice to have 2.2.0 before Debian 13 freeze too. |
Provide a callback function to change the channel binding type of servers (e.g. "tls-server-end-point" instead of "tls-unique") during authentication of secure mechanisms like GS2-KRB5-PLUS or SCRAM-SHA-256-PLUS.
The callback is used by the plugins SCRAM and GS2 when the desired binding type of the client does not match the binding type set with property SASL_CHANNEL_BINDING.
A server can check the requested type of channel binding and overwrite the current channel binding data with the property SASL_CHANNEL_BINDING before the authentication proceeds.
Issue #823
This patch is required to support channel binding for "tls-server-end-point" in cyrus-imapd.
See example: GuidoKiener/cyrus-imapd@5e0af18
Note that the example is not complete and requires more discussion about handling of certificates with signature algorithm SHA224, ED25519, and ED448.