AeonAIRisk's picture
Upload load_npz.py with huggingface_hub
88bd0c4 verified
Raw
History Blame Contribute Delete
406 Bytes
import numpy as np, os
MARKER = r"C:/Users/uozer/AppData/Local/Temp/opencode/NPZ_PWN.txt"
if os.path.exists(MARKER):
os.remove(MARKER)
print("before load, marker:", os.path.exists(MARKER))
d = np.load(r"D:\0projects\bountykimi\tmp\evil_npz.npz", allow_pickle=True)
_ = d["data"]
print("after load, marker:", os.path.exists(MARKER))
if os.path.exists(MARKER):
print("content:", open(MARKER).read())