From 2ba0fab6d4b45e9131eac3228f5e17ce213ff534 Mon Sep 17 00:00:00 2001 From: Icexist Date: Sat, 12 Jun 2021 14:40:05 -0700 Subject: [PATCH] Add note to clarify requirement for reverse proxy (#18133) * Add note to clarify requirement for reverse proxy HA after 2021.7 will require a trusted reverse proxy IP, but there isn't anywhere that I've seen that explicitly states this requirement and how to achieve it. * Update http.markdown --- source/_integrations/http.markdown | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/source/_integrations/http.markdown b/source/_integrations/http.markdown index 8bdf1dd1fa4..c5b9dcfd93d 100644 --- a/source/_integrations/http.markdown +++ b/source/_integrations/http.markdown @@ -105,6 +105,15 @@ http: The [Set up encryption using Let's Encrypt](/blog/2015/12/13/setup-encryption-using-lets-encrypt/) blog post gives you details about the encryption of your traffic using free certificates from [Let's Encrypt](https://letsencrypt.org/). +When using a reverse proxy, you will need to enable the `use_x_forwarded_for` and `trusted_proxies` options. Requests from reverse proxies will be blocked if these options are not set. + +```yaml +http: + use_x_forwarded_for: true + trusted_proxies: + - 172.30.33.0/24 # Add the IP address of the proxy server +``` + ## APIs On top of the `http` integration is a [REST API](https://developers.home-assistant.io/docs/api/rest), [Python API](https://developers.home-assistant.io/docs/api_lib_index) and [WebSocket API](https://developers.home-assistant.io/docs/api/websocket) available.