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

YARN-11738 Modernize SecretManager config #7144

Open
wants to merge 1 commit into
base: trunk
Choose a base branch
from

Conversation

K0K0V0K
Copy link
Contributor

@K0K0V0K K0K0V0K commented Nov 4, 2024

Description of PR

Make hash algorithm at SecretManager configurable.

  • hadoop.security.hmac-algorithm: The name of the hashing algorithm. Default: HmacSHA1
  • hadoop.security.hmac-length: The length of the random keys to use. Default: 64

How was this patch tested?

  • unit test modified
  • deployed and run mapred PI example, while i modified the yarn-site.xml and mapred-site.xml with HmacSHA256 and 1024 key length

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 20m 44s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 0s codespell was not available.
+0 🆗 detsecrets 0m 0s detect-secrets was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
-1 ❌ test4tests 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
_ trunk Compile Tests _
+1 💚 mvninstall 44m 53s trunk passed
+1 💚 compile 20m 4s trunk passed with JDK Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04
+1 💚 compile 18m 46s trunk passed with JDK Private Build-1.8.0_422-8u422-b05-1~20.04-b05
+1 💚 checkstyle 1m 18s trunk passed
+1 💚 mvnsite 1m 50s trunk passed
+1 💚 javadoc 1m 23s trunk passed with JDK Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04
+1 💚 javadoc 0m 56s trunk passed with JDK Private Build-1.8.0_422-8u422-b05-1~20.04-b05
+1 💚 spotbugs 2m 43s trunk passed
+1 💚 shadedclient 38m 23s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+1 💚 mvninstall 1m 3s the patch passed
+1 💚 compile 19m 16s the patch passed with JDK Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04
+1 💚 javac 19m 16s the patch passed
+1 💚 compile 19m 10s the patch passed with JDK Private Build-1.8.0_422-8u422-b05-1~20.04-b05
+1 💚 javac 19m 10s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 1m 13s the patch passed
+1 💚 mvnsite 1m 46s the patch passed
+1 💚 javadoc 1m 16s the patch passed with JDK Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04
+1 💚 javadoc 0m 58s the patch passed with JDK Private Build-1.8.0_422-8u422-b05-1~20.04-b05
+1 💚 spotbugs 2m 47s the patch passed
+1 💚 shadedclient 38m 17s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 19m 57s hadoop-common in the patch passed.
+1 💚 asflicense 1m 5s The patch does not generate ASF License warnings.
258m 35s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/1/artifact/out/Dockerfile
GITHUB PR #7144
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets
uname Linux 627da8f5e004 5.15.0-124-generic #134-Ubuntu SMP Fri Sep 27 20:20:17 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / dfef74c
Default Java Private Build-1.8.0_422-8u422-b05-1~20.04-b05
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_422-8u422-b05-1~20.04-b05
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/1/testReport/
Max. process+thread count 3148 (vs. ulimit of 5500)
modules C: hadoop-common-project/hadoop-common U: hadoop-common-project/hadoop-common
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/1/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

@hadoop-yetus
Copy link

