Skip to content

Commit 7f39d97

Browse files
Add linecache, difflib, gc to UNSAFE_IMPORTS (GHSA-r48f-3986-4f9c)
linecache and difflib could access arbitrary files, and gc can give references to tracked unsafe modules. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 351ed4d commit 7f39d97

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

fickling/fickle.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@
6969
"_imp",
7070
"pkgutil",
7171
"zipimport",
72+
"gc",
7273
# Attribute access (getattr equivalent bypasses)
7374
"inspect",
7475
# Operator module bypasses
@@ -141,6 +142,8 @@
141142
"fileinput",
142143
"glob",
143144
"platform",
145+
"linecache",
146+
"difflib",
144147
# Code compilation (writes .pyc files)
145148
"compileall",
146149
"py_compile",

0 commit comments

Comments
 (0)