and i cant login in my stuff panel to edit the members account it gives me account and permission denied and i cant login to stuff panel with error :
PHP Code:
<?
/***********************************************/
/* WDW Tracker.1 [Nulled] */
/* Special Thanks To */
/* DrNet - wWw.SpecialCoders.CoM */
/* Vinson - wWw.Decode4u.CoM */
/* MrDecoder - wWw.Fearless-Releases.CoM */
/* Fynnon - wWw.BvList.CoM */
/***********************************************/
@error_reporting (E_ALL & ~E_NOTICE);
@ini_set ('error_reporting', E_ALL & ~E_NOTICE);
@ini_set ('display_errors', '0');
@ini_set ('display_startup_errors', '0');
@ini_set ('ignore_repeated_errors', '1');
@ini_set ('log_errors', '1');
@set_time_limit (0);
@ignore_user_abort (1);
@set_magic_quotes_runtime (0);
@ini_set ('magic_quotes_sybase', 0);
define ('IN_ANNOUNCE', true);
define ('ANN_VERSION', '4.5.2 by xam');
define ('TSDIR', dirname (__FILE__));
define ('INC_PATH', TSDIR . '/include');
define ('TIMENOW', date ('Y-m-d H:i:s'));
require INC_PATH . '/config_announce.php';
require INC_PATH . '/languages/' . $defaultlanguage . '/announce.lang.php';
require INC_PATH . '/functions_announce.php';
define ('SKIP_E_WARNING', true);
define ('LOGFILE', 'announce_error_logs');
require_once INC_PATH . '/functions_ts_error_handler.php';
$compact = (isset ($_GET['compact']) ? 0 + $_GET['compact'] : 0);
$passkey = (isset ($_GET['passkey']) ? $_GET['passkey'] : '');
$peer_id = (isset ($_GET['peer_id']) ? $_GET['peer_id'] : '');
$port = (isset ($_GET['port']) ? 0 + $_GET['port'] : '');
$event = (isset ($_GET['event']) ? $_GET['event'] : '');
$info_hash = (isset ($_GET['info_hash']) ? $_GET['info_hash'] : '');
$downloaded = (isset ($_GET['downloaded']) ? 0 + $_GET['downloaded'] : '');
$uploaded = (isset ($_GET['uploaded']) ? 0 + $_GET['uploaded'] : '');
$left = (isset ($_GET['left']) ? 0 + $_GET['left'] : '');
$rsize = (isset ($_GET['numwant']) ? 0 + $_GET['numwant'] : (isset ($_GET['num_want']) ? 0 + $_GET['num_want'] : (isset ($_GET['num want']) ? 0 + $_GET['num want'] : 100)));
if (strpos ($passkey, '?'))
{
$tmp = substr ($passkey, strpos ($passkey, '?'));
$passkey = @substr ($passkey, 0, @strpos ($passkey, '?'));
$tmpname = substr ($tmp, 1, strpos ($tmp, '=') - 1);
$tmpvalue = substr ($tmp, strpos ($tmp, '=') + 1);
$GLOBALS[$tmpname] = $tmpvalue;
unset ($tmp);
unset ($tmpname);
unset ($tmpvalue);
}
if (get_magic_quotes_gpc ())
{
$info_hash = stripslashes ($info_hash);
$peer_id = stripslashes ($peer_id);
}
if (($passkey AND $passkey == 'tssespecialtorrentv1byxamsep2007'))
{
err ($l['registerfirst'] . $BASEURL . '/signup.php');
}
else
{
if (strlen ($passkey) != 32)
{
err ($l['invalidx'] . 'Passkey!');
}
else
{
if (strlen ($info_hash) != 20)
{
err ($l['invalidx'] . 'Info Hash!');
}
else
{
if (strlen ($peer_id) != 20)
{
err ($l['invalidx'] . 'Peer ID!');
}
else
{
if ((!$port OR 65535 < $port))
{
err ($l['invalidx'] . 'PORT');
}
}
}
}
}
$ip = htmlspecialchars ($_SERVER['REMOTE_ADDR']);
$agent = $_SERVER['HTTP_USER_AGENT'];
$seeder = ($left == 0 ? 'yes' : 'no');
dbconn ();
($get_torrent = @mysql_query ('SELECT id, name, size, category, doubleupload, added, banned, free, silver, seeders + leechers AS numpeers FROM torrents WHERE ' . @hash_where ('info_hash', $info_hash) . ' LIMIT 1') OR err ($l['sqlerror'] . ' T1'));
$torrent = mysql_fetch_assoc ($get_torrent);
if ((!$torrentid = intval ($torrent['id']) OR !$torrent))
{
err ($l['error1b']);
}
($get_user = @mysql_query ('SELECT id, status, uploaded, downloaded, enabled, usergroup, birthday FROM users WHERE passkey = ' . @sqlesc ($passkey) . ' LIMIT 1') OR err ($l['sqlerror'] . ' U1'));
$user = mysql_fetch_assoc ($get_user);
if (((!$user OR $user['enabled'] != 'yes') OR $user['status'] != 'confirmed'))
{
err ($l['error2b'] . $BASEURL);
}
require_once TSDIR . '/' . $cache . '/usergroups.php';
$usergroup = $usergroupscache[$user['usergroup']];
unset ($usergroupscache);
if ($usergroup['isbanned'] != 'no')
{
err ($l['error2b'] . $BASEURL);
}
if ($bannedclientdetect == 'yes')
{
require_once INC_PATH . '/functions_announce2.php';
clientbancheck ($peer_id);
}
$fields = 'peer_id, ip, port, uploaded, downloaded, seeder, last_action, (UNIX_TIMESTAMP() - UNIX_TIMESTAMP(last_action)) AS announcetime, UNIX_TIMESTAMP(NOW()) AS nowts, UNIX_TIMESTAMP(prev_action) AS prevts, userid';
unset ($self);
$resp = ($privatetrackerpatch != 'yes' ? 'd' . benc_str ('interval') . 'i' . $announce_interval . 'e' . benc_str ('peers') : 'd' . benc_str ('interval') . 'i' . $announce_interval . 'e' . benc_str ('private') . 'i1e' . benc_str ('peers')) . ($compact ? '' : 'l');
$limit = ($rsize < $torrent['numpeers'] ? ' ORDER BY RAND() LIMIT ' . $rsize : '');
$gp_eq = ($nc == 'yes' ? ' AND connectable = \'yes\'' : '');
$wantseeds = ($seeder == 'yes' ? ' AND seeder = \'no\'' : '');
$plist = '';
$get_peers = mysql_query ('' . 'SELECT ' . $fields . ' FROM peers WHERE torrent = ' . $torrentid . $gp_eq . $wantseeds . $limit);
while ($row = mysql_fetch_assoc ($get_peers))
{
$row['peer_id'] = hash_pad ($row['peer_id']);
if ($row['peer_id'] === $peer_id)
{
$userid = 0 + $row['userid'];
$self = $row;
continue;
}
if ($compact)
{
$peer_ip = explode ('.', $row['ip']);
$plist .= pack ('C*', $peer_ip[0], $peer_ip[1], $peer_ip[2], $peer_ip[3]) . pack ('n*', (int)$row['port']);
continue;
}
else
{
$resp .= 'd' . benc_str ('ip') . benc_str ($row['ip']) . (!$_GET['no_peer_id'] ? benc_str ('peer id') . benc_str ($row['peer_id']) : '') . benc_str ('port') . 'i' . $row['port'] . 'ee';
continue;
}
}
$resp .= ($compact ? benc_str ($plist) : '') . (substr ($peer_id, 0, 4) == '-BC0' ? 'e7:privatei1ee' : 'ee');
$selfwhere = 'torrent = ' . $torrentid . ' AND passkey = ' . sqlesc ($passkey);
if (!isset ($self))
{
$get_peers = mysql_query ('SELECT ' . $fields . ' FROM peers WHERE ' . $selfwhere . ' LIMIT 1');
$row = mysql_fetch_assoc ($get_peers);
if ($row)
{
$userid = 0 + $row['userid'];
$self = $row;
}
}
if ($bannedclientdetect == 'yes')
{
require_once INC_PATH . '/functions_announce2.php';
check_headers ();
}
if (((isset ($self) AND 0 < $announce_wait) AND $self['nowts'] - $announce_wait < $self['prevts']))
{
err ($l['antispam'] . $announce_wait);
}
if (!isset ($self))
{
if ($usergroup['canviewviptorrents'] != 'yes')
{
require_once TSDIR . '/' . $cache . '/categories.php';
foreach ($_categoriesC as $__left => $__right)
{
if ($__right['id'] == $torrent['category'])
{
$torrent['isviptorrent'] = $__right['vip'];
break;
}
}
foreach ($_categoriesS as $__left => $__right)
{
if ($__right['id'] == $torrent['category'])
{
$torrent['isviptorrent'] = $__right['vip'];
break;
}
}
unset ($_categoriesC);
unset ($_categoriesS);
unset ($__left);
unset ($__right);
if ($torrent['isviptorrent'] == 'yes')
{
send_action ($torrentid, $user['id'], $ip, $passkey, 'This user tried to download a VIP torrent!', true);
err ($l['dlerror']);
}
}
else
{
if ($usergroup['candownload'] != 'yes')
{
err ($l['dlerror']);
}
}
if ($check_valid == 'yes')
{
$query = @mysql_query ('' . 'SELECT torrent FROM peers WHERE torrent = \'' . $torrentid . '\' AND passkey = ' . @sqlesc ($passkey));
$valid = @mysql_num_rows ($query);
if ((1 <= $valid AND $seeder == 'no'))
{
err ($l['cerror']);
}
if ((3 <= $valid AND $seeder == 'yes'))
{
err ($l['cerror']);
}
}
$userid = 0 + $user['id'];
if (($usergroup['isvipgroup'] != 'yes' AND ($waitsystem == 'yes' OR $maxdlsystem == 'yes')))
{
$gigs = $user['uploaded'] / (1024 * 1024 * 1024);
$ratio = (0 < $user['downloaded'] ? $user['uploaded'] / $user['downloaded'] : 0);
if ($waitsystem == 'yes')
{
$elapsed = floor ((strtotime (TIMENOW) - strtotime ($torrent['added'])) / 3600);
if ($waitsystemtype == 1)
{
if (($ratio < $ratio1 OR $gigs < $upload1))
{
$wait = $delay1;
}
else
{
if (($ratio < $ratio2 OR $gigs < $upload2))
{
$wait = $delay2;
}
else
{
if (($ratio < $ratio3 OR $gigs < $upload3))
{
$wait = $delay3;
}
else
{
if (($ratio < $ratio4 OR $gigs < $upload4))
{
$wait = $delay4;
}
else
{
$wait = 0;
}
}
}
}
}
else
{
$wait = $usergroup['waitlimit'];
}
if (($elapsed < $wait AND 0 < $wait))
{
err ($l['werror'] . ' (' . ($wait - $elapsed) . $l['hour'] . ')');
}
}
if ($maxdlsystem == 'yes')
{
if ($waitsystemtype == 1)
{
if (($ratio < $ratio5 OR $gigs < $upload5))
{
$max = $slot1;
}
else
{
if (($ratio < $ratio6 OR $gigs < $upload6))
{
$max = $slot2;
}
else
{
if (($ratio < $ratio7 OR $gigs < $upload7))
{
$max = $slot3;
}
else
{
if (($ratio < $ratio8 OR $gigs < $upload8))
{
$max = $slot4;
}
else
{
$max = 0;
}
}
}
}
}
else
{
$max = $usergroup['slotlimit'];
}
if (0 < $max)
{
($res = @mysql_query ('SELECT userid FROM peers WHERE userid = \'' . $userid . '\' AND seeder = \'no\' LIMIT 1') OR err ($l['sqlerror'] . ' P1'));
$num = @mysql_num_rows ($res);
if ($max < $num)
{
err ($l['merror'] . $max);
}
}
}
}
}
else
{
require_once TSDIR . '/cache/freeleech.php';
if (($__F_START < TIMENOW AND TIMENOW < $__F_END))
{
switch ($__FLSTYPE)
{
case 'freeleech':
{
$torrent['free'] = 'yes';
$usergroup['canfreeleech'] = 'yes';
break;
}
case 'silverleech':
{
$torrent['silver'] = 'yes';
break;
}
case 'doubleupload':
{
$torrent['doubleupload'] = 'yes';
}
}
}
unset ($__F_START);
unset ($__F_END);
unset ($__FLSTYPE);
if ((($bdayreward == 'yes' AND $bdayrewardtype) AND $user['birthday']))
{
$curuserbday = explode ('-', $user['birthday']);
if (date ('j-n') === $curuserbday[0] . '-' . $curuserbday[1])
{
switch ($bdayrewardtype)
{
case 'freeleech':
{
$torrent['free'] = 'yes';
$usergroup['canfreeleech'] = 'yes';
break;
}
case 'silverleech':
{
$torrent['silver'] = 'yes';
break;
}
case 'doubleupload':
{
$torrent['doubleupload'] = 'yes';
}
}
}
}
unset ($curuserbday);
unset ($bdayreward);
unset ($bdayrewardtype);
$realupload = max (0, $uploaded - $self['uploaded']);
$upthis = ($torrent['doubleupload'] == 'yes' ? $realupload * 2 : $realupload);
$downthis = max (0, $downloaded - $self['downloaded']);
$upspeed = (0 < $realupload ? $realupload / $self['announcetime'] : 0);
$downspeed = (0 < $downthis ? $downthis / $self['announcetime'] : 0);
$announcetime = ($self['seeder'] == 'yes' ? 'seedtime = seedtime + ' . $self['announcetime'] : 'leechtime = leechtime + ' . $self['announcetime']);
if ((0 < $realupload OR 0 < $downthis))
{
if ((536870912 < $realupload AND $aggressivecheat == 'yes'))
{
send_action ($torrentid, $userid, $ip, $passkey, 'There was no Leecher on this torrent however this user uploaded ' . $realupload . ' bytes, which might be a cheat attempt with a cheat software such as Ratio Maker, Ratio Faker etc..');
}
$dled = ($torrent['silver'] == 'yes' ? $downthis / 2 : $downthis);
($update = mysql_query ('UPDATE users SET uploaded = uploaded + ' . $upthis . (($torrent['free'] != 'yes' AND $usergroup['canfreeleech'] != 'yes') ? ', downloaded = downloaded + ' . $dled : '') . ' WHERE id = \'' . $userid . '\'') OR err ($l['sqlerror'] . ' U2'));
}
if ($max_rate < $upspeed)
{
(mysql_query ('INSERT INTO cheat_attempts (added, uid, agent, transfer_rate, beforeup, upthis, timediff, ip, torrentid) VALUES(NOW(), ' . $userid . ', ' . sqlesc ($agent) . ', ' . sqlesc ($upspeed) . ', ' . sqlesc ($user['uploaded']) . ', ' . sqlesc ($realupload) . ', ' . sqlesc ($self['announcetime']) . ', ' . sqlesc ($ip) . ', ' . sqlesc ($torrentid) . ')') OR err ($l['sqlerror'] . ' C1'));
}
}
$dt = sqlesc (TIMENOW);
$updateset = $updateset_s = array ();
if ($event == 'stopped')
{
if (isset ($self))
{
if ($snatchmod == 'yes')
{
$updateset_s[] = 'seeder = \'no\'';
$updateset_s[] = 'connectable = \'no\'';
$updateset_s[] = '' . 'last_action = ' . $dt;
$updateset_s[] = '' . 'port = ' . $port;
$updateset_s[] = 'agent = ' . sqlesc ($agent);
$updateset_s[] = $announcetime;
$updateset_s[] = '' . 'upspeed = \'' . $upspeed . '\'';
$updateset_s[] = '' . 'downspeed = \'' . $downspeed . '\'';
$updateset_s[] = 'ip = ' . sqlesc ($ip);
$updateset_s[] = '' . 'uploaded = uploaded + ' . $realupload;
$updateset_s[] = '' . 'downloaded = downloaded + ' . $downthis;
$updateset_s[] = '' . 'to_go = ' . $left;
}
mysql_query ('DELETE FROM peers WHERE ' . $selfwhere);
if (mysql_affected_rows ())
{
$updateset[] = ($self['seeder'] == 'yes' ? 'seeders = seeders - 1' : 'leechers = leechers - 1');
}
}
}
else
{
if ($event == 'completed')
{
mysql_query ('UPDATE torrent_hit SET completed = \'yes\' WHERE id = \'' . $torrentid . '\' AND uid = \'' . $userid . '\'');
if ($snatchmod == 'yes')
{
$updateset_s[] = 'finished = \'yes\'';
$updateset_s[] = '' . 'completedat = ' . $dt;
}
$updateset[] = 'times_completed = times_completed + 1';
}
if (isset ($self))
{
$connectable = checkconnect ($ip, $port);
if ($snatchmod == 'yes')
{
$updateset_s[] = '' . 'seeder = \'' . $seeder . '\'';
$updateset_s[] = '' . 'connectable = \'' . $connectable . '\'';
$updateset_s[] = '' . 'last_action = ' . $dt;
$updateset_s[] = '' . 'port = ' . $port;
$updateset_s[] = 'agent = ' . sqlesc ($agent);
$updateset_s[] = $announcetime;
$updateset_s[] = '' . 'upspeed = \'' . $upspeed . '\'';
$updateset_s[] = '' . 'downspeed = \'' . $downspeed . '\'';
$updateset_s[] = 'ip = ' . sqlesc ($ip);
$updateset_s[] = '' . 'uploaded = uploaded + ' . $realupload;
$updateset_s[] = '' . 'downloaded = downloaded + ' . $downthis;
$updateset_s[] = '' . 'to_go = ' . $left;
}
$prev_action = sqlesc ($self['last_action']);
mysql_query ('' . 'UPDATE peers SET uploaded = ' . $uploaded . ', downloaded = ' . $downloaded . ', to_go = ' . $left . ', last_action = NOW(), prev_action = ' . $prev_action . ', seeder = \'' . $seeder . '\'' . (($seeder == 'yes' AND $self['seeder'] != $seeder) ? ', finishedat = ' . time () : '') . ('' . ' WHERE ' . $selfwhere));
if ((mysql_affected_rows () AND $self['seeder'] != $seeder))
{
if ($seeder == 'yes')
{
$updateset[] = 'seeders = seeders + 1';
$updateset[] = 'leechers = leechers - 1';
}
else
{
$updateset[] = 'seeders = seeders - 1';
$updateset[] = 'leechers = leechers + 1';
}
}
}
else
{
if (portblacklisted ($port))
{
err ($l['invalidx'] . 'PORT');
}
else
{
$connectable = checkconnect ($ip, $port);
if (($connectable == 'no' AND $nc == 'yes'))
{
err ($l['conerror']);
}
}
if ($snatchmod == 'yes')
{
$res = @mysql_query ('SELECT torrentid FROM snatched WHERE torrentid = \'' . $torrentid . '\' AND userid = \'' . $userid . '\' LIMIT 1');
if (@mysql_num_rows ($res) == 0)
{
mysql_query ('' . 'INSERT INTO snatched (torrentid, userid, port, startdat, last_action, agent, ip) VALUES (' . $torrentid . ', ' . $userid . ', ' . $port . ', ' . $dt . ', ' . $dt . ', ' . sqlesc ($agent) . ', ' . sqlesc ($ip) . ')');
}
}
$ret = mysql_query ('' . 'INSERT INTO peers (connectable, torrent, peer_id, ip, port, uploaded, downloaded, to_go, started, last_action, seeder, userid, agent, uploadoffset, downloadoffset, passkey) VALUES (\'' . $connectable . '\', ' . $torrentid . ', ' . sqlesc ($peer_id) . ', ' . sqlesc ($ip) . ('' . ', ' . $port . ', ' . $uploaded . ', ' . $downloaded . ', ' . $left . ', NOW(), NOW(), \'' . $seeder . '\', ' . $userid . ', ') . sqlesc ($agent) . ('' . ', ' . $uploaded . ', ' . $downloaded . ', ') . sqlesc ($passkey) . ')');
if ($ret)
{
$updateset[] = ($seeder == 'yes' ? 'seeders = seeders + 1' : 'leechers = leechers + 1');
}
}
}
if ($seeder == 'yes')
{
if ($torrent['banned'] != 'yes')
{
$updateset[] = 'visible = \'yes\'';
}
$updateset[] = 'last_action = NOW()';
}
if (0 < count ($updateset))
{
mysql_query ('UPDATE torrents SET ' . implode (',', $updateset) . ' WHERE id = ' . $torrentid);
}
if (0 < count ($updateset_s))
{
mysql_query ('UPDATE snatched SET ' . implode (',', $updateset_s) . ' WHERE torrentid = ' . $torrentid . ' AND userid = ' . $userid);
}
benc_resp_raw ($resp);
?>