Forbidden 403

Discussion in 'General' started by Jeffrey m Dessy, Dec 16, 2022.

  1. Jeffrey m Dessy

    Jeffrey m Dessy New Member

    I am having an issue that everyone says is solved with adding user www-data to the ispconfg group. I have and it has always been this way. I have this problem showing up randomly and I can't seem to figure out why. I have looked in the error logs for nginx and it says nothing about my ip address being blocked. I have turned off ids for anon... I don't get why I am forbidden. The funny thing is if I am logged in to the wordpress site everything works just fine but as soon as I log out of wordpress I see the 403 error. This same site has had not one change since it was last working just this morning. it keeps happening and so far I have just been rolling backups back out but I can't rely on that forever and I am hoping someone can point me toward a fix. please let me know if I can provide any logs or anything to lead us to an answer as right now I can't log in or anything. I still have access to the config server so let me know if you need anything there too please. Also forgot to mention I am using nginx not apache.
     
    Last edited: Dec 16, 2022
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    You mix up things here, adding the user www-data to ISPConfig group can not fix such an issue as it's completely unrelated. The group ispconfig is not used for anything related to websites on your system. What you did just opens a huge security hole, as all your sites can take over your whole server and all other sites now. So it's important that you undo this immediately.

    Back to your original problem, have a look at the error.log of the website to find out why you get a forbidden error.
     
  3. Jeffrey m Dessy

    Jeffrey m Dessy New Member

    Thank you for your guidance. I have already started the process of reverting to a backup in order to set permissions accordingly back to before added www-data to that group :p as for the logs am I just supposed to be looking through the error log in /web1/logs. before I reimaged I went ahead and took a look and there were two things in the logs

    FastCGI sent in stderr: "PHP message: PHP Warning: getimagesize(*ttps://domain.com/data:image/svg+xml,%3Csvg%20xmlns=): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found
    in /var/www/clients/client1/web1/web/wp-content/plugins/specify-missing-image-dimensions/specify-missing-image-dimensions.php on line 79" while reading response header from upstream, client: 15.235.80.19, server: domain.com, request: "GET /shop/food-dry-goods/seachem-nutr-chlorella-flasks-30g/?nowprocket=1 HTTP/2.0", upstream: *astcgi://unix:/var/lib/php7.4-fpm/web1.sock:", host: "domain.com"

    and
    directory index of "/var/www/domain.com/web/wp-admin/css/" is forbidden, client: 43.130.28.188,

    neither one of these is my address.. but could it point to php for some reason?
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    The first one is a 404 error, so no forbidden error. This is just about being unable to resize a image file as this image files doe snot exist. And /var/www/domain.com/web/wp-admin/css/ should give you a forbidden error as there is and should not be a standard index page in this directory. So that's both fine.

    There might be no error in the configuration, and you get the forbidden message from WordPress or a WordPress plugin. Try disabling the custom error pages option in website settings for this site in ISPConfig and check if the message changes.
     
  5. Jeffrey m Dessy

    Jeffrey m Dessy New Member

    I don't know what time zone you are in but this has to be the best response time on any forum :p
    I will be looking for this setting as soon as it is back up and restored. When I go to sites do I just click the site and look for custom error pages under one of the tabs? I am sorry this is my first month using ispconfg and it has been a small learning curve for me.

    EDIT* found it ... in the manual! ctrl F for the win
     
    Last edited: Dec 16, 2022
  6. Jeffrey m Dessy

    Jeffrey m Dessy New Member

    I also want to say thank you so I bought a manual tonight as a resource and a way to say you are awesome and this software is amazing!
     
    till likes this.
  7. Jeffrey m Dessy

    Jeffrey m Dessy New Member

    You are more than awesome... as soon as I could see the actual error I was able to fix it.. it was a security plugin thinking I am a bot.. will look into it later but for now I am just disabling it! This was the answer I needed " disabling own error documents"! after days of this I really appreciate your fast response times and solid answers. Thanks again and good night
     

Share This Page