Need to create package

TechUST 516 Reputation points
2023-04-24T20:52:31.7433333+00:00

Hi Expert, I need to deploy these below reg keys, can you please help me to create batch file or PowerShell script for this. [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION]
"NetX360v2.exe"=dword:11000
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_SCRIPTURL_MITIGATION]
"NetX360v2.exe"=dword:00000001

Windows
Windows
A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.
5,496 questions
Microsoft System Center
Microsoft System Center
A suite of Microsoft systems management products that offer solutions for managing datacenter resources, private clouds, and client devices.
1,012 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,551 questions
Microsoft Configuration Manager Deployment
Microsoft Configuration Manager Deployment
Microsoft Configuration Manager: An integrated solution for for managing large groups of personal computers and servers.Deployment: The process of delivering, assembling, and maintaining a particular version of a software system at a site.
992 questions
0 comments No comments
{count} votes

Accepted answer
  1. AllenLiu-MSFT 45,381 Reputation points Microsoft Vendor
    2023-04-25T02:23:51.9566667+00:00

    Hi, @TechUST

    Thank you for posting in Microsoft Q&A forum.

    It seems the key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_SCRIPTURL_MITIGATION" does not exist by default, so we need to create the key before adding the value.

    The Powershell script is:

    set-itemproperty -path registry::'HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION' -name NetX360v2.exe -type "DWord" -value "11000"
    
    New-Item -path registry::'HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_SCRIPTURL_MITIGATION' -value ""
    
    set-itemproperty -path registry::'HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_SCRIPTURL_MITIGATION' -name NetX360v2.exe -type "DWord" -value "00000001"
    
    

    1

    2

    3


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Add comment".


1 additional answer

Sort by: Most helpful
  1. Limitless Technology 44,391 Reputation points
    2023-04-25T14:09:54.9666667+00:00

    Hello there, You can first create the key with Powershell and then modify them using GPO . https://devblogs.microsoft.com/scripting/use-powershell-to-easily-create-new-registry-keys/ With group policies, it is also possible to delete or modify the value of an existing key Depending on the hive (HKLM / HKCU), the strategy should be placed on the correct OU (Organizational unit) and the correct computer or user configuration. The registry settings are available in the Computer and User configuration. Hope this resolves your Query !! --If the reply is helpful, please Upvote and Accept it as an answer--

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.