aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--all.json4
-rw-r--r--docs/backend_api.md48
-rw-r--r--recipes/msteams/index.js26
-rw-r--r--recipes/msteams/package.json2
-rw-r--r--recipes/msteams/webview.js5
-rw-r--r--recipes/office365-owa/index.js136
-rw-r--r--recipes/office365-owa/package.json2
7 files changed, 215 insertions, 8 deletions
diff --git a/all.json b/all.json
index 6f75c3e..74bf9f0 100644
--- a/all.json
+++ b/all.json
@@ -885,7 +885,7 @@
885 "featured": false, 885 "featured": false,
886 "id": "msteams", 886 "id": "msteams",
887 "name": "Microsoft Teams", 887 "name": "Microsoft Teams",
888 "version": "3.1.1", 888 "version": "3.1.2",
889 "aliases": [ 889 "aliases": [
890 "teamsChat" 890 "teamsChat"
891 ], 891 ],
@@ -1032,7 +1032,7 @@
1032 "featured": false, 1032 "featured": false,
1033 "id": "office365-owa", 1033 "id": "office365-owa",
1034 "name": "Office 365 Outlook", 1034 "name": "Office 365 Outlook",
1035 "version": "1.4.2", 1035 "version": "1.4.3",
1036 "aliases": [ 1036 "aliases": [
1037 "live.com" 1037 "live.com"
1038 ], 1038 ],
diff --git a/docs/backend_api.md b/docs/backend_api.md
index dd7d760..e4f07df 100644
--- a/docs/backend_api.md
+++ b/docs/backend_api.md
@@ -4,13 +4,14 @@ Provides a set of helper functions to integrate the recipe into [Ferdi](https://
4 4
5## Ferdi Backend Class Methods 5## Ferdi Backend Class Methods
6 6
7* [validateUrl](#user-content-validateurl) 7* [validateUrl](#validateurl)
8* [overrideUserAgent](#user-content-overrideuseragent) 8* [overrideUserAgent](#overrideuseragent)
9* [modifyRequestHeaders](#user-content-modifyrequestheaders) 9* [modifyRequestHeaders](#modifyrequestheaders)
10* [knownCertificateHosts](#knownCertificateHosts)
10 11
11## Events 12## Events
12 13
13* [webview events](#user-content-events) 14* [webview events](#events)
14 15
15### validateUrl(URL) 16### validateUrl(URL)
16 17
@@ -110,6 +111,45 @@ module.exports = Ferdi => class HangoutsChat extends Ferdi {
110}; 111};
111``` 112```
112 113
114### knownCertificateHosts()
115
116Specify an array of known hosts from where certificates can be issued for this service
117
118#### Returns
119
120`Array` containing hostnames from where certificates can be issued
121
122#### Usage
123
124```js
125// msteams Chat integration
126module.exports = Ferdi => class MicrosoftTeams extends Ferdi {
127 knownCertificateHosts() {
128 return [
129 'aka.ms',
130 'aspnetcdn.com',
131 'azure.net',
132 'azureedge.net',
133 'live.com',
134 'microsoft.com',
135 'microsoftonline.com',
136 'msecnd.net',
137 'msedge.net',
138 'mstea.ms',
139 'office.net',
140 'okta.com',
141 'sfbassets.com',
142 'skype.com',
143 'skypeassets.com',
144 'skypeforbusiness.com',
145 'tenor.com',
146 'windows.com',
147 'windows.net',
148 ];
149 };
150};
151```
152
113### Events 153### Events
114 154
115Ferdi recipes can hook into the [electron webview events](https://electron.atom.io/docs/api/webview-tag/#dom-events) to trigger custom functions. 155Ferdi recipes can hook into the [electron webview events](https://electron.atom.io/docs/api/webview-tag/#dom-events) to trigger custom functions.
diff --git a/recipes/msteams/index.js b/recipes/msteams/index.js
index d1bd721..e04254f 100644
--- a/recipes/msteams/index.js
+++ b/recipes/msteams/index.js
@@ -2,4 +2,30 @@ module.exports = Ferdi => class MicrosoftTeams extends Ferdi {
2 overrideUserAgent() { 2 overrideUserAgent() {
3 return window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+ \([^)]+\)/g, '').trim(); 3 return window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+ \([^)]+\)/g, '').trim();
4 } 4 }
5
6 // https://docs.microsoft.com/en-us/microsoftteams/troubleshoot/teams-sign-in/sign-in-loop#resolution
7 // https://docs.microsoft.com/en-us/microsoft-365/enterprise/urls-and-ip-address-ranges?view=o365-worldwide#skype-for-business-online-and-microsoft-teams
8 knownCertificateHosts() {
9 return [
10 'aka.ms',
11 'aspnetcdn.com',
12 'azure.net',
13 'azureedge.net',
14 'live.com',
15 'microsoft.com',
16 'microsoftonline.com',
17 'msecnd.net',
18 'msedge.net',
19 'mstea.ms',
20 'office.net',
21 'okta.com',
22 'sfbassets.com',
23 'skype.com',
24 'skypeassets.com',
25 'skypeforbusiness.com',
26 'tenor.com',
27 'windows.com',
28 'windows.net',
29 ];
30 };
5}; 31};
diff --git a/recipes/msteams/package.json b/recipes/msteams/package.json
index c79276f..2350372 100644
--- a/recipes/msteams/package.json
+++ b/recipes/msteams/package.json
@@ -1,7 +1,7 @@
1{ 1{
2 "id": "msteams", 2 "id": "msteams",
3 "name": "Microsoft Teams", 3 "name": "Microsoft Teams",
4 "version": "3.1.1", 4 "version": "3.1.2",
5 "license": "MIT", 5 "license": "MIT",
6 "aliases": [ 6 "aliases": [
7 "teamsChat" 7 "teamsChat"
diff --git a/recipes/msteams/webview.js b/recipes/msteams/webview.js
index bf25562..786cd9b 100644
--- a/recipes/msteams/webview.js
+++ b/recipes/msteams/webview.js
@@ -2,6 +2,11 @@ const _path = _interopRequireDefault(require('path'));
2 2
3function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } 3function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
4 4
5window.addEventListener('beforeunload', async () => {
6 Ferdi.clearStorageData(['appcache', 'serviceworkers', 'cachestorage', 'websql', 'indexdb']);
7 Ferdi.releaseServiceWorkers();
8});
9
5module.exports = Ferdi => { 10module.exports = Ferdi => {
6 const getMessages = () => { 11 const getMessages = () => {
7 let messages = 0; 12 let messages = 0;
diff --git a/recipes/office365-owa/index.js b/recipes/office365-owa/index.js
index 89568a6..a20b158 100644
--- a/recipes/office365-owa/index.js
+++ b/recipes/office365-owa/index.js
@@ -2,4 +2,140 @@ module.exports = Ferdi => class Outlook extends Ferdi {
2 overrideUserAgent() { 2 overrideUserAgent() {
3 return window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+ \([^)]+\)/g, '').trim(); 3 return window.navigator.userAgent.replace(/(Ferdi|Electron)\/\S+ \([^)]+\)/g, '').trim();
4 } 4 }
5
6 // https://docs.microsoft.com/en-us/microsoftteams/troubleshoot/teams-sign-in/sign-in-loop#resolution
7 // https://docs.microsoft.com/en-us/microsoft-365/enterprise/urls-and-ip-address-ranges?view=o365-worldwide#microsoft-365-common-and-office-online
8 knownCertificateHosts() {
9 return [
10 'accounts.google.com',
11 'acompli.com',
12 'acompli.helpshift.com',
13 'acompli.net',
14 'ad.atdmt.com',
15 'ajax.aspnetcdn.com',
16 'amp.azure.net',
17 'api.dropboxapi.com',
18 'api.login.yahoo.com',
19 'api.meetup.com',
20 'apis.live.net',
21 'app.adjust.com',
22 'app.box.com',
23 'appex-rf.msn.com',
24 'apps.identrust.com',
25 'assets-yammer.com',
26 'assets.onestore.ms',
27 'auth.gfx.ms',
28 'autologon.microsoftazuread-sso.com',
29 'azure-apim.net',
30 'azureedge.net',
31 'bing.com',
32 'bing.net',
33 'bit.ly',
34 'cdn.onenote.net',
35 'cdn.optimizely.com',
36 'cert.int-x3.letsencrypt.org',
37 'cl2.apple.com',
38 'clientconfig.microsoftonline-p.net',
39 'cloudapp.net',
40 'connect.facebook.net',
41 'cortana.ai',
42 'crl.globalsign.net',
43 'crl.identrust.com',
44 'd.docs.live.net',
45 'data.flurry.com',
46 'dc.services.visualstudio.com',
47 'digicert.com',
48 'docs.live.net',
49 'dropbox.com',
50 'edgesuite.net',
51 'en-us.appex-rf.msn.com',
52 'entrust.net',
53 'evernote.com',
54 'geotrust.com',
55 'globalsign.com',
56 'googleapis.com',
57 'graph.facebook.com',
58 'helpshift.com',
59 'hockeyapp.net',
60 'isrg.trustid.ocsp.identrust.com',
61 'itunes.apple.com',
62 'live.comlocalytics.com',
63 'localytics.com',
64 'login.microsoftonline-p.com',
65 'login.windows-ppe.net',
66 'm.facebook.com',
67 'mail.google.com',
68 'management.azure.com',
69 'media.azure.net',
70 'mem.gfx.ms',
71 'microsoft.com',
72 'microsoft.commicrosoft.com',
73 'microsoftonline-p.com',
74 'microsoftonline.com',
75 'microsoftstream.com',
76 'microsoftusercontent.com',
77 'msauth.net',
78 'msauthimages.net',
79 'msecnd.net',
80 'msedge.net',
81 'msft.net',
82 'msftauth.net',
83 'msftauthimages.net',
84 'msftidentity.com',
85 'msidentity.com',
86 'msocdn.com',
87 'nexus.microsoftonline-p.com',
88 'nps.onyx.azure.net',
89 'o365weve.com',
90 'oaspapps.com.akadns.net',
91 'oaspapps.com',
92 'ocsp.int-x3.letsencrypt.org',
93 'ocsp.msocsp.com',
94 'office.com',
95 'office.net ',
96 'office365.com',
97 'office365servicehealthcommunications.cloudapp.net',
98 'officeconfig.msocdn.com',
99 'omniroot.com',
100 'onedrive.com',
101 'onenote.com',
102 'outlook.com',
103 'outlookmobile.com',
104 'p100-sandbox.itunes.apple.com',
105 'partnerservices.getmicrosoftkey.com',
106 'phonefactor.net',
107 'platform.linkedin.com',
108 'play.google.com',
109 'portal.cloudappsecurity.com',
110 'powerapps.com',
111 'prod.msocdn.com',
112 'public-trust.com',
113 'rink.hockeyapp.net',
114 's.ytimg.com',
115 's0.assets-yammer.com',
116 'sdk.hockeyapp.net',
117 'secure.aadcdn.microsoftonline-p.com',
118 'secure.meetup.com',
119 'sharepointonline.com',
120 'shellprod.msocdn.com',
121 'social.yahooapis.com',
122 'staffhub.ms',
123 'sway-cdn.com',
124 'sway-extensions.com',
125 'sway.com',
126 'symcb.com',
127 'symcd.com',
128 'uservoice.com',
129 'verisign.com',
130 'verisign.net',
131 'view.atdmt.com',
132 'virtualearth.net',
133 'windows.com',
134 'windows.net',
135 'windowsazure.com',
136 'yammer.com',
137 'yammerusercontent.com',
138 'youtube.com',
139 ];
140 };
5}; 141};
diff --git a/recipes/office365-owa/package.json b/recipes/office365-owa/package.json
index 0bd1afd..2aeb92b 100644
--- a/recipes/office365-owa/package.json
+++ b/recipes/office365-owa/package.json
@@ -1,7 +1,7 @@
1{ 1{
2 "id": "office365-owa", 2 "id": "office365-owa",
3 "name": "Office 365 Outlook", 3 "name": "Office 365 Outlook",
4 "version": "1.4.2", 4 "version": "1.4.3",
5 "license": "MIT", 5 "license": "MIT",
6 "aliases": [ 6 "aliases": [
7 "live.com" 7 "live.com"