Project: Trace a Request and Build a Network Evidence Pack
Follow a real HTTPS request through DNS, TCP, and TLS, then document the evidence like a professional analyst.
By the end, you’ll be able to…
- Explain DNS resolution and the role of common record types.
- Read an HTTP request and response, including security-relevant headers.
- Describe the TLS handshake and inspect a certificate chain.
- Produce a reproducible evidence pack with commands, outputs, and observations.
01DNS: The First Answer Is Not Always the Truth
DNS translates names into records. An A record maps a name to an IPv4 address, AAAA maps to IPv6, CNAME creates an alias, MX identifies mail servers, and TXT carries arbitrary text often used for verification and email policy. A recursive resolver walks the DNS hierarchy, caches answers, and returns the result to your client.
DNS is attractive to attackers because it is everywhere and often unencrypted. Cache poisoning attempts to insert false answers. Typosquatting registers names that look like a trusted brand. DNS tunnelling hides data inside query names. A compromised registrar account can redirect an entire domain without touching the origin server. Defenders use DNSSEC where available, encrypted DNS for privacy, registrar locks, MFA, and monitoring for unexpected record changes.
For an investigation, record the resolver you used, the query type, the answer, and the time. Different resolvers and locations can return different results because of caching, geo-routing, or malicious targeting. 'It resolved to this IP' is stronger when you can say when, from where, and through which resolver.
# Basic records and the resolver used.dig example.com Adig example.com AAAAdig example.com MXdig example.com TXT# Follow the delegation chain from the root.dig +trace example.com A# Query a specific public resolver for comparison.dig @1.1.1.1 example.com A +shortexample.com. 300 IN A 203.0.113.10 example.com. 300 IN AAAA 2001:db8::10 example.com. 3600 IN MX 10 mail.example.com. example.com. 300 IN TXT "v=spf1 -all"
02HTTP: Requests, Responses, and Headers That Matter
HTTP is a request-response protocol. A request contains a method, a target, headers, and sometimes a body. A response contains a status code, headers, and a body. Methods communicate intent: GET retrieves, POST creates or submits, PUT replaces, PATCH partially updates, and DELETE removes. Status codes communicate outcome: 2xx success, 3xx redirection, 4xx client error, 5xx server error.
Security lives in the details. The Host header selects a virtual host and can be abused if the application trusts it blindly. Cookies carry session state and need Secure, HttpOnly, and appropriate SameSite attributes. Content-Security-Policy limits where scripts can load from. Strict-Transport-Security tells browsers to use HTTPS for future visits. CORS headers decide which origins may read responses. Cache-Control affects whether sensitive pages are stored on shared devices.
Headers are not decoration. A missing security header can widen an attack, and a misconfigured one can break an application. When reviewing a site, capture the raw response headers, not just the rendered page. Then explain what each security-relevant header does and whether its value matches the application's design.
# Show response headers without downloading the body.curl -sS -D - -o /dev/null https://example.com/# Follow redirects and show the final headers.curl -sSL -D - -o /dev/null https://example.com/# Send a request with a custom Host header in a lab only.curl -sS -H "Host: lab.example.test" http://10.10.10.30/ -o /dev/null -D -HTTP/1.1 200 OK content-type: text/html; charset=UTF-8 strict-transport-security: max-age=31536000 content-security-policy: default-src 'self' x-content-type-options: nosniff cache-control: no-store
03TLS: Encryption With an Identity Check
TLS protects data in transit and authenticates the server. The client and server negotiate a protocol version and cipher suite, the server presents a certificate, and both sides derive session keys. Modern TLS 1.3 combines key exchange and authentication in a shorter handshake. The certificate binds a public key to a name, and the certificate chain connects that certificate to a trusted root authority.
Encryption without identity verification is dangerous. If a client accepts any certificate, an attacker on the path can impersonate the server. Browsers and operating systems maintain trust stores and check the certificate's hostname, validity dates, key usage, and revocation status. A certificate warning is a signal to stop, not a nuisance to click through.
TLS does not protect data after it is decrypted, and it does not make a vulnerable application safe. It also does not hide metadata such as the destination IP, SNI in many deployments, or traffic volume. Defenders still need application authentication, authorisation, input validation, and logging. TLS is one layer, not a complete security strategy.
# Inspect the certificate chain and negotiated protocol.openssl s_client -connect example.com:443 -servername example.com </dev/null 2>/dev/null | openssl x509 -noout -subject -issuer -dates -ext subjectAltName# Check the negotiated TLS version and cipher.openssl s_client -connect example.com:443 -servername example.com </dev/null 2>/dev/null | grep -E "Protocol|Cipher"subject=CN = example.com
issuer=C = US, O = Example CA, CN = Example CA R1
notBefore=Jan 1 00:00:00 2026 GMT
notAfter=Apr 1 00:00:00 2026 GMT
X509v3 Subject Alternative Name:
DNS:example.com, DNS:www.example.com
Protocol : TLSv1.3
Cipher : TLS_AES_256_GCM_SHA38404Project Brief: The Network Evidence Pack
Choose a domain you own or a public site you are allowed to inspect passively. Do not scan, brute-force, or send attack traffic. Your task is observation, not exploitation. Produce a Markdown evidence pack with five sections: scope and time, DNS observations, TCP and HTTP observations, TLS observations, and a short risk commentary.
Include the exact commands you ran and their relevant output. Redact any personal or internal information that does not belong in a public portfolio. Explain what each result proves and what it does not prove. For example, a valid certificate proves the server presented a chain that your client trusted at that moment; it does not prove the site is honest or free of vulnerabilities.
Finish with three observations a defender should care about: certificate expiry monitoring, HTTP security headers, DNS change monitoring, or an unexpectedly broad set of subdomains. The project is complete when another learner can rerun your commands, get comparable results, and understand your reasoning without asking you what happened.
# Network Evidence Pack: example.com## Scope and time- Date: 2026-11-01 10:00 UTC- Source: isolated lab VM, 10.10.10.20- Activity: passive DNS, HTTP, and TLS observation only- Out of scope: scanning, authentication, exploitation## DNSCommand: dig example.com A +noall +answerObserved: 203.0.113.10, TTL 300Interpretation: the resolver returned one IPv4 address at this time.## HTTPCommand: curl -sS -D - -o /dev/null https://example.com/Observed: 200 OK, HSTS present, CSP presentGap: no Permissions-Policy header observed.## TLSCommand: openssl s_client ...Observed: TLS 1.3, certificate valid until 2026-04-01Interpretation: the chain was trusted by this client on this date.## Risk commentary1. Certificate expiry needs an owner and alerting.2. Missing Permissions-Policy is a hardening opportunity, not a breach.3. DNS TTL is short; monitor record changes for unexpected redirects.The ideas worth keeping.
- DNS, HTTP, and TLS are separate layers; each can fail or be attacked independently.
- Capture raw headers and certificate details, not just screenshots of the rendered page.
- A certificate proves identity for a name at a moment, not trustworthiness or application security.
- Good evidence is reproducible: commands, time, source, raw output, and explicit limitations.
Make it yours.
Type and test your code right here in the interactive workspace. Run your solution, check the output, and compare with the worked guide when ready.
Exercise 1: Read the headers
A response includes 'strict-transport-security: max-age=31536000', 'content-security-policy: default-src self', and 'x-content-type-options: nosniff'. Explain what each header does and one limitation of relying on them alone.
Explore a worked solution
HSTS tells the browser to use HTTPS for this host for the specified max-age, reducing the risk of protocol downgrade and cookie theft on the first request after the policy is learned. CSP restricts which resources the page may load; default-src 'self' limits scripts, styles, and other resources to the same origin, reducing some XSS impact. X-Content-Type-Options: nosniff stops browsers from guessing a different content type, which can prevent script execution from mislabelled files. Limitation: headers only protect clients that honour them and only for the policies configured. They do not fix server-side injection, authorisation flaws, or a compromised origin.Security headers are browser-enforced hardening. They complement secure code but cannot replace it.
Exercise 2: Separate proof from inference
You observe a valid TLS certificate for a login page. List two things this proves and two things it does not prove. Then state one additional check you would perform before trusting the site with credentials.
Explore a worked solution
Proves: the server presented a certificate chain that your client trusted at that time, and the certificate names matched the host you requested. Does not prove: the site is operated by an honest organisation, the application is free of vulnerabilities, or the server has not been compromised. Additional check: verify the domain through an independent channel, inspect the certificate issuer and issuance time, and confirm the login flow uses HTTPS throughout and submits to the expected origin. For high-value accounts, use a password manager that checks the origin and enable phishing-resistant MFA.Certificates authenticate a name at a moment in time. They do not authenticate business intent or application security.
What stayed with you?
Check the ideas while they’re fresh. Your answers stay in this page and feedback appears as you go.
Keep exploring.
The official references behind this lesson, when you want a second angle or the full details.
Pause. Put the pieces together.
You’ve reached the end of Networking from Packets to Requests. Before moving on, use this task to check what you can do independently.
Capture a DNS lookup, HTTP request, and Nmap scan, then explain every visible field and the security decision it supports.
Try it in your own environment and write down the result. This is a self-check; reading completion does not evaluate your code.
Review this moduleOne lesson closer.
Reading is a start. Trying it yourself makes the connection.