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

NIFI-12813 Correct Username handling in HTTP Request Log #8423

Closed
wants to merge 1 commit into from

Conversation

exceptionfactory
Copy link
Contributor

Summary

NIFI-12813 Corrects username handling in the application HTTP request log written to nifi-request.log in the default Logback configuration.

Upgrading to Jetty 12 in NiFi 2.0.0-M2 required changing the filter responsible for setting the authenticated user required for the Jetty CustomRequestLog. The initial change referenced the wrong AuthenticationState interface, resulting in a failure to retrieve the authenticated user attribute during the logging. This issue does not impact any authentication or authorization behavior and is limited to username logging, which can also be tracked using other loggers in nifi-user.log.

Correcting the AuthenticationState interface reference resolves the problem, and can be validated by authenticating to NiFi and confirming the presence of the username in the nifi-request.log. Additional changes include a new unit test to verify the presence of the expected request attribute name and value.

Tracking

Please complete the following tracking steps prior to pull request creation.

Issue Tracking

Pull Request Tracking

  • Pull Request title starts with Apache NiFi Jira issue number, such as NIFI-00000
  • Pull Request commit message starts with Apache NiFi Jira issue number, as such NIFI-00000

Pull Request Formatting

  • Pull Request based on current revision of the main branch
  • Pull Request refers to a feature branch with one commit containing changes

Verification

Please indicate the verification steps performed prior to pull request creation.

Build

  • Build completed using mvn clean install -P contrib-check
    • JDK 21

Licensing

  • New dependencies are compatible with the Apache License 2.0 according to the License Policy
  • New dependencies are documented in applicable LICENSE and NOTICE files

Documentation

  • Documentation formatting appears as expected in rendered files

- Corrected Jetty AuthenticationState interface reference for authenticated user attribute mapping
- Added unit test verifying expected attribute values
@asfgit asfgit closed this in 9a81f66 Feb 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants