Skip to content

Media Server improperly configure for Safari (therefore also Tauri on MacOS) due to RANGE 0-1 request mishandling #501

@mrztti

Description

@mrztti

The integrated media server is a great feature! I was curious to see if I could add a video player directly inside rqbit. Doing so, I ran into a very frustrating issue where a simple html

I investigated the problem, checked for CSP problems etc but found this problem:

https://stackoverflow.com/questions/50168709/html-video-not-playing-in-safari-browser

Which links to a reference page:

https://developer.apple.com/library/archive/documentation/AppleApplications/Reference/SafariWebContent/CreatingVideoforSafarioniPhone/CreatingVideoforSafarioniPhone.html#//apple_ref/doc/uid/TP40006514-SW6

When I try to verify as they suggest if querying byte ranges 0-1 indeed returns the correct byte, the media server sends the entire file. This is the exact misconfiguration as described in the reference:

% curl --range 0-1 http://127.0.0.1:3030/torrents/1/stream/1 -o /dev/null % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 263M 0 263M 0 0 536M 0 --:--:-- --:--:-- --:--:-- 536M

Consequences: videos are not streamable via Safari (not that important) -> they are not streamable inside a Tauri webview on mac (more annoying)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions