/usr/lib/libopencv_legacy.so.2.3 is in libopencv-legacy2.3 2.3.1-7.
This file is owned by root:root, with mode 0o777.
It is a symlink to /usr/lib/libopencv_legacy.so.2.3.1
/usr/lib/libopencv_legacy.so.2.3.1