Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I have a site built on the ModX Evo CMS. I have noticed that almost every day the .htaccess file is deleted meaning the FURLs no longer work. I have scanned for viruses and found nothing. Does anyone know what this means or what I can do?

share|improve this question
add comment

1 Answer 1

Possibilities

  1. ModX EVO CMS is deleting it
  2. Malware/Virus is deleting it
  3. Shared Hosting is causing it, i.e malware/virus on another user account spreading to yours.
  4. Web host is deleting it for one reason or another.

How to Investigate

  1. Contact your web host if shared hosting
  2. Check logs

Quick Fix

I'm assuming that you are using CHMOD 744 or 777, there is no reason why the owner group would require write access, so it's time to revoke write permissions.. this will mean that the file can not be deleted, can't be altered, unless you login via control panel or FTP and chmod before hand.

Change the CHMOD of the htaccess to 444, this will disable write permissions on public, group and owner. Additionally if your CMS uses a config file that is used to content to the database you can also use this to further your security. As I normally say in another of answers on Pro Web Masters.. Never under estimate the power of CHMOD, it causes problems for hackers, malware, and just generally stuff you don't want happening to your site.

share|improve this answer
    
Hmm its weird - when I try to alter the permissions via FTP it just reverts back to 644. Is this meant to occur? –  MeltingDog Apr 12 '13 at 0:03
    
do in control panel –  bybe Apr 12 '13 at 0:11
    
Hmm for whatever reason the file is not showing in filemanager... perhaps because it is a .htaccess file? –  MeltingDog Apr 12 '13 at 0:21
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.