IE protected mode for the local system account

I have a Windows service that runs Team City Build agent on Windows 7.

This agent runs NUnit tests that use Selenium IE web drivers to run a series of tests.

In order for the Selenium IE web drivers to work, the protected mode for all zones must be set to the same value (the protected mode is turned on or off).

The problem is that the default settings for the local system account are invalid (some zones work in protected mode, while others do not).

Can someone tell me how to change the protected mode settings for all users or the user of the local system account?

+5
source share
4 answers

Here is the solution (and I was in every corner of the Internet to get this):

Launch RegEditand go to this key:

HKEY_USERS\S-1-5-18\Software\Microsoft\Windows\CurrentVersion\Internet Settings\Zones

On my machine (Windows 7), the local system account S-1-5-18. This may be the same for all versions of Windows, but I do not know about it.

In this section of the registry there are five more keys 1, 2, 3, 4 and 5 - each of which represents a zone.

For each zone, if there is a DWORD value with the name "2500", set it to 0 to disable protected mode. Please note that you do not need to add it if it is not.

It is assumed that a value of 2500 will control the Enable Protected Mode checkbox.

UPDATE (from an anonymous user):

- , " " (UI0Detect) ( , Windows 8/2012 HKLM\SYSTEM\CurrentControlSet\Control\Windows\NoInteractiveServices , ) psexec

psexec -si 0 "C:\Program Files\Internet Explorer\iexplore.exe"

" ", Internet Explorer "" β†’ " " | .

!

+9

UAC, .

0

The best solution description is fooobar.com/questions/1085560 / ...

0
source

IE WebDriver has a parameter that tells it to ignore protected mode settings. Judging by the name of the setting, this can lead to some "instability", but I had no problems with this approach:

var options = new InternetExplorerOptions();
// avoid the "Protected Mode must be set to the same value (enabled or disabled) for all zones" error
options.IntroduceInstabilityByIgnoringProtectedModeSettings = true;
return new InternetExplorerDriver(options);
-1
source

All Articles