Jump to content

Site attacked - index.php removed


Digital Cipher

Recommended Posts

Hi all

I have had my site attacked, directories /img, /mails, /modules, /themes/prestashop/lang, /translations have had index.php removed.
Following the prestashop install instructions all the above directories had there permissions set to 777

6. While you have your FTP connected to your Web hosting server, make sure the following PrestaShop folders have ‘write’ permissions (also known as “CHMOD 777” – explanation of file permissions here) but do not apply these permissions recursively (to their subfolders): /config, /upload, /download, /tools/smarty/compile. Then make sure the following folders have ‘write’ permissions and apply these permissions recursively (to their subfolders): /img, /mails, /modules, /themes/prestashop/lang, /translations



Is this needed after the install is completed ?
For the time being i have reset all file/dir permissions to 755 except /tools/smarty/compile which is still 777

Can anyone advise me on this problem / attack

Link to comment
Share on other sites

What host do you use?

I had an attack on a low budget hosting company, but that time it was another website on the server that got hacked and got access to my folder so all files got infected with some kind of virus, and it was not prestashop but joomla I run at that site.. ended up having to reinstall everything :(

Link to comment
Share on other sites

my host is easyspace, i think the hacker removed the index.php files so they should try and list directory contents.

after checking my other sites hosted with easyspace my main web site support engine has being hacked, that directory had a permission of 755

Question for the preata team: which directories/files need 777 permissions (if any) ?????

Link to comment
Share on other sites

I's only a requirement to have 777 (666 - how apt) permissions IF YOUR SERVER REQUIRES IT and if it does then dump them. Most will work fine with 775 (664) or even 755(644). I would always suggest using the most stringent permissions that you can get away with.

I never believe everything I read - especially not on the internet :P

Paul

Link to comment
Share on other sites

  • 1 month later...

Most hackers that are trying to teach you a lesson will just delete your files, but other hackers would just replace your files with their version. It doesn't make since for Presta to not tell you to write protect your config files. Maybe they just for got to put that in the docs. I plan to try removing write protection from everything and see what get affected. It would also be nice if we had the option to move the compiled smarty templates out of the document root since this is a writable directory and probably will need to stay writable.

Link to comment
Share on other sites

I run multiple PS shops with 755 on folders and 644 on the files. No issues what so ever.
Even the installations run without a glitch.


I agree with you, I too use to do that; all depend on how did the sysadmin lockdown the server...
Link to comment
Share on other sites

Hi all

I have had my site attacked, directories /img, /mails, /modules, /themes/prestashop/lang, /translations have had index.php removed.
Following the prestashop install instructions all the above directories had there permissions set to 777

6. While you have your FTP connected to your Web hosting server, make sure the following PrestaShop folders have ‘write’ permissions (also known as “CHMOD 777” – explanation of file permissions here) but do not apply these permissions recursively (to their subfolders): /config, /upload, /download, /tools/smarty/compile. Then make sure the following folders have ‘write’ permissions and apply these permissions recursively (to their subfolders): /img, /mails, /modules, /themes/prestashop/lang, /translations



Is this needed after the install is completed ?
For the time being i have reset all file/dir permissions to 755 except /tools/smarty/compile which is still 777

Can anyone advise me on this problem / attack



I guess problem is with permissions. Try to restore previous permissions
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...