Skip to content

Commit bea9811

Browse files
committed
Prevent potential dentry pointer memory smear
1 parent 8e56cb3 commit bea9811

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

volatility3/framework/symbols/linux/__init__.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,8 +200,11 @@ def path_for_file(cls, context, task, filp) -> str:
200200
Returns:
201201
str: A file (or sock pipe) pathname relative to the task's root directory.
202202
"""
203+
204+
# Memory smear protection: Check that both the file and dentry pointers are valids.
203205
try:
204206
dentry = filp.get_dentry()
207+
dentry.is_root()
205208
except exceptions.InvalidAddressException:
206209
return ""
207210

0 commit comments

Comments
 (0)