Class KeymanagerServiceImpl
- java.lang.Object
-
- io.mosip.kernel.keymanagerservice.service.impl.KeymanagerServiceImpl
-
- All Implemented Interfaces:
KeymanagerService
@Service @Transactional public class KeymanagerServiceImpl extends Object implements KeymanagerService
This class provides the implementation for the methods of KeymanagerService interface.- Since:
- 1.0.0
- Author:
- Dharmesh Khandelwal, Urvil Joshi, Srinivasan
-
-
Constructor Summary
Constructors Constructor Description KeymanagerServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SymmetricKeyResponseDtodecryptSymmetricKey(SymmetricKeyRequestDto symmetricKeyRequestDto)Function to decrypt symmetric keyKeyPairGenerateResponseDtogenerateCSR(CSRGenerateRequestDto csrGenRequestDto)Function to get CSR for the provided appId & refId.KeyPairGenerateResponseDtogenerateMasterKey(String responseObjectType, KeyPairGenerateRequestDto request)Function to generate Master key pair in the HSM specified in config.KeyPairGenerateResponseDtogetCertificate(String appId, Optional<String> refId)Function to get certificate for the provided appId & refId.SignatureCertificategetSignatureCertificate(String applicationId, Optional<String> referenceId, String timestamp)PublicKeyResponse<String>getSignPublicKey(String applicationId, String timestamp, Optional<String> referenceId)Function to get public keyUploadCertificateResponseDtouploadCertificate(UploadCertificateRequestDto uploadCertRequestDto)Function to upload certificate for the provided appId & refId.UploadCertificateResponseDtouploadOtherDomainCertificate(UploadCertificateRequestDto uploadCertRequestDto)Function to upload other domain certificate for the provided appId & refId.
-
-
-
Method Detail
-
decryptSymmetricKey
public SymmetricKeyResponseDto decryptSymmetricKey(SymmetricKeyRequestDto symmetricKeyRequestDto)
Description copied from interface:KeymanagerServiceFunction to decrypt symmetric key- Specified by:
decryptSymmetricKeyin interfaceKeymanagerService- Parameters:
symmetricKeyRequestDto- symmetricKeyRequestDto- Returns:
SymmetricKeyResponseDtoinstance
-
getSignatureCertificate
public SignatureCertificate getSignatureCertificate(String applicationId, Optional<String> referenceId, String timestamp)
- Specified by:
getSignatureCertificatein interfaceKeymanagerService
-
getSignPublicKey
public PublicKeyResponse<String> getSignPublicKey(String applicationId, String timestamp, Optional<String> referenceId)
Description copied from interface:KeymanagerServiceFunction to get public key- Specified by:
getSignPublicKeyin interfaceKeymanagerService- Parameters:
applicationId- applicationIdtimestamp- timeStampreferenceId- referenceId- Returns:
PublicKeyResponseinstance
-
generateMasterKey
public KeyPairGenerateResponseDto generateMasterKey(String responseObjectType, KeyPairGenerateRequestDto request)
Description copied from interface:KeymanagerServiceFunction to generate Master key pair in the HSM specified in config.- Specified by:
generateMasterKeyin interfaceKeymanagerService- Returns:
KeyPairGenerateResponseDtoinstance
-
getCertificate
public KeyPairGenerateResponseDto getCertificate(String appId, Optional<String> refId)
Description copied from interface:KeymanagerServiceFunction to get certificate for the provided appId & refId.- Specified by:
getCertificatein interfaceKeymanagerService- Returns:
KeyPairGenerateResponseDtoinstance
-
generateCSR
public KeyPairGenerateResponseDto generateCSR(CSRGenerateRequestDto csrGenRequestDto)
Description copied from interface:KeymanagerServiceFunction to get CSR for the provided appId & refId.- Specified by:
generateCSRin interfaceKeymanagerService- Returns:
KeyPairGenerateResponseDtoinstance
-
uploadCertificate
public UploadCertificateResponseDto uploadCertificate(UploadCertificateRequestDto uploadCertRequestDto)
Description copied from interface:KeymanagerServiceFunction to upload certificate for the provided appId & refId.- Specified by:
uploadCertificatein interfaceKeymanagerService- Returns:
UploadCertificateResponseDtoinstance
-
uploadOtherDomainCertificate
public UploadCertificateResponseDto uploadOtherDomainCertificate(UploadCertificateRequestDto uploadCertRequestDto)
Description copied from interface:KeymanagerServiceFunction to upload other domain certificate for the provided appId & refId.- Specified by:
uploadOtherDomainCertificatein interfaceKeymanagerService- Returns:
UploadCertificateResponseDtoinstance
-
-