B2G 3G: Support HTTPS proxy

RESOLVED FIXED in Firefox 18

Status

()

Core
DOM: Device Interfaces
RESOLVED FIXED
5 years ago
4 years ago

People

(Reporter: hub, Assigned: st3fan)

Tracking

({b2g-testdriver, unagi})

Trunk
mozilla20
x86_64
Gonk (Firefox OS)
b2g-testdriver, unagi
Points:
---

Firefox Tracking Flags

(blocking-basecamp:+, firefox18 fixed, firefox19 fixed, firefox20 fixed)

Details

Attachments

(1 attachment, 2 obsolete attachments)

(Reporter)

Description

5 years ago
https does not work if APN requires proxy

I use Speakout wireless (see bug 807312)

http works through the proxy. https seems to be like other protocol and not routed through the proxy. This make things like twitter or other sites that require https not work at all. I can't dogfood.
(Reporter)

Updated

5 years ago
Keywords: b2g-testdriver, unagi
(Reporter)

Comment 1

5 years ago
in short, no twitter, no facebook (like if I care), nor anything requiring https. Works fine from Fennec on Android with the same carrier / APN settings (Nightly only)
(Assignee)

Comment 2

5 years ago
Same with Petro Canada Mobility. Requires a proxy and does not work with HTTPS currently.
(Assignee)

Comment 3

5 years ago
This should fix it.

