From: Siddhesh Poyarekar <siddhesh@sourceware.org>
To: libc-alpha@sourceware.org
Subject: [PATCH v3 0/2] _FORTIFY_SOURCE fixes [BZ #28746]
Date: Mon, 10 Jan 2022 21:04:15 +0530 [thread overview]
Message-ID: <20220110153417.100143-1-siddhesh@sourceware.org> (raw)
In-Reply-To: <20220105013946.2646963-1-siddhesh@sourceware.org>
The main patch is 2/2, which fixes some fortified headers to match
feature macros with their corresponding main headers, without which
functions would fail to get fortified. Patch 1/2 is a restructuring of
the tests so that it is easier to add different configurations to
_FORTIFY_SOURCE tests at various levels.
Tested on x86_64 to confirm that there were no new regressions due to
this and that the new tests also run clean.
Changes from v1:
- Rebased against latest trunk so that the patches actually apply.
- Renamed files so that the diffs are easier to compare and also make a
bit more sense.
Changes from v2:
- Renamed tst-chk-0.c to tst-fortify.c and autogenerate all tests and
include it.
- Set all the flags we can as -D in CFLAGS and autogenerate test cases
if needed.
- Fix other review comments.
Siddhesh Poyarekar (2):
debug: Autogenerate _FORTIFY_SOURCE tests
debug: Synchronize feature guards in fortified functions [BZ #28746]
debug/Makefile | 115 ++++++++++++++++++----------
debug/tst-chk2.c | 2 -
debug/tst-chk3.c | 2 -
debug/tst-chk4.cc | 1 -
debug/tst-chk5.cc | 2 -
debug/tst-chk6.cc | 2 -
debug/tst-chk7.c | 2 -
debug/tst-chk8.cc | 2 -
debug/tst-fortify-c-default-1.c | 3 +
debug/tst-fortify-c-default-2.c | 3 +
debug/tst-fortify-c-default-3.c | 3 +
debug/tst-fortify-c-lfs-1.c | 3 +
debug/tst-fortify-c-lfs-2.c | 3 +
debug/tst-fortify-c-lfs-3.c | 3 +
debug/tst-fortify-c-nongnu-1.c | 3 +
debug/tst-fortify-c-nongnu-2.c | 3 +
debug/tst-fortify-c-nongnu-3.c | 3 +
debug/tst-fortify-cc-default-1.cc | 3 +
debug/tst-fortify-cc-default-2.cc | 3 +
debug/tst-fortify-cc-default-3.cc | 3 +
debug/tst-fortify-cc-lfs-1.cc | 3 +
debug/tst-fortify-cc-lfs-2.cc | 3 +
debug/tst-fortify-cc-lfs-3.cc | 3 +
debug/tst-fortify-cc-nongnu-1.cc | 3 +
debug/tst-fortify-cc-nongnu-2.cc | 3 +
debug/tst-fortify-cc-nongnu-3.cc | 3 +
debug/{tst-chk1.c => tst-fortify.c} | 49 ++++++++++--
debug/tst-lfschk1.c | 2 -
debug/tst-lfschk2.c | 2 -
debug/tst-lfschk3.c | 2 -
debug/tst-lfschk4.cc | 2 -
debug/tst-lfschk5.cc | 2 -
debug/tst-lfschk6.cc | 2 -
posix/bits/unistd.h | 2 +-
string/bits/string_fortified.h | 8 +-
support/xsignal.h | 2 +
wcsmbs/bits/wchar2.h | 2 +-
37 files changed, 177 insertions(+), 80 deletions(-)
delete mode 100644 debug/tst-chk2.c
delete mode 100644 debug/tst-chk3.c
delete mode 100644 debug/tst-chk4.cc
delete mode 100644 debug/tst-chk5.cc
delete mode 100644 debug/tst-chk6.cc
delete mode 100644 debug/tst-chk7.c
delete mode 100644 debug/tst-chk8.cc
create mode 100644 debug/tst-fortify-c-default-1.c
create mode 100644 debug/tst-fortify-c-default-2.c
create mode 100644 debug/tst-fortify-c-default-3.c
create mode 100644 debug/tst-fortify-c-lfs-1.c
create mode 100644 debug/tst-fortify-c-lfs-2.c
create mode 100644 debug/tst-fortify-c-lfs-3.c
create mode 100644 debug/tst-fortify-c-nongnu-1.c
create mode 100644 debug/tst-fortify-c-nongnu-2.c
create mode 100644 debug/tst-fortify-c-nongnu-3.c
create mode 100644 debug/tst-fortify-cc-default-1.cc
create mode 100644 debug/tst-fortify-cc-default-2.cc
create mode 100644 debug/tst-fortify-cc-default-3.cc
create mode 100644 debug/tst-fortify-cc-lfs-1.cc
create mode 100644 debug/tst-fortify-cc-lfs-2.cc
create mode 100644 debug/tst-fortify-cc-lfs-3.cc
create mode 100644 debug/tst-fortify-cc-nongnu-1.cc
create mode 100644 debug/tst-fortify-cc-nongnu-2.cc
create mode 100644 debug/tst-fortify-cc-nongnu-3.cc
rename debug/{tst-chk1.c => tst-fortify.c} (97%)
delete mode 100644 debug/tst-lfschk1.c
delete mode 100644 debug/tst-lfschk2.c
delete mode 100644 debug/tst-lfschk3.c
delete mode 100644 debug/tst-lfschk4.cc
delete mode 100644 debug/tst-lfschk5.cc
delete mode 100644 debug/tst-lfschk6.cc
--
2.33.1
next prev parent reply other threads:[~2022-01-10 15:34 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-05 1:39 [PATCH 0/2] _FORTIFY_SOURCE fixes Siddhesh Poyarekar
2022-01-05 1:39 ` [PATCH 1/2] debug: Refactor and expand _FORTIFY_SOURCE tests Siddhesh Poyarekar
2022-01-05 1:39 ` [PATCH 2/2] debug: Synchronize feature guards in fortified functions [BZ #28746] Siddhesh Poyarekar
2022-01-05 4:45 ` [PATCH v2 0/2] _FORTIFY_SOURCE fixes " Siddhesh Poyarekar
2022-01-05 4:45 ` [PATCH v2 1/2] debug: Refactor and expand _FORTIFY_SOURCE tests Siddhesh Poyarekar
2022-01-06 20:51 ` Adhemerval Zanella
2022-01-07 2:09 ` Siddhesh Poyarekar
2022-01-07 13:00 ` Adhemerval Zanella
2022-01-05 4:45 ` [PATCH v2 2/2] debug: Synchronize feature guards in fortified functions [BZ #28746] Siddhesh Poyarekar
2022-01-06 21:15 ` Adhemerval Zanella
2022-01-07 2:12 ` Siddhesh Poyarekar
2022-01-07 13:02 ` Adhemerval Zanella
2022-01-10 15:34 ` Siddhesh Poyarekar [this message]
2022-01-10 15:34 ` [PATCH v3 1/2] debug: Autogenerate _FORTIFY_SOURCE tests Siddhesh Poyarekar
2022-01-10 16:30 ` Siddhesh Poyarekar
2022-01-10 15:34 ` [PATCH v3 2/2] debug: Synchronize feature guards in fortified functions [BZ #28746] Siddhesh Poyarekar
2022-01-10 16:29 ` [PATCH v4 0/2] _FORTIFY_SOURCE fixes " Siddhesh Poyarekar
2022-01-10 16:29 ` [PATCH v4 1/2] debug: Autogenerate _FORTIFY_SOURCE tests Siddhesh Poyarekar
2022-01-11 13:27 ` Adhemerval Zanella
2022-01-11 15:28 ` Siddhesh Poyarekar
2022-01-11 16:41 ` Adhemerval Zanella
2022-01-10 16:29 ` [PATCH v4 2/2] debug: Synchronize feature guards in fortified functions [BZ #28746] Siddhesh Poyarekar
2022-01-12 5:51 ` [PATCH v5 0/2] _FORTIFY_SOURCE fixes " Siddhesh Poyarekar
2022-01-12 5:51 ` [PATCH v5 1/2] debug: Autogenerate _FORTIFY_SOURCE tests Siddhesh Poyarekar
2022-01-12 13:27 ` Adhemerval Zanella
2022-01-12 5:51 ` [PATCH v5 2/2] debug: Synchronize feature guards in fortified functions [BZ #28746] Siddhesh Poyarekar
2022-01-12 13:28 ` Adhemerval Zanella
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=20220110153417.100143-1-siddhesh@sourceware.org \
--to=siddhesh@sourceware.org \
--cc=libc-alpha@sourceware.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).