<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: CSP Header Setting in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/csp-header-setting/m-p/1289472#M81169</link>
    <description>&lt;P&gt;Based on the error message in the screenshot, it appears that the issue is related to the Content Security Policy (CSP) settings blocking the loading of the map. To resolve this issue, you can modify your CSP settings to allow the necessary domains for the map to render properly.&lt;/P&gt;&lt;P&gt;The script-src directive should include the domains used by the map, such as js.arcgis.com. Also, the img-src directive should allow *.arcgis.com for loading map images.&lt;/P&gt;&lt;P&gt;Here's an updated version of your CSP settings:&lt;/P&gt;&lt;P&gt;plaintext&lt;BR /&gt;Copy code&lt;BR /&gt;frame-ancestors 'self';&lt;BR /&gt;block-all-mixed-content;&lt;BR /&gt;default-src 'self';&lt;BR /&gt;script-src 'self' 'report-sample' 'unsafe-inline' 'unsafe-eval' js.arcgis.com;&lt;BR /&gt;style-src 'self' 'report-sample' 'unsafe-inline' js.arcgis.com;&lt;BR /&gt;object-src 'none';&lt;BR /&gt;frame-src 'self';&lt;BR /&gt;child-src 'self';&lt;BR /&gt;img-src 'self' data: blob: *.arcgis.com;&lt;BR /&gt;font-src 'self' data: js.arcgis.com;&lt;BR /&gt;connect-src 'self' *.arcgisonline.com *.arcgis.com;&lt;BR /&gt;manifest-src 'self';&lt;BR /&gt;base-uri 'self';&lt;BR /&gt;form-action 'self';&lt;BR /&gt;media-src 'self';&lt;BR /&gt;prefetch-src 'self';&lt;BR /&gt;worker-src 'self' blob:;&lt;BR /&gt;With these updated CSP settings, you should allow the necessary domains for the map to render without being blocked by the Content Security Policy.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;Rachel Gomez&lt;/P&gt;</description>
    <pubDate>Tue, 16 May 2023 05:38:16 GMT</pubDate>
    <dc:creator>RachelGomez</dc:creator>
    <dc:date>2023-05-16T05:38:16Z</dc:date>
    <item>
      <title>CSP Header Setting</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/csp-header-setting/m-p/1288749#M81148</link>
      <description>&lt;P&gt;Good Day&lt;BR /&gt;&lt;BR /&gt;I'm trying to configure a CSP header, and every time I try to load one of the maps, it just doesn't render, this is what I get:&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-left" image-alt="Screenshot from 2023-05-12 15-39-15.png" style="width: 200px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/70553i3B7B3058A13B08E0/image-size/small?v=v2&amp;amp;px=200" role="button" title="Screenshot from 2023-05-12 15-39-15.png" alt="Screenshot from 2023-05-12 15-39-15.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is my CSP setting:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;frame-ancestors
 'self';
block-all-mixed-content;
default-src
 'self';
script-src
 'self'
 'report-sample'
 'unsafe-inline'
 'unsafe-eval'
style-src
 'self'
 'report-sample'
 'unsafe-inline'
 js.arcgis.com
object-src
 'none';
frame-src
 'self'
child-src
 'self';
img-src
 'self'
 data:
 blob:
 *.arcgis.com
font-src
 'self'
 data:
 js.arcgis.com;
connect-src
 'self'
 *.arcgisonline.com
 *.arcgis.com
manifest-src
 'self';
base-uri
 'self';
form-action
 'self';
media-src
 'self'
prefetch-src
 'self';
worker-src
 'self'
 blob:;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What do I need to add, or change?&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Fri, 12 May 2023 19:42:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/csp-header-setting/m-p/1288749#M81148</guid>
      <dc:creator>AndrewMurdoch1</dc:creator>
      <dc:date>2023-05-12T19:42:32Z</dc:date>
    </item>
    <item>
      <title>Re: CSP Header Setting</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/csp-header-setting/m-p/1289472#M81169</link>
      <description>&lt;P&gt;Based on the error message in the screenshot, it appears that the issue is related to the Content Security Policy (CSP) settings blocking the loading of the map. To resolve this issue, you can modify your CSP settings to allow the necessary domains for the map to render properly.&lt;/P&gt;&lt;P&gt;The script-src directive should include the domains used by the map, such as js.arcgis.com. Also, the img-src directive should allow *.arcgis.com for loading map images.&lt;/P&gt;&lt;P&gt;Here's an updated version of your CSP settings:&lt;/P&gt;&lt;P&gt;plaintext&lt;BR /&gt;Copy code&lt;BR /&gt;frame-ancestors 'self';&lt;BR /&gt;block-all-mixed-content;&lt;BR /&gt;default-src 'self';&lt;BR /&gt;script-src 'self' 'report-sample' 'unsafe-inline' 'unsafe-eval' js.arcgis.com;&lt;BR /&gt;style-src 'self' 'report-sample' 'unsafe-inline' js.arcgis.com;&lt;BR /&gt;object-src 'none';&lt;BR /&gt;frame-src 'self';&lt;BR /&gt;child-src 'self';&lt;BR /&gt;img-src 'self' data: blob: *.arcgis.com;&lt;BR /&gt;font-src 'self' data: js.arcgis.com;&lt;BR /&gt;connect-src 'self' *.arcgisonline.com *.arcgis.com;&lt;BR /&gt;manifest-src 'self';&lt;BR /&gt;base-uri 'self';&lt;BR /&gt;form-action 'self';&lt;BR /&gt;media-src 'self';&lt;BR /&gt;prefetch-src 'self';&lt;BR /&gt;worker-src 'self' blob:;&lt;BR /&gt;With these updated CSP settings, you should allow the necessary domains for the map to render without being blocked by the Content Security Policy.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;Rachel Gomez&lt;/P&gt;</description>
      <pubDate>Tue, 16 May 2023 05:38:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/csp-header-setting/m-p/1289472#M81169</guid>
      <dc:creator>RachelGomez</dc:creator>
      <dc:date>2023-05-16T05:38:16Z</dc:date>
    </item>
    <item>
      <title>Re: CSP Header Setting</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/csp-header-setting/m-p/1289636#M81177</link>
      <description>&lt;P&gt;Thanks for the suggestion.&lt;BR /&gt;&lt;BR /&gt;The issue, I was missing: &lt;A href="https://js.arcgis.com/4.26/@arcgis/core/assets/esri/core/workers/RemoteClient.js" target="_blank"&gt;https://js.arcgis.com/4.26/@arcgis/core/assets/esri/core/workers/RemoteClient.js&lt;/A&gt; in script-src.&amp;nbsp; Once I added that the workers were able to load and everything, so far, has been working great.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 16 May 2023 15:23:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/csp-header-setting/m-p/1289636#M81177</guid>
      <dc:creator>AndrewMurdoch1</dc:creator>
      <dc:date>2023-05-16T15:23:04Z</dc:date>
    </item>
  </channel>
</rss>

