Internet Protocol. Chapter 5 Protocol Layering. Juho Kim Graduate School of Information & Technology Sogang University

Size: px
Start display at page:

Download "Internet Protocol. Chapter 5 Protocol Layering. Juho Kim Graduate School of Information & Technology Sogang University"

Transcription

1 Internet Protocol Chapter 5 Protocol Layering Juho Kim Graduate School of Information & Technology Sogang University Department of of Computer Science and and Engineering, Sogang University Page 1 CAD & VLSI Lab. Page Youse 1 Kim / 35

2 Protocol Layering The structure of the software found in hosts and routers that carries out network communication. Layering makes the internet software easier to build and trace The need for multiple protocols The conceptual layers of protocol software Functionality of the layers: ISO 7-layer reference model TCP/IP Internet layering model Difference between X.25 and internet layering Protocol layering principle Layering in the presence of network substructure Two important boundaries in the TCP/IP model Disadvantage of layering Basic idea behind multiplexing and demultiplexing Department of of Computer Science and and Engineering, Sogang University Page 2 CAD & VLSI Lab. Page Youse 2 Kim / 35

3 The Need For Multiple Protocols Protocol Layering Problems when machines communicate over a data network Hardware failure: A host or router => A protocol software needs to detect such failures and recover from them if possible. Network congestion: The protocol software needs to arrange ways that a congested machine can suppress further traffic. Packet delay or loss: The protocol software needs to learn or adapt to long delay Data corruption: The protocol software needs to detect and recover from errors Data duplication or sequence errors: The protocol software need to reorder or remove any duplicates. No single protocol can handle all of the problems Among layers of protocols, they must agree on formats. Department of of Computer Science and and Engineering, Sogang University Page 3 CAD & VLSI Lab. Page Youse 3 Kim / 35

4 Protocol Layering Conceptual Layers of Protocol Software The path of a message traversing the Internet from the sender through two intermediate machines to the receiver. Intermediate machines only send the datagram to the IP software layer. Department of of Computer Science and and Engineering, Sogang University Page 4 CAD & VLSI Lab. Page Youse 4 Kim / 35

5 OSI 7-Layer Reference Model Developed by the International Organization for Standardization protocol standards OSI Model (open systems interconnection) Application; provides access to OSI environment for users and also provides distributed information Presentation; provides application processes from data representation (syntax) Session; provides the control structure for communication between applications Transport; provides reliable, transparent transfer of data between end points (error recovery, flow control) Network; provides data transmission and switching techniques to connect systems Data link; provides for the reliable transfer of information across physical link Physical; transmission of unstructured bit stream over physical medium Department of of Computer Science and and Engineering, Sogang University Page 5 CAD & VLSI Lab. Page Youse 5 Kim / 35

6 TCP/IP Internet Layering Model Application layer ; support user application Transport layer ; transmission control protocol (TCP) provides reliability of exchanging data, flow control, and packets Internet layer ; internet protocol (IP) provides routing function across multiple networks. Encapsulating packet in an IP datagram (fills header and uses routing alg.) Network access layer ; circuit switching, packet switching (e.g., X.25), local area network (Ethernet) Physical layer ; physical interface between devices and a transmission medium or network Department of of Computer Science and and Engineering, Sogang University Page 6 CAD & VLSI Lab. Page Youse 6 Kim / 35

7 Layering in a TCP/IP Internet Environment Layering principle when a router is used. The frame delivered to router R is exactly the frame sent from host A, but differs from the frame sent between R and B Department of of Computer Science and and Engineering, Sogang University Page 7 CAD & VLSI Lab. Page Youse 7 Kim / 35

8 Layering In The Presence Of Network Substructure A set of point-to-point connections among routers Independent network: Serial Line IP (SLIP) or Point to Point Protocol (PPP) Causing too many networks (large routing table) Single IP network small routing table for intranet (a) Conceptual position of an internet protocol for point-to-point connections when IP treats them as a single IP network (b) Detailed diagram of corresponding software modules. Each arrow corresponds to one physical device. Department of of Computer Science and and Engineering, Sogang University Page 8 CAD & VLSI Lab. Page Youse 8 Kim / 35

9 Two Important Boundaries In The TCP/IP Model Protocol address boundary Operating system boundary Department of of Computer Science and and Engineering, Sogang University Page 9 CAD & VLSI Lab. Page Youse 9 Kim / 35

10 Disadvantages of Layering Strict layering prevents from the higher-level knowing the lowerlevel For example, the transport layer accepts a stream of bytes from an application program, divide the stream into packets, and send each packet across the internet. To optimize the transfer, the transport layer finds the largest packet size for that network. However, the transport layer does not know the routing and traffic. Relaxing the strict layering : passing information such as route selection, MTU (maximum transfer unit) to higher layer protocols. Department of of Computer Science and Engineering, Sogang University Page 10 CAD & VLSI Lab. Page Youse 10 / Kim 35

11 Demultiplexing at Network Interface Layer Demultiplexing of incoming frames based on the type field found in the frame header Department of of Computer Science and Engineering, Sogang University Page 11 CAD & VLSI Lab. Page Youse 11 / Kim 35

12 Demultiplexing at the Internet Layer Demultiplexing at the Internet layer. IP software chooses an appropriate procedure to handle a datagram based on the protocol type field in the datagram header Department of of Computer Science and Engineering, Sogang University Page 12 CAD & VLSI Lab. Page Youse 12 / Kim 35

13 User Datagram Protocol User Datagram Protocol (UDP) UDP message format UDP Encapulation and Protocol Layering UDP Multiplexing, Demultiplexing, and Ports Reserved and Available UDP Port Numbers Sockets Department of of Computer Science and Engineering, Sogang University Page 13 CAD & VLSI Lab. Page Youse 13 / Kim 35

14 User Datagram Protocol (UDP) Distinguishing multiple destinations within a given host: allowing multiple application programs executing on a given computer to send and receive datagrams independently. use different port number to identify different application protocol port : abstract destination port buffering port for late processing Sender needs to know both IP address and the protocol port number User Datagram Protocol : The primary mechanism that application programs use to send datagrams to other application programs. Department of of Computer Science and Engineering, Sogang University Page 14 CAD & VLSI Lab. Page Youse 14 / Kim 35

