Skip to content

NIFI-9988 Correct Property Decryption for Authorizers and Providers#6017

Closed
exceptionfactory wants to merge 1 commit intoapache:mainfrom
exceptionfactory:NIFI-9988
Closed

NIFI-9988 Correct Property Decryption for Authorizers and Providers#6017
exceptionfactory wants to merge 1 commit intoapache:mainfrom
exceptionfactory:NIFI-9988

Conversation

@exceptionfactory
Copy link
Contributor

Summary

NIFI-9988 Corrects Sensitive Property Provider decryption for encrypted property values in authorizers.xml and login-identity-providers.xml.

Refactoring Sensitive Property Providers to use isolated class-loading for NIFI-9883 involved changes to the configuration classes for Authorizers and Login Identity Providers, leveraging the ProtectionSchemeResolver to determine the Protection Scheme based on the value of the encryption attribute, such as aes/gcm/256.

The StandardProtectionSchemeResolver worked with the encrypt-config command, which specifies the scheme using one of the known enumerated values, but did not work with the Authorizers or Login Identity Providers configurations, which used the path value. Updating the StandardProtectionSchemeResolver to support resolution based on either the Name or the Path prefix resolves the problem.

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-0000
  • Pull Request commit message starts with Apache NiFi Jira issue number, as such NIFI-0000

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 8
    • JDK 11
    • JDK 17

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

- Updated Protection Scheme Resolver to support both Name matching and Path matching
@thenatog
Copy link
Contributor

thenatog commented May 4, 2022

Reviewing

@thenatog
Copy link
Contributor

thenatog commented May 4, 2022

So with main branch I ran into:
Caused by: org.apache.nifi.properties.SensitivePropertyProtectionException: Protection Scheme [aes/gcm/256] not supported

and now with this PR it appears fixed.

+1 will merge

@thenatog thenatog closed this in 272325c May 4, 2022
asfgit pushed a commit that referenced this pull request May 9, 2022
- Updated Protection Scheme Resolver to support both Name matching and Path matching

Signed-off-by: Nathan Gough <thenatog@gmail.com>

This closes #6017.
genehynson pushed a commit to influxdata/nifi that referenced this pull request May 17, 2022
- Updated Protection Scheme Resolver to support both Name matching and Path matching

Signed-off-by: Nathan Gough <thenatog@gmail.com>

This closes apache#6017.
krisztina-zsihovszki pushed a commit to krisztina-zsihovszki/nifi that referenced this pull request Jun 28, 2022
- Updated Protection Scheme Resolver to support both Name matching and Path matching

Signed-off-by: Nathan Gough <thenatog@gmail.com>

This closes apache#6017.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants