Bug 66028 - Can't use openssl3.0.x ktls.
Summary: Can't use openssl3.0.x ktls.
Status: RESOLVED WONTFIX
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: mod_ssl (show other bugs)
Version: 2.4.53
Hardware: PC Linux
: P2 normal (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-04-24 01:07 UTC by paulzakk
Modified: 2022-04-27 07:46 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description paulzakk 2022-04-24 01:07:28 UTC
I am using apache version 2.5.53 in Linux environment.
openssl version 3.0.2 is used.
I know that openssl 3.0.x version officially supports kernel tls (ktls).

I know that openssl 3.0.x version officially supports kernel tls (ktls). So I built using the enable-ktls option when building openssl and added SSLOpenSSLConfCmd Options KTLS to enable KTLS in apache.
However, when I traced the log, it was confirmed that the following log was output.

ssl_engine_io.c(586): [client xxx.xxx.xxx.xxx:xxxxx] BUG: bio_filter_in_ctrl() should not be called with cmd=76

Is there any way to use openssl's ktls function?
Comment 1 paulzakk 2022-04-24 01:43:45 UTC
(In reply to paulzakk from comment #0)
> I am using apache version 2.5.53 in Linux environment.
> openssl version 3.0.2 is used.
> I know that openssl 3.0.x version officially supports kernel tls (ktls).
> 
> I know that openssl 3.0.x version officially supports kernel tls (ktls). So
> I built using the enable-ktls option when building openssl and added
> SSLOpenSSLConfCmd Options KTLS to enable KTLS in apache.
> However, when I traced the log, it was confirmed that the following log was
> output.
> 
> ssl_engine_io.c(586): [client xxx.xxx.xxx.xxx:xxxxx] BUG:
> bio_filter_in_ctrl() should not be called with cmd=76
> 
> Is there any way to use openssl's ktls function?

The apache version was written incorrectly.
The version I use is 2.4.53 .
Comment 2 Joe Orton 2022-04-25 10:38:54 UTC
That is only a debugging message - though it is wrong since it's not a bug.

I think that OpenSSL's KTLS support will not be usable from httpd because mod_ssl does not use a socket BIO (OpenSSL's support for talking directly to a socket);  all output from mod_ssl goes through the output filter chain so it can be interpreted/intercepted/handled elsewhere in the server.
Comment 3 Joe Orton 2022-04-26 15:01:51 UTC
Does mod_ssl fail in this configuration or not with 2.4.53? If it fails please give more logs. If it works but doesn't use KTLS there's probably little we can do about it in mod_ssl.
Comment 4 paulzakk 2022-04-26 15:36:09 UTC
There are no mod_ssl errors in my environment.
I understand that if mod_ssl doesn't use BIO, then openssl's KTLS doesn't work as you said.

Thank you for answer.
Comment 5 Joe Orton 2022-04-27 07:46:35 UTC
Thanks for following up.  I've adjusted the log messages in r1900309 - since there is not otherwise a bug here I will close this.