Skip to content

Commit

Permalink
Use integrity for scripts hosted on the CDN
Browse files Browse the repository at this point in the history
  • Loading branch information
mei23 committed Mar 13, 2021
1 parent bf4cd9b commit 224138a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/client/assets/redoc.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@
</head>
<body>
<redoc spec-url='/api.json'></redoc>
<script src="https://cdn.jsdelivr.net/npm/redoc@next/bundles/redoc.standalone.js"> </script>
<script src="https://cdn.jsdelivr.net/npm/redoc@2.0.0-rc.48/bundles/redoc.standalone.js" integrity="sha256-FI07Zo3zrSdvkLx95toZ5sXGQKn9BsM2MulFYpo+Pno=" crossorigin="anonymous"></script>
</body>
</html>
4 changes: 2 additions & 2 deletions src/server/web/views/docs-base.pug
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ html(lang= lang)
title
| #{title} | Misskey Docs
link(rel="stylesheet" href="/docs/assets/style.css")
link(rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.1.2/styles/github.min.css")
script(src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.1.2/highlight.min.js")
link(rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.6.0/styles/github.min.css" integrity="sha512-7QTQ5Qsc/IL1k8UU2bkNFjpKTfwnvGuPYE6fzm6yeneWTEGiA3zspgjcTsSgln9m0cn3MgyE7EnDNkF1bB/uCw==" crossorigin="anonymous")
script(src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.6.0/highlight.min.js" integrity="sha512-zol3kFQ5tnYhL7PzGt0LnllHHVWRGt2bTCIywDiScVvLIlaDOVJ6sPdJTVi0m3rA660RT+yZxkkRzMbb1L8Zkw==" crossorigin="anonymous")
block meta

body
Expand Down

0 comments on commit 224138a

Please sign in to comment.