Trivial Protocols CS328 Dick Steflik Whats a Protocol

  • Slides: 16
Download presentation
Trivial Protocols CS-328 Dick Steflik

Trivial Protocols CS-328 Dick Steflik

What’s a Protocol • The rules that govern the exchange of information between to

What’s a Protocol • The rules that govern the exchange of information between to hosts – when a dignitary visits a foreign country there are certain rules of protocol that they must follow – when you meet the Queen of Great Britain you bow or curtsey

more specifically… • Communications rules – who initiates the exchange – who terminates the

more specifically… • Communications rules – who initiates the exchange – who terminates the exchange – what order things are done in • finite state machine model – option negotiation

Day. Time • • RFC 868, RFC 867 TCP and UDP port 13 client

Day. Time • • RFC 868, RFC 867 TCP and UDP port 13 client connects to port 13 – server returns date/time and closes connection

Echo • • RFC 862 TCP and UDP well known port 7 TCP Client

Echo • • RFC 862 TCP and UDP well known port 7 TCP Client opens connection on port 7 – Client sends data <crlf> – server echos data back – repeat prev two steps – client closes connection

Echo • UDP Client connects and sends data – host receives and immediately returns

Echo • UDP Client connects and sends data – host receives and immediately returns datagram

Finger • • Retrieve user information from remote host RFC 1288 well known TCP

Finger • • Retrieve user information from remote host RFC 1288 well known TCP port 79 Client opens connection on port 79 – client sends finger query – remote host runs query, returns data and closes connection

Finger • Remote User Interface Program (RUIP) – program on remote host that performs

Finger • Remote User Interface Program (RUIP) – program on remote host that performs finger queries – may be turned off in TCP/IP config – may be configured to return limited info on user for security purposes – format may be differant on various platforms

Finger • Security – many sites don’t fun finger servers • a bug in

Finger • Security – many sites don’t fun finger servers • a bug in the original finger left a hole through which unfriendly and unnatural acts could be done – 1988 - Internet Worm gained machine access via the finger bug – some sites run a finger server that just returns a textual message

Post Office Protocol (POP 3) • Used in conjunction with an. SMTP Host –

Post Office Protocol (POP 3) • Used in conjunction with an. SMTP Host – SMTP Host sends and receives e-mail for remote users, POP allows users to retreive their mail from the host. – SMTP stores mail for unconnected hosts • RFC 1730 • TCP Port 110

POP 3 • protocol is relatively simple – connect to port 110 of remote

POP 3 • protocol is relatively simple – connect to port 110 of remote host • read back a response check for OK or ERR • over and over again – close the connection

POP 3 - State Machine Commands Auth USER Transaction PASS QUIT Update

POP 3 - State Machine Commands Auth USER Transaction PASS QUIT Update

POP 3 • Commands – USER name • terminate with <crlf> • identifies the

POP 3 • Commands – USER name • terminate with <crlf> • identifies the user/mail drop name – PASS string • user password • usually the same as the user’s logon password – STAT • request number of messages on server and size of mail drop

POP 3 (Commands) – LIST • return a list <crlf> of all msgs on

POP 3 (Commands) – LIST • return a list <crlf> of all msgs on server – format msg size – LIST [msg_no] • request size of msg_no – format msg_no size – RETR msg_no • return the message identified by msg_no

POP 3 (Commands) – DELE msg_no • delete msg_no from server • happens in

POP 3 (Commands) – DELE msg_no • delete msg_no from server • happens in UPDATE State – NOOP • nothing except a positive reply from server – RSET • reset all deletions pending on server – QUIT • quit session, UPDATE, enter AUTH 1 State