Display AppContainer integrity instead of Low integrity for Windows Store apps
@@ -3018,6 +3018,7 @@ NTSTATUS PhGetTokenIntegrityLevelRID(
ULONG subAuthoritiesCount;
ULONG subAuthority;
PWSTR integrityString;
+ BOOLEAN isAppContainer;
status = PhpQueryTokenVariableSize(TokenHandle, TokenIntegrityLevel, &mandatoryLabel);
@@ -3038,6 +3039,15 @@ NTSTATUS PhGetTokenIntegrityLevelRID(
PhFree(mandatoryLabel);
if (IntegrityString)
+ {
+ isAppContainer = FALSE;
+ PhGetTokenIsAppContainer(TokenHandle, &isAppContainer);
+
+ if (isAppContainer)
+ {
+ integrityString = L"AppContainer";
+ }
+ else
{
switch (subAuthority)
{
@@ -3066,6 +3076,7 @@ NTSTATUS PhGetTokenIntegrityLevelRID(
integrityString = L"Other";
break;
}
+ }
*IntegrityString = integrityString;
}
