[
https://issues.apache.org/jira/browse/CB-9558?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14713458#comment-14713458
]
ASF GitHub Bot commented on CB-9558:
------------------------------------
GitHub user voliva opened a pull request:
https://github.com/apache/cordova-ios/pull/155
CB-9558 Blob schemes won't load in iframes
Blob schemes won't load in iframes, even though blob:* is whitelisted.
This is needed for special cases, like when using an epub reader
([ePub.js](https://github.com/futurepress/epub.js/)), that downloads an epub,
extracts it to a blob and displays it in an iframe.
This currently works perfectly in cordova-android, but not in cordova-ios.
I've debugged why it happens... the Whitelists says the scheme is allowed
and the URL is allowed, but then
```Objective-C
[NSURLConnection canHandleRequest]
```
returns false, thus cancelling the request. Hardcoding "blob" as an allowed
scheme (like it's currently done with mailto, tel and sms) fixes this issue.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/voliva/cordova-ios 3.9.x
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/cordova-ios/pull/155.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #155
----
commit cef9b1fa4d4999f3632877ab86c05862ee741950
Author: daserge <[email protected]>
Date: 2015-06-11T18:13:06Z
CB-8197 Switch to nodejs for ios platform scripts
Convert copy-www-build-step.sh to nodejs
Adds glob module and bundledDependencies to package.json. This closes #146
commit 043d2b8cb5c463e56e0cd960fbc99f28f2fb6b7b
Author: daserge <[email protected]>
Date: 2015-07-16T19:03:12Z
CB-9273 "Copy www build phase" node is not found
commit a89fe4ed3550527eea51d6b2015e42d6398c9733
Author: sgrebnov <[email protected]>
Date: 2015-07-27T13:57:07Z
CB-9406 updated RELEASENOTES
commit dd6673d4163739039772490512d427eeb325a6e4
Author: sgrebnov <[email protected]>
Date: 2015-07-28T07:49:33Z
Updating version to 3.9.0
commit 7e0d39a84890398589f29f7fdae0a619e4d87ece
Author: sgrebnov <[email protected]>
Date: 2015-07-28T10:41:28Z
Update JS snapshot to version 3.9.0 (via coho)
commit 209c1e9e025b71475e4670b058fba43c2b08fecb
Author: sgrebnov <[email protected]>
Date: 2015-07-28T10:41:28Z
Set VERSION to 3.9.0 (via coho)
commit aecce2e05bb44a4499d991cc19d881372f9366dc
Author: daserge <[email protected]>
Date: 2015-08-05T16:53:30Z
CB-9453 Updating to [email protected] not building
commit 639b6c33464df6494d1fd3321dee0e7067b34437
Author: Steve Gill <[email protected]>
Date: 2015-08-05T21:49:17Z
CB-9463 updated RELEASENOTES
commit 8d128c7d2f8bab880dc30ce68db3f6977531b9c1
Author: Steve Gill <[email protected]>
Date: 2015-08-05T22:29:23Z
CB-9463 added version to CDVAvailability.h
commit 211969dd792275a65315678b78e308331c7a1794
Author: Steve Gill <[email protected]>
Date: 2015-08-05T22:31:30Z
Update JS snapshot to version 3.9.1 (via coho)
commit d98128682c3cd6a9f51948c7cd6c0d6add2eab44
Author: Steve Gill <[email protected]>
Date: 2015-08-05T22:31:30Z
Set VERSION to 3.9.1 (via coho)
commit ebbc6d05995e50312c044dd1ae11d18e1ff669ba
Author: Steve Gill <[email protected]>
Date: 2015-08-11T00:00:52Z
removed bundledependencies from package.json
commit a8ec82bc133c51c6d30f73d4121eae5dc6366102
Author: voliva <[email protected]>
Date: 2015-08-26T13:40:39Z
Blob schemes won't load in iframes
----
> Blob schemes won't load in iframes
> ----------------------------------
>
> Key: CB-9558
> URL: https://issues.apache.org/jira/browse/CB-9558
> Project: Apache Cordova
> Issue Type: Bug
> Components: iOS
> Affects Versions: 3.9.0
> Reporter: VĂctor Oliva Vidal
> Priority: Minor
>
> Blob schemes won't load in iframes, even though blob:* is whitelisted.
> This is needed for special cases, like when using an epub reader
> ([ePub.js|https://github.com/futurepress/epub.js/]), that downloads an epub,
> extracts it to a blob and displays it in an iframe.
> This currently works perfectly in cordova-android, but not in cordova-ios.
> I've debugged why it happens... the Whitelists says the scheme is allowed and
> the URL is allowed, but then
> {code}
> [NSURLConnection canHandleRequest]
> {code}
> returns false, thus cancelling the request. Hardcoding "blob" as an allowed
> scheme (like it's currently done with mailto, tel and sms) fixes this issue.
> I was about to put a pull request in github when I saw your contributing
> guidelines.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]