SlideShare a Scribd company logo
1 of 33
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Leveraging Osquery for DFIR at scale
Sohini Mukherjee | Security Researcher @ Adobe
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Agenda
 Rapid Incident Response
 Fast Forensics
 Proactive Threat Hunting
2
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Needle in a haystack?
 Running processes
 Active network connections
 New user accounts
 Detect file system changes
 Kernel Modules loaded
 Evidence of Persistence
 Evidence of Code Injection
 Non-standard Running Services
3
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Can Osquery help?
 Abstracts the OS to SQL (SQLite)
 Open-Source, active development
 Cross-platform
 Light-weight agent
 Non-intrusive: user-mode
4
Reference: https://blog.kolide.com/profiling-osquery-performance-with-kolide-cloud-8e01097469db
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Some Osquery statements..
5
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Osquery Deployment..
6
1. osquery enrolls or polls
2. TLS endpoint responds with a query
3. osquery replies with results
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Kolide Fleet – Open Source Osquery Manager
7
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Kolide Fleet Portal
8
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
@ Scale..
9
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Potential Attack Scenarios
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Attack Scenario : Reverse Shells
11
© 2019 Adobe. All Rights Reserved. Adobe Confidential. 12
© 2019 Adobe. All Rights Reserved. Adobe Confidential. 13
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Reverse Shell : Mshta : MITRE [T1170]
14
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Reverse Shell : Regsvr32 : MITRE [T1117]
15
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Reverse Shell : DLL Injection : MITRE [T1055]
16
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
DLLInjection: Detections
17
• Pstree with active network sockets
• https://github.com/facebook/osquery/blob/master/specs/processes.table
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
DLLInjection: Detections
18
• Injection (malicious msf.dll) as seen by process_memory_map table
• https://github.com/facebook/osquery/blob/master/specs/process_memory_map.table
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
DLLInjection: Evidence gathering
19
• File System Metadata for evidence of time of execution
• https://github.com/facebook/osquery/blob/master/specs/utility/file.table
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
CryptoMining
20
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Attack Scenario
21
4. The miner establishes connection to its pool
2. Attacker establishes alternate access by creating a new user
1. Attacker authenticates with stolen credentials
3. The new user installs and starts the miner
© 2019 Adobe. All Rights Reserved. Adobe Confidential. 22
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Detection via Kolide Fleet deployment
23
• Suspicious process on a non-standard network socket
• select s.pid, p.name, local_address, remote_address, family, protocol, local_port, remote_port from process_open_sockets s join
processes p on s.pid = p.pid where remote_port like 4444
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
How does it look like in SIEM?
24
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Detection from artifacts
25
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Container Exploit
26
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Privileged Container/ Container escape attempt
27
Container
Container
Container
Container
Container
Privileged
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Can we detect it?
28
• Container running in privileged mode with the root user without any Security Profiles
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Docker queries
 Docker_open_sockets:
29
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Container Exploit Scenario
30
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
References
 https://osquery.io/
 https://github.com/facebook/osquery
 https://github.com/teoseller/osquery-attck
 https://github.com/polylogyx/osq-ext-bin
 https://github.com/osql/extensions
 https://github.com/gcmurphy/windmill
 https://github.com/osquery/osquery-python
 https://blog.trailofbits.com/2018/05/28/collect-ntfs-forensic-information-with-osquery/
31
© 2019 Adobe. All Rights Reserved. Adobe Confidential.
Thank You
Leveraging Osquery for DFIR @ Scale _BSidesSF_2020

More Related Content

What's hot

Dev week cloud world conf2021
Dev week cloud world conf2021Dev week cloud world conf2021
Dev week cloud world conf2021Archana Joshi
 
Hacking IoT with EXPLIoT Framework
Hacking IoT with EXPLIoT FrameworkHacking IoT with EXPLIoT Framework
Hacking IoT with EXPLIoT FrameworkPriyanka Aash
 
