mirror of
				https://github.com/continew-org/continew-admin.git
				synced 2025-10-31 00:57:13 +08:00 
			
		
		
		
	| @@ -76,7 +76,6 @@ public class StorageReq extends BaseReq { | ||||
|      * 私有密钥 | ||||
|      */ | ||||
|     @Schema(description = "私有密钥", example = "") | ||||
|     @Length(max = 255, message = "私有密钥长度不能超过 {max} 个字符") | ||||
|     private String secretKey; | ||||
|  | ||||
|     /** | ||||
|   | ||||
| @@ -189,6 +189,7 @@ public class StorageServiceImpl extends BaseServiceImpl<StorageMapper, StorageDO | ||||
|         // 新增时或修改了 SecretKey | ||||
|         String secretKey = ExceptionUtils.exToNull(() -> SecureUtils.decryptByRsaPrivateKey(newSecretKey)); | ||||
|         ValidationUtils.throwIfNull(secretKey, "私有密钥解密失败"); | ||||
|         ValidationUtils.throwIf(secretKey.length() > 255, "私有密钥长度不能超过 255 个字符"); | ||||
|         req.setSecretKey(secretKey); | ||||
|     } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user