Skip to content

Netty factory: Close TCP connection when receive TLS close notify - #1220

Merged
KostyaSha merged 1 commit into
docker-java:masterfrom
vladimirlagunov:ssl-close-notify-to-tcp-fin
Jul 18, 2019
Merged

Netty factory: Close TCP connection when receive TLS close notify#1220
KostyaSha merged 1 commit into
docker-java:masterfrom
vladimirlagunov:ssl-close-notify-to-tcp-fin

Conversation

@vladimirlagunov

@vladimirlagunov vladimirlagunov commented Jul 15, 2019

Copy link
Copy Markdown
Contributor

TLS has special TLS Alert message "close_notify". After receiving such packet any conversation
should be immediately stopped. Some TLS implementations (OpenSSL for example) closes underlying TCP connection when TLS connection being closed, some (Docker SSL server and docker-java before current commit) does not close. AttachContainerCmd executes onComplete callback only when TCP connection closes, so without this patch onComplete called after a long timeout, with this patch it called when container exits.


This change is Reviewable

TLS has special TLS Alert message "close_notify". After receiving such packet any conversation
should be immediately stopped. Some TLS implementations (OpenSSL for example) closes underlying TCP
connection when TLS connection being closed, some (Docker SSL server and docker-java before current
commit) does not close. AttachContainerCmd executes `onComplete` callback only when TCP connection
closes, so without this patch `onComplete` called after a long timeout, with this patch it called
when container exits.
@KostyaSha KostyaSha added this to the 3.1.4 milestone Jul 18, 2019
@KostyaSha
KostyaSha merged commit f760f0c into docker-java:master Jul 18, 2019
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.

2 participants