is there a way to get the ip address of a forwarded machine from http request header in asp.net mvc?

Viewed 85

I have two LANs(for examle:A,B) that are connected using a Mikro Tik Router and my web application is hosted on B,when users from A send request to B the IP Address of all of them are same(ip address of router). i can't get the ip address of forwarded machine. I tried these lines of code but not worked: HttpContext.Current.Request.UserHostAddress; HttpContext.Current.Request.Headers["X-Forwarded-For"]

Is there any other way?

0 Answers
Related