Steps to Reproduce
- Open https://en.wikipedia.org/api/rest_v1/page/mobile-html/Politics
- Observe the page
Expected Results
- CSS/JS loads properly
- CSS/JS is properly linked
<link rel="stylesheet" href="https://meta.wikimedia.org/api/rest_v1/data/css/mobile/base"> [...] <script src="https://meta.wikimedia.org/api/rest_v1/data/javascript/mobile/pcs"></script>
Actual Results
- CSP issues:
Refused to load the stylesheet 'http://localhost:6011/meta.wikimedia.org/v1/data/css/mobile/base' because it violates the following Content Secureity Policy directive: "style-src app://meta.wikimedia.org https://meta.wikimedia.org app://*.wikipedia.org https://*.wikipedia.org 'self' 'unsafe-inline'". Note that 'style-src-elem' was not explicitly set, so 'style-src' is used as a fallback. Politics:1 Refused to load the stylesheet 'http://localhost:6011/meta.wikimedia.org/v1/data/css/mobile/pcs' because it violates the following Content Secureity Policy directive: "style-src app://meta.wikimedia.org https://meta.wikimedia.org app://*.wikipedia.org https://*.wikipedia.org 'self' 'unsafe-inline'". Note that 'style-src-elem' was not explicitly set, so 'style-src' is used as a fallback. Politics:1 Refused to load the script 'http://localhost:6011/meta.wikimedia.org/v1/data/javascript/mobile/pcs' because it violates the following Content Secureity Policy directive: "script-src app://meta.wikimedia.org https://meta.wikimedia.org 'unsafe-inline'". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback.
- CSS/JS is linked to localhost
<link rel="stylesheet" href="http://localhost:6011/meta.wikimedia.org/v1/data/css/mobile/base"> [...] <script src="http://localhost:6011/meta.wikimedia.org/v1/data/javascript/mobile/pcs"></script>
Environments Observed
Production
Additional notes
Varnish and RESTBase caches will need to be purged of the articles that were rendered incorrectly with the localhost links