MODULE 1 - Core internet technologies Flashcards
Why are IP addresses important for data transmission on the internet?
IP addresses are crucial because they function like postal addresses, ensuring that packets of information are delivered to the correct destination.
What are the two most widely used standards of Internet Protocol?
The two most widely used standards are Internet Protocol version 4 (IPv4) and Internet Protocol version 6 (IPv6).
How is an IPv4 address structured?
An IPv4 address consists of four octets (A group or set of eight of something) separated by periods or dots. For example, 192.0.2.235.
How is an IPv6 address structured?
An IPv6 address contains eight groups of hexadecimal digits separated by colons. For example, 4527:0a00:1567:0200:ff00:0042:8329.
What are IP packets and what do they contain?
IP packets, also known as datagrams, are the messages sent across a network. They contain a header and a payload. The header includes metadata such as the source and destination IP addresses, while the payload contains the actual data being transmitted.
What are some common issues that can occur during data transmission, similar to postal system issues?
Just like letters can arrive out of order, get damaged, or be lost, IP packets can also arrive out of order, become damaged or corrupted, or be dropped or lost during transit.
How are these transmission issues addressed in data packets?
To address these issues, the payload part of the packets contains other protocols. The most common ones are the Transmission Control Protocol (TCP) and the User Datagram Protocol (UDP).
What does TCP do to ensure data integrity, and what is its drawback?
TCP ensures that data arrives correctly and in order, solving issues like out-of-order arrival, damage, and loss. However, this comes with a small delay in sending the data.
For what type of data transmission is TCP typically used?
TCP is used for sending data that must arrive correctly and in order, such as text files and images.
What are the characteristics of UDP in data transmission?
UDP can solve the corrupt packet issue but does not ensure that packets arrive in order or that all packets arrive. It allows for faster transmission with some data loss.
For what type of data transmission is UDP typically used?
UDP is used for sending data that can tolerate some loss, such as voice calls or live video streaming.
What is the importance of header in an IP packet?
The header contains essential information required for the packet to reach its destination and for proper handling during transmission.
What is the importance of payload in an IP packet?
The payload contains the actual data being transmitted from the sender to the receiver.
How does TCP ensure reliable data transmission?
TCP ensures reliability through several mechanisms:
1) Connection Establishment: TCP establishes a connection between the sender and receiver using a process called the three-way handshake before data transfer begins.
2) Data Segmentation and Sequencing: Data is broken into smaller segments, each with a sequence number. This allows the receiver to reassemble the data in the correct order.
3) Acknowledgments: The receiver sends back an acknowledgment (ACK) for each segment received. If the sender does not receive an ACK within a certain time, it resends the segment.
4) Error Detection and Correction: TCP checks for errors in the data and ensures that any corrupted data is retransmitted.
What is the Three-Way handshake?
Before data transfer can begin, TCP establishes a reliable connection between the sender and the receiver to ensure that both parties are ready to communicate.
PROCESS:
1) SYN (Synchronize) Packet: The sender starts by sending a SYN packet to the receiver to initiate the connection.
2) SYN-ACK (Synchronize-Acknowledge) Packet: The receiver responds with a SYN-ACK packet, acknowledging the receipt of the SYN packet and indicating its willingness to establish the connection.
3) ACK (Acknowledge) Packet: Finally, the sender sends an ACK packet back to the receiver, confirming that the connection is established.
How does UDP ensure fast data transmission?
UDP achieves fast transmission through the following:
- Connectionless Protocol: UDP does not establish a connection before sending data. Each packet, known as a datagram, is sent independently.
- No Sequencing or Acknowledgments: UDP does not number the packets or wait for acknowledgments, reducing overhead and delay.
- Minimal Error Checking: UDP includes a simple checksum for error checking but does not provide mechanisms for error correction.
How does UDP handle data transmission without a connection?
In UDP, each datagram or data packet is sent individually and includes the destination address. There is no handshake process or acknowledgment of receipt. If a datagram is lost or arrives out of order, UDP does not attempt to resend or reorder it.
SUMMARY
Summary of TCP and UDP
Connection-Oriented (TCP):
* Establishes a connection before data transmission.
* Ensures reliable, ordered delivery of data.
* Involves higher overhead and potential delays.
* Suitable for applications where data integrity and order are critical.
Connectionless (UDP):
* Does not establish a connection before data transmission.
* Each packet is sent independently without acknowledgment.
* Involves lower overhead and reduced latency.
* Suitable for applications where speed is more important than reliability and some data loss is acceptable.
When is TCP typically used?
TCP is used for applications where reliable and ordered delivery of data is crucial, such as:
- Web browsing (HTTP/HTTPS)
- Email (SMTP, IMAP, POP3)
- File transfers (FTP)
- Remote terminal access (SSH, Telnet)
When is UDP typically used?
UDP is used for applications where speed is essential and some data loss is acceptable, such as:
- Live video and audio streaming
- Online gaming
- Voice over IP (VoIP)
- Broadcast and multicast communication
What is HTTP and how does it function in web communication?
HTTP stands for Hypertext Transfer Protocol. It is a fundamental protocol used for transmitting web resources such as HTML documents, images, and stylesheets between a client (like a web browser) and a server (hosting the website). HTTP operates on a request-response model where the client initiates a request and the server responds accordingly.
What does HTTPS stand for and how does it differ from HTTP?
HTTPS stands for Hypertext Transfer Protocol Secure. It is the secure version of HTTP. HTTPS ensures encrypted communication between the client and the server, protecting the integrity and confidentiality of data transmitted over the network. You can identify HTTPS usage by the presence of a lock icon in the browser’s address bar.
What are the primary components of an HTTP request?
An HTTP request consists of:
- Method: Specifies the action to be performed (e.g., GET, POST).
- Path: The location of the resource on the server.
- Version: The HTTP version being used (e.g., HTTP/1.1, HTTP/2.0).
- Headers: Additional metadata about the request.
- Body: Optional data sent with methods like POST.
Can you explain the common HTTP methods used?
- GET: The client requests a resource on the web server.
- POST: The client submits data to a resource on the web server.
- PUT: The client replaces a resource on the web server.
- DELETE: The client deletes a resource on the web server.
- PATCH: The client partially updates a resource on the web server.
How are HTTP responses structured?
An HTTP response comprises:
- Status Line: Includes the status code (e.g., 200 for success) and status message.
- Headers: Additional information about the response.
- Body: Optional content like HTML documents or images.
Which versions of the HTTP protocol are most used?
Versions 1.1 and 2.0
What is the range of HTTP status codes?
100-599
What are the 5 groups of status codes?
- 100-199: Informational
- 200-299: Successful response
- 300-399: Redirection
- 400-499: Client error
- 500-599: Server error
How does HTTPS ensure secure communication?
HTTPS uses encryption to secure data transmission between the client and the server. Encryption converts data into a format that is unreadable to anyone who intercepts it without the decryption key, thus ensuring that sensitive information like credit card details remains private.
What are Informational responses?
These status codes indicate provisional responses from the server. They inform the client that the server has received the request and is continuing the process.
Example Codes:
- 100 Continue: Indicates that the initial part of the request has been received and the client should proceed with the request or ignore it if already completed.
- 101 Switching Protocols: Indicates that the server is willing to change the application protocol being used by the client.
What are Successful responses?
These status codes indicate that the request was successfully received, understood, and accepted by the server.
Example Codes:
- 200 OK: Standard response for successful HTTP requests.
- 201 Created: Indicates that the request has been fulfilled and a new resource has been created.
- 204 No Content: Indicates that the server successfully processed the request but is not returning any content (commonly used for DELETE operations).
What are Redirection responses?
These status codes indicate that further action needs to be taken by the client to complete the request.
Example Codes:
- 301 Moved Permanently: The requested resource has been permanently moved to a new URL, and the client should update its records.
- 302 Found: Indicates a temporary redirection. The client should use the new URL provided in the Location header for future requests.
- 304 Not Modified: Used for caching purposes. Indicates that the resource has not been modified since the last request.
What are Client Error responses?
These status codes indicate that there was an error in the client’s request, preventing the server from fulfilling it.
Example Codes:
- 400 Bad Request: The server cannot process the request due to malformed syntax or other client-side errors.
- 401 Unauthorized: Authentication is required and has failed or has not been provided.
- 403 Forbidden: The server understood the request but refuses to authorize it.
- 404 Not Found: The requested resource could not be found on the server.
What are Server error responses?
These status codes indicate that the server encountered an unexpected condition that prevented it from fulfilling the request.
Example Codes:
- 500 Internal Server Error: A generic error message indicating that something has gone wrong on the server-side, without specifying the exact nature of the problem.
- 502 Bad Gateway: Indicates that the server received an invalid response from an inbound server while acting as a gateway or proxy.
- 503 Service Unavailable: The server is currently unable to handle the request due to temporary overloading or maintenance of the server.
What is an HTTP request?
An HTTP request is a message sent by a client (usually a web browser) to a server (hosting a website) to request a specific action.
used to retrieve pages, send data to servers, update or delete resources
What is an HTTP response?
An HTTP response is a message sent by the server back to the client in response to an HTTP request.
informs client about the status of request and provide requested info
What are the common HTTP request headers?
HTTP request headersconvey additional context about the request, the client, and the desired response.
- Host: Specifies the domain name of the server (for virtual hosting) and the TCP port number on which the server is listening. For example, Host: www.example.com.
- User-Agent: Contains information about the user agent (the client software) initiating the request. This can include details about the browser version, operating system, and more. For example, User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64).
- Accept: Informs the server about the types of media that the client can process. For example, Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp.
- Accept-Language: Indicates the natural languages that the client prefers for the response. For example, Accept-Language: en-US,en;q=0.5.
- Content-Type: The Content-type header indicates the type of content being transmitted in the request body.
What is HTTP request body?
HTTP requests can optionally include a request body. A request body is often included when using the HTTP POST and PUT methods to transmit data.
Common 1xx (Informational) status codes
- 100- Continue: The server received the request headers and should continue to send the request body.
- 101- Switching protocols: The client has requested the server to switch protocols and the server has agreed to do so.
Common 2xx (Successful) status codes
- 200- OK: Standard response returned by the server to indicate it successfully processed the request.
- 201- Created: The server successfully processed the request and a resource was created.
- 202- Accepted: The server accepted the request for processing but the processing has not yet been completed.
- 204- No Content: The server successfully processed the request but is not returning any content.
Common 3xx (Redirection) status codes
- 301- Moved permanently: This request and all future requests should be sent to the returned location.
- 302- Found: This request should be sent to the returned location.
Common 4xx (Client Error) status codes
- 404- Bad request: The server cannot process the request due to a client error, e.g., invalid request or transmitted data is too large.
- 401- Unauthorised: The client making the request is unauthorized and should authenticate.
- 403- Forbidden: The request was valid but the server is refusing to process it. This is usually returned due to the client having insufficient permissions for the website, e.g., requesting an administrator action but the user is not an administrator.
- 404- Not Found: The server did not find the requested resource.
- 405- Method not allowed: The web server does not support the HTTP method used.
Common 5xx (Server Error) status codes
- 500- Internal server error: A generic error status code given when an unexpected error or condition occurred while processing the request.
- 502- Bad gateway: The web server received an invalid response from the Application Server.
- 503- Service unavailable: The web server cannot process the request.
What are the common HTTP response headers?
- Date: The Date header specifies the date and time the HTTP response was generated.
- Server: The Server header describes the web server software used to generate the response.
- Content-Length: The Content-Length header describes the length of the response.
- Content-type: The Content-Type header describes the media type of the resource returned (e.g. HTML document, image, video).
What is HTTP repsonse body?
Following the HTTP response headers is the HTTP response body. This is the main content of the HTTP response.
This can contain images, video, HTML documents and other media types.
What is DHCP?
DHCP stands for Dynamic Host Configuration Protocol. It is a network management protocol used on IP networks where a DHCP server dynamically assigns IP addresses and other network configuration parameters to devices connected to the network.
Why is DHCP necessary?
Computers and devices need IP addresses to communicate over a network. DHCP automates and simplifies the process of IP address allocation, making network administration more efficient.
How does DHCP assign IP addresses?
1) DHCP Discover: The client device broadcasts a DHCP Discover message to find available DHCP servers.
2) DHCP Offer: The DHCP server responds with a DHCP Offer, offering an IP address and configuration settings.
3) DHCP Request: The client replies with a DHCP Request message, asking to use the offered IP address.
4) DHCP Acknowledge: The DHCP server sends a DHCP Acknowledge, confirming the allocation of the IP address to the client.
What protocol does DHCP use for communication?
DHCP primarily uses the User Datagram Protocol (UDP) as its transport protocol. UDP is preferred over TCP because it is faster and more efficient for simple, short-lived transactions like DHCP requests and responses.
What is a DHCP server?
A DHCP server is a network server that automatically provides and manages IP addresses and other network configuration information to devices on a network. It keeps track of IP address leases, ensuring that addresses are allocated efficiently without conflicts.
What is DNS and why is it important?
DNS, or the Domain Name System, is a hierarchical decentralized naming system for computers, services, or any resource connected to the Internet or a private network. It translates domain names (like meta.com) into IP addresses (like 192.0.2.1) that computers use to identify each other on a network.
What is IMAP?
IMAP, which stands for Internet Message Access Protocol, is a protocol used by email clients to retrieve emails from a mail server. Unlike older protocols like POP (Post Office Protocol), IMAP is designed to allow users to manage their email messages directly on the server, enabling access from multiple devices while keeping emails synchronized.
How does IMAP differ from other email protocols like POP?
Unlike POP (Post Office Protocol), which typically downloads emails to a local device and removes them from the server, IMAP keeps emails stored on the server. This allows users to access and manage their email from multiple devices while keeping all changes synchronized.