pythonsecurityserverweb-applicationsids

Setting up reverse proxy for firewall


I have created an simple web application firewall that can detect multiple types of attack using ml and I want to test it . FOR that I I have set up this firewall at front of website such that it will intercept request going for website and allow only legiment traffic .

I set-up the revsered proxy server for this using appache (on windows) but didn't work Any solution Note :the firewall was made as and web application too ,I can't provide detail code here


Solution

  • Try NginX, here is a sample code

    server {
        listen 80;
        server_name your_domain.com;
    
        location / {
            proxy_pass http://localhost:your_webapp_port;
            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;
        }
    }
    

    consider running the website with https for security.