bstjohn

Silent uninstall broken in Win10 -- need suggestions for workaround

14 posts in this topic

#1 ·  Posted (edited)

I'm running AutoIT v3.3.14.2 on Windows 10 ver 1511.  The September Cumulative Update from Microsoft has broken the way some third party credential providers work.  You can see more detail here:  https://www.novell.com/support/kb/doc.php?id=7018051

So I want to automatically and silently remove this update from all our machines.  In Windows 7 I could easily do it with this:

wusa.exe /uninstall /kb:3185614 /quiet

But apparently Microsoft has taken away the /quiet switch functionality in Windows 10.   wusa /? will show that the switch is there, but when trying to use it error 87 (invalid parameter) is returned.

So I relented on that point and decided to run wusa without the quiet switch.  It pops up a child window that prompts for confirmation before uninstalling the update.  Sounds like a perfect job for AutoIT, right?  Except I can't get the button to click, either using ControlClick or ControlSend or Send.  I can select it by sending the {Alt} key to it and it highlights.  But I just can't get it to accept the click or {Enter}.

I then tried using Powershell and DISM to remove the package, but this is a hotfix and doesn't have a package name, so I can't use dism /remove-package, either.

Does anybody have any other ideas how this can be done silently?

Edited by bstjohn

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

mine runs clean as you have posted.  Though I am not on 1511 (i am on 14931)

Can you verify that this behavior occurs with other KBs, while I confirm it on previous builds?

*just removed 3118281 from Win10 in the exact manner you have above, with no user interaction.

Have you ruled out the other scenarios on technet that throw 0x80070057 like services disabled or the source server issues here?

https://social.technet.microsoft.com/Forums/windows/en-US/90b1d1dd-3538-444d-9ad8-0f080211a268/solved-having-a-hard-time-with-getting-windows-update-to-work?forum=w7itprogeneral

Edited by iamtheky

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

whats the result of MicrosoftFixit50202?

Edited by iamtheky

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Share this post


Link to post
Share on other sites

I absolutely do not want to do that.  That's what started this whole mess.  You think you have automatic updates locked down and Microsoft finds some sneaky way to get one by and break things.

Our updates are only supposed to come from a WSUS server.  This one Microsoft was able to send directly to machines.  If I reset automatic update settings it will just pull the lid off Pandora's Box.

-Barry.

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

do you not have the update server blocked by firewall or GPO or other means?  Are your endpoints only a radio button away from running out to MS?  Resetting the entire stack should not be something to be afraid of.

ftr - i am enterprise security and have the same want for systems to only fetch from in house (we are SCCM on endpoints though), this solution would not circumvent any of those controls.

Edited by iamtheky

,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Share this post


Link to post
Share on other sites

Alright, just for the sake of argument I'll give this a shot.  Not until Monday, though.

-Barry.

Share this post


Link to post
Share on other sites

There were a couple of other suggestions in that link, it looked like one was a batch version of the tear down, so you could walk it yourself rather than trusting the FixIt.  I understand the aversion, and am not trying to be antagonistic, it just comes naturally. :)


,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

Windows 10 Pro 1511, wusa /? says :

wusa /uninstall /kb:<KB number> [/norestart | /warnrestart:<seconds> | /promptrestart | /forcerestart] [/log:<file name>]

No /quiet options when using /kb parameter... strange

Edited by jguinch

Share this post


Link to post
Share on other sites

probably not ideal, but can you call the one from the windows.old directory?


,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-.
|(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/
(_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_)
| | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) (
| | | | |)| | \ / | | | | | |)| | `--. | |) \ | |
`-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_|
'-' '-' (__) (__) (_) (__)

Share this post


Link to post
Share on other sites

#11 ·  Posted (edited)

For me, it's a from stratch install,  not an upgrade, so I can't.

