Skip to content

Commit 68e3316

Browse files
committed
AC-1450: Disable Swagger in production mode
1 parent 9bea6d2 commit 68e3316

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
<csp_whitelist xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Csp:etc/csp_whitelist.xsd">
10+
<policies>
11+
<policy id="img-src">
12+
<values>
13+
<value id="swagger" type="host">validator.swagger.io</value>
14+
</values>
15+
</policy>
16+
</policies>
17+
</csp_whitelist>

lib/internal/Magento/Framework/Filesystem/Driver/File/Mime.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ class Mime
9191
private $genericMimeTypes = [
9292
'application/x-empty',
9393
'inode/x-empty',
94+
'application/octet-stream'
9495
];
9596

9697
/**

0 commit comments

Comments
 (0)