🎊 +1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 1m 1s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 1s codespell was not available.
+0 🆗 detsecrets 0m 1s detect-secrets was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+0 🆗 mvndep 16m 39s Maven dependency ordering for branch
+1 💚 mvninstall 33m 4s trunk passed
+1 💚 compile 20m 15s trunk passed with JDK Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04
+1 💚 compile 19m 3s trunk passed with JDK Private Build-1.8.0_422-8u422-b05-1~20.04-b05
+1 💚 checkstyle 4m 24s trunk passed
+1 💚 mvnsite 2m 52s trunk passed
+1 💚 javadoc 2m 20s trunk passed with JDK Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04
+1 💚 javadoc 1m 53s trunk passed with JDK Private Build-1.8.0_422-8u422-b05-1~20.04-b05
+1 💚 spotbugs 4m 16s trunk passed
+1 💚 shadedclient 36m 50s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+0 🆗 mvndep 0m 32s Maven dependency ordering for patch
+1 💚 mvninstall 1m 39s the patch passed
+1 💚 compile 19m 20s the patch passed with JDK Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04
+1 💚 javac 19m 20s the patch passed
+1 💚 compile 18m 47s the patch passed with JDK Private Build-1.8.0_422-8u422-b05-1~20.04-b05
+1 💚 javac 18m 47s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 4m 17s the patch passed
+1 💚 mvnsite 2m 48s the patch passed
+1 💚 javadoc 2m 14s the patch passed with JDK Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04
+1 💚 javadoc 1m 49s the patch passed with JDK Private Build-1.8.0_422-8u422-b05-1~20.04-b05
+1 💚 spotbugs 4m 42s the patch passed
+1 💚 shadedclient 37m 42s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 20m 54s hadoop-common in the patch passed.
+1 💚 unit 27m 19s hadoop-yarn-server-nodemanager in the patch passed.
+1 💚 asflicense 1m 2s The patch does not generate ASF License warnings.
289m 33s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/2/artifact/out/Dockerfile
GITHUB PR #7144
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets
uname Linux e87184f7ce14 5.15.0-124-generic #134-Ubuntu SMP Fri Sep 27 20:20:17 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / 79738f8
Default Java Private Build-1.8.0_422-8u422-b05-1~20.04-b05
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.24+8-post-Ubuntu-1ubuntu320.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_422-8u422-b05-1~20.04-b05
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/2/testReport/
Max. process+thread count 3151 (vs. ulimit of 5500)
modules C: hadoop-common-project/hadoop-common hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager U: .
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/2/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

@szetszwo
Copy link
Contributor

szetszwo commented Nov 6, 2024

@K0K0V0K , thanks for working on this!

If we change the HMAC and key length, then the keys generated before this change and after this change won't be the same. Then, this become an incompatible change.

We probably need to add confs to set the algorithm and key length for backward compatibility.

@K0K0V0K K0K0V0K marked this pull request as ready for review November 6, 2024 01:15
@brumi1024
Copy link
Member

Thanks @K0K0V0K for working on this. I agree with @szetszwo that this probably should be configurable.

@brumi1024 brumi1024 self-requested a review November 6, 2024 13:23
@K0K0V0K K0K0V0K force-pushed the YARN-11738 branch 2 times, most recently from 1352cfd to 9854cee Compare November 20, 2024 09:38
@K0K0V0K
Copy link
Contributor Author

K0K0V0K commented Nov 20, 2024

Hi @szetszwo and @brumi1024 !

First of all thanks for the review. I modified the PR, now it is configurable. I know to create a configuration object at class static method is a bit risky, but that was the quick win what i found.
May i ask a review again? Thanks!

@K0K0V0K K0K0V0K changed the title YARN-11738 Increase SecretManager#KEY_LENGTH to 128 YARN-11738 Modernize SecretManager config Nov 20, 2024
@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 0m 19s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 0s codespell was not available.
+0 🆗 detsecrets 0m 0s detect-secrets was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+0 🆗 mvndep 14m 13s Maven dependency ordering for branch
-1 ❌ mvninstall 19m 18s /branch-mvninstall-root.txt root in trunk failed.
+1 💚 compile 8m 48s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 compile 8m 21s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 checkstyle 2m 5s trunk passed
+1 💚 mvnsite 1m 31s trunk passed
+1 💚 javadoc 1m 24s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 10s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 2m 23s trunk passed
+1 💚 shadedclient 21m 12s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+0 🆗 mvndep 0m 23s Maven dependency ordering for patch
+1 💚 mvninstall 0m 53s the patch passed
+1 💚 compile 8m 37s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javac 8m 37s the patch passed
+1 💚 compile 8m 17s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 javac 8m 17s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 2m 2s the patch passed
+1 💚 mvnsite 1m 37s the patch passed
+1 💚 javadoc 1m 16s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 9s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 2m 41s the patch passed
+1 💚 shadedclient 21m 14s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 16m 50s hadoop-common in the patch passed.
+1 💚 unit 23m 25s hadoop-yarn-server-nodemanager in the patch passed.
+1 💚 asflicense 0m 43s The patch does not generate ASF License warnings.
172m 2s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/4/artifact/out/Dockerfile
GITHUB PR #7144
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets
uname Linux 127b373aca57 5.15.0-124-generic #134-Ubuntu SMP Fri Sep 27 20:20:17 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / 9854cee
Default Java Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/4/testReport/
Max. process+thread count 3154 (vs. ulimit of 5500)
modules C: hadoop-common-project/hadoop-common hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager U: .
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/4/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

