Leveraging ML and AI for Better Attack Detection

Nilesh Dherange (Co-founder & CTO · Gurucul)

Black Hat Middle East & Africa 2023 (Executive Summit) · Day 3 · Executive Summit

Overview

In this insightful Black Hat MEA talk, Nilesh Dherange, Co-founder and CTO of Gurucul, addresses the critical need for advanced security mechanisms in the face of increasingly sophisticated cyber threats. The presentation, titled "Leveraging ML and AI for Better Attack Detection," argues that traditional, signature-driven security systems are largely ineffective against modern attack vectors, which range from crypto mining to complex supply chain compromises. Dherange posits that a fundamental shift towards machine learning (ML) and artificial intelligence (AI) based security operations centers (SOCs) is not just beneficial, but essential for robust organizational defense.

Watch on YouTube

Visual summary for Leveraging ML and AI for Better Attack Detection by Nilesh Dherange
Visual summary for Leveraging ML and AI for Better Attack Detection by Nilesh Dherange

Key moments

  1. 0:00 Introduction: Evolution of cyber threats and need for ML/AI
  2. 2:00 ML and AI for SOC: Adaptive, predictive, and automated security
  3. 4:00 Leveraging behavioral analysis and large datasets for detection
  4. 6:00 Importance of context in ML to reduce false positives
  5. 8:00 Improving ML detection accuracy through continuous feedback loops
  6. 10:00 Tuning and adapting ML models with user feedback
  7. 12:00 Real-world case study: SI's success with ML/AI platform
  8. 16:00 Future of AI/ML in cybersecurity: hardware, biometrics, bad AI

Leveraging ML and AI for Better Attack Detection

Speakers: Nilesh Dherange, Co-founder & CTO, Gurucul

Conference: Black Hat MEA

YouTube: https://www.youtube.com/watch?v=TTQpSToS4KE

Overview

In this insightful Black Hat MEA talk, Nilesh Dherange, Co-founder and CTO of Gurucul, addresses the critical need for advanced security mechanisms in the face of increasingly sophisticated cyber threats. The presentation, titled "Leveraging ML and AI for Better Attack Detection," argues that traditional, signature-driven security systems are largely ineffective against modern attack vectors, which range from crypto mining to complex supply chain compromises. Dherange posits that a fundamental shift towards machine learning (ML) and artificial intelligence (AI) based security operations centers (SOCs) is not just beneficial, but essential for robust organizational defense.

Dherange emphasizes that while there is significant buzz around AI, it is not a standalone "silver bullet." Instead, effective threat detection necessitates a strategic combination of AI and purpose-built machine learning systems. These adaptive technologies enable continuous monitoring, predictive analysis, and automated responses, moving beyond reactive detection to proactive prevention. The core argument revolves around the ability of ML and AI to perform behavioral analysis and anomaly detection across vast, diverse datasets, thereby reducing false positives and significantly increasing the accuracy of true positive threat detections.

The talk highlights how ML and AI can transform security by learning from past behaviors, adapting to unique organizational contexts, and continuously improving detection accuracy through feedback loops. This adaptive approach is crucial for handling the sheer volume and variety of data generated in modern enterprises, offering a path to more efficient and effective security operations. Dherange presents a compelling case for how these technologies empower security teams to focus on strategic threat hunting and use case development rather than being overwhelmed by manual alert triage.

Background

▶ Watch: Introduction: Evolution of cyber threats and need for ML/AI (0:00)

The landscape of cyber threats has undergone a profound evolution over recent years, transforming from simple, recognizable attacks like spyware to highly sophisticated, multi-vector campaigns such as crypto mining and supply chain compromises. These modern attacks leverage advanced technologies and intricate mechanisms, rendering traditional security approaches largely obsolete. Historically, security operations centers (SOCs) have relied heavily on signature-driven systems—mechanisms that identify threats based on known patterns or signatures. While effective against previously identified threats, this reactive approach struggles with novel or polymorphic attacks.

The inherent limitations of traditional systems are manifold: they generate an excessive number of false positives, demanding significant manual effort for triage and verification. This overload not only strains security teams but also diverts resources from proactive defense strategies. Moreover, their inability to adapt to evolving attack methodologies means they often miss sophisticated, unknown threats. The problem is exacerbated by the sheer volume and diversity of data generated within modern enterprises, spanning on-premise infrastructure, cloud environments, and external threat intelligence feeds. Traditional systems lack the computational power and analytical capabilities to derive meaningful insights from such large, complex datasets.

