Class AuthenticationService

java.lang.Object
com.jangular.backend.service.AuthenticationService

@Service public class AuthenticationService extends Object
  • Constructor Details

    • AuthenticationService

      public AuthenticationService()
  • Method Details

    • authenticate

      @Transactional public AuthResponse authenticate(AuthRequest request, String ipAddress, String userAgent)
      Authenticate user and generate JWT tokens
    • refreshToken

      public AuthResponse refreshToken(String refreshToken)
      Refresh access token using refresh token
    • logout

      @Transactional public void logout(String token)
      Logout user (in a complete implementation, you might want to blacklist the token)
    • changePassword

      @Transactional public void changePassword(Long userId, String oldPassword, String newPassword)
      Change user password