@hadoop-yetus
Copy link

🎊 +1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 20m 59s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 0s codespell was not available.
+0 🆗 detsecrets 0m 0s detect-secrets was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+0 🆗 mvndep 15m 2s Maven dependency ordering for branch
+1 💚 mvninstall 33m 12s trunk passed
+1 💚 compile 20m 29s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 compile 19m 4s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 checkstyle 4m 20s trunk passed
+1 💚 mvnsite 2m 48s trunk passed
+1 💚 javadoc 2m 19s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 51s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 4m 18s trunk passed
+1 💚 shadedclient 37m 26s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+0 🆗 mvndep 0m 32s Maven dependency ordering for patch
+1 💚 mvninstall 1m 34s the patch passed
+1 💚 compile 19m 16s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javac 19m 16s the patch passed
+1 💚 compile 18m 44s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 javac 18m 44s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 4m 24s the patch passed
+1 💚 mvnsite 2m 49s the patch passed
+1 💚 javadoc 2m 13s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 48s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 4m 42s the patch passed
+1 💚 shadedclient 37m 29s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 20m 49s hadoop-common in the patch passed.
+1 💚 unit 27m 19s hadoop-yarn-server-nodemanager in the patch passed.
+1 💚 asflicense 1m 2s The patch does not generate ASF License warnings.
308m 2s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/3/artifact/out/Dockerfile
GITHUB PR #7144
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets
uname Linux 2bb1aac2b091 5.15.0-124-generic #134-Ubuntu SMP Fri Sep 27 20:20:17 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / 9854cee
Default Java Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/3/testReport/
Max. process+thread count 3151 (vs. ulimit of 5500)
modules C: hadoop-common-project/hadoop-common hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager U: .
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/3/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

@hadoop-yetus
Copy link

🎊 +1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 0m 20s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 1s codespell was not available.
+0 🆗 detsecrets 0m 1s detect-secrets was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+0 🆗 mvndep 14m 33s Maven dependency ordering for branch
+1 💚 mvninstall 19m 21s trunk passed
+1 💚 compile 9m 0s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 compile 8m 15s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 checkstyle 2m 9s trunk passed
+1 💚 mvnsite 1m 34s trunk passed
+1 💚 javadoc 1m 27s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 13s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 2m 26s trunk passed
+1 💚 shadedclient 21m 23s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+0 🆗 mvndep 0m 21s Maven dependency ordering for patch
+1 💚 mvninstall 0m 52s the patch passed
+1 💚 compile 8m 31s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javac 8m 31s the patch passed
+1 💚 compile 9m 8s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 javac 9m 8s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 2m 37s the patch passed
+1 💚 mvnsite 1m 27s the patch passed
+1 💚 javadoc 1m 7s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 1s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 2m 38s the patch passed
+1 💚 shadedclient 22m 36s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 16m 43s hadoop-common in the patch passed.
+1 💚 unit 23m 5s hadoop-yarn-server-nodemanager in the patch passed.
+1 💚 asflicense 0m 35s The patch does not generate ASF License warnings.
174m 21s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/5/artifact/out/Dockerfile
GITHUB PR #7144
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets
uname Linux 6a2100d6fd97 5.15.0-124-generic #134-Ubuntu SMP Fri Sep 27 20:20:17 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / 3495662
Default Java Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/5/testReport/
Max. process+thread count 3155 (vs. ulimit of 5500)
modules C: hadoop-common-project/hadoop-common hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager U: .
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/5/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

@hadoop-yetus
Copy link

