public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Florian Weimer <fweimer@redhat.com>
To: Mark Wielaard <mjw@redhat.com>
Cc: libc-alpha@sourceware.org
Subject: Re: fortification and valgrind/memcheck (Was: [PATCH BZ#20422] Do not allow asan/msan/tsan and fortify@the same time)
Date: Wed, 05 Oct 2016 11:49:00 -0000	[thread overview]
Message-ID: <cb76ae33-01ee-2ced-68da-fccf8893eeec@redhat.com> (raw)
In-Reply-To: <1475583338.21750.26.camel@redhat.com>

On 10/04/2016 02:15 PM, Mark Wielaard wrote:
> My proposal was to extend __chk_fail (or introduce a new __chk_fail_addr
> function) that provides the address that would have been accessed. Then
> valgrind just intercepts __chk_fail and uses that address to provide
> some additional information.

There many different reasons why __chk_fail might be called.  For 
example, you get a fortify failure if you call snprintf with a buffer 
size that is larger than what is inferred by the compiler.  This happens 
even if the actual written value fits within the shorter space.  So you 
have a fortify failure without any invalid memory accesses.

Florian

  reply	other threads:[~2016-10-05 11:49 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-05 17:27 [PATCH BZ#20422] Do not allow asan/msan/tsan and fortify at the same time Maxim Ostapenko
2016-09-05 19:48 ` Andrew Pinski
2016-09-06  8:39 ` Florian Weimer
2016-09-06  8:58   ` Yuri Gribov
2016-09-06  9:13     ` Florian Weimer
2016-09-06  9:20       ` Yuri Gribov
2016-09-06  9:51         ` Florian Weimer
2016-09-09 22:35       ` Kostya Serebryany
     [not found]       ` <CAN=P9phe_OP+tU+nnDDPEeZCR77w2ddrSX+LtSnx2-42p9JgUg@mail.gmail.com>
2016-09-12  9:36         ` Florian Weimer
2016-09-06  9:16   ` Maxim Ostapenko
2016-09-06  9:44     ` Florian Weimer
2016-09-09 22:36     ` Kostya Serebryany
2016-09-12  9:31       ` Florian Weimer
2016-09-12 18:54         ` Kostya Serebryany
2016-09-17  9:00   ` Yuri Gribov
2016-09-29  8:08     ` Florian Weimer
2016-09-29  9:47       ` Yuri Gribov
2016-09-29 10:04         ` Jakub Jelinek
2016-09-29 10:32           ` Yuri Gribov
2016-09-29 10:44             ` Jakub Jelinek
2016-09-29 10:52               ` Andrew Pinski
2016-09-29 21:23                 ` Kostya Serebryany
2016-10-01 21:38                   ` Andrew Pinski
2016-10-01 21:50                     ` Jakub Jelinek
2016-10-02  7:51                   ` Florian Weimer
2016-10-02  9:40                     ` Jakub Jelinek
2016-10-02  9:43                       ` Florian Weimer
2016-10-02 14:02                         ` Yuri Gribov
2016-10-04  0:53                           ` Kostya Serebryany
2016-10-04  6:46                             ` Jakub Jelinek
2016-10-04 12:15                               ` fortification and valgrind/memcheck (Was: [PATCH BZ#20422] Do not allow asan/msan/tsan and fortify@the same time) Mark Wielaard
2016-10-05 11:49                                 ` Florian Weimer [this message]
2016-10-05 12:02                                   ` Mark Wielaard
2016-10-05 14:27 ` [PATCH BZ#20422] Do not allow asan/msan/tsan and fortify at the same time Florian Weimer
2016-10-05 15:46   ` Maxim Ostapenko
2016-10-05 16:01     ` Maxim Ostapenko
2016-10-05 16:01     ` Kostya Serebryany
2016-10-05 16:06 ` Zack Weinberg
2016-10-05 16:11   ` Kostya Serebryany
2016-10-05 16:46     ` Zack Weinberg
2016-10-05 17:58       ` Yuri Gribov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cb76ae33-01ee-2ced-68da-fccf8893eeec@redhat.com \
    --to=fweimer@redhat.com \
    --cc=libc-alpha@sourceware.org \
    --cc=mjw@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).