By FreeFly on
installed drupal, a few times.
Now am trying to secure it more with 'security review' but am stuck with the following 2 errors.
-PHP files in the Drupal files directory can be executed.
-Some files and directories in your install are writable by the server.
I have already (after backup of the directory)
directory's are 755
files 644
.htaccess 444
settings.php 444
Also tried 555 for files and folders 444.
Still keep getting the warnings, is secure review maby not compete compatible with 7.25 ?
its hosting space from strato, lucky with ssh access.
You can ignore the warnings. But really dont like that whole idea.
Comments
Does it not tell you which
Does it not tell you which files it's referring to?
Contact me to contract me for D7 -> D10/11 migrations.
Or anything really. I'm friendly, and open to work or conversation.
Yes its telloing me wich
Yes its telloing me wich files.
Its saying all files have wrong perms. changed it for now back to 755 / 664 and the settings.php back,
/misc
/sites
/modules
/themes
only thing i see is in /sites/all/modules/security_review stores the file_write_test. files
But again i can change the perms for the directory 444 555 it keeps writeing inside there.
So tried 555 on the directory's that keeps security_review from writeing the file.
Going to test a bit with 550 and 440 to.
But last night things where fine for security_review
only the whole drupal where screwed bacause the way to tight permissions.
Weird. useing 440 on files
Weird. useing 440 on files and 755 on directory's
with 555 on directory's am getting the help page when im clicking details for security review.
SLowly things start to get mangled again. lucky i now have a backup directory
Permissions should be as
Permissions should be as follows:
Folders:
sites/default - 644
every other folder - 755
Files:
sites/default/settings.php - 444
every other file - 644
You also should have no .php files in your sites/default/files folder (or any other files folder if you are using multisite).
Contact me to contract me for D7 -> D10/11 migrations.
Or anything really. I'm friendly, and open to work or conversation.
Did the above settings.
Did the above settings. result is am getting the installation screen back.
Tried the same settings on my virtual machine with own installed linux. same result the installation screen.
sites/default - 644 is not allowed to have 644. but need to be 755.
not finetuned it but with 644 you get the installation screen.
Ok, i have now one error left. on my Virtual machine.
on the webhosting i have 2 errors left.
"PHP files in the Drupal files directory can be executed."
Because its working better on
Because its working better on my own linux server in virtualbox.
Besides the "PHP files in the Drupal files directory can be executed."
Am not sure if security review can reas the .htacces correct in /default/files
Pre-installation the sites
Pre-installation the sites/default folder needs to be 755. Drupal will change this to 644 during installation.
Contact me to contract me for D7 -> D10/11 migrations.
Or anything really. I'm friendly, and open to work or conversation.
=-=
Perms may be environmentally dependent to some degree as a Drupal installation uses 555 on default folder/s in my installations.
If i change the sites/default
If i change the sites/default manual to 644 it start to display the installation screen. Until i changed it back to 755 then i get the administrator screen back. also my linux VM showes it green and secure then. only the problem with .htaccess or something like that in files shows error.
Ok. looks like the directory
Ok. looks like the directory permissions are right, i need to keep a directory list in file for later.
Its a bit different from what all drupal sites say.
Now i have only the little error left. "PHP files in the Drupal files directory can be executed."
And i think thats maby error in security_review, because the .htaccess file looks fine.
Probleem you need the execute on places or drupal site break terrible
Same problems
I am on a shared hosting system and I get the same errors on security review. Directories are set to 755, files to 644, settings.php, index.php and all .htaccess files (per SA-CORE-2013-003) are set to 444.
A patch shown in the issues of Security_Review fixed the error about executable PHP files.
Did your errors go away or are you ignoring them? Are you also on a shared host?
Trial and error fix
I changed all directories to 555 except for sites/default/files which I had to set to 755 to make it work. Don't ask me why but it works.