Skip to content

linux: pslist: fix task credentials rendering#1551

Merged
ikelos merged 1 commit intovolatilityfoundation:developfrom
gcmoreira:linux_fix_pslist_task_credentials
Jan 17, 2025
Merged

linux: pslist: fix task credentials rendering#1551
ikelos merged 1 commit intovolatilityfoundation:developfrom
gcmoreira:linux_fix_pslist_task_credentials

Conversation

@gcmoreira
Copy link
Contributor

Currently, when the user id is zero, typically root, we are incorrectly using the BaseAbsentValue resulting in a Hyphen - being displayed in each ID column.

This PR fixes this issue. New output:

$ ./vol.py -r pretty \
    -f ./linux-sample-1.bin \
    linux.pslist 
Volatility 3 Framework 2.16.0
  |     OFFSET (V) |  PID |  TID | PPID |            COMM |  UID |   GID | EUID |  EGID |                  CREATION TIME | File output
* | 0x88001f994740 |    1 |    1 |    0 |            init |    0 |     0 |    0 |     0 | 2014-06-24 10:22:33.016001 UTC |    Disabled
* | 0x88001f994040 |    2 |    2 |    0 |        kthreadd |    0 |     0 |    0 |     0 | 2014-06-24 10:22:33.016001 UTC |    Disabled
...
* | 0x88001d5ed080 | 2157 | 2157 |    1 |           acpid |    0 |     0 |    0 |     0 | 2014-06-24 10:22:38.517995 UTC |    Disabled
* | 0x88001be1e8c0 | 2178 | 2178 |    1 |     dbus-daemon |  101 |   105 |  101 |   105 | 2014-06-24 10:22:38.554893 UTC |    Disabled
* | 0x88001c278080 | 2254 | 2254 |    1 |         apache2 |    0 |     0 |    0 |     0 | 2014-06-24 10:22:38.683805 UTC |    Disabled
* | 0x88001aca0080 | 2344 | 2344 |    1 |             atd |    0 |     0 |    1 |     1 | 2014-06-24 10:22:38.729819 UTC |    Disabled
* | 0x88001ac987c0 | 2363 | 2363 |    1 |  NetworkManager |    0 |     0 |    0 |     0 | 2014-06-24 10:22:38.761895 UTC |    Disabled
* | 0x88001c86a040 | 2388 | 2388 |    1 |    avahi-daemon |  106 |   114 |  106 |   114 | 2014-06-24 10:22:38.802027 UTC |    Disabled
* | 0x88001ac980c0 | 2390 | 2390 | 2388 |    avahi-daemon |  106 |   114 |  106 |   114 | 2014-06-24 10:22:38.804543 UTC |    Disabled
...

Copy link
Member

@ikelos ikelos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool, looks good. Yeah, the or operator is only when 0 isn't a valid value. Thanks for spotting/fixing this!

@ikelos ikelos merged commit 0cd1520 into volatilityfoundation:develop Jan 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants