UK WEB HOSTING FORUM FOR DISCUSSION ON WEB HOSTING SERVICE AND SUPPORT
LINUX HOSTING WINDOWS HOSTING PACKAGES SHOPPING CART OSCOMMERCE ZEN CART AGORA
ECOMMERCE HOSTING ASP MSSQL FRONTPAGE HOSTING PHP MYSQL HOSTING DISCUSSION FORUM
CPANEL RESELLER HOSTING DEDICATED SERVER VPS HOSTING PLESK VIRTUOZZO
Quick Search
Your forum announcement here!

  UK Web Hosting | Dedicated Server Windows and Linux VPS Forum > Web Hosting and Domains > Web Hosting Forum

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 31-03-2008, 06:42
new member
 
Join Date: Apr 2007
Posts: 2
Default Site Hacked - Links Added

Hi

Just wondering if anyone has had their site hacked over the weekend?? Received a disk usage exceeded message yesterday and just checked my site (not logged in to it for a few months). All of my HTML files have had dodgy links added to them on 27th March!!

Called support who asked me to send emails to support and abuse which I have done. But would like to delete the links asap.

Cheers
gaz
Reply With Quote
  #2 (permalink)  
Old 31-03-2008, 11:16
Quality Assurance
 
Join Date: Sep 2007
Posts: 559
Send a message via MSN to eUK-Nick
Default

Hello Gareth,

Martin has already replied to your email. He has suggested a few steps in it.
__________________
Nick
Quality Assurance & Analysis
EMAIL & MSN : nick@eukhost.com
Reply With Quote
  #3 (permalink)  
Old 10-04-2008, 09:54
Junior Member
 
Join Date: Jan 2007
Posts: 22
Default

This happened to me too. On March 17th.

I noticed both a line that contained a load of links and a different line starting eval(base64_decode...

Note: Decoding the code leads to another base 64 decode which generates a remote procedure call to the phpAdsNew program installed on ppc100 dot info. This is obviously a malicious ad server.

Be sure to remove both lines from your files.

I'm contemplating writing a script to automatically remove the links from the infected files, but this largely depends on whether I can knock one up quicker than it would take me to manually delete the lines. I'll post the script here if I do end up writing one.
Reply With Quote
  #4 (permalink)  
Old 10-04-2008, 10:06
DavidAllen's Avatar
Premium Member
 
Join Date: Jan 2007
Location: Amersham
Posts: 330
Send a message via MSN to DavidAllen Send a message via Skype™ to DavidAllen
Default

What server are you guys on - as often this type of think can affect a lot of accounts on the same server and others on that same server might be unaware that they are also affected.
__________________
David Allen - www.serina.co.uk
Reply With Quote
  #5 (permalink)  
Old 10-04-2008, 10:09
Junior Member
 
Join Date: Jan 2007
Posts: 22
Default

Btw, if anyone want to search their files for this infection, you can search for a number of things.

1. The eval(base64... statement.

Code:
find . -name "*" -exec grep "eval(base64_decode(" -l {} \;
2. The id of the divider surrounding the links, though this is likely to be changed periodically by the attacker.

Code:
find . -name "*" -exec grep "myDiv412" -l {} \;
3. dc.write statements responsible for hiding the dodgy links.

Code:
find . -name "*" -exec grep "dc\.write(" -l {} \;
4. Some of the text in the block of dodgy links, though when I tried this it didn't return all infected files because the links varied.

Code:
find . -name "*" -exec grep "mind in love saying" -l {} \;
Note: These commands will search recursively from the current directory in all files. It could take some time. You could change the command to search the public_html directory in all html files by changing the command to the following (using example 1):

Code:
find public_html -name "*.html" -exec grep "eval(base64_decode(" -l {} \;

Last edited by brighter : 10-04-2008 at 10:13.
Reply With Quote
  #6 (permalink)  
Old 10-04-2008, 10:15
Junior Member
 
Join Date: Jan 2007
Posts: 22
Default

firefly

I spoke to someone via chat. They say that no other accounts are infected, but I doubt they could know that for certain in the time it took them to check.
Reply With Quote
  #7 (permalink)  
Old 10-04-2008, 10:38
Junior Member
 
Join Date: Jan 2007
Posts: 22
Default

Ok. I've got a basic script. It's not perfect. It looks at all html files and replaces all lines that match the matchstring with nothing. It creates backup files with a .bak extension whether a file is altered or not.

Code:
find . -name "*.html" -exec sed -e '/^matchstring*/d' -i.bak {} \;
So, replace matchstring with the malicious line you want removed.

BACKUP ALL FILES FIRST!! just in case something goes wrong.

Edit: And if you want to check other files, just change the *.html to *.whatever, or just use * alone to search all files.
Reply With Quote
  #8 (permalink)  
Old 10-04-2008, 14:41
jc8654's Avatar
Moderator
 
Join Date: May 2007
Location: Manchester, United Kingdom
Posts: 1,219
Send a message via MSN to jc8654
Default

I had this a while ago. It was only the one account on the VPS which seemed a bit odd. I had a backup copy so just wiped it and reuploaded as it is only a CSS and HTML site.
__________________
Jonathan Crass
Joint Partner in Checker Design

North East Website design
UK based monitoring
Cheap UK Web Hosting

Save Jodrell Bank: www.savejodrellbank.org.uk

eUKhost Forum Moderator
Reply With Quote
  #9 (permalink)  
Old 10-04-2008, 16:59
eUKhost.com's Avatar
Chief Marketing Officer
 
Join Date: Sep 2005
Posts: 4,261
Send a message via AIM to eUKhost.com Send a message via MSN to eUKhost.com
Default

Firefly was reserved for customers who needed SSH access and no "security settings". We have 2 servers reserved for such customers as some customers using CMS like Joomla or Mambo need mod_security and php disabled_functions disabled on the server.

We have basic security for this 2 servers but they are not as secure as other servers.
__________________
UK Web Hosting || Business Hosting || eUKhost Knowledgebase
Toll Free : 0808 262 0255 || MSN : mark @ eukhost.com || AIM : eukmark
A bunch of Sheep led by a Lion is better than a bunch of Lions led by a Sheep.
__________________________________________________

Great Opportunity :: Join our Affiliate Program for FREE and earn 20% commission on each referral.
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is On
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT. The time now is 04:09.

 

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by Web Hosting 3.1.0
Copyright © 2001-2008, eUKhost.com. All rights reserved.

 
Site Map

knowledgebase articles

popular blog categories