Consequently, there is an urgent and undeniable need for more sophisticated tools and mechanisms to combat these advanced threat vectors. The industry is moving towards an ML and AI-based security operations center model, designed to be more adaptive, predictive, and automated. This new paradigm seeks to overcome the limitations of signature-based detection by focusing on understanding normal behavior and identifying deviations, rather than solely relying on predefined threat patterns. The shift represents a fundamental change in how organizations approach threat detection, moving from a static, rule-based defense to a dynamic, intelligence-driven security posture.

Key Findings

▶ Watch: Leveraging behavioral analysis and large datasets for detection (4:00)

The talk presents several key findings and principles underpinning the effective application of ML and AI in cybersecurity. Foremost among these is the recognition that ML and AI enable a paradigm shift from reactive, signature-based detection to proactive and adaptive security. Unlike traditional systems, ML-driven approaches facilitate continuous monitoring and offer predictive capabilities, allowing SOCs to anticipate and mitigate threats more effectively. The inherent adaptiveness of ML systems means they can learn and evolve with the threat landscape and internal organizational behaviors.

A central tenet is the critical role of behavioral analysis and anomaly detection. The speaker stresses that every organization, infrastructure, and user interaction pattern is unique. Therefore, ML systems must learn from past behaviors of users, devices, and network entities to establish dynamic baselines. Any significant deviation from these baselines can then be flagged as a potential anomaly. This approach is far more robust than static rules, as it accounts for the nuanced and constantly changing environment of an enterprise.

Furthermore, the efficacy of ML/AI heavily relies on the ingestion and analysis of large, diverse datasets. These include both structured and unstructured data from various sources: on-premise systems, cloud environments, and external threat intelligence feeds. The challenge lies not just in collecting this data but in intelligently processing it. A crucial step identified is feature extraction (or feature engineering), where meaningful attributes are derived from raw data to make it effective for ML algorithms. Not all data points are equally valuable, and intelligent feature selection significantly enhances model performance.

Perhaps the most significant finding revolves around the concept of context. Dherange powerfully illustrates that "not all anomalies are risky." A user logging in remotely might be a threat, or it might be a legitimate action if they are traveling or working from home. By integrating additional contextual data—such as HR records indicating remote work status or travel plans—ML systems can drastically reduce false positives and pinpoint true positive incidents. This contextual enrichment is paramount for achieving high detection accuracy and preventing alert fatigue.

Finally, the talk highlights the importance of detection accuracy and a continuous feedback loop for ML models. An ML system is not foolproof; it will generate false positives and false negatives. The key is to continuously feed back detection outcomes (true positives, false positives, false negatives) into the system. This iterative learning process allows the ML models to refine their algorithms, improve their efficacy, and become more effective over time. This adaptive tuning, often guided by human analyst feedback, is essential for maintaining and enhancing the security posture.

Technical Deep Dive

▶ Watch: Improving ML detection accuracy through continuous feedback loops (8:00)

The technical foundation of leveraging ML and AI for advanced attack detection, as outlined by Dherange, centers on several core principles and methodologies. At its heart is behavioral analysis, where ML algorithms are trained to understand the "normal" operational patterns of users, endpoints, applications, and networks within an organization. This involves generating behavior profiles or baselines over a defined period (e.g., 30-60 days). These baselines are highly individualized, reflecting the unique interactions and activities of each entity. Deviations from these established baselines are then identified as anomalies, which may signify malicious activity.

The process begins with data ingestion, which must be comprehensive and encompass a wide variety of sources. This includes security logs from firewalls, intrusion detection systems, and endpoint protection platforms, alongside non-security data such as HR records, identity management systems, and even physical access logs. Data streams from both on-premise infrastructure and cloud environments are critical, as are external threat intelligence feeds. The challenge with such vast and disparate data is its raw, often unstructured nature. This necessitates feature engineering—the process of transforming raw data into features that are suitable for ML algorithms. For example, instead of just a raw login event, features might include login frequency, time of day, geographic location, device type, and prior successful logins from that location.

