Simple questions about a socket
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6

Thread: Simple questions about a socket

  1. #1
    Join Date
    May 2010
    Posts
    6

    Simple questions about a socket

    Hi All,
    My first thread....

    I am working on a project and I am stuck with a conceptual idea.

    I am going to try and explain things here... but feel free to ask if something is not clear enough.

    I have a system that has a single host and a single client.

    This system is connected together using a simple Ethernet hub.

    The client is to remain connected to the host AT ALL TIMES - no exceptions.

    A person (user) can change the IP of the host which will trigger automatically a message to the client that my ip has change to xxx.xxx.xxx.xxx and a new connection is established.

    All this works fine - so far.

    I am running into some problems (explained below) and I wanted to change my implementation.

    I was thinking about assigning my host an IP of 10.1.4.2 and my client 10.1.4.3 (private network IPs) but here is where the problem arises.

    If I want to connect my system to my home network - then my laptop cannot talk to the client since my laptop gets an ip assignment from my ISP and the network has private IPs.

    Is there a list of IPs that allow me to communicate between my laptop and my client?

    Thanks

  2. #2
    Join Date
    Feb 2005
    Posts
    2,160

    Re: Simple questions about a socket

    Clarify some. Is the laptop part of the same network as the client/server? If so, how does it connect to your ISP? A different ethernet? If not, then by design, private networks are private and inaccessible from the internet.

  3. #3
    Join Date
    May 2010
    Posts
    6

    Re: Simple questions about a socket

    thanks hoxsiew,
    Well, the laptop is connected on the same hub, but it dynamically leases an IP from the ISP.

    I realize that the private network will not be accessible, but what I wanted to know if there are some IPs I can use for example (224.0.0.x) that can act as a private network but still be accessible by the laptop.

  4. #4
    Join Date
    Feb 2005
    Posts
    2,160

    Re: Simple questions about a socket

    I'm still having trouble picturing the topology of this network. If the laptop is on the same hub but is obtaining an address that is not recognized by the other nodes on the hub, then something is messed up. Is it a smart-hub, or even a router? How does the laptop connect to the internet (broadband router, firewall gateway, DSL, T1)?

  5. #5
    Join Date
    May 2010
    Posts
    6

    Re: Simple questions about a socket

    The laptop (and the ISP) are the variables here in this topology. The "system" I am interested in is the constant and the laptop in my question, can be connected to any network through that hub.

    This hub is a simple hub, not a smart one and not a router.

    Let me ask a different question....

    What IPs are available that would work as a private network but could be accessed externally?

    For example, 10.1.4.x is a private network but cannot be accessed externally.

    thanks.

  6. #6
    Join Date
    Feb 2005
    Posts
    2,160

    Re: Simple questions about a socket

    There are no such private networks. That's the whole point of a private network. For an addressable network you need to be assigned one from ICANN.

Tags for this Thread

Posting Permissions

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


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center