Skip to content

Commit 522acbe

Browse files
authored
Merge pull request #287 from tclahr/release/3.0.0
Release/3.0.0
2 parents 2647c12 + 0ea594f commit 522acbe

File tree

409 files changed

+7870
-6811
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

409 files changed

+7870
-6811
lines changed

.github/workflows/shellcheck.yaml

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,27 @@
11
name: ShellCheck
22

33
on:
4-
push:
5-
branches:
6-
- develop
7-
- main
8-
- 'releases/**'
9-
paths:
10-
- 'lib/**'
11-
- 'tools/**'
12-
- 'uac'
13-
144
pull_request:
155
branches:
166
- develop
177
- main
18-
- 'releases/**'
198
paths:
209
- 'lib/**'
21-
- 'tools/**'
2210
- 'uac'
2311

2412
# Allows you to run this workflow manually from the Actions tab
2513
workflow_dispatch:
2614

2715
jobs:
28-
shellcheck:
16+
build:
2917
name: ShellCheck
3018
runs-on: ubuntu-latest
3119

3220
steps:
3321
- name: Clone uac repo
34-
uses: actions/checkout@v3
22+
uses: actions/checkout@v4
3523
with:
3624
path: uac
3725

3826
- name: Run ShellCheck
3927
uses: ludeeus/action-shellcheck@master
40-
with:
41-
ignore_paths: artifacts bin config profiles
42-

