add:新增webdav相关功能,修复安全隐患

This commit is contained in:
tiansh
2024-01-23 17:41:51 +08:00
parent f02d865389
commit 44814e79b0
19 changed files with 199 additions and 114 deletions
@@ -67,7 +67,7 @@ public class ClientService {
return msg;
}
u2.setEmail(email);
u2.setPassword(Base64Encryption.encryptBASE64(pass.getBytes()));
u2.setPassword(Base64.getEncoder().encodeToString(pass.getBytes()));
User u = userMapper.getUsers(u2);
if (null == u || u.getIsok() != 1) {
msg.setCode("4006");
@@ -142,8 +142,10 @@ public class ClientService {
imgnameEd = updatePath + "/" + shortUuid_y + "." + prefix;
imgObj.setImgname(imgnameEd);
if (key.getStorageType().equals(5)) {
imgObj.setImgurl(key.getRequestAddress() + "/ota/" + imgnameEd);
} else {
imgObj.setImgurl(confdata.getString("domain") + "/ota/" + imgnameEd);
} else if(key.getStorageType().equals(9) && key.getSysTransmit()){
imgObj.setImgurl(confdata.getString("domain") + "/w/" + shortUuid_y);
}else {
imgObj.setImgurl(key.getRequestAddress() + "/" + imgnameEd);
}
imgObj.setSizes(Long.toString(file.length()));