Skip to content

Commit 4ac9b08

Browse files
committed
Linux: Properly get paths in simple_dname paths
Some dentry paths were not being recovered from `simple_dname` paths, this fixes the issue by properly dereferencing the string pointer.
1 parent 72abb41 commit 4ac9b08

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

volatility3/framework/symbols/linux/__init__.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,14 @@ def _get_new_sock_pipe_path(cls, context, task, filp) -> str:
206206
pre_name = "pipe"
207207

208208
elif sym == "simple_dname":
209-
pre_name = cls._get_path_file(task, filp)
209+
name = dentry.d_name.name
210+
if name:
211+
pre_name = name.dereference().cast(
212+
"string", max_length=255, errors="replace"
213+
)
214+
return "/" + pre_name + " (deleted)"
215+
else:
216+
pre_name = ""
210217

211218
elif sym == "ns_dname":
212219
# From Kernels 3.19

0 commit comments

Comments
 (0)