1. aruiz

    aruiz MDL Novice

    Mar 6, 2018
    23
    2
    0
    Yes, I always used start.cmd
     
  2. Ace2

    Ace2 MDL Expert

    Oct 10, 2014
    1,414
    1,193
    60
    Windows-Defender.cmd
    Code:
    @Echo Off
    
    reg load HKLM\S C:\mount\Windows\System32\Config\SOFTWARE
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-AM-Default-Definitions-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-AM-Default-Definitions-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-AM-Default-Definitions-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-AppLayer-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-AppLayer-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-AppLayer-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-ApplicationGuard-Inbox-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-ApplicationGuard-Inbox-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-ApplicationGuard-Inbox-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Client-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Client-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Client-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-amcore-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-amcore-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-amcore-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-onecore-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-onecore-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-onecore-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Core-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Group-Policy-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Group-Policy-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Group-Policy-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-amcore-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-amcore-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-amcore-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-onecore-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-onecore-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-onecore-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-MDM-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-MDM-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-MDM-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Powershell-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Powershell-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Management-Powershell-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Nis-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v Visibility /t REG_DWORD /d 1 /f
    reg add "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Nis-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1" /v DefVis /t REG_DWORD /d 2 /f
    reg delete "HKLM\S\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages\Windows-Defender-Nis-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1\Owners" /f
    
    reg unload HKLM\S
    Pause
    
    dism /image:C:\mount /Remove-Package /PackageName:Windows-Defender-AM-Default-Definitions-Package~31bf3856ad364e35~amd64~~10.0.18362.1
    dism /image:C:\mount /Remove-Package /PackageName:Windows-Defender-AppLayer-Group-Package~31bf3856ad364e35~amd64~~10.0.18362.1
    dism /image:C:\mount /Remove-Package /PackageName:Windows-Defender-ApplicationGuard-Inbox-Package~31bf3856ad364e35~amd64~~10.0.18362.1
    dism /image:C:\mount /Remove-Package /PackageName:Windows-Defender-Client-Package~31bf3856ad364e35~amd64~~10.0.18362.1
    dism /image:C:\mount /Remove-Package /PackageName:Windows-Defender-Group-Policy-Package~31bf3856ad364e35~amd64~~10.0.18362.1
    Pause

    @MSMG thanks for posting these commands, now i can replace install-wim-tweak.exe with dism.:cool:
     
  3. marioalpha

    marioalpha MDL Novice

    Apr 26, 2017
    31
    7
    0
    I have tried and tried many times, but I can't do step 6> 1
    when adding updates i always get errors with sfc / scannow.

    • MSMG ToolKit : 9.9 with ToolKitHelper.exe 1.0.3132.0
    • x64 ISO : 18363.418.CCCOMA_X64FRE_IT-IT_DV9.ISO
    • x64 SSU : windows10.0-kb4552152-x64_705fda69935538eab5054d9d616e1761742816ec.msu
    • x64 CU : windows10.0-kb4556799-x64_9de920d8738612baa81a751b003ff98f0ce7156b.msu
    • x64 FlPlayer : AMD64-all-windows10.0-kb4537759-x64_ea293539b86301f3c89abbae0d4cc70060d00848.msu
    • x64 NetCU : windows10.0-kb4552931-x64_2db4f6d9a62833406875986aae69351f82f3ca2b.msu
    Extract ISO (1 > 3)
    Select source (1 > 1) (only mount image)
    Apply updates (3 > 4 > Y > 2 > 1 > 2)
    Cleanup (6 > 1)
    Apply changes to image (6 > 2 > Y)
    Rebuild (6 > 1)
    Make ISO (7 > 1)

    I still don't understand where I'm wrong o_O:confused:
     

    Attached Files:

    • CBS.txt
      File size:
      377.4 KB
      Views:
      3
  4. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    6,411
    15,487
    210
    Then check if there is any AV interference with the Toolkit or Mount Directory.

    or

     
  5. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    6,411
    15,487
    210
    Welcome, the credit goes to MDL user lite8 for providing this trick.

     
  6. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    6,411
    15,487
    210
    Check skipping the cleanup step and see if SFC error occurs, in many previous CU's there were SFC scan bugs which were fixed at some point.

     
  7. Windows 10 User

    Windows 10 User MDL Expert

    Feb 2, 2017
    1,908
    118
    60
    #15247 Windows 10 User, May 19, 2020
    Last edited: Jul 13, 2023
    Thanks. After removing Cortana with NTLite some items appeared with the wrong icons in the Start Menu search, and after typing some words, I got no results.
     
  8. marioalpha

    marioalpha MDL Novice

    Apr 26, 2017
    31
    7
    0
    if skipping the cleanup step i have no errors, this happened to me also with KB4549951

    So am I not the one who misses the steps?

    I kept doing it because I read many who succeed without problems, how is it possible?
     
  9. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    6,411
    15,487
    210
    In v2004 there are no two separate things like Cortana Component and Cortana App, only Cortana App is present.

    The ToolKitHelper method used for removing Cortana App needs further tweaking to fix the Start Menu search and that's why I did gave a temporary solution to use DISM's remove provisioned apps command to remove the Cortana App until a fix is implemented in ToolKitHelper.

     
  10. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    6,411
    15,487
    210
    May be the latest CU might have brought back the SFC bug again which the Microsoft had fixed earlier.

     
  11. Windows 10 User

    Windows 10 User MDL Expert

    Feb 2, 2017
    1,908
    118
    60
    #15251 Windows 10 User, May 19, 2020
    Last edited: Jun 8, 2020
    By using the DISM method to remove the Cortana app would it break the Start Menu search?
     
  12. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    6,411
    15,487
    210
    In W10 v2004 the Cortana UI and Search has been separated.

    The Search part is now a System App (Microsoft.Windows.Search_cw5n1h2txyewy) and is present in <Windows\SystemApps> folder.

    The Cortana App which is the Cortana UI is now normal Provisioned Appx Package (Microsoft.549981C3F5F10) and is present in <Program Files\WindowsApps> folder.

     
  13. raptorddd

    raptorddd MDL Addicted

    Aug 17, 2019
    617
    204
    30
    i been away for few months. i was getting power offs randomly i still need to send motherboard to warrantt. so i have no PC LOL. question does using toolkit now still reinstalls rwmoved apps when windows update is used.?
     
  14. Windows 10 User

    Windows 10 User MDL Expert

    Feb 2, 2017
    1,908
    118
    60
    #15254 Windows 10 User, May 19, 2020
    Last edited: Dec 3, 2022
    If they're separated in 2004, then why does removing Cortana break the Start Menu and the Settings app?
     
  15. ceo54

    ceo54 MDL Addicted

    Aug 13, 2015
    867
    361
    30

    Thanks MSMG. Just one question, how do I set the ISO label and filename on the fly like the toolkit does ?? The script already sets the two values and won't ask when it's run.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  16. almubdea1

    almubdea1 MDL Novice

    Apr 30, 2012
    24
    3
    0
    hi
    Iknow that you are doing great work spending a lot of your time
    if you can add with removing all accept so I can keep one of the list and remove the rest
    thanks to you
     
  17. You can remove apps of your choice via going to msmg project & edit removeappslist.txt in lists directory inside bin folder.
     
  18. inTerActionVRI

    inTerActionVRI MDL Expert

    Sep 23, 2009
    1,651
    3,398
    60
    Nice! I had registry entries being added also through scripts triggered by "setupcomplete.cmd". When I fixed everything, including the "*.reg" files, I got rid of the problem. In this case my problem was directly related to the commands for adding registry entries in my scripts.


    Good to know! Thanks!
     
  19. almubdea1

    almubdea1 MDL Novice

    Apr 30, 2012
    24
    3
    0
    thanks a lot

    can I ad version number of windows not include?
     
    There are only two ways you can remove all provisioned apps & some system apps from your offline wim :
    Via Dism - use only package name in remove apps list txt.
    Via Toolkit Helper - use ToolkitHelper : package name in remove apps list txt.
    Note Dont use both methods .
    You can use any of them to remove packages.