This really sounds stupid because I’ve seen a router, but let’s get into the basics.

  • FunkyCheese@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    11
    ·
    8 hours ago

    Its a box that allows multiple computers (and phones etc) to be connected to each other in a network

    If a computer wants to go through the router and onto the internet, then the router keeps track of which connected computer, asked for what

    Pc1 wants go to bbc.co.uk When it sends that request it keeps track that the response is passed on to pc1 , who requested it

    And then pc2 and pc3 dont need to know about it

    Your internet connection has some random IP adress but then your router also creates “local” ip addresses for the locally connected computers, usually starting with 192, or 10.

    And if i recall ports are used so the pc knows which program on the computer, requested the data

    So the “address “ might be 192.168.0.10:443

    Where 443 is the port

    • nibbler@discuss.tchncs.de
      link
      fedilink
      English
      arrow-up
      2
      ·
      5 hours ago

      Its a box that allows multiple computers (and phones etc) to be connected to each other in a network

      That’s a hub. Maybe an accesspoint.

      If a computer wants to go through the router and onto the internet, then the router keeps track of which connected computer, asked for what Pc1 wants go to bbc.co.uk When it sends that request it keeps track that the response is passed on to pc1 , who requested it

      Routers in general are stateless. Your description is more like a stateful nat-device/firewall.

      And then pc2 and pc3 dont need to know about it

      Did I say hub? Switch I mean!

      Yet I fully agree with you!