jinlin
2024-01-10 cdf29a8f6fb9990f82ccc1d3f47bfba48cfaf4fc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
package com.zt.modules.oss.encry;
 
import cn.hutool.core.io.IoUtil;
import com.zt.core.oss.encry.IOssEncryptService;
import org.springframework.stereotype.Service;
 
import java.io.File;
import java.io.InputStream;
 
@Service("noEncryptService")
public class NoEncryptService implements IOssEncryptService {
 
    public InputStream encrypt(InputStream inputStream) {
        return inputStream;
    }
 
    public InputStream decrypt(File file) {
        return IoUtil.toStream(file);
    }
 
}