💔 -1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 1m 0s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 0s codespell was not available.
+0 🆗 detsecrets 0m 0s detect-secrets was not available.
+0 🆗 xmllint 0m 0s xmllint was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+0 🆗 mvndep 14m 52s Maven dependency ordering for branch
+1 💚 mvninstall 33m 5s trunk passed
+1 💚 compile 20m 2s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 compile 19m 18s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 checkstyle 4m 33s trunk passed
+1 💚 mvnsite 2m 48s trunk passed
+1 💚 javadoc 2m 20s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 54s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 4m 24s trunk passed
+1 💚 shadedclient 37m 15s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+0 🆗 mvndep 0m 33s Maven dependency ordering for patch
+1 💚 mvninstall 1m 37s the patch passed
+1 💚 compile 19m 23s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javac 19m 23s the patch passed
+1 💚 compile 18m 47s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 javac 18m 47s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
+1 💚 checkstyle 4m 15s the patch passed
+1 💚 mvnsite 2m 47s the patch passed
+1 💚 javadoc 2m 15s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 48s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 4m 41s the patch passed
+1 💚 shadedclient 37m 51s patch has no errors when building and testing our client artifacts.
_ Other Tests _
-1 ❌ unit 20m 49s /patch-unit-hadoop-common-project_hadoop-common.txt hadoop-common in the patch passed.
+1 💚 unit 27m 22s hadoop-yarn-server-nodemanager in the patch passed.
+1 💚 asflicense 1m 1s The patch does not generate ASF License warnings.
288m 13s
Reason Tests
Failed junit tests hadoop.conf.TestCommonConfigurationFields
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/6/artifact/out/Dockerfile
GITHUB PR #7144
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets xmllint
uname Linux f3ffc5c5b384 5.15.0-124-generic #134-Ubuntu SMP Fri Sep 27 20:20:17 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / d23e2e9
Default Java Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/6/testReport/
Max. process+thread count 1255 (vs. ulimit of 5500)
modules C: hadoop-common-project/hadoop-common hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager U: .
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/6/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

Make hash algorithm at SecretManager configurable.
- hadoop.security.hmac-algorithm: The name of the hashing algorithm. Default: HmacSHA1
- hadoop.security.hmac-length: The length of the random keys to use. Default: 64

Change-Id: I735573c1d7b9f256e05722c98cd550cd8dd4acf0
@hadoop-yetus
Copy link

🎊 +1 overall

Vote Subsystem Runtime Logfile Comment
+0 🆗 reexec 1m 0s Docker mode activated.
_ Prechecks _
+1 💚 dupname 0m 0s No case conflicting files found.
+0 🆗 codespell 0m 1s codespell was not available.
+0 🆗 detsecrets 0m 1s detect-secrets was not available.
+0 🆗 xmllint 0m 1s xmllint was not available.
+1 💚 @author 0m 0s The patch does not contain any @author tags.
+1 💚 test4tests 0m 0s The patch appears to include 1 new or modified test files.
_ trunk Compile Tests _
+0 🆗 mvndep 15m 9s Maven dependency ordering for branch
+1 💚 mvninstall 33m 2s trunk passed
+1 💚 compile 20m 9s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 compile 19m 7s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 checkstyle 4m 25s trunk passed
+1 💚 mvnsite 2m 47s trunk passed
+1 💚 javadoc 2m 18s trunk passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 52s trunk passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 4m 20s trunk passed
+1 💚 shadedclient 37m 27s branch has no errors when building and testing our client artifacts.
_ Patch Compile Tests _
+0 🆗 mvndep 0m 33s Maven dependency ordering for patch
+1 💚 mvninstall 1m 35s the patch passed
+1 💚 compile 19m 44s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javac 19m 44s the patch passed
+1 💚 compile 19m 17s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 javac 19m 17s the patch passed
+1 💚 blanks 0m 0s The patch has no blanks issues.
-0 ⚠️ checkstyle 4m 22s /results-checkstyle-root.txt root: The patch generated 4 new + 110 unchanged - 0 fixed = 114 total (was 110)
+1 💚 mvnsite 2m 50s the patch passed
+1 💚 javadoc 2m 15s the patch passed with JDK Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04
+1 💚 javadoc 1m 53s the patch passed with JDK Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
+1 💚 spotbugs 4m 39s the patch passed
+1 💚 shadedclient 38m 34s patch has no errors when building and testing our client artifacts.
_ Other Tests _
+1 💚 unit 20m 59s hadoop-common in the patch passed.
+1 💚 unit 27m 23s hadoop-yarn-server-nodemanager in the patch passed.
+1 💚 asflicense 1m 4s The patch does not generate ASF License warnings.
290m 22s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/7/artifact/out/Dockerfile
GITHUB PR #7144
Optional Tests dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets xmllint
uname Linux c8167cf2c945 5.15.0-124-generic #134-Ubuntu SMP Fri Sep 27 20:20:17 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/bin/hadoop.sh
git revision trunk / ea7f701
Default Java Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Multi-JDK versions /usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.25+9-post-Ubuntu-1ubuntu120.04 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_432-8u432-gaus1-0ubuntu220.04-ga
Test Results https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/7/testReport/
Max. process+thread count 1348 (vs. ulimit of 5500)
modules C: hadoop-common-project/hadoop-common hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager U: .
Console output https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-7144/7/console
versions git=2.25.1 maven=3.6.3 spotbugs=4.2.2
Powered by Apache Yetus 0.14.0 https://yetus.apache.org

