Skip to content

Commit

Permalink
Fix Content Security Policy for Outlook (#60)
Browse files Browse the repository at this point in the history
  • Loading branch information
wandyezj authored Jun 22, 2024
1 parent 409db83 commit 29ef6bd
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions .vscode/cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"words": [
"Addin",
"appsforoffice",
"aspnetcdn",
"CODEOWNERS",
"endregion",
"eqeqeq",
Expand Down
6 changes: 6 additions & 0 deletions docs/features/content-security-policy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Content Security Policy

The policy applied

- script-src `ajax.aspnetcdn.com`
- required for outlook, loaded by office.js
2 changes: 1 addition & 1 deletion src/edit.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="UTF-8" />
<meta
http-equiv="Content-Security-Policy"
content="default-src 'self'; script-src 'self' appsforoffice.microsoft.com; style-src 'self' 'unsafe-inline'; connect-src *; frame-src telemetryservice.firstpartyapps.oaspapps.com;"
content="default-src 'self'; script-src 'self' appsforoffice.microsoft.com ajax.aspnetcdn.com; style-src 'self' 'unsafe-inline'; connect-src *; frame-src telemetryservice.firstpartyapps.oaspapps.com;"
/>
<script src="https://appsforoffice.microsoft.com/lib/1/hosted/office.js" type="text/javascript"></script>
<link rel="stylesheet" type="text/css" href="./edit.css" />
Expand Down

0 comments on commit 29ef6bd

Please sign in to comment.