HTTP-Messages Flashcards

1
Q

What is a client?

A

It is an interface that a user interacts with to receive data, content or a service

Whether a computer is a client, a server, or both, is determined by the nature of the application that requires the service functions.

The client sends a request, and the server returns a response.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is a server?

A

usually another computer (or in the same system) that the user accesses via the client

Whether a computer is a client, a server, or both, is determined by the nature of the application that requires the service functions.

The client sends a request, and the server returns a response.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Which HTTP method does a browser issue to a web server when you visit a URL?

A

GET request mthod

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is on the first line of an HTTP request message?

A

HTTP Method, the request target (URL usually) and HTTP version

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is on the first line of an HTTP response message?

A

protocol version (usually HTTP/1.1), status code (200, 204 or 302), status text (connects to status code)

HTTP/1.1 404 Not Found

General headers – apply to the whole message.
Request headers – additional info
Entity headers – content length, data types

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Is a body required for a valid HTTP message?

A

no, requests fetching resources, like GET, HEAD, DELETE, or OPTIONS, usually don’t need one.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What are HTTP headers?

A

meta data about request and response

General headers – apply to the whole message.
Request headers – additional info
Entity headers – content length, data types

How well did you know this?
1
Not at all
2
3
4
5
Perfectly