Jump to content

Странные файлы html

Featured Replies

Так как я не разбирась в html посмотрите вы.

Странным для меня стало потому что я прочитал коментарий "Говорят есть бэкдор в этом скрипте. Будьте осторожны."

Файл с названием :




<?php

session_start();


require 'config.php';

require 'php/functions.php';


require 'lang/'.LANG.'.php';


@mysql_connect(DB_HOST, DB_USER, DB_PASS) or die('Please view the <b>config.php</b> file.');

@mysql_select_db(DB_NAME) or die('Please view the <b>config.php</b> file.');


define('WEB', ($_SERVER['SCRIPT_NAME'] == '/gallery.php')?'/':dirname($_SERVER['SCRIPT_NAME']).'/');

define('HTTP', '__'.$_SERVER['HTTP_HOST'].WEB);


// Check

$month = mysql_fetch_row(mysql_query('SELECT COUNT(*) FROM `album` WHERE `upload_id` IS NULL AND `date` > NOW() - INTERVAL 1 MONTH'));


if(!$month[0])

{

$week = array(0);

$today = array(0);

} else

{

$week = mysql_fetch_row(mysql_query('SELECT COUNT(*) FROM `album` WHERE `upload_id` IS NULL AND `date` > NOW() - INTERVAL 1 WEEK'));


if(!$week[0])

{

$today = array(0);

} else

{

$today = mysql_fetch_row(mysql_query('SELECT COUNT(*) FROM `album` WHERE `upload_id` IS NULL AND `date` > NOW() - INTERVAL 1 DAY'));

}

}


// Gallery

$order = isset($_GET['order'])?$_GET['order']:'new';

$range = isset($_GET['range'])?$_GET['range']:'all';

$page = isset($_GET['page'])?((int) $_GET['page']):1;


$query = ' FROM `image` WHERE (SELECT `upload_id` FROM `album` WHERE `id`=`image`.`album_id`) IS NULL';


// Range

switch($range)

{

default:

$range = 'all';

break;

case 'month':

if($month[0]) $query .= ' AND `date` > NOW() - INTERVAL 1 MONTH';

break;

case 'week':

if($week[0]) $query .= ' AND `date` > NOW() - INTERVAL 1 WEEK';

break;

case 'today':

if($today[0]) $query .= ' AND `date` > NOW() - INTERVAL 1 DAY';

break;

}


if($range != 'all')

{

$check = $$range;


if(!$check[0]) $range = 'all';

}


// Page

$total = mysql_fetch_row(mysql_query('SELECT COUNT(*)'.$query));

$pages = ceil($total[0]/25);


if($page < 1) $page = 1;

if($page > $pages) $page = $pages;


$min = $page - 4;

$max = $page + 4;


if($min < 1)

{

$max += 1 - $min;

$min = 1;

}


if($max > $pages)

{

$min += $pages - $max;


if($min < 1) $min = 1;


$max = $pages;

}


// Order

switch($order)

{

default:

$order = 'new';


$query .= ' ORDER BY `date` DESC';

break;

case 'popular':


$query .= ' ORDER BY `views` DESC';

break;

}


$_SESSION['order'] = $order;

$_SESSION['range'] = $range;

$_SESSION['page'] = $page;


$images = mysql_query('SELECT `id`, `extension`'.$query.' LIMIT '.($page*25-25).',25');


require 'view/gallery.html';

файл index.php



<?php

session_start();


require 'config.php';

require 'php/functions.php';


require 'lang/'.LANG.'.php';


@mysql_connect(DB_HOST, DB_USER, DB_PASS) or die('Please view the <b>config.php</b> file.');

@mysql_select_db(DB_NAME) or die('Please view the <b>config.php</b> file.');


define('WEB', ($_SERVER['SCRIPT_NAME'] == '/index.php')?'/':dirname($_SERVER['SCRIPT_NAME']).'/');

define('HTTP', '__'.$_SERVER['HTTP_HOST'].WEB);


// Album request

if(isset($_GET['a']))

