Dotclear

Vous n'êtes pas identifié(e).

Annonce

13 février 2024 Sortie de Dotclear 2.29

#1 2019-12-01 18:24:40

joshuajayg
Membre
Inscription : 2019-12-01

403 Forbidden

I am not sure when this error began since I updated twice before trying to post again.  When I try and post a new entry (or even save for publishing later) I get a 403 Forbidden error. 

I checked my folder permissions and I have it at 755.  I'm not sure where to go from here.  I don't have an .htaccess file.

Joshua

Hors ligne

#2 2019-12-03 05:47:30

ben_griffith
Membre
Lieu : Wiltshire
Inscription : 2009-09-28

Re : 403 Forbidden

Hi joshuajayg

Years ago, I used to have an error 500 for almost 6 months caused by an incompatibility between Dotclear and the server's PHP version. Once my provider updated the software on his end, suddenly it was gone.

In the recent years, providers have changed a lot their certificates and SSL connections.

You might have to upload a .htaccess file. If I remember correctly, I once read that the recent changes in PHP7 require now more likely to need a .htaccess file.

Just try this:

<Files 403.shtml>
order allow,deny
allow from all
</Files>

I use Scite to edit my files. Text editors on systems (like Notepad or TextEdit might not allow to create a file with no title and an extension .htaccess).

Also, check that you are up to date on your provider side. Older versions of PHP are no longer supported. PHP7 doesn't support mySQL and you need to enable msSQLi.

And finally, make sure that your {blog}/cache and {blog}/public folders have got 777.
755 is only required for the install files.

Dernière modification par ben_griffith (2019-12-03 05:51:42)


I Dotclear.

Hors ligne

#3 2019-12-04 04:28:02

joshuajayg
Membre
Inscription : 2019-12-01

Re : 403 Forbidden

Thank you for the reply, ben.  I tried everything you suggested and no go.  Still getting the 403 error. 

I added .htaccess with and without the lines you suggested.

I was already running PHP 7.2 and hadn't updated that from my last successful posting.  I downgraded to below 7.0 and then all the way to 7.3 with no change in outcome.  Mysqli was enabled on all versions.

I also changed folder permissions as you suggested. 

I'm still at a loss.

Is there a log in the dotclear files on my server that can give me some more information as to why I'm running into a 403 error?

Hors ligne

#4 2019-12-04 05:30:36

ben_griffith
Membre
Lieu : Wiltshire
Inscription : 2009-09-28

Re : 403 Forbidden

Hi Joshua

- My domain also has got a pre-installed 500.shtml, 404.shtml and 403.shtml. They are there by default. Can you download them and check the content?

- In what order is your blog?  domain.com / Blog folder / index.php etc   or    domain.com / index.php.
Create a index.html with some text and load it up as domain.com/index.html: Can you read the content or do you get a 403 error?

- Create a new test blog and don't add any content. Still 403 error?


I Dotclear.

Hors ligne

#5 2019-12-04 13:18:19

joshuajayg
Membre
Inscription : 2019-12-01

Re : 403 Forbidden

Ben, before I continued on any more of your suggestions, I made a test user.  I have him default admin privileges and wrote a test entry.  It uploaded fine.

Now I need to track down why my login isn't able to post.


EDIT: This isn't a user error, it's a text format error.  I can save posts using wiki text formatting but not XHTML.  Both users have the same problem.

Dernière modification par joshuajayg (2019-12-04 13:36:59)

Hors ligne

#6 2019-12-05 04:04:26

ben_griffith
Membre
Lieu : Wiltshire
Inscription : 2009-09-28

Re : 403 Forbidden

Hi joshua

Congrats for finding the reason.
In Dashboard, go to Users, and check the permissions for your main user. You should have that little star which is for Blogadmin.
Set a tick before the name and click on Set Permissions.
You should have "default" and a green tick in Status.

Now this issue: wiki text formatting but not XHTML.

This is easy. On the right top side next to Username Logout, click on My Preferences.
In tab "My options", scroll down to Edition and eh voila, you can change it there.

Dernière modification par ben_griffith (2019-12-05 04:26:29)


I Dotclear.

