Nightmares of a Pentester
Chris Nickerson
BruCON 0x07 · Day 1
Overview
In "Nightmares of a Pentester," Chris Nickerson, a veteran in the information security industry and owner of Lares, delivers a provocative and insightful talk that challenges conventional approaches to cybersecurity. Drawing from over 15 years of experience in red team testing and real-world attacks, Nickerson dissects the persistent failures in organizational defense despite increasing security investments. His core thesis revolves around the critical distinction between "built-in" and "bolt-on" security, advocating for fundamental architectural changes and proactive, aggressive defensive strategies rather than relying on an endless cycle of purchasing new, often ineffective, security products.

Key moments
- 4:15 Chris Nickerson's personal inspiration from BruCON
- 17:00 Core philosophy: Make pentesters cry and interact fully
- 20:40 Implement port scanning bans to deter attackers
- 31:00 Empower users with "get hacked days" to build defenses
- 35:30 Hardcore defense: network segmentation with no default route
- 52:30 Advanced detection using WMI/Powershell for persistence mechanisms
- 63:20 Staying motivated during multi-year adversarial engagements
- 67:30 The culture of effective defensive security teams
Nightmares of a Pentester
Speakers: Chris Nickerson, Owner, Lares
Conference: BruCON
YouTube: https://www.youtube.com/watch?v=2ufBtLw6QgY
Overview
In "Nightmares of a Pentester," Chris Nickerson, a veteran in the information security industry and owner of Lares, delivers a provocative and insightful talk that challenges conventional approaches to cybersecurity. Drawing from over 15 years of experience in red team testing and real-world attacks, Nickerson dissects the persistent failures in organizational defense despite increasing security investments. His core thesis revolves around the critical distinction between "built-in" and "bolt-on" security, advocating for fundamental architectural changes and proactive, aggressive defensive strategies rather than relying on an endless cycle of purchasing new, often ineffective, security products.
The talk serves as a stark wake-up call, urging security professionals to move beyond reactive measures and embrace a mindset where they actively seek to make pentesters "cry" by implementing robust, often basic, defenses that force adversaries to work exceptionally hard. Nickerson emphasizes the power of open-source tools, intelligent correlation, and empowering internal teams to become the first line of defense. This article will delve into the specific technical and cultural shifts Nickerson proposes, highlighting actionable strategies for building genuinely resilient security programs that can withstand sophisticated and persistent attacks.
Background
▶ Watch: Chris Nickerson's personal inspiration from BruCON (4:15)
Chris Nickerson opens his talk by reflecting on the disheartening statistics presented in reports like the Verizon Data Breach Investigations Report (DBIR). Despite annual increases in security spending, organizations continue to suffer more losses, with attack motives consistently centered around financial gain. A critical observation from the DBIR cited by Nickerson is that over 70% of attacks involve a secondary victim, meaning organizations are often compromised not as primary targets, but as stepping stones to reach their partners or more valuable assets. This highlights a fundamental flaw in the "nobody's going to come after us" mindset, as any entity can become a crucial link in a larger attack chain.
Furthermore, Nickerson points out that the average exploit used in successful attacks is often more than a year old, indicating a widespread failure in basic patching and vulnerability management. Compounding this issue, less than 25% of attacks from 2004 to 2014 were even identified as having occurred, suggesting a severe lack of visibility rather than an actual improvement in defensive capabilities. This leads Nickerson to conclude that while we may think we're getting worse, it's often just that we now have slightly better tools to detect our long-standing failures.
The prevailing problem, as Nickerson identifies it, is a reliance on a "grass is greener" security paradigm. Organizations continuously buy new products, hoping the latest "NG 2000 version with added AP defense" will solve their problems, only to find attackers bypassing them. This marketing-driven, "bolt-on" approach to security creates a false sense of protection. Nickerson argues that this cycle is not the fault of the buyers, who are often non-technical decision-makers trying their best, but rather a systemic issue within the industry. His motivation for the talk is to share the practical pain points of pentesters, revealing what truly makes their job difficult, so defenders can implement strategies that genuinely hurt adversaries rather than just buying more "widgets." He stresses that good security programs are built in, not bolt-on, meaning security must be an inherent part of architecture and processes, not an afterthought.
Key Findings
▶ Watch: Implement port scanning bans to deter attackers (20:40)
Chris Nickerson's talk distills several critical findings that challenge conventional security wisdom and offer a pragmatic path forward:
- The Ineffectiveness of "Bolt-on" Security: Nickerson powerfully argues that simply purchasing more security products (the "grass is greener" game) without integrating security into the core architecture and processes is a losing battle. This "bolt-on" approach leads to continuous spending without proportional improvement in defense.
- The Power of Fundamentals: A significant portion of successful attacks leverage exploits that are more than a year old. By focusing on basic, well-executed defensive measures – often achievable with open-source tools – organizations can thwart 90-95% of "point-and-click" pentesters and less sophisticated attackers.
- Visibility, Not Just Prevention: Many organizations lack the ability to even detect an attack, with historical data showing that less than 25% of attacks are identified. True improvement in security comes from enhanced visibility and the ability to respond, not just from attempting to block everything upfront.
- Users Are Not the Problem (Your Program Is): Nickerson firmly rejects the notion that "users are the weakest link" or "always click on stuff." Instead, he asserts that it is the security team's responsibility to build a program that protects against user actions. This involves empowering users as a "first line of defense" through aggressive training and robust technical controls.
- Aggressive Pentesting as a Catalyst for Improvement: Rather than "whitelisted" or "gentle" penetration tests, Nickerson advocates for full-scope, aggressive red teaming designed to make pentesters "cry." The goal is to identify true weaknesses and force internal teams to innovate their defenses, fostering a culture of resilience and continuous improvement.
- WMI and PowerShell as Critical Attack/Defense Vectors: For advanced persistent threats (APTs) and sophisticated attackers, Windows Management Instrumentation (WMI) and PowerShell have become primary tools for persistence and command-and-control. Nickerson highlights specific WMI events that defenders can monitor to detect these advanced techniques.
- Open Source for Strategic Advantage: Many sophisticated defensive capabilities, from threat intelligence correlation to host-based monitoring, can be achieved with powerful open-source tools (e.g., ELK stack, Bro, OSSEC, RTIR), often outperforming expensive commercial solutions for specific use cases.
- Incident Response Beyond Re-imaging: A common, yet ineffective, incident response (IR) practice is simply re-imaging compromised machines. Nickerson stresses the importance of a comprehensive IR process that includes harvesting credentials, analyzing collateral damage, and using ticketing systems to feed lessons learned back into the security program.
- The Culture of Defense: The most effective blue teams are those that welcome the fight, get "fired up" by offensive challenges, and use red team engagements to ignite their passion for defense, rather than fearing exposure.
Technical Deep Dive
▶ Watch: Hardcore defense: network segmentation with no default route (35:30)
Nickerson's talk offers a comprehensive blueprint for building resilient defenses, breaking down strategies into external, internal, workstation, and server-specific controls, culminating in advanced correlation and incident response.
External Defenses
- Don't Talk to Strangers:
- Block Emerging Threats Lists: Nickerson advocates for automatically blocking all traffic from well-known emerging threats lists. He claims this simple action can cut down 90% of bad traffic. "It's internet known bad guys. If you had known neighborhood criminals, would you just let them come kick it at your house?" he quips.
- Honeypots: Deploying honeypots, especially for common targets like Drupal and WordPress, can divert malicious traffic and provide valuable intelligence for tuning defensive rules, assuming adequate staffing for analysis.
- Port Scanning Bans: Implementing active port scanning bans that automatically block or alert on any port scan attempts. Nickerson states this alone will stop 90-95% of "point-and-click" pentesters. Legitimate traffic rarely needs to port scan, and internal systems that do (e.g., some mainframe message queues) can be whitelisted.
- Firewall Efficacy Testing: Actively test firewalls to ensure they actually block traffic as intended. He references the TCP Midstream renegotiation vulnerability from two years prior, noting that only one out of ten top firewalls could effectively stop it, despite being an RFC-defined behavior.
- Big Data & Threat Intelligence: Instead of relying on expensive vendors "full of shit," organizations can build their own threat intelligence platforms using open-source tools. This involves leveraging OpenIOC and TAXII feeds, and standing up an ELK stack (Elasticsearch, Logstash, Kibana) to dump traffic logs and correlate threat indicators.
- OSINT & Surface Landscape: Tools like SpiderFoot are highly recommended for automated reconnaissance, helping organizations understand what information is being leaked about them and what their external attack surface looks like.
Phishing Defenses
Nickerson asserts that blaming users for clicking links is a cop-out; it's the security program's job to protect against it.
- Email Hardening:
- Disable SPPP verify (a simple one-click or two-command fix for Microsoft/Linux).
- Use SPF records to prevent email spoofing.
- Ensure mail filtering solutions encrypt and decrypt all protocol types for thorough inspection.
- Site Classification & DNS Analysis:
- Monitor the age of certificates and domain registration for new websites. Nickerson suggests blocking access to sites that haven't "marinated on the internet long enough" to be properly classified, as most legitimate new sites are not the first place an organization's users will visit.
- Utilize DNS analysis (e.g., OpenDNS services) to check domain validity, certificate status, and age. Attackers are often too lazy to properly age domains, set up valid certificates, or configure SPF records correctly.
- Sender Identity Verification: Verify sender identity against MX records to catch improperly configured phishing domains.
- Proactive Blocking: Block known bad lists like Spamhaus and Spamcop at the mailer level to significantly reduce noise and malicious inbound emails.
- User Empowerment through Training: Instead of just "don't click," conduct "get hacked days" where users are encouraged to intentionally click on malicious content in a controlled, isolated environment. The security team then uses these scenarios to build better proactive defenses, shifting users from a liability to the "first line of defense."
Internal Defenses
- Granular Monitoring: Shift focus from just external IDS/IPS to internal network monitoring. Tune signatures and alerts for internal traffic, as an internal alert signifies a much higher probability of a real incident. "If you're ignoring your alerts, then you're just alerting wrong."
- Segmentation: Implement robust network segmentation.
- Internal Port Scan Blocking: Actively block and alert on internal port scans. Few legitimate internal systems should be widely port scanning.
- NetFlow & Top Talkers: Monitor NetFlow and analyze "top talkers" to detect large data exfiltration (e.g., gigabytes of data to an outside entity).
- Cloud Service Monitoring: Monitor and restrict access to various cloud services (Azure, AWS, Dropbox). If an unauthorized cloud service is accessed, investigate and shut it down.
- Hardened Configurations: Ensure all configurations are hardened.
- No Default Route + NAC: Nickerson describes a client that implemented a network with no default route and Network Access Control (NAC). This was "the most hardcore thing" he'd encountered as a pentester. Devices only received routes to specific, necessary internal services, completely isolating them from general network traversal. This makes lateral movement incredibly difficult and simplifies IDS tuning.
Workstation Defenses
- Workstations for Work: Workstations should only perform workstation functions. Remove all server functions, unnecessary software (e.g., Office, Adobe products), and bloatware.
- Remove GPO Passwords: Eliminate the practice of embedding clear-text passwords for service accounts in Group Policy Objects (GPOs). Any user who can mount
net sysvolon a domain controller can decrypt these. Nickerson urges immediate removal. - Software Whitelisting/Blacklisting: Implement strict application whitelisting and blacklisting. If a user "really, really needs" software like Flash or Java, implement a multi-level approval process involving two levels of management to sign off on the risk.
- No Local Admin Privileges: Remove local administrator privileges from users. Nickerson notes that Microsoft's LAPS (Local Administrator Password Solution) helps randomize local admin passwords, mitigating hash spraying attacks.
- Assume Compromise: Operate under the assumption that a workstation will get compromised. Focus on preventing lateral movement and detecting post-exploitation activities, such as hash harvesting and spraying.
- Host-Based Controls: Deploy host-based firewalls, IDS, and behavioral analysis tools. These don't require huge investments; even partial implementation provides value.
- Proactive Vulnerability Scanning: Proactively scan for vulnerabilities on workstations, especially legacy systems like Windows XP or embedded systems. If a vulnerability cannot be patched (e.g., due to a legacy application), implement specific detective controls (IDS/IPS rules) to alert on exploitation attempts targeting that system.
Server Defenses
- Lean Servers: Servers should only run services built for serving. Remove all non-server software. Nickerson gives examples like Office or Adobe products on a server as immediate indicators of failure.
- Unquoted Service Paths: Test for and remediate unquoted service path vulnerabilities (e.g., in products like IBM Tivoli Management Services). If a service path contains spaces and is not enclosed in quotes, an attacker can place an executable with the same name as the first word in the path (e.g.,
program.exeinC:\Program Files\IBM Tivoli\) and have it run with elevated privileges. - Privilege Escalation Checks: Utilize scripts like those from Pentest Monkey to check for common Windows and Linux privilege escalation vectors.
- OSSEC: For critical servers, deploy OSSEC or similar open-source host-based intrusion detection systems to gain visibility into host-level activities without significant cost. Nickerson suggests deploying it initially in a non-running, analysis-only mode on default images, allowing for activation during an IR event without alerting the attacker.
Correlation and Advanced Monitoring
- Open-Source SIEM/Correlation:
- Bro (now Zeek) and Snort/Suricata (IDS/IPS) are excellent for network traffic analysis and reporting.
- While Splunk is powerful, Nickerson points out its high cost post-IPO. He strongly advocates for the ELK stack (Elasticsearch, Logstash, Kibana) as a free, self-built alternative that provides "magic Splunk" capabilities.
- Integrate OpenIOC and TAXII feeds into the ELK stack to correlate internal logs with external threat intelligence (e.g., matching MD5 hashes of known malware).
- Skilly is mentioned for its ability to correlate from multiple sources, allowing organizations to "become ioactive" by aggregating Intel feeds.
- WMI/PowerShell Defense for APTs:
- Nickerson highlights PowerShell and WMI (Windows Management Instrumentation) as the primary mechanisms for advanced attackers (APTs) in Windows environments. WMI is a "beautifully rich system for logging."
- He points to tools like PowerSploit and the Empire framework as examples of advanced PowerShell-based attack tools.
- Inspired by FireEye Flare's work on host-based WMI IDS, Nickerson shares key WMI events to monitor for persistence and C2:
- Event Filters: Creation of event filters (indicates a persistent mechanism).
- Event Consumers: Creation of event consumers (something consuming an event, often for persistence).
- Filter Consumers: Creation of filter consumers (linking a filter to a consumer).
- Namespace Instances: Creation of new namespace instances (can indicate C2).
- Class Creation Events: Creation of new classes (data storage for classed data).
- Provider Engagement Services: Anytime a new WMI provider comes into play.
- Nickerson mentions quick PowerShell scripts on his GitHub to log these events, which can then be fed into a SIEM for instant alerts.
Incident Response (IR)
- Structured IR Program: Most organizations lack a true IR process. Nickerson recommends using resources like Lenny Zeltser's website for building IR capabilities, including tools, flowcharts, and methodologies.
- Beyond Re-imaging: A common failure is simply re-imaging a compromised machine. Instead, IR must involve:
- Harvesting Credentials: Using tools like Mimikatz to dump hashes, live SSP, and web session cookies from the compromised machine.
- Collateral Damage Assessment: Understanding what other systems or data the compromised machine had access to.
- Frameworks for Investigation: Teaching IR teams to use offensive frameworks (e.g., Metasploit, Core Impact) to understand how attackers operate and what artifacts they leave.
- Response Platforms:
- Existing response platforms, including an offering from CrowdStrike, or more complex commercial tools.
- Nickerson personally uses a "ghetto" but effective combination of RTIR (Request Tracker for Incident Response) and MediaWiki. RTIR serves as a ticketing system, and MediaWiki acts as a knowledge base to document attacks, collateral damage, successful defenses, and lessons learned, constantly feeding education back into the security program.
Demo / Proof of Concept
▶ Watch: Advanced detection using WMI/Powershell for persistence mechanisms (52:30)
Chris Nickerson's talk is a high-level strategic and tactical discussion based on his extensive experience, rather than a live demonstration. He does not present a specific demo or proof of concept during the presentation. Instead, he references various tools and techniques, such as SpiderFoot, the ELK stack, PowerSploit, Empire, Mimikatz, and his own GitHub Powershell scripts for WMI monitoring, as examples of capabilities that defenders can implement.
Defensive Implications
▶ Watch: The culture of effective defensive security teams (67:30)
Chris Nickerson's "Nightmares of a Pentester" provides a clear, actionable mandate for defenders seeking to build truly resilient security programs:
- Embrace "Built-in, Not Bolt-on" Security: Organizations must fundamentally re-evaluate their security architecture. Instead of continuously buying new products to "bolt on" defenses, security must be an inherent part of system design, development lifecycles, and operational processes. This means prioritizing robust, foundational controls over shiny new widgets.
- Master the Fundamentals: The majority of attacks leverage basic weaknesses like unpatched systems (exploits over a year old), default configurations, and lack of basic network hygiene. Defenders should aggressively implement core security controls:
- Strict patch management.
- Aggressive network segmentation (even "no default route" where feasible).
- Removal of local admin privileges and management of passwords (e.g., using LAPS).
- Hardened workstation and server configurations, stripping unnecessary software and services.
- Robust email security (SPF, encryption, sender verification).
- Leverage Open Source for Strategic Advantage: Don't be swayed by expensive vendor promises. Powerful and effective security tools are often available in the open-source domain. Defenders should actively explore and implement solutions like:
- ELK stack (Elasticsearch, Logstash, Kibana) for scalable log aggregation and threat intelligence correlation.
- Bro (Zeek) for network traffic analysis.
- OSSEC for host-based intrusion detection.
- SpiderFoot for automated external reconnaissance.
- RTIR + MediaWiki for incident response management and knowledge sharing. These tools provide significant capabilities at a fraction of the cost, forcing vendors to truly demonstrate added value.
- Shift to Proactive, Aggressive Monitoring and Detection: Defenders must move beyond perimeter defense and implement deep visibility into their internal networks and endpoints.
- Tune IDS/IPS for internal traffic to detect lateral movement.
- Actively block internal port scans and monitor NetFlow for anomalous data exfiltration.
- Crucially, implement WMI-based monitoring to detect advanced attacker techniques using PowerShell and WMI for persistence and C2. Nickerson's provided WMI event indicators are a critical starting point for detecting modern APT activity.
- Actively monitor and restrict access to cloud services.
- Empower Users as the First Line of Defense: Instead of blaming users, invest in aggressive, realistic security awareness training. Programs like "get hacked days" can transform users from perceived liabilities into active contributors to defense, understanding the threat landscape and reporting suspicious activity.
- Revolutionize Incident Response: Move beyond simply re-imaging compromised machines. A robust IR program must include:
- Detailed forensic analysis to understand the full scope of compromise.
- Credential harvesting (e.g., using Mimikatz) from compromised hosts to understand what an attacker gained and prevent lateral movement.
- Assessment of collateral damage to other systems.
- A continuous feedback loop where lessons learned from incidents are documented and used to strengthen defenses proactively.
- Cultivate a Resilient Security Culture: The most effective blue teams are those that welcome offensive testing and use it as a catalyst for improvement. Foster a culture where security professionals are "fired up about the fight," continuously learning from red team engagements and striving to make attackers' jobs as difficult as possible. This adversarial mindset, embraced internally, is critical for sustained defensive strength.
Key Takeaways
- Built-in Security is Paramount: Stop bolting on security products; integrate security into the core architecture and processes from the ground up.
- Master the Fundamentals: Basic, well-executed defenses like patching, segmentation, and access control can stop 90-95% of common attacks.
- Empower Users, Don't Blame Them: Treat users as the first line of defense through aggressive, realistic training and robust technical controls that account for human error.
- Leverage Open Source Tools: Powerful, cost-effective open-source solutions (ELK stack, Bro, OSSEC, WMI monitoring) can provide superior visibility and threat intelligence compared to many expensive commercial offerings.
- Aggressive Red Teaming Drives Improvement: Embrace full-scope penetration tests designed to push your defenses to their limits; this feedback is invaluable for continuous improvement.
- Advanced Detection for Modern Threats: Implement specific monitoring for WMI and PowerShell activity to detect sophisticated APTs that bypass traditional controls.
About the Speaker(s)
Chris Nickerson is a highly experienced and well-known figure in the information security industry, with over 15 years as a pentester. He is recognized as an expert in red team testing and real-world attacks, having encountered numerous complex situations throughout his career. Nickerson is the owner of Lares, a company that provides a wide range of security services including code review, application testing, incident response, risk assessments, physical security, forensics, adversarial modeling, and advanced red teaming. He is passionate about fostering a stronger security community and inspiring defenders to improve their craft.