This message was automatically generated.

@K0K0V0K
Copy link
Contributor Author

K0K0V0K commented Nov 21, 2024

Hi @brumi1024 @szetszwo!

May i ask a review again? Thanks!

Copy link
Contributor

@szetszwo szetszwo left a comment

Choose a reason for hiding this comment

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

@K0K0V0K , thanks for the update! Please see the comments inlined.

Comment on lines +1013 to +1014
public static final String HMAC_ALGORITHM = "hadoop.security.hmac-algorithm";
public static final String DEFAULT_HMAC_ALGORITHM = "HmacSHA1";
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's add "secret-manager.key-generator.algorithm" (we may use a non-hmac algorithm).

  • Also, we should use the existing naming convention.
  • The javadoc is not useful. Let's skip it.
  public static final String HADOOP_SECURITY_SECRET_MANAGER_KEY_GENERATOR_ALGORITHM_KEY
      = "hadoop.security.secret-manager.key-generator.algorithm";
  public static final String HADOOP_SECURITY_SECRET_MANAGER_KEY_GENERATOR_ALGORITHM_DEFAULT
      = "HmacSHA1";

Comment on lines +1021 to +1022
public static final String HMAC_LENGTH = "hadoop.security.hmac-length";
public static final int DEFAULT_HMAC_LENGTH = 64;
Copy link
Contributor

Choose a reason for hiding this comment

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

This should be "key-length". It has nothing to do with hmac.

  public static final String HADOOP_SECURITY_SECRET_MANAGER_KEY_LENGTH_KEY
      = "hadoop.security.secret-manager.key-length";
  public static final int HADOOP_SECURITY_SECRET_MANAGER_KEY_LENGTH_DEFAULT
      = 64;

} catch (NoSuchAlgorithmException nsa) {
throw new IllegalArgumentException("Can't find " + DEFAULT_HMAC_ALGORITHM +
" algorithm.");
throw new IllegalArgumentException("Can't find " + SELECTED_ALGORITHM + " algorithm.");
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's include the cause:

      throw new IllegalArgumentException("Failed to get " + HMAC_ALGORITHM, nsa);

} catch (NoSuchAlgorithmException nsa) {
throw new IllegalArgumentException("Can't find " + DEFAULT_HMAC_ALGORITHM +
" algorithm.");
throw new IllegalArgumentException("Can't find " + SELECTED_ALGORITHM + " algorithm.");
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's include the cause:

      throw new IllegalArgumentException("Failed to get " + HMAC_ALGORITHM, nsa);

Comment on lines +1052 to +1060
<description>The configuration key specifying the hashing algorithm used for
HMAC (Hash-based Message Authentication Code) operations.

The HMAC algorithm is used in token management to compute secure
message digests. This configuration allows users to specify the
algorithm to be used for HMAC operations. The algorithm must be a
valid cryptographic hash algorithm supported by the Java Cryptography
Architecture (JCA). Common examples include "HmacSHA1", "HmacSHA256",
and "HmacSHA512".</description>
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's update the description as below:

The configuration key specifying the KeyGenerator algorithm used in SecretManager
for generating secret keys. The algorithm must be a KeyGenerator algorithm supported by
the Java Cryptography Architecture (JCA). Common examples include "HmacSHA1",
"HmacSHA256", and "HmacSHA512".

Comment on lines +1066 to +1072
<description>The configuration key specifying the key length for HMAC (Hash-based
Message Authentication Code) operations.

This property determines the size of the secret keys generated
for HMAC computations. The key length must be appropriate for the
selected HMAC algorithm. For example, longer keys are generally
more secure but may not be supported by all algorithms.</description>
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's change this to:

The configuration key specifying the key length of the generated secret keys
in SecretManager. The key length must be appropriate for the algorithm.
For example, longer keys are generally more secure but may not be supported
by all algorithms.

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.

4 participants