Tracker sending invalid data

Started by greentide, September 05, 2011, 12:10:59 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

autotron

Quote from: stoner on October 17, 2012, 04:51:48 PM
Oops.  Sry I posted in this thread thinking it was V3. 

What I posted is for V3, so may not work on V2.
As far as I know there was never a prob on V2  (at least I cant remember fixing one)

that bit is basically the same in both versions, but yes it was an issue, I corrected on both my sites....but as I said it only effected torrentflux all other clients worked fine

stoner

Oops.  Sry I posted in this thread thinking it was V3. 

What I posted is for V3, so may not work on V2.
As far as I know there was never a prob on V2  (at least I cant remember fixing one)

autotron

Quote from: stoner on October 17, 2012, 09:25:44 AM
In announce line 125 :

/*
//== compact mod
if ($_GET['compact'] != 1) {
    $resp = "d".benc_str("interval")."i".$INSTALLER09['announce_interval']."e".benc_str("private").'i1e'.benc_str("peers")."l";
} else {
    $resp = "d".benc_str("interval")."i".$INSTALLER09['announce_interval']."e".benc_str("private").'i1e'.benc_str("min interval")."i".300."e5:"."peers";
}*/

//MY MODDED CODE//
if($_GET['compact'] != 1)
{
$resp = "d" . benc_str("interval") . "i" . $INSTALLER09['announce_interval'] . "e" . benc_str("peers") . "l";
}
else
{
$resp = "d" . benc_str("interval") . "i" . $INSTALLER09['announce_interval'] ."e" . benc_str("min interval") . "i" . 300 ."e5:"."peers" ;
}

The error I was getting was:
Parse error: syntax error, unexpected T_DNUMBER in /home/beta/www/announce.php on line 125

This now works fine.  Not sure its a proper fix, will have to let others look at it.  But it is a fix :-)

Mindless:
I think this invalid data is on the SVN source code.  I downloaded it yesterday.  I have only modded a few bits and none of it should of caused this issue.


I also had this issue in V2 and the fix is as Stoner says except if you move the bit removed benc_str("private") . 'i1e' way down to the bottom of announce.php just above the last line benc_resp_raw($resp);
it works well
but then the error was never in utorrent, only in torrentflux.

stoner

In announce line 125 :

/*
//== compact mod
if ($_GET['compact'] != 1) {
    $resp = "d".benc_str("interval")."i".$INSTALLER09['announce_interval']."e".benc_str("private").'i1e'.benc_str("peers")."l";
} else {
    $resp = "d".benc_str("interval")."i".$INSTALLER09['announce_interval']."e".benc_str("private").'i1e'.benc_str("min interval")."i".300."e5:"."peers";
}*/

//MY MODDED CODE//
if($_GET['compact'] != 1)
{
$resp = "d" . benc_str("interval") . "i" . $INSTALLER09['announce_interval'] . "e" . benc_str("peers") . "l";
}
else
{
$resp = "d" . benc_str("interval") . "i" . $INSTALLER09['announce_interval'] ."e" . benc_str("min interval") . "i" . 300 ."e5:"."peers" ;
}

The error I was getting was:
Parse error: syntax error, unexpected T_DNUMBER in /home/beta/www/announce.php on line 125

This now works fine.  Not sure its a proper fix, will have to let others look at it.  But it is a fix :-)

Mindless:
I think this invalid data is on the SVN source code.  I downloaded it yesterday.  I have only modded a few bits and none of it should of caused this issue. 

Mindless

Guess ? Afraid not - You have either modified and fucked something up or somethings wrong on the server, Error logs, http debugger get it installed and see whats happening on response from tracker.

greentide


Hi

Im getting an error in uTorrent"Tracker sending invalid data" Does anyone know how I can solve this.

Regards

Greentide