summaryrefslogtreecommitdiff
path: root/0161-bugfix-for-workdir-len-verify.patch
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2025-01-11 14:20:43 +0000
committerCoprDistGit <infra@openeuler.org>2025-01-11 14:20:43 +0000
commit2295e96f69a8c13751ba69ea9176b0599c0909a8 (patch)
treec908aaed1b7f92c2e5aaa55ac6981ebe00dfe9bf /0161-bugfix-for-workdir-len-verify.patch
parentb7a2cf915b9d2c7e530c02097631b69bacc0e93c (diff)
automatic import of iSuladopeneuler24.03_LTS
Diffstat (limited to '0161-bugfix-for-workdir-len-verify.patch')
-rw-r--r--0161-bugfix-for-workdir-len-verify.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/0161-bugfix-for-workdir-len-verify.patch b/0161-bugfix-for-workdir-len-verify.patch
new file mode 100644
index 0000000..238e9b5
--- /dev/null
+++ b/0161-bugfix-for-workdir-len-verify.patch
@@ -0,0 +1,28 @@
+From 3c9d51bfdf0e71ac846946d746003139bf3a02c8 Mon Sep 17 00:00:00 2001
+From: zhongtao <zhongtao17@huawei.com>
+Date: Tue, 26 Nov 2024 23:46:52 +1400
+Subject: [PATCH 03/19] bugfix for workdir len verify
+
+Signed-off-by: zhongtao <zhongtao17@huawei.com>
+---
+ src/daemon/modules/runtime/isula/isula_rt_ops.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/daemon/modules/runtime/isula/isula_rt_ops.c b/src/daemon/modules/runtime/isula/isula_rt_ops.c
+index e628c3fe..22608e4c 100644
+--- a/src/daemon/modules/runtime/isula/isula_rt_ops.c
++++ b/src/daemon/modules/runtime/isula/isula_rt_ops.c
+@@ -786,8 +786,8 @@ static int shielded_output_check(const char *output, const char *workdir)
+ return 0;
+ }
+
+- if (sizeof(chdir_pattern) > PATH_MAX - strlen("chdir ") - strlen(" failed")) {
+- INFO("chdir_pattern is too long");
++ if (strlen(workdir) > PATH_MAX - strlen("chdir ") - strlen(" failed")) {
++ INFO("workdir is too long");
+ return -1;
+ }
+
+--
+2.23.0
+