Modern Security Operations aka Secure DevOps @ All Day DevOps 2017
Modern Security Operations aka Secure DevOps @ All Day DevOps 2017Modern Security Operations aka Secure DevOps @ All Day DevOps 2017
Modern Security Operations aka Secure DevOps @ All Day DevOps 2017Madhu Akula
 
Practical Secure Coding Workshop - {DECIPHER} Hackathon
Practical Secure Coding Workshop - {DECIPHER} HackathonPractical Secure Coding Workshop - {DECIPHER} Hackathon
Practical Secure Coding Workshop - {DECIPHER} HackathonStefan Streichsbier
 
A journey from dev ops to devsecops
A journey from dev ops to devsecopsA journey from dev ops to devsecops
A journey from dev ops to devsecopsVeritis Group, Inc
 
Why cloud native envs deserve better security - Dima Stopel, Twistlock - Clou...
Why cloud native envs deserve better security - Dima Stopel, Twistlock - Clou...Why cloud native envs deserve better security - Dima Stopel, Twistlock - Clou...
Why cloud native envs deserve better security - Dima Stopel, Twistlock - Clou...Cloud Native Day Tel Aviv
 
Practical DevSecOps Using Security Instrumentation
Practical DevSecOps Using Security InstrumentationPractical DevSecOps Using Security Instrumentation
Practical DevSecOps Using Security InstrumentationVMware Tanzu
 
Chaos engineering for cloud native security
Chaos engineering for cloud native securityChaos engineering for cloud native security
Chaos engineering for cloud native securityKennedy
 
AllDayDevOps 2019 AppSensor
AllDayDevOps 2019 AppSensorAllDayDevOps 2019 AppSensor
AllDayDevOps 2019 AppSensorjtmelton
 
The path of secure software by Katy Anton
The path of secure software by Katy AntonThe path of secure software by Katy Anton
The path of secure software by Katy AntonDevSecCon
 
Overcoming Security Challenges in DevOps
Overcoming Security Challenges in DevOpsOvercoming Security Challenges in DevOps
Overcoming Security Challenges in DevOpsAlert Logic
 
Outpost24 webinar: cloud providers ate hosting companies' lunch, what's next?...
Outpost24 webinar: cloud providers ate hosting companies' lunch, what's next?...Outpost24 webinar: cloud providers ate hosting companies' lunch, what's next?...
Outpost24 webinar: cloud providers ate hosting companies' lunch, what's next?...Outpost24
 
Outpost24 webinar : how to secure your data in the cloud - 06-2018
Outpost24 webinar : how to secure your data in the cloud - 06-2018Outpost24 webinar : how to secure your data in the cloud - 06-2018
Outpost24 webinar : how to secure your data in the cloud - 06-2018Outpost24
 
Finding Security a Home in a DevOps World
Finding Security a Home in a DevOps WorldFinding Security a Home in a DevOps World
Finding Security a Home in a DevOps WorldShannon Lietz
 
DevSecCon Singapore 2019: Embracing Security - A changing DevOps landscape
DevSecCon Singapore 2019: Embracing Security - A changing DevOps landscapeDevSecCon Singapore 2019: Embracing Security - A changing DevOps landscape
DevSecCon Singapore 2019: Embracing Security - A changing DevOps landscapeDevSecCon
 
Think Like a Hacker: Using Network Analytics and Attack Simulation to Find an...
Think Like a Hacker: Using Network Analytics and Attack Simulation to Find an...Think Like a Hacker: Using Network Analytics and Attack Simulation to Find an...
Think Like a Hacker: Using Network Analytics and Attack Simulation to Find an...Skybox Security
 
Bio IT World 2015 - DevOps Security and Transparency
Bio IT World 2015 - DevOps Security and TransparencyBio IT World 2015 - DevOps Security and Transparency
Bio IT World 2015 - DevOps Security and TransparencyKevin Gilpin
 
