# Proxied wowza getting users ip address from either x-forwarded-for or x-real-ip

**URL:** <https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421>\
**Category:** Wowza Streaming Engine\
**Created:** [February 18, 2014, 11:43am UTC](https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421 "2014-02-18T11:43:08Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/system/32/447_2.png) [@system](https://community.wowza.com/u/system)\
**Post date:** [February 18, 2014, 11:43am UTC](https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421/1 "2014-02-18T11:43:08Z")

</div>

I have wowza behind a proxy and am looking for the proper header to set such that wowza sees the request coming from a users ip instead of from the ip address of the proxy. I’ve tried to set the x-real-ip but that fails… I’ve also tried x-forwarded-for but that also fails. Can you guys let me know which header value to set so that wowza uses that ip instead of the ip of the proxy?

Thanks for all your help.

Jake

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [February 18, 2014, 7:18pm UTC](https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421/2 "2014-02-18T19:18:41Z")

</div>

Jake,

I think this has come up recently, and that there was not a way to do that.

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [February 19, 2014, 9:40pm UTC](https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421/3 "2014-02-19T21:40:00Z")

</div>

Jake,

I think it must be REMOTE\_ADDR in the case of HTTP requests at least. I don’t think you can proxy rtmp streams.

Richard

---

<div class="post-metadata">

**Author:** ![Jake\_Hilton](https://avatars.discourse-cdn.com/v4/letter/j/9f8e36/32.png) [@Jake\_Hilton](https://community.wowza.com/u/Jake_Hilton)\
**Post date:** [February 18, 2014, 2:15pm UTC](https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421/4 "2014-02-18T14:15:39Z")

</div>

Richard,

Thank you for the confirmation on that. I was hoping I could modify the request to expose it to wowza. Do you know what property of the request wowza uses to determine the ip of the client?

Thanks,

Jake

---

<div class="post-metadata">

**Author:** ![Chris\_Bell1](https://avatars.discourse-cdn.com/v4/letter/c/a587f6/32.png) [@Chris\_Bell1](https://community.wowza.com/u/Chris_Bell1)\
**Post date:** [July 24, 2020, 4:28am UTC](https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421/5 "2020-07-24T04:28:23Z")

</div>

Hi,

I too would like to use Playback Security using XFF (X-Forwarded-For) or set c-ip to XFF. We have a load balancer appliance in front of some edge servers and would like to use the option “Include client IP address in hash generation”. The Secure URL works fine however it seems the hash is using the c\_ip.

I will look into if I can preserve the c\_ip somehow however it would also make sense if I can choose the XFF header instead. If this is not possible perhaps there is an API hook where I can change the method.

Please let me know if anyone has an answer or has made any progress.

Chris

---

<div class="post-metadata">

**Author:** ![video\_streaming](https://avatars.discourse-cdn.com/v4/letter/v/22d042/32.png) [@video\_streaming](https://community.wowza.com/u/video_streaming)\
**Post date:** [July 24, 2020, 4:45pm UTC](https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421/6 "2020-07-24T16:45:38Z")

</div>

Hey Chris, that code will not use the XFF. However, it is possible to retrieve, but you’d have to build your own.

---

<div class="post-metadata">

**Author:** ![0cadfc0a9c12bbbb8112](https://avatars.discourse-cdn.com/v4/letter/0/7ea924/32.png) [@0cadfc0a9c12bbbb8112](https://community.wowza.com/u/0cadfc0a9c12bbbb8112)\
**Post date:** [January 30, 2023, 5:06pm UTC](https://community.wowza.com/t/proxied-wowza-getting-users-ip-address-from-either-x-forwarded-for-or-x-real-ip/421/7 "2023-01-30T17:06:53Z")

</div>

Hello, I also have same issue. Anyone found solution?  
Thanks
