Skip to content

Conversation

halibobo1205
Copy link
Contributor

What does this PR do?
Revert the change to HTTP error message handling, pre PR #6417
Why are these changes required?
The workaround broke clients depending on the original error output.
This PR has been tested by:

  • Unit Tests
  • Manual Testing

Follow up
We may need to open a new issue to discuss how to resolve this warning going forward.
Extra details

  Revert change to HTTP error message handling — workaround broke clients
  depending on original error output.
@halibobo1205 halibobo1205 changed the title CodeQL(http/response): revert workaround for java/error-message-exposure api(CodeQL): revert error message exposure in http response Sep 16, 2025
response.getWriter().println(e.getMessage());
} catch (IOException ioe) {
logger.debug("IOException: {}", ioe.getMessage());
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe it's not a good idea to modify the error message and remove Exception for every API. A better solution would be to update the implementation of Util.processError uniformly.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@317787106 This is a legacy API; do not modify anything, even the error messages.

Copy link
Contributor

Choose a reason for hiding this comment

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

Get it

@kuny0707 kuny0707 merged commit 316de9a into tronprotocol:release_v4.8.1 Sep 18, 2025
7 checks passed
@github-project-automation github-project-automation bot moved this from In Review to Done in java-tron Sep 18, 2025
halibobo1205 added a commit to halibobo1205/java-tron that referenced this pull request Oct 14, 2025
…ronprotocol#6449)

Revert change to HTTP error message handling — workaround broke clients
  depending on original error output.
@kuny0707 kuny0707 changed the title api(CodeQL): revert error message exposure in http response api(CodeQL): fix error message exposure in http response Oct 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants