spdk: use -fstack-protector-strong instead of -fstack-protector for stronger security.

Signed-off-by: Zhiqiang Liu <liuzhiqiang26@huawei.com>
This commit is contained in:
Zhiqiang Liu 2021-09-13 21:40:45 +08:00
parent ab1056dd30
commit 76b60ec6b3
2 changed files with 36 additions and 1 deletions

View File

@ -0,0 +1,30 @@
From b1959244d8178975119606e9fc1323dbee06c18f Mon Sep 17 00:00:00 2001
From: Zhiqiang Liu <liuzhiqiang26@huawei.com>
Date: Mon, 13 Sep 2021 21:36:51 +0800
Subject: [PATCH] spdk: use -fstack-protector-strong instead of
-fstack-protector
use -fstack-protector-strong instead of -fstack-protector for
stronger security.
Signed-off-by: Zhiqiang Liu <liuzhiqiang26@huawei.com>
---
mk/spdk.common.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mk/spdk.common.mk b/mk/spdk.common.mk
index f3fe5c2..dc8ed69 100644
--- a/mk/spdk.common.mk
+++ b/mk/spdk.common.mk
@@ -120,7 +120,7 @@ COMMON_CFLAGS += -D_GNU_SOURCE
COMMON_CFLAGS += -fPIC
# Enable stack buffer overflow checking
-COMMON_CFLAGS += -fstack-protector
+COMMON_CFLAGS += -fstack-protector-strong
# Prevent accidental multiple definitions of global variables
COMMON_CFLAGS += -fno-common
--
1.8.3.1

View File

@ -3,7 +3,7 @@
Name: spdk
Version: 21.01
Release: 4
Release: 5
Summary: Set of libraries and utilities for high performance user-mode storage
License: BSD and MIT
URL: http://spdk.io
@ -36,6 +36,7 @@ Patch25: 0025-nvmf-fix-fd-leakage-problem-in-nvmf_vfio_user_listen.patch
Patch26: 0026-posix-set-fd-to-1-after-close-fd-in-posix_sock_creat.patch
Patch27: 0027-spdk_top-check-return-value-of-strdup-in-store_last_.patch
Patch28: 0028-uring-set-fd-to-1-after-close-fd-in-uring_sock_creat.patch
Patch29: 0029-spdk-use-fstack-protector-strong-instead-of-fstack-p.patch
%define package_version %{version}-%{release}
@ -196,6 +197,10 @@ mv doc/output/html/ %{install_docdir}
%changelog
* Mon Sep 13 2021 Zhiqiang Liu <liuzhiqiang26@huawei.com> - 21.01-5
- use -fstack-protector-strong instead of -fstack-protector for
stronger security.
* Sat Jul 24 2021 Zhiqiang Liu <liuzhiqiang26@huawei.com> - 21.01-4
- backport 13 bugfix from upstream