├── LICENSE
├── Readme.md
├── package.json
├── plugin.xml
└── scripts
└── afterBuild.js
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2016 The App Workshop
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/Readme.md:
--------------------------------------------------------------------------------
1 | # Meteor 1.4.1 Cordova iOS 10 Content Security Policy Web Sockets Fix
2 |
3 | That's a mouthful of a title. But it's a really simple little cordova plugin that
4 | just rewrites the ```META``` tag in your cordova build's ```platforms/ios/www/index.html```
5 | file.
6 |
7 | This fixes an issue with meteor 1.4 (and probably other cordova apps) where iOS 10's content security
8 | policy prevents connections via web sockets.
9 |
10 | The new content security policy META element will be:
11 |
12 | ```
13 |
14 | ```
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "meteor-ios10-csp-fix",
3 | "version": "0.1.0",
4 | "description": "Fixes the iOS 10 issue with websockets: \"Refused to connect to wss://mydomain.com/sockjs/.../websocket because it appears in neither the connect-src directive nor the default-src directive of the Content Security Policy\"",
5 | "cordova": {
6 | "id": "meteor-ios10-csp-fix",
7 | "platforms": [
8 | "ios"
9 | ]
10 | },
11 | "repository": {
12 | "type": "git",
13 | "url": "https://github.com/AppWorkshop/meteor-ios10-csp-fix"
14 | },
15 | "keywords": [
16 | "cordova",
17 | "meteor",
18 | "ios",
19 | "ios10",
20 | "csp"
21 | ],
22 | "author": "Mike Cunneen - The App Workshop",
23 | "license": "MIT",
24 | "bugs": {
25 | "url": "https://github.com/AppWorkshop/meteor-ios10-csp-fix/issues"
26 | },
27 | "homepage": "https://github.com/AppWorkshop/meteor-ios10-csp-fix#readme"
28 | }
29 |
--------------------------------------------------------------------------------
/plugin.xml:
--------------------------------------------------------------------------------
1 |
2 |