Modernizing Traditional Security - DEM13 - AWS re:Inforce 2019
Modernizing Traditional Security - DEM13 - AWS re:Inforce 2019 Modernizing Traditional Security - DEM13 - AWS re:Inforce 2019
Modernizing Traditional Security - DEM13 - AWS re:Inforce 2019 Amazon Web Services
 
SBA Security Meetup - Deploying and managing azure sentinel as code by Bojan ...
SBA Security Meetup - Deploying and managing azure sentinel as code by Bojan ...SBA Security Meetup - Deploying and managing azure sentinel as code by Bojan ...
SBA Security Meetup - Deploying and managing azure sentinel as code by Bojan ...SBA Research
 
Locking Down Your Cloud
Locking Down Your CloudLocking Down Your Cloud
Locking Down Your CloudTeri Radichel
 

What's hot (20)

Dev week cloud world conf2021
Dev week cloud world conf2021Dev week cloud world conf2021
Dev week cloud world conf2021
 
Hacking IoT with EXPLIoT Framework
Hacking IoT with EXPLIoT FrameworkHacking IoT with EXPLIoT Framework
Hacking IoT with EXPLIoT Framework
 
Modern Security Operations aka Secure DevOps @ All Day DevOps 2017
Modern Security Operations aka Secure DevOps @ All Day DevOps 2017Modern Security Operations aka Secure DevOps @ All Day DevOps 2017
Modern Security Operations aka Secure DevOps @ All Day DevOps 2017
 
Practical Secure Coding Workshop - {DECIPHER} Hackathon
Practical Secure Coding Workshop - {DECIPHER} HackathonPractical Secure Coding Workshop - {DECIPHER} Hackathon
Practical Secure Coding Workshop - {DECIPHER} Hackathon
 
A journey from dev ops to devsecops
A journey from dev ops to devsecopsA journey from dev ops to devsecops
A journey from dev ops to devsecops
 
Why cloud native envs deserve better security - Dima Stopel, Twistlock - Clou...
Why cloud native envs deserve better security - Dima Stopel, Twistlock - Clou...Why cloud native envs deserve better security - Dima Stopel, Twistlock - Clou...
Why cloud native envs deserve better security - Dima Stopel, Twistlock - Clou...
 
Practical DevSecOps Using Security Instrumentation
Practical DevSecOps Using Security InstrumentationPractical DevSecOps Using Security Instrumentation
Practical DevSecOps Using Security Instrumentation
 
Chaos engineering for cloud native security
Chaos engineering for cloud native securityChaos engineering for cloud native security
Chaos engineering for cloud native security
 
AllDayDevOps 2019 AppSensor
AllDayDevOps 2019 AppSensorAllDayDevOps 2019 AppSensor
AllDayDevOps 2019 AppSensor
 
The path of secure software by Katy Anton
The path of secure software by Katy AntonThe path of secure software by Katy Anton
The path of secure software by Katy Anton
 
Overcoming Security Challenges in DevOps
Overcoming Security Challenges in DevOpsOvercoming Security Challenges in DevOps
Overcoming Security Challenges in DevOps
 
Outpost24 webinar: cloud providers ate hosting companies' lunch, what's next?...
Outpost24 webinar: cloud providers ate hosting companies' lunch, what's next?...Outpost24 webinar: cloud providers ate hosting companies' lunch, what's next?...
Outpost24 webinar: cloud providers ate hosting companies' lunch, what's next?...
 
Outpost24 webinar : how to secure your data in the cloud - 06-2018
Outpost24 webinar : how to secure your data in the cloud - 06-2018Outpost24 webinar : how to secure your data in the cloud - 06-2018
Outpost24 webinar : how to secure your data in the cloud - 06-2018
 
Finding Security a Home in a DevOps World
Finding Security a Home in a DevOps WorldFinding Security a Home in a DevOps World
Finding Security a Home in a DevOps World
 
DevSecCon Singapore 2019: Embracing Security - A changing DevOps landscape
DevSecCon Singapore 2019: Embracing Security - A changing DevOps landscapeDevSecCon Singapore 2019: Embracing Security - A changing DevOps landscape
DevSecCon Singapore 2019: Embracing Security - A changing DevOps landscape
 
