Bypasses / Safe model loader or scanner
Safe model loader or scanner
91 cases that got past this protection.
- vLLM: Public multimodal SHM handle forgery reaches worker-side `pickle.loads()` with insecure serialization disabled Forged shared-memory handles in vLLM's multimodal cache reach pickle.loads in the worker, and this works without the insecure-serialisation opt-in.
- NLTK: Allowlisted pickle loaders still permit code execution in current source Allowlisted pickle loaders trust whole module namespaces, so a crafted pickle can call dangerous helpers such as subprocess-spawning functions during unpickling.
- MLFLOW_ALLOW_PICKLE_DESERIALIZATION=False safety control bypassed by mlflow.statsmodels flavor — RCE via crafted model artifact The statsmodels loader skips the pickle deserialisation guard, so a crafted model artifact runs code when loaded even with pickle disabled.
- NLTK AllowlistUnpickler dotted-name validation bypass allows remote code execution A malicious transition-parser model uses dotted-name attribute traversal to reach callables outside the unpickler allowlist, running commands when the model loads.
- Keras: HDF5 links can disclose local file contents A malicious model file with HDF5 external links makes Keras load and expose local files through functions that skip its link-safety helpers.
- sentence-transformers local model loading bypasses trust_remote_code and executes custom Python When the model path exists locally, the trust_remote_code gate is skipped, so Python files in the model directory are imported even though remote code is disabled.
- Keras: TorchModuleWrapper can deserialize unsafe PyTorch pickle data The TorchModuleWrapper config loader calls torch.load with unrestricted unpickling unless an ambient safe-mode flag is set, so untrusted configs run code.
- PyTorch Lightning allows arbitrary code execution through checkpoint _instantiator hyperparameters A crafted checkpoint supplies a module name in hyperparameters that is imported during loading, bypassing the weights_only protection.
- Keras: Lambda deserialization can bypass safe mode and execute code A model config containing a Lambda layer with marshalled bytecode runs when deserialised, because the safe-mode guard fails when the flag is left unset.
- huggingface/transformers: Arbitrary Code Execution During Model Initialization in the LightGlue Model Loading Path A model config can set trust_remote_code internally to true, so loading with it disabled still imports attacker-supplied Python modules.
- HuggingFace transformers vulnerable to remote code execution A crafted config.json points an internal attention field at a hub repo, so from_pretrained fetches and runs attacker Python without trust_remote_code.
- Cleartext storage of HMAC signing key in Amazon SageMaker Python SDK ModelBuilder/Serve path A signing key readable through cloud describe APIs lets an attacker forge integrity signatures so malicious model artifacts are accepted and run in the serving container.
- Diffusers has a `trust_remote_code` bypass via `custom_pipeline` and local custom components Remote code in a custom pipeline or local model folder runs even when trust_remote_code is false, because the check sits in the download step that those paths skip.
- Keras has an untrusted deserialization vulnerability A crafted .keras archive makes TFSMLayer load an attacker's SavedModel, running code even when safe_mode is enabled.
- HuggingFace Transformers allows for arbitrary code execution in the `Trainer` class A crafted RNG state checkpoint executes code when the Trainer loads it, because torch.load runs without the weights-only restriction.
- vLLM has Hardcoded Trust Override in Model Files Enables RCE Despite Explicit User Opt-Out Two model implementation files hardcode trust_remote_code=True for sub-component loads, so a malicious model repository runs Python even when the user disabled remote code.
- PickleScan's profile.run blocklist mismatch allows exec() bypass A pickle calling the module-level profile run function reaches exec() because the scanner blocklist only matches the class-qualified names.
- PickleScan has multiple stdlib modules with direct RCE not in blocklist The scanner's blocklist omits several standard library modules that can run shell commands, so pickles using them are reported as clean.
- PickleScan's pkgutil.resolve_name has a universal blocklist bypass A pickle calls pkgutil.resolve_name with a module:attribute string to obtain a blocked function such as os.system, so the dangerous name never appears in the opcodes.
- Keras has a Local File Disclosure via HDF5 External Storage During Keras Weight Loading A malicious HDF5 weights file uses external storage links that load_weights follows, so contents of arbitrary host files are read into model tensors, bypassing safe mode.
- Picklescan (scan_pytorch) Bypass via dynamic eval MAGIC_NUMBER A pickle payload calls eval through __reduce__ with a magic-number value the scanner's opcode check misses but the real torch loader still reads.
- picklescan missing detection by simple obfuscation of a `builtins.eval` call A pickle payload hides a builtins eval call behind getattr, so the scanner does not flag it and the code runs when the file is loaded.
- picklescan vulnerable to arbitrary file create using logging.FileHandler Pickle payloads that instantiate logging.FileHandler slip past the scanner's blocklist and create empty files at attacker-chosen paths.
- PyTorch Vulnerable to Remote Code Execution via Untrusted Checkpoint Files A crafted .pth checkpoint passes the weights-only unpickler despite invalid opcodes and storage sizes, corrupting heap memory during torch.load.
- vLLM affected by RCE via auto_map dynamic module loading during model initialization A model repository's auto_map entry makes vLLM import attacker Python during model resolution, even with trust_remote_code disabled.
- picklescan has Arbitrary file read using `io.FileIO` A crafted pickle chains file-reading and HTTP-posting callables to send local file contents to an external server, evading the scanner's execution-focused blocklist.
- Picklescan is vulnerable to RCE via missing detection when calling built-in python _operator.attrgetter Picklescan does not flag _operator.attrgetter gadgets, so a hand-built pickle reaching __import__ runs shell commands when loaded.
- Picklescan is vulnerable to RCE through missing detection when calling numpy.f2py.crackfortran._eval_length A pickle using a numpy f2py helper as its reduce callable executes code on load, and picklescan fails to flag this gadget as dangerous.
- Picklescan is vulnerable to RCE via missing detection when calling built-in python _operator.methodcaller A pickle using the _operator.methodcaller reducer is not flagged by the scanner, so loading it still runs attacker-chosen commands.
- Picklescan is vulnerable to RCE via missing detection when calling numpy.f2py.crackfortran.getlincoef A pickle that calls a NumPy F2PY helper to run Python code evades Picklescan's detection, so loading the scanned-as-safe file executes commands.
- Picklescan is vulnerable to RCE through missing detection when calling numpy.f2py.crackfortran.myeval A pickle payload calling a numpy helper evades picklescan's blocklist, so a file reported safe still runs code when loaded.
- Picklescan does not block ctypes Picklescan's denylist omits ctypes, so a pickle that calls ctypes.WinDLL and foreign functions evades detection and runs native code on load.
- Picklescan has Incomplete List of Disallowed Inputs The pickle scanner's deny-list misses pydoc.locate and operator.methodcaller, so a crafted pickle chaining them to call os.system passes the scan.
- Picklescan is vulnerable to RCE via missing detection when calling numpy.f2py.crackfortran.param_eval A pickle payload calls a numpy helper that the scanner does not flag, so scanning passes and loading the file executes attacker-supplied code.
- Picklescan Bypasses Unsafe Globals Check using pty.spawn A pickle payload calling pty.spawn evades the scanner because that function is missing from its unsafe globals list, enabling code execution when loaded.
- Picklescan vulnerable to Arbitrary File Writing A crafted pickle calls a distutils file-writing helper that the scanner's blocklist does not cover, overwriting arbitrary files on disk.
- Picklescan missing detection when calling numpy.f2py.crackfortran.getlincoef Picklescan's blocklist omits numpy.f2py.crackfortran functions that eval strings, so a pickle calling getlincoef runs code while passing the scan.
- Picklescan missing detection when calling pty.spawn A pickle's __reduce__ calls pty.spawn to run shell commands, and picklescan does not flag pty.spawn, so the scan reports the file as clean.
- Picklescan is vulnerable to RCE through missing detection when calling built-in python operator.methodcaller A pickle using operator.methodcaller to call a system function evades picklescan, so loading the file runs attacker commands.
- vLLM vulnerable to remote code execution via transformers_utils/get_config Loading a model config whose auto_map points to another repository imports and runs that repository's Python even when remote code is disabled.
- vLLM deserialization vulnerability leading to DoS and potential RCE The Completions endpoint loads user-supplied tensor embeddings with torch.load, where disabled sparse checks let crafted tensors cause out-of-bounds writes.
- Keras is vulnerable to arbitrary local file loading and Server-Side Request Forgery A crafted .keras archive sets a StringLookup vocabulary path to a local file or remote URL, and load_model reads it even with safe_mode enabled.
- Keras framework vulnerable to deserialization of untrusted data A crafted Keras file referencing a TorchModuleWrapper class runs attacker code while loading, even with safe mode enabled, whether the file is local or remote.
- Keras is vulnerable to Deserialization of Untrusted Data A crafted .keras archive re-enables unsafe deserialisation from inside its config before layer parsing, then a pickled Lambda layer runs attacker code when the model loads.
- The Keras `Model.load_model` method **silently** ignores `safe_mode=True` and allows arbitrary code execution when a `.h5`/`.hdf5` file is loaded. Loading an .h5 model ignores safe_mode=True, so pickled code inside the file runs on the victim's machine during load.
- Picklescan is Vulnerable to Unsafe Globals Check Bypass through Subclass Imports Pickles referencing subclasses of dangerous asyncio classes evade picklescan's exact module-name check, so their embedded payloads load and execute.
- Picklescan Bypass is Possible via File Extension Mismatch Picklescan sends a plain pickle with a PyTorch file extension down the PyTorch path, which errors out without running the pickle scanner, so malicious payloads go unflagged.
- Picklescan: ZIP archive scan bypass is possible through non-exhaustive Cyclic Redundancy Check Picklescan returns no results for a ZIP archive containing a bad CRC, while PyTorch can still load the hidden malicious pickle inside it.
- Picklescan is missing detection when calling built-in python idlelib.pyshell.ModifiedInterpreter.runcode A pickle payload calling idlelib's ModifiedInterpreter.runcode is not flagged by picklescan, so loading the malicious model file executes attacker code.
- Picklescan has a missing detection when calling built-in python idlelib.debugobj.ObjectTreeItem The pickle scanner does not flag calls to idlelib debugobj methods, so a malicious pickle that uses them passes the scan and runs commands when loaded.