Lecture 02: Basic Concepts of Networking (Part I)

Estimated read time: 1:20

    AI is evolving every day. Don't fall behind.

    Join 50,000+ readers learning how to use AI in just 5 minutes daily.

    Completely free, unsubscribe at any time.

    Summary

    In this lecture, the speaker discusses basic concepts of networking essential for a course on Ethical Hacking. The lecture covers various types of computer networks, such as Local Area Networks (LAN) and Wide Area Networks (WAN), and explains data transfer modes like circuit switching and packet switching, specifically touching upon virtual circuits. The importance of computer networks for communication and resource sharing, alongside definitions and classifications of network types, is covered. The lecture also delves into the methodologies of data transfer, explaining the differences, advantages, and disadvantages of circuit switching versus packet switching.

      Highlights

      • Discussing basic networking concepts related to Ethical Hacking 🛡️.
      • Introduction to types of computer networks: LAN and WAN 🌍.
      • Explaining circuit switching and packet switching modes of data transfer 🔄.
      • Understanding the difference between circuit and packet switching 📶.
      • Highlighting the concept of virtual circuits and their application in networks 🔗.

      Key Takeaways

      • Computer networks are essential for communication between diverse computing devices 📡.
      • There are two primary types of networks: Local Area Networks (LAN) and Wide Area Networks (WAN) 🌐.
      • Data can be transferred using circuit switching or packet switching methods, each with its advantages and drawbacks 🔄.
      • Packet switching is more efficient for bursty data traffic due to shared links and better link utilization 📦.
      • Virtual circuits offer a route similar to circuit switching but without dedicated links, enabling shared paths 📶.

      Overview

      Networking is pivotal in today's digital age, connecting various computing devices, be it computers, gadgets, or any other form of technology. The lecture begins by emphasizing the role of computer networks as communication systems that bring efficiency and connectivity to our lives. From connecting household security systems to cloud computing resources, networks serve as the backbone of technological communication.

        The world of networking is diverse, with networks primarily being categorized into Local Area Networks (LAN) for small geographical areas and Wide Area Networks (WAN) for broader regions. The lecture delves into the specifics, discussing how LANs are typically faster and cheaper, while WANs offer broader access but at a higher cost. Through anecdotes and examples, the speaker makes the subject approachable and relatable.

          Data transfer within these networks is a fascinating domain itself, with circuit switching and packet switching exemplifying two different methodologies. While circuit switching gives a set path for data transfer, packet switching offers flexibility with shared network links. The lecture examines the concept of virtual circuits, which seek to combine elements of both switching methods, bridging traditional methods with modern needs.

            Lecture 02: Basic Concepts of Networking (Part I) Transcription

            • 00:00 - 00:30 Hello welcome back, as we have discussed in the first lecture, in this course on Ethical Hacking, we shall be talking about a lot of issues and techniques and tools related to
            • 00:30 - 01:00 computer networks. So, it is imperative that some basic background of computer networks and some of the relevant aspects of it should be discussed as part of the course. So, in this lecture specifically we shall be starting with a discussion on some Basic Concepts of Networking. In this lecture, we shall be very specifically looking at different types of computer networks;
            • 01:00 - 01:30 the difference between the circuit switching and packet switching mode of data transfer and one method of packet switching data transfer which is called virtual circuits. So, we shall be talking about these few things. So, let us start with some of the basic concepts on computer networking ok. Now, as you already know that a computer network is essentially a communication system.
            • 01:30 - 02:00 Why do you use computer networks? We use computer networks, so that different computing devices, nowadays the computing devices appear in various shapes and forms, not necessarily they are computers. They can be anywhere, of any type that can be some gadgets, they can be some equipments anything.
            • 02:00 - 02:30 The idea is that they are connected to the internet or some kind of a network and they can communicate with other devices. You think of a security system in your home, that is also connected to some kind of a network, connected to some central servers, so that whenever some, you can say anomalous incident occurs, some central server will be notified accordingly ok. So, essentially a computer network we can define as a communication system, where some
            • 02:30 - 03:00 kind of computers or there any kind of hosts, as I told you, the nodes that are connecting are not necessarily computers. They are some devices, which have communication capability; they can be connected to the network right. Now, the question is why do we need networking? The reason is very clear; we want to have better connectivity. So, that the nodes remain connected with each other, we can have better communication.
            • 03:00 - 03:30 And obviously, sharing of resources nowadays, we talk about cloud computing, where not only storage space, but also computing resources are available online on the network, on the cloud. So, we can share some valuable resources over the network and it helps in bringing people together as we are seeing with our social networking applications that are coming up.
            • 03:30 - 04:00 Talking about the different types of computer networks, very broadly speaking, we can classify computer networks as Local Area Networks or LAN and Wide Area Networks or WAN. Of course, there are some intermediate nomenclatures that are also used like, people talk about metropolitan area network, which is somewhere in between, but we are not going into that
            • 04:00 - 04:30 detail. Now, essentially local area network as the name implies, they are used to connect hosts, which are separated by relatively small geographical area. Now, this relatively small is a, really a relative term, it can be in the same room, it can be in the same building or maybe within the same campus.
            • 04:30 - 05:00 Means, whether or not it is a local area network, it depends upon the technology that is being used. Nowadays, the most commonly used local area network standard is the Ethernet, various versions of Ethernet are there. It started with a very primitive form, the 10 mega Hertz, mbps, megabits per second Ethernet. Subsequently nowadays we have several giga Hertz speed, 100 giga Hertz and also beyond
            • 05:00 - 05:30 such speeds are coming up ok. Now, local area networks broadly speaking, this is the fastest kind of network and it is also relatively cheaper in the long run. Fastest when I talk about fast nowadays, by default we have something called gigabit per second speed available on our desktops, but there are technologies with which you can
            • 05:30 - 06:00 even enhance the speeds 10 gbps, 40 gbps, 100 gbps those technologies are also available in LAN. Talking about wide area network, they are used to connect devices or networks which are widely separated. Now by meaning widely separated, they can be across campuses, they can be across cities, countries or even continents.
            • 06:00 - 06:30 Traditionally such wide area networks were relatively slow. So, that is why we are saying that they are slower as compared to local area network. And they are also expensive in the long run, well initial deployment investment may not be that high, but you will have to pay a very hefty rental, annual rental or monthly rental to use this wide area network facility. Because, there is some kind of a service provider you are subscribing to the service, you will
            • 06:30 - 07:00 have to pay for the service, but in contrast a local area network is something which is your own, you are buying the equipments, you are buying the cables and the entire management the entire infrastructure is your own. So, you are not paying any body for using that infrastructure right. Now, talking about data communication over a network, let us look at rough picture like
            • 07:00 - 07:30 this, let us say these ABCD are the different nodes in a computer network and let us suppose this node A wants to send some message or some data to this node H and this BCD etc., these are so called intermediate nodes. So, from A to H there is no direct path, whatever data you want to send, they have to traverse
            • 07:30 - 08:00 or travel through various other intermediate nodes. Now in computer network terminology these intermediate nodes are typically routers, we shall be looking into routers again later. Broadly speaking communication may happen using two techniques; one is called circuit switching which was more traditional the old method and nowadays we have something called
            • 08:00 - 08:30 packet switching, let us look into this one by one. Talking about circuit switching, now whenever you want to communicate between two nodes, again I am talking about this A and H, what we are saying is that we are kind of establishing a circuit or a dedicated path for the communication. If you think of our old analogue telephone systems, when we used to dial a number, then
            • 08:30 - 09:00 a dedicated copper path used to get established from the caller to the person you are calling. Similar is the case here, say whenever A wants to communicate with H, some dedicated path, here it is marked in red, you can see via C, D and G possibly, this path will get established.
            • 09:00 - 09:30 And this path will be dedicated means, during the time of data communication, this dedicated path will be used for sending this information chunks, bits or whatever you are sending. And as you see, the path that we are selecting or we are deciding upon, they will follow a fix sequence of intermediate nodes or links through C, D and G ok.
            • 09:30 - 10:00 Now, on every physical link, this is a link, this is a link, this is a link and this is a link, there are 4 communication links, that exists in between right. So, over each of these communication links, something called a logical channel gets defined or established. Logical channel is something which guarantees you some dedicated bandwidth.
            • 10:00 - 10:30 Suppose you want a dedicated bandwidth of 64 kilobits per second. Let us take an example. So, all these communication channels that you are establishing, they will be guaranteeing a minimum bandwidth of 64 kbps ok, that is how this works? That is not that you are actually physically using that link means, on your own you are
            • 10:30 - 11:00 not allowing others to share, not like that, maybe this particular link is also shared by some other communication, but for this particular communication for from A to H, there is a 64 kilobyte channel or bandwidth that you are guaranteed to get, you have been provided with right that is the idea ok. So, in circuit switching, because we have a path to be established between the sender
            • 11:00 - 11:30 and receiver before you can actually start the communication, there are broadly three steps that need to be followed. The first is clearly a step of connection establishment, just like when you are dialing a telephone that step is the connection establishment phase, where the dedicated channels or links are getting established.
            • 11:30 - 12:00 This is required before the data transmission can start and once you have connection established, you can actually carry out the data transfer. Now, the advantage of circuit switching comes in the second step, when data transfer takes place, it is in the maximum possible speed without any disruption. So, you have dedicated bandwidth along all the links. So, that amount of dedicated bandwidth is always available to you ok.
            • 12:00 - 12:30 And of course, at the end when you are finished with the data communication, you terminate the connection. Terminate the connection means the resources that you had reserved, the communication links or the bandwidths, now, you can release them, now some other communication can use that bandwidth now ok. This is what do you mean by resources we allocating, we are deallocating ok, fine.
            • 12:30 - 13:00 Now, circuit switching has some obvious drawbacks. First drawback is that because you are having dedicated links from the source to the destination, during the time, the communication is active, this entire channel is dedicated for the communication. But you see, you, when you send a, transmit data it is not that data are being transmitted
            • 13:00 - 13:30 continuously. Usually computer data are bursty in nature, sometimes there is lot of data and there is a period where there is no data, sometimes again there is lot of data flowing, sometimes again there is no data. So, if you would reserve the channel for the entire period, your average channel utilization may not be that good, this is the drawback ok. Because, you are dedicating or reserving the channel capacity for the entire duration of
            • 13:30 - 14:00 communication, this will be quite inefficient for data traffic, which is typically generated by computer, which is bursty in nature. Data appears in burts, in between there is no data, there is a gap. But for voice communication when we talk over telephone, we normally do not remain silent,
            • 14:00 - 14:30 either I am talking or the person on the other side is talking, there is always some communication going on with respect to voice traffic. Nowadays most of the voice communication is also being carried out through computer network kind of an infrastructure. They are converted to digital, digitized and then voice is transmitted as data ok. And the other drawback is that, because of the connection establishment requirement, there will be an initial delay, only after that the communication can start ok.
            • 14:30 - 15:00 These are some of the drawbacks you have to remember. Next let us come to the other method so called packet switching. Now, packet switching as I said, this is more widely used nowadays, this is the modern form and this is used for long distance data communication, because it has some advantages.
            • 15:00 - 15:30 The main advantage is that you are not dedicating any network resources here. All communication links are shared, the links that your data will be traversing, they are all shared; they are not dedicated only for your communication ok. Because, the links are shared, there is no concept of guaranteed bandwidth typically.
            • 15:30 - 16:00 Typically, there is no such concept, but of course, you can have something called quality of service, you can have a guarantee on that, but typically there is no guarantee on the bandwidth. So, when there is lot of traffic on the network, you may feel that your data transmission or communication has become slow. So, this basic concept of packet switching as evolved over time, we shall be looking
            • 16:00 - 16:30 at this in some more details. Now, in packet switching, the essential idea is that when you are trying to send a message, suppose, here we have a message that you want to send. First step, the message is broken up into smaller pieces or chunks which are called packets; these are my packets 1, 2 and 3, there are 3 packets ok.
            • 16:30 - 17:00 And with each packet you add a header. This header will contain some relevant information like, where you want to send the packet, destination address and some information relating to that. So, these packets, you are dividing your message into each of this packets will be having some additional overheads in terms of headers ok. And each of these packets are transmitted separately.
            • 17:00 - 17:30 The message is not transmitted as a whole rather the packets that constitute the message, they will be transmitted one by one, this is the basic idea behind packet switching. So, it is not the message, you are thinking about is being transmitted, but rather the individual packets that are getting transmitted all right.
            • 17:30 - 18:00 There is another concept here that is used, this is a very important concept, which is called store and forward concept. The idea is as follows, let us say, I have a node here, I have node here, I have a node here. So, I am sending some data first to here and this fellow is forwarding the data to this fellow. Now, if we think of this central node.
            • 18:00 - 18:30 What happens is that, whatever packets that are being transmitted first through this first link, they will get stored in an internal buffer. There will be a buffer, a memory space where these packets will get stored right. And later on from this buffer, these packets will get forwarded to the next link. So, there is a store and forward kind of a concept.
            • 18:30 - 19:00 If due to some reason, the next link is busy there is lot of traffic, then you will be temporarily storing them in the buffer, you will not be sending now, when the link becomes free, then you forward them. In this way the link utilization can improve to great extent right. And each of these intermediate nodes you see, there may not be single link, there can be a multiple links to different nodes right, there can be multiple links.
            • 19:00 - 19:30 So, there is another thing, these nodes have to decide whenever a packet comes, it will have to take a decision which outgoing link I should forward this packet to. So, this will decide the route the packet should follow. And this is typically done on a per packet basis, not on a per message basis, each packet
            • 19:30 - 20:00 is independently routed through the network. And because of this thing, you will have to know or you will have to tell this intermediate nodes that whenever a packet comes, where to forward it. Now, this information is typically kept in a place which is called a routing table. Each of this intermediate nodes maintain something called a routing table, we shall be talking about this later again.
            • 20:00 - 20:30 And this routing table will decide where an incoming packet should be forwarded to, there can be multiple outgoing links. Now, this packet switching has some advantages clearly you can see, this links are shared. So, naturally link utilization is much better as compared to circuit switching and this is very suitable for bursty traffic, because you are not dedicating any link, if a link
            • 20:30 - 21:00 is free, other communications can share that link right. So, always, I mean always on the average you can see that all the link utilizations can be quite proper and uniform, there will be no such instance where some link is reserved by somebody and there is no data to be sent nothing like that ok. And because of the buffer you are using, buffering and data rate conversion can be performed easily.
            • 21:00 - 21:30 The ideas is as follows, suppose the incoming link is faster, outgoing link is slower. So, I can collect my packets at a faster rate, stored in a buffer and then slowly and slowly I will send it to the outgoing link, which has a slower data rate. So, I can do this kind of data rate conversion also using this store and forward concept. And of course, here you can give some kind of priority to some packets. So, you have several packets in the buffer, the packet which has the highest priority
            • 21:30 - 22:00 will be forwarded first like that ok, you can assign some kind of packet priority. Now, talking about packet transmission so, how are these packets transmitted? So, here again there are two alternate approaches which have been talked about, these are called virtual circuits and datagrams.
            • 22:00 - 22:30 Now, in the internet, mostly datagram packet communication or transmission method is used ok. Now, the abstract network model will again be just assuming something like this which we had shown earlier, where there will be a sender, there will be a receiver and there will be several intermediate nodes and some links that are connecting the intermediate nodes. So, data or the packets will be following some of these links from the source A to the
            • 22:30 - 23:00 destination H ok, this is our model that will be assuming. Now, the first method which is the virtual circuit approach, I am just mentioning briefly, because this is not that widely used in the internet, very rarely we will find this. Now, here the concept is somewhat similar to circuit switching. Now, in circuit switching, you recall I said before a communication some path is decided
            • 23:00 - 23:30 upon and the links are dedicated or reserved, some guaranteed bandwidth is provided for the communication. So, virtual circuit is similar in this sense, that here you are saying that you are establishing a route. Like for example, if I have a network like this, there are several nodes which are connected
            • 23:30 - 24:00 in certain way. Suppose I have links like this right. Suppose I want to transmit data from this source to this destination. So, I may choose a route like, my route can be like this, it will follow this, then this, then this, then this, this may be my route ok. Now, once I have fixed my routes, all the packets will be following the same route,
            • 24:00 - 24:30 this is the essential idea behind virtual circuit. So, here again there will be something like a connection establishment phase where this route will be decided upon ok. And our packets will be following the same path, but the point to note is that the links here are not dedicated like circuit switching. Since packets are passing, the same link may be part of another virtual circuit, some other
            • 24:30 - 25:00 communication is going on, that may also be going through that same link, in that way some of the links or paths may be shared, they are not dedicated. Now, this virtual circuit is somewhat similar to the telephone system that we use today, something like that ok. Now, talking about some detail how it works?
            • 25:00 - 25:30 As I said in the first step for virtual circuit, the route has to be established. Now, once the route is established, suppose, for a node A, it wants to send some data to a node H. Let us say the path is established as follows, A to let us say, node B, B to a node let us say, E, E to H let us say.
            • 25:30 - 26:00 So, once this path is established, each virtual circuit will be given a virtual circuit number ok. This virtual circuit number will be known to all this intermediate nodes when the connection is being established. So, once this virtual circuit number or the virtual circuit is established, when the packets
            • 26:00 - 26:30 are being transmitted, so, you recall, I said that the packet will be containing the data and some header. Now, in the header only the virtual circuit number will be kept, because this node B will know, because a circuit has already being established, that if I am talking about virtual circuit number two, then this is the path to be followed. So, it will automatically forward that packet along that virtual circuit number which you
            • 26:30 - 27:00 have specified. So, here routing of the packets are carried out based on the virtual circuit number, that is present as part of the header. And during the connection establishment phase when the path or the route is being finalized, this information will be established in all the intermediate nodes.
            • 27:00 - 27:30 They will be having some kind of a routing table and that routing table will tell you that, if it is virtual circuit number one, then you have to go to this link. If it is virtual circuit number two, you have to go to this link and so on, fine. Now, regarding the packet forwarding, it will be normal store and forward scheme. And here as I said that the packet in the header, it will carry only the virtual circuit
            • 27:30 - 28:00 number and all intermediate nodes will be maintaining some kind of a routing table ok. And the important thing is no dynamic routing decision is taken here. Once you establish the connection at the beginning, all the packets for a particular virtual circuit will be following that same path. Even, if some of the links is very much, it has become slow, but still that same path
            • 28:00 - 28:30 will be followed ok. This is one drawback of virtual circuit, because it is not dynamic or adaptive, it cannot adapt itself automatically, you can say in, I means in light of some changing network conditions, it is static in some sense. So, we shall be looking at the datagram approach where some of these drawbacks are not present
            • 28:30 - 29:00 ok. So we have looked at the virtual circuit approach here and with this we come to the end of this lecture. We shall be continuing with our discussion in the next lecture where we shall be first talking about the datagram approach, the other approach for routing of the packets and some other networking issues as well. Thank you.