Think Like a Hacker: Using Network Analytics and Attack Simulation to Find an...
Think Like a Hacker: Using Network Analytics and Attack Simulation to Find an...Think Like a Hacker: Using Network Analytics and Attack Simulation to Find an...
Think Like a Hacker: Using Network Analytics and Attack Simulation to Find an...
 
Bio IT World 2015 - DevOps Security and Transparency
Bio IT World 2015 - DevOps Security and TransparencyBio IT World 2015 - DevOps Security and Transparency
Bio IT World 2015 - DevOps Security and Transparency
 
Modernizing Traditional Security - DEM13 - AWS re:Inforce 2019
Modernizing Traditional Security - DEM13 - AWS re:Inforce 2019 Modernizing Traditional Security - DEM13 - AWS re:Inforce 2019
Modernizing Traditional Security - DEM13 - AWS re:Inforce 2019
 
SBA Security Meetup - Deploying and managing azure sentinel as code by Bojan ...
SBA Security Meetup - Deploying and managing azure sentinel as code by Bojan ...SBA Security Meetup - Deploying and managing azure sentinel as code by Bojan ...
SBA Security Meetup - Deploying and managing azure sentinel as code by Bojan ...
 
Locking Down Your Cloud
Locking Down Your CloudLocking Down Your Cloud
Locking Down Your Cloud
 

Similar to Leveraging Osquery for DFIR @ Scale _BSidesSF_2020

RICOH THETA x IoT Developers Contest : Cloud API Seminar
 RICOH THETA x IoT Developers Contest : Cloud API Seminar RICOH THETA x IoT Developers Contest : Cloud API Seminar
RICOH THETA x IoT Developers Contest : Cloud API Seminarcontest-theta360
 
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at BSides Delh...
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at BSides Delh...VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at BSides Delh...
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at BSides Delh...Riddhi Shree
 
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at c0c0n XII)
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at c0c0n XII)VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at c0c0n XII)
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at c0c0n XII)Riddhi Shree
 
Security Patterns for Microservice Architectures - London Java Community 2020
Security Patterns for Microservice Architectures - London Java Community 2020Security Patterns for Microservice Architectures - London Java Community 2020
Security Patterns for Microservice Architectures - London Java Community 2020Matt Raible
 
Securing your web applications in CF 2016
Securing your web applications in CF 2016Securing your web applications in CF 2016
Securing your web applications in CF 2016Pavan Kumar
 
Security Patterns for Microservice Architectures - Oktane20
Security Patterns for Microservice Architectures - Oktane20Security Patterns for Microservice Architectures - Oktane20
Security Patterns for Microservice Architectures - Oktane20Matt Raible
 
2023 Patch Tuesday de Octubre
2023 Patch Tuesday de Octubre2023 Patch Tuesday de Octubre
2023 Patch Tuesday de OctubreIvanti
 
Webinar–Vulnerabilities in Containerised Production Environments
Webinar–Vulnerabilities in Containerised Production EnvironmentsWebinar–Vulnerabilities in Containerised Production Environments
Webinar–Vulnerabilities in Containerised Production EnvironmentsSynopsys Software Integrity Group
 
Securing Containers - Sathyajit Bhat - Adobe
Securing Containers - Sathyajit Bhat - AdobeSecuring Containers - Sathyajit Bhat - Adobe
Securing Containers - Sathyajit Bhat - AdobeCodeOps Technologies LLP
 
Keeping your options open
Keeping your options openKeeping your options open
Keeping your options openDoug Tidwell
 
July Patch Tuesday 2019
July Patch Tuesday 2019July Patch Tuesday 2019
July Patch Tuesday 2019Ivanti
 
Security Patterns for Microservice Architectures - ADTMag Microservices & API...
Security Patterns for Microservice Architectures - ADTMag Microservices & API...Security Patterns for Microservice Architectures - ADTMag Microservices & API...
Security Patterns for Microservice Architectures - ADTMag Microservices & API...Matt Raible
 
