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

Remake console backend from JAX-RS to Spring-MVC #6755

Merged

Conversation

Matthbo
Copy link
Sponsor Member

@Matthbo Matthbo commented May 2, 2024

No description provided.

Matthbo and others added 28 commits April 15, 2024 17:19
…or spring endpoints & remade SecurityItems endpoint in spring
FileViewer in spring does currently stream
…g-web-mvc' of https://github.com/frankframework/frankframework into issue/6676-migrate-console-backend-from-jax-rs-to-spring-web-mvc
…nd-from-jax-rs-to-spring-web-mvc' into issue/6676-migrate-console-backend-from-jax-rs-to-spring-web-mvc
…g-web-mvc' of https://github.com/frankframework/frankframework into issue/6676-migrate-console-backend-from-jax-rs-to-spring-web-mvc
Comment on lines +110 to +111
SEC_LOG.info("created bus request from URI [{}:{}] issued by{} with headers [{}] payload [{}]", method, base.getServletRequest()
.getRequestURI(), issuedBy, headers, payload);

Check notice

Code scanning / SonarCloud

Logging should not be vulnerable to injection attacks

<!--SONAR_ISSUE_KEY:AY8-seApcQlkI-qXfsVr-->Change this code to not log user-controlled data. <p>See more on <a href="https://sonarcloud.io/project/issues?id=ibissource_iaf&issues=AY8-seApcQlkI-qXfsVr&open=AY8-seApcQlkI-qXfsVr&pullRequest=6755">SonarCloud</a></p>
if("GET".equalsIgnoreCase(method) || "OPTIONS".equalsIgnoreCase(method)) {
SEC_LOG.debug("created bus request from URI [{}:{}] issued by{}", method, base.getUriInfo().getRequestUri(), issuedBy);
if ("GET".equalsIgnoreCase(method) || "OPTIONS".equalsIgnoreCase(method)) {
SEC_LOG.debug("created bus request from URI [{}:{}] issued by{}", method, base.getServletRequest().getRequestURI(), issuedBy);

Check notice

Code scanning / SonarCloud

Logging should not be vulnerable to injection attacks

<!--SONAR_ISSUE_KEY:AY8-seApcQlkI-qXfsVs-->Change this code to not log user-controlled data. <p>See more on <a href="https://sonarcloud.io/project/issues?id=ibissource_iaf&issues=AY8-seApcQlkI-qXfsVs&open=AY8-seApcQlkI-qXfsVs&pullRequest=6755">SonarCloud</a></p>
// This event listens to all Spring refresh events.
// When adding new Spring contexts (with this as a parent) refresh events originating from other contexts will also trigger this method.
// Since we never want to reinitialize this servlet, we can ignore the 'refresh' event completely!
super.doService(request, response);

Check notice

Code scanning / SonarCloud

Exceptions should not be thrown from servlet methods

<!--SONAR_ISSUE_KEY:AY8-seCTcQlkI-qXfsW4-->Handle the following exception that could be thrown by "doService": Exception. <p>See more on <a href="https://sonarcloud.io/project/issues?id=ibissource_iaf&issues=AY8-seCTcQlkI-qXfsW4&open=AY8-seCTcQlkI-qXfsW4&pullRequest=6755">SonarCloud</a></p>
@Matthbo Matthbo requested a review from jkosternl May 29, 2024 13:57
…nd-from-jax-rs-to-spring-web-mvc' into issue/6676-migrate-console-backend-from-jax-rs-to-spring-web-mvc
Copy link
Sponsor Member

@nielsm5 nielsm5 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ik heb niet alle tests bekeken maar voor de rest lijkt het allemaal naar behoren te werken 🎉


import org.springframework.web.filter.ShallowEtagHeaderFilter;

public class WeakShallowEtagHeaderFilter extends ShallowEtagHeaderFilter {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding this reason in this PR is nice, but won't be seen in the future. Please use Javadoc instead.

Copy link

sonarcloud bot commented May 30, 2024

Quality Gate Failed Quality Gate failed

Failed conditions
27.5% Coverage on New Code (required ≥ 65%)
C Reliability Rating on New Code (required ≥ A)
B Security Rating on New Code (required ≥ A)

See analysis details on SonarCloud

Catch issues before they fail your Quality Gate with our IDE extension SonarLint

@nielsm5 nielsm5 merged commit af33964 into master May 30, 2024
13 of 16 checks passed
@nielsm5 nielsm5 deleted the issue/6676-migrate-console-backend-from-jax-rs-to-spring-web-mvc branch May 30, 2024 10:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Migrate Console Backend from JAX-RS to Spring Web MVC
4 participants