15

We know that in the OSI or TCP-IP model, the higher layer utilizes the services offered by the lower layer. For example, the data link layer uses services offered by the physical layer, network layer uses services offered by the data link layer and so on.

However, I find that some protocols uses services provided by the protocols in the layers above them. For example, both BGP and RIP perform routing which is usually considered as network layer functionality. BGP uses TCP while RIP uses UDP. So here protocols at the network layer which are using services from the protocols in the transport layer. That's why some people online argue that BGP & RIP should be associated at least at the transport layer, while some say that these are application layer protocols as they use services of transport layers, and in TCP-IP model above transport layer there is only application layer.

I understand both BGP and RIP perform mostly network layer functionality of routing. What's the truth/convention?

13

You have to remember that models like OSI are just that, models. They are theoretical. The real world doesn't fall neatly into these models. For the most part, routing is a layer-3 function, but, as you pointed out, BGP uses a layer-4 protocol to communicate with other BGP speakers in order to do what is normally considered a layer-3 function.

Many network protocols fall into a gray area, or are considered in one layer while using another layer. Take ARP for instance. It resolves layer-3 addresses to layer-2 addresses. Which layer should it be considered to be in?

Understanding the models is useful, but the models are not mandated by any organization, and you are free to create protocols and functions that do not follow any model.

  • Thanks. Thats exactly what I concluded after reading many articles online. You reaffirmed this fact. – Maha Nov 10 '15 at 7:32
8

BGP is on top of TCP, so it would be Internet layer 4, OSI layer 7. Usually external BGP is done only between 2 directly connected peers, enforced by setting TTL flag on IP header, which is located at layer 3.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.