[PATCH] hostapd: Pass BSS tls_flags to tls_global_set_params

Jouni Malinen j at w1.fi
Sun Nov 15 05:06:43 PST 2026


On Sat, Oct 03, 2026 at 11:00:41PM +1300, Karsten Sperling wrote:
> The tls.h API accepts TLS_CONN_* flags both in tls_init
> (tls_config.tls_flags) and tls_global_set_params
> (tls_connection_params.flags), and also per connection in
> tls_connection_set_params (tls_connection_params.flags) and
> tls_connection_set_verify (flags).
> 
> authsrv_init passes the BSS tls_flags to tls_init, but was passing flags
> == 0 in the subsequent tls_global_set_params call. Depending on how a
> particular backend implements flag handling in these 4 functions, this
> can have the effect of clobbering configuration that the tls_init call
> set up.
> 
> For example, with the wolfSSL backend if the [SUITEB] tls_flag is set on
> the BSS but no explicit list of ciphers is configured, tls_init will
> configure the relevant Suite-B ciphers, but tls_global_set_params with
> flags = 0 will reset the cipher list back to default. The BSS tls_flags
> also make their way into tls_connection_set_verify, but wolfSSL doesn't
> happen to re-apply the ciphers based on the SUITEB flag at that point.
> 
> The tls.h documentation does not document whether subsequent calls are
> intended to fully replace or only augment flags and other state, but
> given the variations between backends, passing (as much as possible) the
> same flags to all functions seems prudent.
> 
> Note that on the OpenSSL backend this change has no impact, since
> tls_global_set_params ignores all flags other than
> DISABLE_SESSION_TICKET, which is later re-configured per connection in
> tls_connection_set_verify.

Thanks, applied.
 
-- 
Jouni Malinen                                            PGP id EFC895FA



More information about the Hostap mailing list