numpy is vulnerable to Untrusted Pointer Dereference
59
Medium Risk
numpy.rec.fromstring and numpy.rec.fromfile build a recarray directly over a caller-supplied byte buffer or file according to a caller-supplied dtype, without checking whether that dtype contains object references. When the dtype includes reference fields, the raw buffer bytes land in memory that NumPy later treats as PyObject* pointers, so arbitrary bytes from an untrusted string or file get dereferenced and reference-counted as if they were real Python objects. Reading or garbage-collecting the resulting array can crash the process or corrupt memory. The fix rejects dtypes whose hasobject flag is set before constructing the array.
You are affected if you are using a version that falls within the vulnerable range and you call numpy.rec.fromstring or numpy.rec.fromfile with a dtype containing object/reference fields on data you do not fully control.
numpy is vulnerable to Untrusted Pointer Dereference in versions 1.0.0 - 2.5.2.
Upgrade the numpy library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant
ISO 42001Compliant© All Intel data is openly available and commercially licensed.