feat(core): enable zero-config Bedrock identity defaults - #90
Merged
robinbraemer merged 4 commits intoJul 30, 2026
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Intent
Ship Connect Java's Bedrock identity defaults so a newly installed plugin with an untouched server or proxy config works for Connect-managed Bedrock without any operator config paste. The packaged config.yml and proxy-config.yml must default metadata-url to https://watch-connect.minekube.net/.well-known/minekube-connect/bedrock-identity-keys.json, enforcement to the non-rejecting safe starting value warn, expected-issuer to minekube-connect, and expected-policy to trusted_bedrock_xuid. Document why trusting Minekube's HTTPS metadata is coherent and safe, the verifier's userinfo/fragment/redirect rejection, and how operators clear metadata-url to pin public-key/public-keys. Prove an untouched default config advertises trusted bedrock-identity and admits a valid unlinked Bedrock session, while Java-only sessions remain allowed without key fetches, warnings, or behavioral weakening. Preserve legacy Java object fallback and static-key configuration semantics by limiting the new trust values to generated install templates. Do not touch Gate or Moxy consumption, release, deploy, merge, production, or public support threads; deliver a green PR for human review.
What Changed
warnmode with the expected issuer and policy defaults.Risk Assessment
✅ Low: The session-lazy metadata change and documentation now align with the stated Java-only and zero-config Bedrock requirements; no additional material source risks were found.
Testing
Fresh targeted tests passed. Packaged config defaults, capability advertisement, valid unlinked Bedrock admission, Java-only no-fetch/no-warning behavior, metadata rejection, static-key semantics, and legacy defaults were directly verified. No UI surface applies.
Evidence: Bedrock identity validation evidence
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
🔧 **Review** - 1 issue found → auto-fixed (2) ✅
core/src/main/resources/config.yml:37- The changed template enablesenforcement: warnand setsmetadata-urlto the Minekube endpoint (line 37), so everyWatchClient.watch()/libp2p registration checks readiness and synchronously fetches keys before any player is known. This conflicts with the required criterion “Java-only sessions remain allowed without key fetches.” The new test only calls the enforcer directly and misses this registration path. Please clarify whether startup capability discovery fetches are exempt; otherwise move key acquisition out of readiness negotiation.🔧 Fix: Made Bedrock metadata fetch session-lazy; focused tests pass
1 warning still open:
docs/bedrock-identity.md:7- The documentation says the capability is advertised “after validating the metadata,” buthasConfiguredKeySource()now only validates the URL syntax; metadata is fetched and validated later during session verification. Update the wording to describe this session-lazy flow.🔧 Fix: Aligned Bedrock identity docs with lazy metadata validation
✅ Re-checked - no issues remain.
✅ **Test** - passed
✅ No issues found.
./gradlew :core:test --rerun-tasks --tests com.minekube.connect.bedrock.BedrockIdentityDefaultConfigTest --tests com.minekube.connect.bedrock.BedrockIdentityKeyProviderTest --tests com.minekube.connect.bedrock.BedrockIdentityReadinessTest --tests com.minekube.connect.bedrock.BedrockIdentityConfigurationTest --tests com.minekube.connect.bedrock.BedrockIdentityEnforcerTest --tests com.minekube.connect.config.ConfigLoaderTestInspected packaged JAR templates, documentation, and legacy object defaults../gradlew cleanand generated-output cleanup✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.