Repository navigation
[ISSUE #14036] Support TLS prefix for HTTP login - #15405
KomachiSion merged 2 commits into
Conversation
|
Thanks for your this PR. 🙏 感谢您提交的PR。 🙏 |
|
I re-checked the linked issue and the patch. The problem is valid and the fix direction looks correct to me. The current blocker is CI formatting only: |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
What is the purpose of the change
Fixes #14036.
When
HttpLoginProcessorreceives a server address without an explicithttp://orhttps://prefix, it currently always prependshttp://. That makes the login request ignore the Nacos client TLS switch and prevents HTTPS login for callers that pass plain addresses.This change keeps explicitly prefixed addresses unchanged, and only uses the Nacos client TLS property when the prefix is missing. If
tls.enable=true, the login URL is built withhttps://; otherwise it keeps the existing defaulthttp://behavior.Brief changelog
TlsSystemConfig.TLS_ENABLEwhenHttpLoginProcessorneeds to infer a missing protocol prefix.tls.enable=truewith a plain server address.Verifying this change
JAVA_HOME=$(/usr/libexec/java_home -v 17) ./mvnw -s .codex-empty-settings.xml -pl client-basic -am -Dtest=HttpLoginProcessorTest -Dsurefire.failIfNoSpecifiedTests=false testTests run: 5, Failures: 0, Errors: 0, Skipped: 0JAVA_HOME=$(/usr/libexec/java_home -v 17) ./mvnw -s .codex-empty-settings.xml -pl client-basic -am -DskipITs -DskipRat testSUCCESS;nacos-client-basicreportedTests run: 281, Failures: 0, Errors: 0, Skipped: 0.git diff --checkChecklist:
[ISSUE #123] ....mvn -B clean package apache-rat:check spotbugs:check -DskipTests/ full integration-test suite.