public inbox for linux-man@vger.kernel.org
 help / color / mirror / Atom feed
From: Alejandro Colomar <alx.manpages@gmail.com>
To: Sam James <sam@gentoo.org>
Cc: linux-man@vger.kernel.org
Subject: Re: [PATCH] feature_test_macros.7: document -D_FORTIFY_SOURCE=3
Date: Thu, 13 Oct 2022 20:50:51 +0200	[thread overview]
Message-ID: <43b87bb6-2c18-5df5-fe5b-6d753f97ad85@gmail.com> (raw)
In-Reply-To: <20221013183117.477592-1-sam@gentoo.org>


[-- Attachment #1.1: Type: text/plain, Size: 1439 bytes --]

Hi Sam,

On 10/13/22 20:31, Sam James wrote:
> Reference: https://developers.redhat.com/blog/2021/04/16/broadening-compiler-checks-for-buffer-overflows-in-_fortify_source
> Reference: https://developers.redhat.com/articles/2022/09/17/gccs-new-fortification-level
> Signed-off-by: Sam James <sam@gentoo.org>
> ---
>   man7/feature_test_macros.7 | 11 +++++++++++
>   1 file changed, 11 insertions(+)
> 
> diff --git a/man7/feature_test_macros.7 b/man7/feature_test_macros.7
> index d33041001..e62185745 100644
> --- a/man7/feature_test_macros.7
> +++ b/man7/feature_test_macros.7
> @@ -643,9 +643,20 @@ and result in compiler warnings;
>   other checks take place at run time,
>   and result in a run-time error if the check fails.
>   .IP
> +With
> +.B _FORTIFY_SOURCE
> +set to 3, additional checking is added to capture some function

What do you mean by "capture"?

Cheers,

Alex

> +calls used with an argument of variable size.
> +.IP
>   Use of this macro requires compiler support, available with
>   .BR gcc (1)
>   since version 4.0.
> +.IP
> +For use of
> +.B _FORTIFY_SOURCE
> +set to 3, then
> +.BR gcc (1)
> +version 12.0 or later is required.
>   .SS Default definitions, implicit definitions, and combining definitions
>   If no feature test macros are explicitly defined,
>   then the following feature test macros are defined by default:

-- 
<http://www.alejandro-colomar.es/>

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2022-10-13 18:54 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-13 18:31 [PATCH] feature_test_macros.7: document -D_FORTIFY_SOURCE=3 Sam James
2022-10-13 18:50 ` Alejandro Colomar [this message]
2022-10-13 18:57   ` Sam James
2022-10-13 19:12     ` Alejandro Colomar
2022-10-13 21:06       ` Sam James

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=43b87bb6-2c18-5df5-fe5b-6d753f97ad85@gmail.com \
    --to=alx.manpages@gmail.com \
    --cc=linux-man@vger.kernel.org \
    --cc=sam@gentoo.org \
    /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