Cybersecurity Engineer Top 100 Interview Questions
100 cybersecurity engineer interview questions with structured answers, comparison tables, flow diagrams, worked calculations and runnable code. Covers security fundamentals, cryptography, network and application security, identity, detection, incident response and vulnerability management, from the basics to design and scenario questions.
Questions 81-100 of 100
Q81.How is endpoint detection and response different from traditional antivirus?
Traditional antivirus mainly blocks known malicious files by matching signatures. Endpoint detection and response records detailed activity on each device, detects suspicious behavior, and gives responders tools to investigate and act remotely.
Traditional antivirus Endpoint detection and response Detects known file signatures, with some heuristics Detects behavior, signatures and analytics Records little beyond detections Records process, file, network and registry activity Largely misses attacks without files Detects attacks without files through behavior Limited investigation Full timeline and process tree per device Responds by quarantining a file Responds by isolating a host, killing processes, collecting files, running scripts Low operating effort Needs analysts to review alerts When each fits:
- Antivirus is still a useful baseline layer that stops known commodity malware cheaply.
- Detection and response tools are expected wherever a security team investigates incidents, because they answer "what happened on this machine?" in minutes.
- Their value depends on people and process: unmonitored alerts protect nothing, so many smaller organizations use a managed detection service.
Q82.What are the main types of malware?
Malware is classified by how it spreads and what it does once installed. Real samples often combine several types, such as a trojan that installs ransomware.
Virus Worm Trojan Ransomware Attaches to legitimate files and runs when they run Spreads on its own across networks via vulnerabilities Poses as legitimate software Encrypts files and demands payment, often after stealing data Corrupts files, spreads through sharing Rapid, wide infection Opens a back door for other tools Outage and extortion Information stealer Rootkit Botnet agent Fileless malware Harvests passwords, cookies and session tokens Hides itself and other malware deep in the system Joins a remotely controlled network of devices Runs in memory using built-in system tools Leads to account takeover Gives long-term, hidden control Used for floods, spam and further attacks Evades file-based scanning Defensive takeaways:
- Behavior-based endpoint detection matters because file signatures miss fileless and newly changed samples.
- Information stealers are now a common first step: stolen session cookies can bypass multi-factor authentication, so short session lifetimes and device binding matter.
- Patch quickly to stop worms, and restrict who can install software to stop trojans.
- Back up data to immutable storage, so ransomware cannot also destroy the way back.
Q83.How do you analyze a suspicious email?
Check who really sent it, where its links and attachments lead, and whether anyone else received or clicked it, without opening anything on your own workstation.
- Read the headers: compare the visible sender with the actual sending domain and the Reply-To address, and trace the receiving servers.
- Check authentication results: SPF says whether the sending server was allowed to send for the domain, DKIM proves the message was signed by the domain, and DMARC says whether those match the visible From domain.
- Inspect links without clicking: look at the real destination behind each link, the domain's age and reputation, and any redirects. Open it only in an isolated sandbox.
- Inspect attachments safely: get the file hash, check reputation, and run it in a sandbox. HTML attachments, archives and documents with macros are red flags.
- Judge the content: urgency, payment changes, credential requests and unusual tone.
- Scope: search the mail system for other recipients, and the proxy logs for anyone who visited the link.
- Respond: remove the message from all mailboxes, block the sender and domains, and reset credentials for anyone who submitted them.
Passing SPF, DKIM and DMARC proves only that the email came from the domain it claims. Attackers register look-alike domains and authenticate them perfectly.
Example
Headers from a reported "updated bank details" email:
From: Accounts Team <billing@harbor-part5.example> Reply-To: payments.harborparts@freemail.example Authentication-Results: spf=pass smtp.mailfrom=harbor-part5.example; dkim=pass header.d=harbor-part5.example; dmarc=pass header.from=harbor-part5.example Received: from mail.harbor-part5.example (203.0.113.25)What the analysis found:
- All three checks pass, but for
harbor-part5.example, a look-alike of the real supplierharbor-parts.example, with the letter "s" replaced by "5". - The look-alike domain was registered six days earlier.
- Replies go to a free webmail address, not to the supplier.
- The message asks for future payments to go to a new bank account, a classic business email compromise.
The finance team confirmed by phone, using the number on file, that the supplier had sent nothing. The domain was blocked and the email removed from the other 3 recipients.
Q84.How would you detect lateral movement inside a network?
Lateral movement uses valid credentials and built-in admin tools, so it is detected by unusual relationships, such as who logs in where, from where and how, rather than by malware signatures.
One account logging in to many hosts in minutes Workstation-to-workstation admin connections Remote service or scheduled task creation on servers Automated spreading with stolen credentials Normal admin work goes from managed admin hosts to servers A common way to run tools on a remote host Admin account use from a host it has never used Access to credential stores or memory of login processes New remote desktop or remote shell sessions at odd hours Credentials used away from their normal source Harvesting more credentials to move further Hands-on-keyboard activity What makes detection possible:
- Baselines of normal authentication paths per account and host group.
- Rich telemetry: authentication logs from servers and the directory, plus process and network data from endpoints.
- Deception: decoy accounts and credentials planted on hosts that should never be used. Any use of them is a high-confidence alert.
Prevention reduces the noise too. If admin accounts can log in only from dedicated admin workstations, any other source stands out immediately.
Example
How a burst of activity was caught one evening:
- At 19:42 a help-desk account authenticated to 37 servers in 6 minutes. Its normal pattern was about 5 logins a day to workstations.
- The source was a marketing laptop, which had never been used for admin logins.
- On 12 of those servers, a new service was created within a minute of the login, running a binary from a temporary folder.
- The laptop showed a phishing attachment opened at 18:55, followed by a memory dump of the login process, which is how the help-desk credentials were taken.
The account was disabled, the laptop and 12 servers were isolated, and the attack stopped before any data left the network.
Q85.Write a script that finds IP addresses with repeated failed logins in an authentication log.
Parse each log line into a timestamp, outcome, user and source address, keep a sliding time window of failures per source, and alert when a source crosses a threshold. Also flag a success that follows several failures, which may mean the attacker got in.
Key points:
- Use a time window, not a total count: 5 failures in a minute is suspicious, 5 in a month is not.
- Count distinct usernames per source to tell password spraying, which tries many accounts, from someone mistyping their own password.
- Alert on success after failures, the most important outcome to catch.
- Parse strictly with a regular expression and skip lines that do not match, rather than guessing at fields.
- Process in time order; logs merged from several servers may arrive out of order.
- Slow attacks that stay under the threshold need a second, longer window, such as failures per source per day.
In production, the same logic usually runs as a rule in the log platform. Writing it once by hand shows exactly what the rule must do.
Example
A sliding-window detector over a small sample log:
import re from collections import defaultdict, deque from datetime import datetime, timedelta LOG = """\ 2026-03-02T10:00:01Z login failure user=admin src=203.0.113.9 2026-03-02T10:00:03Z login failure user=root src=203.0.113.9 2026-03-02T10:00:05Z login failure user=test src=203.0.113.9 2026-03-02T10:00:06Z login failure user=backup src=203.0.113.9 2026-03-02T10:00:09Z login failure user=deploy src=203.0.113.9 2026-03-02T10:00:12Z login failure user=maria src=198.51.100.20 2026-03-02T10:00:15Z login success user=maria src=198.51.100.20 2026-03-02T10:01:00Z login failure user=sam src=192.0.2.44 2026-03-02T10:02:00Z login failure user=lee src=203.0.113.77 2026-03-02T10:02:05Z login failure user=lee src=203.0.113.77 2026-03-02T10:02:09Z login failure user=lee src=203.0.113.77 2026-03-02T10:02:14Z login failure user=lee src=203.0.113.77 2026-03-02T10:02:20Z login success user=lee src=203.0.113.77 2026-03-02T10:03:30Z login failure user=sam src=192.0.2.44 """ LINE = re.compile(r"^(\S+) login (failure|success) user=(\S+) src=(\S+)$") WINDOW = timedelta(minutes=1) THRESHOLD = 5 recent = defaultdict(deque) # source -> failure times inside the window users = defaultdict(set) # source -> usernames it has tried alerts = [] for line in sorted(LOG.splitlines()): match = LINE.match(line) if not match: continue stamp, outcome, user, source = match.groups() when = datetime.fromisoformat(stamp.replace("Z", "+00:00")) window = recent[source] while window and when - window[0] > WINDOW: window.popleft() if outcome == "failure": window.append(when) users[source].add(user) if len(window) == THRESHOLD: alerts.append(f"{stamp} {source}: {THRESHOLD} failures in 1 minute, {len(users[source])} usernames") elif len(window) >= 3: alerts.append(f"{stamp} {source}: success for {user} after {len(window)} recent failures") for alert in alerts: print(alert) # Output: # 2026-03-02T10:00:09Z 203.0.113.9: 5 failures in 1 minute, 5 usernames # 2026-03-02T10:02:20Z 203.0.113.77: success for lee after 4 recent failuresThe single typo from
198.51.100.20and the slow failures from192.0.2.44stay quiet. The second alert is the urgent one: a password was guessed or reused successfully.Q86.What is threat hunting, and how does it differ from alert-driven monitoring?
Threat hunting is a proactive search for attackers who have not triggered any alert, starting from a hypothesis about how they might operate. Alert-driven monitoring waits for rules to fire; hunting assumes some attacks slip past those rules.
Alert-driven monitoring Threat hunting Starts when a rule fires Starts from a hypothesis or new intelligence Asks: is this alert real? Asks: is this technique happening here undetected? Triage and respond Explore data, look for rare and anomalous activity Produces closed or escalated alerts Produces found intrusions, new detections, visibility gaps Needs playbooks and speed Needs deep knowledge of systems and attacker techniques A good hunt cycle:
- Form a hypothesis from intelligence or a known gap, such as "attackers use scheduled tasks for persistence".
- Gather the data needed to test it, over a meaningful period.
- Analyze by grouping and stacking: rare values across the fleet are more interesting than common ones.
- Investigate the outliers until each is explained.
- Turn results into automation: every successful hunt should leave behind a new or improved detection rule.
Hunting also reveals missing logs. Finding that you cannot test a hypothesis is itself a valuable result.
Example
A persistence hunt over 30 days of endpoint data:
- Hypothesis: an attacker has created scheduled tasks that run programs from user-writable folders.
- Data: 412 scheduled tasks were created across 2,300 hosts in the period.
- Stacking: 409 tasks matched software installed on more than 50 hosts each, such as updaters and backup agents. Three tasks appeared on only one host each.
- Investigation: two were a developer's legitimate test jobs. The third ran an unsigned file from a temporary folder every 15 minutes and connected to a domain registered last week.
- Outcome: the host was isolated and investigated, and a new rule now alerts on tasks that run unsigned binaries from temporary folders.
Q87.How do you write and test a new detection rule?
Start from a specific attacker behavior, confirm you have the data to see it, write the rule, then test it against both malicious and normal activity before it reaches analysts.
flowchart LR A["Pick a behavior to detect"] --> B["Confirm the logs exist"] B --> C["Write the rule"] C --> D["Test on simulated attacks"] D --> E["Test on historical normal data"] E --> F{"Precise enough?"} F -->|no| C F -->|yes| G["Deploy with a triage playbook"] G --> H["Track alert outcomes"]- Define the behavior precisely, such as "a user granted admin rights outside an approved change".
- Check data availability: which log records it, with which fields, and how quickly it arrives.
- Write the rule with clear logic and comments explaining why it exists.
- Test true positives by simulating the behavior in a test environment.
- Test against history, running the rule over weeks of past data to estimate alert volume.
- Write unit tests with sample events, so future changes cannot silently break the rule.
- Ship it with a playbook that tells the analyst what to check and what to do.
Store rules in version control with reviews, like code. Detection rules break when log formats change, and tests catch that.
Example
A rule for admin rights granted without an approved change, with tests that document its behavior:
APPROVED_CHANGES = {"CHG-1042", "CHG-1043"} def admin_grant_without_change(event: dict) -> bool: """Alert when admin rights are granted without an approved change record.""" return event.get("action") == "admin_role_granted" and event.get("change_id") not in APPROVED_CHANGES TESTS = [ ("grant with no change record", {"action": "admin_role_granted", "actor": "j.doe"}, True), ("grant under an approved change", {"action": "admin_role_granted", "change_id": "CHG-1042"}, False), ("grant citing an unapproved change", {"action": "admin_role_granted", "change_id": "CHG-9999"}, True), ("unrelated action", {"action": "password_reset", "actor": "j.doe"}, False), ("event missing its action field", {"actor": "j.doe"}, False), ] for name, event, expected in TESTS: result = admin_grant_without_change(event) print(f"{'PASS' if result == expected else 'FAIL'} {name}") # Output: # PASS grant with no change record # PASS grant under an approved change # PASS grant citing an unapproved change # PASS unrelated action # PASS event missing its action fieldThe last test records a deliberate decision: malformed events do not alert here, so a separate health check must alert when a log source starts sending events without the expected fields.
Q88.What are the types of threat intelligence, and who uses each one?
Threat intelligence is usually split into four types by its time horizon and audience: from long-term trends for leaders to machine-readable indicators for blocking tools.
Strategic Operational Tactical Technical Trends, attacker motives, business risk Specific campaigns and their timing Attacker techniques and procedures Indicators such as hashes, domains and addresses Used by executives and risk owners Used by incident responders and hunters Used by detection engineers and the security operations center Used by automated blocking and enrichment Ransomware groups increasingly target our sector A campaign is phishing logistics firms with fake customs notices This group steals browser cookies to bypass multi-factor authentication A list of command servers for one malware family What makes intelligence useful:
- Relevant: it concerns attackers who actually target your sector, regions and technologies.
- Timely: technical indicators lose value within days or weeks as attackers change infrastructure.
- Actionable: each report should lead to a decision, a detection, a hunt or a block.
Feeding thousands of generic indicators into a firewall creates false positives without much protection. Tactical intelligence about techniques usually improves detection more than raw indicator lists do.
Q89.What are the phases of incident response?
Incident response follows a cycle: prepare before anything happens, detect and analyze, contain the damage, remove the cause, recover, and learn. Containment, eradication and recovery often repeat as the investigation finds more.
flowchart LR A["Preparation"] --> B["Detection and analysis"] B --> C["Containment"] C --> D["Eradication"] D --> E["Recovery"] E --> F["Post-incident review"] C -->|new findings| B F -->|improvements| A- Preparation: plans, playbooks, contacts, logging, tools, trained people and practice exercises.
- Detection and analysis: confirm the incident, judge its severity, and work out scope and timeline.
- Containment: stop the spread by isolating hosts, disabling accounts and blocking indicators, while preserving evidence.
- Eradication: remove malware, persistence and attacker access, and fix the vulnerability that let them in.
- Recovery: restore systems from clean sources, monitor closely, and return to normal operations in stages.
- Post-incident review: a blameless review of what happened, what worked, and the improvements to make.
Running it well: name one incident lead, keep a timestamped log of actions, communicate on a regular schedule, and involve legal and communications early when data or customers are affected.
Interview tip: stress that preparation is a phase; most response failures trace back to missing logs, unclear authority or untested backups, all of which are fixed before an incident.
Q90.How would you contain a ransomware outbreak?
Contain ransomware by cutting its paths to spread, protecting backups and identity systems first, and preserving evidence, all while the scope is still being worked out.
- Isolate affected hosts with endpoint tools or network controls. Keep them powered on if possible, since memory may hold keys and evidence.
- Protect the backups: disconnect or lock backup systems and confirm that immutable copies are intact.
- Stop lateral movement: block remote administration protocols between workstations, and segment critical servers.
- Contain identity: reset passwords of compromised accounts, especially admins and service accounts. Invalidate sessions and tokens too, since attackers often hold them.
- Block attacker infrastructure: command servers, file-sharing sites and tools seen in the attack.
- Find the scope and entry point: which accounts and hosts were used, and whether data was stolen before encryption.
- Engage the right people: leadership, legal, insurers, and law enforcement where appropriate. Use an out-of-band channel if email or chat may be compromised.
Containment is a trade-off between speed and disruption. Pulling the internet connection stops the spread quickly but also stops the business, so decide in advance who has the authority to do it.
Example
The first two hours of a real-world style response:
- 00:00 Endpoint alerts show files being renamed with a new extension on 9 file servers.
- 00:10 The response lead isolates those 9 servers and the 3 workstations that connected to them. Backup operators confirm the immutable backup store has not been touched and disable its admin logins.
- 00:25 Logs show a domain admin account used from a workstation at 23:40. Its password is reset twice in a row and all its sessions are revoked.
- 00:45 Remote administration between workstations is blocked by policy across the network, and two attacker domains are blocked at the egress proxy.
- 01:30 Investigation finds that data was uploaded to a file-sharing service before encryption, so legal and privacy teams start their assessment of notification duties.
- 02:00 Spread has stopped. Recovery planning begins from backups taken before the attacker's first login, 11 days earlier.
Q91.What is the order of volatility in digital forensics?
The order of volatility tells investigators to collect the most short-lived evidence first, because it disappears soonest. Memory and network state vanish on reboot, while disks and backups last much longer.
1. CPU registers and cache 2. Memory 3. Temporary file systems and swap space Lasts nanoseconds Lasts until shutdown or overwrite; holds processes, network connections, keys and logged-in users Lasts until reboot or reuse 4. Disk contents 5. Remote logs and monitoring data 6. Archives and backups Lasts until deleted or overwritten Lasts until retention expires Lasts months to years Practical consequences:
- Do not switch off a compromised machine by reflex. Capture memory first when the incident justifies it, because fileless malware and encryption keys may exist only there.
- Record everything you do, since every action on a live system changes it a little.
- Image disks with write protection and hash the images, then analyze copies, never the originals.
- Secure remote logs early; attackers often delete local logs, and retention limits erase central ones over time.
Q92.What is chain of custody, and why does it matter?
Chain of custody is the documented record of who collected each piece of evidence, how, when, where it was stored and everyone who handled it afterwards. It proves the evidence presented later is exactly what was collected and has not been altered.
What a good chain of custody includes:
- Identification: what the item is, such as a laptop serial number or a disk image file name.
- Collection details: who collected it, when, where and with which tool.
- Integrity proof: a cryptographic hash taken at collection and checked again at every transfer.
- Secure storage: sealed, labeled evidence bags for devices, and access-controlled storage for images.
- A transfer log: every hand-off, signed and timestamped, with the reason.
- Working copies: analysis is done on verified copies; the original stays untouched.
Why it matters:
- Evidence with gaps in its record may be rejected in court or in disciplinary hearings.
- Insurers, regulators and law enforcement may rely on the findings.
- It protects investigators from claims that they planted or changed evidence.
Treat any serious incident as if it could end up in court. Adding a proper chain of custody afterwards is impossible.
Q93.An employee's credentials were phished. What do you do?
Assume the attacker has already used them: lock the account down, remove every session and access path the attacker may have created, then check what they did with it.
- Reset the password and require re-enrollment of multi-factor authentication if the method may have been captured.
- Revoke all sessions and tokens, including refresh tokens and app passwords; a password reset alone does not end an existing session.
- Look for persistence: new multi-factor devices, mailbox forwarding rules, app consents, API keys and recovery addresses added by the attacker.
- Review activity since the phishing time: sign-ins, locations, file downloads, emails sent and admin actions.
- Scope the campaign: find other recipients, block the phishing domain, and check proxy logs for other users who submitted credentials.
- Contain onward abuse: if the account sent phishing internally or to customers, warn them and remove those messages.
- Learn: move the user, and ideally everyone, to phishing-resistant authentication.
flowchart TD A["Credential phish reported"] --> B["Reset password and revoke sessions"] B --> C["Remove attacker persistence"] C --> D["Review account activity"] D --> E{"Signs of misuse?"} E -->|no| F["Close with user follow-up"] E -->|yes| G["Escalate to full incident response"] G --> H["Notify affected parties"]Example
What a review of a phished mailbox found:
- The user entered credentials and an authenticator code on a fake sign-in page at 09:12. The attacker signed in from another country at 09:13.
- At 09:20 the attacker added a mailbox rule that moved any email containing "invoice" or "payment" into a hidden folder.
- At 09:31 the attacker registered a new authenticator device on the account.
- Between 10:00 and 10:40, 220 phishing emails went to the user's external contacts.
The response reset the password, revoked sessions, removed the rule and the rogue device, and recalled the messages. Every contact was warned, and the user was moved to a hardware security key.
Q94.How should backups be designed to survive a ransomware attack?
Ransomware groups deliberately find and destroy backups before encrypting anything else. Backups must therefore be isolated from the production environment, impossible to change for a set period, and proven to restore quickly.
- Keep multiple copies: at least three copies of data, on two kinds of storage, with one off-site. Make at least one copy immutable or offline.
- Make them immutable: object locking or write-once storage that even an administrator cannot delete before the retention period ends.
- Separate identity: backup systems use their own accounts and multi-factor authentication, not the main directory, so stolen domain admin credentials cannot reach them.
- Retain long enough: attackers often wait weeks before encrypting, so keep restore points older than the likely dwell time.
- Protect the backup configuration itself, and alert on retention changes and mass deletions.
- Test restores regularly, including a full rebuild of a critical system, and measure how long it takes.
- Back up what recovery needs: identity services, configuration and infrastructure code, not only data.
A backup that has never been restored is a hope, not a plan.
Example
Why retention length decided one recovery:
- The attacker first logged in 21 days before encrypting the network, and planted a back door in the file servers on day 3.
- Nightly backups were kept for 14 days, so every available restore point already contained the back door.
- The team had to restore 14-day-old data and then hunt for and remove the back door on each server, which added a week to the recovery.
- After the incident, immutable retention moved to 35 days for daily copies plus 12 monthly copies, which gives clean restore points that predate typical dwell times.
Q95.How do you measure the effectiveness of a security program?
Measure outcomes and speed, not activity: how quickly threats are found and fixed, how much of the environment is covered, and whether risk is going down over time. A count of blocked attacks or completed trainings says little on its own.
Mean time to detect Mean time to respond Patch time for critical flaws Coverage How long attackers operate before being noticed How quickly incidents are contained The exposure window on known vulnerabilities Share of assets with endpoint protection, logging and scanning Phishing report rate Multi-factor authentication adoption Detection coverage Whether staff report suspicious emails, not just whether they click Share of accounts protected, especially admins Share of simulated attack techniques that raise an alert How to use metrics well:
- Track trends over quarters rather than single values.
- Use medians for time-based measures, since one long incident distorts an average.
- Tie metrics to risk: a quarterly report should show which top risks were reduced, not only which numbers moved.
- Beware incentives: if teams are judged on ticket counts, they will close tickets rather than fix problems.
Example
Calculating detection and response times for one quarter's five confirmed incidents:
- Hours from attacker activity to detection: 2, 5, 9, 30 and 300. The median is 9 hours; the mean is 69.2 hours because of one slow detection.
- Hours from detection to containment: 1, 1.5, 2, 4 and 6. The median is 2 hours.
- The 300-hour case was a compromised cloud account with no audit log alerts, so the next quarter's priority is cloud audit coverage, not faster containment.
The median shows typical performance, while the outlier shows exactly where the program has a gap.
Q96.How do you prevent and detect misconfigured cloud storage that exposes data?
Prevent public exposure with account-wide guardrails and secure defaults, then detect the remaining mistakes quickly with continuous configuration checks and access monitoring.
Prevention:
- Block public access at the account or organization level, so a single bucket policy cannot make data public by accident.
- Deploy storage through infrastructure code with policy checks in the pipeline that reject public or unencrypted configurations.
- Use least-privilege access policies tied to roles, and avoid long-lived share links and wildcard principals.
- Encrypt by default and turn on versioning and access logging for sensitive buckets.
- Tag data with its classification, so stricter rules apply to sensitive stores automatically.
Detection:
- Posture management scans that flag public, unencrypted or unlogged storage within minutes.
- Alerts on policy changes, especially a change to public access or cross-account sharing.
- Access log analysis for unusual readers, large downloads or anonymous requests.
- External checks that look for your storage from the internet, as an attacker would.
When exposure is found, remove the public access first, then use the access logs to see whether anyone read the data, which decides whether it is a breach.
Q97.How do you harden a server before it goes into production?
Hardening reduces a server to what it needs, secures what remains, and makes sure you will see what happens on it. Build the hardened state into an image and configuration code, so every server starts secure rather than being fixed by hand.
- Start minimal: a minimal operating system install, with unused packages, services and features removed.
- Patch fully before exposure, and enroll the server in automated patching.
- Secure access: key-based remote login only, no direct root or administrator login, multi-factor authentication through a bastion or access proxy, and no shared accounts.
- Remove defaults: default accounts, passwords, sample applications and verbose banners.
- Restrict the network: a host firewall that allows only required ports and sources.
- Run services with least privilege, each under its own account with only the file access it needs.
- Apply a configuration baseline from a recognized hardening benchmark, and scan against it.
- Enable logging and monitoring: send logs to the central platform, install the endpoint detection agent and sync time so timelines line up.
- Encrypt disks and protect secrets with a secrets manager, never in local files.
- Verify before go-live with a vulnerability scan and a configuration compliance check.
Immutable servers go further: they are never changed in place but replaced with a new hardened image. Configuration drift then has nowhere to accumulate.
Q98.Design the security architecture for a new customer-facing web application.
Design it as layers around the data: protected entry points, strong identity, an application that enforces authorization on every request, private and encrypted data stores, and monitoring across all of them.
flowchart LR A["Users"] --> B["Edge: content delivery, web firewall, denial-of-service protection"] B --> C["Load balancer with TLS"] C --> D["Web and API tier in private subnets"] D --> E["Database, encrypted and private"] D --> F["Secrets manager"] G["Identity provider with multi-factor authentication"] --> D D --> H["Central logging and alerting"] I["Pipeline with code, dependency and secret scans"] --> DKey decisions:
- Identity: a standard sign-in protocol with an identity provider, multi-factor authentication, secure session cookies and protected account recovery.
- Authorization: checks on every request against the object being accessed, enforced in a shared component.
- Input and output: schema validation on input, parameterized queries and context-aware output encoding.
- Data protection: TLS everywhere, encryption at rest with managed keys, and minimal collection of personal data.
- Network: only the edge is public; application and data tiers live on private networks with strict rules.
- Secrets: fetched at runtime from a secrets manager by workload identity, never stored in code.
- Operations: central logs, alerts on authentication and data access anomalies, and a tested incident plan.
Trade-offs: stricter controls add latency and development effort, so put the strongest controls around the most sensitive data and actions.
Example
How the design handles a password-reuse attack against the new application:
- An attacker replays 50,000 leaked username and password pairs from many addresses.
- The web firewall's bot rules and per-account rate limits slow the attack, and the login failure alert fires within 3 minutes.
- 41 pairs are correct, but multi-factor authentication stops all 41 logins. Each account owner is told about the attempt and asked to change their password.
- Because the attack never reaches a valid session, the authorization layer, database encryption and data access alerts are never tested. They remain in place for the attack that eventually gets further.
Q99.How should you explain a security project you personally worked on?
Tell it as a short story with a clear structure: the risk, what you did and why, what changed, and what you learned. Make your own contribution clear, and give numbers wherever you can.
- Context: the system, the business, and the risk or incident that started the project.
- Your role: what you personally owned, as distinct from the team's work.
- The problem: what made it hard, such as legacy systems, conflicting priorities or limited budget.
- Your decisions: the options you considered, the trade-offs, and why you chose your approach.
- The result: measurable outcomes, such as "phishing-related account takeovers fell from six a quarter to zero" or "critical patch time dropped from 30 days to 5".
- Lessons: what you would do differently, and what the team does differently now.
What the interviewer is listening for:
- Whether you understand why the work mattered to the business, not just which tools you used.
- Whether you can weigh security against usability, cost and delivery.
- Honesty about mistakes and limits, which signals maturity.
- Whether you can explain technical points simply.
Prepare two or three stories in advance, such as an incident, a hardening or detection project, and a time you influenced other teams. Practise telling each in about three minutes.
Q100.How do you handle a disagreement when a business owner wants to accept a risk you consider serious?
Make sure the owner truly understands the risk in business terms, offer practical options that reduce it, and if they still accept it, document the decision properly rather than blocking or quietly giving up.
- Understand their goal: what deadline, revenue or customer need is driving the decision.
- Explain the risk in their language: likely scenarios, impact on customers and revenue, and regulatory exposure, rather than technical severity scores.
- Offer options, not a veto: a compensating control, a phased fix, a smaller launch, or extra monitoring until the fix ships.
- Agree on facts: where you disagree, test assumptions together, such as whether the system really is unreachable from the internet.
- Escalate through governance if the risk exceeds what this owner may accept, rather than going around them.
- Document the acceptance: the named owner, the reasoning, conditions and an expiry date for review.
- Follow up: check that the agreed controls are delivered, and revisit when the date arrives.
What the interviewer is listening for:
- That you see security as enabling the business, and the risk decision as belonging to the business owner.
- Influence without authority, and calm communication under pressure.
- That you hold firm on facts and process, not on personal preference.