fix(cable): close hybrid transport spec gaps in tunnel and L2CAP
メンテナーはふだん 2 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 42/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- rust
- 領域
- networking, security, testing-qa
調査の方向性
transport/cable/tunnel.rs と connection_stages.rs から始め、次に接続ステータスの処理について transport/error.rs と CableKnownDeviceInfoStore::delete_known_device を調べてください。channel.rs、protocol.rs、l2cap.rs を読み、フレーミングまたはシャットダウンの動作を変更する前に、既存の split_handles_binary_payload テストを実行してください。完了条件は、内部 CRLF のリグレッションテストを含め、一覧にある 4 つの transport および framing のケースがカバーされ、必要な仕様の明確化が提起されていることです。
索引モデルが issue の本文から書いたものです。
説明
Problem
The hybrid (caBLE) transport in transport/cable handles the common QR-initiated flow, but four behaviours required by the CTAP hybrid / caBLE v2 spec are missing or broken, across tunnel connect handling and L2CAP framing.
Why it matters
These break interop with real authenticators and platforms. Redirecting tunnel servers are unreachable, dead linking records are retried forever, clean shutdown and late linking updates are lost, and some direct-BLE messages get corrupted.
What to do
1. Follow HTTP redirects on tunnel connect
tunnel::connect() (libwebauthn/src/transport/cable/tunnel.rs) calls tokio_tungstenite::connect_async(), which doesn't follow redirects, so any 3xx becomes ConnectionFailed. The spec requires following them.
- Follow 3xx redirects (e.g. 307/308) to the
Locationtarget before the WebSocket upgrade, with a redirect cap. - Re-attach
Sec-WebSocket-Protocol: fido.cable, andX-caBLE-Client-Payloadfor known-device connections, on the redirected request.
2. Handle HTTP 410 Gone on state-assisted contact
connect() collapses every non-101 status into ConnectionFailed. For CableTunnelConnectionType::KnownDevice (/cable/contact/{contact_id}), a 410 means the linking record is permanently gone, but nothing deletes it, so the dead link is retried forever.
- Surface 410 distinctly. No
TransportErrorvariant exists yet (transport/error.rs). - On 410, delete the record via
CableKnownDeviceInfoStore::delete_known_deviceand stop retrying.connect_data_channel()inconnection_stages.rsneeds store access (today it is only in the post-handshakeconnection()path).
3. Send Shutdown on close and linger for late linking data
CableChannel::close() (channel.rs) is an empty TODO and Drop just aborts. We handle inbound CableTunnelMessageType::Shutdown (protocol.rs, RecvOutcome::PeerShutdown) but never send one, and tearing down right after the CTAP response drops any post-transaction Update linking message.
- On
close(), send aShutdownframe over the encrypted channel before dropping it. - After the CTAP response, linger briefly (~2 minutes) to capture late
Updatelinking data.
4. Fix ambiguous CRLF framing over L2CAP
l2cap.rs ends each message with EOM = [0x0D, 0x0A] and split_next_message() splits at the first CRLF, but binary Noise/AES-GCM payloads can contain 0x0D 0x0A. For a 700-1400 byte ciphertext that is a ~1-2% chance of an internal CRLF corrupting the frame. The split_handles_binary_payload test only covers payloads with no internal CRLF.
- Make L2CAP message boundaries unambiguous for arbitrary binary payloads.
- Add a regression test for a payload containing an internal
0x0D 0x0A. - Raise the framing ambiguity with the CTAP hybrid spec editors. Delimiter framing without escaping or a length prefix is unsafe and likely needs a spec clarification.
- 主要言語
- Rust
- スター
- 602
- フォーク
- 33
- 平均マージ
- 1日 13時間
- マージ済み PR(30日)
- 9
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
linux-credentials/libwebauthn のほかの issue
-
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
linux-credentials/libwebauthn#328 ·
メンテナーはふだん 2 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
linux-credentials/libwebauthn#327 ·
メンテナーはふだん 2 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 52/100
linux-credentials/libwebauthn#326 ·
メンテナーはふだん 2 日以内に返信
-
難易度 3/5 1〜2日 初心者へのやさしさ 55/100
linux-credentials/libwebauthn#313 ·
メンテナーはふだん 2 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 58/100
linux-credentials/libwebauthn#195 ·
メンテナーはふだん 2 日以内に返信
linux-credentials/libwebauthn の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
-
needs triage
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
pbakaus/impeccable#1620 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
swc-project/swc-next-issues#533 ·
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
nautechsystems/nautilus_trader#5718 ·
メンテナーはふだん 1 日以内に返信
-
`luvus --remote` cannot start on a host whose login shell is Nushell対応中かも @schlich が今日担当しました。 オープンstatus: needs triage
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 4 日以内に返信