.github/workflows/unit-testing.yaml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Unit testing
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- develop
7+
- main
8+
paths:
9+
- 'lib/**'
10+
- 'uac'
11+
12+
# Allows you to run this workflow manually from the Actions tab
13+
workflow_dispatch:
14+
15+
jobs:
16+
build:
17+
name: Unit testing
18+
runs-on: ubuntu-latest
19+
20+
steps:
21+
- name: Checkout uac repository
22+
uses: actions/checkout@v4
23+
with:
24+
repository: tclahr/uac
25+
path: uac
26+
27+
- name: Checkout ushunit repository
28+
uses: actions/checkout@v4
29+
with:
30+
repository: tclahr/ushunit
31+
ref: main
32+
path: ushunit
33+
34+
- name: Checkout uac-tests repository
35+
uses: actions/checkout@v4
36+
with:
37+
repository: tclahr/uac-tests
38+
ref: ${{ github.event.pull_request.base.ref }}
39+
path: uac-tests
40+
41+
- name: Run tests
42+
working-directory: ushunit
43+
run: |
44+
UAC_DIR="../uac" ./ushunit -i ../uac-tests/tests/lib/*.sh ../uac-tests/tests/*.sh

.github/workflows/validate-artifacts-file.yaml

Lines changed: 0 additions & 41 deletions
This file was deleted.
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Validate Artifacts
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- develop
7+
- main
8+
paths:
9+
- 'artifacts/**'
10+
11+
# Allows you to run this workflow manually from the Actions tab
12+
workflow_dispatch:
13+
14+
jobs:
15+
validate-artifact-files:
16+
name: Validate Artifacts
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- name: Clone uac repo
21+
uses: actions/checkout@v4
22+
with:
23+
path: uac
24+
25+
- name: Validate Artifacts
26+
working-directory: uac
27+
run: |
28+
find artifacts/* -name "*.yaml" -type f \
29+
| while read file || [ -n "${file}" ]; do
30+
./uac --validate-artifact "${file}"
31+
done
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Validate Profiles
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- develop
7+
- main
8+
paths:
9+
- 'profiles/**'
10+
11+
# Allows you to run this workflow manually from the Actions tab
12+
workflow_dispatch:
13+
14+
jobs:
15+
validate-profile-files:
16+
name: Validate Profiles
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- name: Clone uac repo
21+
uses: actions/checkout@v4
22+
with:
23+
path: uac
24+
25+
- name: Validate Profiles
26+
working-directory: uac
27+
run: |
28+
find profiles/* -name "*.yaml" -type f \
29+
| while read file || [ -n "${file}" ]; do
30+
./uac --validate-profile "${file}"
31+
done
32+

CHANGELOG.md

Lines changed: 109 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,116 @@
11
# Changelog
22

3-
## 2.9.1 (2024-06-12)
3+
## 3.0.0 (2024-10-22)
44

5-
### Fixes
5+
### Features
66

7-
- live_response/containers/docker.yaml: Fixed docker stats command that was running in a loop and therefore the program was not terminating [linux] (by [0xtter](https://github.com/0xtter)).
8-
- live_response/containers/podman.yaml: Fixed docker stats command that was running in a loop and therefore the program was not terminating [linux].
7+
- New '--enable-modifiers' command line option. Enabling this option will case UAC to run artifacts that change the current system state ([#272](https://github.com/tclahr/uac/issues/272)).
8+
- UAC now completely skips an artifact file (YAML) that has no artifacts to be collected for the target operating system. You can use '--artifacts list [OPERATING_SYSTEM]' to display artifacts for a specific operating system only.
9+
- New output file formats:
10+
- none: Collected data will not be archived or compressed. Instead, it will be copied directly to an output directory ([#188](https://github.com/tclahr/uac/issues/188)).
11+
- zip: Collected data will be archived and compressed into a zip file. Additionally, you can create a password-protected zip file using the '--output-password' option ([#149](https://github.com/tclahr/uac/issues/149)).
12+
- You can now set a custom output file name using the '-o/--output-base-name' command line option. Variables are available to format the filename ([#179](https://github.com/tclahr/uac/issues/179)).
13+
- Now you have the option to supply a file path to a custom profile located outside the profiles directory.
14+
- Now you have the option to supply a file path to a custom artifact located outside the artifacts directory ([#154](https://github.com/tclahr/uac/issues/154)).
15+
- Now you can have the option to supply a file path to a custom config file located outside the config directory using the '-c/--config' command line option.
16+
- New remote transfer options for Amazon, Google and IBM cloud storage locations.
17+
- UAC will now use 'wget' to transfer files to remote cloud storage locations when 'curl' is not available.
18+
- You can now increase the verbosity level using the '-v/--verbose' command line option. Enabling a higher verbosity level will result in the display of all executed commands.
19+
- UAC will now use the built-in function 'astrings' to extract strings from binary files when 'strings' is not available on the system.
20+
- The message 'The strings command requires the command line developer tools.' will no longer appear on macOS systems without developer tools installed ([#171](https://github.com/tclahr/uac/issues/171)).
21+
- Error messages generated by executed commands (stderr) are now recorded in the uac.log file ([#150](https://github.com/tclahr/uac/issues/150)).
22+
- New '-H/--hash-collected' command line option. Enabling this option will cause UAC to hash all collected files and save the results in a hash file. To accomplish this, all collected data must first be copied to the destination directory. Therefore, ensure you have twice the free space available on the system: once for the collected data and once for the output file. Additionally, note that this process will increase the running time ([#189](https://github.com/tclahr/uac/issues/189)).
23+
- You can now validate profiles using the '--validate-profile' command line option.
924

1025
### Artifacts
1126

12-
- files/shell/history.yaml: Added collection support for *.historynew files [all].
13-
- files/shell/sessions.yaml: Added collection support for *.session files [all] [randomaccess3](https://github.com/randomaccess3))
27+
- bodyfile/bodyfile.yaml: Updated to remove max_depth limit.
28+
- files/applications/git.yaml: Added collection of files that can be used to run persistence [linux, macos] ([mnrkbys](https://github.com/mnrkbys)).
29+
- files/applications/lesshst.yaml: Added less history file (.lesshst) collection [aix, freebsd, linux, macos, netbsd, netscaler, openbsd, solaris] ([mnrkbys](https://github.com/mnrkbys)).
30+
- files/applications/whatsapp.yaml: Added collection of WhatsApp Desktop files [macos].
31+
- files/logs/additional_logs.yaml: Artifact was renamed to advanced_log_search.yaml.
32+
- files/logs/relink.yaml: Added collection of the kernel relink log file [openbsd] ([Herbert-Karl](https://github.com/Herbert-Karl)).
33+
- files/logs/run_log.yaml: Added collection of /run/log directory.
34+
- files/packages/apt.yaml: Add artifacts to collect package manager plugins/scripts [linux] ([mnrkbys](https://github.com/mnrkbys)).
35+
- files/packages/dnf.yaml: Add artifacts to collect package manager plugins/scripts [linux] ([mnrkbys](https://github.com/mnrkbys)).
36+
- files/packages/pkg_contents.yaml: Updated to collect FreeBSD installed packages database [freebsd] ([Herbert-Karl](https://github.com/Herbert-Karl)).
37+
- files/packages/yum.yaml: Add artifacts to collect package manager plugins/scripts [linux] ([mnrkbys](https://github.com/mnrkbys)).
38+
- files/system/acct.yaml: Added collection of system accounting files [freebsd, netbsd, openbsd] ([Herbert-Karl](https://github.com/Herbert-Karl)).
39+
- files/system/acct.yaml: Updated to collect system accounting files [solaris] ([sec-hbaer](https://github.com/sec-hbaer)).
40+
- files/system/dev_db.yaml: Added collection of the database file used for device lookups [netbsd, openbsd] ([Herbert-Karl](https://github.com/Herbert-Karl)).
41+
- files/system/dev_shm.yaml: Updated to increase max_file_size to 10MB.
42+
- files/system/locate_db.yaml: Added collection of the database file used by locate command, representing a snapshot of the virtual file system accessible with minimal permissions [freebsd, netbsd, openbsd] ([Herbert-Karl](https://github.com/Herbert-Karl)).
43+
- files/system/netscaler.yaml: Updated to increase max_file_size to 10MB.
44+
- files/system/run_shm.yaml: Updated to increase max_file_size to 10MB.
45+
- files/system/security_backups.yaml: Added collection of file backups and hashes created by the integrated security script [freebsd, netbsd, openbsd] ([Herbert-Karl](https://github.com/Herbert-Karl)).
46+
- files/system/systemd.yaml: Updated to add new locations for configuration files.
47+
- files/system/tmp.yaml: Updated to increase max_file_size to 10MB.
48+
- files/system/udev.yaml: Added collection of udev rule files ([mnrkbys](https://github.com/mnrkbys)).
49+
- files/system/var_tmp.yaml: Updated to increase max_file_size to 10MB.
50+
- hash_executables/hash_executables.yaml: Updated to remove max_depth and max_file_size properties.
51+
- live_response/containers/jls.yaml: Added collection of jails used on FreeBSD systems [freebsd] ([Herbert-Karl](https://github.com/Herbert-Karl)).
52+
- live_response/hardware/dmesg.yaml: Updated collection of console message bufffer [esxi, freebsd, netscaler, openbsd, solaris] ([Herbert-Karl](https://github.com/Herbert-Karl)).
53+
- live_response/modifiers/revel_hidden_processes.yaml: Added command to umount filesystems mounted onto a directory that tipically corresponds to a process ID (PID) [linux] ([halpomeranz](https://github.com/halpomeranz)).
54+
- live_response/network/procfs_information.yaml: Added collection of TCP and UDP network details from /proc/net [linux].
55+
- live_response/process/deleted.yaml: Collection of deleted processes will no longer use dd conv=swab. The binary file will be collected in its raw format now [linux].
56+
- live_response/process/deleted.yaml: Updated to fix the collection of open files of (malicious) processes [linux] ([mnrkbys](https://github.com/mnrkbys)).
57+
- live_response/process/hash_running_processes.yaml: Updated to add support to hash running processes on FreeBSD systems that are using procfs (/proc) [freebsd].
58+
- live_response/process/procfs_information.yaml: Added artifact collection using cat when strings is not available.
59+
- live_response/process/procfs_information.yaml: Updated to collect /proc/*/mount [linux] ([halpomeranz](https://github.com/halpomeranz)).
60+
- live_response/process/procfs_information.yaml: Updated to collect /proc/*/stat [linux] ([mnrkbys](https://github.com/mnrkbys)).
61+
- live_response/process/strings_running_processes.yaml: Added collection of strings from running processes for ESXi systems [esxi].
62+
- live_response/process/strings_running_processes.yaml: Added condition to check whether developer tools are installed before running strings on macOS [macos].
63+
- live_response/process/strings_running_processes.yaml: Added support for collecting strings even when the strings command is unavailable. In such cases, the built-in astrings command will be used instead [all].
64+
- live_response/storage/btrfs.yaml: Added collection of btrfs mountpoints, subvolumes and snapshots information [linux] ([mnrkbys](https://github.com/mnrkbys)).
65+
- live_response/system/acctadm.yaml: Added collection of configuration for extended accounting [solaris] ([sec-hbaer](https://github.com/sec-hbaer)).
66+
- live_response/system/acctcom.yaml: Added collection of the last commands executed in a reverse order based on the default and historic accounting files [solaris] ([sec-hbaer](https://github.com/sec-hbaer)).
67+
- live_response/system/bpftool.yaml: Added eBPF programs information collection using bpftool [linux] ([mnrkbys](https://github.com/mnrkbys)).
68+
- live_response/system/hidden_directories.yaml: Updated to remove max_depth limit.
69+
- live_response/system/hidden_files.yaml: Updated to remove max_depth limit.
70+
- live_response/system/kernel_tainted_state.yaml: Added collection of dmesg messages showing modules tainting the kernel [linux].
71+
- live_response/system/lastcomm.yaml: Added collection of the last commands executed in a reverse order based on the default and historic accounting file [freebsd, netbsd, openbsd] ([Herbert-Karl](https://github.com/Herbert-Karl)).
72+
- live_response/system/lastcomm.yaml: Updated to collect the last commands executed in a reverse order based on the extended accounting file [solaris] ([sec-hbaer](https://github.com/sec-hbaer)).
73+
- live_response/system/sgid.yaml: Updated to remove max_depth limit.
74+
- live_response/system/socket_files.yaml: Updated to remove max_depth limit.
75+
- live_response/system/suid.yaml: Updated to remove max_depth limit.
76+
- live_response/system/sys_modules.yaml: Removed as it is was duplicate artifact with kernel_modules.yaml.
77+
- live_response/system/world_writable_directories.yaml: Updated to remove max_depth limit.
78+
- live_response/system/world_writable_files.yaml: Updated to remove max_depth limit.
79+
- live_response/system/zoneadm.yaml: Artifact was moved to live_response/containers directory ([Herbert-Karl](https://github.com/Herbert-Karl)).
80+
81+
### Profiles
82+
83+
- files/applications/git.yaml, files/applications/lesshst.yaml, files/applications/viminfo.yaml, and files/applications/wget.yaml artifacts were added to the 'ir_triage' profile.
84+
85+
### Command Line Option Changes
86+
87+
- '--date-range-start' was renamed to '--start-date' ([#186](https://github.com/tclahr/uac/issues/186)).
88+
- '--date-range-end' was renamed to '--end-date' ([#186](https://github.com/tclahr/uac/issues/186)).
89+
- '--validate-artifacts-file' was renamed to '--validate-artifact'.
90+
- '--s3-presigned-url' was renamed to '--aws-s3-presigned-url'.
91+
- '--s3-presigned-url-log-file' was renamed to '--aws-s3-presigned-url-log-file'.
92+
- '--ibm-cos-url', '--ibm-cos-url-log-file' and '--ibm-cloud-api-key' were removed and now transfers to IBM cloud should be done using '--s3-provider', '--s3-region', '--s3-bucket' and '--s3-token' options.
93+
94+
### Artifacts Properties Changes
95+
96+
- Introduced a new global 'modifier' property that ensures the artifact runs only if '--enable-modifiers' command line option is used.
97+
- Introduced a new 'condition' property that ensures the collection runs only if the specified condition returns true.
98+
- The 'output_directory' property is now mandatory for the following collectors: command, find, hash and stat.
99+
- The 'file_type' property is now an array.
100+
- The 'permissions' property is now an array.
101+
102+
### uac.conf
103+
104+
- Introduced a new global 'max_depth' configuration option to limit the depth of directory tree searches globally.
105+
106+
### Tools
107+
108+
- Statically linked 'zip' is now available for the following systems:
109+
- linux/esxi (arm, arm64, i386 and x86_64)
110+
- freebsd/netscaler (i386 and x86_64)
111+
- 'avml' and 'linux_procmemdump.sh' tools were moved to the 'bin' directory.
112+
- AVML updated to v0.14.0.
113+
114+
### Deprecated
115+
116+
- Android support was removed, but UAC can still be executed on Android systems using '--operating-system linux' option.

CODE_OF_CONDUCT.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,4 +79,4 @@ To report incidents or to appeal reports of incidents, send email to iplsdk@linu
7979

8080
## Credits
8181

82-
This code is based on the [Hyperledger Project's CoC](https://github.com/hyperledger/hyperledger/wiki/Hyperledger-Project-Code-of-Conduct), [W3Cs Code of Ethics and Professional Conduct](https://www.w3.org/Consortium/cepc) with some additions from the [Cloud Foundry](https://www.cloudfoundry.org/)‘s Code of Conduct.
82+
This code is based on the [Hyperledger Project's CoC](https://github.com/hyperledger/hyperledger/wiki/Hyperledger-Project-Code-of-Conduct), [W3C's Code of Ethics and Professional Conduct](https://www.w3.org/Consortium/cepc) with some additions from the [Cloud Foundry](https://www.cloudfoundry.org/)‘s Code of Conduct.

CONTRIBUTING.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ Here are a couple of things we are looking for help with:
88

99
## New artifacts
1010

11-
Have you identified a new artifact that is still not collected by UAC? Please create a new artifact file and submit it via a new Pull Request.
11+
Have you identified a new artifact that is still not collected by UAC? Please create a new artifact and submit it via a new Pull Request.
1212

13-
Please see [Artifacts file definition](https://tclahr.github.io/uac-docs/latest/artifacts_file/) docs for more information.
13+
Please see [Artifacts definition](https://tclahr.github.io/uac-docs/artifacts/) docs for more information.
1414

1515
## New features
1616

17-
You can request a new feature by submitting an issue to our GitHub Repository. If you would like to implement a new feature, please submit an issue with a proposal for your work first, to be sure that we can use it. This will also allow us to better coordinate our efforts, prevent duplication of work, and help you to craft the change so that it is successfully accepted into the project.
17+
You can request a new feature by submitting an issue to our GitHub Repository. If you would like to implement a new feature, please submit an issue with a proposal for your work first, to be sure that we can use it. This will also allow us to better coordinate our efforts, prevent duplication of work, and help you craft the change so that it is successfully accepted into the project.
1818

1919
## Found a bug?
2020

@@ -84,9 +84,9 @@ git checkout -b my-feature-branch develop
8484

8585
1. Create your code following our [Coding Rules](#coding-rules).
8686

87-
1. Test your code against as many systems as you can using the [uac-unit-test](https://github.com/tclahr/uac-unit-test). For instance, your code can fully work on a Linux but not on a FreeBSD system.
87+
1. Test your code against as many systems as you can. For instance, your code can fully work on a Linux but not on a FreeBSD system.
8888

89-
1. Commit your changes using a descriptive commit message that follows our [commit message guidelines](#commit-message-guidelines). *Dont commit code as an unrecognized author. Having commits with unrecognized authors makes it more difficult to track who wrote which part of the code. Ensure your Git client is configured with the correct email address and linked to your GitHub user.*
89+
1. Commit your changes using a descriptive commit message that follows our [commit message guidelines](#commit-message-guidelines). *Don't commit code as an unrecognized author. Having commits with unrecognized authors makes it more difficult to track who wrote which part of the code. Ensure your Git client is configured with the correct email address and linked to your GitHub user.*
9090

9191
```shell
9292
git commit -s

LICENSE

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
Apache License
32
Version 2.0, January 2004
43
http://www.apache.org/licenses/

0 commit comments

Comments
 (0)