Web Application Basics
18 May 2025
• 1 min read
What is a Uniform resource locator (URL)
Scheme
-
either http or https (most common)
-
user field is rare now days because of the security risk
-
Host/domain the name of the website and is vulnerable to typosquatting
-
the port is the help us to access the needed service on the web server
-
path represents where are we on the web server
-
query string is usually used for search and is vulnerable to injection attacks
-
fragment help use divide the single web page into parts that we can jump to
http requests/responses
Security Headers
-
Content-Security-Policy(CSP)
- Can help us defend against XSS
- It says which websites are trusted
-
Strict-Transport-Security (HSTS)
- The HSTS header ensures that web browsers will always connect over HTTPS
-
X-Content-Type-Options
- Instructs the browser to not guess the MIME time and use the content-type header
-
Referrer-Policy
- How much data will be sent to the user when being reffered