From 4470052c3b6bdeb18e45987f8aa293d1e93d0552 Mon Sep 17 00:00:00 2001
From: Ludc <2870569285@qq.com>
Date: 星期二, 18 十一月 2025 11:59:12 +0800
Subject: [PATCH] 所有文件上传接口增加文件安全校验逻辑。
---
Source/BladeX-Tool/blade-core-launch/src/main/java/org/springblade/core/launch/constant/NacosConstant.java | 128 ++++++++++++++++++++++++++++++++++++++++++
1 files changed, 128 insertions(+), 0 deletions(-)
diff --git a/Source/BladeX-Tool/blade-core-launch/src/main/java/org/springblade/core/launch/constant/NacosConstant.java b/Source/BladeX-Tool/blade-core-launch/src/main/java/org/springblade/core/launch/constant/NacosConstant.java
new file mode 100644
index 0000000..786e690
--- /dev/null
+++ b/Source/BladeX-Tool/blade-core-launch/src/main/java/org/springblade/core/launch/constant/NacosConstant.java
@@ -0,0 +1,128 @@
+/*
+ * Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *
+ * Redistributions of source code must retain the above copyright notice,
+ * this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * Neither the name of the dreamlu.net developer nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ * Author: Chill 搴勯獮 (smallchill@163.com)
+ */
+package org.springblade.core.launch.constant;
+
+/**
+ * Nacos甯搁噺.
+ *
+ * @author Chill
+ */
+public interface NacosConstant {
+
+ /**
+ * nacos 鍦板潃
+ */
+ String NACOS_ADDR = "127.0.0.1:8848";
+
+ /**
+ * nacos 閰嶇疆鍓嶇紑
+ */
+ String NACOS_CONFIG_PREFIX = "blade";
+
+ /**
+ * nacos 缁勯厤缃悗缂�
+ */
+ String NACOS_GROUP_SUFFIX = "-group";
+
+ /**
+ * nacos 閰嶇疆鏂囦欢绫诲瀷
+ */
+ String NACOS_CONFIG_FORMAT = "yaml";
+
+ /**
+ * nacos json閰嶇疆鏂囦欢绫诲瀷
+ */
+ String NACOS_CONFIG_JSON_FORMAT = "json";
+
+ /**
+ * nacos 鏄惁鍒锋柊
+ */
+ String NACOS_CONFIG_REFRESH = "true";
+
+ /**
+ * nacos 鍒嗙粍
+ */
+ String NACOS_CONFIG_GROUP = "DEFAULT_GROUP";
+
+ /**
+ * seata 鍒嗙粍
+ */
+ String NACOS_SEATA_GROUP = "SEATA_GROUP";
+
+ /**
+ * 鏋勫缓鏈嶅姟瀵瑰簲鐨� dataId
+ *
+ * @param appName 鏈嶅姟鍚�
+ * @return dataId
+ */
+ static String dataId(String appName) {
+ return appName + "." + NACOS_CONFIG_FORMAT;
+ }
+
+ /**
+ * 鏋勫缓鏈嶅姟瀵瑰簲鐨� dataId
+ *
+ * @param appName 鏈嶅姟鍚�
+ * @param profile 鐜鍙橀噺
+ * @return dataId
+ */
+ static String dataId(String appName, String profile) {
+ return dataId(appName, profile, NACOS_CONFIG_FORMAT);
+ }
+
+ /**
+ * 鏋勫缓鏈嶅姟瀵瑰簲鐨� dataId
+ *
+ * @param appName 鏈嶅姟鍚�
+ * @param profile 鐜鍙橀噺
+ * @param format 鏂囦欢绫诲瀷
+ * @return dataId
+ */
+ static String dataId(String appName, String profile, String format) {
+ return appName + "-" + profile + "." + format;
+ }
+
+ /**
+ * 鏈嶅姟榛樿鍔犺浇鐨勯厤缃�
+ *
+ * @return sharedDataIds
+ */
+ static String sharedDataId() {
+ return NACOS_CONFIG_PREFIX + "." + NACOS_CONFIG_FORMAT;
+ }
+
+ /**
+ * 鏈嶅姟榛樿鍔犺浇鐨勯厤缃�
+ *
+ * @param profile 鐜鍙橀噺
+ * @return sharedDataIds
+ */
+ static String sharedDataId(String profile) {
+ return NACOS_CONFIG_PREFIX + "-" + profile + "." + NACOS_CONFIG_FORMAT;
+ }
+
+ /**
+ * 鏈嶅姟榛樿鍔犺浇鐨勯厤缃�
+ *
+ * @param profile 鐜鍙橀噺
+ * @return sharedDataIds
+ */
+ static String sharedDataIds(String profile) {
+ return NACOS_CONFIG_PREFIX + "." + NACOS_CONFIG_FORMAT + "," + NACOS_CONFIG_PREFIX + "-" + profile + "." + NACOS_CONFIG_FORMAT;
+ }
+
+}
--
Gitblit v1.10.0