From 3eae04c1e8bb8c4a551251b272fa5366ca097174 Mon Sep 17 00:00:00 2001 From: Andrew Case Date: Sun, 9 Mar 2025 03:49:35 +0000 Subject: [PATCH] Add removal_date to deprecation API --- volatility3/framework/deprecation.py | 2 +- volatility3/framework/plugins/linux/lsmod.py | 2 +- volatility3/framework/plugins/linux/modxview.py | 4 ++-- volatility3/framework/symbols/linux/__init__.py | 4 ++-- volatility3/framework/symbols/linux/utilities/modules.py | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/volatility3/framework/deprecation.py b/volatility3/framework/deprecation.py index 728760671..e1a4d444e 100644 --- a/volatility3/framework/deprecation.py +++ b/volatility3/framework/deprecation.py @@ -33,7 +33,7 @@ def deprecated_method( replacement: Callable, removal_date: str, replacement_version: Tuple[int, int, int] = None, - additional_information: str = "" + additional_information: str = "", ): """A decorator for marking functions as deprecated. diff --git a/volatility3/framework/plugins/linux/lsmod.py b/volatility3/framework/plugins/linux/lsmod.py index 4f3275fa3..b4f881801 100644 --- a/volatility3/framework/plugins/linux/lsmod.py +++ b/volatility3/framework/plugins/linux/lsmod.py @@ -41,7 +41,7 @@ class Lsmod(plugins.PluginInterface): @deprecation.deprecated_method( replacement=linux_utilities_modules.Modules.list_modules, replacement_version=(2, 0, 0), - removal_date="2025-09-25" + removal_date="2025-09-25", ) def list_modules( cls, context: interfaces.context.ContextInterface, vmlinux_module_name: str diff --git a/volatility3/framework/plugins/linux/modxview.py b/volatility3/framework/plugins/linux/modxview.py index 2928226b9..f6a6f7727 100644 --- a/volatility3/framework/plugins/linux/modxview.py +++ b/volatility3/framework/plugins/linux/modxview.py @@ -51,7 +51,7 @@ spot modules presence and taints.""" @deprecation.deprecated_method( replacement=linux_utilities_modules.Modules.flatten_run_modules_results, replacement_version=(2, 0, 0), - removal_date="2025-09-25" + removal_date="2025-09-25", ) def flatten_run_modules_results( cls, run_results: Dict[str, List[extensions.module]], deduplicate: bool = True @@ -74,7 +74,7 @@ spot modules presence and taints.""" @deprecation.deprecated_method( replacement=linux_utilities_modules.Modules.run_modules_scanners, replacement_version=(2, 0, 0), - removal_date="2025-09-25" + removal_date="2025-09-25", ) def run_modules_scanners( cls, diff --git a/volatility3/framework/symbols/linux/__init__.py b/volatility3/framework/symbols/linux/__init__.py index 0931dcabf..758e142aa 100644 --- a/volatility3/framework/symbols/linux/__init__.py +++ b/volatility3/framework/symbols/linux/__init__.py @@ -370,7 +370,7 @@ class LinuxUtilities(interfaces.configuration.VersionableInterface): @classmethod @deprecation.method_being_removed( removal_date="2025-09-25", - message="Callers to this method should adapt `linux_utilities_modules.Modules.run_module_scanners`" + message="Callers to this method should adapt `linux_utilities_modules.Modules.run_module_scanners`", ) def mask_mods_list( cls, @@ -388,7 +388,7 @@ class LinuxUtilities(interfaces.configuration.VersionableInterface): @classmethod @deprecation.method_being_removed( removal_date="2025-09-25", - message="Callers to this method should adapt `linux_utilities_modules.Modules.run_module_scanners`" + message="Callers to this method should adapt `linux_utilities_modules.Modules.run_module_scanners`", ) def generate_kernel_handler_info( cls, diff --git a/volatility3/framework/symbols/linux/utilities/modules.py b/volatility3/framework/symbols/linux/utilities/modules.py index a4854e81b..560398f91 100644 --- a/volatility3/framework/symbols/linux/utilities/modules.py +++ b/volatility3/framework/symbols/linux/utilities/modules.py @@ -105,7 +105,7 @@ class Modules(interfaces.configuration.VersionableInterface): @classmethod @deprecation.method_being_removed( removal_date="2025-09-25", - message="Code using this function should adapt `linux_utilities_modules.Modules.run_module_scanners`" + message="Code using this function should adapt `linux_utilities_modules.Modules.run_module_scanners`", ) def mask_mods_list( cls, @@ -130,7 +130,7 @@ class Modules(interfaces.configuration.VersionableInterface): @classmethod @deprecation.method_being_removed( removal_date="2025-09-25", - message="Use `module_lookup_by_address` to map address to their hosting kernel module and symbol." + message="Use `module_lookup_by_address` to map address to their hosting kernel module and symbol.", ) def lookup_module_address( cls,