fix
This commit is contained in:
@@ -8,6 +8,8 @@ import com.sunyard.chsm.utils.CodecUtils;
|
||||
*/
|
||||
public interface CryptoConst {
|
||||
|
||||
byte[] iv = CodecUtils.decodeHex("30303030303030303030303030303030");
|
||||
static byte[] iv() {
|
||||
return CodecUtils.decodeHex("30303030303030303030303030303030");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -134,6 +134,10 @@ public class TmkService {
|
||||
cipher = EccCipher.fromHex(check.getEncTmk());
|
||||
log.debug("device serial, pubKey not changed, use origin device enc tmk");
|
||||
} else {
|
||||
if (DeviceTmkStatus.finished.name().equals(check.getTmkStatus())) {
|
||||
res.setStatus(DeviceTmkStatus.available);
|
||||
return res;
|
||||
}
|
||||
log.debug("device serial, pubKey is changed, or no tmk in origin device");
|
||||
Device device = getOneByStatus(DeviceTmkStatus.finished);
|
||||
Assert.notNull(device, "系统主密钥设备异常,请联系管理员排查");
|
||||
|
||||
Reference in New Issue
Block a user