Re: KNOW MI WAN IP WITH C#
- From: "Lau Lei Cheong" <leu_lc@xxxxxxxxxxxx>
- Date: Fri, 15 Jul 2005 09:58:26 +0800
You may create a webservice that'll return client's IP and use "wsdl"
command to generate proper C# class for you if you want.
Or create a plain ASP/ASP.NET page that'll return client's IP, and use
webclient class to read it.
There're many ways to implement it.
"Soussan Mikael" <mikael@xxxxxxxxxxxxxxxxxxxx> ¼¶¼g©ó¶l¥ó·s»D:42d61152$0$1254$8fcfb975@xxxxxxxxxxxxxxxxxx
> that's to say i have to implement a server located on the web and to ask
> him for my ip adress???
> How czn I do in C# to ask various websites that print my ipadress?
>
> "Arthur M." <ArthurM@xxxxxxxxxxxxxxxxxxxxxxxxx> a écrit dans le message de
> news: E51C6F62-FF07-4FEC-AEE7-94E7AE58FE41@xxxxxxxxxxxxxxxx
>> There is really no way to do that reliably using your local system as the
>> only point of query. Once IP packet leaves your system it can get
>> translated
>> and changed any number of times without your system's knowledge, that is
>> hte
>> whole point of NAT.
>>
>> If your firewall is local to your PC, you can query the firewall
>> configuration to determine external IP address, however, if firewall is a
>> different system - the only truly reliable way to determine translated IP
>> address is to query a remote system outside your firewall for it to
>> report
>> which IP address you APPEAR to be coming from.
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> "Soussan Mikael" wrote:
>>
>>> Hello evrybody,
>>>
>>> I have to implement a simple module that can retrieve my own ip adress
>>> but
>>> if i am behind a firewall i have to get my wan ip that's to say my
>>> external
>>> ip adress!!!
>>>
>>> I don't know how to do this!!!I see a little at WMI but anything.
>>> My dns client updater can see my external ip, but if i launch ipconfig i
>>> see
>>> only my lan 192.168.1.3)
>>>
>>> Thank for helping!!
>>>
>>>
>>>
>
>
.
- References:
- KNOW MI WAN IP WITH C#
- From: Soussan Mikael
- RE: KNOW MI WAN IP WITH C#
- From: Arthur M.
- Re: KNOW MI WAN IP WITH C#
- From: Soussan Mikael
- KNOW MI WAN IP WITH C#
- Prev by Date: Copy the contents of one StringCollection to another
- Next by Date: EventLogTraceListener incompatible with typical usage of Trace?
- Previous by thread: Re: KNOW MI WAN IP WITH C#
- Next by thread: [ANN] nVision Software Technologies Releases New Application Service Level Auditing Tool
- Index(es):
Relevant Pages
|