-
Pavol Marko authored
(Reland with WebviewProxyAuthLoginTest browsertext fix) This CL fixes sign-in behind an authenticated proxy. Two actual changes were necessary in this context: - SigninPartitionManager: copy auth data from the system request context into new StoragePartitions This makes SigninPartitionManager::StartSigninSession async, which made small changes necessary in GaiaScreenHandler and EnrollmentScreenHandler - SigninScreenHandler: Don't reload gaia immediately when auth details have been supplied. This was unnecessary (the URL Request will continue) and actually harmful, as now that we're using a new StoragePartition for each sign-in attempt, this discards auth data before we can copy them. To support the browsertest, testserver.py gets an argument to redirect CONNECT requests to localhost when proxying (in sign-in browsertests without proxy, we use RuleBasedHostResolverProc::AddRule to achieve this effect). unit_tests --gtest_filter=SigninPartitionManagerTest* Manual test: Setup: Setup an proxy server with Basic authentication Configure the device to use the proxy server. Make sure the user adding screen is shown. Test 1: Expect proxy auth dialog. Enter correct proxy auth data. Expect that sign-in screen is shown and sign-in works. Test 2: Expect proxy auth dialog. Enter incorrect proxy auth data. Expect that proxy-auth dialog is shown again. Test 3: Expect proxy auth dialog. Press Cancel. Expect that a network error dialog is shown. Press "try to sign in again". Expect proxy auth dialog. Enter correct proxy auth data. Expect that sign-in screen is shown and sign-in works. Bug: 793524 Test: browser_tests --gtest_filter=WebviewProxyAuthLoginTest.* && Change-Id: I56dafa240ad3bb5902517688a5cb17e309f2982d Reviewed-on: https://chromium-review.googlesource.com/850472Reviewed-by:Matt Menke <mmenke@chromium.org> Reviewed-by:
Xiyuan Xia <xiyuan@chromium.org> Commit-Queue: Pavol Marko <pmarko@chromium.org> Cr-Commit-Position: refs/heads/master@{#527103}
569a169a