Microsoft.Identity.Client.Platforms.Features.DesktopOs.WindowsNativeMethods
namespace Microsoft.Identity.Client.Platforms.Features.DesktopOs
{
internal static class WindowsNativeMethods
{
public enum NetJoinStatus
{
NetSetupUnknownStatus,
NetSetupUnjoined,
NetSetupWorkgroupName,
NetSetupDomainName
}
public const int ErrorSuccess = 0;
public static extern uint GetCurrentProcessId();
public static extern uint GetWindowThreadProcessId(IntPtr hWnd, out uint lpdwProcessId);
public static string GetProcessorArchitecture();
public static extern bool GetUserNameEx(int nameFormat, StringBuilder userName, ref uint userNameSize);
public static extern int NetGetJoinInformation(string server, out IntPtr domain, out NetJoinStatus status);
public static extern int NetApiBufferFree(IntPtr Buffer);
public static extern IntPtr GetDesktopWindow();
public static extern IntPtr GetConsoleWindow();
}
}