You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ag...@apache.org on 2015/03/03 02:38:25 UTC

[1/2] android commit: Simplify default navigation policy to allow navigations within `/app_webview/`

Repository: cordova-android
Updated Branches:
  refs/heads/master c237a1c0d -> 1ad280db9


Simplify default navigation policy to allow navigations within `/app_webview/`

It's really on XHRs to it that are an issue.


Project: http://git-wip-us.apache.org/repos/asf/cordova-android/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-android/commit/035c3ad3
Tree: http://git-wip-us.apache.org/repos/asf/cordova-android/tree/035c3ad3
Diff: http://git-wip-us.apache.org/repos/asf/cordova-android/diff/035c3ad3

Branch: refs/heads/master
Commit: 035c3ad319d93314780efdab4e5f87c088922483
Parents: c237a1c
Author: Andrew Grieve <ag...@chromium.org>
Authored: Fri Feb 27 15:46:17 2015 -0500
Committer: Andrew Grieve <ag...@chromium.org>
Committed: Fri Feb 27 15:46:17 2015 -0500

----------------------------------------------------------------------
 framework/src/org/apache/cordova/PluginManager.java | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-android/blob/035c3ad3/framework/src/org/apache/cordova/PluginManager.java
----------------------------------------------------------------------
diff --git a/framework/src/org/apache/cordova/PluginManager.java b/framework/src/org/apache/cordova/PluginManager.java
index 9424a6f..4d7c823 100755
--- a/framework/src/org/apache/cordova/PluginManager.java
+++ b/framework/src/org/apache/cordova/PluginManager.java
@@ -362,13 +362,7 @@ public class PluginManager {
         }
 
         // Default policy:
-        // Internal urls on file:// or data:// that do not contain "/app_webview/" are allowed for navigation
-        if (url.startsWith("file://") || url.startsWith("data:")) {
-            // This directory on WebKit/Blink based webviews contains SQLite databases!
-            // DON'T CHANGE THIS UNLESS YOU KNOW WHAT YOU'RE DOING!
-            return !url.contains("/app_webview/");
-        }
-        return false;
+        return url.startsWith("file://");
     }
 
     /**


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org


[2/2] android commit: Add an `isSecretEstablished()` getter to CordovaBridge

Posted by ag...@apache.org.
Add an `isSecretEstablished()` getter to CordovaBridge

Not being used, but might be of use to an Engine plugin or a Whitelist
plugin.


Project: http://git-wip-us.apache.org/repos/asf/cordova-android/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-android/commit/1ad280db
Tree: http://git-wip-us.apache.org/repos/asf/cordova-android/tree/1ad280db
Diff: http://git-wip-us.apache.org/repos/asf/cordova-android/diff/1ad280db

Branch: refs/heads/master
Commit: 1ad280db985cd1e6176f194407ecf9272ad06aae
Parents: 035c3ad
Author: Andrew Grieve <ag...@chromium.org>
Authored: Mon Mar 2 20:37:33 2015 -0500
Committer: Andrew Grieve <ag...@chromium.org>
Committed: Mon Mar 2 20:37:33 2015 -0500

----------------------------------------------------------------------
 framework/src/org/apache/cordova/CordovaBridge.java | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-android/blob/1ad280db/framework/src/org/apache/cordova/CordovaBridge.java
----------------------------------------------------------------------
diff --git a/framework/src/org/apache/cordova/CordovaBridge.java b/framework/src/org/apache/cordova/CordovaBridge.java
index 50eb901..b9c6098 100644
--- a/framework/src/org/apache/cordova/CordovaBridge.java
+++ b/framework/src/org/apache/cordova/CordovaBridge.java
@@ -107,6 +107,10 @@ public class CordovaBridge {
         expectedBridgeSecret = -1;
     }
 
+    public boolean isSecretEstablished() {
+        return expectedBridgeSecret != -1;
+    }
+
     /** Called by cordova.js to initialize the bridge. */
     int generateBridgeSecret() {
         SecureRandom randGen = new SecureRandom();


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org