Repository navigation
v0.4.0
mimicry v0.4.0
Chrome and Firefox on Linux, Edge on macOS and Windows, Firefox 159 on desktop, Chrome's client hints, and binding to a local address over HTTP/3 too. URLs are now sent as each browser parses them, a trailing-dot host's SNI as each browser sends it, and QPACK on resumed 0-RTT connections starts as the browsers' does.
New profiles
-
chrome-157-linux(profiles.ChromeLinux()) andfirefox-159-linux(profiles.FirefoxLinux()). They are captured on Ubuntu 24.04; Chrome and Firefox on Fedora 45 sent the same first requests. Distribution builds and arm64 aren't covered (decision 0058). (#64, #92) -
edge-157-macos(profiles.EdgeMacOS()) andedge-157-windows(profiles.EdgeWindows()), captured on their own rather than derived from Chrome. Edge differs from Chrome 157 in four ways (decision 0059):- no Trust Anchor IDs extension;
- no
image/jxlinaccept; - the
Edg/user agent and"Microsoft Edge"brand; - 2-byte packet numbers on its second QUIC Initial.
-
firefox-159-macosandfirefox-159-windows:profiles.FirefoxMacOS()andprofiles.FirefoxWindows()now return them. The 158 profiles stay. (#76, #82)
New API
-
Config.LocalAddrs(at most one IPv4 and one IPv6 address) binds every socket mimicry opens itself: TCP, QUIC's UDP sockets and SOCKS5 UDP relays. Before, HTTP/3 ignoredDialContextand left from the host's default address while HTTP/2 left from the bound one. (#81, #87) -
Client hints (Chrome and Edge profiles; decision 0055). A navigation's
Accept-CHis kept per origin and the hints are sent where Chrome sends them:Critical-CHrestarts a GET navigation once, on the same connection;Clear-Site-Dataempties the origin's set;Config.ClientHintStoreholds the hints: nil keeps one per Transport, andNewClientHintStore()returns aMemoryClientHintStorethat saves and loads as JSON;Config.ClientHintssets the machine the hints describe, andprofiles.Machinesandprofiles.RandomMachinelist the captured ones;Request.ClientHints(HintsDelegated,HintsWithheld) says whether the page delegates its hints to another origin.
-
req.URL.Opaquesends the request target exactly as written, path and query, as net/http does. Use it for a target a browser would rewrite, or one Go's URL parser refuses, like a lone%. (#71, #89)
Behaviour changes
These don't change the API, but a request can now go out differently than in v0.3.0:
-
URLs are sent as the browsers parse them, as measured in a new
urlscapture of 43 awkward URLs (decision 0057):'in a query becomes%27;- in a path,
\becomes/and dot segments are resolved; - an IPv4 host in any form becomes dotted decimal;
- Chrome and Edge encode
|in a path; - Firefox and Safari 26 refuse an invalid
xn--host.
-
A trailing-dot host's SNI (
https://example.com./) is sent as each browser sends it:- Chrome, Edge and Firefox keep the dot;
- Safari and the iPhone profiles send no SNI, and still verify the certificate against the host.
Before, the dot was dropped for every profile. (#88, #97, #99; uTLS fork roachadam/utls#18)
-
QPACK on a resumed 0-RTT connection: the encoder starts from the server's SETTINGS remembered with the ticket, as Chrome, Edge and Firefox do. Chrome and Edge set the table capacity again once the server's SETTINGS arrive. Before, a 0-RTT connection used no dynamic table until the handshake finished. A server that shrinks its SETTINGS on such a connection gets
H3_SETTINGS_ERROR, as RFC 9114 says. (#90, #98, #99) -
Firefox's QUIC packet numbers: before anything in a packet number space is acknowledged, a packet number goes in the fewest bytes that hold it, as Firefox does (RFC 9000 appendix A.2 asks for twice that range). This only affects Firefox's random first Initial, in about 1.6% of connections. (#91, #93)
Profiles and tooling
-
Older profiles measured:
firefox-158-macosandfirefox-158-windowsare measured for trailing-dot SNI, URLs and QPACK, from Firefox 158 itself.chrome-155-macosis measured for the two network-stack rules (trailing-dot SNI and QPACK on resumption), from Chrome for Testing 155. Its URL rules stay unmeasured:|in a path and invalidxn--hosts fail withErrNotMeasured.
(#99)
-
Capture tooling:
cmd/refreshcaptures Linux through WSL (-linux,-wsl) and Edge;cmd/capture -firefox-appand-chrome-apptake a specific browser build;- the release watch follows Edge Stable.
-
CI: main's harness tests take about a third of the time they did. The race detector no longer runs on single-goroutine code, and tests that wait on page timers run more subtests at once. (#100, #101)