The code as-is appears to be OK. Note how sys_getdents64() will run
access_ok() against the entire user buffer up-front. Then the start/len of
that verified area is copied into the getdents_callback64 and that is
propagated down to filldir64().
And filldir64() looks like it correctly remains within the bounds of the
start/len.
I guess that copy_to_user() should be __copy_to_user().
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/