473,325 Members | 2,785 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,325 software developers and data experts.

Capturing IP Address

tma
How does one capture the IP address of an incoming connection to an ASPX
page?

Nov 18 '05 #1
4 3051
Hi,

You can use the HttpReferer to find the IP address .

Thanks
Raghavendra
"tma" <tm*@allisconfusing.net> wrote in message
news:eH*************@TK2MSFTNGP09.phx.gbl...
How does one capture the IP address of an incoming connection to an ASPX
page?

Nov 18 '05 #2
"tma" <tm*@allisconfusing.net> wrote in message
news:eH*************@TK2MSFTNGP09.phx.gbl...
How does one capture the IP address of an incoming connection to an ASPX
page?


Best to do a newsgroup search before posting - this question was asked and
answered only yesterday...
Nov 18 '05 #3
Raghavendra T V wrote:
Hi,

You can use the HttpReferer to find the IP address .


Generally speaking, you cannot. First, referrer identifies the resource (web
page) from which the request was made (hyperlink clicked on), which is
normally not the user's host. If you don't click a hyperlink or use any
other navigation control, there'll be no referrer anyway. Also, both clients
and proxies are free to change or omit this header, so don't blindly assume
it's there.

You can obtain the client IP address through the HttpRequest.UserHostAddress
property, but that's only the last client in the request chain (could be a
proxy for example).

You'll have to use a mixture of UserHostAddress and extension headers like
X-Forwarded-For to obtain more relibale data, and even that won't be
perfect.

Cheers,
--
Joerg Jooss
jo*********@gmx.net
Nov 18 '05 #4
Try Request.ServerVariables("REMOTE_ADDR")

"tma" <tm*@allisconfusing.net> wrote in message
news:eH*************@TK2MSFTNGP09.phx.gbl...
How does one capture the IP address of an incoming connection to an ASPX
page?


Nov 18 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Jay Xx | last post by:
I have an IFrame in design mode. I've tried a bunch of things to capture key presses in that IFrame, but I can't seem to get it. I can capture key presses outside the IFrame fine. I have this...
33
by: Joerg Schuster | last post by:
Hello, Python regular expressions must not have more than 100 capturing groups. The source code responsible for this reads as follows: # XXX: <fl> get rid of this limitation! if...
14
by: Brent Burkart | last post by:
I am trying to capture the Windows Authenticated username, but I want to be able to capture the login name that exists in IIS, not Windows. In order to enter my company's intranet through the...
2
by: Stampede | last post by:
Hi guys & girls, I would like to write some kind of "Head-Tracking-Software", which uses a WebCam to react to the movement of the head of the person sitting in front of the monitor. I searched...
6
by: Ed Leafe | last post by:
I've been approached by a local business that has been advised that they need to start capturing and archiving their instant messaging in order to comply with Sarbanes-Oxley. The company is largely...
2
by: veronicab | last post by:
Hi, I have a small JavaScript code in a page to trap when user presses Return key. My problem is that if you visit the page and then enter a different url in address field, and press Return,...
15
by: Nayan | last post by:
Hi, Can anyone suggest working sample of capturing a window's picture? I tried a few, but couldn't get the image. I don't know why those functions are not getting the image. Note: I want the...
2
by: GS | last post by:
How can one avoid capturing leading empty or blank lines? the data I deal with look like this "will be paid on the dates you specified. xyz supplier amount: $100.52 when: September 07,...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.