From the course: Complete Guide to Open Source Security

Unlock the full course today

Join today to access over 24,800 courses taught by industry experts.

Opening up the file server

Opening up the file server

- [Instructor] We've set up our lab as we want it, but let's say our requirements changed and we're asked to provide access to the file server remotely. We won't do that directly from WAN to LAN, but instead we'll go via the Nginx proxy service in the DMZ. Let's put a proxy endpoint on Nginx. We'll configure a proxy stream to rejetto for any traffic arriving at the proxy server on port 8088. sudo nano /etc/nginx/nginx.conf. And we'll go down to the end of the http section and we'll add a stream section, server, listen 8088 and proxy_pass, any traffic on 88 to 172.16.1.2 port 80. And that's it. And we'll sudo systemctl restart nginx. We now need to configure access to the application server. In order to pass traffic within the firewall zones, we need to enable routing between the DMZ and the LAN. The app server's running on IP address 172.16.1.2, and we set up the Nginx proxy to listen on port 8088. So let's now add a rule to forward traffic arriving at port 8088 on the firewall to the…

Contents