15 UDP Message Format UDP header UDP SOURCE PORT : optional UDP DESTINATION PORT : 16-bit protocol port number LENGTH : a count of octets in the UDP datagram (header + data) CHECKSUM : optional Department of of Computer Science and Engineering, Sogang University Page 15 CAD & VLSI Lab. Page Youse 15 / Kim 35

16 UDP Encapsulation and Protocol Layering The IP layer is responsible only for transferring data between a pair of hosts on an internet, while the UDP layer is responsible only for differentiating among multiple sources or destinations within one host. Department of of Computer Science and Engineering, Sogang University Page 16 CAD & VLSI Lab. Page Youse 16 / Kim 35

17 UDP Demultiplexing and Ports Example of demultiplexing one layer above IP. UDP uses the UDP destination port number to select an appropriate destination port for incoming datagrams. When port is full, UDP discards the incoming datagram and sends back port unreachable ICMP message back to the sender. Department of of Computer Science and Engineering, Sogang University Page 17 CAD & VLSI Lab. Page Youse 17 / Kim 35

18 Ports To identify different applications, tag each datagram with a port number. The UDP(or TCP) decides which application should receive the datagram by comparing the port number with ports currently in use. Each application program negotiates to obtain a protocol field and associated port number before it sends a UDP(TCP) datagram. Usually the port number points to an internal queue created by the Operating System Application as client should know in advance the port number for the particular application in the server. Application as a server can obtain the port number of the client on receiving the first request. Department of of Computer Science and Engineering, Sogang University Page 18 CAD & VLSI Lab. Page Youse 18 / Kim 35

19 Reserved Port Numbers Department of of Computer Science and Engineering, Sogang University Page 19 CAD & VLSI Lab. Page Youse 19 / Kim 35

20 Socket Interface Interface between application programs and TCP/IP protocols. Interface depends on operating systems. Socket is not considered as protocols (just an application, not standard). Used for network I/O: similar to file descriptor for file I/O in UNIX File I/O in UNIX: Open-Read-Write-Close paradigm Open returns an integer file descriptor --> user process uses the number for accessing the file Read transfers data into user process. Write transfers data from the user process to the file or device. Close is called by the user process to terminate the process. With file access application programs request the operating system to create a socket The system returns a small integer that the application program uses to reference the newly created socket. Department of of Computer Science and Engineering, Sogang University Page 20 CAD & VLSI Lab. Page Youse 20 / Kim 35

21 Networking with java.net Internet Address and URL InetAddress class java.lang.object + -- java.net.inetaddress public final class InetAddress extends Object implements Serializable This class represents an Internet Protocol (IP) address. Applications should use the methods getlocalhost, getbyname, or getallbyname to create a new InetAddress instance. Department of of Computer Science and Engineering, Sogang University Page 21 CAD & VLSI Lab. Page Youse 21 / Kim 35

22 Department of of Computer Science and Engineering, Sogang University Page 22 CAD & VLSI Lab. Page Youse 22 / Kim 35

