Skip to content

Commit

Permalink
selenium: proxy "localhost" in Chrome 72
Browse files Browse the repository at this point in the history
Change ExtensionSelenium to add an argument to ChromeOptions to not
bypass localhost when proxying, thanks to:
cypress-io/cypress#1872 (comment)
for the syntax to use with `proxy-bypass-list`.
Update changes in ZapAddOn.xml file.
  • Loading branch information
thc202 committed Jan 31, 2019
1 parent 1927491 commit 0965ae6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -671,6 +671,7 @@ private static WebDriver getWebDriverImpl(int requester, Browser browser, String
case CHROME:
ChromeOptions chromeOptions = new ChromeOptions();
setCommonOptions(chromeOptions, proxyAddress, proxyPort);
chromeOptions.addArguments("--proxy-bypass-list=<-loopback>");
return new ChromeDriver(chromeOptions);
case FIREFOX:
FirefoxOptions firefoxOptions = new FirefoxOptions();
Expand Down
1 change: 1 addition & 0 deletions src/org/zaproxy/zap/extension/selenium/ZapAddOn.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
Tweak error message shown when failed to start/connect to the browser.<br>
Disable Firefox JSON viewer when used by AJAX Spider to prevent crawl.<br>
Prevent WebDriver process leak when closing ZAP.<br>
Ensure "localhost" is proxied through ZAP on Chrome >= 72.<br>
]]>
</changes>
<extensions>
Expand Down

0 comments on commit 0965ae6

Please sign in to comment.