# Wie man set\_real\_ip\_from für discourse festlegt

**URL:** <https://meta.discourse.org/t/how-to-set-set-real-ip-from-for-discourse/74416>\
**Category:** Support\
**Created:** [20. November 2017 um 11:02 UTC](https://meta.discourse.org/t/how-to-set-set-real-ip-from-for-discourse/74416 "2017-11-20T11:02:33Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)\
**Post date:** [22. November 2017 um 20:09 UTC](https://meta.discourse.org/t/how-to-set-set-real-ip-from-for-discourse/74416/10 "2017-11-22T20:09:51Z")

</div>

Looks good to me, you highlight the **super important** fact there that you can not just trust any IP address with that header, cause if you did, user IPs can be spoofed.

An alternative I have seen (that we use in haproxy) is setting the IP only if we see some top secret header that we have the CDN always send us.

---

_[View the full topic](https://meta.discourse.org/t/how-to-set-set-real-ip-from-for-discourse/74416)._
