internal static System.ServiceModel.ComIntegration.LUID GetModifiedIDLUID(SafeCloseHandle token)
 {
     using (SafeHandle handle = GetTokenInformation(token, TOKEN_INFORMATION_CLASS.TokenStatistics))
     {
         TOKEN_STATISTICS token_statistics = (TOKEN_STATISTICS)Marshal.PtrToStructure(handle.DangerousGetHandle(), typeof(TOKEN_STATISTICS));
         return(token_statistics.ModifiedId);
     }
 }
 internal static LUID GetModifiedIDLUID(SafeCloseHandle token)
 {
     using (SafeHandle buffer =
                GetTokenInformation(token, TOKEN_INFORMATION_CLASS.TokenStatistics))
     {
         TOKEN_STATISTICS tokenStats = (TOKEN_STATISTICS)
                                       Marshal.PtrToStructure(buffer.DangerousGetHandle(), typeof(TOKEN_STATISTICS));
         return(tokenStats.ModifiedId);
     }
 }