标签:code work rac p12 读取 cer cert org 获取文件
支持linux下读取
import org.springframework.core.io.ClassPathResource; public InputStream getCertStream() { try { ClassPathResource classPathResource = new ClassPathResource("config/apiclient_cert.p12"); //获取文件流 InputStream certStream = classPathResource.getInputStream(); this.certData = IOUtils.toByteArray(certStream); certStream.read(this.certData); certStream.close(); } catch (IOException e) { e.printStackTrace(); } }
标签:code work rac p12 读取 cer cert org 获取文件
原文地址:https://www.cnblogs.com/fengqiaoyebo/p/10120790.html