Skip to content

[v16] Prevent forwarded tcpip requests hanging indefinitely#50239

Merged
rosstimothy merged 1 commit intobranch/v16from
tross/backport-50209/v16
Dec 13, 2024
Merged

[v16] Prevent forwarded tcpip requests hanging indefinitely#50239
rosstimothy merged 1 commit intobranch/v16from
tross/backport-50209/v16

Conversation

@rosstimothy
Copy link
Copy Markdown
Contributor

Backport #50209 to branch/v16

changelog: Properly close ssh port forwarding connections to prevent requests hanging indefinitely.

@aws-amplify-us-west-2
Copy link
Copy Markdown

This pull request is automatically being deployed by Amplify Hosting (learn more).

Access this pull request here: https://pr-50239.d1v2yqnl3ruxch.amplifyapp.com

The SSH channel was only being closed in the happy path once
proxying of data completed. This resulted in any connections being
made, and failing for any reason prior to that hanging until the
user terminated the request.

The behavior from the regular.Server was copied to the forward.Server
to ensure that the channel is always closed when handleDirectTCPIPRequest
terminates.
@rosstimothy rosstimothy force-pushed the tross/backport-50209/v16 branch from d641363 to adcf2bc Compare December 13, 2024 20:53
@rosstimothy rosstimothy marked this pull request as ready for review December 13, 2024 21:17
@rosstimothy rosstimothy added this pull request to the merge queue Dec 13, 2024
Merged via the queue into branch/v16 with commit e565b25 Dec 13, 2024
@rosstimothy rosstimothy deleted the tross/backport-50209/v16 branch December 13, 2024 22:01
@doggydogworld doggydogworld mentioned this pull request Dec 18, 2024
@fheinecke fheinecke mentioned this pull request Apr 9, 2025
@fheinecke fheinecke mentioned this pull request Jan 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants