Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Chrome 21 is not supporting --disable-web-security command line switch

Since the latest release of Google Chrome browser version 21.* and Selenium Chrome Driver version 22.* , the special command line switch “--disable-web-security” which we have been using to test our iframes with different domain is no longer supported (deprecated).Is there any workaround for the same to automate our frame which is in different domain in Chrome browser?

Our existing functional Automation framework completely depends on this switch (--disable-web-security).Response would be appreciated.

like image 841
user1523153 Avatar asked Jul 13 '12 09:07

user1523153


People also ask

How do I run chrome with CORS disabled?

How do I disable CORS in Windows 10 chrome? Right click on desktop, add new shortcut. Add the target as "[PATH_TO_CHROME]\chrome.exe" –disable-web-security –disable-gpu –user-data-dir=~/chromeTemp. Click OK.

How do I know if chrome security is disabled?

In Windows - Right Click (or Shift+right click, in-case of taskbar) on Chrome Icon. Select Properties. In "Target" text-box, add --disable-web-security flag.


1 Answers

You don't need a workaround, the flag still works, what's new is the warning.

I just performed a test using jQuery to send an AJAX request to another domain and it worked using the command-line flag, and it didn't when not using it.

It would be nice to have a way to disable the "yellow infobar", though.

(I'm running Chrome 21.0.1180.60).

like image 50
gabrielmaldi Avatar answered Nov 09 '22 01:11

gabrielmaldi