23 Example) AddressTest.java import java.net.*; class AddressTest { public static void main(string args[]) } throws UnknownHostException { InetAddress Address = InetAddress.getLocalHost(); } System.out.println("Local Host Name : " + Address.getHostName()); System.out.println("Local Host IP Address : " + Address.getHostAddress()); Address = InetAddress.getByName("sogang.ac.kr"); System.out.println("sogang.ac.kr's computer name and IP Address : " + Address); InetAddress sw[] = InetAddress.getAllByName(" for (int i = 0; i < sw.length; i++) System.out.println(sw[i]); Department of of Computer Science and Engineering, Sogang University Page 23 CAD & VLSI Lab. Page Youse 23 / Kim 35

24 URL class Class URL represents a Uniform Resource Locator, a pointer to a "resource" on the World Wide Web. A resource can be something as simple as a file or a directory, or it can be a reference to a more complicated object, such as a query to a database or to a search engine. More information on the types of URLs and their formats can be found at: In general, a URL can be broken into several parts. The previous example of a URL indicates that the protocol to use is http (HyperText Transport Protocol) and that the information resides on a host machine named The information on that host machine is named demoweb/url-primer.html. The exact meaning of this name on the host machine is both protocol dependent and host dependent. The information normally resides in a file, but it could be generated on the fly. This component of the URL is called the file component, even though the information is not necessarily in a file. Department of of Computer Science and Engineering, Sogang University Page 24 CAD & VLSI Lab. Page Youse 24 / Kim 35

25 A URL can optionally specify a "port", which is the port number to which the TCP connection is made on the remote host machine. If the port is not specified, the default port for the protocol is used instead. For example, the default port for http is 80. An alternative port could be specified as: A URL may have appended to it an "anchor", also known as a "ref" or a "reference". The anchor is indicated by the sharp sign character "#" followed by more characters. For example, This anchor is not technically part of the URL. Rather, it indicates that after the specified resource is retrieved, the application is specifically interested in that part of the document that has the tag chapter1 attached to it. The meaning of a tag is resource specific. An application can also specify a "relative URL", which contains only enough information to reach the resource relative to another URL. Relative URLs are frequently used within HTML pages. For example, if the contents of the URL: contained within it the relative URL: FAQ.html it would be a shorthand for: The relative URL need not specify all the components of a URL. If the protocol, host name, or port number is missing, the value is inherited from the fully specified URL. The file component must be specified. The optional anchor is not inherited. Department of of Computer Science and Engineering, Sogang University Page 25 CAD & VLSI Lab. Page Youse 25 / Kim 35

26 Department of of Computer Science and Engineering, Sogang University Page 26 CAD & VLSI Lab. Page Youse 26 / Kim 35

27 Department of of Computer Science and Engineering, Sogang University Page 27 CAD & VLSI Lab. Page Youse 27 / Kim 35

28 Example) urltest.java import java.net.*; class urltest { public static void main(string args[]) throws MalformedURLException { URL location = new URL(" System.out.println("protocol : " + location.getprotocol()); System.out.println("port : " + location.getport()); System.out.println("host : " + location.gethost()); System.out.println("file : " + location.getfile()); System.out.println("URL " + location.toexternalform()); } } Department of of Computer Science and Engineering, Sogang University Page 28 CAD & VLSI Lab. Page Youse 28 / Kim 35

29 URLConnection class The abstract class URLConnection is the superclass of all classes that represent a communications link between the application and a URL. Instances of this class can be used both to read from and to write to the resource referenced by the URL. The following methods are used to access the header fields and the contents after the connection is made to the remote object: getcontent getheaderfield getinputstream getoutputstream Certain header fields are accessed frequently. The methods: getcontentencoding getcontentlength getcontenttype getexpiration getdate getlastmodifed provide convenient access to these fields. The getcontenttype method is used by the getcontent method to determine the type of the remote object; subclasses may find it convenient to override the getcontenttype method. Department of of Computer Science and Engineering, Sogang University Page 29 CAD & VLSI Lab. Page Youse 29 / Kim 35

30 Example urlconnectiontest.java import java.util.date; class urlconnectiontest { public static void main(string args[]) throws Exception { int c; URL addr = new URL(" URLConnection addrconnection = addr.openconnection(); System.out.println("Document Type : " + addrconnection.getcontenttype()); System.out.println("Last Modified : " + new Date(addrConnection.getLastModified())); int len = addrconnection.getcontentlength(); System.out.println("Document Length : " + len + "byte"); if (len > 0) { System.out.println(" ===== Contents ======= "); InputStream input = addrconnection.getinputstream(); int i = len; while (((c = input.read())!= -1) && (--i > 0)) { System.out.print((char) c); } input.close(); } else { System.out.println("No Contents"); } }} Department of of Computer Science and Engineering, Sogang University Page 30 CAD & VLSI Lab. Page Youse 30 / Kim 35

31 Department of of Computer Science and Engineering, Sogang University Page 31 CAD & VLSI Lab. Page Youse 31 / Kim 35

32 Department of of Computer Science and Engineering, Sogang University Page 32 CAD & VLSI Lab. Page Youse 32 / Kim 35

33 Socket ServerSocket class ServerSocket(int port) Creates a server socket on a specified port. ServerSocket(int port, int backlog) Creates a server socket and binds it to the specified local port number. ServerSocket(int port, int backlog, InetAddress bindaddr) Create a server with the specified port, listen backlog, and local IP address to bind to. Department of of Computer Science and Engineering, Sogang University Page 33 CAD & VLSI Lab. Page Youse 33 / Kim 35

34 Example) ServerSide.java import java.io.*; import java.net.*; class ServerSide { public static void main(string args[]) { try { int port = Integer.parseInt(args[0]); ServerSocket ss = new ServerSocket(port); while(true) { Socket s = ss.accept(); OutputStream os = s.getoutputstream(); DataOutputStream dos = new DataOutputStream(os); for (int i = 1; i <= 10; i++) dos.writeint(i); s.close(); }} catch(exception e) { System.out.println("Exception: " + e); }}} Department of of Computer Science and Engineering, Sogang University Page 34 CAD & VLSI Lab. Page Youse 34 / Kim 35

35 Example) ClientSide.java import java.io.*; import java.net.*; class ClientSide { public static void main(string args[]) { try { String server = args[0]; int port = Integer.parseInt(args[1]); Socket c = new Socket(server, port); InputStream is = c.getinputstream(); DataInputStream dis = new DataInputStream(is); for (int i = 1; i <= 10; i++) { int j = dis.readint(); System.out.println("data from server " + j); } c.close();} catch(exception e) { System.out.println("Exception: " + e); }}} Department of of Computer Science and Engineering, Sogang University Page 35 CAD & VLSI Lab. Page Youse 35 / Kim 35

Networking and Security

Networking and Security Chapter 03 Networking and Security Mr. Nilesh Vishwasrao Patil Government Polytechnic Ahmednagar Socket Network socket is an endpoint of an interprocess communication flow across a computer network. Sockets

More information

JAVA - NETWORKING (SOCKET PROGRAMMING)

JAVA - NETWORKING (SOCKET PROGRAMMING) JAVA - NETWORKING (SOCKET PROGRAMMING) http://www.tutorialspoint.com/java/java_networking.htm Copyright tutorialspoint.com The term network programming refers to writing programs that execute across multiple

More information

Unit 1 Java Networking

Unit 1 Java Networking Q1. What is Server Socket? Discuss the difference between the Socket and ServerSocket class. The ServerSocket class (java.net) can be used to create a server socket. This object is used to establish communication

More information

CSCD 330 Network Programming Spring 2018

CSCD 330 Network Programming Spring 2018 CSCD 330 Network Programming Spring 2018 Lecture 6 Application Layer Socket Programming in Java Reading for Java Client/Server see Relevant Links Some Material in these slides from J.F Kurose and K.W.

More information

Outlines. Networking in Java. Internet hardware structure. Networking Diagram. IP Address. Networking in Java. Networking basics

Outlines. Networking in Java. Internet hardware structure. Networking Diagram. IP Address. Networking in Java. Networking basics G52APR Application programming Networking in Java Michael Li http://www.cs.nott.ac.uk/~jwl/g52apr Outlines Networking basics Network architecture IP address and port Server-client model TCP and UDP protocol

More information

JAVA Network API. 2 - Connection-Oriented vs. Connectionless Communication

JAVA Network API. 2 - Connection-Oriented vs. Connectionless Communication JAVA Network API To be discussed 1 - java.net... 1 2 - Connection-Oriented vs. Connectionless Communication... 1 3 - Connectionless:... 1 4 - Networking Protocols... 2 5 - Sockets... 2 6 - Multicast Addressing...

More information

TCP/IP THE TCP/IP ARCHITECTURE

TCP/IP THE TCP/IP ARCHITECTURE TCP/IP-1 The Internet Protocol (IP) enables communications across a vast and heterogeneous collection of networks that are based on different technologies. Any host computer that is connected to the Internet

More information

AJP: Chapter 2 Networking: 18 marks

AJP: Chapter 2 Networking: 18 marks AJP: Chapter 2 Networking: 18 marks Syllabus 2.1 Basics Socket overview, client/server, reserved sockets, proxy servers, internet addressing. 2.2 Java & the Net The networking classes & interfaces 2.3

More information

Chapter 2 Applications and

Chapter 2 Applications and Chapter 2 Applications and Layered Architectures Sockets Socket API API (Application Programming Interface) Provides a standard set of functions that can be called by applications Berkeley UNIX Sockets

More information

Socket Programming(TCP & UDP) Sanjay Chakraborty

Socket Programming(TCP & UDP) Sanjay Chakraborty Socket Programming(TCP & UDP) Sanjay Chakraborty Computer network programming involves writing computer programs that enable processes to communicate with each other across a computer network. The endpoint

More information

Introduction to Socket Programming

Introduction to Socket Programming Introduction to Socket Programming (Advanced Computer Networks) By Priyank Shah NET ID : pss160530 A Simple Question What are Sockets? Sockets are communication points on the same or different computers

More information

Connecting to a Server Implementing Servers Making URL Connections Advanced Socket Programming

Connecting to a Server Implementing Servers Making URL Connections Advanced Socket Programming Course Name: Advanced Java Lecture 11 Topics to be covered Connecting to a Server Implementing Servers Making URL Connections Advanced Socket Programming Introduction Internet and WWW have emerged as global

More information

OBJECT ORIENTED PROGRAMMING

OBJECT ORIENTED PROGRAMMING 1 OBJECT ORIENTED PROGRAMMING Lecture 14 Networking Basics Outline 2 Networking Basics Socket IP Address DNS Client/Server Networking Class & Interface URL Demonstrating URL Networking 3 Java is practically

More information

Basic Java Network Programming. CS211 July 30 th, 2001

Basic Java Network Programming. CS211 July 30 th, 2001 Basic Java Network Programming CS211 July 30 th, 2001 The Network and OSI Model IP Header TCP Header TCP/IP: A Paradox TCP Connection Oriented and Connectionless Protocols Reliable: no loss, or duplication,

More information

C18: Network Fundamentals and Reliable Sockets

C18: Network Fundamentals and Reliable Sockets CISC 3120 C18: Network Fundamentals and Reliable Sockets Hui Chen Department of Computer & Information Science CUNY Brooklyn College 4/16/2018 CUNY Brooklyn College 1 Outline Networking fundamentals Network

More information

Transport Layer. Gursharan Singh Tatla. Upendra Sharma. 1

Transport Layer. Gursharan Singh Tatla.   Upendra Sharma. 1 Transport Layer Gursharan Singh Tatla mailme@gursharansingh.in Upendra Sharma 1 Introduction The transport layer is the fourth layer from the bottom in the OSI reference model. It is responsible for message

More information

Advanced Java Programming. Networking

Advanced Java Programming. Networking Advanced Java Programming Networking Eran Werner and Ohad Barzilay Tel-Aviv University Advanced Java Programming, Spring 2006 1 Overview of networking Advanced Java Programming, Spring 2006 2 TCP/IP protocol

More information

Lecture 3. Java Socket Programming. TCP, UDP and URL

Lecture 3. Java Socket Programming. TCP, UDP and URL Lecture 3 TCP, UDP and URL 1 Java Sockets Programming The package java.net provides support for sockets programming (and more). Typically you import everything defined in this package with: import java.net.*;

More information

CS 4390 Computer Networks. Transport Services and Protocols

CS 4390 Computer Networks. Transport Services and Protocols CS 4390 Computer Networks UT D data Session 07 Transport Layer Overview and UDP Adapted from Computer Networking a Top-Down Approach 1996-2012 by J.F Kurose and K.W. Ross, All Rights Reserved Transport

More information

Networking Basics. network communication.

Networking Basics. network communication. JAVA NETWORKING API Networking Basics When you write Java programs that communicate over the network, you are programming at the application layer. Typically, you don't need to concern yourself with the

More information

NT1210 Introduction to Networking. Unit 10

NT1210 Introduction to Networking. Unit 10 NT1210 Introduction to Networking Unit 10 Chapter 10, TCP/IP Transport Objectives Identify the major needs and stakeholders for computer networks and network applications. Compare and contrast the OSI

More information

ET4254 Communications and Networking 1

ET4254 Communications and Networking 1 Topic 9 Internet Protocols Aims:- basic protocol functions internetworking principles connectionless internetworking IP IPv6 IPSec 1 Protocol Functions have a small set of functions that form basis of

More information

Concept Questions Demonstrate your knowledge of these concepts by answering the following questions in the space that is provided.

Concept Questions Demonstrate your knowledge of these concepts by answering the following questions in the space that is provided. 223 Chapter 19 Inter mediate TCP The Transmission Control Protocol/Internet Protocol (TCP/IP) suite of protocols was developed as part of the research that the Defense Advanced Research Projects Agency

More information

COMP 213. Advanced Object-oriented Programming. Lecture 20. Network Programming

COMP 213. Advanced Object-oriented Programming. Lecture 20. Network Programming COMP 213 Advanced Object-oriented Programming Lecture 20 Network Programming Network Programming A network consists of several computers connected so that data can be sent from one to another. Network

More information

Object-Oriented Programming in Java

Object-Oriented Programming in Java CSCI/CMPE 3326 Object-Oriented Programming in Java 1. Socket Programming Dongchul Kim Department of Computer Science University of Texas Rio Grande Valley Two types of TCP Socket java.net.serversocket

More information

Network Layer (1) Networked Systems 3 Lecture 8

Network Layer (1) Networked Systems 3 Lecture 8 Network Layer (1) Networked Systems 3 Lecture 8 Role of the Network Layer Application Application The network layer is the first end-to-end layer in the OSI reference model Presentation Session Transport

More information

ECE4110 Internetwork Programming. Introduction and Overview

ECE4110 Internetwork Programming. Introduction and Overview ECE4110 Internetwork Programming Introduction and Overview 1 EXAMPLE GENERAL NETWORK ALGORITHM Listen to wire Are signals detected Detect a preamble Yes Read Destination Address No data carrying or noise?

More information

Transport Layer. The transport layer is responsible for the delivery of a message from one process to another. RSManiaol

Transport Layer. The transport layer is responsible for the delivery of a message from one process to another. RSManiaol Transport Layer Transport Layer The transport layer is responsible for the delivery of a message from one process to another Types of Data Deliveries Client/Server Paradigm An application program on the

More information

The TCP Protocol Stack

The TCP Protocol Stack The TCP Protocol Stack Michael Brockway February 16, 2018 Introduction - Layered archtecture Networking software is desgined in a layered fashion The bottom layer is the services offered by the underlying

More information

ICS 351: Networking Protocols

ICS 351: Networking Protocols ICS 351: Networking Protocols IP packet forwarding application layer: DNS, HTTP transport layer: TCP and UDP network layer: IP, ICMP, ARP data-link layer: Ethernet, WiFi 1 Networking concepts each protocol

More information

SUBJECT: DATA COMMUNICATION AND NETWORK SEMESTER: V SEMESTER COURSE: BCA SUBJECT TEACHER: Dr.K.Chitra Assistant Professor, Department of Computer

SUBJECT: DATA COMMUNICATION AND NETWORK SEMESTER: V SEMESTER COURSE: BCA SUBJECT TEACHER: Dr.K.Chitra Assistant Professor, Department of Computer SUBJECT: DATA COMMUNICATION AND NETWORK SEMESTER: V SEMESTER COURSE: BCA SUBJECT TEACHER: Dr.K.Chitra Assistant Professor, Department of Computer Science Chapter - 2 Switching and Network Architecture

More information

Ex. No. : 1 Retrieving Data using URL Procedure URLs A URL identifies the location of a resource on the Internet. It specifies the protocol used to access a server (e.g., FTP, HTTP), the name of the server,

More information

Java Networking (sockets)

Java Networking (sockets) Java Networking (sockets) Rui Moreira Links: http://java.sun.com/docs/books/tutorial/networking/toc.html#sockets http://www.javaworld.com/javaworld/jw-12-1996/jw-12-sockets_p.html Networking Computers

More information

Chapter 6. What happens at the Transport Layer? Services provided Transport protocols UDP TCP Flow control Congestion control

Chapter 6. What happens at the Transport Layer? Services provided Transport protocols UDP TCP Flow control Congestion control Chapter 6 What happens at the Transport Layer? Services provided Transport protocols UDP TCP Flow control Congestion control OSI Model Hybrid Model Software outside the operating system Software inside

More information

TCP connections. Fundamentals of Internet Connections Objectives. Connect to an Echo port. java.net.socket

TCP connections. Fundamentals of Internet Connections Objectives. Connect to an Echo port. java.net.socket Objectives TCP connections To understand programming of clients that connect to servers via TCP To understand the basics of programming of servers that accept TCP connections To practice programming of

More information

Network Architecture Models

Network Architecture Models School of Business Eastern Illinois University Network Architecture Models (September 8, 2009) Abdou Illia, Fall 2009 Learning Objectives 2 Discuss the OSI reference Model Discuss the Internet Model Compare

More information

UDP and TCP. Introduction. So far we have studied some data link layer protocols such as PPP which are responsible for getting data

UDP and TCP. Introduction. So far we have studied some data link layer protocols such as PPP which are responsible for getting data ELEX 4550 : Wide Area Networks 2015 Winter Session UDP and TCP is lecture describes the two most common transport-layer protocols used by IP networks: the User Datagram Protocol (UDP) and the Transmission

More information

Introduction. IP Datagrams. Internet Service Paradigm. Routers and Routing Tables. Datagram Forwarding. Example Internet and Conceptual Routing Table

Introduction. IP Datagrams. Internet Service Paradigm. Routers and Routing Tables. Datagram Forwarding. Example Internet and Conceptual Routing Table Introduction Datagram Forwarding Gail Hopkins Service paradigm IP datagrams Routing Encapsulation Fragmentation Reassembly Internet Service Paradigm IP Datagrams supports both connectionless and connection-oriented

More information

CS 355. Computer Networking. Wei Lu, Ph.D., P.Eng.

CS 355. Computer Networking. Wei Lu, Ph.D., P.Eng. CS 355 Computer Networking Wei Lu, Ph.D., P.Eng. Chapter 2: Application Layer Overview: Principles of network applications? Introduction to Wireshark Web and HTTP FTP Electronic Mail: SMTP, POP3, IMAP

More information

Info 408 Distributed Applications programming 2 nd semester of 2017/2018 Credits: 5 Lecturer: Dr. Antoun Yaacoub

Info 408 Distributed Applications programming 2 nd semester of 2017/2018 Credits: 5 Lecturer: Dr. Antoun Yaacoub Lebanese University Faculty of Science I Master 1 degree Computer Science Info 408 Distributed Applications programming 2 nd semester of 2017/2018 Credits: 5 Lecturer: Dr. Antoun Yaacoub Starting Network

More information

Operating Systems CS 571

Operating Systems CS 571 Computer Networks: Overview Operating Systems CS 571 Network types Range Bandwidth (Mbps) Latency (ms) LAN 1-2 kms 10-1000 1-10 WAN worldwide 0.010-600 100-500 MAN 2-50 kms 1-150 10 Wireless LAN 0.15-1.5

More information

Previous lecture: threads G51PRG: Introduction to Programming Second semester Lecture 12 URL

Previous lecture: threads G51PRG: Introduction to Programming Second semester Lecture 12 URL Previous lecture: threads G51PRG: Introduction to Programming Second semester Lecture 12 What is a thread Why use multiple threads Issues and problems involved Java threads Natasha Alechina School of Computer

More information

APPENDIX F THE TCP/IP PROTOCOL ARCHITECTURE

APPENDIX F THE TCP/IP PROTOCOL ARCHITECTURE APPENDIX F THE TCP/IP PROTOCOL ARCHITECTURE William Stallings F.1 TCP/IP LAYERS... 2 F.2 TCP AND UDP... 4 F.3 OPERATION OF TCP/IP... 6 F.4 TCP/IP APPLICATIONS... 10 Copyright 2014 Supplement to Computer

More information

05 Transmission Control Protocol (TCP)

05 Transmission Control Protocol (TCP) SE 4C03 Winter 2003 05 Transmission Control Protocol (TCP) Instructor: W. M. Farmer Revised: 06 February 2003 1 Interprocess Communication Problem: How can a process on one host access a service provided

More information

CS September 2017

CS September 2017 Machine vs. transport endpoints IP is a network layer protocol: packets address only the machine IP header identifies source IP address, destination IP address Distributed Systems 01r. Sockets Programming

More information

Chapter 2 Network Models 2.1

Chapter 2 Network Models 2.1 Chapter 2 Network Models 2.1 Copyright The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 2-1 LAYERED TASKS We use the concept of layers in our daily life. As an example,

More information

TSIN02 - Internetworking

TSIN02 - Internetworking Lecture 4: Transport Layer Literature: Forouzan: ch 11-12 2004 Image Coding Group, Linköpings Universitet Lecture 4: Outline Transport layer responsibilities UDP TCP 2 Transport layer in OSI model Figure

More information

Computer Networks with Internet Technology William Stallings. Chapter 2 Protocols and the TCP/IP Protocol Suite

Computer Networks with Internet Technology William Stallings. Chapter 2 Protocols and the TCP/IP Protocol Suite Computer Networks with Internet Technology William Stallings Chapter 2 Protocols and the TCP/IP Protocol Suite Need For Protocol Architecture E.g. File transfer Source must activate comms. Path or inform

More information

User Datagram Protocol

User Datagram Protocol Topics Transport Layer TCP s three-way handshake TCP s connection termination sequence TCP s TIME_WAIT state TCP and UDP buffering by the socket layer 2 Introduction UDP is a simple, unreliable datagram

More information

Data and Computer Communications. Chapter 2 Protocol Architecture, TCP/IP, and Internet-Based Applications

Data and Computer Communications. Chapter 2 Protocol Architecture, TCP/IP, and Internet-Based Applications Data and Computer Communications Chapter 2 Protocol Architecture, TCP/IP, and Internet-Based s 1 Need For Protocol Architecture data exchange can involve complex procedures better if task broken into subtasks

More information

SC/CSE 3213 Winter Sebastian Magierowski York University CSE 3213, W13 L8: TCP/IP. Outline. Forwarding over network and data link layers

SC/CSE 3213 Winter Sebastian Magierowski York University CSE 3213, W13 L8: TCP/IP. Outline. Forwarding over network and data link layers SC/CSE 3213 Winter 2013 L8: TCP/IP Overview Sebastian Magierowski York University 1 Outline TCP/IP Reference Model A set of protocols for internetworking The basis of the modern IP Datagram Exchange Examples

More information

TSIN02 - Internetworking

TSIN02 - Internetworking Lecture 4: Transport Layer Literature: Forouzan: ch 11-12 2004 Image Coding Group, Linköpings Universitet Lecture 4: Outline Transport layer responsibilities UDP TCP 2 Transport layer in OSI model Figure

More information

Need For Protocol Architecture

Need For Protocol Architecture Chapter 2 CS420/520 Axel Krings Page 1 Need For Protocol Architecture E.g. File transfer Source must activate communications path or inform network of destination Source must check destination is prepared

More information

Need For Protocol Architecture

Need For Protocol Architecture Chapter 2 CS420/520 Axel Krings Page 1 Need For Protocol Architecture E.g. File transfer Source must activate communications path or inform network of destination Source must check destination is prepared

More information

TCP/IP protocol suite

TCP/IP protocol suite TCP/IP protocol suite The TCP/IP protocol suite was developed prior to the OSI model. Therefore, the layers in the TCP/IP protocol suite do not match exactly with those in the OSI model. The original TCP/IP

More information

Computer Networks (Introduction to TCP/IP Protocols)

Computer Networks (Introduction to TCP/IP Protocols) Network Security(CP33925) Computer Networks (Introduction to TCP/IP Protocols) 부산대학교공과대학정보컴퓨터공학부 Network Type Elements of Protocol OSI Reference Model OSI Layers What we ll learn today 2 Definition of

More information

Internetwork Protocols

Internetwork Protocols Internetwork Protocols Background to IP IP, and related protocols Internetworking Terms (1) Communications Network Facility that provides data transfer service An internet Collection of communications

More information

Socket 101 Excerpt from Network Programming

Socket 101 Excerpt from Network Programming Socket 101 Excerpt from Network Programming EDA095 Nätverksprogrammering Originals by Roger Henriksson Computer Science Lund University Java I/O Streams Stream (swe. Ström) - A stream is a sequential ordering

More information

CS 640: Introduction to Computer Networks. Today s Lecture. Page 1

CS 640: Introduction to Computer Networks. Today s Lecture. Page 1 CS 640: Introduction to Computer Networks Aditya Akella Lecture 2 Layering, Protocol Stacks, and Standards 1 Today s Lecture Layers and Protocols A bit about s 2 Network Communication: Lots of Functions

More information

cs144 Midterm Review Fall 2010

cs144 Midterm Review Fall 2010 cs144 Midterm Review Fall 2010 Administrivia Lab 3 in flight. Due: Thursday, Oct 28 Midterm is this Thursday, Oct 21 (during class) Remember Grading Policy: - Exam grade = max (final, (final + midterm)/2)

More information

Defining Networks with the OSI Model. Module 2

Defining Networks with the OSI Model. Module 2 Defining Networks with the OSI Model Module 2 Objectives Skills Concepts Objective Domain Description Objective Domain Number Understanding OSI Basics Defining the Communications Subnetwork Defining the

More information

Distributed Systems COMP 212. Lecture 8 Othon Michail

Distributed Systems COMP 212. Lecture 8 Othon Michail Distributed Systems COMP 212 Lecture 8 Othon Michail HTTP Protocol Hypertext Transfer Protocol Used to transmit resources on the WWW HTML files, image files, query results, Identified by Uniform Resource

More information

C19: User Datagram and Multicast

C19: User Datagram and Multicast CISC 3120 C19: User Datagram and Multicast Hui Chen Department of Computer & Information Science CUNY Brooklyn College 4/18/2018 CUNY Brooklyn College 1 Outline Recap Network fundamentals IPv4, IPv6 addresses

More information

TSIN02 - Internetworking

TSIN02 - Internetworking TSIN02 - Internetworking Literature: Lecture 4: Transport Layer Forouzan: ch 11-12 Transport layer responsibilities UDP TCP 2004 Image Coding Group, Linköpings Universitet 2 Transport layer in OSI model

More information

Chapter 7 Internet Protocol Version 4 (IPv4) Kyung Hee University

Chapter 7 Internet Protocol Version 4 (IPv4) Kyung Hee University Chapter 7 Internet Protocol Version 4 (IPv4) 1 7.1 Introduction The transmission mechanism used by the TCP/IP Unreliable and connectionless datagram protocol Best-effort delivery service IP packets can

More information

Unix Network Programming

Unix Network Programming Unix Network Programming Remote Communication Dr Hamed Vahdat-Nejad Network Applications Types: Client Server Exampels: A web browser (client) Ap communicating with a Web server An FTP client Fetching

More information

Networking with java (socket programming) a brief study

Networking with java (socket programming) a brief study REVIEWS COMPUTER ENGINEERING Discovery Engineering, Volume 2, Number 7, October 2013 ISSN 2320 6675 EISSN 2320 6853 Discovery Engineering REVIEWS COMPUTER ENGINEERING discovery Engineering Networking with

More information

CSCI-GA Operating Systems. Networking. Hubertus Franke

CSCI-GA Operating Systems. Networking. Hubertus Franke CSCI-GA.2250-001 Operating Systems Networking Hubertus Franke frankeh@cs.nyu.edu Source: Ganesh Sittampalam NYU TCP/IP protocol family IP : Internet Protocol UDP : User Datagram Protocol RTP, traceroute

More information

COMP750. Distributed Systems. Network Overview

COMP750. Distributed Systems. Network Overview COMP750 Distributed Systems Network Overview Network Standards The purpose of a network is to allow two computers to communicate. Ex: The electrical power network in North America follows a standard to

More information

TRANSMISSION CONTROL PROTOCOL. ETI 2506 TELECOMMUNICATION SYSTEMS Monday, 7 November 2016

TRANSMISSION CONTROL PROTOCOL. ETI 2506 TELECOMMUNICATION SYSTEMS Monday, 7 November 2016 TRANSMISSION CONTROL PROTOCOL ETI 2506 TELECOMMUNICATION SYSTEMS Monday, 7 November 2016 ETI 2506 - TELECOMMUNICATION SYLLABUS Principles of Telecom (IP Telephony and IP TV) - Key Issues to remember 1.

More information

Java.net Package and Classes(Url, UrlConnection, HttpUrlConnection)

Java.net Package and Classes(Url, UrlConnection, HttpUrlConnection) Java.net Package and Classes(Url, UrlConnection, HttpUrlConnection) Sisoft Technologies Pvt Ltd SRC E7, Shipra Riviera Bazar, Gyan Khand-3, Indirapuram, Ghaziabad Website: www.sisoft.in Email:info@sisoft.in

More information

Distributed Systems Recitation 2. Tamim Jabban

Distributed Systems Recitation 2. Tamim Jabban 15-440 Distributed Systems Recitation 2 Tamim Jabban Project 1 Involves creating a Distributed File System (DFS) Released yesterday When/If done with PS1, start reading the handout Today: Socket communication!

More information

Introduction to TCP/IP networking

Introduction to TCP/IP networking Introduction to TCP/IP networking TCP/IP protocol family IP : Internet Protocol UDP : User Datagram Protocol RTP, traceroute TCP : Transmission Control Protocol HTTP, FTP, ssh What is an internet? A set

More information

CSCI Computer Networks

CSCI Computer Networks CSCI-1680 - Computer Networks Chen Avin (avin) Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti, Peterson & Davie, Rodrigo Fonseca Administrivia Sign and hand in Collaboration

More information

Introduction to Protocols

Introduction to Protocols Chapter 6 Introduction to Protocols 1 Chapter 6 Introduction to Protocols What is a Network Protocol? A protocol is a set of rules that governs the communications between computers on a network. These

More information

Transport Layer. Chapter 3: Transport Layer

Transport Layer. Chapter 3: Transport Layer Transport Layer EECS 3214 Slides courtesy of J.F Kurose and K.W. Ross, All Rights Reserved 29-Jan-18 1-1 Chapter 3: Transport Layer our goals: understand principles behind layer services: multiplexing,

More information

Chapter 2 - Part 1. The TCP/IP Protocol: The Language of the Internet

Chapter 2 - Part 1. The TCP/IP Protocol: The Language of the Internet Chapter 2 - Part 1 The TCP/IP Protocol: The Language of the Internet Protocols A protocol is a language or set of rules that two or more computers use to communicate 2 Protocol Analogy: Phone Call Parties

More information

IP - The Internet Protocol. Based on the slides of Dr. Jorg Liebeherr, University of Virginia

IP - The Internet Protocol. Based on the slides of Dr. Jorg Liebeherr, University of Virginia IP - The Internet Protocol Based on the slides of Dr. Jorg Liebeherr, University of Virginia Orientation IP (Internet Protocol) is a Network Layer Protocol. IP: The waist of the hourglass IP is the waist

More information

Communication in Distributed Systems: Sockets Programming. Operating Systems

Communication in Distributed Systems: Sockets Programming. Operating Systems Communication in Distributed Systems: Sockets Programming Operating Systems TCP/IP layers Layers Message Application Transport Internet Network interface Messages (UDP) or Streams (TCP) UDP or TCP packets

More information

Chapter 3 Protocols and the TCP/IP Suite

Chapter 3 Protocols and the TCP/IP Suite Chapter 3 Protocols and the TCP/IP Suite 3.1 The Need for a Protocol Architecture need for a standard communication tasks by layers architecture peer protocol: a set of rules or conventions to exchange

More information

Introduction to Sockets 9/25/14

Introduction to Sockets 9/25/14 Introduction to Sockets 9/25/14 81 Remote communication Inter-process communication is at the heart of all distributed systems Using the network protocol stack on a node is the only way to communicate

More information

UNIT IV -- TRANSPORT LAYER

UNIT IV -- TRANSPORT LAYER UNIT IV -- TRANSPORT LAYER TABLE OF CONTENTS 4.1. Transport layer. 02 4.2. Reliable delivery service. 03 4.3. Congestion control. 05 4.4. Connection establishment.. 07 4.5. Flow control 09 4.6. Transmission

More information

Networking: IPv6, UDP and TCP. Network Programming in Java UDP and TCP

Networking: IPv6, UDP and TCP. Network Programming in Java UDP and TCP Networking: IPv6, UDP and TCP Network Programming in Java UDP and TCP SCOMRED, November 2018 Instituto Superior de Engenharia do Porto (ISEP) Departamento de Engenharia Informática(DEI) SWitCH Computing

More information

User Datagram Protocol (UDP):

User Datagram Protocol (UDP): SFWR 4C03: Computer Networks and Computer Security Feb 2-5 2004 Lecturer: Kartik Krishnan Lectures 13-15 User Datagram Protocol (UDP): UDP is a connectionless transport layer protocol: each output operation

More information

03 The Internet Model and TCP/IP

03 The Internet Model and TCP/IP SE 4C03 Winter 2003 03 The Internet Model and TCP/IP Instructor: W. M. Farmer Revised: 16 January 2003 1 The OSI Model In 1977 the International Standards Organization (ISO) offered the Open Systems Interconnection

More information

Distributed Systems Recitation 2. Tamim Jabban

Distributed Systems Recitation 2. Tamim Jabban 15-440 Distributed Systems Recitation 2 Tamim Jabban Agenda Communication via Sockets in Java (this enables you to complete PS1 and start P1 (goes out today!)) Multi-threading in Java Coding a full Client-Server

More information

SERVER/CLIENT NETWORKING AT JAVA PLATFORM

SERVER/CLIENT NETWORKING AT JAVA PLATFORM SERVER/CLIENT NETWORKING AT JAVA PLATFORM Vibhu Chinmay, Shubham Sachdeva Student (B.tech5 th sem) Department of Electronics and Computers Engineering Dronacharya College of Engineering, Gurgaon-123506,

More information

EE 610 Part 2: Encapsulation and network utilities

EE 610 Part 2: Encapsulation and network utilities EE 610 Part 2: Encapsulation and network utilities Objective: After this experiment, the students should be able to: i. Understand the format of standard frames and packet headers. Overview: The Open Systems

More information

UNIT IV TRANSPORT LAYER

UNIT IV TRANSPORT LAYER Transport Layer UNIT IV TRANSPORT LAYER Congestion Control and Quality of Service Ref: Data Communication & Networking, 4 th edition, Forouzan IV-1 DATA TRAFFIC The main focus of congestion control and

More information

Networking for Data Acquisition Systems. Fabrice Le Goff - 14/02/ ISOTDAQ

Networking for Data Acquisition Systems. Fabrice Le Goff - 14/02/ ISOTDAQ Networking for Data Acquisition Systems Fabrice Le Goff - 14/02/2018 - ISOTDAQ Outline Generalities The OSI Model Ethernet and Local Area Networks IP and Routing TCP, UDP and Transport Efficiency Networking

More information

UDP: Datagram Transport Service

UDP: Datagram Transport Service UDP: Datagram Transport Service 1 Topics Covered Introduction Transport Protocols and End-to-End Communication The User Datagram Protocol The Connectionless Paradigm Message-Oriented Interface UDP Communication

More information

Introduction to Open System Interconnection Reference Model

Introduction to Open System Interconnection Reference Model Chapter 5 Introduction to OSI Reference Model 1 Chapter 5 Introduction to Open System Interconnection Reference Model Introduction The Open Systems Interconnection (OSI) model is a reference tool for understanding

More information

Lecture 2 Communication services The Trasport Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

Lecture 2 Communication services The Trasport Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it Lecture 2 Communication services The Trasport Layer Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it The structure edge: applications and hosts core: routers of s access s, media:

More information

Operating Systems. 16. Networking. Paul Krzyzanowski. Rutgers University. Spring /6/ Paul Krzyzanowski

Operating Systems. 16. Networking. Paul Krzyzanowski. Rutgers University. Spring /6/ Paul Krzyzanowski Operating Systems 16. Networking Paul Krzyzanowski Rutgers University Spring 2015 1 Local Area Network (LAN) LAN = communications network Small area (building, set of buildings) Same, sometimes shared,

More information

Distributed Systems. 02. Networking. Paul Krzyzanowski. Rutgers University. Fall 2017

Distributed Systems. 02. Networking. Paul Krzyzanowski. Rutgers University. Fall 2017 Distributed Systems 02. Networking Paul Krzyzanowski Rutgers University Fall 2017 1 Inter-computer communication Without shared memory, computers need to communicate Direct link Direct links aren't practical

More information

Chapter 23 Process-to-Process Delivery: UDP, TCP, and SCTP 23.1

Chapter 23 Process-to-Process Delivery: UDP, TCP, and SCTP 23.1 Chapter 23 Process-to-Process Delivery: UDP, TCP, and SCTP 23.1 Copyright The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 23-1 PROCESS-TO-PROCESS DELIVERY 23.2 The transport

More information

ch02 True/False Indicate whether the statement is true or false.

ch02 True/False Indicate whether the statement is true or false. ch02 True/False Indicate whether the statement is true or false. 1. No matter what medium connects computers on a network copper wires, fiber-optic cables, or a wireless setup the same protocol must be

More information

The ASP Virtual Networking (VNET) Component. 23 July Abstract

The ASP Virtual Networking (VNET) Component. 23 July Abstract The ASP Virtual Networking (VNET) Component 23 July 2002 Abstract This document describes the implementation of the virtual networking (VNET) component of the ASP EE. VNET is a simple and modular implementation

More information

Computer Communication & Networks / Data Communication & Computer Networks Week # 03

Computer Communication & Networks / Data Communication & Computer Networks Week # 03 Computer Communication & Networks / Data Communication & Computer Networks Week # 03 M.Nadeem Akhtar CS & IT Department The University of Lahore Email: nadeem.akhtar@cs.uol.edu.pk URL-https://sites.google.com/site/nadeemuolcsccn/home

More information

CS 428/528 Computer Networks Lecture 01. Yan Wang

CS 428/528 Computer Networks Lecture 01. Yan Wang 1 CS 428/528 Computer Lecture 01 Yan Wang 2 Motivation: Why bother? Explosive growth of networks 1989, 100,000 hosts on the Internet Distributed Applications and Systems E-mail, WWW, multimedia, distributed

More information