private void FillTable() { dataGridView1.ColumnCount = 11; dataGridView1.Columns[0].Name = "ProcName"; dataGridView1.Columns[1].Name = "PID"; dataGridView1.Columns[2].Name = "Description"; dataGridView1.Columns[3].Name = "Path"; dataGridView1.Columns[4].Name = "ParName"; dataGridView1.Columns[5].Name = "ParPID"; dataGridView1.Columns[6].Name = "Owner"; dataGridView1.Columns[7].Name = "SID"; dataGridView1.Columns[8].Name = "Arc-t"; dataGridView1.Columns[9].Name = "DEP"; dataGridView1.Columns[10].Name = "ASLR"; ListOfProcesses.Clear(); InfoOfProcesses.GetProccesses(); ListOfProcesses = InfoOfProcesses.ListOfProcesses; dataGridView1.Rows.Clear(); foreach (var proc in ListOfProcesses) { dataGridView1.Rows.Add(proc.ProcName, proc.PID, proc.Description, proc.Path, proc.ParName, proc.ParPID, proc.Owner, proc.SID, proc.Arch, proc.DEP, proc.ASLR); ListOfModules.Add(proc.Module); } }
private void button2_Click(object sender, EventArgs e) { if (textBox2.Text.Length != 0) { var id = Convert.ToInt32(textBox2.Text); var sel = comboBox1.SelectedIndex + 1; InfoOfProcesses.SetProcessIntegrityLevel(id, sel); } }
private void button3_Click(object sender, EventArgs e) { if (textBox1.Text.Length != 0) { var id = textBox1.Text; var sel = comboBox1.SelectedIndex + 1; InfoOfProcesses.SetFileIntegrityLevel(sel, id); var lvl = InfoOfProcesses.GetFileIntegrityLevel(id); label3.Visible = true; label3.Text = ShowIntegrity(lvl); } }
private void button2_Click(object sender, EventArgs e) { if (textBox1.Text.Length != 0) { var id = textBox1.Text; var lvl = InfoOfProcesses.GetFileIntegrityLevel(id); label3.Visible = true; label3.Text = ShowIntegrity(lvl); } else { MessageBox.Show("You must select path to file!!!\nIf you want to check file integrity level again, select him in Browse button."); } }
private void button1_Click(object sender, EventArgs e) { if (textBox2.Text.Length != 0) { var id = Convert.ToInt32(textBox2.Text); var lvl = InfoOfProcesses.GetProcessIntegrityLevel(id); label3.Visible = true; label3.Text = ShowIntegrity(lvl); } else { MessageBox.Show("You must select PID or Path to file!!!\nIf you want to check file integrity level again, select him in Browse button."); } //if (rbtn_file_int.Checked == true) }