• Hi there, at some point recently (not sure when exactly) my .htaccess file completely disappeared/ got renamed to htaccess-workaround (there is a file called that which has exactly the same content as the .htaccess file had) and so broke all the sites on my wordpress network ??

    I’m pretty sure wordfence was to blame.

    I’ve just managed to fix it but re-adding a copy from a backup but wondered how this might have happened and could be avoided in the future (I’ve only recently moved over to wordfence from ithemes security because that was causing loads of 500 errors due to how much stuff it adds to .htaccess and was hoping security plugin breaking site such issues were behind me). Has this happened to anyone else?

    Here are my general server details for info:

    General

    OS: Linux
    Server: Apache

    PHP

    v5.6.24-0+deb8u1
    GD: 2.1.1-dev
    Magic Quotes GPC: Off
    Memory Limit: 512.0 MiB
    Max Upload Size: 128.0 MiB

    MYSQL

    v5.5.52-0+deb8u1
    Maximum No. Connections: 100
    Maximum Packet Size: 16.0 MiB
    Data Disk Usage: 65.0 MiB
    Index Disk Usage: 19.5 MiB

Viewing 2 replies - 1 through 2 (of 2 total)
  • This has happened to several of my sites too. Investigating now. I’ll report what I find out if you do too :]

    Hi jdaviescoates and karelles,
    I want to confirm that we don’t have any function that can rename “.htaccess” file to “htaccess-workaround” or any other name.

    When Wordfence inserts any code in “.htaccess” file, it’s wrapped between:
    # Wordfence WAF
    and
    # END Wordfence WAF

    By this way you can easily identify any code blocks inserted by the plugin, possible reasons for such file name modification could be:
    – Any other plugin that can do some operations on “.htaccess” file (backup, modify, create new one, etc…).
    – Any other account that has access to your server.
    – One of your web host support agents.

    Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘.htaccess files completely disappeared’ is closed to new replies.