Results 1 to 4 of 4

Thread: winsock IP issue

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Aug 2000
    Posts
    258

    Question

    Iv'e written a winsock app . It's two seperate pieces a server and a client . Heres my systems
    I have 3 pc's all on a lan through a linksys stwitch . all the machines have a local IP (on the lan) . I also have a dialup connection on all machines . Now If I run the server
    with no OUTSIDE CONNECTION (ie. the net) the clients on the lan set their Ip to the Ip the server is running on , and connect with no problem . If I establish a connection Via Dialup to the outside world and run the server the winsock reports the Local IP (winsock1.localIp) not the Dialup IP
    yet it seems to listen on both Ip's but shows only the LAN ip ? is this a bug/feature of winsock or poor coding ?
    Visual Basic 6 SP4 on win98se

    QUIT THE RAT RACE BECAUSE YOUR MESSING THE WORLD UP !!!!!

  2. #2
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649
    I don't know if I should call this a bug or not. The limitation is that you get the IP address from a simple property and not an array.
    On one of my servers I have mapped two IP addesses to one NIC but the INet control only reports one of them.
    The reason that your server application listen to both IP's is because it doesn't map it to the address itself but rather the port your using. Every call that comes in via IP that maps to the correct port is captured by your application.

    Best regards

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Aug 2000
    Posts
    258
    This does't sound very good to me especialy if the server is run on a machine that supports multiple domains like a web server . How can I fix this ?
    Visual Basic 6 SP4 on win98se

    QUIT THE RAT RACE BECAUSE YOUR MESSING THE WORLD UP !!!!!

  4. #4
    Fanatic Member
    Join Date
    Jul 2000
    Location
    Manchester NH
    Posts
    833
    There is an API to determine the IPs that are associated with your computer.

    if you created a new post with the subject "determine computer IP addresses" you will get more help.


    ----------


    quickly i would batch

    route print

    to a text file and read it.

    The interface column will return all IPs that are associated with your computer
    Kurt Simons
    [I know I'm a hack but my clients don't!]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width