Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to update torrent content #556

Closed
sunk818 opened this issue Jan 5, 2016 · 6 comments
Closed

Ability to update torrent content #556

sunk818 opened this issue Jan 5, 2016 · 6 comments
Labels

Comments

@sunk818
Copy link

@sunk818 sunk818 commented Jan 5, 2016

Not sure how others are using WebTorrent. I'm curious about the ability to create a web site and publish updates to the web site. ZeroNet does this well for small web sites, but not for web sites that hundreds of megabytes of HTML.

I noticed Bittorrent has an enhancement draft for update URLs in Bittorrent: http://www.bittorrent.org/beps/bep_0039.html

Curious if WebTorrent is useful for publishing and updating large amounts of HTML.

@feross feross added the question label Jan 5, 2016
@DiegoRBaquero

This comment has been minimized.

Copy link
Member

@DiegoRBaquero DiegoRBaquero commented Jan 7, 2016

You would need a central server to provide the updated/latest torrent.

I've been looking a lot into this kind of things. On way is to reference the location of where I can find the located version inside the torrent. Another way, and I'd prefer because it can be built in top for WebTorrent for the browsers is that you, in your website download the latest .torrent and then render it.

Something like publish packs the html, css & js into a .torrent called latest.torrent and pushes it to yourdomain.com/latest.torrent . Then, users would go in your website and the client uses latest.torrent and then renders it.

In BTorrent, I'm making a browser that will support the exact features I propose. The "URLs" would be the infohashes/magnets/.torrent . Instead of linking with href you'd link with wtref.

@sunk818

This comment has been minimized.

Copy link
Author

@sunk818 sunk818 commented Jan 7, 2016

Could the update url be via dht that points to a new magnet link (the new torrent)? No central server required?

For webtorrent videos, it seems videos are streamed so the file pieces have to be served sequentially for optimal viewing of video.

So instead of href, wtref is a replacement and the browser accesses different resources as needed on demand? Or would the entire torrent need to complete first before serving updated content?

@madd512

This comment has been minimized.

Copy link

@madd512 madd512 commented Jan 7, 2016

This can be accomplished by an extension to the bittorrent protocol. You can seed a public key file and distribute verifiable updates across the network by sending signed messages to any peers you can find, and rebroadcasting valid signed messages that you receive.

@feross

This comment has been minimized.

Copy link
Member

@feross feross commented Jan 7, 2016

This is probably best accomplished outside of WebTorrent right now, with something like BEP44. This lets you set, get, and update key/values on BitTorrent DHT nodes. So this will let you update a "pointer" to point at the latest torrent. And you can implement a kind of linked list structure where each new torrent points to the last.

get(key) ---> info hash 1 ---> info hash 2  --->  ...
                   |                |
                   v                v
               content 1        content 2

The bittorrent-dht package already supports BEP44.

(It won't work in the browser because there's no WebRTC DHT yet.)

@feross

This comment has been minimized.

Copy link
Member

@feross feross commented Jan 7, 2016

Feel free to continue discussing this topic here, but I'm going to close this since it's not an issue with WebTorrent. :)

@feross feross closed this Jan 7, 2016
@lock

This comment has been minimized.

Copy link

@lock lock bot commented May 4, 2018

This thread has been automatically locked because it has not had recent activity. To discuss futher, please open a new issue.

@lock lock bot locked as resolved and limited conversation to collaborators May 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.