IBM WebSphere Liberty and Docker Deep Dive
IBM WebSphere Liberty and Docker Deep DiveIBM WebSphere Liberty and Docker Deep Dive
IBM WebSphere Liberty and Docker Deep DiveDavid Currie
 
Français Patch Tuesday – Octobre
Français Patch Tuesday – OctobreFrançais Patch Tuesday – Octobre
Français Patch Tuesday – OctobreIvanti
 
2023 October Patch Tuesday
2023 October Patch Tuesday2023 October Patch Tuesday
2023 October Patch TuesdayIvanti
 
Do Try This at Home! Extend IBM Connections using IBM Worklight
Do Try This at Home! Extend IBM Connections using IBM WorklightDo Try This at Home! Extend IBM Connections using IBM Worklight
Do Try This at Home! Extend IBM Connections using IBM WorklightProlifics
 
Building and Deploying Cloud Native Applications
Building and Deploying Cloud Native ApplicationsBuilding and Deploying Cloud Native Applications
Building and Deploying Cloud Native ApplicationsManish Kapur
 

Similar to Leveraging Osquery for DFIR @ Scale _BSidesSF_2020 (20)

Webinar–OWASP Top 10 for JavaScript for Developers
Webinar–OWASP Top 10 for JavaScript for DevelopersWebinar–OWASP Top 10 for JavaScript for Developers
Webinar–OWASP Top 10 for JavaScript for Developers
 
Webinar–Reviewing Modern JavaScript Applications
Webinar–Reviewing Modern JavaScript ApplicationsWebinar–Reviewing Modern JavaScript Applications
Webinar–Reviewing Modern JavaScript Applications
 
RICOH THETA x IoT Developers Contest : Cloud API Seminar
 RICOH THETA x IoT Developers Contest : Cloud API Seminar RICOH THETA x IoT Developers Contest : Cloud API Seminar
RICOH THETA x IoT Developers Contest : Cloud API Seminar
 
OpenWhisk JavaOne
OpenWhisk JavaOneOpenWhisk JavaOne
OpenWhisk JavaOne
 
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at BSides Delh...
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at BSides Delh...VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at BSides Delh...
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at BSides Delh...
 
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at c0c0n XII)
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at c0c0n XII)VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at c0c0n XII)
VyAPI - A Modern Cloud Based Vulnerable Android App (Presented at c0c0n XII)
 
Security Patterns for Microservice Architectures - London Java Community 2020
Security Patterns for Microservice Architectures - London Java Community 2020Security Patterns for Microservice Architectures - London Java Community 2020
Security Patterns for Microservice Architectures - London Java Community 2020
 
Securing your web applications in CF 2016
Securing your web applications in CF 2016Securing your web applications in CF 2016
Securing your web applications in CF 2016
 
Security Patterns for Microservice Architectures - Oktane20
Security Patterns for Microservice Architectures - Oktane20Security Patterns for Microservice Architectures - Oktane20
Security Patterns for Microservice Architectures - Oktane20
 
2023 Patch Tuesday de Octubre
2023 Patch Tuesday de Octubre2023 Patch Tuesday de Octubre
2023 Patch Tuesday de Octubre
 
Webinar–Vulnerabilities in Containerised Production Environments
Webinar–Vulnerabilities in Containerised Production EnvironmentsWebinar–Vulnerabilities in Containerised Production Environments
Webinar–Vulnerabilities in Containerised Production Environments
 
Securing Containers - Sathyajit Bhat - Adobe
Securing Containers - Sathyajit Bhat - AdobeSecuring Containers - Sathyajit Bhat - Adobe
Securing Containers - Sathyajit Bhat - Adobe
 
Keeping your options open
Keeping your options openKeeping your options open
Keeping your options open
 
July Patch Tuesday 2019
July Patch Tuesday 2019July Patch Tuesday 2019
July Patch Tuesday 2019
 