diff --git a/dom/system/gonk/NetworkManager.js b/dom/system/gonk/NetworkManager.js
index a5e7869..30a9aa9 100644
--- a/dom/system/gonk/NetworkManager.js
+++ b/dom/system/gonk/NetworkManager.js
@@ -449,8 +449,10 @@ NetworkManager.prototype = {
      // Do not use this proxy server for all protocols.
      Services.prefs.setBoolPref("network.proxy.share_proxy_settings", false);
      Services.prefs.setCharPref("network.proxy.http", this.active.httpProxyHost);
+      Services.prefs.setCharPref("network.proxy.ssl", this.active.httpProxyHost);
      let port = this.active.httpProxyPort == "" ? 8080 : this.active.httpProxyPort;
      Services.prefs.setIntPref("network.proxy.http_port", port);
+      Services.prefs.setIntPref("network.proxy.ssl_port", port);
    } catch (ex) {
       debug("Exception " + ex + ". Unable to set proxy setting for "
             + this.active.name + " network interface.");
(Reporter)

Comment 4

5 years ago
Created attachment 686418 [details] [diff] [review]
Bug 807659 - Set proxy from APN for https.

Proposed patch by sarentz
(Assignee)

Comment 5

5 years ago
I manually applied the above patch to my 2012-11-28 build by patching /system/b2g/omni.ja

I can now load HTTPS sites in the browser and also use applications that use HTTPS (like for example the Market Place)

This would be great to have for testers.

 S.
So who should we set to review this?
(Reporter)

Comment 7

5 years ago
wait for an updated patch. It is coming soon. I'll get things moving.
(Assignee)

Updated

5 years ago
Component: General → DOM: Device Interfaces
OS: Linux → Gonk (Firefox OS)
Product: Boot2Gecko → Core
Target Milestone: --- → mozilla17
Version: unspecified → Trunk
(Assignee)

Updated

5 years ago
Summary: https does not work if APN requires proxy → B2G 3G: Support HTTPS proxy
(Assignee)

Comment 8

5 years ago
Created attachment 687342 [details] [diff] [review]
Bug 807659 - Also configure HTTPS proxy from APN settings. r=
(Reporter)

Comment 9

5 years ago
Right now bug 817036 is preventing anything from working. But this patch should be ok.
(Reporter)

Updated

5 years ago
Attachment #686418 - Attachment is obsolete: true
(Reporter)

Comment 10

5 years ago
Comment on attachment 687342 [details] [diff] [review]
Bug 807659 - Also configure HTTPS proxy from APN settings. r=

Philip, if you know a better reviewer, please chime in. Thanks.
Attachment #687342 - Flags: review?(philipp)
(Reporter)

Comment 11

5 years ago
Comment on attachment 687342 [details] [diff] [review]
Bug 807659 - Also configure HTTPS proxy from APN settings. r=

Adding blake.
Attachment #687342 - Flags: review?(mrbkap)
(Assignee)

Comment 12

5 years ago
This bug is followup work for the following bug that Jose worked on:

	B2G 3G: Support HTTP proxy
	https://bugzilla.mozilla.org/show_bug.cgi?id=740640

Note the HTTP vs HTTPS.

The problem is that the original work only configures the HTTP proxy while having a proxy configured for the APN actually explicitly means that it should also be used for HTTPS.

My small patch corrects this by also configuring network.proxy.ssl and network.proxy.ssl_port.

Without this, HTTPS will simply not work, which leads to a bad user experience as many sites (including our own like the Marketplace) require HTTPS.

Initially I thought that the HTTP and HTTPS proxy maybe should be specified separately. But this does not seem to be the case. To confirm that I have looked at iOS and Android: both only allow you to set the proxy hostname and port and then use those settings to configure both the HTTP and HTTPS proxy.

This fix is probably not super important for Telefonica, but in Canada we happen to use two (cheap, prepaid) providers for the dogfooding program that both require a proxy to go online. I have tested the patch on my B2G phone with one of those providers and things seem to work well. I can now fully use the web.

Also note that many providers listed in the APN presets that we ship require a proxy host. So this fix would apply to all of those networks too.
(Reporter)

Comment 13

5 years ago
Requesting blocking-basecamp. See comment 12.
blocking-basecamp: --- → ?
Comment on attachment 687342 [details] [diff] [review]
Bug 807659 - Also configure HTTPS proxy from APN settings. r=

Review of attachment 687342 [details] [diff] [review]:
-----------------------------------------------------------------

r=me. Thanks for the patch, Stefan!

This should definitely block basecamp and should land in v1.
Attachment #687342 - Flags: review?(philipp)
Attachment #687342 - Flags: review?(mrbkap)
Attachment #687342 - Flags: review+
blocking-basecamp: ? → +
(Assignee)

Comment 15

5 years ago
Created attachment 687898 [details] [diff] [review]
687342: Bug 807659 - Also configure HTTPS proxy from APN settings. r=philikon

Updated the reviewer in the commit message.
Attachment #687342 - Attachment is obsolete: true
(Assignee)

Updated

5 years ago
Keywords: checkin-needed
https://hg.mozilla.org/integration/mozilla-inbound/rev/310c028ec15d
Keywords: checkin-needed

Comment 17

5 years ago
Stefan, it looks like you're working on this. 
So, I assigned you as the owner. If you're not, please remove your name. :)
Thanks.
Assignee: nobody → sarentz
(Reporter)

Comment 18

5 years ago
Comment on attachment 687898 [details] [diff] [review]
687342: Bug 807659 - Also configure HTTPS proxy from APN settings. r=philikon

[Approval Request Comment]

Blocking basecamp
b2g only.
Attachment #687898 - Flags: approval-mozilla-beta?
Attachment #687898 - Flags: approval-mozilla-aurora?

Updated

5 years ago
Attachment #687898 - Flags: approval-mozilla-beta?
Attachment #687898 - Flags: approval-mozilla-beta+
Attachment #687898 - Flags: approval-mozilla-aurora?
Attachment #687898 - Flags: approval-mozilla-aurora+
https://hg.mozilla.org/mozilla-central/rev/310c028ec15d
Status: NEW → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → FIXED
https://hg.mozilla.org/releases/mozilla-aurora/rev/9eae59ffecdd
https://hg.mozilla.org/releases/mozilla-beta/rev/6b0ff34db352
status-firefox18: --- → fixed
status-firefox19: --- → fixed
status-firefox20: --- → fixed
Target Milestone: mozilla17 → mozilla20
You need to log in before you can comment on or make changes to this bug.