tranquilit / WAPT-archives

Archives of WAPT repository for reference
Other
30 stars 5 forks source link

Tweak wapt-get add-upgrade-shutdown command - Fixes #24 #26

Closed jf-guillou closed 7 years ago

jf-guillou commented 7 years ago

Fixed gPCMachineExtensionNames handler in add_shutdown_script()

Removed malformed array fixer, as it was based on wrong assumption that gPCMachineExtensionNames was a GUID pair list and could break working GPO. See https://technet.microsoft.com/en-us/library/cc978247.aspx

The format is: [{< GUID of client-side extension >}{< GUID of MMC extension >}{< GUID of second MMC extension if appropriate >}][repeat first section as appropriate].

Added array sorter, Windows assumes the list is sorted and won't process the group policy if not positioned properly. See https://social.msdn.microsoft.com/Forums/en-US/70264a14-579e-4064-887d-4d3743af9a29/msgpol-incorrect-description-for-gpcmachineextensionnames-and-maybe-gpcuserextensionnames

I had a discussion with Product Group and they confirmed that the CSE guids need to be in sorted order otherwise processing stops at the one that is out of sequence.

This may not be the perfect solution but it's working for me and is probably a good starting point.

htouvet commented 7 years ago

Thanks ;)