Security Patterns for Microservice Architectures - ADTMag Microservices & API...
Security Patterns for Microservice Architectures - ADTMag Microservices & API...Security Patterns for Microservice Architectures - ADTMag Microservices & API...
Security Patterns for Microservice Architectures - ADTMag Microservices & API...
 
IBM WebSphere Liberty and Docker Deep Dive
IBM WebSphere Liberty and Docker Deep DiveIBM WebSphere Liberty and Docker Deep Dive
IBM WebSphere Liberty and Docker Deep Dive
 
Français Patch Tuesday – Octobre
Français Patch Tuesday – OctobreFrançais Patch Tuesday – Octobre
Français Patch Tuesday – Octobre
 
2023 October Patch Tuesday
2023 October Patch Tuesday2023 October Patch Tuesday
2023 October Patch Tuesday
 
Do Try This at Home! Extend IBM Connections using IBM Worklight
Do Try This at Home! Extend IBM Connections using IBM WorklightDo Try This at Home! Extend IBM Connections using IBM Worklight
Do Try This at Home! Extend IBM Connections using IBM Worklight
 
Building and Deploying Cloud Native Applications
Building and Deploying Cloud Native ApplicationsBuilding and Deploying Cloud Native Applications
Building and Deploying Cloud Native Applications
 

Recently uploaded

Introduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHIntroduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHC Sai Kiran
 
IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024Mark Billinghurst
 
US Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionUS Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionMebane Rash
 
Research Methodology for Engineering pdf
Research Methodology for Engineering pdfResearch Methodology for Engineering pdf
Research Methodology for Engineering pdfCaalaaAbdulkerim
 
System Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingSystem Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingBootNeck1
 
Mine Environment II Lab_MI10448MI__________.pptx
Mine Environment II Lab_MI10448MI__________.pptxMine Environment II Lab_MI10448MI__________.pptx
Mine Environment II Lab_MI10448MI__________.pptxRomil Mishra
 
Energy Awareness training ppt for manufacturing process.pptx
Energy Awareness training ppt for manufacturing process.pptxEnergy Awareness training ppt for manufacturing process.pptx
Energy Awareness training ppt for manufacturing process.pptxsiddharthjain2303
 
Past, Present and Future of Generative AI
Past, Present and Future of Generative AIPast, Present and Future of Generative AI
Past, Present and Future of Generative AIabhishek36461
 
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionSachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionDr.Costas Sachpazis
 
complete construction, environmental and economics information of biomass com...
complete construction, environmental and economics information of biomass com...complete construction, environmental and economics information of biomass com...
complete construction, environmental and economics information of biomass com...asadnawaz62
 
Class 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm SystemClass 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm Systemirfanmechengr
 
