Click here to Skip to main content
15,886,199 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Any idea how can I Change Internet Explorer- Local Intranet zone security settings using a script?

I tried few things but no success
I manage to found these settings and key codes which I am looking to change:

CSS
Local Intranet Zone->  1        
--
Enable: 2201  ActiveX controls and plug-ins: Automatic prompting for ActiveX controls
Enable: 1201  ActiveX controls and plug-ins: Initialize and script ActiveX controls not marked as safe for scripting
--
Disable: 2102     Miscellaneous: Allow script initiated windows without size or position constraints
Enable:  1406     Miscellaneous: Access data sources across domains
Disable: 1809     Miscellaneous: Use Pop-up Blocker
Disable: 2301     Miscellaneous: Use SmartScreen Filter
--
Enable:  1407     Scripting: Allow Programmatic clipboard access
--
0x00000000 Automatically logon with current username and password



Source: http://support.microsoft.com/kb/182569/en-us[^]


Any help would be appreciated. Thanks.
Posted
Comments
[no name] 19-Aug-14 7:06am    
The short answer is: You don't. Allow the user to manage the security of their own hardware.
Sergey Alexandrovich Kryukov 19-Aug-14 16:03pm    
I basically agree. But probably OP needs a "registry script". This is quite possible, please see my answer.
I credited your comment.
—SA
Sergey Alexandrovich Kryukov 19-Aug-14 15:50pm    
What do you mean by "script"? What script, hosted where?
—SA

1 solution

Please see my comment to the question. But your link at the end of the post suggests that you may mean the system registry "script". You can do it; and it will require privilege elevation, which is natural, for safety.

Do the following: run Regedit (confirm security elevation), locate the registry key in question. Do the modifications you need to do for IE. Better yet, do the changes in IE, and see what difference they make. You can preserve part of the Register and restore it later; see below.

Now, in Regedit, select the parent node of the changed data, and export in in a file using File —> Export. You will obtain some .reg file.
Next time, when you or your user needs the same changes, click on this file (again, elevation of the privileges will be required). It will "execute the registry scrip), modifying the registry to the data recorded in this file. Likewise, you can execute this file through a shell in any other way: programmatically starting a process, using a batch file, some other scripting system, and the like.

That's all.

But, to close the issue, I would like to note: why taking care about anything IE-specific? The users should use any Web browsers by their choice. And care about security by themselves. Basically, I agree with the comment to the question by Wes Aday.

Besides, I suggest you never allow ActiveX controls; they are too unsafe in general. However, corporations do it, but only for intranet and limited by internal corporate scripts. Not the best practice, anyway.

—SA
 
Share this answer
 
v2
Comments
Zakizawa 21-Aug-14 10:14am    
Tnx guys. But its a specific requirement as i want is like a vbs or bat file script as we reset IE settings alot and after we have to change these settings to make things work again. Thats all.
Sergey Alexandrovich Kryukov 21-Aug-14 10:53am    
Okay, then use it all in a batch or VBS script. I just explained how to do it. What else are you missing?
—SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900