The ML techniques employed span various categories, including supervised learning, unsupervised learning, deep learning, and even emerging LLM models. While the talk doesn't delve into specific algorithms, it emphasizes that the choice of technique depends on the specific use case. Unsupervised learning is particularly valuable for anomaly detection, as it can identify unusual patterns without requiring pre-labeled "attack" data. Supervised learning, conversely, can be used when historical labeled data of attacks is available to train models to classify new events.

A critical technical aspect is the adaptive learning mechanism of these ML systems. Once an ML model is deployed, it requires continuous tuning. This tuning is not a one-time event but an ongoing process driven by feedback. When a security analyst investigates an alert generated by the ML system, their determination (e.g., true positive, false positive) is fed back into the model. This feedback loop allows the system to learn from its mistakes and successes. For instance, if a legitimate new connection from a device is initially flagged as abnormal, the analyst marking it as a false positive teaches the system to incorporate this new behavior into the device's baseline, preventing future alerts for the same activity. This iterative refinement helps address challenges like model retrofitting and enables rebaselining of behavior profiles over time.

To ensure the effectiveness of ML models, various detection accuracy metrics are continuously tracked. These include the true positive rate, false positive rate, precision, accuracy, efficacy, and efficiency of the ML models. By monitoring these metrics, security teams can gauge the performance of their ML-driven detections and identify areas for improvement. An adaptive ML system automatically leverages these metrics and user feedback to adjust model parameters, weights, and even the selection of features or algorithms, thereby constantly enhancing its ability to detect genuine threats while minimizing noise.

Demo / Proof of Concept

▶ Watch: Tuning and adapting ML models with user feedback (10:00)

While the talk did not feature a live technical demonstration in the traditional sense, Nilesh Dherange presented a compelling real-world case study that serves as a powerful proof of concept for the efficacy of ML and AI in security operations. This example detailed the experience of a large global system integrator (SI) that had adopted Gurucul's ML-based security analytics platform.

Prior to implementing the ML/AI solution, the global SI faced significant challenges with their existing security tools. As an organization handling vast amounts of sensitive information for numerous Fortune 500 customers, they were constantly overwhelmed by a deluge of alerts and a high volume of false positives. Their substantial SOC team, comprising 70 to 80 security analysts, was primarily consumed by manually triaging these alerts, struggling to identify actual threats amidst the noise. This reactive posture limited their ability to proactively protect their customers' data and respond effectively to sophisticated attacks.

Within approximately 90 days of deploying the ML and AI-based system, the SI observed dramatic improvements. The platform's ability to contextualize information from various data sources led to a significant reduction in the number of open cases. Instead of multiple alerts for the same underlying pattern, the ML system correlated and consolidated these, presenting a clearer, more actionable view of potential incidents. This allowed the SOC team to manage threats more efficiently.

Crucially, the ML-based platform expanded their anomaly detection capabilities to cover previously unknown use cases and threat vectors that their traditional systems could not identify. This proactive detection of novel behaviors represented a substantial uplift in their security posture. The most striking result was an almost 60% increase in overall true positives. This meant the system was far more accurate at identifying genuine threats, ranging from insider threat detection and IP protection to real-time threat detection.

The benefits extended beyond detection accuracy. The solution drastically reduced manual efforts for the SOC team. Freed from the burden of constant false positive triage, the 70-person team could redirect their focus towards more strategic activities, such as building new use cases, enhancing threat hunting capabilities, and proactively strengthening the organization's overall defense. This real-world example vividly illustrates how ML and AI can transform a burdened and reactive SOC into a highly efficient, proactive, and effective security operation.

Defensive Implications

▶ Watch: Future of AI/ML in cybersecurity: hardware, biometrics, bad AI (16:00)

The insights from Nilesh Dherange's talk carry profound defensive implications for organizations grappling with the evolving threat landscape. The primary imperative is a strategic shift away from solely relying on traditional, signature-based security tools towards an ML and AI-driven security operations center (SOC). This transition is not merely an upgrade but a fundamental re-architecture of defensive capabilities.

Defenders must prioritize the implementation of systems capable of behavioral analysis and anomaly detection. This means moving beyond looking for known bad patterns to understanding what constitutes "normal" behavior across all entities within the enterprise—users, devices, applications, and networks. Investing in platforms that can establish and continuously refine these behavioral baselines is crucial for identifying novel and sophisticated attacks that evade static rules.

