[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openssl-users
Subject:    Re: win32 build and freeing pointers
From:       Dan Kegel <dank () kegel ! com>
Date:       2020-07-31 14:43:45
Message-ID: CAPF-yOZEw3_KE37aE8h-j_xj4PJ+EC3ZJ0zbY01z1jCvJon1xw () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Sounds like the pointer is *pointing to* memory containing 0xdddddddd...
i.e. this is a use-after-free error.

You might consider building your app with Address Sanitizer enabled,
that might find the problem earlier during execution.
- Dan

On Fri, Jul 31, 2020 at 5:32 AM <Tobias.Wolf@t-systems.com> wrote:

> Hi guys,
>
>
>
> I've experienced the following strange behaviour.
>
> I have the same code and the same openssl build.
>
> With x64 everything I fine, but with x86 build not.
>
> With a 32bit environment I got the following access vialotion.
>
> I read that windows marks a freed pointer as "0XDDDDDDDD", but we are
> usally freeing and setting NULL value to a pointer, therefore a following
> NULL check later for a already freed pointer would NOT work, right?
>
> Has anybody an adivice for me?
>
>
>
> Regards
>
> Tobias
>
>
>
>
>
>

[Attachment #5 (text/html)]

<div dir="ltr">Sounds like the pointer is *pointing to* memory containing \
0xdddddddd...<div>i.e. this is a use-after-free error.</div><div><br></div><div>You \
might consider building your app with Address Sanitizer enabled,</div><div>that might \
find the problem earlier during execution.</div><div>- Dan</div></div><br><div \
class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jul 31, 2020 at 5:32 AM \
&lt;<a href="mailto:Tobias.Wolf@t-systems.com">Tobias.Wolf@t-systems.com</a>&gt; \
wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px \
0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">





<div lang="EN-US">
<div class="gmail-m_6714668683754622851WordSection1">
<p class="MsoNormal"><span lang="DE">Hi guys,<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="DE"><u></u>  <u></u></span></p>
<p class="MsoNormal"><span style="color:rgb(31,73,125)">I've experienced the \
following strange behaviour.<u></u><u></u></span></p> <p class="MsoNormal"><span \
style="color:rgb(31,73,125)">I have the same code and the same openssl \
build.<u></u><u></u></span></p> <p class="MsoNormal"><span \
style="color:rgb(31,73,125)">With x64 everything I fine, but with x86 build \
not.<u></u><u></u></span></p> <p class="MsoNormal"><span \
style="color:rgb(31,73,125)">With a 32bit environment I got the following access \
vialotion.<u></u><u></u></span></p> <p class="MsoNormal"><span \
style="color:rgb(31,73,125)">I read that windows marks a freed pointer as \
"0XDDDDDDDD", but we are usally freeing and setting NULL value to a pointer, \
therefore a following NULL check later for a already freed pointer  would NOT work, \
right?<u></u><u></u></span></p> <p class="MsoNormal"><span \
style="color:rgb(31,73,125)">Has anybody an adivice for me?<u></u><u></u></span></p> \
<p class="MsoNormal"><span style="color:rgb(31,73,125)"><u></u>  <u></u></span></p> \
<p class="MsoNormal"><span \
style="color:rgb(31,73,125)">Regards<u></u><u></u></span></p> <p \
class="MsoNormal"><span style="color:rgb(31,73,125)">Tobias<u></u><u></u></span></p> \
<p class="MsoNormal"><span style="color:rgb(31,73,125)"><u></u>  <u></u></span></p> \
<p class="MsoNormal"><span style="color:rgb(31,73,125)"><u></u>  <u></u></span></p> \
<p class="MsoNormal"><img width="823" height="335" style="width: 8.5763in; height: \
3.493in;" id="gmail-m_6714668683754622851Grafik_x0020_1" \
src="cid:173a552e20d6917eb1"><u></u><u></u></p> </div>
</div>

</blockquote></div>


["image003.jpg" (image/jpeg)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic