テクノロジー · 実用ガイド

OpenSSL の wrong version number?TLS を変える前に port・protocol・proxy 経路を証明する

正確な経路と最初の bytes を保存し、plaintext、誤 port、HTTP proxy、STARTTLS、interception、framing 破損を分離します。

オリジナル概念イラスト:client、proxy/inspection path、listener、TLS か plaintext かを決める first bytes を追跡します。
オリジナル概念イラスト:client、proxy/inspection path、listener、TLS か plaintext かを決める first bytes を追跡します。 Watch at Ease

wrong version number は record-layer の手掛かりで、相手が古い TLS だけを話す証明ではありません。certificate が届く前に、first bytes が TLS record の形でないため発生することがあります。

URL、host、port、proxy 環境と error を保存し、direct TLS、HTTP CONNECT、正しい STARTTLS として同じ経路を検査します。一つの境界だけ修正し、TLS identity と application response を確認します。

正確な経路と最初の失敗を固定する

application、OpenSSL version、URL、resolved address、port、proxy variables、NO_PROXY、mesh や inspection device を記録します。retry 前に first failure を保存します。

peer certificate が無く数 bytes だけなら trust store より protocol boundary を先に確認します。secret を含む capture は公開しません。

direct TLS、CONNECT、STARTTLS を分類する

immediate TLS は openssl s_client -connect host:port -servername host -brief で検査し、IP 指定でも SNI は intended virtual host を使います。

HTTP proxy は -proxy で CONNECT を発行し、proxy endpoint は plain HTTP のことがあります。mail、LDAP、PostgreSQL などは対応する -starttls を使います。

最初の response を protocol evidence として読む

TLS record には header と handshake sequence があります。HTTP status、SMTP banner、proxy block page、error word は TLS endpoint より前の component が答えた証拠です。短い redacted sample を保存します。

wrong listener、reverse proxy port、health endpoint、sidecar、outbound proxy、inspection gateway、application protocol の所有者へ結び付けます。network ごとの差を route 差として扱います。

証明された境界だけ修正する

scheme、port、proxy/CONNECT、STARTTLS、load-balancer listener、upstream mapping、framing のうち証明された箇所だけを直します。古い TLS や verification off で隠しません。

first bytes が TLS で later negotiation が失敗するなら、alert、version、cipher、certificate、SNI の別 issue として扱います。

同じ経路で TLS と application を受け入れる

元の runtime と path から certificate identity、hostname verification、protocol、cipher、SNI、proxy/STARTTLS、remote address を記録します。application は verification を強制します。

最後に harmless application response を一つ取得します。旧 error が消えただけでは合格ではなく、route ledger を保存します。

オリジナル概念イラスト:4 steps で route を分類し、一つを修正し、TLS identity と application response を検証します。
オリジナル概念イラスト:4 steps で route を分類し、一つを修正し、TLS identity と application response を検証します。 Watch at Ease