You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by yi...@apache.org on 2025/12/11 11:25:08 UTC
(doris) branch branch-4.0 updated: branch-4.0: [chore](security) Add ssrf check for create stage #58585 (#58875)
This is an automated email from the ASF dual-hosted git repository.
yiguolei pushed a commit to branch branch-4.0
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/branch-4.0 by this push:
new 18054665cfc branch-4.0: [chore](security) Add ssrf check for create stage #58585 (#58875)
18054665cfc is described below
commit 18054665cfcac1081ad4b54beead714b84292663
Author: github-actions[bot] <41...@users.noreply.github.com>
AuthorDate: Thu Dec 11 19:25:02 2025 +0800
branch-4.0: [chore](security) Add ssrf check for create stage #58585 (#58875)
Cherry-picked from #58585
Co-authored-by: Gavin Chou <ga...@selectdb.com>
---
.../apache/doris/nereids/trees/plans/commands/CreateStageCommand.java | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/CreateStageCommand.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/CreateStageCommand.java
index 0b9a15c506e..907c2edddae 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/CreateStageCommand.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/CreateStageCommand.java
@@ -29,6 +29,7 @@ import org.apache.doris.cloud.proto.Cloud.RamUserPB;
import org.apache.doris.cloud.proto.Cloud.StagePB;
import org.apache.doris.cloud.proto.Cloud.StagePB.StageAccessType;
import org.apache.doris.cloud.proto.Cloud.StagePB.StageType;
+import org.apache.doris.cloud.security.SecurityChecker;
import org.apache.doris.cloud.storage.RemoteBase;
import org.apache.doris.cloud.storage.RemoteBase.ObjectInfo;
import org.apache.doris.common.AnalysisException;
@@ -148,6 +149,7 @@ public class CreateStageCommand extends Command implements ForwardWithSync, Need
String urlStr = "http://" + endpoint;
// TODO: Server-Side Request Forgery Check is still need?
URL url = new URL(urlStr);
+ SecurityChecker.getInstance().startSSRFChecking(urlStr);
connection = (HttpURLConnection) url.openConnection();
connection.setConnectTimeout(10000);
connection.connect();
@@ -164,6 +166,7 @@ public class CreateStageCommand extends Command implements ForwardWithSync, Need
LOG.warn("Failed to disconnect connection, endpoint={}", endpoint, e);
}
}
+ SecurityChecker.getInstance().stopSSRFChecking();
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org