[tor-bugs] #6978 [Website]: Create Magnet links for download

Tor Bug Tracker & Wiki blackhole at torproject.org
Sat Apr 20 10:02:42 UTC 2013


#6978: Create Magnet links for download
-------------------------+--------------------------------------------------
 Reporter:  ioerror      |          Owner:     
     Type:  enhancement  |         Status:  new
 Priority:  normal       |      Milestone:     
Component:  Website      |        Version:     
 Keywords:               |         Parent:     
   Points:               |   Actualpoints:     
-------------------------+--------------------------------------------------

Comment(by mo):

 #1 Magnets and torrents support the notion of a file, or a directory
 containing files. Ideally, a torrent/magnet would contain both the package
 and its signature. The sad thing about it is that if you add web URLs as
 sources, Bittorrent requires to download to be at
 http://weburl/directory/. So, we can create magnets for file+signature
 combined, and use web URLs as sources, but then the directory the user
 will get would not have a nice name: for example "dist" for plain Tor,
 "linux" for linux TBB etc.

 #2 I was unable to find a torrent creation tool that I can point at
 multiple files. They all expect either a file, or a directory, and will
 add all files in that directory recursively to the torrent. The closed I
 could find is http://www.robertnitsch.de/projects/py3createtorrent , where
 you can specify regular expressions to exclude files. Unfortunately, it
 does not seem to support the notion of a regexp like "^(?!package)*$", but
 looking at the sources the thing could easily be modified to simply
 support lists of files.

 Conclusion: If we want it the easy way, we have to give the user separate
 torrents/magnets for a file and its signature. This is what I've been
 doing since 2011 at https://www.torservers.net/mirrors/torrents/ (script
 is at https://github.com/moba/createtortorrents ). If we want combined
 releases, we cannot use web URLs as source, and either would have to
 modify a torrent creation tool, or do some hard link magic (temporarily
 creating the directory structure we want on the seedbox).

 Another caveat: If we want "nice" directory names, we have to derive them
 somehow from either the file name or the directory structure. Sounds easy,
 but actually is not if we want, say, "Tor Browser" or "torbrowser" as
 directory name (how would you programmatically derive that from
 /dist/torbrowser/linux/tor-obfsproxy-browser-gnu-linux-i686-2.4.9-alpha-1
 -dev-ar.tar.gz.asc). If we simply go with "filename without extension" (so
 the directory name would include version information), I don't know of a
 good way to remove extensions since we have some files with a single
 extension, whereas other files have multiple extensions like .tar.gz.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/6978#comment:9>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list