News for hackers. Stuff that matters.
Re:How Do Routers Work, Really? by Cerium on Thursday September 10, 2020 @04:07PM (#24436030)
The IP stack has the concept of layers, which function as abstractions that hide the implementation of lower layers from the upper layers. Layer 2 (L2) is the physical link layer - it only cares about getting a packet between two devices. Layer 3 (L3) is where IP addresses live. As the article describes a router has functionality to send a packet towards its final destination as well as get it between ports.
Re:How Do Routers Work, Really? by josteink on Thursday September 10, 2020 @04:29PM (#24436259)
> The IP stack has the concept of layers, which function as abstractions that hide the implementation of lower layers from the upper layers

Correction: the network stack has layers, where IP is one of them, near the top.

Which is why most software targets IP. It’s a good abstraction and it’s portable.

Re:How Do Routers Work, Really? by cameronh90 on Thursday September 10, 2020 @05:51PM (#24436918)
GP may be referring to the "TCP/IP model" which does indeed define the layers used in common parlance. This model has 4 layers in contrast to the OSI model's 7 layers. The TCP/IP model is closer to how most real life network stack implementations are defined.

Arguably even this layering system is too rigid for reality but it's a decent model. See RFC 3439 section 3.

Re:How Do Routers Work, Really? by varjag on Thursday September 10, 2020 @04:35PM (#24436322)
L1 is (naturally) physical. L2 is data link.
Re:How Do Routers Work, Really? by Cyph0n on Thursday September 10, 2020 @05:11PM (#24436612)
L1 is the physical layer. L2 is the MAC layer.