Get the most out of your Centmin Mod LEMP stack
Become a Member

403 Forbidden NGINX

Discussion in 'Install & Upgrades or Pre-Install Questions' started by anthony parsons, Jul 18, 2018.

  1. anthony parsons

    anthony parsons Premium Member Premium Member

    77
    18
    8
    Feb 12, 2017
    Ratings:
    +22
    Local Time:
    5:04 AM
    Current yum stable
    10.1
    My test site has been working fine for the past couple of days. Suddenly, 403 Forbidden NGINX error. No access.

    I have disabled auto protect.sh as per Beta Branch - autoprotect.sh - apache .htaccess check & migration to nginx deny all

    I have checked CSF for my IP, IP returns csf.allow for it.

    I have checked the error log of the vhost and see:

    Code:
    2018/07/18 06:10:26 [error] 1366#1366: *19 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 27.254.82.224, server: anthonyparsons.com, request: "POST / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    2018/07/18 06:12:32 [error] 1802#1802: *1 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 118.127.122.136, server: anthonyparsons.com, request: "GET / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    2018/07/18 06:14:58 [error] 1802#1802: *4 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 118.127.122.136, server: anthonyparsons.com, request: "GET / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    2018/07/18 06:18:05 [error] 1896#1896: *1 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 118.127.122.136, server: anthonyparsons.com, request: "GET / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    2018/07/18 06:19:27 [error] 1951#1951: *1 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 118.127.122.136, server: anthonyparsons.com, request: "GET / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    2018/07/18 06:21:47 [error] 1951#1951: *4 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 27.254.82.224, server: anthonyparsons.com, request: "POST / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    2018/07/18 06:21:48 [error] 1951#1951: *5 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 27.254.82.224, server: anthonyparsons.com, request: "POST / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    2018/07/18 06:28:51 [error] 1951#1951: *10 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 14.142.115.178, server: anthonyparsons.com, request: "GET / HTTP/1.1", host: "anthonyparsons.com"
    2018/07/18 06:30:39 [error] 2176#2176: *1 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 118.127.122.136, server: anthonyparsons.com, request: "GET / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    2018/07/18 06:30:56 [error] 2176#2176: *2 directory index of "/home/nginx/domains/anthonyparsons.com/public/" is forbidden, client: 118.127.122.136, server: anthonyparsons.com, request: "GET / HTTP/1.1", host: "anthonyparsons.com", referrer: "https://anthonyparsons.com/"
    Access Log

    Code:
    27.254.82.224 - - [18/Jul/2018:06:10:26 +0000] "POST / HTTP/1.1" 403 162 "https://anthonyparsons.com/" "The Incutio XML-RPC PHP Library -- WordPress/4.9.7"
    118.127.122.136 - - [18/Jul/2018:06:12:32 +0000] "GET / HTTP/1.1" 403 162 "https://anthonyparsons.com/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.1.2 Safari/605.1.15"
    118.127.122.136 - - [18/Jul/2018:06:14:58 +0000] "GET / HTTP/1.1" 403 162 "https://anthonyparsons.com/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.1.2 Safari/605.1.15"
    118.127.122.136 - - [18/Jul/2018:06:18:05 +0000] "GET / HTTP/1.1" 403 162 "https://anthonyparsons.com/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.1.2 Safari/605.1.15"
    118.127.122.136 - - [18/Jul/2018:06:19:27 +0000] "GET / HTTP/1.1" 403 162 "https://anthonyparsons.com/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.1.2 Safari/605.1.15"
    54.36.148.97 - - [18/Jul/2018:06:20:12 +0000] "GET /component/k2/itemlist/category/22-software.html HTTP/1.1" 444 0 "-" "Mozilla/5.0 (compatible; AhrefsBot/5.2; +http://ahrefs.com/robot/)"
    27.254.82.224 - - [18/Jul/2018:06:21:47 +0000] "POST / HTTP/1.1" 403 162 "https://anthonyparsons.com/" "The Incutio XML-RPC PHP Library -- WordPress/4.9.7"
    27.254.82.224 - - [18/Jul/2018:06:21:48 +0000] "POST / HTTP/1.1" 403 162 "https://anthonyparsons.com/" "The Incutio XML-RPC PHP Library -- WordPress/4.9.7"
    138.204.71.60 - - [18/Jul/2018:06:26:21 +0000] "GET /wp-login.php HTTP/1.1" 404 162 "-" "Mozilla/5.0 (X11; Linux i686; rv:45.0) Gecko/20100101 Firefox/45.0"
    14.142.115.178 - - [18/Jul/2018:06:28:51 +0000] "GET / HTTP/1.1" 403 564 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36"
    What am I missing?
     
  2. anthony parsons

    anthony parsons Premium Member Premium Member

    77
    18
    8
    Feb 12, 2017
    Ratings:
    +22
    Local Time:
    5:04 AM
    Current yum stable
    10.1
    Disregard. Found the issue. All my files have been changed to .gz... argh.
     
  3. eva2000

    eva2000 Administrator Staff Member

    37,258
    8,140
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +12,532
    Local Time:
    4:04 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    woah how that happen ?
     
  4. anthony parsons

    anthony parsons Premium Member Premium Member

    77
    18
    8
    Feb 12, 2017
    Ratings:
    +22
    Local Time:
    5:04 AM
    Current yum stable
    10.1
    Me being a tool, experimenting with things I didn't understand the consequences to.
     
..