Skip to content

SslHandler: Ensure buffers are never leaked when wrap(...) produce SS…#14647

Merged
normanmaurer merged 1 commit into4.1from
ssl_buffer_leak
Jan 13, 2025
Merged

SslHandler: Ensure buffers are never leaked when wrap(...) produce SS…#14647
normanmaurer merged 1 commit into4.1from
ssl_buffer_leak

Conversation

@normanmaurer
Copy link
Copy Markdown
Member

…LException

Motivation:

After we removed the ByteBuf from the pendingUnencryptedWrites queue we need to ensure we will always release ByteBuf even in the case of wrapMultiple(...) or wrap(...) throwing a SSLException.

Modifications:

  • Ensure we release the ByteBuf when a SSLException is thrown before rethrowing it.

Result:

Fixes #14644

…LException

Motivation:

After we removed the ByteBuf from the pendingUnencryptedWrites queue we need to ensure we will always release ByteBuf even in the case of wrapMultiple(...) or wrap(...) throwing a SSLException.

Modifications:

- Ensure we release the ByteBuf when a SSLException is thrown before rethrowing it.

Result:

Fixes #14644
@normanmaurer
Copy link
Copy Markdown
Member Author

I am surprised that nobody reported this before...

@normanmaurer
Copy link
Copy Markdown
Member Author

I am currently still trying to figure out how to best write a test case for that which is kind of hard. I think we should merge this PR anyway

@normanmaurer normanmaurer merged commit b8e25e0 into 4.1 Jan 13, 2025
@normanmaurer normanmaurer deleted the ssl_buffer_leak branch January 13, 2025 06:26
normanmaurer added a commit that referenced this pull request Jan 13, 2025
#14647)

…LException

Motivation:

After we removed the ByteBuf from the pendingUnencryptedWrites queue we
need to ensure we will always release ByteBuf even in the case of
wrapMultiple(...) or wrap(...) throwing a SSLException.

Modifications:

- Ensure we release the ByteBuf when a SSLException is thrown before
rethrowing it.

Result:

Fixes #14644
normanmaurer added a commit that referenced this pull request Jan 13, 2025
#14651)

…… (#14647)

…LException

Motivation:

After we removed the ByteBuf from the pendingUnencryptedWrites queue we
need to ensure we will always release ByteBuf even in the case of
wrapMultiple(...) or wrap(...) throwing a SSLException.

Modifications:

- Ensure we release the ByteBuf when a SSLException is thrown before
rethrowing it.

Result:

Fixes #14644
normanmaurer added a commit that referenced this pull request Jan 13, 2025
#14647)

…LException

Motivation:

After we removed the ByteBuf from the pendingUnencryptedWrites queue we
need to ensure we will always release ByteBuf even in the case of
wrapMultiple(...) or wrap(...) throwing a SSLException.

Modifications:

- Ensure we release the ByteBuf when a SSLException is thrown before
rethrowing it.

Result:

Fixes #14644
normanmaurer added a commit that referenced this pull request Jan 13, 2025
#14652)

…… (#14647)

…LException

Motivation:

After we removed the ByteBuf from the pendingUnencryptedWrites queue we
need to ensure we will always release ByteBuf even in the case of
wrapMultiple(...) or wrap(...) throwing a SSLException.

Modifications:

- Ensure we release the ByteBuf when a SSLException is thrown before
rethrowing it.

Result:

Fixes #14644
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

4 participants