Repository navigation
feat!: add authorization for the signaling API - #25
Merged
Merged
Conversation
Authorization is mandatory; WithAuthorizationDisabled turns it off. - Authorization extension point (WithAuthorization): outbound Authorization headers from the target control plane's entry, inbound caller identification via ExtractControlPlaneID - oauth2_client_credentials profile in pkg/authorization/oauth2 (client credentials grant with token caching, JWT verification against a JWKS endpoint) - NewHandler authenticates every route (401) before reading the body; WithAuthenticator replaces the scheme - 403, with a logged warning, when a control plane accesses another control plane's data flow or registration - registrations reject authorization types without a registered Authorization; control plane endpoints require https except loopback (WithInsecureEndpoints) BREAKING CHANGE: ControlPlaneClient, ControlPlaneResolver, WithControlPlane, RegisterDataPlane and DeregisterDataPlane take a ControlPlane instead of a URL; WithControlPlaneIdentifier is replaced by WithAuthenticator; NewHandler answers 401 unless an Authorization is registered or authorization is disabled. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
wolf4ood
approved these changes
Nov 10, 2026
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.
Phase 7 of the signaling v1.0 migration: authorization in both directions. Authorization is mandatory;
WithAuthorizationDisabled()is the explicit opt-out.Authorizationextension point (Type,AuthorizationHeader,ExtractCallerID), registered withWithAuthorization; mirrors the Java SDK.Authorizationheader (401), the caller id is recorded on new flows, and a caller acting on another control plane's flow or registration gets 403 with a logged warning.pkg/authorization/oauth2:oauth2_client_credentialsviagolang.org/x/oauth2(cached tokens) and JWT/JWKS verification viagolang-jwt/jwt/v5andMicahParks/keyfunc/v3, pinned to versions that keepgo 1.24.WithInsecureEndpoints().Breaking:
ControlPlaneClient,ControlPlaneResolverandWithControlPlanenow take aControlPlane;WithControlPlaneIdentifieris replaced byWithAuthenticator.🤖 Generated with Claude Code