I just tried to copy the wusa.exe file from a Windows 7 VM into my Windows 10 System32 directory (with a backup on the original one before, of course) : the command does nothing... (and anyway it's a bad idea)

I also tried with dism /online /get-packages, but the KB3185614 does not appear in the list (however, it appears in the updates list in the control panel)

Edited by jguinch

Share this post


Link to post
Share on other sites

@jguinch

Interesting.  I, too, am working with a fresh install (no upgrade from 7) but I see the /quiet switch.  See attached.

As for dism, you won't find it there because KB3185614 doesn't have a package name.

In powershell, it shows up under get-hotfix, but there's no corresponding command for removing a hotfix, only a package.  And you can't remove a package without the package name -- at least not that I've been able to find.

-Barry.

 

wusa.png

Share this post


Link to post
Share on other sites

#14 ·  Posted (edited)

OH!  Good catch!  The line above has it, but also lists <update>.  Not sure I get using /uninstall and update together.  Reading....  d'oh!  OK, update is what you'd be uninstalling.  I was looking at it as a verb.

-Barry.

Edited by bstjohn
clarity

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Similar Content

    • WoodGrain
      By WoodGrain
      Hi guys,
      This is probably an obvious one, but I really don't use this command at all so am hoping you can spot my mistake.
      I'm running a powershell script on a schedule with the following script in a function, the function is being called in a loop, but the console process is not closing in the background and I end up with a bunch of console windows running in the background:
      Run(@comspec & ' /k PowerShell.exe -STA -NonInteractive -ExecutionPolicy ByPass -Command "& ''Z:\Powershell\365\GetNextDetails.ps1'' "', "", @SW_HIDE) Thanks!
    • caramen
      By caramen
      !Arf it i used [Start new topic] when i was in GUI section and the post was moved without i even noticed it. Can an admin move that to general (SORRY)!
       
      Hello guys ME again and my ugly english xD.
       
      This is the only one powershell command i am not able to use becose i dont found a way to insert the USERNAME $Variable at the first line. i am not able to find a third way to QUOTE a variable when i use "*" for the AutoIt command and the '*' for the PS command but i need to QUOTE inside the '*'PS command my $Variable
       
      $iPid = run("powershell get-aduser -Filter {sn -eq 'USERNAME'} -Properties sAMAccountName,Title" , @WindowsDir , @SW_HIDE , 0x2) $AllInfo = "" While 1 $AllInfo &= StdoutRead($iPID) If @error Then ExitLoop EndIf WEnd $AllInfo = stringsplit($AllInfo , @LF , 2) ;split result in all @LF but don't use the splitted result for anything _ArrayDisplay($AllInfo) This gonna be my last question becose i can do all the rest (i guess & wish ) alone
       
    • caramen
      By caramen
      Hello.
      I improved my powershell skill like F**** !! I am so happy Level skill under beginner HAHA well i am just getting what i want but now i got a question about autoit + powershell
      When i run that Shellcommand 
      $iPid = run("Powershell Get-ADUser USER -Properties * | select -Expand Title"  , @WindowsDir , @SW_HIDE , 0x2)
       
      The return valu is :
      Micro r,seau (this is normal in PowerShell)
      Can i transform the value
      Micro réseau with autoit 
    • profyt7
      By profyt7
      Hey Guys,
      I am almost there but feel I am missing something that is right in front of me and need another set of eyes.
       
      I am trying to run the following powershell file with the following parameters. This works in powershell just fine.
      Reset-LocalAdminPassword.ps1 -Password $secureString
       
      I created an autoit script to do a few other things but from venturing in the forums I found some code and did the following:
      ;THIS COMMAND WILL RUN THE powershell script
      $iDir = "C:\test\script\Reset-LocalAdminPassword.ps1"
      Run('cmd /k C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -File ' & '"' & $iDir & '-Password $secureString')
      Sleep(15000)
       
      The problem is that when it runs it gives me a message that C:\test\script\Reset-LocalAdminPassword.ps1-Password $secureString' is not a valid ps1 file.
      I cannot seem to get it to run the ps1 file with the -Password $secureString' parameter. It keeps cobining the ps1 path and the parameters all as one.
      I am sure this is something I am overlooking but I have been battling with this for a few hours now and just don't know what I am missing.
       
    • ur
      By ur
      I have a project in eclipse which is created using below options.
      File --> New --> Dynamic web application project..   I have linked the src folder to local GitHub synced folder.   Whenever there is a change in GitHub source files, I need to clean the project (only clean , not clean and build)   Once the clean is completed, I will export the complete project as war file (right click on project folder in eclipse and export --> war )   I didn't find any command line options to eclipse to do this. Any other alternative to automate this in AutoIT.