From 8b6ab44310e3e39cd3fa06321dd208c2e88d5cd8 Mon Sep 17 00:00:00 2001 From: Mike Auty Date: Sun, 26 Nov 2023 12:30:06 +0000 Subject: [PATCH] Core: Fix array_of_pointers to act only on those pointers --- volatility3/framework/objects/utility.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/volatility3/framework/objects/utility.py b/volatility3/framework/objects/utility.py index 177074cd7..0292608c1 100644 --- a/volatility3/framework/objects/utility.py +++ b/volatility3/framework/objects/utility.py @@ -44,8 +44,9 @@ def array_of_pointers( raise TypeError( "Subtype must be a valid template (or string name of an object template)" ) + # We have to clone the pointer class, or we'll be defining the pointer subtype for all future pointers subtype_pointer = context.symbol_space.get_type( symbol_table + constants.BANG + "pointer" - ) + ).clone() subtype_pointer.update_vol(subtype=subtype) return array.cast("array", count=count, subtype=subtype_pointer)