commandline for adding trusted intranet site to IE

Stian Størstfeskar Andersen picture Stian Størstfeskar Andersen · Mar 27, 2014 · Viewed 21k times · Source

I'm running a batch from a network share. The batch is opening a new batch, and then I get a security warning. I want to remove this so I don't need to push "run" all the time. I tested it manually by entering the server IP to Trusted Sites on intranet in IE. Is there a command I can inject to my batch making my computer add this automatically?

Answer

Brian Tompsett - 汤莱恩 picture Brian Tompsett - 汤莱恩 · Jan 25, 2015

(Answered by the OP in edits. See Question with no answers, but issue solved in the comments (or extended in chat) )

The OP wrote:

  1. Made a regfile:

Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\192.168.1.241] "*"=dword:00000001"

  1. Made a batchfile:

regedit -s addtrust.reg

WARNING: Editing the registry is quite dangerous, and shouldn't be used to do this, though it may be the only way.