HTTP Protocol Basics Flashcards
HTTP (Hypertext Transfer Protocol)
- clear-text
- most used app protocol
- client-server
- transfers web pages and web app data
- can be intercepted
- does not provide strong authentication between parties
HTTP first step
client (usually web browser) connects to web server (MS IIS r Apache HTTP Server)
HTTP second step
client and server exchange messages (request & response)
How is HTTP related to TCP protocol?
It works on top of TCP.
- TCP connection is made
- client sends request
- server processes request
- server send back answer w/ status code and data
What is the format of an HTTP message?
- Headers\r\n
- \r\n
- Message Body\r\n
How do you end lines in HTTP?
\r : carriage return
\n: newline
What is the format of an HTTP header field?
Header-name: header value
HTTP verb
- aka: request method
- state the type of request
GET request
used when opening web resources
After the HTTP verb, there is a path. What does the path do?
tells server which resources the browser is asking for
After the HTTP verb and path, there is the protocol version. What is the protocol version?
tells server how to communicate with the browser
What is the structure of the first line of an HTTP request?
HTTP VERB, path, protocol version
What does the HTTP Request Host header field specify?
- it specifies the internet hostname and port number of the resource being requested
- tells server which site client is asking for
URI
identifies a specific resuorce: page, book, document
URL
- type of URI
- tells you how to access the resource: HTTPS, FTP