Skip to content

fix: transfers without data and plain HTTP redirects under --secure - #160

Open
BKPepe wants to merge 2 commits into
librespeed:masterfrom
BKPepe:fix/transfer-status-codes
Open

BKPepe wants to merge 2 commits into
librespeed:masterfrom
BKPepe:fix/transfer-status-codes

Conversation

@BKPepe

@BKPepe BKPepe commented Nov 22, 2026 •

Copy link
Copy Markdown
Member

Two commits. The second needs the first.

A download or upload URL that answers with an error status was timed as if the error pages were data, and requested again without a pause. Such an answer no longer counts, and neither does a 307 or 308 to an upload, which the client does not follow. Each stream waits 200 ms before it asks again, and a server with no successful request fails like one that is down.

Under --secure a server could redirect to http://, and the probe, the IP lookup, the transfers and the telemetry request followed. Such a redirect is now refused.

Download URL answering 404, 5 s, local server:

before: exit 0, "download": 21.14, 223932 requests
after:  exit 1, 75 requests
        Selected server local (127.0.0.1) gave no result: the download request returned HTTP 404 Not Found

Upload requests that fail in transport are left as they are, because --timeout covers the whole request body. This overlaps #154 in Upload.

A download or upload URL that answered with an error status was timed
as if it carried data and requested again without a pause, and a
download whose requests all failed was reported as 0 Mbps. Such a
server now fails like one that is down.
A server could answer with a redirect to an http:// URL, and the probe,
the IP lookup, the transfers and the telemetry request followed it. A
run that asked for HTTPS was then measured, or its result sent, over
plain HTTP.
@BKPepe
BKPepe force-pushed the fix/transfer-status-codes branch from c34f6d4 to 45a48a8 Compare November 22, 2026 14:34

This branch has not been deployed

No deployments
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.

1 participant