java.lang.Object
io.mosip.kernel.auth.defaultimpl.repository.impl.KeycloakImpl
All Implemented Interfaces:
DataStore

@Component public class KeycloakImpl extends Object implements DataStore
  • Constructor Details

    • KeycloakImpl

      public KeycloakImpl()
  • Method Details

    • getAllRoles

      public io.mosip.kernel.core.authmanager.model.RolesListDto getAllRoles(String appId)
      Specified by:
      getAllRoles in interface DataStore
    • getListOfUsersDetails

      public io.mosip.kernel.core.authmanager.model.MosipUserListDto getListOfUsersDetails(List<String> userDetails, String realmId) throws Exception
      Specified by:
      getListOfUsersDetails in interface DataStore
      Throws:
      Exception
    • getAllUserDetailsWithSalt

      public io.mosip.kernel.core.authmanager.model.MosipUserSaltListDto getAllUserDetailsWithSalt(List<String> userDetails, String appId) throws Exception
      Specified by:
      getAllUserDetailsWithSalt in interface DataStore
      Throws:
      Exception
    • getRidFromUserId

      public io.mosip.kernel.core.authmanager.model.RIdDto getRidFromUserId(String userId, String appId) throws Exception
      Specified by:
      getRidFromUserId in interface DataStore
      Throws:
      Exception
    • unBlockAccount

      public io.mosip.kernel.core.authmanager.model.AuthZResponseDto unBlockAccount(String userId) throws Exception
      Specified by:
      unBlockAccount in interface DataStore
      Throws:
      Exception
    • registerUser

      public io.mosip.kernel.core.authmanager.model.MosipUserDto registerUser(io.mosip.kernel.core.authmanager.model.UserRegistrationRequestDto userId)
      Specified by:
      registerUser in interface DataStore
    • isUserAlreadyPresent

      public boolean isUserAlreadyPresent(String userName, String realmId)
      Checks if is user already present.
      Parameters:
      userName - the user name
      Returns:
      true, if successful
      Throws:
      IOException - Signals that an I/O exception has occurred.
    • addPassword

      public io.mosip.kernel.core.authmanager.model.UserPasswordResponseDto addPassword(io.mosip.kernel.core.authmanager.model.UserPasswordRequestDto userPasswordRequestDto)
      Specified by:
      addPassword in interface DataStore
    • changePassword

      public io.mosip.kernel.core.authmanager.model.AuthZResponseDto changePassword(io.mosip.kernel.core.authmanager.model.PasswordDto passwordDto) throws Exception
      Specified by:
      changePassword in interface DataStore
      Throws:
      Exception
    • resetPassword

      public io.mosip.kernel.core.authmanager.model.AuthZResponseDto resetPassword(io.mosip.kernel.core.authmanager.model.PasswordDto passwordDto) throws Exception
      Specified by:
      resetPassword in interface DataStore
      Throws:
      Exception
    • getUserNameBasedOnMobileNumber

      public io.mosip.kernel.core.authmanager.model.UserNameDto getUserNameBasedOnMobileNumber(String mobileNumber) throws Exception
      Specified by:
      getUserNameBasedOnMobileNumber in interface DataStore
      Throws:
      Exception
    • authenticateUser

      public io.mosip.kernel.core.authmanager.model.MosipUserDto authenticateUser(io.mosip.kernel.core.authmanager.model.LoginUser loginUser) throws Exception
      Specified by:
      authenticateUser in interface DataStore
      Throws:
      Exception
    • authenticateWithOtp

      public io.mosip.kernel.core.authmanager.model.MosipUserDto authenticateWithOtp(io.mosip.kernel.core.authmanager.model.OtpUser otpUser) throws Exception
      Specified by:
      authenticateWithOtp in interface DataStore
      Throws:
      Exception
    • authenticateUserWithOtp

      public io.mosip.kernel.core.authmanager.model.MosipUserDto authenticateUserWithOtp(io.mosip.kernel.core.authmanager.model.UserOtp loginUser) throws Exception
      Specified by:
      authenticateUserWithOtp in interface DataStore
      Throws:
      Exception
    • authenticateWithSecretKey

      public io.mosip.kernel.core.authmanager.model.MosipUserDto authenticateWithSecretKey(io.mosip.kernel.core.authmanager.model.ClientSecret clientSecret) throws Exception
      Specified by:
      authenticateWithSecretKey in interface DataStore
      Throws:
      Exception
    • getUserRoleByUserId

      public io.mosip.kernel.core.authmanager.model.MosipUserDto getUserRoleByUserId(String username) throws Exception
      Specified by:
      getUserRoleByUserId in interface DataStore
      Throws:
      Exception
    • getUserDetailBasedonMobileNumber

      public io.mosip.kernel.core.authmanager.model.MosipUserDto getUserDetailBasedonMobileNumber(String mobileNumber) throws Exception
      Specified by:
      getUserDetailBasedonMobileNumber in interface DataStore
      Throws:
      Exception
    • validateUserName

      public io.mosip.kernel.core.authmanager.model.ValidationResponseDto validateUserName(String userId)
      Specified by:
      validateUserName in interface DataStore
    • getUserDetailBasedOnUid

      public io.mosip.kernel.core.authmanager.model.UserDetailsResponseDto getUserDetailBasedOnUid(List<String> userIds)
      Specified by:
      getUserDetailBasedOnUid in interface DataStore
    • getIndividualIdFromUserId

      public io.mosip.kernel.core.authmanager.model.IndividualIdDto getIndividualIdFromUserId(String userId, String realmID)
      Specified by:
      getIndividualIdFromUserId in interface DataStore
    • getListOfUsersDetails

      public io.mosip.kernel.core.authmanager.model.MosipUserListDto getListOfUsersDetails(String realmId, String roleName, int pageStart, int pageFetch, String email, String firstName, String lastName, String username, String search)
      Specified by:
      getListOfUsersDetails in interface DataStore