Allow root user to run 'T1087.001: Account Discovery: Local Account - List opened files by user' by updating how current username is determined

This commit is contained in:
Tyler Fisher
2020-11-19 11:18:53 -05:00
parent d0b51ff08a
commit de1bd5a20f
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -146,7 +146,7 @@ List opened files by user
```sh
username=$(echo $HOME | awk -F'/' '{print $3}') && lsof -u $username
username=$(id -u -n) && lsof -u $username
```
+1 -1
View File
@@ -68,7 +68,7 @@ atomic_tests:
- macos
executor:
command: |
username=$(echo $HOME | awk -F'/' '{print $3}') && lsof -u $username
username=$(id -u -n) && lsof -u $username
name: sh
- name: Show if a user account has ever logged in remotely
auto_generated_guid: 0f0b6a29-08c3-44ad-a30b-47fd996b2110