Secure Application Content
SEI can be embedded into other websites—for example, some Sage products use SEI inside their web portal. However, this also introduces the risk of clickjacking attacks if malicious sites embed SEI without authorization.
To prevent unauthorized embedding, configure a Content Security Policy (CSP) with the frame-ancestors directive. This restricts which websites can display SEI content in an iframe.
Add a content security policy
You can enforce frame-ancestor rules using either the web.config file or IIS Manager.
Method 1: Edit web.config file
- Open File Explorer and go to:
C:\Program Files\Nectari\Nectari Server\WebServer\web.config - Locate the
<customHeaders>section. - Add or update this line with your allowed website URLs:
<add name="Content-Security-Policy" value="frame-ancestors http://website1.url.com https://website2.url.com"/> - Save the file and restart your web server if needed.
Example of URLs
http://example.nectari.comhttps://*.nectari.com- For localhost development:
http://localhost/*
Your <customHeaders> section might look like:
<httpProtocol>
<customHeaders>
<add name="X-UA-Compatible" value="IE=edge" />
<!-- Removes the header showing the technologies used by the web server -->
<remove name="X-Powered-By" />
<add name="Content-Security-Policy" value="frame-ancestors http://localhost/*" />
</customHeaders>
</httpProtocol>
Method 2: Set CSP Headers in IIS
- Open IIS Manager (
inetmgr). - Go to your SEI site and open HTTP Response Headers in the IIS section.
- In the Actions panel, click Add.
- Set Name to
Content-Security-Policy. - Set Value to your whitelist of allowed site URLs.
- Click Ok.
- Repeat steps 3–6 for each additional allowed site.
Obsolete X-Frame-Options directive
The older X-Frame-Options header (such as ALLOWFROM) is mostly unsupported in modern browsers and should not be used to secure SEI for embedded scenarios.
SAMEORIGINandDENYstill work but are not recommended for embedded integrations.- For complete browser compatibility, always prefer the CSP
frame-ancestorsdirective.
Avoid using the deprecated ALLOWFROM or ALLOWURL directives—they are no longer supported in Chrome, Firefox, and most modern browsers.