Opened 7 years ago

Closed 7 years ago

#4689 closed Bug (fixed)

Transmission creates corrupt metafiles from valid magnet links

Reported by: cfpp2p Owned by:
Priority: Normal Milestone: 2.50
Component: Transmission Version: 2.42
Severity: Normal Keywords:
Cc:

Description

When transmission acquires the metafile for a magnet link it sometimes does not complete the 'info' dictionary section of the final metafile.

Case in point for the attached is that the info dictionary should contain a secondary dictionary entry but does not. The metafile acquired by transmission will therefor not have the correct 'info' section hash and trackers will not recognize the transmission acquired .torrent(metafile)and will report tracker error. If the transmission acquired .torrent is used in other clients the SAME tracker ERROR results.

When the tracker error is reported immediately after magnet link acquires the metafile transmission crashes ( ticket #4687 ).

Attached file contains magnet links and Transmission acquired corrupt .torrents and non-corrupt .torrents from bc client. The Transmission acquired .torrents give tracker error on every client I try, whereas the bc .torrents function perfectly in Transmission, all from the exact same magnet links.

Attachments (3)

crashers-via-mag-com.zip (119.3 KB) - added by cfpp2p 7 years ago.
CrashFixMag.patch (719 bytes) - added by cfpp2p 7 years ago.
isPeerIoDBG_test.patch (2.9 KB) - added by cfpp2p 7 years ago.

Download all attachments as: .zip

Change History (11)

Changed 7 years ago by cfpp2p

comment:1 Changed 7 years ago by cfpp2p

  • Summary changed from Transmission acquires corrupt metafiles from magnet links to Transmission creates corrupt metafiles from valid magnet links

comment:2 Changed 7 years ago by cfpp2p

I try to get transmission to create metafile with similar structure to that of other clients that don't have a problem. Patches at tr_torrentSetMetadataPiece, tr_metainfoParse, tr_magnetCreateMetainfo, etc. but this still doesn't address the underlying problem with tr_isPeerIo( const tr_peerIo * io ) crashes. Tried older versions of transmission back to v2.2 and still crash... I don't know what to patch for tr_isPeerIo.

Changed 7 years ago by cfpp2p

Changed 7 years ago by cfpp2p

comment:3 Changed 7 years ago by cfpp2p

  • Resolution set to fixed
  • Status changed from new to closed

patch to fix crash and correct tracker errors. also have attached debug patch (debug use ONLY!) that helped maybe root out tr_peerIo crashes. somebody needs to look at: lines starting at:

1936 /* FIXME: this is kind of a mess. */ of peer-mgr.c

and try to organize that.

comment:4 Changed 7 years ago by livings124

Why did you close this ticket if the ix isn't in yet?

comment:5 follow-up: Changed 7 years ago by cfpp2p

  • Milestone changed from None Set to 2.50
  • Resolution fixed deleted
  • Status changed from closed to reopened

I meant that the CrashFixMag?.patch fixes this ticket as well as ticket #4687 . Sorry... it still needs to be put in the repository.

comment:6 in reply to: ↑ 5 Changed 7 years ago by gunzip

Replying to cfpp2p:

I meant that the CrashFixMag?.patch fixes this ticket as well as ticket #4687 . Sorry... it still needs to be put in the repository.

yes, your patch solved a repeatable crash re magnet links in both Mac and Linux versions (see ticket #4687 for details).

i've been carrying the patch for a month now with no ill effects. so is there any reason not to enter this in trunk? just asking the developers to review ..

comment:7 Changed 7 years ago by jordan

  • Version changed from 2.42+ to 2.42

comment:8 Changed 7 years ago by jordan

  • Resolution set to fixed
  • Status changed from reopened to closed

Fixed for 2.50 by r13198.

Note: See TracTickets for help on using tickets.