Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature/IVYPORTAL-18034-Information-exposure-through-an-error-message #1317

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import com.axonivy.portal.response.GlobalSearchResponse;
import com.axonivy.portal.service.GlobalSearchService;

import ch.ivyteam.ivy.environment.Ivy;
import ch.ivyteam.ivy.security.ISecurityConstants;
import io.swagger.v3.oas.annotations.media.Content;
import io.swagger.v3.oas.annotations.responses.ApiResponse;
Expand All @@ -30,7 +31,8 @@ public Response processes(SearchPayload payload) {
GlobalSearchResponse result = service.searchProcesses(payload);
return Response.ok(result).build();
} catch (NotFoundException e) {
return Response.status(Status.NOT_FOUND).entity(e.getMessage()).build();
Ivy.log().error(e);
return Response.status(Status.NOT_FOUND).build();
}
}

Expand All @@ -42,7 +44,8 @@ public Response tasks(SearchPayload payload) {
GlobalSearchResponse result = service.searchTasks(payload);
return Response.ok(result).build();
} catch (NotFoundException e) {
return Response.status(Status.NOT_FOUND).entity(e.getMessage()).build();
Ivy.log().error(e);
return Response.status(Status.NOT_FOUND).build();
}
}

Expand All @@ -54,7 +57,8 @@ public Response cases(SearchPayload payload) {
GlobalSearchResponse result = service.searchCases(payload);
return Response.ok(result).build();
} catch (NotFoundException e) {
return Response.status(Status.NOT_FOUND).entity(e.getMessage()).build();
Ivy.log().error(e);
return Response.status(Status.NOT_FOUND).build();
}
}
}
Loading