Skip to content

Commit 9ad8287

Browse files
authored
Merge pull request #1781 from volatilityfoundation/1780-dlllist-loadcount-missing
1780 dlllist loadcount missing
2 parents 1ebb82a + 88c8bfe commit 9ad8287

File tree

4 files changed

+23
-3
lines changed

4 files changed

+23
-3
lines changed

volatility3/framework/constants/_version.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# We use the SemVer 2.0.0 versioning scheme
22
VERSION_MAJOR = 2 # Number of releases of the library with a breaking change
3-
VERSION_MINOR = 26 # Number of changes that only add to the interface
4-
VERSION_PATCH = 2 # Number of changes that do not change the interface
3+
VERSION_MINOR = 27 # Number of changes that only add to the interface
4+
VERSION_PATCH = 0 # Number of changes that do not change the interface
55
VERSION_SUFFIX = ""
66

77
PACKAGE_VERSION = (

volatility3/framework/plugins/windows/dlllist.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class DllList(interfaces.plugins.PluginInterface, timeliner.TimeLinerInterface):
2222
"""Lists the loaded DLLs in a particular windows memory image."""
2323

2424
_required_framework_version = (2, 0, 0)
25-
_version = (3, 0, 0)
25+
_version = (3, 0, 1)
2626

2727
@classmethod
2828
def get_requirements(cls) -> List[interfaces.configuration.RequirementInterface]:
@@ -173,6 +173,10 @@ def _generator(self, procs):
173173
except exceptions.InvalidAddressException:
174174
size_of_image = renderers.NotAvailableValue()
175175

176+
LoadCount = entry.get_load_count()
177+
if LoadCount is None:
178+
LoadCount = renderers.NotAvailableValue()
179+
176180
yield (
177181
0,
178182
(
@@ -186,6 +190,7 @@ def _generator(self, procs):
186190
size_of_image,
187191
BaseDllName,
188192
FullDllName,
193+
LoadCount,
189194
DllLoadTime,
190195
file_output,
191196
),
@@ -232,6 +237,7 @@ def run(self):
232237
("Size", format_hints.Hex),
233238
("Name", str),
234239
("Path", str),
240+
("LoadCount", int),
235241
("LoadTime", datetime.datetime),
236242
("File output", str),
237243
],

volatility3/framework/symbols/windows/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ def __init__(self, *args, **kwargs) -> None:
4141
self.set_type_class("_POOL_TRACKER_BIG_PAGES", pool.POOL_TRACKER_BIG_PAGES)
4242
self.set_type_class("_IMAGE_DOS_HEADER", pe.IMAGE_DOS_HEADER)
4343
self.set_type_class("_KTIMER", extensions.KTIMER)
44+
self.set_type_class("_LDR_DATA_TABLE_ENTRY", extensions.LDR_DATA_TABLE_ENTRY)
4445

4546
# Might not necessarily defined in every version of windows
4647
self.optional_set_type_class("_IMAGE_NT_HEADERS", pe.IMAGE_NT_HEADERS)

volatility3/framework/symbols/windows/extensions/__init__.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1710,3 +1710,16 @@ def get_available_pages(self) -> List:
17101710
)
17111711

17121712
return vacb_list
1713+
1714+
1715+
class LDR_DATA_TABLE_ENTRY(objects.StructType):
1716+
def get_load_count(self) -> Optional[int]:
1717+
try:
1718+
LoadCount = self.LoadCount.cast("short")
1719+
except Exception:
1720+
try:
1721+
LoadCount = self.ObsoleteLoadCount.cast("short")
1722+
except Exception:
1723+
LoadCount = None
1724+
1725+
return LoadCount

0 commit comments

Comments
 (0)