Instrumentation, measurement and control of bio process parameters ( Temperat...
Instrumentation, measurement and control of bio process parameters ( Temperat...Instrumentation, measurement and control of bio process parameters ( Temperat...
Instrumentation, measurement and control of bio process parameters ( Temperat...121011101441
 
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor CatchersTechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catcherssdickerson1
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfROCENODodongVILLACER
 
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfCCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfAsst.prof M.Gokilavani
 
An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...Chandu841456
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort servicejennyeacort
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvLewisJB
 
Industrial Safety Unit-IV workplace health and safety.ppt
Industrial Safety Unit-IV workplace health and safety.pptIndustrial Safety Unit-IV workplace health and safety.ppt
Industrial Safety Unit-IV workplace health and safety.pptNarmatha D
 

Recently uploaded (20)

Design and analysis of solar grass cutter.pdf
Design and analysis of solar grass cutter.pdfDesign and analysis of solar grass cutter.pdf
Design and analysis of solar grass cutter.pdf
 
Introduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECHIntroduction to Machine Learning Unit-3 for II MECH
Introduction to Machine Learning Unit-3 for II MECH
 
IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024IVE Industry Focused Event - Defence Sector 2024
IVE Industry Focused Event - Defence Sector 2024
 
US Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionUS Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of Action
 
Research Methodology for Engineering pdf
Research Methodology for Engineering pdfResearch Methodology for Engineering pdf
Research Methodology for Engineering pdf
 
System Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event SchedulingSystem Simulation and Modelling with types and Event Scheduling
System Simulation and Modelling with types and Event Scheduling
 
Mine Environment II Lab_MI10448MI__________.pptx
Mine Environment II Lab_MI10448MI__________.pptxMine Environment II Lab_MI10448MI__________.pptx
Mine Environment II Lab_MI10448MI__________.pptx
 
Energy Awareness training ppt for manufacturing process.pptx
Energy Awareness training ppt for manufacturing process.pptxEnergy Awareness training ppt for manufacturing process.pptx
Energy Awareness training ppt for manufacturing process.pptx
 
Past, Present and Future of Generative AI
Past, Present and Future of Generative AIPast, Present and Future of Generative AI
Past, Present and Future of Generative AI
 
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionSachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
 
complete construction, environmental and economics information of biomass com...
complete construction, environmental and economics information of biomass com...complete construction, environmental and economics information of biomass com...
complete construction, environmental and economics information of biomass com...
 
Class 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm SystemClass 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm System
 
Instrumentation, measurement and control of bio process parameters ( Temperat...
Instrumentation, measurement and control of bio process parameters ( Temperat...Instrumentation, measurement and control of bio process parameters ( Temperat...
Instrumentation, measurement and control of bio process parameters ( Temperat...
 
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor CatchersTechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdf
 
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfCCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
 
An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvv
 
Industrial Safety Unit-IV workplace health and safety.ppt
Industrial Safety Unit-IV workplace health and safety.pptIndustrial Safety Unit-IV workplace health and safety.ppt
Industrial Safety Unit-IV workplace health and safety.ppt
 

Leveraging Osquery for DFIR @ Scale _BSidesSF_2020

  • 1. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Leveraging Osquery for DFIR at scale Sohini Mukherjee | Security Researcher @ Adobe
  • 2. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Agenda  Rapid Incident Response  Fast Forensics  Proactive Threat Hunting 2
  • 3. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Needle in a haystack?  Running processes  Active network connections  New user accounts  Detect file system changes  Kernel Modules loaded  Evidence of Persistence  Evidence of Code Injection  Non-standard Running Services 3
  • 4. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Can Osquery help?  Abstracts the OS to SQL (SQLite)  Open-Source, active development  Cross-platform  Light-weight agent  Non-intrusive: user-mode 4 Reference: https://blog.kolide.com/profiling-osquery-performance-with-kolide-cloud-8e01097469db
  • 5. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Some Osquery statements.. 5
  • 6. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Osquery Deployment.. 6 1. osquery enrolls or polls 2. TLS endpoint responds with a query 3. osquery replies with results
  • 7. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Kolide Fleet – Open Source Osquery Manager 7
  • 8. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Kolide Fleet Portal 8
  • 9. © 2019 Adobe. All Rights Reserved. Adobe Confidential. @ Scale.. 9
  • 10. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Potential Attack Scenarios
  • 11. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Attack Scenario : Reverse Shells 11
  • 12. © 2019 Adobe. All Rights Reserved. Adobe Confidential. 12
  • 13. © 2019 Adobe. All Rights Reserved. Adobe Confidential. 13
  • 14. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Reverse Shell : Mshta : MITRE [T1170] 14
  • 15. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Reverse Shell : Regsvr32 : MITRE [T1117] 15
  • 16. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Reverse Shell : DLL Injection : MITRE [T1055] 16
  • 17. © 2019 Adobe. All Rights Reserved. Adobe Confidential. DLLInjection: Detections 17 • Pstree with active network sockets • https://github.com/facebook/osquery/blob/master/specs/processes.table
  • 18. © 2019 Adobe. All Rights Reserved. Adobe Confidential. DLLInjection: Detections 18 • Injection (malicious msf.dll) as seen by process_memory_map table • https://github.com/facebook/osquery/blob/master/specs/process_memory_map.table
  • 19. © 2019 Adobe. All Rights Reserved. Adobe Confidential. DLLInjection: Evidence gathering 19 • File System Metadata for evidence of time of execution • https://github.com/facebook/osquery/blob/master/specs/utility/file.table
  • 20. © 2019 Adobe. All Rights Reserved. Adobe Confidential. CryptoMining 20
  • 21. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Attack Scenario 21 4. The miner establishes connection to its pool 2. Attacker establishes alternate access by creating a new user 1. Attacker authenticates with stolen credentials 3. The new user installs and starts the miner
  • 22. © 2019 Adobe. All Rights Reserved. Adobe Confidential. 22
  • 23. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Detection via Kolide Fleet deployment 23 • Suspicious process on a non-standard network socket • select s.pid, p.name, local_address, remote_address, family, protocol, local_port, remote_port from process_open_sockets s join processes p on s.pid = p.pid where remote_port like 4444
  • 24. © 2019 Adobe. All Rights Reserved. Adobe Confidential. How does it look like in SIEM? 24
  • 25. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Detection from artifacts 25
  • 26. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Container Exploit 26
  • 27. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Privileged Container/ Container escape attempt 27 Container Container Container Container Container Privileged
  • 28. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Can we detect it? 28 • Container running in privileged mode with the root user without any Security Profiles
  • 29. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Docker queries  Docker_open_sockets: 29
  • 30. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Container Exploit Scenario 30
  • 31. © 2019 Adobe. All Rights Reserved. Adobe Confidential. References  https://osquery.io/  https://github.com/facebook/osquery  https://github.com/teoseller/osquery-attck  https://github.com/polylogyx/osq-ext-bin  https://github.com/osql/extensions  https://github.com/gcmurphy/windmill  https://github.com/osquery/osquery-python  https://blog.trailofbits.com/2018/05/28/collect-ntfs-forensic-information-with-osquery/ 31
  • 32. © 2019 Adobe. All Rights Reserved. Adobe Confidential. Thank You

Editor's Notes

  1. Discussion on artifacts
  2. Running misconfigured containers in Prod or any environment can lead to vulnerable scenarios. E.g. Running Privileged Containers, Running without Security Restrictions like AppArmor, Conrainers running as root. An attacker might exploit an Application vulnerability and compromise a Container and with enough elevated privileges , might be able to break in to the underlying Host Kernel space. And eventually, move laterally to other Containers sharing the same host kernelspace and say, starts running Miners in all Production Containers. Container Forensics is challenging – one of the many reasons being short-lived nature of Containers. That’s how Containers are supposed to be. However, we can audit for this security misconfigurations and remediate those proactively before a compromise actually takes place
  3. We can use more complex osquery statements to audit for Docker Open Sockets And as we have seen from our previous examples – Open Sockets might lead to pretty interesting information For proactive theat-hunting, we might want to do an Outlier Analysis beyond a baseline of known good. E.g. A newly seen process is running out of an unexpected file path and reaching out to a first-seen set of IP Addresses – not necessarily malicious but gives you an interesting subset of information to investigate further on. And this is not just related to Containers, we can apply the same logic to more conventional environments as well.
  4. But what if none of these Security flaws were detected or remediated and an attacker has been able to compromise ang gain access to a Container Let’s try to put us in the attacker’s shoes The attacker might want to download more malicious code in to the Container – or say, try to install and start running a miner And he might just use a command like “curl” or “wget” to do so And if this is not a commandline that’s expected in your runtime environment – that might just give you a very critical heads-up that some anomaly has just happened in your Container environment
  5. As we approach the concluding part of the talk, I would want to reiterate that all that we have discussed today are not necessarily limited to just Osquery We can extrapolate the detection mechanisms and apply to any Commercial EDR tool that you might be running or even better , build your own framework and open-source it It’s basically unleashing the power of Open-Source and contribute to it – so that we , as a community, can be a step ahead of the bad guys