Intermediate Level
This section covers intermediate networking and security concepts commonly asked in interviews for experienced professionals.
What is the CIA triad?
The three pillars every security decision balances:
- Confidentiality — only authorized parties can read data (encryption, access control)
- Integrity — data can't be undetectably altered (hashes, signatures, checksums)
- Availability — systems are reachable when needed (redundancy, DDoS protection, HA design)
How it's used in interviews: it's the lens for justifying security choices — "TLS gives confidentiality and integrity; a WAF protects availability." The follow-up to expect: "what are the trade-offs?" — e.g., heavy encryption can cost availability performance, and every control balances the three against cost/complexity. Related extensions: authentication/authorization/non-repudiation as operational companions.
What is the OSI model, and why does a DevOps engineer care?
OSI defines seven layers — a vocabulary for locating where a problem or tool lives:
- Physical — cables, signals
- Data Link — MAC addresses, switches, ARP
- Network — IP, routers (L3 firewall)
- Transport — TCP/UDP, ports (L4 load balancer, security groups)
- Session — connection management
- Presentation — encryption, encoding (TLS lives here practically)
- Application — HTTP, DNS, SSH (L7 firewall, WAF)
Why it matters day-to-day: it's diagnostic shorthand — "it's an L4 problem, not L7" (connection refused vs 500 error), and it explains the tool ecosystem (L4 vs L7 load balancers, stateful L4 firewalls vs WAFs). The practical alternative to name: TCP/IP's 4-layer model, which most engineers actually use.
What is the difference between TCP and UDP?
- TCP — connection-oriented (3-way handshake: SYN → SYN-ACK → ACK), ordered, reliable delivery with retransmission and flow control. Cost: latency and state. Used by HTTP, SSH, databases
- UDP — connectionless fire-and-forget datagrams. Faster, no delivery guarantee. Used by DNS (one query, one reply — and retransmission is trivial), video/streaming, gaming, metrics (StatsD)
The DevOps follow-ups to expect: "why is DNS over UDP — and when does DNS use TCP?" (responses over the packet size limit, zone transfers), "where would each protocol appear in your stack?" (TCP for APIs; UDP for metrics/log shipping that tolerates loss), and "what is a TCP handshake timeout in practice?" — connection-pool exhaustion is a classic incident.
What is the difference between symmetric and asymmetric encryption?
- Symmetric (AES-256) — one shared key encrypts and decrypts. Very fast; the problem is key distribution: how do both parties get the key without an eavesdropper grabbing it?
- Asymmetric (RSA, ECC) — public key encrypts, only the private key decrypts (and vice versa for signatures). Solves distribution — but 100–1000× slower than symmetric
How real systems combine them — the answer interviewers want: asymmetric to exchange/bootstrap, symmetric for the session. TLS: certificate (asymmetric) authenticates and establishes keys → session traffic uses AES (symmetric). Same pattern in SSH, mTLS, and envelope encryption (data encrypted with a data key, data key encrypted with a KMS master key).
What is TLS termination, and where should it happen?
TLS termination = decrypting HTTPS at a chosen point in your infrastructure:
- At the edge (load balancer/CDN) — simplest; internal traffic is plaintext unless re-encrypted. Common default
- At the ingress pod — TLS ends inside the cluster; traffic to backends still needs protection
- End-to-end / at the service — highest security (mTLS between services), most operational work
The trade-off to articulate: termination point determines where plaintext exists — behind an L7 balancer you need health checks and header forwarding (
X-Forwarded-Proto), and zero-trust stacks re-encrypt internally with mTLS. Follow-ups: "what is TLS passthrough?" (L4 balancer forwards encrypted bytes — the balancer can't see headers), and "where do certificates live?" (ACM, cert-manager, mesh).How does HTTPS/TLS handle authentication — what exactly does a certificate prove?
A TLS handshake proves the server controls the private key matching a certificate that a trusted CA issued for that domain. What it does not prove: that the server is honest, the site is legitimate, or the client is who it says it is (standard TLS authenticates the server only).
The follow-ups to expect:
- "what if a CA is tricked into issuing a certificate for my domain?" — mitigations: Certificate Transparency logs (public record of issued certs), Certificate Authority Authorization (CAA) DNS records restricting which CAs may issue for you
- "how does the client authenticate?" — client certificates (mTLS) or application-level auth (tokens) — standard TLS has no client identity
- "what is certificate pinning?" — hardcoding expected certs/keys for known peers; strong but brittle (rotation pain)
What is multi-factor authentication (MFA), and why does phishing-resistant MFA matter?
MFA requires multiple independent factors: something you know (password), have (device/key), or are (biometric).
The nuance that elevates the answer: not all MFA resists the same attacks —
- SMS OTP — vulnerable to SIM-swapping and real-time phishing relays; better than nothing
- TOTP apps — resistant to SIM-swap, still phishable by real-time relay
- FIDO2/WebAuthn hardware keys or passkeys — cryptographically bound to the origin domain; phishing-resistant
DevOps application: MFA on everything human-facing (cloud consoles, CI, VPN) — especially root/break-glass accounts — plus hardware keys for administrators. The zero-trust tie-in: MFA is one pillar; identity-aware proxies and short-lived session tokens complete it.
What is Single Sign-On (SSO), and how do OIDC and SAML differ?
SSO lets users authenticate once against an identity provider (IdP) and access many applications — centralizing credentials, MFA, and offboarding (disable one account, revoke everything).
- SAML 2.0 — XML-based; the enterprise classic (Okta, Azure AD → legacy/internal apps); browser redirects, assertion-based
- OIDC (OpenID Connect) — JSON/OAuth 2.0-based; the modern default for web/mobile apps and APIs; ID tokens are JWTs
- OAuth 2.0 — the authorization framework both build on (delegated access: "let this app act for me") — OIDC adds the identity layer
DevOps applications: federate everything (cloud consoles, Grafana, CI) into the IdP; workload federation is the machine-side equivalent (CI assumes cloud roles via OIDC — no static keys). Follow-ups: "what's the difference between authentication and authorization?" (who you are vs what you may do) and "what happens when the IdP is down?" — design for cached sessions and break-glass local access.
What is a WAF (Web Application Firewall), and what does it protect against?
A WAF inspects HTTP(S) traffic at Layer 7 and blocks application-layer attacks the network firewalls can't see:
- Protects against — OWASP classics: SQL injection, XSS, path traversal, known-exploit signatures (Log4j), bots/credential stuffing
- Modes — detection (log only) → prevention (block); managed rule sets (AWS Managed Rules, OWASP CRS) plus custom rules (rate limits per IP, geo/size constraints)
- Placement — in front of the app: CloudFront/Cloudflare/ALB + WAF, or NGINX ModSecurity self-hosted
The honest limitation to state: WAFs reduce exploit surface but don't fix vulnerable code — they're a compensating control layered with secure development (SAST/DAST), not a substitute. Follow-up: "WAF vs IDS/IPS?" — WAF is L7 application-focused; IDS/IPS operate at network layers on broader signatures.
What is the principle of least privilege, and how do you implement it in practice?
Every identity (human, service, pipeline) gets exactly the permissions needed for its function — nothing more, permanently.
Implementation in DevOps systems:
- IAM — scoped policies per role; no wildcard actions/resources in production; access analyzer to find over-permissions
- Short-lived credentials — OIDC federation for CI, dynamic DB credentials, expiring tokens — standing access shrinks to break-glass
- Kubernetes — RBAC Roles (not ClusterRoles) per namespace, no automounted tokens where unneeded, admission policies enforcing limits
- Reviews — periodic access audits, anomaly detection on permission usage (GuardDuty/Access Analyzer)
The interview framing: least privilege is enforced by defaults and automation — new identities start minimal and gain scope through review — not by periodic manual cleanups. Follow-up: "how do you balance it with operability?" — JIT elevation and audit trails replace standing broad access.
What is network segmentation, and how do you achieve it in the cloud?
Segmentation divides the network so a compromise in one zone can't freely reach others:
- VPC/subnet design — public (LB) / private-app / private-data tiers; databases unreachable from the internet and from the frontend tier
- Filtering at boundaries — security groups (stateful, per-instance) + NACLs (stateless, per-subnet) + route tables controlling paths
- East-west segmentation — internal traffic segmented too: Kubernetes NetworkPolicies, micro-segmentation, service-mesh authorization
- Account-level isolation — separate accounts/OUs (landing zones) with Service Control Policies as the hardest boundary
The pattern to name: default deny, explicit allow — and the classic test to mention: from a compromised frontend host, try to reach the database directly; if that path exists outside the app, segmentation failed.
Security Groups vs Network ACLs — what's the difference?
The stateful/stateless distinction is the interview answer's core: with a security group, allowing outbound 443 automatically permits the response back; with a NACL you must also allow the ephemeral return ports (1024–65535) inbound. Practical guidance: security groups carry most of the policy; NACLs add explicit denies and org-level guardrails.
What is a DDoS attack, and what does a layered mitigation look like?
DDoS overwhelms a target with traffic from many sources — volumetric (bandwidth), protocol (SYN floods), or application-layer (HTTP floods). Mitigation is layered because each layer fails differently:
- Absorb — provider-scale scrubbing (AWS Shield, Cloudflare/GCP Armor): volumetric attacks must die on someone else's network
- Filter at the edge — WAF rules, rate limiting per IP/session/API key, bot management
- Protect the origin — origin reachable only from the CDN/WAF (security groups referencing edge IPs — attackers can't bypass the edge)
- Application resilience — caching (uncached paths are the real risk), autoscaling with cost caps, graceful degradation
- Practice the economics — attack-induced autoscaling bills and Shield Advanced cost protection are part of the plan, not an afterthought
The trade-off to name: aggressive rate limiting blocks real users behind shared IPs (NAT, mobile networks) — tune with allowlisting and progressive backoff.
What is DNS hijacking/poisoning, and what defends against it?
DNS attacks redirect name resolution to attacker-controlled servers:
- Poisoning/cache poisoning — forged responses injected into a resolver's cache (the classic Kaminsky attack class) — users type the right domain and land on the wrong server
- Hijacking — changing records at the registrar/nameserver level (compromised registrar accounts) — affects everyone, not just one resolver
- Defenses — DNSSEC (cryptographic signatures on records — resolvers verify authenticity), DNS-over-HTTPS/TLS for client→resolver paths, registrar security (MFA, registrar lock), monitoring for unauthorized record changes, and CAA records limiting which CAs can issue certs for your domains
The DevOps tie-in: DNSSEC at scale needs key management (KSK/ZSK rollover), and your own monitoring should alert on unexpected record changes — DNS is infrastructure, and it's in Git/pipelines like everything else.
What is a reverse proxy vs forward proxy — and what security does each provide?
- Forward proxy — sits in front of clients, controlling and logging their outbound traffic (corporate egress filtering, content policy, anonymity)
- Reverse proxy — sits in front of servers: TLS termination, hiding backend topology, request filtering, caching, load distribution
Security value of the reverse proxy: backends never face the internet directly; the proxy can enforce WAF rules, rate limits, and header hygiene (HSTS, security headers) centrally. Follow-ups: "why does X-Forwarded-For matter?" (real client IP through the proxy — and trusting it blindly enables spoofing), and "reverse proxy vs API gateway?" (gateway adds authN/authZ, quotas, and API semantics).
What is security segmentation for containers and Kubernetes?
Containers share a kernel, so container networking security is layered deliberately:
- NetworkPolicies — default-deny east-west traffic; only declared pod-to-pod paths allowed (requires a supporting CNI — verify enforcement, don't assume)
- Namespaces + RBAC — blast-radius control at the API level
- mTLS between services — mesh-managed identity so a compromised pod can't impersonate others
- Runtime isolation for hostile workloads — gVisor/Kata micro-VMs where tenant code is untrusted; seccomp/AppArmor profiles; non-root, read-only filesystems
- Registry-to-pod chain — signed images only (admission policy), scanned before deploy
The statement interviewers want: in Kubernetes, "the network is flat by default" — zero-trust pod networking is something you build (default-deny policies + mTLS), not something you get.
Contribute & Stay Updated
Want to contribute? We welcome contributions! If you have insights, new tools, or improvements, feel free to submit a pull request.
How to Contribute?
- Read the CONTRIBUTING.md guide.
- Fix errors, add missing topics, or suggest improvements.
- Submit a pull request with your updates.
Community & Support
GitHub: @NotHarshhaa Blog: ProDevOpsGuy Telegram Community: Join Here