Messages in this thread | | | From | Denis Vlasenko <> | Subject | Re: AUDIT: copy_from_user is a deathtrap. | Date | Fri, 17 May 2002 15:58:03 -0200 |
| |
On 17 May 2002 10:58, Rusty Russell wrote: > > > /* of course this returns 0 or -EFAULT! */ > > > return copy_from_user(xxx); > > > > So lets verify and fix them. Post the list to the kenrel janitors > > Again, like we did 12 months ago you mean? > > We could do that, or, we could fix the actual problem, which is the > HUGE FUCKING BEARTRAP WHICH CATCHES EVERY SINGLE NEW PROGRAMMER ON THE > WAY THROUGH.
Looks like it is waiting for me yet (if I'll ever do something useful for lk).
> Not fixing earlier was criminal, not fixing it today is insane.
What's the problem? People don't understand what copy_x_user() returns and how to check return value properly?
Maybe good function name(s) will help?
copy_{from,to}_user_and_count()
> There are 415 uses of copy_to/from_user which are wrong, despite an > audit 12 months ago by the Stanford checker.
What are typical errors? -- vda - 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/
| |