{

$album_id = alphaID($_GET['a'], true);


if(mysql_num_rows($result = mysql_query('SELECT `date`, `upload_id` FROM `album` WHERE `id`='.$album_id)))

{

$row = mysql_fetch_row($result);


$album_date = $row[0];


if($row[1])

{

mysql_query('UPDATE `album` SET `upload_id`=NULL WHERE `id`='.$album_id);

}


$album = mysql_query('SELECT `id`, `extension`, `size`, `views` FROM `image` WHERE `album_id`='.$album_id.' ORDER BY `id` DESC');


$image = mysql_fetch_assoc($album);


if(mysql_num_rows($album) == 1)

{

unset($album);

} else

{

mysql_data_seek($album, 0);

}

}

} else


// Image request

if(isset($_GET['i']))

{

$image_id = alphaID($_GET['i'], true);


if(mysql_num_rows($result = mysql_query('SELECT `id`, `album_id`, `extension`, `size`, `views` FROM `image` WHERE `id`='.$image_id)))

{

$image = mysql_fetch_assoc($result);


$row = mysql_fetch_row(mysql_query('SELECT `date` FROM `album` WHERE `id`='.$image['album_id']));


$album_date = $row[0];


$album = mysql_query('SELECT `id`, `extension` FROM `image` WHERE `album_id`='.$image['album_id'].' ORDER BY `id` DESC');


$album_id = $image['album_id'];


if(mysql_num_rows($album) == 1) unset($album);

}

}


if(isset($image))

{

$alpha = alphaID($image['id']);


mysql_query('UPDATE `image` SET `views`='.(++$image['views']).' WHERE `id`='.$image['id']);


# Slides

if(isset($album))

{

$slide = isset($_GET['slide'])?((int) $_GET['slide']):-1;


$max_slide = ceil(mysql_num_rows($album)/6) - 1;


if($slide < 0 || $slide > $max_slide)

{

$index = 0;


while($tmp = mysql_fetch_assoc($album))

{

$index++;


if($tmp['id'] == $image['id']) break;

}


$slide = ceil($index/6) - 1;


mysql_data_seek($album, 0);

}

}


require 'view/album.html';

} else

{

$recent = mysql_query('SELECT `id` FROM `album` WHERE `upload_id` IS NULL ORDER BY `id` DESC LIMIT 0,12');


$total_albums = mysql_fetch_row(mysql_query('SELECT COUNT(*) FROM album'));

$total_images = mysql_fetch_row(mysql_query('SELECT COUNT(*) FROM image'));


$total_amounts = sprintf($lang['total_amounts'],

'<span>'.sprintf($lang['total_albums'], number_format($total_albums[0], 0, '.', $lang['thousand_separator'])).'</span>',

'<span>'.sprintf($lang['total_images'], number_format($total_images[0], 0, '.', $lang['thousand_separator'])).'</span>'

);


require 'view/upload.html';

}

Вот полный комплект файлов, посмотрите ipboard.xml.gz

И вопрос а чем мне гразит то что если там и вправду есть бэкдор?

Link to comment
https://ipbmafia.ru/topic/1723-strannye-fajly-html/
Share on other sites

Причём здесь форум Тех. поддержка IPB?

Думаю Дарк разберётся с этим, переезжаем :)

Link to comment
https://ipbmafia.ru/topic/1723-strannye-fajly-html/?&do=findComment&comment=10628
Share on other sites

Причём здесь форум Тех. поддержка IPB?

Думаю Дарк разберётся с этим, переезжаем :)

Думаю стоит открыть новый раздел тех поддержки по Web :)

Link to comment
https://ipbmafia.ru/topic/1723-strannye-fajly-html/?&do=findComment&comment=10632
Share on other sites

И первый и второй файл чистые, архив смотреть не стал, подозреваю, что и там все в порядке.

Link to comment
https://ipbmafia.ru/topic/1723-strannye-fajly-html/?&do=findComment&comment=10637
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.


Guest
Ответить в этой теме...

Последние посетители 0

  • No registered users viewing this page.