-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(admin) disable retrieval of plugins by name (#2726)
In the `/apis/:api/plugins/:plugin` endpoint, #2252 recently introduced the possibility to pass a plugin name as `:plugin`, instead of an id only. Like: `/apis/:api/plugins/basic-auth`. However, the following minimally reproducible example exposes the flaw with such an endpoint given the current model: ``` $ http POST :8001/apis/ name=api1 hosts=example.com upstream_url=http://httpbin.org $ http POST :8001/consumers name=peter $ http POST :8001/consumers name=mary $ http POST :8001/plugins name=request-size-limiting api_id=$API1_UUID consumer_id=$PETER_UUID $ http POST :8001/plugins name=request-size-limiting api_id=$API1_UUID consumer_id=$MARY_UUID $ http :8001/apis/$API1_UUID/plugins $ http :8001/apis/$API1_UUID/plugins/request-size-limiting ``` Reverts the main part of #2252 Signed-off-by: Thibault Charbonnier <[email protected]>
- Loading branch information
Showing
6 changed files
with
21 additions
and
38 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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