Hors ligne

#7 2019-12-06 03:35:17

joshuajayg
Membre
Inscription : 2019-12-01

Re : 403 Forbidden

I am posing as the "superadmin".  I have default permissions and the green status.

I think the you are also telling me how to change my preferred formatting?  I don't want to change my default formatting, I want to be able to post in xhtml but I am unable to.  If I post in the wiki format, things work cleanly.  If I try and post in xhtml, I get the 403 forbidden error. 

Also, when trying to change my preferences.  I got the 403 error again.

Hors ligne

#8 2019-12-06 05:46:54

ben_griffith
Membre
Lieu : Wiltshire
Inscription : 2009-09-28

Re : 403 Forbidden

Then set up a new test blog, see if it has the same issue. If not, you can reinstall the blog with the issue.


I Dotclear.

Hors ligne

#9 2019-12-08 21:06:17

joshuajayg
Membre
Inscription : 2019-12-01

Re : 403 Forbidden

I installed a new blog and still have the exact same issue in the new blog.  I found a lot of differences between file permission in the new blog directory and my active blog directory.  I think I'll just accept posting in wiki format only for now.  It has become more of a hassle than seems to be worth it.

Hors ligne

#10 2019-12-14 06:58:29

ben_griffith
Membre
Lieu : Wiltshire
Inscription : 2009-09-28

Re : 403 Forbidden

Hello Joshua

What you can do is to set up a new blog with new folder (means new address), import your backup file and see how it works. If that works fine, then you can have a redirection from the old address to the new address and no-one will notice this if you don't rely on public attention.


I Dotclear.

Hors ligne

#11 2020-01-06 00:45:46

joshuajayg
Membre
Inscription : 2019-12-01

Re : 403 Forbidden

And... now it works fine again.  I have not changed anything since last time I posted.  Must have been the hosting server doing something funny.

Hors ligne

#12 2020-01-07 05:40:47

ben_griffith
Membre
Lieu : Wiltshire
Inscription : 2009-09-28

Re : 403 Forbidden

Excellent. Nothing is better than problems that go on their own.


I Dotclear.

Hors ligne

#13 2022-04-25 03:52:05

musinou
Membre
Lieu : Montréal, Québec
Inscription : 2006-11-25
Site Web

Re : 403 Forbidden

I have had the same issue, a forbidden page after saving some configuration or using wiki and sometime for xhtml pages too. I looked at permissions. Changed .htaccess. I looked a php error logs. Looked a database permissions. I did a manual update of dotclear. I tried multiple php versions. I ended up trying to take the plugins away and finally found that it seams to be related to dcckeditor and dclegacyeditor. When I deleted them from the plugin folder, it worked. Now I don't have menus to make me choose between wiki or xhtml.

Any idea why dcckeditor and dclegacyeditor plugins would make some forbidden errors?

Hors ligne

#14 2022-04-25 14:52:59

musinou
Membre
Lieu : Montréal, Québec
Inscription : 2006-11-25
Site Web

Re : 403 Forbidden

So, I was wrong. When I take dcckeditor and dclegacyeditor plugins out of the plugin directory, I can save a change of configuration but I still can't save a post. I still have a forbidden page when I try to save a post.

Hors ligne

#15 2022-04-27 16:37:13

musinou
Membre
Lieu : Montréal, Québec
Inscription : 2006-11-25
Site Web

Re : 403 Forbidden

I have found the problem. It is modsecurity on the server.

One can whitelist their ip by changing
/usr/local/apache/modsecurity-cwaf/custom_user.conf

and adding with their own ip
# Allow unrestricted access from 192.0.2.1
SecRule REMOTE_ADDR "@ipMatch 192.0.2.1" "phase:1,id:200000001,nolog,allow"

Hors ligne

#16 2022-07-16 04:06:48

ben_griffith
Membre
Lieu : Wiltshire
Inscription : 2009-09-28

Re : 403 Forbidden

Thanks musinou for letting us know.
Server setting changes can be a pain. I had to live with a 501 error more than 6 months...


I Dotclear.

Hors ligne

Vous n'êtes pas identifié(e).

Pied de page des forums

Sites map