bg_image
header

Entity Header

Entity headers are HTTP headers that provide information about the body of a message. They can appear in both requests and responses, describing properties of the content such as type, length, encoding, or last modification date.

Important Entity Headers:

1. Content-Type

  • Specifies the media type (MIME type) of the content.
  • Example:
Content-Type: application/json; charset=UTF-8

2. Content-Length

  • Indicates the size of the content in bytes.
  • Example:
Content-Length: 1024

3. Content-Encoding

  • Shows if the content has been compressed (e.g., gzip).
  • Example:
Content-Encoding: gzip

4. Content-Language

  • Specifies the language of the content.
  • Example:
Content-Language: de-DE

5. Cache-Location

  • Indicates the URL or storage location of the actual resource.
  • Example:
Content-Location: /files/document.pdf

6. Last-Modified

  • Specifies when the content was last changed.
  • Example:
Last-Modified: Tue, 30 Jan 2025 14:20:00 GMT

7. ETag

  • A unique identifier for a version of the resource, useful for caching.
  • Example:
ETag: "abc123xyz"

8. Expires

  • Indicates when the content should be considered outdated.
  • Example:
Expires: Fri, 02 Feb 2025 12:00:00 GMT

9. Allow

  • Lists the allowed HTTP methods for a resource.
  • Example:
Allow: GET, POST, HEAD

10. Refresh  (Not standardized but often used)

  • Instructs the browser to refresh the page after a specified time.
  • Example:
Refresh: 10; url=https://example.com

These headers help describe the content of an HTTP message, optimize caching strategies, and ensure correct rendering.




Created 13 Hours 58 Minutes ago
General HTTP headers Response Headers Apache HTTP Server Entity Entity-Header HTTP Request headers HTTP Header HyperText Markup Language - HTML Hypertext Transfer Protocol - HTTP Hypertext Transfer Protocol Secure - HTTPS Communication Properties Uniform Resource Locator - URL Web Development

Leave a Comment Cancel Reply
* Required Field
Random Tech

Open Web Application Security Project - OWASP


owasp.png