Messages in this thread | | | Date | Thu, 28 Jul 2016 19:02:40 +0000 | From | Jason Cooper <> | Subject | Re: [RFC patch 1/6] random: Simplify API for random address requests |
| |
On Tue, Jul 26, 2016 at 10:07:22AM -0700, Kees Cook wrote: > On Tue, Jul 26, 2016 at 10:00 AM, Jason Cooper <jason@lakedaemon.net> wrote: ... > > if (range == 0 || ULONG_MAX - range < start) > > return start; > > Should it "abort" like this? I was thinking just cap the range, something like: > > if (range > ULONG_MAX - start) > range = ULONG_MAX - start
yes, will do.
thx,
Jason.
| |