ok(!ret&&error==ERROR_INSUFFICIENT_BUFFER,"GetTokenInformation(TokenPrivileges) should have failed with ERROR_INSUFFICIENT_BUFFER instead of %d\n",error);
ok(!ret&&error==ERROR_BAD_IMPERSONATION_LEVEL,"PrivilegeCheck for SecurityAnonymous token should have failed with ERROR_BAD_IMPERSONATION_LEVEL instead of %d\n",error);
}
CloseHandle(Token);
ret=ImpersonateSelf(SecurityIdentification);
ok(ret,"ImpersonateSelf(SecurityIdentification) failed with error %d\n",GetLastError());