A critical defensive strategy involves comprehensive data collection and contextualization. Organizations need to ingest diverse data sources—including security logs, network traffic, endpoint data, cloud logs, HR records, and threat intelligence—into a centralized analytics platform. The ability to correlate and contextualize this data is paramount for reducing false positives and increasing the fidelity of alerts. Defenders should assess their current data pipeline capabilities and invest in solutions that facilitate rich feature extraction for ML models.

Furthermore, a robust feedback loop mechanism is essential for any adaptive ML-based defense. Security teams must be empowered to provide direct feedback on alerts (marking them as true positive, false positive, or benign). This human-in-the-loop approach allows ML models to continuously learn, tune, and rebaseline, improving their accuracy and efficacy over time. Implementing systems that support this iterative learning process is vital for long-term defensive strength.

Looking ahead, ML and AI offer capabilities that extend beyond detection. Future defensive strategies should explore:

  • Automated software and hardware patching: Adaptive AI systems could potentially identify vulnerabilities and trigger automated patching processes, significantly reducing the window of exposure to zero-day attacks.
  • Data information security: ML can identify where critical information resides, who has access to it, and detect abnormal access patterns, enhancing data loss prevention and intellectual property protection.
  • Behavioral biometrics: Integrating ML with behavioral biometrics (e.g., keystroke dynamics, mouse movements) can provide an additional layer of authentication and continuous identity verification, mitigating risks from stolen credentials.

Finally, defenders must also be cognizant of the concept of "bad AI" or adversarial AI. Just as ML can be used for defense, attackers are leveraging AI for more sophisticated attacks. This includes training AI models on abnormal data to generate misleading results or developing AI-powered malware. Therefore, defensive ML systems must be robust, adaptive, and resilient to adversarial attacks, continuously learning and adapting to counter malicious AI strategies. This necessitates a proactive approach to understanding and defending against AI-enabled threats.

Key Takeaways

  • ML and AI are indispensable for modern threat detection: Traditional signature-driven systems are inadequate against sophisticated, evolving cyber threats, necessitating a shift to adaptive ML/AI-based security operations.
  • Contextual data is paramount for accuracy: Integrating diverse data sources (security, HR, cloud, threat intel) provides crucial context, drastically reducing false positives and enhancing the accuracy of true threat detections.
  • Behavioral analysis is the cornerstone: Understanding and baselining "normal" behavior for users, devices, and applications allows ML systems to effectively identify deviations and anomalies indicative of malicious activity.
  • Adaptive ML requires continuous feedback and tuning: Security systems must incorporate a feedback loop where analyst input (true/false positive) continuously refines and improves ML models, ensuring ongoing accuracy and relevance.
  • Significant operational improvements are achievable: A real-world case study demonstrated a 60% increase in true positives and substantial reductions in manual effort, allowing SOC teams to focus on strategic threat hunting and use case development.
  • ML/AI will drive future security capabilities: Beyond detection, these technologies are poised to enable advanced defensive measures such as automated patching, enhanced data security, and behavioral biometrics, while also requiring vigilance against "bad AI" used by attackers.

About the Speaker(s)

Nilesh Dherange is the Co-founder and Chief Technology Officer (CTO) for Gurucul. Gurucul is recognized as a company specializing in security analytics, threat detection, investigations, and response platforms. Dherange's expertise lies in leveraging advanced technologies like machine learning and artificial intelligence to develop sophisticated solutions for combating complex cyber threats and enhancing organizational security postures.

Reviews

Dr. Zero (Offensive Security Researcher) — HARD PASS

This isn't a research talk; it's a 2014 Gartner UEBA marketing brochure read aloud. The CTO of Gurucul got on a Black Hat stage to tell us that signatures are dead, false positives are bad, and his platform's magical 'AI' will solve alert fatigue. Skip this entirely unless you are actively shopping for a vendor platform and want to hear a standard sales pitch.

Heather Calloway (CISO) — PASS

This is a sales deck, not a strategy briefing. The premise—that SOCs need behavioral baselines and business context to reduce false positives—is accurate but ten years old. Repackaging standard UEBA capabilities under the current AI hype cycle does not warrant your leadership team's attention.

→ Top-rated talks at Black Hat Middle East & Africa 2023 (Executive Summit)

All talks from Black Hat Middle East & Africa 2023 (Executive Summit)