Enhancement request: allow programatically setting idle socket timeout through Android API
Reported by
chad.hay...@gmail.com,
Apr 7 2017
|
||||||
Issue descriptionSteps to reproduce the problem: We have an enterprise web application in which the login happens through a custom Identity Provider (IdP). We deploy our application shell on managed enterprise Android devices (these are not consumer based devices). The native shell application uses the Android WebView in order to show our login page. We recently encountered an issue at one of our client sites where an outbound firewall was silently tearing down connections to our servers after a 1 minute idle period. The firewall was not sending any RST or FIN packets to the device, so the OS would not tear down the connections. This ultimately let our end users get into a situation where if they loaded our login page, let the device sit between 2 and 5 minutes, and tried to log in, the login would "hang" for several minutes until it eventually timed out. After several days of investigation we discovered the requests were getting "stalled" (or black-holed), because of the firewall silently tearing down connections. Upon looking at the Chromium source code we found that it will reuse idle socket connections for up to 5 minutes [1]. We also found that Chromium on Android will not sent TCP keepalives [2], so we can't prevent these socket connections from being closed by the firewall. [1] https://chromium.googlesource.com/chromium/src.git/+/50.0.2661.86/net/socket/client_socket_pool.cc#18 [2] https://chromium.googlesource.com/chromium/src.git/+/50.0.2661.86/net/socket/tcp_socket_posix.cc#365 What is the expected behavior? The proposed solution is to allow developers to set the idle socket timeout through an Android API. This could be a part of the WebView class or another system level API. What went wrong? Currently there is no way to configure the idle socket timeout without building a custom version of Chromium. Since we do not control the OS, it is our understanding that we cannot install a custom System WebView APK without root privileges (something we do not have). Did this work before? N/A Does this work in other browsers? N/A Chrome version: 50.0.2661.86 Channel: n/a OS Version: 6.0.1 Flash Version:
,
Apr 7 2017
I will look at it, but unlikely.
,
Apr 7 2017
Thank you. Are there alternatives or other ways for us to get a custom Chromium build on a device without root privileges? I'm not opposed to building our own version, just unsure how we deploy it.
,
Apr 7 2017
something to replace Webview package on nonroot devices? no.
,
Apr 14 2017
,
Apr 21 2017
Hi, wanted to see if there's been any progress on this?
,
Sep 1 2017
this did not go anywhere in Android O.
,
Sep 8 2017
I am going to send it to network team to comment on. Perhaps there is a different solution.
,
Sep 8 2017
,
Apr 25 2018
The network stack team isn't terribly interested in implementing this, unless there's a need seen by the WebView team.
,
Apr 25 2018
Yeah unfortunately I think this has been the only request for this we've come across, so it's hard to justify. |
||||||
►
Sign in to add a comment |
||||||
Comment 1 by ppolise...@chromium.org
, Apr 7 2017