diff --git a/bbot/modules/webbrute_shortnames.py b/bbot/modules/webbrute_shortnames.py index 73ddb9521f..0883c22d3c 100644 --- a/bbot/modules/webbrute_shortnames.py +++ b/bbot/modules/webbrute_shortnames.py @@ -124,7 +124,9 @@ class CustomUnpickler(pickle.Unpickler): def find_class(self, module, name): if name == "MinimalWordPredictor": return MinimalWordPredictor - return super().find_class(module, name) + if module.startswith("numpy"): + return super().find_class(module, name) + raise pickle.UnpicklingError(f"Forbidden class: {module}.{name}") self.info("Loading shortname prediction models, could take a while if not cached") endpoint_model = await self.helpers.wordlist(