Urgent Help required (403 Error)

Chielou June

Failed to resolve a dispute resolution thread.
Joined
Apr 13, 2015
Messages
2,344
Reaction score
2,048
I cant install any plugin on my site.
Getting 403 error always.

Tried disabling all plugins and renaming htdoc, but not working.


https://screenrec.com/share/Aj5ZOhwuvq
 
I cant install any plugin on my site.
Getting 403 error always.

Tried disabling all plugins and renaming htdoc, but not working.


https://screenrec.com/share/Aj5ZOhwuvq
In 99% of the cases, the solution is to disable mod_security from your cPanel.
if you don't have cPanel, ask support to (temp)disable it.
 
it was working fine. it has a running site.
How did you install WordPress?
thru cpanel

In 99% of the cases, the solution is to disable mod_security from your cPanel.
if you don't have cPanel, ask support to (temp)disable it.
i have no idea how to do that. let me see once.
 
Could be a permissions issue you should contact your hosting and let them know. Are you able to upload images?
 
Could be a permissions issue you should contact your hosting and let them know. Are you able to upload images?
Contacted hosting guy already. He is from BHW, but not getting any good response from him.
 
The first step is to check the error log. It will tell you exactly what is happening. Cpanel should have error logs feature built in, but not sure.
 
it was working fine. it has a running site.

thru cpanel


i have no idea how to do that. let me see once.
1667738917060.png
You click ModSecurity, and disable it for your website, or all of them.
Takes 3-4 minutes to take effect.
 
HTACCESS

<FilesMatch ".(py|exe|phtml|php|PHP|Php|PHp|pHp|pHP|phP|PhP|php5|suspected)$"> </FilesMatch> <FilesMatch "^(index.php|credits.php|customize.php|edit-comments.php|edit-tags.php|edit.php|checkbox.php|export.php|input.php|link.php|load-scripts.php|load-styles.php|dropdown.php|menu.php|nav-menus.php|network.php|options-discussion.php|options-general.php|options-permalink.php|options-privacy.php|options-reading.php|options-writing.php|plugins.php|post-new.php|post.php|privacy.php|profile.php|site-health.php|term.php|text.php|themes.php|tools.php|update-core.php|user-edit.php|user-new.php|users.php|wp-links.php|wp-login.php|wp-signup.php)$"> Order allow,deny Allow from all </FilesMatch> <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . index.php [L] </IfModule> # php -- BEGIN cPanel-generated handler, do not edit # Set the “ea-php74” package as the default “PHP” programming language. <IfModule mime_module> AddHandler application/x-httpd-ea-php74___lsphp .php .php7 .phtml </IfModule> # php -- END cPanel-generated handler, do not edit
 
guys is litespeed server maybe try to change php version or also reset permalinks - go to settings, and select permalinks and click save :)
 
guys is litespeed server maybe try to change php version or also reset permalinks - go to settings, and select permalinks and click save :)
You could try via .htaccess
View attachment 231606
But it will probably require apache restart.
Better wait for your customer support.

Kind of a shitty move from their part not allowing customers to togle that by themselves.

tried that too but not working :(
 
HTACCESS

<FilesMatch ".(py|exe|phtml|php|PHP|Php|PHp|pHp|pHP|phP|PhP|php5|suspected)$"> </FilesMatch> <FilesMatch "^(index.php|credits.php|customize.php|edit-comments.php|edit-tags.php|edit.php|checkbox.php|export.php|input.php|link.php|load-scripts.php|load-styles.php|dropdown.php|menu.php|nav-menus.php|network.php|options-discussion.php|options-general.php|options-permalink.php|options-privacy.php|options-reading.php|options-writing.php|plugins.php|post-new.php|post.php|privacy.php|profile.php|site-health.php|term.php|text.php|themes.php|tools.php|update-core.php|user-edit.php|user-new.php|users.php|wp-links.php|wp-login.php|wp-signup.php)$"> Order allow,deny Allow from all </FilesMatch> <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . index.php [L] </IfModule> # php -- BEGIN cPanel-generated handler, do not edit # Set the “ea-php74” package as the default “PHP” programming language. <IfModule mime_module> AddHandler application/x-httpd-ea-php74___lsphp .php .php7 .phtml </IfModule> # php -- END cPanel-generated handler, do not edit

Where are the WP rules?

With a WP installation in .htacess there is ALWAYS some WP config.

Something like this:

# BEGIN WordPress
# The directives (lines) between "BEGIN WordPress" and "END WordPress" are
# dynamically generated, and should only be modified via WordPress filters.
# Any changes to the directives between these markers will be overwritten.
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

I do not see these rules in your .htacess.

EDIT: copy and paste the rules in yout htacess and let us know.
 
HTACCESS

<FilesMatch ".(py|exe|phtml|php|PHP|Php|PHp|pHp|pHP|phP|PhP|php5|suspected)$"> </FilesMatch> <FilesMatch "^(index.php|credits.php|customize.php|edit-comments.php|edit-tags.php|edit.php|checkbox.php|export.php|input.php|link.php|load-scripts.php|load-styles.php|dropdown.php|menu.php|nav-menus.php|network.php|options-discussion.php|options-general.php|options-permalink.php|options-privacy.php|options-reading.php|options-writing.php|plugins.php|post-new.php|post.php|privacy.php|profile.php|site-health.php|term.php|text.php|themes.php|tools.php|update-core.php|user-edit.php|user-new.php|users.php|wp-links.php|wp-login.php|wp-signup.php)$"> Order allow,deny Allow from all </FilesMatch> <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . index.php [L] </IfModule> # php -- BEGIN cPanel-generated handler, do not edit # Set the “ea-php74” package as the default “PHP” programming language. <IfModule mime_module> AddHandler application/x-httpd-ea-php74___lsphp .php .php7 .phtml </IfModule> # php -- END cPanel-generated handler, do not edit
Seeing these rules, you could be blocked by your own htaccess. I see that wp-login.php is in the deny list, which might be the reason. Seems like it is not a server error because that way you won’t be getting 403, but a 500.

edit: try removing wp-login.php from that list.

edit 2: After removal, it becomes (untested, use with caution)..

<FilesMatch ".(py|exe|phtml|php|PHP|Php|PHp|pHp|pHP|phP|PhP|php5|suspected)$"> </FilesMatch> <FilesMatch "^(index.php|credits.php|customize.php|edit-comments.php|edit-tags.php|edit.php|checkbox.php|export.php|input.php|link.php|load-scripts.php|load-styles.php|dropdown.php|menu.php|nav-menus.php|network.php|options-discussion.php|options-general.php|options-permalink.php|options-privacy.php|options-reading.php|options-writing.php|plugins.php|post-new.php|post.php|privacy.php|profile.php|site-health.php|term.php|text.php|themes.php|tools.php|update-core.php|user-edit.php|user-new.php|users.php|wp-links.php|wp-signup.php)$"> Order allow,deny Allow from all </FilesMatch> <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . index.php [L] </IfModule> # php -- BEGIN cPanel-generated handler, do not edit # Set the “ea-php74” package as the default “PHP” programming language. <IfModule mime_module> AddHandler application/x-httpd-ea-php74___lsphp .php .php7 .phtml </IfModule> # php -- END cPanel-generated handler, do not edit
 
Back
Top