Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upSuggestion for better interoperability between WebTorrent and his partner archive.org #1471
Comments
This comment has been minimized.
This comment has been minimized.
|
A first simple solution is just to add <meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">It would be grate if the trackers and url's where secure even before the torrent/magnet link even where created. When creating a new torrent, we could log something to suggest to them that they should use https whenever possible if something is insecure. |
This comment has been minimized.
This comment has been minimized.
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. |
This comment has been minimized.
This comment has been minimized.
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. |
This comment has been minimized.
This comment has been minimized.
|
@mitra42 do you have any thoughts about this issue? |
This comment has been minimized.
This comment has been minimized.
|
Plenty of thoughts, but have been unable to get the changes done at the Archive :-( |
This comment has been minimized.
This comment has been minimized.
|
@mitra42 What is the main objection to supporting this at the Archive? |
This comment has been minimized.
This comment has been minimized.
|
No objection, but one of those complex things that requires I tried a couple of times, I finally gave up and rewrite my own magnet links and hack torrent files, on hte fly as in dweb (e.g. in https://dweb.archive.org/metadata/commute )
Three issues came up: Open questions:
I'll be back in San Francisco Oct 19th for the big Archive event on 23rd and staying through Nov 10, that would be best time to try and get a solution (to Cors and torrent rewrite) if we can get answers to these 3 questions about the required torrent file before then. Will you be in SF then? |
This comment has been minimized.
This comment has been minimized.
The solution seems like it should be: always allow cross-origin requests for static files, deny cross-origin requests for everything else. The logic goes like this: By definition, the Internet Archive wants to make the static files available as wide and far as possible. Letting JS code from any website download these files directly introduces no vulnerabilities as the site owner could always set up a proxy server to fetch the files from the Internet Archive and proxy them. All other requests like logging in, posting comments, etc. should continue to be denied to cross-origin JS code.
It seems like the requirements are:
Nothing else should be needed. One other thing I'll add is that you might want to just rewrite the |
This comment has been minimized.
This comment has been minimized.
|
Re CORS - I agree, I've made that same argument unsuccessfully. |
This comment has been minimized.
This comment has been minimized.
Regarding HTTPs, I was referring to the web seed URLS (i.e. the URLs that host the content itself). I believe that these already work over HTTPS. Regarding the other points, that is disappointing. I'm closing this issue since there's no bug to fix here, but feel free to continue discussion! |
This comment has been minimized.
This comment has been minimized.
|
The seed URLs work over HTTPS but have CORS issues, The Tracker URLs as I said I have no way to test, |
This comment has been minimized.
This comment has been minimized.
|
@mitra42 I'm super busy at the moment, but I can try. Perhaps other from the community may be able to help too. Can you open an issue with the tracker URL and a description of the expected behavior? This is the tracker server which creates a peer for content on-demand and always includes that peer's IP address in the response, right? |
This comment has been minimized.
This comment has been minimized.
|
One of these (wss://dweb.archive.org:6969 or probably https://dweb.archive.org:6969 as well) is that tracker. I'm not trying to test whether its doing the part of including the super-peer, just trying to figure out how to know if that tracker (and the others in the IA torrents) works before I ask people to rewrite torrent files. I simply don't know how to test if a tracker works. |
This comment has been minimized.
This comment has been minimized.
|
I don't have time at the moment, but I'll reopen this issue in case someone from the community is interested in testing out these trackers to help the Internet Archive. |
This comment has been minimized.
This comment has been minimized.
|
A quick update ... I've added two microservices, so that people wanting working torrents or magnet links don't have to rely on the rest of the dweb.archive.org code ... |
An example archive.org url:
https://archive.org/details/219425main_iss016e033024_hires_full
the .torrent uploaded in instant.io generate the following magnet:
magnet:?xt=urn:btih:5f091a0901022cc966c09cd5f076c53b848f6e23&dn=219425main_iss016e033024_hires_full&tr=http%3A%2F%2Fbt1.archive.org%3A6969%2Fannounce&tr=http%3A%2F%2Fbt2.archive.org%3A6969%2Fannounce&tr=wss%3A%2F%2Ftracker.btorrent.xyz&tr=wss%3A%2F%2Ftracker.fastcast.nz&tr=wss%3A%2F%2Ftracker.openwebtorrent.com&ws=http%3A%2F%2Fia600209.us.archive.org%2F33%2Fitems%2F&ws=http%3A%2F%2Fia800209.us.archive.org%2F33%2Fitems%2F&ws=https%3A%2F%2Farchive.org%2Fdownload%2FMixed Content: The page at '<URL>' was loaded over HTTPS, but requested an insecure resource '<URL>'. This request has been blocked; the content must be served over HTTPS.For example the webseed link
http://ia800209.us.archive.org/33/items/219425main_iss016e033024_hires_full/219425main_iss016e033024_hires_full.jpg
and yes, https:// version work.
Two suggestion about this:
Maybe the webseed don't support SSL, but without it will not works in any case.
This is the above magnet: link adapted for https:
magnet:?xt=urn:btih:5f091a0901022cc966c09cd5f076c53b848f6e23&dn=219425main_iss016e033024_hires_full&tr=http%3A%2F%2Fbt1.archive.org%3A6969%2Fannounce&tr=http%3A%2F%2Fbt2.archive.org%3A6969%2Fannounce&tr=wss%3A%2F%2Ftracker.btorrent.xyz&tr=wss%3A%2F%2Ftracker.fastcast.nz&tr=wss%3A%2F%2Ftracker.openwebtorrent.com&ws=https%3A%2F%2Fia600209.us.archive.org%2F33%2Fitems%2F&ws=https%3A%2F%2Fia800209.us.archive.org%2F33%2Fitems%2F&ws=https%3A%2F%2Farchive.org%2Fdownload%2Fit have anyway CORS/CORB issues:
OPTIONS https://ia600209.us.archive.org/33/items/219425main_iss016e033024_hires_full/219425main_iss016e033024_hires_full.jpg 405 (Not Allowed)Failed to load https://ia600209.us.archive.org/33/items/219425main_iss016e033024_hires_full/219425main_iss016e033024_hires_full.jpg: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://instant.io' is therefore not allowed access. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.Cross-Origin Read Blocking (CORB) blocked cross-origin response <URL> with MIME type text/html. See <URL> for more details.It can be fixed only on archive.org side.
Maybe someone here can contact archive.org to address some of this issues.