Skip to content

Commit

Permalink
Merge pull request kubernetes#23234 from nikhiljindal/swaggerRemoveur…
Browse files Browse the repository at this point in the history
…lQuery

Auto commit by PR queue bot
(cherry picked from commit b50e89e)
  • Loading branch information
k8s-merge-robot authored and eparis committed Mar 24, 2016
1 parent a367666 commit 1b37979
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
2 changes: 2 additions & 0 deletions third_party/swagger-ui/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ https://github.com/swagger-api/swagger-ui#how-to-use-it
https://github.com/swagger-api/swagger-ui#how-to-use-it
- Modified swagger-ui.js to list resources and operations in sorted order: https://github.com/kubernetes/kubernetes/pull/3421
- Set supportedSubmitMethods: [] in index.html to remove "Try it out" buttons.
- Remove the url query param to fix XSS issue:
https://github.com/kubernetes/kubernetes/pull/23234

LICENSE file has been created for compliance purposes.
Not included in original distribution.
7 changes: 1 addition & 6 deletions third_party/swagger-ui/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,7 @@

<script type="text/javascript">
$(function () {
var url = window.location.search.match(/url=([^&]+)/);
if (url && url.length > 1) {
url = decodeURIComponent(url[1]);
} else {
url = "../../swaggerapi";
}
var url = "../../swaggerapi";
window.swaggerUi = new SwaggerUi({
url: url,
dom_id: "swagger-ui-container",
Expand Down

0 comments on commit 1b37979

Please sign in to comment.