You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 12, 2024. It is now read-only.
Platform:
Verified in Firefox 81 and Chrome 85 on Windows, Linux, and Macos
Subsystem:
Unknown
Severity:
Medium
Description:
If there are many repeat calls of ipfs.cat on subpaths of a IPFS hash, then each cat will call refs on the root of the hash. The calls are identical, and they don't seem to end up the browser's indexdb, or at least they aren't referenced there again.
On large trees, you could end up downloading many gigabytes of the same refs exact refs data.
Steps to reproduce the error:
I discovered this while sending over improvements to moshisushi/hlsjs-ipfs-loader
If you look at the network requests made on https://charade.fu.io you will see hundreds of requests to the following 4 URLS.
There are 1360 parts times 5 different bit rates, and each part cat also triggers ipfs-js to call that refs api for the entire tree, not just for that part. The refs here are 2.5MB. As a result the browser is downloading more than 3.5GB of the same 2.5MB from the preload servers.
The movie Charade (1963) is in the Public Domain, I'm using it as a much longer Big Buck Bunny to enhance the issue. There is no copyright infringement there.