示例#1
0
        // Token: 0x06000015 RID: 21 RVA: 0x0000282C File Offset: 0x00000A2C
        public static List <RemoteProcess> ListOfProcesses()
        {
            List <RemoteProcess> list = new List <RemoteProcess>();

            try
            {
                foreach (Process process in Process.GetProcesses())
                {
                    try
                    {
                        RemoteProcess remoteProcess = new RemoteProcess
                        {
                            ProcessID          = process.Id,
                            ProcessCommandLine = ClientInfoHelper.GetCommandLine(process),
                            ProcessName        = new FileInfo(process.MainModule.FileName).Name
                        };
                        string str;
                        string str2;
                        ClientInfoHelper.ReciveOwner(process.Id, out str, out str2);
                        remoteProcess.ProcessUsername = str2 + "\\" + str;
                        list.Add(remoteProcess);
                    }
                    catch
                    {
                    }
                }
            }
            catch
            {
            }
            return(list);
        }