Skip to content

Possible use-after-free via aliased pointer in ticket-key HMAC - #1005

Closed
normanmaurer wants to merge 1 commit into
mainfrom
point_fix
Closed

Possible use-after-free via aliased pointer in ticket-key HMAC#1005
normanmaurer wants to merge 1 commit into
mainfrom
point_fix

Conversation

@normanmaurer

Copy link
Copy Markdown
Member

Motivation:

current_session_key/find_session_key copies tcn_ssl_ticket_key_t by value, but mac_params[0].data still points into the original heap array, not the copy.
If setSessionTicketKeys0 frees/replaces the array concurrently after the read-lock is released but before EVP_MAC_CTX_set_params dereferences it, that's a use-after-free (not a plain NULL deref, but same crash class under concurrency).

Modifications:

Repoint to copy

Result:

No more use-after-free possible

Motivation:

current_session_key/find_session_key copies tcn_ssl_ticket_key_t by value, but mac_params[0].data still points into the original heap array, not the copy.
If setSessionTicketKeys0 frees/replaces the array concurrently after the read-lock is released but before EVP_MAC_CTX_set_params dereferences it, that's a use-after-free (not a plain NULL deref, but same crash class under concurrency).

Modifications:

Repoint to copy

Result:

No more use-after-free possible
@normanmaurer normanmaurer added this to the 2.0.84.Final milestone Aug 30, 2026
@normanmaurer
normanmaurer deleted the point_fix branch September 1, 2026 06:34
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 this pull request may close these issues.

1 participant