Re: Entropy sources under WinXP
- From: Mark Nudelman <markn@xxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 23 May 2007 14:36:30 -0700
On 5/23/2007 1:30 PM, Karl Malbrain wrote:
<michael.spath@xxxxxxxxx> wrote in message
news:1179948814.886698.280790@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
On May 22, 8:52 pm, "Karl Malbrain" <malbr...@xxxxxxxxx> wrote:
The compiled code cannot do this unless the source code
is written this way, which would be absurd and is not the
case in vanilla Win2K and WinXP as shown by the
disassembled code.
absurd???
// test for overflow
if( regentry->size > *userbuffersize )
goto buffer_overflow;
//copy data to user buffer and return number of bytes copied
memcpy (userbufferaddress, regentry->data, regentry->size);
*userbuffersize = regentry->size;
is hardly absurd!!!
But if regentry points to shared data and it's not protected by a mutex,
that *is* absurd. Any CS major fresh out of college would know enough
to avoid that problem. I can't believe that a piece of code as
important and heavily used as the registry APIs would have such an
elementary error, and one which has never been noticed until now.
--Mark
.
- Follow-Ups:
- Re: Entropy sources under WinXP
- From: Karl Malbrain
- Re: Entropy sources under WinXP
- References:
- Entropy sources under WinXP
- From: keith
- Re: Entropy sources under WinXP
- From: Mark Nudelman
- Re: Entropy sources under WinXP
- From: Sebastian G.
- Re: Entropy sources under WinXP
- From: Mark Nudelman
- Re: Entropy sources under WinXP
- From: Sebastian G.
- Re: Entropy sources under WinXP
- From: Mark Nudelman
- Re: Entropy sources under WinXP
- From: Sebastian G.
- Re: Entropy sources under WinXP
- From: michael . spath
- Re: Entropy sources under WinXP
- From: Karl Malbrain
- Re: Entropy sources under WinXP
- From: michael . spath
- Re: Entropy sources under WinXP
- From: Karl Malbrain
- Re: Entropy sources under WinXP
- From: michael . spath
- Re: Entropy sources under WinXP
- From: Karl Malbrain
- Entropy sources under WinXP
- Prev by Date: Re: Hint for users of Google Groups
- Next by Date: Re: fixed block size
- Previous by thread: Re: Entropy sources under WinXP
- Next by thread: Re: Entropy sources under WinXP
- Index(es):
Relevant Pages
|