Skip to content

WebTransport Swift 1.3.8

Choose a tag to compare

@Pummelchen Pummelchen released this 13 Sep 12:07
· 608 commits to main since this release

A defect-fix release for issue #24. There are no wire-format changes and nothing is added to or removed from the public API.

The defect

A peer that ends a stream before sending the bytes that stream has to begin with was reported as QUICCodecError.truncated(needed: 1, available: 0). The runtime read the first chunk of a stream and dropped the endOfStream flag, so the codec's empty-buffer refusal was what a caller saw for a peer that FINed an inbound stream without writing to it — a message that reads like an internal truncation rather than a peer that is not following the protocol.

The fix

WebTransportNetworkRuntimeError.peerClosedStreamWithoutData(streamID:) names the stream and the cause. It is raised on the request stream, an inbound WebTransport stream, the peer's HTTP/3 control stream and a CONNECT response. A read that returns no bytes while the stream is still open is now waited out rather than returned, so "nothing yet" and "the peer is done" cannot be confused.

Verification

  • 300 package tests pass on the tagged revision (13d29fd), up from 297: the three additions are the regression tests for the issue #24 fix. Swift CI on 1.3.8 runs them, together with the peer-input fuzz corpus under AddressSanitizer and the in-process suite under Thread Sanitizer. That run is green on its second attempt: the first failed listenerServesMoreSequentialSessionsThanTheDefaultCeiling with a Network is down (ENETDOWN) from the runner, which did not reproduce here or on rerun and is filed in the project tracker as WT-185.
  • The published binaries pass both 40-scenario CLI conformance suites. Downloaded from this release, checked against SHA256SUMS, and run from the tagged checkout: passed=40 failed=0 total=40 for WebTransportClient and for WebTransportServer. The suites read Package.swift and Swift/build-release-apple-silicon.sh for two of the forty scenarios to assert properties of the source tree, so from a directory holding only the assets those two report a missing file and the suite says passed=38 failed=2; the 38 that exercise the transport itself pass in either directory. Making the tree-reading pair report "not in a checkout" rather than fail is filed in the project tracker as WT-186.
  • The published checksums reproduce from source. ./Swift/build-release-apple-silicon.sh builds both products twice from a clean tree and compares normalized Mach-O hashes (the linker's UUID is zeroed, since it differs per link and carries nothing); the SHA256SUMS attached here is that script's output for the tagged revision.
  • The interoperability evidence is one revision older than this release. The containerized five-implementation matrix in the wiki was last run against 1.3.5. 1.3.8 changes no wire encoding, so that evidence stands for the encoding, but it was not rerun for 1.3.8 and this page does not claim it was.

Assets

WebTransportClient and WebTransportServer are thin arm64 Mach-O binaries; SHA256SUMS covers both. GitHub does not carry a file's mode through a release upload, so make them executable, then clear the quarantine flag that ad-hoc signing without notarization leaves on them:

shasum -a 256 -c SHA256SUMS
chmod +x WebTransportClient WebTransportServer
xattr -d com.apple.quarantine WebTransportClient WebTransportServer
./WebTransportServer --scenario all

The two release scenarios that read the source tree need a checkout to pass; the rest run anywhere.