Repository navigation
[urgent]: fix v1beta authz bypass - #5274
Merged
diegosouzapw merged 1 commit intoJun 29, 2026
Merged
diegosouzapw merged 1 commit into
diegosouzapw merged 1 commit into
Conversation
Contributor
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
diegosouzapw
merged commit Jun 29, 2026
1fd19c4
into
cheaper-inference:release/v3.8.40
7 checks passed
Merged
tkgo11
pushed a commit
to tkgo11/OmniRoute
that referenced
this pull request
Sep 23, 2026
Security: close /v1beta authz bypass — classify /v1beta + /api/v1beta aliases as CLIENT_API so Bearer auth is enforced. Validated authz TDD suite (classify/proxy-contract/pipeline/inventory). Integrated into release/v3.8.40.
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.
Summary
/v1beta/*Gemini-compatible aliases were rewritten to/api/v1beta/*without first entering the central proxy/authz pipeline./v1beta/*aliases and/api/v1beta/*routes asCLIENT_API, so the existingclientApiPolicyenforces Bearer auth whenREQUIRE_API_KEYis enabled.Root Cause
next.config.mjsalready rewrote/v1beta/:path*to/api/v1beta/:path*, butsrc/proxy.tsdid not match/v1betabefore rewrite andclassifyRoute()did not classify/api/v1beta/*as client API. As a result, unauthenticated/v1beta/models/...:generateContenttraffic could reach the model-serving route without the central client API auth policy.Validation
node --import tsx/esm --test tests/unit/authz/classify.test.tsnode --import tsx/esm --test tests/unit/authz/proxy-contract.test.tsnode --import tsx/esm --test tests/unit/authz/pipeline.test.tsnode --import tsx/esm --test tests/unit/api/authz-inventory.test.tsnpm run check:fabricated-docsgit diff --checknpm run check:any-budget:t11,npm run check:tracked-artifacts