Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding script to calcuate CAR-like coverage #177

Open
wants to merge 100 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
100 commits
Select commit Hold shift + click to select a range
7d1f069
Bump nokogiri from 1.13.3 to 1.13.6 in /docs
dependabot[bot] May 19, 2022
d928619
Delete implementations directory
alexiacrumpton Jun 10, 2022
006e043
Create updates.md
alexiacrumpton Jun 24, 2022
7de7b1e
Update index.md
alexiacrumpton Jun 24, 2022
47e3fbb
Rename updates.md to index.md
alexiacrumpton Jun 24, 2022
7ba4d38
Update and rename docs/resources/index.md to docs/resources/updates/i…
alexiacrumpton Jun 24, 2022
f8f54cf
Rename docs/Glossary.md to docs/resources/glossary/index.md
alexiacrumpton Jun 24, 2022
1c02e6b
Create index.md
alexiacrumpton Jun 24, 2022
21a1861
Update header.html
alexiacrumpton Jun 24, 2022
257fc5c
Update CAR-2016-04-002.yaml
Ptylu Jul 5, 2022
1d17ce0
Update CAR-2016-04-002.yaml
Ptylu Jul 5, 2022
3457780
Bump tzinfo from 1.2.5 to 1.2.10 in /docs
dependabot[bot] Jul 22, 2022
b48c969
Update file.md
InfiniteInsight Sep 12, 2022
0882ed9
Merge pull request #1 from InfiniteInsight/InfiniteInsight-file-md-fo…
InfiniteInsight Sep 12, 2022
2f2c58a
Create http.md
InfiniteInsight Sep 12, 2022
707eb02
Merge pull request #2 from InfiniteInsight/InfiniteInsight-docs-data_…
InfiniteInsight Sep 12, 2022
0ae783c
Beginning to format document based on car/data_model/ http.yml
InfiniteInsight Sep 12, 2022
04f7456
adding headings and the coverage map table
InfiniteInsight Sep 12, 2022
2049ec3
adjusting table format for coverage map
InfiniteInsight Sep 12, 2022
06f0d71
Merge pull request #3 from InfiniteInsight/http-md-writing
InfiniteInsight Sep 12, 2022
34959d9
fixing like breaks in the coverage map table
InfiniteInsight Sep 13, 2022
a749871
Merge pull request #4 from InfiniteInsight/http-md-writing
InfiniteInsight Sep 13, 2022
0abab47
Update process.md
InfiniteInsight Sep 13, 2022
c16920e
Merge pull request #5 from InfiniteInsight/InfiniteInsight-process.md…
InfiniteInsight Sep 13, 2022
246813d
Bump pillow from 9.0.1 to 9.3.0 in /scripts
dependabot[bot] Nov 22, 2022
d2824f1
Merge pull request #160 from InfiniteInsight/master
alexiacrumpton Nov 22, 2022
54be062
Bump certifi from 2020.12.5 to 2022.12.7 in /scripts
dependabot[bot] Dec 8, 2022
302b402
Merge pull request #156 from mitre-attack/dependabot/bundler/docs/nok…
alexiacrumpton Dec 15, 2022
e6a9a7f
Merge pull request #157 from Ptylu/Ptylu-update-CAR-2016-04-002
alexiacrumpton Dec 15, 2022
3fa6f5b
Merge pull request #158 from mitre-attack/dependabot/bundler/docs/tzi…
alexiacrumpton Dec 15, 2022
8fbf3f3
Merge pull request #162 from mitre-attack/dependabot/pip/scripts/pill…
alexiacrumpton Dec 15, 2022
5c88838
Merge pull request #163 from mitre-attack/dependabot/pip/scripts/cert…
alexiacrumpton Dec 15, 2022
1b3e697
Bump nokogiri from 1.13.6 to 1.13.10 in /docs
dependabot[bot] Dec 15, 2022
66437c5
Update splunk_security_content_to_car.py
alexiacrumpton Dec 16, 2022
65bbaa1
Update splunk_security_content_to_car.py
alexiacrumpton Dec 16, 2022
47f4bc1
Updated Coverage files
alexiacrumpton Dec 30, 2022
26edee5
Updated repo counts
alexiacrumpton Dec 30, 2022
baacbcc
Update index.md
alexiacrumpton Dec 30, 2022
8c5225c
Merge pull request #164 from mitre-attack/dependabot/bundler/docs/nok…
alexiacrumpton Dec 30, 2022
9edfaa1
Update CAR-2016-04-002.yaml
alexiacrumpton Feb 3, 2023
1428226
Handle the case when the by_technique directory wasn't already created
Amndeep7 Feb 4, 2023
bea8e61
Merge pull request #165 from Amndeep7/patch-1
alexiacrumpton Feb 6, 2023
4d95bfa
Moved auditd yaml to /sensors from /docs/sensors and also fixed a str…
Amndeep7 Feb 15, 2023
ad37faa
make generate scripts more robust by adding a dependency warning (sen…
Amndeep7 Feb 15, 2023
7df9d68
automatically regenerate /docs/sensors/index.md and make index.md res…
Amndeep7 Feb 15, 2023
52f84b8
ran generate_analytics
Amndeep7 Feb 15, 2023
888b779
ran generate_attack_nav_layer
Amndeep7 Feb 15, 2023
156185e
ran generate_sensors
Amndeep7 Feb 15, 2023
698ae29
fixed bug where techniques that had no subtechniques were not being l…
Amndeep7 Feb 15, 2023
858bf44
fixed bug where techniques with both technique only CARs and subtechn…
Amndeep7 Feb 15, 2023
4049143
reran generate_analytics to generate a correct by_technique table
Amndeep7 Feb 15, 2023
f9472d0
created workflow to automatically regenerate /docs on every push to m…
Amndeep7 Feb 16, 2023
0c87a55
Make it work on pull request as well
Amndeep7 Feb 19, 2023
f6f2900
change branch
Amndeep7 Feb 19, 2023
4baf5a4
change branch
Amndeep7 Feb 19, 2023
6c0b4c4
hopefully pulls/commits to the fork now
Amndeep7 Feb 20, 2023
dd0f9d7
yaml linting dependencies
Amndeep7 Feb 20, 2023
4c17670
Update regenerate-docs.yml
Amndeep7 Feb 20, 2023
6d2c662
finished linting
Amndeep7 Feb 21, 2023
281e0da
fixed errors in the model yamls
Amndeep7 Feb 21, 2023
d912dd0
fixed yamllint complaints about sensors
Amndeep7 Feb 21, 2023
55cb11f
Revert "fixed yamllint complaints about sensors"
Amndeep7 Feb 21, 2023
17c2e86
module.yaml was out of date from the docs, 'session' was misspelled i…
Amndeep7 Feb 21, 2023
4c7f892
whoops kept some testing text
Amndeep7 Feb 21, 2023
1ff2bfc
typo where 'data_mode' was used instead of 'data_model'
Amndeep7 Feb 21, 2023
47a06b1
added schema matching - schemas based off of the template files, gene…
Amndeep7 Feb 21, 2023
fe53905
a field in the sensor schema should've been optional
Amndeep7 Feb 21, 2023
f3fbf05
run yamllint against the data files, not other yaml files that might …
Amndeep7 Feb 21, 2023
2961ff8
remove an extraneous attribute in the datamodel schema
Amndeep7 Feb 21, 2023
24e3dc9
grabbed cleaned up datamodels from the yaml branch
Amndeep7 Feb 23, 2023
89e10e8
added coverage map attribute and fixed some weird file permissions
Amndeep7 Feb 23, 2023
ad45f84
implemented data model template
Amndeep7 Feb 24, 2023
8ca29c2
changed up whitespace and also used td instead of th
Amndeep7 Feb 24, 2023
a51838f
changed whitespace again and simplified table structure
Amndeep7 Feb 24, 2023
ffac373
trying with th again
Amndeep7 Feb 24, 2023
6937482
wrapped examples with code tags
Amndeep7 Feb 24, 2023
6649d58
fixed tables to actually show the sensors
Amndeep7 Feb 24, 2023
5d01e40
markdown links don't work in html table
Amndeep7 Feb 24, 2023
e7ac755
update references to the glossary's location and also run the redirec…
Amndeep7 Feb 26, 2023
a951c30
made the key of the dict the filename instead of the path since i nev…
Amndeep7 Feb 26, 2023
e4b4a89
generate index file from template
Amndeep7 Feb 26, 2023
0912ea8
generate index with sensors
Amndeep7 Feb 27, 2023
01ff21d
formatting change to fix tables
Amndeep7 Feb 27, 2023
5b9c3a8
use the more modern pathlib instead of path and glob
Amndeep7 Feb 27, 2023
01c9588
Merge pull request #166 from Amndeep7/generate_improvements
alexiacrumpton Feb 27, 2023
fbb3cfc
Merge pull request #167 from Amndeep7/generate_workflow
alexiacrumpton Feb 27, 2023
9a02481
Merge pull request #168 from Amndeep7/yaml
alexiacrumpton Feb 27, 2023
5684c73
Automated commit to rebuild the static site
alexiacrumpton Feb 27, 2023
c8c2314
resolved conflicts
Amndeep7 Feb 27, 2023
581658f
added generate_datamodels to the workflow
Amndeep7 Feb 27, 2023
2e5f456
added coverage field to datamodel schema
Amndeep7 Feb 27, 2023
7abef66
reran generate analytics - just seem to hae changed the order for som…
Amndeep7 Feb 27, 2023
292d191
reran generate sensors - seems to put the data model coverage section…
Amndeep7 Feb 27, 2023
1ac88dc
reran generate nav layer - seems to be a reordering
Amndeep7 Feb 27, 2023
d720756
handle case where data_model directory is removed entirely before reg…
Amndeep7 Feb 27, 2023
9f06a95
reran generate_datamodels - changes to file permissions to not be exe…
Amndeep7 Feb 27, 2023
6a882ac
Automated commit to rebuild the static site
Amndeep7 Feb 27, 2023
50bae40
Merge pull request #170 from Amndeep7/generate_datamodel
alexiacrumpton Feb 27, 2023
84ac9ea
Create detectable_calcuator.py
keepwatch Sep 26, 2023
9d8b6cc
Adding supplement files
keepwatch Sep 26, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
110 changes: 110 additions & 0 deletions .github/workflows/lint-yaml.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
name: Lint the yaml

on:
pull_request_target:
push:
branches: [master]

jobs:
yamllint:
runs-on: ubuntu-latest
steps:
- name: Pull down repo
uses: actions/checkout@v3
- name: Set up python
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
- name: Install script dependencies
run: pip install -r ./scripts/requirements.txt
- name: Run yamllint
run: yamllint analytics/ data_model/ sensors/
analysis-schema:
runs-on: ubuntu-latest
steps:
- name: Pull down repo
uses: actions/checkout@v3
- name: Set up python
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
- name: Install script dependencies
run: pip install -r ./scripts/requirements.txt
- name: Validate against analysis schema
run: yamale -s scripts/analytic_schema.yaml --no-strict analytics/
datamodel-schema:
runs-on: ubuntu-latest
steps:
- name: Pull down repo
uses: actions/checkout@v3
- name: Set up python
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
- name: Install script dependencies
run: pip install -r ./scripts/requirements.txt
- name: Validate against data model schema
run: yamale -s scripts/datamodel_schema.yaml --no-strict data_model/
sensor-schema:
runs-on: ubuntu-latest
steps:
- name: Pull down repo
uses: actions/checkout@v3
- name: Set up python
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
- name: Install script dependencies
run: pip install -r ./scripts/requirements.txt
- name: Validate against sensor schema
run: yamale -s scripts/sensor_schema.yaml --no-strict sensors/
filetype-is-yaml:
runs-on: ubuntu-latest
steps:
- name: Pull down repo
uses: actions/checkout@v3
- name: Files should be .yaml not .yml and should also be actual files (ex. not directories)
shell: bash
run: find analytics data_model sensors -mindepth 1 -maxdepth 1 \( ! -name "*.yaml" \) -o \( ! -type f \)
id-filename-equivalence:
runs-on: ubuntu-latest
steps:
- name: Pull down repo
uses: actions/checkout@v3
- name: Analytics files need to have their filename be '{id}.yaml'
run: >
ret=0;
for file in analytics/*.yaml; do
echo "Checking $file";
if ! [ "$(basename $file | sed -e "s/\.yaml$//")" = "$(yq '.id' < $file)" ]; then
echo "Failed";
ret=1;
fi;
done;
exit "$ret"
- name: Data model files need to have their filename be '{name but fully lowercase and with underscores replacing spaces}.yaml'
run: >
ret=0;
for file in data_model/*.yaml; do
echo "Checking $file";
if ! [ "$(basename $file | sed -e "s/\.yaml$//")" = "$(yq '.name | downcase | sub(" ", "_")' < $file)" ]; then
echo "Failed";
ret=1;
fi;
done;
exit "$ret"
- name: Sensor files need to have their filename be '{sensor_name but fully lowercase}_{sensor_version}.yaml'
run: >
ret=0;
for file in sensors/*.yaml; do
echo "Checking $file";
if ! [ "$(basename $file | sed -e "s/\.yaml$//")" = "$(yq '(.sensor_name | downcase) + "_" + .sensor_version' < $file)" ]; then
echo "Failed";
ret=1;
fi;
done;
exit "$ret"
53 changes: 53 additions & 0 deletions .github/workflows/regenerate-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Regenerate /docs using the generate_*.py scripts

on:
pull_request_target:
push:
branches: [master]

jobs:
regenerate:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Pull down repo
uses: actions/checkout@v3
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.head_ref }}
- name: Clean /docs/data_model
shell: bash
run: rm -rfv ./docs/data_model
- name: Clean /docs/analytics
shell: bash
run: rm -rfv ./docs/analytics
- name: Clean /docs/sensors
shell: bash
run: rm -rfv ./docs/sensors
- name: Set up python
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
- name: Install script dependencies
run: pip install -r ./scripts/requirements.txt
- name: Regenerate datamodels
working-directory: ./scripts
run: python generate_datamodels.py
- name: Regenerate analytics
working-directory: ./scripts
run: python generate_analytics.py
- name: Regenerate sensors
working-directory: ./scripts
run: python generate_sensors.py
- name: Regenerate attack nav layer
working-directory: ./scripts
run: python generate_attack_nav_layer.py
- name: Commit new static site
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: 'Automated commit to rebuild the static site'
commit_options: '--signoff'
commit_user_name: 'Build and Push Automation Script'
commit_user_email: '<>'
5 changes: 5 additions & 0 deletions .yamllint
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
extends: default

rules:
line-length: disable
3 changes: 2 additions & 1 deletion analytics/CAR-2013-01-002.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Autorun Differences
submission_date: 2013/01/25
information_domain: 'Analytic, Host'
Expand All @@ -11,7 +12,7 @@ analytic_types:
contributors:
- MITRE
id: CAR-2013-01-002
description: |-
description: |
The Sysinternals tool [Autoruns](../sensors/autoruns) checks the registry and file system for known identify persistence mechanisms. It will output any tools identified, including built-in or added-on Microsoft functionality and third party software. Many of these locations are known by adversaries and used to obtain [Persistence](https://attack.mitre.org/tactics/TA0003). Running Autoruns periodically in an environment makes it possible to collect and monitor its output for differences, which may include the removal or addition of persistent tools. Depending on the persistence mechanism and location, legitimate software may be more likely to make changes than an adversary tool. Thus, this analytic may result in significant noise in a highly dynamic environment. While Autoruns is a convenient method to scan for programs using persistence mechanisms its scanning nature does not conform well to streaming based analytics. This analytic could be replaced with one that draws from sensors that collect registry and file information if streaming analytics are desired.

Utilizes the Sysinternals autoruns tool (ignoring validated Microsoft entries). Primarily not a detection analytic by itself but through analysis of results by an analyst can be used for such. Building another analytic on top of this one identifying unusual entries would likely be a beneficial alternative.
Expand Down
9 changes: 5 additions & 4 deletions analytics/CAR-2013-01-003.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: SMB Events Monitoring
submission_date: 2013/01/25
information_domain: Network
Expand All @@ -10,8 +11,8 @@ analytic_types:
contributors:
- MITRE
id: CAR-2013-01-003
description: |-
[Server Message Block](https://en.wikipedia.org/wiki/Server_Message Block) (SMB) is used by Windows to allow for file, pipe, and printer sharing over port 445/tcp. It allows for enumerating, and reading from and writing to file shares for a remote computer. Although it is heavily used by Windows servers for legitimate purposes and by users for file and printer sharing, many adversaries also use SMB to achieve [Lateral Movement](https://attack.mitre.org/tactics/TA0008). Looking at this activity more closely to obtain an adequate sense of situational awareness may make it possible to detect adversaries moving between hosts in a way that deviates from normal activity. Because SMB traffic is heavy in many environments, this analytic may be difficult to turn into something that can be used to quickly detect an APT. In some cases, it may make more sense to run this analytic in a forensic fashion. Looking through and filtering its output after an intrusion has been discovered may be helpful in identifying the scope of compromise.
description: |
[Server Message Block](https://en.wikipedia.org/wiki/Server_Message Block) (SMB) is used by Windows to allow for file, pipe, and printer sharing over port 445/tcp. It allows for enumerating, and reading from and writing to file shares for a remote computer. Although it is heavily used by Windows servers for legitimate purposes and by users for file and printer sharing, many adversaries also use SMB to achieve [Lateral Movement](https://attack.mitre.org/tactics/TA0008). Looking at this activity more closely to obtain an adequate sense of situational awareness may make it possible to detect adversaries moving between hosts in a way that deviates from normal activity. Because SMB traffic is heavy in many environments, this analytic may be difficult to turn into something that can be used to quickly detect an APT. In some cases, it may make more sense to run this analytic in a forensic fashion. Looking through and filtering its output after an intrusion has been discovered may be helpful in identifying the scope of compromise.

### Output Description

Expand All @@ -28,8 +29,8 @@ coverage:
- T1021.002
coverage: Moderate
implementations:
- description: 'Although there may be more native ways to detect detailed SMB events on the host, they can be extracted out of network traffic. With the right protocol decoders, port 445 traffic can be filtered and even the file path (relative to the share) can be retrieved. '
code: |-
- description: 'Although there may be more native ways to detect detailed SMB events on the host, they can be extracted out of network traffic. With the right protocol decoders, port 445 traffic can be filtered and even the file path (relative to the share) can be retrieved.'
code: |
flow = search Flow:Message
smb_events = filter flow where (dest_port == "445" and protocol == "smb")
smb_events.file_name = smb_events.proto_info.file_name
Expand Down
1 change: 1 addition & 0 deletions analytics/CAR-2013-02-003.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Processes Spawning cmd.exe
submission_date: 2013/02/05
information_domain: Host
Expand Down
7 changes: 4 additions & 3 deletions analytics/CAR-2013-02-008.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Simultaneous Logins on a Host
submission_date: 2013/02/18
information_domain: Host
Expand All @@ -12,7 +13,7 @@ analytic_types:
contributors:
- MITRE
id: CAR-2013-02-008
description: |-
description: |
Multiple users logged into a single machine at the same time, or even within the same hour, do not typically occur in networks we have observed.

Logon events are Windows Event Code 4624 for Windows Vista and above, 518 for pre-Vista. Logoff events are 4634 for Windows Vista and above, 538 for pre-Vista.
Expand All @@ -26,10 +27,10 @@ coverage:
- T1078.003
coverage: Low
implementations:
- code: |-
- code: |
users_list = search UserSession:Login
users_grouped = group users_list by hostname
users_grouped = from users_grouped select min(time) as earliest_time, max(time) as latest_time count(user) as user_count
users_grouped = from users_grouped select min(time) as earliest_time, max(time) as latest_time count(user) as user_count
multiple_logins = filter users_grouped where (latest_time - earliest_time <= 1 hour and user_count > 1)
output multiple_logins
type: pseudocode
Expand Down
7 changes: 4 additions & 3 deletions analytics/CAR-2013-02-012.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: User Logged in to Multiple Hosts
submission_date: 2013/02/27
information_domain: Host
Expand All @@ -12,7 +13,7 @@ analytic_types:
contributors:
- MITRE
id: CAR-2013-02-012
description: |-
description: |
Most users use only one or two machines during the normal course of business. User accounts that log in to multiple machines, especially over a short period of time, may be compromised. Remote logins among multiple machines may be an indicator of [Lateral Movement](https://attack.mitre.org/tactics/TA0008).

Certain users will likely appear as being logged into several machines and may need to be "whitelisted." Such users would include network admins or user names that are common to many hosts.
Expand All @@ -25,8 +26,8 @@ coverage:
tactics:
- TA0008
subtechniques:
- T1078.002
- T1078.003
- T1078.002
- T1078.003
coverage: Moderate
d3fend_mappings:
- iri: d3f:AuthenticationEventThresholding
Expand Down
7 changes: 4 additions & 3 deletions analytics/CAR-2013-03-001.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Reg.exe called from Command Shell
submission_date: 2013/03/28
information_domain: Host
Expand All @@ -10,7 +11,7 @@ analytic_types:
contributors:
- MITRE
id: CAR-2013-03-001
description: |-
description: |
Registry modifications are often essential in establishing persistence via known Windows mechanisms. Many legitimate modifications are done graphically via `regedit.exe` or by using the corresponding channels, or even calling the Registry APIs directly. The built-in utility `reg.exe` provides a [command-line interface](https://en.wikipedia.org/wiki/Command-line_interface) to the registry, so that queries and modifications can be performed from a shell, such as `cmd.exe`. When a user is responsible for these actions, the parent of `cmd.exe` will likely be `explorer.exe`. Occasionally, power users and administrators write scripts that do this behavior as well, but likely from a different process tree. These background scripts must be learned so they can be tuned out accordingly.

### Output Description
Expand Down Expand Up @@ -45,15 +46,15 @@ coverage:
coverage: Moderate
implementations:
- description: 'To gain better context, it may be useful to also get information about the cmd process to know its parent. This may be helpful when tuning the analytic to an environment, if this behavior happens frequently. This may also help to rule out instances of users running '
code: |-
code: |
processes = search Process:Create
reg = filter processes where (exe == "reg.exe" and parent_exe == "cmd.exe")
cmd = filter processes where (exe == "cmd.exe" and parent_exe != "explorer.exe"")
reg_and_cmd = join (reg, cmd) where (reg.ppid == cmd.pid and reg.hostname == cmd.hostname)
output reg_and_cmd
type: pseudocode
- description: DNIF version of the above pseudocode.
code: |-
code: |
_fetch * from event where $LogName=WINDOWS-SYSMON AND $EventID=1 AND $Process=regex(.*reg\.exe.*)i AND $ParentProcess=regex(.*cmd\.exe.*)i as #A limit 100
>>_fetch * from event where $LogName=WINDOWS-SYSMON AND $EventID=1 AND $Process=regex(.*cmd\.exe.*)i NOT $ParentProcess=regex(.*explorer\.exe.*)i as #B limit 100
>>_checkif sjoin #B.$PPID = #A.$CPID str_compare #B.$SystemName eq #A.$SystemName include
Expand Down
1 change: 1 addition & 0 deletions analytics/CAR-2013-04-002.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Quick execution of a series of suspicious commands
submission_date: 2013/04/11
information_domain: 'Analytic, Host'
Expand Down
1 change: 1 addition & 0 deletions analytics/CAR-2013-05-002.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Suspicious Run Locations
submission_date: 2013/05/07
information_domain: Host
Expand Down
3 changes: 2 additions & 1 deletion analytics/CAR-2013-05-003.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: SMB Write Request
submission_date: 2013/05/13
information_domain: 'Host, Network'
Expand Down Expand Up @@ -35,7 +36,7 @@ coverage:
- T1078.003
coverage: Moderate
implementations:
- code: |-
- code: |
flow = search Flow:Message
smb_write = filter flow where (dest_port == "445" and protocol == "smb.write")
smb_write.file_name = smb_write.proto_info.file_name
Expand Down
1 change: 1 addition & 0 deletions analytics/CAR-2013-05-004.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Execution with AT
submission_date: 2013/05/13
information_domain: Host
Expand Down
1 change: 1 addition & 0 deletions analytics/CAR-2013-05-005.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: SMB Copy and Execution
submission_date: 2013/05/13
information_domain: 'Host, Network'
Expand Down
1 change: 1 addition & 0 deletions analytics/CAR-2013-05-009.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Running executables with same hash and different names
submission_date: 2013/05/23
information_domain: Host
Expand Down
1 change: 1 addition & 0 deletions analytics/CAR-2013-07-001.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Suspicious Arguments
submission_date: 2013/07/05
information_domain: Host
Expand Down
1 change: 1 addition & 0 deletions analytics/CAR-2013-07-002.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: RDP Connection Detection
submission_date: 2013/07/24
information_domain: 'Analytic, Network'
Expand Down
9 changes: 5 additions & 4 deletions analytics/CAR-2013-07-005.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
title: Command Line Usage of Archiving Software
submission_date: 2013/07/31
information_domain: Host
Expand All @@ -12,7 +13,7 @@ analytic_types:
contributors:
- MITRE
id: CAR-2013-07-005
description: |-
description: |
Before [exfiltrating data](https://attack.mitre.org/tactics/TA0010) that an adversary has [collected](https://attack.mitre.org/tactics/TA0009), it is very likely that a [compressed archive](https://attack.mitre.org/techniques/T1560) will be created, so that transfer times are minimized and fewer files are transmitted. There is variety between the tools used to compress data, but the command line usage and context of archiving tools, such as ZIP, RAR, and 7ZIP, should be monitored.

In addition to looking for RAR or 7z program names, command line usage of 7Zip or RAR can be detected with the flag usage of "`\* a \*`". This is helpful, as adversaries may change program names.
Expand All @@ -25,18 +26,18 @@ coverage:
coverage: Moderate
implementations:
- description: 'This analytic looks for the command line argument `a`, which is used by RAR. However, there may be other programs that have this as a legitimate argument and may need to be filtered out.'
code: |-
code: |
processes = search Process:Create
rar_argument = filter processes where (command_line == "* a *")
output rar_argument
type: pseudocode
- description: DNIF version of the above pseudocode.
code: |-
code: |
_fetch * from event where $LogName=WINDOWS-SYSMON AND $EventID=1 AND $Process=regex(.* a .*)i limit 100
type: DNIF
data_model: Sysmon native
- description: LogPoint version of the above pseudocode.
code: |-
code: |
norm_id=WindowsSysmon event_id=1 command="* a *"
type: LogPoint
data_model: LogPoint native
Expand Down
Loading