SMFHacks.com

SMF Gallery Pro => Support => Topic started by: guest3817 on January 20, 2018, 11:04:49 am

Title: 403 forbidden error
Post by: guest3817 on January 20, 2018, 11:04:49 am
Hello

We have recently moved servers and have an issue with 403 errors when trying to view or delete gallery images.

we have smf 7.0.15 and smf gallery pro 7.2.4
running on a litespeed server with php 7. Mod_security is not running.
Initially everything seemed to be working fine with smf gallery however we now get 403 forbidden errors when trying to view or delete images in the gallery. We can add images without issues.

Can you shed any light on what might be causing this please?

htaccess file contains the following

# PHP settings
php_value upload_max_filesize 256M
php_value post_max_size 256M
php_value memory_limit 1024M

php_value max_execution_time 3000
php_value max_input_vars 10000


# Error logging
#php_flag display_startup_errors on
#php_flag display_errors on
#php_flag html_errors on

# Block wp-config.php access
<files wp-config.php>
order allow,deny
deny from all
</files>

# Block the include-only files
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^wp-admin/includes/ - [F,L]
RewriteRule !^wp-includes/ - [S=3]
RewriteRule ^wp-includes/[^/]+\.php$ - [F,L]
RewriteRule ^wp-includes/js/tinymce/langs/.+\.php - [F,L]
RewriteRule ^wp-includes/theme-compat/ - [F,L]
</IfModule>

# BEGIN litespeed noabort
<IfModule Litespeed>
        RewriteEngine On
        RewriteRule .* - [E=noabort:1]
</IfModule>
# END litespeed noabort

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress

# Exclude the file upload and WP CRON scripts from authentication
<FilesMatch "(async-upload\.php|wp-cron\.php|xmlrpc\.php)$">
    Satisfy Any
    Order allow,deny
    Allow from all
    Deny from none
</FilesMatch>

# Disable Directory Indexing and Browsing
Options -Indexes
Title: Re: 403 forbidden error
Post by: SMFHacks on January 20, 2018, 11:17:03 am
It is a mod_security issue contact your host to disable
https://wiki.simplemachines.org/smf/Mod_security_-_Having_problems_with_mod_security
Title: Re: 403 forbidden error
Post by: guest3817 on January 20, 2018, 11:46:38 am
Hi

This is a litespeed server and doesnt have mod_security running.

Doug
Title: Re: 403 forbidden error
Post by: SMFHacks on January 20, 2018, 12:02:53 pm
That's the only reason I can think. You would need to check your webservers error logs.
It is a rule that is filtering ;id= in the url.
Otherwise you will have to do a find and replace of ;id= to &id= in all the gallery files.