application layer Flashcards
process
a program running code within a host on the application layer
encapsulation
the message going through each layer with each one adding its header to it
decapsulation
the message going back up the layers with each one processing its header then removing it
what are the benefits of encapsulation and decapsulation
allows each layer to operate independently
each layer only has to be concerned with its corresponding header
client process
initiates communication
server process
waits to be contacted
why do we need interfaces
so that the layers can communicate with each other
what is the interface used between the application and transport layer
socket
which 2 pieces of information do we need when sending a message
ip address
port number
ip address
network identifier
ipv4; 32
ipv6; 128
port number
transport layer identifier that delivers the message to the right process
why do we need both the ip and port number when sending messages
many processes can be on the same host so we need to specify which one
5 tuple
uniquely identifies a communication between two processes
what do we need to create the 5 tuple
source and destination ip
source and destination port number
transport protocol
how does the client know which port to use
popular applications have well know ports
ephemeral ports are arbitrary numbers automatically assigned by the os and are used for temporary communication
what are some standard api system calls
read()
write()
close()
what are some socket specific calls
send()
recv()
bind()
what defines application layer protocols
a set of messages with their type and when and how processes send and respond to protocols given the value of the field
open protocols
have public documents explaining the messages and fields
e.g. http
propriety protocols
not public and are tied to specific products
e.g. skype
what might an application need form the transport layer
data integrity
timing
throughput
security
tcp service
reliable
provides congestion and flow control
connection oriented
tcp as reliable
guaranteed that messages are delivered in the order that they were sent
tcp and congestion control
can delay or reduce the number of packets sent if theres high congestion