3

The goal is to control the AppLocker by temporarily stopping the AppIDSvc (Application Identity) Windows service and then resuming its execution. The action is supposed to be performed from within another Windows service with elevated permissions under the SYSTEM user security context.

By default, the AppIDSvc service startup type is Manual (Trigger Start). It means that even if the service is stopped with ServiceController.Stop method or sc stop AppIDSvc command, it will be triggered and started again by any AppLocker event, e.g. an executable is launched.

Since it’s a protected service, calling ChangeServiceConfig WinAPI function or sc config AppIDSvc start= disabled to disable the service returns "Access Denied" error.

Attempting to kill the service process, even from within the SYSTEM user security context, also leads to "Access Denied".

The only method that worked for me was to change the registry value Start in HKLM\SYSTEM\CurrentControlSet\Services\AppIDSvc to 4 and then restart a computer. Unfortunately, this method is not suitable because of the computer restart.

There could also be the following solution based on AppLocker PowerShell cmdlets:
1) backup existing AppLocker rules;
2) import “Allow Everything to Everyone” rules with “overwrite existing” option;
3) recover existing ones after the operation.
It is proved to be working, but also not suitable: it will only substitute local GPO rules, Domain rules will not be overwritten, and the solution needs to work in Domain corporate networks.

Can anyone give advice? Also, the solution mustn't degrade native Windows security. At the same time, we can rely on the fact that customers are aware and, even more, they intend to pause the AppLocker for a certain amount of time.

Olexander Ivanitskyi
  • 2,202
  • 17
  • 32
  • It's not clear why you want to disable AppIDSvc or pause AppLocker? In any case, it will degrade the security of windows to some extent. – Drake Wu Dec 04 '19 at 03:19
  • Application Identity cannot be started under any conditions, if the following services are disabled, deleted or working improperly: AppID Driver, Cryptographic Services, Remote Procedure Call (RPC). – Drake Wu Dec 04 '19 at 05:15
  • @DrakeWu-MSFT The AppLocker is paused, so a user with elevated privileges can setup software, which he normally can't do due to the AppLocker block. File system watchers then watch for the installed executables and create/import appropriate exception rules to the AppLocker. After that, the AppLocker is back on again. – Olexander Ivanitskyi Dec 04 '19 at 11:46

0 Answers0