UBUNTU: SAUCE: opennsl: bde: check for out-of-bounds index io.dev
BugLink: https://launchpad.net/bugs/1718388 io.dev is used as an index into the _devices array and currently the user may pass any unsigned int value into io.dev which can create an out-of-bounds error. Fix this by sanity checking io.dev and returning -EINVAL for out-of-bounds values of io.dev Detected by CoverityScan CID#1456895 ("Untrusted array index read") Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Juerg Haefliger <juerg.haefliger@canonical.com> Acked-by: Stefan Bader <stefan.bader@canonical.com> [kleber: adapted for new version path; adapted for context] Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Showing
Please register or sign in to comment