fix
This commit is contained in:
@@ -57,8 +57,8 @@ public class KeyInfoController {
|
||||
@PostMapping("/create")
|
||||
@AuditControllerLog(description = "创建密钥", operateType = AuditLogConst.ADD)
|
||||
public R<String> save(@Valid @RequestBody KeyInfoDTO.KeySave save) {
|
||||
Long id = keyInfoService.save(save);
|
||||
return R.data(String.valueOf(id));
|
||||
List<Long> ids = keyInfoService.save(save);
|
||||
return R.data(String.valueOf(ids.get(0)));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -168,8 +168,7 @@ public class SingleSdfApiService implements SdfApiService, InitializingBean {
|
||||
public byte[] encryptByTMK(byte[] data) {
|
||||
checkKey();
|
||||
byte[] pad = PaddingUtil.PKCS7Padding(data);
|
||||
sdfApiAdapter.symEncrypt(sessionHandle, tmkHandle, AlgId.SGD_SM4_CBC, new byte[8], pad);
|
||||
return new byte[0];
|
||||
return sdfApiAdapter.symEncrypt(sessionHandle, tmkHandle, AlgId.SGD_SM4_CBC, new byte[8], pad);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user