ROOTPLOIT
Server: nginx/1.18.0
System: Linux snslocalproxy 6.8.0-149-generic #149~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Wed Oct 28 20:58:45 UTC x86_64
User: root (0)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: //home/yopromote.mytiny.us
# HTTP → HTTPS redirect
server {
    listen 80;
    server_name yopromote.mytiny.us;

    location /.well-known/acme-challenge/ {
        root /var/www/html;
    }

    location / {
        return 301 https://$host$request_uri;
    }
}

# Upstreams
upstream react_frontend {
    server 192.168.1.200:8081;
}

upstream laravel_backend {
    server 192.168.1.200:9099;
}

# HTTPS server
server {
    listen 443 ssl;
    server_name yopromote.mytiny.us;

    ssl_certificate /etc/letsencrypt/live/yopromote.mytiny.us/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/yopromote.mytiny.us/privkey.pem;

    add_header Strict-Transport-Security "max-age=31536000; includeSubDomains" always;

    # Laravel API
    location /api/ {
        proxy_pass http://laravel_backend/;
        proxy_http_version 1.1;

        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }

    # React Frontend
    location / {
        proxy_pass http://react_frontend;
        proxy_http_version 1.1;

        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;

        client_max_body_size 32M;
    }
}