SocketProgramming

SocketProgramming - TodaysAgenda 1. Overview of Socket...

Info iconThis preview shows pages 1–10. Sign up to view the full content.

View Full Document Right Arrow Icon
CSCI 232: Computer Networks Socket API 1 Today’s Agenda 1. Overview of Socket Programming 2. Project Description
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
CSCI 232: Computer Networks Socket API 2 Socket Programming Socket Programming Overview BSD Unix C Socket Programming API Handle asynchronous  input output from multiple socket  descriptors Additional Readings on BSD Socket on class website;  Online Project I Description
Background image of page 2
CSCI 232: Computer Networks Socket API 3 Soothing words Don’t worry too much about the sense of information  overload you may get from this lecture.  There is a lot of  detail about sockets that you don’t need to remember,  because you can look it up.  Pay attention to the patterns  and outlines of what’s going on, and use reference  material for the details as you program.
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
CSCI 232: Computer Networks Socket API 4 Refreshing  Host (NIC card) identified by unique IP address Network application/process identified by port number Network connection identified by a 5-tuple ( src ip, src port, dst ip,  dst port, protocol ) Two kinds of Internet transport services provided to applications Connection-oriented TCP Connectionless UDP 
Background image of page 4
CSCI 232: Computer Networks Socket API 5 Huh? We haven’t yet covered the transport layer in class, and  yet you’re being called on to use sockets to access  transport services This is partly a matter of semester mechanics, and partly  because everything has to start somewhere Treat this as your intro to the essentials of transport,  with details to follow
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
CSCI 232: Computer Networks Socket API 6 Socket Programming API API: Application Programming  Interface Socket analogous to door  sending process shoves message out door sending process assumes transport  infrastructure on other side of door that  brings message to socket at receiving  process connection between sockets set- up/managed by OS process TCP with buffers, variables socket host or server process TCP with buffers, variables socket host or server Internet controlled by OS controlled by app developer
Background image of page 6
CSCI 232: Computer Networks Socket API 7 What APIs Needed? How to create socket (door) How to establish connection Client connects to a server Server accepts client req. How to send/recv data How to identify socket Bind to local address/port How to close socket (door) How to create socket How to send/recv data How to identify socket How to close socket Connection-Oriented TCP Connectionless UDP
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
CSCI 232: Computer Networks Socket API 8 Socket: Conceptual View
Background image of page 8
CSCI 232: Computer Networks Socket API 9 Another conceptual view Physical layer Link layer Internet layer Transport layer Other layers Socket {API/layer} Kernel Hardware User
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 10
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 12/04/2009 for the course CS 183 taught by Professor Susan during the Spring '09 term at GWU.

Page1 / 48

SocketProgramming - TodaysAgenda 1. Overview of Socket...

This preview shows document pages 1 - 10. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online