OPNsenseXXXII · TLS Inspection and Content FilteringContent filtering policy
Content filtering policy and ethics — what the operator is allowed to do
What you'll learn
- Identify the legal frameworks that govern employer monitoring of employee traffic
- Distinguish between security monitoring, productivity monitoring, and surveillance
- Apply the exemption framework for protected traffic classes
- Recognise the retention limits and access controls that apply to filtered content logs
- Use the human review process required when filtered content becomes evidence
Prerequisites
- TLS inspection concepts and risks — what MITM at the firewall means
- TLS intercept deployment — putting the proxy between the client and the Internet
- Web filtering plugins — URL categories, content types, and application control
- Threat intelligence and blocklists — feeding the firewall from external sources
Verified against OPNsense 25.x · FreeBSD 14.x · PF (FreeBSD packet filter) FreeBSD 14.x · Unbound 1.20+ · Kea DHCP OPNsense 25.x plugin · WireGuard in-kernel + OPNsense plugin · strongSwan (IPsec plugin) OPNsense 25.x plugin · OpenVPN 2.6.x · Suricata 7.x · 2026-08-14
TLS interception gives the firewall the same view of employee traffic that the employee has. The technical capability exists. The question of whether the operator should use it — and to what extent — is a policy question, not a technical one. This lesson covers the legal frameworks that govern employer monitoring, the distinction between security monitoring and surveillance, the exemption categories that must exist before interception is enabled, the retention limits on filtered content logs, and the human review required when those logs become evidence.
Legal frameworks
The legal landscape for employer monitoring varies by jurisdiction, but the principles are consistent across most Western legal systems:
- Notice: the employee must be told that monitoring is occurring. The notice should be specific — what is monitored, what is logged, what is reviewed, who has access.
- Consent: in some jurisdictions (e.g., EU under GDPR), explicit consent is required for monitoring that goes beyond legitimate business need.
- Proportionality: monitoring must be proportionate to the stated purpose. Reading every email to detect malware is proportional. Reading every email to detect “low productivity” is not.
- Purpose limitation: data collected for one purpose (security) cannot be used for another (performance review) without a separate justification.
- Retention limits: data cannot be retained indefinitely. The retention period must be defined and enforced.
Security monitoring versus surveillance
The distinction is sharper than it sounds:
-
Security monitoring: detecting malware, preventing data loss, identifying compromised hosts. The operator looks at traffic patterns, file hashes, destination reputation. The user identity is incidental — the goal is “this host is compromised”, not “this user is browsing”.
-
Productivity monitoring: tracking which websites employees visit, how long they spend on each, what applications they use. The user identity is central. The goal is “this user is unproductive”, not “this host is at risk”.
-
Surveillance: reading the content of communications, tracking personal browsing, building dossiers on individuals. The goal is “this user is doing something we want to know about”.
The technical capability is the same — TLS interception sees everything. The legal and ethical framework is different. Security monitoring is broadly lawful with notice. Productivity monitoring is restricted in many jurisdictions. Surveillance is restricted almost everywhere.
The discipline: decide which mode the deployment is, document it, configure it accordingly. The firewall that logs every URL visited by every user with full request and response bodies is configured for surveillance, regardless of what the documentation says. The configuration matches the intent.
Exemption categories
Before interception is enabled, the operator must define exemptions. Categories that should be exempted in most jurisdictions:
| Category | Reason | Mechanism |
|---|---|---|
| Banking and finance | Regulated, sensitive | Domain/IP exemption in proxy |
| Healthcare portals | HIPAA, GDPR special category | Domain exemption |
| Personal email | Often protected under labour law | Domain exemption |
| Union communications | Protected in many jurisdictions | Domain exemption |
| Attorney-client | Privileged in most jurisdictions | Domain exemption |
| Religious sites | Sometimes protected | Per-jurisdiction |
| Whistleblower channels | Often legally protected | Per-jurisdiction |
| Personal devices (BYOD) | Consent unclear | Network segmentation |
The exemption mechanism is the proxy bypass list (covered in lesson 189) plus, where appropriate, separate network segments for devices that should not be intercepted (guest network, BYOD network).
Retention and access
The filtered content log is data. The discipline around it:
- Retention period: defined in the DPIA. Common periods: 30 days for URL logs, 90 days for security incidents, indefinite for confirmed malware events (subject to legal hold rules).
- Access controls: who can read the logs. The principle of least privilege — security team only, no broader access.
- Audit trail: who accessed what, when. Logs of log access. The meta-log.
- Deletion process: automatic or manual, on schedule, verified.
$ ls -la /var/log/squid/ 2>/dev/null | head -10; echo '---'; find /var/log -name '*.log' -mtime +30 2>/dev/null | head -10--- (illustrative)
-rw-r--r-- 1 root wheel 5242880 Aug 14 16:30 access.log
-rw-r--r-- 1 root wheel 524288 Aug 14 16:30 cache.log
-rw-r--r-- 1 root wheel 102400 Aug 14 16:30 store.log
/var/log/squid/access.log.30.gz
/var/log/squid/access.log.31.gz
/var/log/squid/access.log.32.gz
Illustrative output
Human review
When filtered content becomes evidence — in a disciplinary hearing, in a legal proceeding, in a regulatory investigation — the operator’s logs are subject to challenge. The discipline:
- Chain of custody: who collected the evidence, who had access, what was changed.
- Context: a URL visited does not mean what the URL suggests. The operator must present context, not just data points.
- Human review: a human must review the evidence before it is used. The firewall’s automated alerts are signals; they are not evidence.
- Right to challenge: the affected employee has the right to challenge the evidence. The operator must be able to produce the original log, the rule that triggered, and the chain of custody.
The operator who has not built the human review process into the workflow will be forced to build it after the first disciplinary case that the employee challenges. The discipline: design the review process before the first incident.
Summary
- The legal framework governs what the operator may do. Notice, consent, proportionality, purpose limitation, retention — all required.
- Security monitoring, productivity monitoring, and surveillance are different. The configuration matches the declared intent.
- Exemptions must be defined before interception is enabled. Banking, healthcare, personal email, and protected communications are typical exemptions.
- Retention, access controls, and audit trails are mandatory. The DPIA is the document that defines them.
- Filtered content becomes evidence through human review, with chain of custody. The firewall log is a signal; it is not evidence until reviewed.
Knowledge check · 3 questions
Q1. A manager asks the security team for a list of every URL an employee visited last week, to use in a performance review. What is the correct response?
Q2. A TLS interception deployment configured to log every URL visited by every user with full request bodies is a security monitoring deployment if the documentation says it is for security.
Q3. Which of the following are required components of a TLS interception deployment’s policy framework? Select all that apply.
Passing score: 75%. Answers are checked in this browser.