Language: VB6
How would I obtain my real IP address that my isp gives me. I can only get my fake lan ip address, but i'm not sure how to get the real one. Thx
Will need to contact a third party server. I suggest connecting via CHAT to battle.net and it will give you your IP address.
I'm sure there's an easier way than that.
Since you're using Visual Basic, I will assume you mean using some edition of Microsoft Windows.
The IP is bound to a network interface. Using the WIN32 API, you can enumerate network adapters. Each enumeration returns a structure containing information. This is enough help to get you started.
Let us know what you come up with!
Grok, that wont even begin to help him unless he is connected directly to a WAN interface, which I sincerely doubt based on his post.
Quote from: FuZe- on September 18, 2003, 05:09 PM
Language: VB6
How would I obtain my real IP address that my isp gives me. I can only get my fake lan ip address, but i'm not sure how to get the real one. Thx
The easiest way would be to find a site that determines your external IP address. Use the INET OCX to download the page and parse the IP out of the data.
My ISP used to make me use a proxy for port 80, so it would be wrong.
Good site is www.network-tools.com
The class I wrote to do this connected to http://www.whatismyip.com (http://www.whatismyip.com) and parsed the HTML to find the IP. Even enumerating the local IP addresses won't give you the WAN address if you're behind a router or two.
what the fuck, why do people ignore my posts all the time?
Quote from: FuZe- on September 18, 2003, 05:09 PM
Language: VB6
How would I obtain my real IP address that my isp gives me. I can only get my fake lan ip address, but i'm not sure how to get the real one. Thx
I think if you go to 'Local Area Network' in the D2 login page, it will give you your correct IP... If not then Storm had a good idea. I'm not sure how accurate it is though because I can't even host games on war3 due to my firewall/router.
Storm -- maybe he tried it and it didn't work so instead of flaming you he said nothing... or maybe he hasn't checked the forum again... who knows.
Quote from: St0rm.iD on September 19, 2003, 05:53 AM
what the fuck, why do people ignore my posts all the time?
Probably because Grok posted after you and bears much authority and hardly ever makes a mistake, so when he now might have made one, everyone jumped at the chance to bash him.
Quote from: Adron on September 19, 2003, 07:18 AM
Quote from: St0rm.iD on September 19, 2003, 05:53 AM
what the fuck, why do people ignore my posts all the time?
Probably because Grok posted after you and bears much authority and hardly ever makes a mistake, so when he now might have made one, everyone jumped at the chance to bash him.
St0rm, heh, it's been observed dozens of times that people ignore your completely legitimate and workable solutions.
Adron, I make plenty of mistakes. But you're correct, there are a number of insecure people here who are more comfortable being critics than being creators. Rather than come up with solutions themselves, and let other people criticize them, they bash people who are trying to offer help. Camel is a primary example of such a person.
Quote from: Grok on September 19, 2003, 10:29 AMAdron, I make plenty of mistakes. But you're correct, there are a number of insecure people here who are more comfortable being critics than being creators. Rather than come up with solutions themselves, and let other people criticize them, they bash people who are trying to offer help. Camel is a primary example of such a person.
Interesting view. My intent, however, was to save him some agony.
[edit] I didn't give an answer because St0rm already did.
I guess I'm confused... Are you looking for some type of code to write in VB 6.0 or VB .Net to reveal your real IP or are you just trying to generally find your ISP given IP...
Also are you behind a router of some sort or are you hooked directly to the net via modem. If that's the case there are multiple ways of finding your IP given to you by your ISP... If your looking for your LAN IP then I suggest the normal methods either in code using winsock or dsSocket32 or you could just go to Command Prompt or DOS and type ipconfig /all
If you are looking for your ISP given IP then I suggest looking at your router settings... If you don't have access to that type of information (assuming your even behind a router) then I can't help you in terms of coding because I'm not at my computer but on my g/f's comp.
So again, what exactly are you trying to do in terms of the questions asked above?
Quote from: DarkVirus on September 20, 2003, 07:42 PM
I guess I'm confused... Are you looking for some type of code to write in VB 6.0 or VB .Net to reveal your real IP or are you just trying to generally find your ISP given IP...
Also are you behind a router of some sort or are you hooked directly to the net via modem. If that's the case there are multiple ways of finding your IP given to you by your ISP... If your looking for your LAN IP then I suggest the normal methods either in code using winsock or dsSocket32 or you could just go to Command Prompt or DOS and type ipconfig /all
If you are looking for your ISP given IP then I suggest looking at your router settings... If you don't have access to that type of information (assuming your even behind a router) then I can't help you in terms of coding because I'm not at my computer but on my g/f's comp.
So again, what exactly are you trying to do in terms of the questions asked above?
He's using vb6, so ipconfig /all wouldn't be too useful, unless he parses the information from there (I don't know how to use a shell like that, though). I get the impression that he isn't behind a router, but that he has multiple network connections.
It might be useful to ask, what type of internet connection do you have? If it's DSL, it's harder since there's a LAN connection to your modem, then another connection from the modem to the internet.
...or you could do what I said, which takes, oh, maybe thirty seconds to implement?
That involves depending on a third-party server, though, which isn't always a good idea. Although, you can list several battle.net servers so if one is down, or you're banned from one, you can just switch.
Thanks guys for the help
to obtain ur ip address go to start>run and type in
"winipcfg" with out the " though ur system ip configuration should come up
Quote from: DarkExperts on September 29, 2003, 05:18 PM
to obtain ur ip address go to start>run and type in
"winipcfg" with out the " though ur system ip configuration should come up
Except....
1) this will only work on win9x, not NT/2k/XP.
2) this will not give you your external IP address.
3) this is not a programmatic solution.
Quote from: K on September 29, 2003, 05:25 PM
Quote from: DarkExperts on September 29, 2003, 05:18 PM
to obtain ur ip address go to start>run and type in
"winipcfg" with out the " though ur system ip configuration should come up
1) this will only work on win9x, not NT/2k/XP.
Can you ipconfig for that :)
Doesn't ICQ give the real IP?
Quote from: Seven on October 16, 2003, 07:03 AM
Doesn't ICQ give the real IP?
That's a terribly unreliable way of getting it.
Or you could do what I said.
http://www.ThugProductions.net/
Go to the Downloads section.
All you need. It is freaken awsome.
:) ;) :D ;D >:( :( :o 8) ??? ::) :P :-[ :-X :-\ :-:-* :'(
Add a winsock control then winsock1.LocalIP
that wouldn't get your real ip for example if your on a router.
Quote from: Fr0z3N on October 18, 2003, 09:43 AMthat wouldn't get your real ip for example if your on a router.
Of course it would get your real [internal] IP. The problem is he wants his external IP address, which is known only by the NAT device and other things outside it.
Or you could so what I said.
Quote from: St0rm.iD on October 19, 2003, 07:51 PM
Or you could so what I said.
Perhaps he wants a variety of options?
Why do people keep posting suggestions for getting the local IP?
Because they don't know the difference?