Core Accessible on Siteground Hosting

I’ve just moved a site (Modx 2.8.4) to Siteground hosting and I’m getting the old message that the core folder is at least partially accessible. I’ve got appropriate code in root .htaccess and core .htaccess. There’s a .htaccess file above the root in Siteground hosting but I’ve got no access to that - winder if it’s affecting things. If I try to access mysitedotcom/core I get a 403 message from the server.

Core .htaccess…

# deny access to _all_ files in the core, including changelog.txt and error.log
# original borrowed from owncloud

# line below if for Apache 2.4
<ifModule mod_authz_core.c>
    Require all denied

# line below if for Apache 2.2
<ifModule !mod_authz_core.c>
    deny from all
    Satisfy All

# section for Apache 2.2 and 2.4
IndexIgnore *

and I’ve also got this in root .htaccess…

# Block access to folders/files people have no need to touch
RewriteRule ^(\.|core|config\.core\.php) /index.php?q=doesnotexist[L]

As standard siteground uses NGINX so I don’t think your htaccess is picked up, I disable it bu going to your site tools >> Speed >> Caching and disabeling it, that should then work.

1 Like

You are quite right thank you Paul. That fixed the issue with the core being partially accessible. Pity not to be able to take advantage of the caching though.

Your site is still using the Dynamic Cache ( second tab on the same page ).

Ah ok - got it. FIrst time I’ve used Siteground. Thank you

The documentation also has examples for locking it down properly in NGINX.

1 Like

Thanks Mark but I don’t think I have access to web rules - it’s shared hosting with Siteground and I’ve just replaced an old WP site with a new Modx site.