Cat Feeder  1.0.0
The Cat feeder project
Loading...
Searching...
No Matches
server_header_constants.py
Go to the documentation of this file.
1r"""
2# +==== BEGIN CatFeeder =================+
3# LOGO:
4# ..............(..../\
5# ...............)..(.')
6# ..............(../..)
7# ...............\‍(__)|
8# Inspired by Joan Stark
9# source https://www.asciiart.eu/
10# animals/cats
11# /STOP
12# PROJECT: CatFeeder
13# FILE: server_header_constants.py
14# CREATION DATE: 27-11-2025
15# LAST Modified: 14:51:45 19-12-2025
16# DESCRIPTION:
17# This is the backend server in charge of making the actual website work.
18# /STOP
19# COPYRIGHT: (c) Cat Feeder
20# PURPOSE: The constants used in the Server Header class
21# // AR
22# +==== END CatFeeder =================+
23"""
24
25# Custom application headers
26# Custom header to identify the application sending the response
27HEADER_APP_NAME: str = "app_sender"
28
29# Caching control headers
30# Directives for caching mechanisms in browsers and proxies
31CACHE_CONTROL: str = "Cache-Control"
32# HTTP/1.0 backward-compatible cache control (deprecated but still used)
33PRAGMA: str = "Pragma"
34EXPIRES: str = "Expires" # Date/time after which the response is considered stale
35
36# Content delivery headers
37# Indicates if content should be inline or attachment with filename
38CONTENT_DISPOSITION: str = "Content-Disposition"
39
40# Privacy and referrer headers
41# Controls how much referrer information is sent with requests
42REFERRER_POLICY: str = "Referrer-Policy"
43
44# Range request headers
45# Indicates server support for partial content requests (streaming/seeking)
46ACCEPT_RANGES: str = "Accept-Ranges"
47
48# Security headers
49# Prevents XSS by controlling allowed content sources
50CONTENT_SECURITY_POLICY: str = "Content-Security-Policy"
51# Prevents MIME type sniffing attacks
52CONTENT_TYPE: str = "X-Content-Type-Options"
53# Prevents clickjacking by controlling iframe embedding
54FRAME_OPTIONS: str = "X-Frame-Options"
55# Enables browser's built-in XSS filter (legacy but still used)
56XSS_PROTECTION: str = "X-XSS-Protection"