Date: Wed, 15 May 2024 14:39:44 +0200 From: Alexander Leidinger <Alexander@Leidinger.net> To: Kyle Evans <kevans@freebsd.org> Cc: "freebsd-hackers@FreeBSD.org" <freebsd-hackers@freebsd.org> Subject: Re: Initial implementation of _FORTIFY_SOURCE Message-ID: <fc68c3ee9085d4b0c81ae1b40ca96220@Leidinger.net> In-Reply-To: <b77dee76-34e0-4a22-808a-bdbca33bc7dd@FreeBSD.org> References: <f8000e6b-226b-45f3-a751-aca790f4f8c8@FreeBSD.org> <83ac28b8e8e79866facbde716b051340@Leidinger.net> <97f000a2-eba8-4767-91e3-d5f311fa4e72@FreeBSD.org> <b77dee76-34e0-4a22-808a-bdbca33bc7dd@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
Am 2024-05-15 01:15, schrieb Kyle Evans:
> I've confirmed that this patch fixes libfido2, will commit shortly.
I can confirm too.
If I want to test this on more ports, I have to add -D_FORTIFY_SOURCE=2
to the CFLAGS / CSSFLAGS? Or rather do this:
---snip---
diff --git a/Mk/Features/ssp.mk b/Mk/Features/ssp.mk
index 4213e6d668a..545e74bfa05 100644
--- a/Mk/Features/ssp.mk
+++ b/Mk/Features/ssp.mk
@@ -7,8 +7,10 @@ SSP_Include_MAINTAINER= portmgr@FreeBSD.org
. if !defined(SSP_UNSAFE) && \
(! ${ARCH:Mmips*})
# Overridable as a user may want to use -fstack-protector-all
-SSP_CFLAGS?= -fstack-protector-strong
+SSP_CFLAGS?= -fstack-protector-strong -D_FORTIFY_SOURCE=2
+SSP_LDFLAGS?= -fstack-protector-strong
CFLAGS+= ${SSP_CFLAGS}
-LDFLAGS+= ${SSP_CFLAGS}
+CXXFLAGS+= ${SSP_CFLAGS}
+LDFLAGS+= ${SSP_LDFLAGS}
. endif
.endif
---snip---
Bye,
Alexander.
--
http://www.Leidinger.net Alexander@Leidinger.net: PGP 0x8F31830F9F2772BF
http://www.FreeBSD.org netchild@FreeBSD.org : PGP 0x8F31830F9F2772BF
[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCAAdFiEER9UlYXp1PSd08nWXEg2wmwP42IYFAmZErR8ACgkQEg2wmwP4
2IYWRQ//aIc6OlvzwY/3OYm95qKK3O9I3xVTq6/u0IgD+BY+MhMTXx/Ba2jruGZE
MKeLrRObyS9V8gfbLgDAbuajI+UIBuIszVdm1YqXy3EfPAZQXWWB+W+pJDPgQzvQ
zFNFrV6cQTYjVqkiUgD3/OX1pVoAesR7xlBdi+gTj7hGI7TmZ48qRzezz2MLmEX1
OZddhbmfXfPlFDH0hrFhlugROQbEpH4iZlI5J+vp8XPrWKIYD9alvTmTbH1iyrss
okQB3xet16ZyR+dft2s2+Bwa7t+bKVltAdAHFeNR5GuCghhPAoCt+N2OzFRxLa8m
zIRvcSLyZ8xCpElHS6nybeeXfRjj7sUUVPwOpcH5UO0T9SnqhBA42C3reA36mCwl
PT3YAwWGtFUsuPUt1C7lmsIJYIMB8wWXlSqnOkbY6BzUl1E0xRNCdeAFllUXk/Q3
bOTwtk5IcsDMiN9xQjbmvu0XEf8g6KRSM5pfsEucKScpyqB+XWTucFX3r6koTWbc
0otRMq/5wmzjcaCOAJHimGl+BHOldYy+EeP0nqTL1pxroLnkVHOAzqBhX/aBwDPF
0aGSbZOKeetteadb4riEoF+mBHaUg0/YT5u0Wox+9hL7e/9wVqCRLUpL8bZjNC9Z
ZBJHuMOfA4K0bTMJxxNbg9BARjH5rxe+c3k1Dak8XJpVmHpz9yk=
=Ozjo
-----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?fc68c3ee9085d4b0c81ae1b40ca96220>
