Skip to content
This repository has been archived by the owner on Sep 6, 2019. It is now read-only.

View/loadUrl doesn't prevent loading the URL #2122

Closed
Cyclu opened this issue Jan 20, 2015 · 5 comments
Closed

View/loadUrl doesn't prevent loading the URL #2122

Cyclu opened this issue Jan 20, 2015 · 5 comments
Labels

Comments

@Cyclu
Copy link

Cyclu commented Jan 20, 2015

I wonder why View/loadUrl even is restricted doesn't prevent loading the URL "http://" also the local URL like this "file:///" that's true for all tried applications.

Here is example with BubbleUPnP I can see the tips page and the changelog under Settings>About/Help:
screenshot_2015-01-20-11-32-18

Google Search also can display the result page:
screenshot_2015-01-20-12-27-08

@M66B M66B added the question label Jan 20, 2015
@M66B
Copy link
Owner

M66B commented Jan 20, 2015

Please provide a logcat as short as possible.
Also read the limitations: https://github.com/M66B/XPrivacy#limitations
See also issue #1685

@Cyclu
Copy link
Author

Cyclu commented Jan 20, 2015

Here is the logcat for BubbleUPnP which use a library "chromium_net" I think this library is the culprit.

01-20 16:09:16.452 I/LibraryLoader(1200): Expected native library version number "",actual native library version number ""
01-20 16:09:16.452 I/chromium(1200): [INFO:library_loader_hooks.cc(116)] Chromium logging enabled: level = 0, default verbosity = 0
01-20 16:09:16.462 E/chromium(1200): [ERROR:resource_bundle.cc(607)] Failed to load /data/data/com.bubblesoft.android.bubbleupnp/app_webview/paks/webviewchromium.pak
01-20 16:09:16.572 W/chromium(1200): [WARNING:resource_bundle.cc(368)] Unable to load image with id 5746
01-20 16:09:16.582 V/GAV4    (1200): Thread[GAThread,5,main]: Loaded clientId
01-20 16:09:18.382 I/chromium(1200): [INFO:CONSOLE(12)] "Not allowed to load local resource: file:///android_asset/webkit/android-weberror.png", source: data:text/html,chromewebdata (12)
01-20 16:09:21.622 V/GAV4    (1200): Thread[GAThread,5,main]: Loaded clientId
01-20 16:09:24.872 W/chromium(1200): [WARNING:resource_bundle.cc(368)] Unable to load image with id 5746
01-20 16:29:32.611 I/XPrivacy(1237): Get service uid=10170 Url/http://bubblesoftapps.com/bubbleupnp/tips2.html=null 0 ms
01-20 16:29:32.611 I/XPrivacy(1237): Get service 10170/loadUrl(http://bubblesoftapps.com/bubbleupnp/tips2.html;null) view=!restricted? (ccached) 3 ms
01-20 16:29:32.611 I/XPrivacy/XWebView(5068): Get client 10170/loadUrl(http://bubblesoftapps.com/bubbleupnp/tips2.html;null) view=!restricted 3 ms

Here is another logcat for WiFiInfoConnect which not use any native library:

1-20 16:21:27.112 I/LibraryLoader(7311): Expected native library version number "",actual native library version number ""
01-20 16:21:27.112 I/chromium(7311): [INFO:library_loader_hooks.cc(116)] Chromium logging enabled: level = 0, default verbosity = 0
01-20 16:21:27.132 E/chromium(7311): [ERROR:resource_bundle.cc(607)] Failed to load /data/data/jp.webware.WifiConnect/app_webview/paks/webviewchromium.pak
01-20 16:21:29.612 W/chromium(7311): [WARNING:resource_bundle.cc(368)] Unable to load image with id 5746
01-20 16:21:32.182 W/chromium(7311): [WARNING:resource_bundle.cc(368)] Unable to load image with id 5746
01-20 16:21:32.312 E/AndroidProtocolHandler(7311):  at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java)
01-20 16:21:32.312 E/AndroidProtocolHandler(7311):  at java.lang.ClassLoader.loadClass(ClassLoader.java)
01-20 16:21:32.322 E/AndroidProtocolHandler(7311): Unable to open resource URL: file:///android_res/drawable/wificonnect_autoreload.png
01-20 16:46:16.031 I/XPrivacy(1237): Get service uid=10187 Url/file:///android_asset/html/help/help_en.html=null 1 ms
01-20 16:46:16.031 I/XPrivacy(1237): Get service uid=10187 Url//android_asset/html/help/*=null 1 ms
01-20 16:46:16.031 I/XPrivacy(1237): Get service uid=10187 Url//android_asset/html/*=null 1 ms
01-20 16:46:16.031 I/XPrivacy(1237): Get service uid=10187 Url//android_asset/*=null 1 ms
01-20 16:46:16.031 I/XPrivacy(1237): Get service 10187/loadUrl(file:///android_asset/html/help/help_en.html;null) view=!restricted? (ccached) 8 ms
01-20 16:46:16.041 I/XPrivacy/XWebView(10570): Get client 10187/loadUrl(file:///android_asset/html/help/help_en.html;null) view=restricted 10 ms

@M66B
Copy link
Owner

M66B commented Jan 20, 2015

I don't think this can be fixed, but if I have some more time I will look into this restriction again.

@M66B
Copy link
Owner

M66B commented Jan 21, 2015

The restriction loadUrl is to fake the user agent and not to prevent loading URLs. Maybe this is confusing, but XPrivacy is not there to block things, but to hide privacy sensitive data.

@M66B M66B closed this as completed Jan 21, 2015
M66B added a commit that referenced this issue Jan 21, 2015
@M66B
Copy link
Owner

M66B commented Jan 21, 2015

You could create an issue for a new restriction for loading URLs ...

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants