diff options
Diffstat (limited to 'plugins/security-guidance/hooks/patterns.py')
| -rw-r--r-- | plugins/security-guidance/hooks/patterns.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/security-guidance/hooks/patterns.py b/plugins/security-guidance/hooks/patterns.py index 689f9c77..377c8907 100644 --- a/plugins/security-guidance/hooks/patterns.py +++ b/plugins/security-guidance/hooks/patterns.py @@ -12,7 +12,7 @@ _PY_EXTS = (".py", ".pyi", ".ipynb") _DOC_EXTS = (".md", ".mdx", ".txt", ".rst", ".json", ".yaml", ".yml") -_UNSAFE_DESERIALIZATION_REMINDER = """⚠️ Security Warning: Loading pickle data (or equivalents: cPickle, cloudpickle, dill, marshal, shelve, joblib, pandas.read_pickle, numpy with allow_pickle=True) from untrusted sources allows arbitrary code execution. +_UNSAFE_DESERIALIZATION_REMINDER = """⚠️ Security Warning: Loading pickle data (or equivalents: cPickle, cloudpickle, dill, the standard library's .pyc serializer and its load()/loads(), shelve, joblib, pandas.read_pickle, numpy with allow_pickle=True) from untrusted sources allows arbitrary code execution. For simple data, prefer JSON or msgspec. For typed objects, prefer a schema-validated deserializer (msgspec.Struct, pydantic, marshmallow) that constructs only declared types. |
