-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathMainForm.cs
75 lines (64 loc) · 1.67 KB
/
MainForm.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.Globalization;
using System.IO;
using System.Text.RegularExpressions;
using System.Windows.Forms;
namespace DeobHellper
{
public partial class MainForm : Form
{
public MainForm()
{
InitializeComponent();
}
void BtnBrowseAutoClick(object sender, EventArgs e)
{
using(OpenFileDialog of = new OpenFileDialog())
{
of.CheckFileExists = true;
of.Multiselect = false;
of.Filter = "AutoIt Sources Files|*.au3";
if(of.ShowDialog() == DialogResult.OK) {
txtFileAuto.Text = of.FileName;
}
}
}
void BtnBrowseTblAutoClick(object sender, EventArgs e)
{
using(OpenFileDialog of = new OpenFileDialog())
{
of.CheckFileExists = true;
of.Multiselect = false;
of.Filter = "TBL Files|*.tbl";
if(of.ShowDialog() == DialogResult.OK) {
txtFileTblAuto.Text = of.FileName;
}
}
}
void BtnAutoDeobClick(object sender, EventArgs e)
{
if(txtFileAuto.Text.ToLower().Contains("money")) {
this.Height = 237;
return;
}
try
{
string obf, tbl, deob;
obf = File.ReadAllText(txtFileAuto.Text);
tbl = File.ReadAllText(txtFileTblAuto.Text);
deob = AutoDeobfuscator.Deobfuscate(obf, tbl);
System.IO.File.WriteAllText(txtFileAuto.Text.Replace(".au3", "") + "_deob.au3", deob);
MessageBox.Show("Done!");
} catch (Exception ex) {
MessageBox.Show("Error: " + ex.Message, "Error!", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
void LblToyClick(object sender, EventArgs e)
{
Process.Start("https://www.youtube.com/watch?v=VSipiuRi7Do");
}
}
}