1 PDF
1 PDF
S e c t i o n 0 1 | M o d u l e 0 1
© Caendra Inc. 2018
All Rights Reserved
Table of Contents
Module 01 | Incident Handling Process
1.1 Incident Handling Definition & Scope 1.2
Incident Handling
Definition & Scope
1.1.1 Incident Handling Definition
• Packet floods,
NOTE
Incident Handling
Process
1.2 Incident Handling Process
Defensive
Employees Documentation
Measures
1.2.1 Incident Handling Process –Preparation
Defensive
Employees Documentation
Measures
Defensive
Employees Documentation
Measures
•Well-defined policies
1.2.1 Incident Handling Process –Preparation
Defensive
Employees Documentation
Measures
• Well-defined policies
Defensive
Employees Documentation
Measures
• Well-defined policies
• Well-defined response procedures
1.2.1 Incident Handling Process –Preparation
Defensive
Employees Documentation
Measures
• Well-defined policies
• Well-defined response procedures
Based on those, you will decide how you will handle “major” incidents.
• Should the respective cybercrime unit be notified?
• Contain immediately or closely monitor the intruder?
Agreement of the upper-management is required.
1.2.1 Incident Handling Process –Preparation
Defensive
Employees Documentation
Measures
• Well-defined policies
• Well-defined response procedures
• Breach/incident communication plan(s)
• Maintaining a chain of custody of actions
1.2.1 Incident Handling Process –Preparation
Defensive
Employees Documentation
Measures
https://www.wireshark.org/
1.2.2 Incident Handling Process –Detection & Analysis
>> lsof-i:22
• “lsof” scans the process table, this is why it missed the concealed process
and the accompanying open sockets
“netstat” on the other hand, focuses on the open socket list, and only if we
• instruct it (-p flag), it tries to locate the associated processes in the process
table. Regardless of “netstat” finding associated processes or not, it will still
output open sockets.
1.2.2 Incident Handling Process –Detection & Analysis
1. Utilize packet destinations (network perimeter) and identified ports (network and
host perimeter) to identify the running services at the respective host, using internet
resources such as IANA.
Are the identified services actually running and part of your organization?
2.
If not, check for port abuse through resources, such as
3.
https://www.speedguide.net/ports.php, to identify possible malware.
Example: We see a packet trying to reach port 21 of a host, or we see a host listening on port 21.
It could be FTP traffic if our organization includes such functionality or malicious traffic if it doesn’t.
1.2.2 Incident Handling Process –Detection & Analysis
• http://httpd.apache.org/docs/current/logs.html
1.2.2 Incident Handling Process –Detection & Analysis
Short-Term Long-Term
System Back-Up
Containment Containment
Make sure the intruder is locked
Render the intrusion out of the affected host and
ineffective network
1.2.3.1 Incident Handling Process –Before Containment
Incident Classification
Incident Classification
Incident Classification
Incident Classification
Incident Classification
Incident Classification
Incident Classification
Incident Classification
https://www.first.org/resources/guides/csirt_case_classifi
cation.html
1.2.3.1 Incident Handling Process –Before Containment
Incident Communication
Incident Communication
This will ensure that the affected business units will be kept
in the loop.
1.2.3.1 Incident Handling Process –Before Containment
Incident Tracking
•Short-term Containment
• System Back-up
• Long-term Containment
1.2.3.2 Incident Handling Process –Short-term Containment
Data Acquisition
Data Acquisition
Data Acquisition
Data Acquisition
External &
secondary
Registers CPU Cache Ram HDD
storage
devices
1.2.3.3 Incident Handling Process –System Back-Up
Data Acquisition
Dynamic /
Static Acquisition
Live Acquisition
Data Acquisition
Data Acquisition
Data Acquisition
Data Acquisition
Acquisition approaches:
There are two main approaches in which data acquisition
could be performed, each with a different output.
Data Acquisition
Data Acquisition
Such tools are Write Blockers. Write Blockers ensure that data
acquisition is performed without the risk of losing or altering
data.
1.2.3.3 Incident Handling Process –System Back-Up
Data Acquisition
The slightest change to the source file will result in a totally different
hash.
1.2.3.3 Incident Handling Process –System Back-Up
Also, askeverything
includes the business unit to
needed forensure the system
their operations.
1.2.3.6 Incident Handling Process –Recovery
this matter.
1.2.3.6 Incident Handling Process –Recovery
https://www.commandlinefu.com/commands/browsecontains a lot of
commands/one-liners to acquire various system information.
1.2.3 Incident Handling Process –Containment,
Eradication & Recovery
Incident handling was never (and will never be) trivial; this is
exactly why the Post-Incident Activity phase is important.
1.2.4 Incident Handling Process –Post-Incident Activity
This is not to say that the report should contain only the
identified weaknesses, oversights, and blind spots. Working
processes and successful detection methods should also
be included.
Incident Handling
Forms
This form should contain information such as: (one form per affected
system is advised)
•Handler(s) performing investigation on the system
•Was the incident’s root cause discovered?
▪Incident root cause analysis
•Actions taken to ensure the incident’s root cause was remediated
and the possibility of a new incident eliminated
p.133
1.4 Incident Handling Forms
NOTE
p.134
1.5
Appendix
p.135
Appendix
• User Accounts
▪ Identify curious-looking accounts in the Administrators group [use lusrmgr.mscfor GUI access]
▪ Related Command: net user
▪ Related Command: net localgroup administrators
• Processes (focus on those running with high privileges)
▪ Identify abnormal processes [use taskmgr.exefor GUI access]
▪ Related Command:tasklist
▪ Related Command:wmic process list full
▪ Related Command:wmic process get name,parentprocessid,processid
▪ Related Command: wmic process where processid=[pid] get commandline
• Services
▪ Identify abnormal services [use services.mscfor GUI access]
▪ Related Command: net start
▪ Related Command: scquery | more
▪ Related Command (associate running services with processes): tasklist/svc
p.136
Appendix
• Scheduled Tasks (focus on those running with high privileges or look suspicious)
▪ Identify curious-looking scheduled tasks [you can go to Start -> Programs -> Accessories -> System
▪ Tools -> Scheduled Tasks for GUI access to scheduled tasks]
Related Command: schtasks
• Extra Startup Items
▪ Identify users’ autostartfolders
▪ Related Command: dir /s /b "C:\Documents and Settings\[username]\Start Menu\"
▪ Related Command: dir /s /b "C:\Users\[username]\Start Menu\"
• Auto-start Reg Key Entries
▪ Check the below registry keys for malicious autorun configurations [use regedit for GUI access and
inspect both HKLM and HKCU] You can also scrutinize every auto-start location through the Autoruns
MS tool
▪ HKLM\Software\Microsoft\Windows\CurrentVersion\Run
▪ HKLM\Software\Microsoft\Windows\CurrentVersion\Runonce
▪ HKLM\Software\Microsoft\Windows\CurrentVersion\RunonceEx
▪ Related Command: reg query [reg key]
https://docs.microsoft.com/en-us/sysinternals/downloads/autoruns p.137
Appendix
p.139
Appendix
https://docs.microsoft.com/en-us/sysinternals/downloads/process-explorer
https://docs.microsoft.com/en-us/sysinternals/downloads/procmon p.140
Appendix
p.141
Appendix
http://www.chkrootkit.org/
https://github.com/Tripwire/tripwire-open-source
https://sourceforge.net/projects/aide/ p.144
Incident Handling Process
Lab #1
Enterprise-wide Incident
Response: Part 1 -GRR
In this lab, you will learn how to utilize the
GRR Incident Response framework in
order to perform quicker and more
efficient IR activities.
During the lab, you will have the
opportunity to detect (fileless) malware,
various stealthy persistence techniques
and privilege escalation attempts on a
heterogeneous and enterprise-like
network.
*To access, go to the course in your members area and click the labs drop-down in the
appropriate module line or to the virtual labs tabs on the left navigation.
p.145
Incident Handling Process
Lab #2
Enterprise-wide Incident
Response: Part 2 -Velociraptor
In this lab, you will learn how to utilize the
Velociraptor Incident Response
framework in order to perform quicker
and more efficient IR activities.
During the lab, you will have the
opportunity to detect filelessmalware, as
well as leverage specific Velociraptor
capabilities to proactively monitor
endpoints on a heterogeneous and
enterprise-like network.
*To access, go to the course in your members area and click the labs drop-down in the
appropriate module line or to the virtual labs tabs on the left navigation.
p.146
1.6
References
p.147
References
Computer Security Incident Handling Guide by NIST
https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-61r2.pdf
Wireshark
https://www.wireshark.org/
Kernel-level rootkit
http://www.dmi.unipg.it/bista/didattica/sicurezza-pg/seminari2008-
09/seminario_neri/seminario_neri.pdf
p.148
References
IANA
http://www.iana.org/assignments/service-names-port-numbers/service-names-port-
numbers.xhtml
Speed Guide –Port Database
https://www.speedguide.net/ports.php
p.149
References
CSIRT Case Classification (Example for Enterprise CSIRT)
https://www.first.org/resources/guides/csirt_case_classification.html
Canarytokens
http://canarytokens.org/generate
p.150
References
Paging
https://medium.com/@esmerycornielle/memory-management-paging-43b85abe6d2f
Commandlinefu
https://www.commandlinefu.com/commands/browse
Autoruns
https://docs.microsoft.com/en-us/sysinternals/downloads/autoruns
Process Explorer
https://docs.microsoft.com/en-us/sysinternals/downloads/process-explorer
p.151
References
Process Monitor
https://docs.microsoft.com/en-us/sysinternals/downloads/procmon
Chkrookit
http://www.chkrootkit.org/
Tripwire
https://github.com/Tripwire/tripwire-open-source
AIDE
https://sourceforge.net/projects/aide/
*To access, go to the course in your members area and click the labs drop-down in the appropriate module line or
to the virtual labs tabs on the left navigation.
p.153