老不死

  • 3 小时前
  • 注册于 4 天前
  • 0 次助人
  • 现在博客的主页可以访问,但是在需要账户登入的页面输入账户进行登入操作就返回 HTTP ERROR 403错误(浏览器疑似提示此网站没有证书。) 这些页面都可以通过ip地址进行正常访问。

    ssl证书是通过 1panel 申请的。

    比如访问:https://blog.jty.life/login?authentication_required 时的nginx日志显示

    懵懂的我想知道是不是nginx 自已的配置有问题:

    server {
    listen 80 default_server;
    listen 443 ssl http2 default_server;
    server_name *.jty.life;
    index index.php index.html index.htm default.php default.htm default.html;
    proxy_set_header Host $host;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Host $server_name;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection $http_connection;
    location ^~ /.well-known/acme-challenge {
    allow all;
    root /usr/share/nginx/html;
    }

    location / {
        proxy_pass http://127.0.0.1:8190; 
    }
    
    if ($scheme = http) {
        return 301 https://$host$request_uri; 
    }
    ssl_certificate /etc/nginx/ssl/fullchain.pem; 
    ssl_certificate_key /etc/nginx/ssl/privkey.pem; 
    ssl_protocols TLSv1.3 TLSv1.2 TLSv1.1 TLSv1; 
    ssl_ciphers ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES128-SHA256:!aNULL:!eNULL:!EXPORT:!DSS:!DES:!RC4:!3DES:!MD5:!PSK:!KRB5:!SRP:!CAMELLIA:!SEED; 
    ssl_prefer_server_ciphers on; 
    ssl_session_cache shared:SSL:10m; 
    ssl_session_timeout 10m; 
    error_page 497 https://$host$request_uri; 
    proxy_set_header X-Forwarded-Proto https; 
    add_header Strict-Transport-Security "max-age=31536000"; 

    }