Sync code

(cherry picked from commit 51cee96d9ccc43a11377b1be4d27df25e52ae715)
This commit is contained in:
starlet-dx 2024-03-26 16:02:38 +08:00 committed by openeuler-sync-bot
parent 7f60f6db8d
commit db5cf64d06
2 changed files with 51 additions and 1 deletions

View File

@ -0,0 +1,42 @@
From 006551b798d9066ca8cbd3f01b2309329c4ca20c Mon Sep 17 00:00:00 2001
From: yangchenguang <yangchenguang@kylinsec.com.cn>
Date: Fri, 12 May 2023 14:38:23 +0800
Subject: [PATCH] Add loongarch64 support
Signed-off-by: yangchenguang <yangchenguang@kylinsec.com.cn>
---
programs/addconn/addconn.c | 2 ++
programs/pluto/pluto_seccomp.c | 2 ++
2 files changed, 4 insertions(+)
diff --git a/programs/addconn/addconn.c b/programs/addconn/addconn.c
index 527d5cf..900a6c7 100644
--- a/programs/addconn/addconn.c
+++ b/programs/addconn/addconn.c
@@ -99,7 +99,9 @@ static void init_seccomp_addconn(uint32_t def_action, struct logger *logger)
LSW_SECCOMP_ADD(epoll_pwait);
LSW_SECCOMP_ADD(exit_group);
LSW_SECCOMP_ADD(fcntl);
+#ifndef __loongarch64
LSW_SECCOMP_ADD(fstat);
+#endif
LSW_SECCOMP_ADD(futex);
LSW_SECCOMP_ADD(getdents);
LSW_SECCOMP_ADD(getegid);
diff --git a/programs/pluto/pluto_seccomp.c b/programs/pluto/pluto_seccomp.c
index 27b1560..775033f 100644
--- a/programs/pluto/pluto_seccomp.c
+++ b/programs/pluto/pluto_seccomp.c
@@ -138,7 +138,9 @@ static void init_seccomp(uint32_t def_action, bool main, struct logger *logger)
LSW_SECCOMP_ADD(exit);
LSW_SECCOMP_ADD(exit_group);
LSW_SECCOMP_ADD(fcntl);
+#ifndef __loongarch64
LSW_SECCOMP_ADD(fstat);
+#endif
LSW_SECCOMP_ADD(futex);
LSW_SECCOMP_ADD(getpid);
LSW_SECCOMP_ADD(gettid);
--
2.34.1

View File

@ -35,6 +35,8 @@ Source2: https://download.libreswan.org/cavs/ikev1_psk.fax.bz2
Source3: https://download.libreswan.org/cavs/ikev2.fax.bz2
Source4: openeuler-libreswan-sysctl.conf
Patch3000: 3000-Add-loongarch64-support.patch
BuildRequires: audit-libs-devel
BuildRequires: bison
BuildRequires: curl-devel
@ -190,9 +192,15 @@ certutil -N -d sql:$tmpdir --empty-password
%attr(0644,root,root) %doc %{_mandir}/*/*
%changelog
* Tue Mar 12 2024 yaoxin <yao_xin001@hoperun.com> - 4.14-1
* Tue Mar 26 2024 yaoxin <yao_xin001@hoperun.com> - 4.14-1
- Upgrade to 4.14 for fix CVE-2024-2357
* Mon Sep 11 2023 penghaitao <htpengc@isoftstone.com> - 4.12-3
- Fix build error of 3000-Add-loongarch64-support.patch
* Mon Aug 14 2023 suwei <suwei@kylinsec.com.cn> - 4.12-2
- Add loongarch64 support
* Sat Aug 12 2023 Funda Wang <fundawang@yeah.net> - 4.12-1
- Update to 4.12 for CVE-2023-38710, CVE-2023-38711 and CVE-2023-38712