// Decompiled with JetBrains decompiler // Type: FiestaShark.MainForm // Assembly: FiestaShark, Version=2.3.0.0, Culture=neutral, PublicKeyToken=null // MVID: 12469781-3753-4869-9C1A-117F1862B52C // Assembly location: E:\Fiesta\Emus\DragonFiesta\Tools\FiestaShark-Farbod\FiestaShark.exe using FiestaShark.Properties; using PacketDotNet; using SharpPcap; using SharpPcap.LibPcap; using System; using System.Collections.Generic; using System.Collections.ObjectModel; using System.ComponentModel; using System.Drawing; using System.Drawing.Drawing2D; using System.IO; using System.Text.RegularExpressions; using System.Threading; using System.Windows.Forms; using WeifenLuo.WinFormsUI.Docking; namespace FiestaShark { public class MainForm : Form { private bool started = true; private SearchForm mSearchForm = new SearchForm(); private DataForm mDataForm = new DataForm(); private StructureForm mStructureForm = new StructureForm(); private PropertyForm mPropertyForm = new PropertyForm(); private List closes = new List(); private bool mClosed; private LibPcapLiveDevice mDevice; private string[] _startupArguments; private PcapDevice device; private IContainer components; private MenuStrip mMenu; private ToolStripMenuItem mFileMenu; private ToolStripMenuItem mFileImportMenu; private ToolStripMenuItem mFileOpenMenu; private System.Windows.Forms.Timer mTimer; private OpenFileDialog mImportDialog; private OpenFileDialog mOpenDialog; private DockPanel mDockPanel; private ToolStripMenuItem mViewMenu; private ToolStripMenuItem mViewPropertiesMenu; private ToolStripMenuItem mViewStructureMenu; private ToolStripSeparator mFileSeparatorMenu; private ToolStripMenuItem mFileQuit; private ToolStripMenuItem mViewDataMenu; private ToolStripMenuItem mViewSearchMenu; private ToolStrip toolStrip; private ToolStripButton openToolStripButton; private ToolStripButton saveToolStripButton; private ToolStripSeparator toolStripSeparator1; private ToolStripButton mStopStartButton; private ToolStripSeparator toolStripSeparator2; private ToolStripButton helpToolStripButton; private ToolStripMenuItem importJavapropertiesFileToolStripMenuItem; private ToolStripMenuItem setupToolStripMenuItem; private ToolStripSeparator toolStripSeparator4; private ToolStripMenuItem importMSnifferToolStripMenuItem; private ToolStripSeparator toolStripSeparator3; private ToolStripMenuItem creditsToolStripMenuItem; public MainForm(string[] startupArguments) { this.InitializeComponent(); this.Text = "FiestaShark " + Program.AssemblyVersion; this._startupArguments = startupArguments; try { Point windowLocation = Settings.Default.WindowLocation; this.Location = Settings.Default.WindowLocation; Size windowSize = Settings.Default.WindowSize; this.Size = Settings.Default.WindowSize; } catch (Exception ex) { } } public SearchForm SearchForm { get { return this.mSearchForm; } } public DataForm DataForm { get { return this.mDataForm; } } public StructureForm StructureForm { get { return this.mStructureForm; } } public PropertyForm PropertyForm { get { return this.mPropertyForm; } } private SessionForm NewSession() { return new SessionForm(); } public void CloseSession(SessionForm form) { this.mDockPanel.Contents.Remove((IDockContent) form); } public void CopyPacketHex(KeyEventArgs pArgs) { if (this.mDataForm.HexBox.SelectionLength > 0L && pArgs.Modifiers == Keys.Control && pArgs.KeyCode == Keys.C) { Clipboard.SetText(BitConverter.ToString((this.mDataForm.HexBox.ByteProvider as DynamicByteProvider).Bytes.ToArray(), (int) this.mDataForm.HexBox.SelectionStart, (int) this.mDataForm.HexBox.SelectionLength).Replace("-", " ")); pArgs.SuppressKeyPress = true; } else { if (this.mDataForm.HexBox.SelectionLength <= 0L || !pArgs.Control || (!pArgs.Shift || pArgs.KeyCode != Keys.C)) return; byte[] bs = new byte[this.mDataForm.HexBox.SelectionLength]; Buffer.BlockCopy((Array) (this.mDataForm.HexBox.ByteProvider as DynamicByteProvider).Bytes.ToArray(), (int) this.mDataForm.HexBox.SelectionStart, (Array) bs, 0, (int) this.mDataForm.HexBox.SelectionLength); this.mSearchForm.HexBox.ByteProvider.DeleteBytes(0L, this.mSearchForm.HexBox.ByteProvider.Length); this.mSearchForm.HexBox.ByteProvider.InsertBytes(0L, bs); pArgs.SuppressKeyPress = true; } } private DialogResult ShowSetupForm() { return new SetupForm().ShowDialog((IWin32Window) this); } private bool SetupAdapter() { if (this.mDevice != null) this.mDevice.Close(); foreach (LibPcapLiveDevice libPcapLiveDevice in (ReadOnlyCollection) LibPcapLiveDeviceList.Instance) { if (libPcapLiveDevice.Interface.FriendlyName == Config.Instance.Interface) { this.mDevice = libPcapLiveDevice; break; } } if (this.mDevice == null) { if (this.ShowSetupForm() != DialogResult.OK) { this.Close(); return false; } this.SetupAdapter(); } try { this.mDevice.Open(DeviceMode.Promiscuous, 1); } catch { int num = (int) MessageBox.Show("Failed to set the device in Promiscuous mode! But that doesn't really matter lol."); this.mDevice.Open(); } this.mDevice.Filter = string.Format("tcp portrange {0}-{1}", (object) Config.Instance.LowPort, (object) Config.Instance.HighPort); return true; } private void MainForm_Load(object pSender, EventArgs pArgs) { if (!Config.Instance.LoadedFromFile && this.ShowSetupForm() != DialogResult.OK) this.Close(); else if (!this.SetupAdapter()) { this.Close(); } else { this.mTimer.Enabled = true; this.mSearchForm.Show(this.mDockPanel); this.mDataForm.Show(this.mDockPanel); this.mStructureForm.Show(this.mDockPanel); this.mPropertyForm.Show(this.mDockPanel); DockPane dockPane1 = new DockPane((IDockContent) this.mStructureForm, DockState.DockRight, true); DockPane dockPane2 = new DockPane((IDockContent) this.mPropertyForm, DockState.DockRight, true); dockPane1.Show(); dockPane2.Show(); foreach (string startupArgument in this._startupArguments) { SessionForm sessionForm = this.NewSession(); sessionForm.OpenReadOnly(startupArgument); sessionForm.Show(this.mDockPanel, DockState.Document); } } } private void MainForm_FormClosed(object pSender, FormClosedEventArgs pArgs) { this.mTimer.Enabled = false; if (this.mDevice != null) this.mDevice.Close(); this.mClosed = true; } private void mDockPanel_ActiveDocumentChanged(object pSender, EventArgs pArgs) { if (this.mClosed) return; SessionForm activeDocument = this.mDockPanel.ActiveDocument as SessionForm; this.mSearchForm.ComboBox.Items.Clear(); if (activeDocument != null) { this.mSearchForm.RefreshOpcodes(false); activeDocument.ReselectPacket(); } else { if (this.mDataForm.HexBox.ByteProvider != null) this.mDataForm.HexBox.ByteProvider.DeleteBytes(0L, this.mDataForm.HexBox.ByteProvider.Length); this.mStructureForm.Tree.Nodes.Clear(); this.mPropertyForm.Properties.SelectedObject = (object) null; } } private void mFileImportMenu_Click(object pSender, EventArgs pArgs) { if (this.mImportDialog.ShowDialog((IWin32Window) this) != DialogResult.OK) return; this.device = (PcapDevice) new CaptureFileReaderDevice(this.mImportDialog.FileName); this.device.Open(); new Thread(new ThreadStart(this.ParseImportedFile)).Start(); } private void ParseImportedFile() { RawCapture packet = (RawCapture) null; SessionForm session = (SessionForm) null; this.Invoke((Delegate) (() => { while ((packet = this.device.GetNextPacket()) != null) { if (this.started) { TcpPacket pTCPPacket = (TcpPacket) Packet.ParsePacket(packet.LinkLayerType, packet.Data).Extract(typeof (TcpPacket)); if (pTCPPacket != null && ((int) pTCPPacket.SourcePort >= (int) Config.Instance.LowPort && (int) pTCPPacket.SourcePort <= (int) Config.Instance.HighPort || (int) pTCPPacket.DestinationPort >= (int) Config.Instance.LowPort && (int) pTCPPacket.DestinationPort <= (int) Config.Instance.HighPort)) { try { if (pTCPPacket.Syn && !pTCPPacket.Ack) { session?.Show(this.mDockPanel, DockState.Document); session = this.NewSession(); if (session.BufferTCPPacket(pTCPPacket, packet.Timeval.Date) != SessionForm.Results.Continue) ; } else if (session != null) { if (session.MatchTCPPacket(pTCPPacket)) { if (session.BufferTCPPacket(pTCPPacket, packet.Timeval.Date) == SessionForm.Results.CloseMe) session.Close(); } } } catch (Exception ex) { Console.WriteLine("Exception while parsing logfile: {0}", (object) ex); session.Close(); session = (SessionForm) null; } } } } session?.Show(this.mDockPanel, DockState.Document); if (session == null) return; this.mSearchForm.RefreshOpcodes(false); })); } private void mFileOpenMenu_Click(object pSender, EventArgs pArgs) { if (this.mOpenDialog.ShowDialog((IWin32Window) this) != DialogResult.OK) return; foreach (string fileName in this.mOpenDialog.FileNames) { SessionForm sessionForm = this.NewSession(); sessionForm.OpenReadOnly(fileName); sessionForm.Show(this.mDockPanel, DockState.Document); } this.mSearchForm.RefreshOpcodes(false); } private void mFileQuit_Click(object pSender, EventArgs pArgs) { this.Close(); } private void mViewMenu_DropDownOpening(object pSender, EventArgs pArgs) { this.mViewSearchMenu.Checked = this.mSearchForm.Visible; this.mViewDataMenu.Checked = this.mDataForm.Visible; this.mViewStructureMenu.Checked = this.mStructureForm.Visible; this.mViewPropertiesMenu.Checked = this.mPropertyForm.Visible; } private void mViewSearchMenu_CheckedChanged(object pSender, EventArgs pArgs) { if (this.mViewSearchMenu.Checked) this.mSearchForm.Show(); else this.mSearchForm.Hide(); } private void mViewDataMenu_CheckedChanged(object pSender, EventArgs pArgs) { if (this.mViewDataMenu.Checked) this.mDataForm.Show(); else this.mDataForm.Hide(); } private void mViewStructureMenu_CheckedChanged(object pSender, EventArgs pArgs) { if (this.mViewStructureMenu.Checked) this.mStructureForm.Show(); else this.mStructureForm.Hide(); } private void mViewPropertiesMenu_CheckedChanged(object pSender, EventArgs pArgs) { if (this.mViewPropertiesMenu.Checked) this.mPropertyForm.Show(); else this.mPropertyForm.Hide(); } private void mTimer_Tick(object sender, EventArgs e) { if (!this.started) return; try { this.mTimer.Enabled = false; DateTime now = DateTime.Now; foreach (SessionForm mdiChild in this.MdiChildren) { if (mdiChild.CloseMe(now)) this.closes.Add(mdiChild); } this.closes.ForEach((Action) (a => a.Close())); this.closes.Clear(); RawCapture nextPacket; while ((nextPacket = this.mDevice.GetNextPacket()) != null) { TcpPacket tcpPacket = (TcpPacket) Packet.ParsePacket(nextPacket.LinkLayerType, nextPacket.Data).Extract(typeof (TcpPacket)); sessionForm = (SessionForm) null; try { if (tcpPacket.Syn && !tcpPacket.Ack && ((int) tcpPacket.DestinationPort >= (int) Config.Instance.LowPort && (int) tcpPacket.DestinationPort <= (int) Config.Instance.HighPort)) { sessionForm = this.NewSession(); if (sessionForm.BufferTCPPacket(tcpPacket, nextPacket.Timeval.Date) == SessionForm.Results.Continue) sessionForm.Show(this.mDockPanel, DockState.Document); } else if (Array.Find
(this.MdiChildren, (Predicate) (f => (f as SessionForm).MatchTCPPacket(tcpPacket))) is SessionForm sessionForm) { if (sessionForm.BufferTCPPacket(tcpPacket, nextPacket.Timeval.Date) == SessionForm.Results.CloseMe) sessionForm.Close(); } } catch (Exception ex) { Console.WriteLine(ex.ToString()); sessionForm.Close(); } } this.mTimer.Enabled = true; } catch (Exception ex) { if (this.mDevice.Opened) return; this.mDevice.Open(DeviceMode.Promiscuous, 1); } } private void toolStripButton1_Click(object sender, EventArgs e) { if (this.started) { this.started = false; this.mStopStartButton.Image = (Image) FiestaShark.Properties.Resources.Button_Blank_Green_icon; this.mStopStartButton.Text = "Resume"; } else { this.started = true; this.mStopStartButton.Image = (Image) FiestaShark.Properties.Resources.Button_Blank_Red_icon; this.mStopStartButton.Text = "Pause"; } } private void helpToolStripButton_Click(object sender, EventArgs e) { OutputForm outputForm = new OutputForm("Script Help"); string pOutput = FiestaShark.Properties.Resources.Readme.Replace("\n", Environment.NewLine); outputForm.Append(pOutput); outputForm.Show(this.mDockPanel, new Rectangle(this.Location, new Size(400, 400))); } private void saveToolStripButton_Click(object sender, EventArgs e) { if (!(this.mDockPanel.ActiveDocument is SessionForm activeDocument)) return; activeDocument.RunSaveCMD(); } private void importJavapropertiesFileToolStripMenuItem_Click(object sender, EventArgs e) { int num = (int) new frmImportProps().ShowDialog(); } private void MainForm_DragEnter(object sender, DragEventArgs e) { if (e.Data.GetDataPresent(DataFormats.FileDrop)) { string[] data = (string[]) e.Data.GetData(DataFormats.FileDrop); bool flag = false; foreach (string path in data) { string extension = Path.GetExtension(path); if (extension == ".msb" || extension == ".pcap" || extension == ".txt") flag = true; } e.Effect = flag ? DragDropEffects.Move : DragDropEffects.None; } else e.Effect = DragDropEffects.None; } private void MainForm_DragDrop(object sender, DragEventArgs e) { foreach (string str in (string[]) e.Data.GetData(DataFormats.FileDrop)) { if (File.Exists(str)) { string extension = Path.GetExtension(str); if (!(extension == ".msb")) { if (!(extension == ".pcap")) { if (extension == ".txt") this.ReadMSnifferFile(str); } else { this.device = (PcapDevice) new CaptureFileReaderDevice(str); this.device.Open(); this.ParseImportedFile(); } } else { SessionForm sessionForm = this.NewSession(); sessionForm.OpenReadOnly(str); sessionForm.Show(this.mDockPanel, DockState.Document); this.mSearchForm.RefreshOpcodes(false); } } } } private void MainForm_FormClosing(object sender, FormClosingEventArgs e) { List sessionFormList = new List(); foreach (IDockContent content in (ReadOnlyCollection) this.mDockPanel.Contents) { if (content is SessionForm) sessionFormList.Add(content as SessionForm); } int count = sessionFormList.Count; bool flag = true; if (count > 5) flag = MessageBox.Show("You've got " + (object) count + " sessions open. Say 'Yes' if you want to get a question for each session, 'No' if you want to quit FiestaShark.", "FiestaShark", MessageBoxButtons.YesNo) == DialogResult.Yes; while (flag && sessionFormList.Count > 0) { SessionForm sessionForm = sessionFormList[0]; if (!sessionForm.Saved) { sessionForm.Focus(); switch (MessageBox.Show(string.Format("Do you want to save the session '{0}'?", (object) sessionForm.Text), "FiestaShark", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Exclamation)) { case DialogResult.Cancel: e.Cancel = true; return; case DialogResult.Yes: sessionForm.RunSaveCMD(); break; } } this.mDockPanel.Contents.Remove((IDockContent) sessionForm); sessionFormList.Remove(sessionForm); } DefinitionsContainer.Instance.Save(); Settings.Default.WindowLocation = this.Location; Settings.Default.WindowSize = this.WindowState != FormWindowState.Normal ? this.RestoreBounds.Size : this.Size; Settings.Default.Save(); } private void setupToolStripMenuItem_Click(object sender, EventArgs e) { if (this.ShowSetupForm() != DialogResult.OK) return; bool enabled = this.mTimer.Enabled; if (enabled) this.mTimer.Enabled = false; this.SetupAdapter(); if (!enabled) return; this.mTimer.Enabled = true; } private void importMSnifferToolStripMenuItem_Click(object sender, EventArgs e) { OpenFileDialog openFileDialog = new OpenFileDialog(); openFileDialog.Title = "Select MSniffer logfile"; openFileDialog.Filter = "All files|*.*"; if (openFileDialog.ShowDialog() != DialogResult.OK) return; this.ReadMSnifferFile(openFileDialog.FileName); } private void ReadMSnifferFile(string filename) { SessionForm sessionForm = (SessionForm) null; Regex regex = new Regex("Capturing MapleStory version (\\d+) on ([0-9\\.]+):(\\d+) with unknown \"(.*)\".*"); using (StreamReader streamReader = new StreamReader(filename)) { while (!streamReader.EndOfStream) { string str = streamReader.ReadLine(); if (!(str == "") && (str[0] == '[' || str[0] == 'C')) { if (str[0] == 'C') { Match match = regex.Match(str); if (match.Captures.Count != 0) { Console.WriteLine("Version: {0}.{1} IP {2} Port {3}", new object[4] { (object) match.Groups[1].Value, (object) match.Groups[4].Value, (object) match.Groups[2].Value, (object) match.Groups[3].Value }); sessionForm?.Show(this.mDockPanel, DockState.Document); sessionForm = this.NewSession(); sessionForm.SetConnectionInfo(match.Groups[2].Value, ushort.Parse(match.Groups[3].Value)); } } else if (str[0] == '[' && sessionForm != null) sessionForm.ParseMSnifferLine(str); } } } sessionForm?.Show(this.mDockPanel, DockState.Document); } private void creditsToolStripMenuItem_Click(object sender, EventArgs e) { int num = (int) MessageBox.Show("MapleShark was modified by MrFarbodD to work with Fiesta Online.", "About", MessageBoxButtons.OK, MessageBoxIcon.Asterisk); } protected override void Dispose(bool disposing) { if (disposing && this.components != null) this.components.Dispose(); base.Dispose(disposing); } private void InitializeComponent() { this.components = (IContainer) new Container(); ComponentResourceManager componentResourceManager = new ComponentResourceManager(typeof (MainForm)); DockPanelSkin dockPanelSkin = new DockPanelSkin(); AutoHideStripSkin autoHideStripSkin = new AutoHideStripSkin(); DockPanelGradient dockPanelGradient1 = new DockPanelGradient(); TabGradient tabGradient1 = new TabGradient(); DockPaneStripSkin dockPaneStripSkin = new DockPaneStripSkin(); DockPaneStripGradient paneStripGradient = new DockPaneStripGradient(); TabGradient tabGradient2 = new TabGradient(); DockPanelGradient dockPanelGradient2 = new DockPanelGradient(); TabGradient tabGradient3 = new TabGradient(); DockPaneStripToolWindowGradient toolWindowGradient = new DockPaneStripToolWindowGradient(); TabGradient tabGradient4 = new TabGradient(); TabGradient tabGradient5 = new TabGradient(); DockPanelGradient dockPanelGradient3 = new DockPanelGradient(); TabGradient tabGradient6 = new TabGradient(); TabGradient tabGradient7 = new TabGradient(); this.mMenu = new MenuStrip(); this.mFileMenu = new ToolStripMenuItem(); this.mFileOpenMenu = new ToolStripMenuItem(); this.toolStripSeparator3 = new ToolStripSeparator(); this.mFileImportMenu = new ToolStripMenuItem(); this.importJavapropertiesFileToolStripMenuItem = new ToolStripMenuItem(); this.importMSnifferToolStripMenuItem = new ToolStripMenuItem(); this.toolStripSeparator4 = new ToolStripSeparator(); this.setupToolStripMenuItem = new ToolStripMenuItem(); this.mFileSeparatorMenu = new ToolStripSeparator(); this.creditsToolStripMenuItem = new ToolStripMenuItem(); this.mFileQuit = new ToolStripMenuItem(); this.mViewMenu = new ToolStripMenuItem(); this.mViewSearchMenu = new ToolStripMenuItem(); this.mViewDataMenu = new ToolStripMenuItem(); this.mViewStructureMenu = new ToolStripMenuItem(); this.mViewPropertiesMenu = new ToolStripMenuItem(); this.mTimer = new System.Windows.Forms.Timer(this.components); this.mImportDialog = new OpenFileDialog(); this.mOpenDialog = new OpenFileDialog(); this.toolStrip = new ToolStrip(); this.openToolStripButton = new ToolStripButton(); this.saveToolStripButton = new ToolStripButton(); this.toolStripSeparator1 = new ToolStripSeparator(); this.mStopStartButton = new ToolStripButton(); this.toolStripSeparator2 = new ToolStripSeparator(); this.helpToolStripButton = new ToolStripButton(); this.mDockPanel = new DockPanel(); this.mMenu.SuspendLayout(); this.toolStrip.SuspendLayout(); this.SuspendLayout(); this.mMenu.ImageScalingSize = new Size(24, 24); this.mMenu.Items.AddRange(new ToolStripItem[2] { (ToolStripItem) this.mFileMenu, (ToolStripItem) this.mViewMenu }); this.mMenu.Location = new Point(0, 0); this.mMenu.Name = "mMenu"; this.mMenu.Padding = new Padding(9, 3, 0, 3); this.mMenu.Size = new Size(1578, 35); this.mMenu.TabIndex = 1; this.mFileMenu.DropDownItems.AddRange(new ToolStripItem[10] { (ToolStripItem) this.mFileOpenMenu, (ToolStripItem) this.toolStripSeparator3, (ToolStripItem) this.mFileImportMenu, (ToolStripItem) this.importJavapropertiesFileToolStripMenuItem, (ToolStripItem) this.importMSnifferToolStripMenuItem, (ToolStripItem) this.toolStripSeparator4, (ToolStripItem) this.setupToolStripMenuItem, (ToolStripItem) this.mFileSeparatorMenu, (ToolStripItem) this.creditsToolStripMenuItem, (ToolStripItem) this.mFileQuit }); this.mFileMenu.Name = "mFileMenu"; this.mFileMenu.Size = new Size(50, 29); this.mFileMenu.Text = "&File"; this.mFileOpenMenu.Name = "mFileOpenMenu"; this.mFileOpenMenu.ShortcutKeys = Keys.O | Keys.Control; this.mFileOpenMenu.Size = new Size(261, 30); this.mFileOpenMenu.Text = "&Open"; this.mFileOpenMenu.Click += new EventHandler(this.mFileOpenMenu_Click); this.toolStripSeparator3.Name = "toolStripSeparator3"; this.toolStripSeparator3.Size = new Size(258, 6); this.mFileImportMenu.Name = "mFileImportMenu"; this.mFileImportMenu.Size = new Size(261, 30); this.mFileImportMenu.Text = "Import PCap File"; this.mFileImportMenu.Click += new EventHandler(this.mFileImportMenu_Click); this.importJavapropertiesFileToolStripMenuItem.Name = "importJavapropertiesFileToolStripMenuItem"; this.importJavapropertiesFileToolStripMenuItem.Size = new Size(261, 30); this.importJavapropertiesFileToolStripMenuItem.Text = "Import Property File"; this.importJavapropertiesFileToolStripMenuItem.Click += new EventHandler(this.importJavapropertiesFileToolStripMenuItem_Click); this.importMSnifferToolStripMenuItem.Name = "importMSnifferToolStripMenuItem"; this.importMSnifferToolStripMenuItem.Size = new Size(261, 30); this.importMSnifferToolStripMenuItem.Text = "Import Sniffer logfile"; this.importMSnifferToolStripMenuItem.Visible = false; this.importMSnifferToolStripMenuItem.Click += new EventHandler(this.importMSnifferToolStripMenuItem_Click); this.toolStripSeparator4.Name = "toolStripSeparator4"; this.toolStripSeparator4.Size = new Size(258, 6); this.setupToolStripMenuItem.Name = "setupToolStripMenuItem"; this.setupToolStripMenuItem.Size = new Size(261, 30); this.setupToolStripMenuItem.Text = "Network Setup"; this.setupToolStripMenuItem.Click += new EventHandler(this.setupToolStripMenuItem_Click); this.mFileSeparatorMenu.Name = "mFileSeparatorMenu"; this.mFileSeparatorMenu.Size = new Size(258, 6); this.creditsToolStripMenuItem.Name = "creditsToolStripMenuItem"; this.creditsToolStripMenuItem.Size = new Size(261, 30); this.creditsToolStripMenuItem.Text = "About"; this.creditsToolStripMenuItem.Click += new EventHandler(this.creditsToolStripMenuItem_Click); this.mFileQuit.Name = "mFileQuit"; this.mFileQuit.ShortcutKeys = Keys.F4 | Keys.Alt; this.mFileQuit.Size = new Size(261, 30); this.mFileQuit.Text = "&Quit"; this.mFileQuit.Click += new EventHandler(this.mFileQuit_Click); this.mViewMenu.DropDownItems.AddRange(new ToolStripItem[4] { (ToolStripItem) this.mViewSearchMenu, (ToolStripItem) this.mViewDataMenu, (ToolStripItem) this.mViewStructureMenu, (ToolStripItem) this.mViewPropertiesMenu }); this.mViewMenu.Name = "mViewMenu"; this.mViewMenu.Size = new Size(61, 29); this.mViewMenu.Text = "&View"; this.mViewMenu.DropDownOpening += new EventHandler(this.mViewMenu_DropDownOpening); this.mViewSearchMenu.Checked = true; this.mViewSearchMenu.CheckOnClick = true; this.mViewSearchMenu.CheckState = CheckState.Checked; this.mViewSearchMenu.ImageScaling = ToolStripItemImageScaling.None; this.mViewSearchMenu.Name = "mViewSearchMenu"; this.mViewSearchMenu.ShortcutKeys = Keys.F9; this.mViewSearchMenu.Size = new Size(217, 30); this.mViewSearchMenu.Text = "Sea&rch"; this.mViewSearchMenu.CheckedChanged += new EventHandler(this.mViewSearchMenu_CheckedChanged); this.mViewDataMenu.Checked = true; this.mViewDataMenu.CheckOnClick = true; this.mViewDataMenu.CheckState = CheckState.Checked; this.mViewDataMenu.ImageScaling = ToolStripItemImageScaling.None; this.mViewDataMenu.Name = "mViewDataMenu"; this.mViewDataMenu.ShortcutKeys = Keys.F10; this.mViewDataMenu.Size = new Size(217, 30); this.mViewDataMenu.Text = "&Data"; this.mViewDataMenu.CheckedChanged += new EventHandler(this.mViewDataMenu_CheckedChanged); this.mViewStructureMenu.Checked = true; this.mViewStructureMenu.CheckOnClick = true; this.mViewStructureMenu.CheckState = CheckState.Checked; this.mViewStructureMenu.ImageScaling = ToolStripItemImageScaling.None; this.mViewStructureMenu.Name = "mViewStructureMenu"; this.mViewStructureMenu.ShortcutKeys = Keys.F11; this.mViewStructureMenu.Size = new Size(217, 30); this.mViewStructureMenu.Text = "&Structure"; this.mViewStructureMenu.CheckedChanged += new EventHandler(this.mViewStructureMenu_CheckedChanged); this.mViewPropertiesMenu.Checked = true; this.mViewPropertiesMenu.CheckOnClick = true; this.mViewPropertiesMenu.CheckState = CheckState.Checked; this.mViewPropertiesMenu.ImageScaling = ToolStripItemImageScaling.None; this.mViewPropertiesMenu.Name = "mViewPropertiesMenu"; this.mViewPropertiesMenu.ShortcutKeys = Keys.F12; this.mViewPropertiesMenu.Size = new Size(217, 30); this.mViewPropertiesMenu.Text = "&Properties"; this.mViewPropertiesMenu.CheckedChanged += new EventHandler(this.mViewPropertiesMenu_CheckedChanged); this.mTimer.Interval = 300; this.mTimer.Tick += new EventHandler(this.mTimer_Tick); this.mImportDialog.Filter = "PCap Files|*.pcap"; this.mImportDialog.ReadOnlyChecked = true; this.mImportDialog.RestoreDirectory = true; this.mImportDialog.Title = "Import"; this.mOpenDialog.Filter = "FietaShark Binary Files|*.fsb"; this.mOpenDialog.Multiselect = true; this.mOpenDialog.ReadOnlyChecked = true; this.mOpenDialog.RestoreDirectory = true; this.mOpenDialog.Title = "Open"; this.toolStrip.ImageScalingSize = new Size(24, 24); this.toolStrip.Items.AddRange(new ToolStripItem[6] { (ToolStripItem) this.openToolStripButton, (ToolStripItem) this.saveToolStripButton, (ToolStripItem) this.toolStripSeparator1, (ToolStripItem) this.mStopStartButton, (ToolStripItem) this.toolStripSeparator2, (ToolStripItem) this.helpToolStripButton }); this.toolStrip.Location = new Point(0, 35); this.toolStrip.Name = "toolStrip"; this.toolStrip.Padding = new Padding(0, 0, 2, 0); this.toolStrip.Size = new Size(1578, 32); this.toolStrip.TabIndex = 11; this.toolStrip.Text = "ToolStrip"; this.openToolStripButton.DisplayStyle = ToolStripItemDisplayStyle.Image; this.openToolStripButton.Image = (Image) FiestaShark.Properties.Resources.folder_open_16x16; this.openToolStripButton.ImageScaling = ToolStripItemImageScaling.None; this.openToolStripButton.ImageTransparentColor = Color.Black; this.openToolStripButton.Name = "openToolStripButton"; this.openToolStripButton.Size = new Size(23, 29); this.openToolStripButton.Text = "Open"; this.openToolStripButton.Click += new EventHandler(this.mFileOpenMenu_Click); this.saveToolStripButton.DisplayStyle = ToolStripItemDisplayStyle.Image; this.saveToolStripButton.Image = (Image) FiestaShark.Properties.Resources.disk; this.saveToolStripButton.ImageScaling = ToolStripItemImageScaling.None; this.saveToolStripButton.ImageTransparentColor = Color.Black; this.saveToolStripButton.Name = "saveToolStripButton"; this.saveToolStripButton.Size = new Size(23, 29); this.saveToolStripButton.Text = "Save"; this.saveToolStripButton.Click += new EventHandler(this.saveToolStripButton_Click); this.toolStripSeparator1.Name = "toolStripSeparator1"; this.toolStripSeparator1.Size = new Size(6, 32); this.mStopStartButton.Image = (Image) FiestaShark.Properties.Resources.Button_Blank_Red_icon; this.mStopStartButton.ImageScaling = ToolStripItemImageScaling.None; this.mStopStartButton.ImageTransparentColor = Color.Magenta; this.mStopStartButton.Name = "mStopStartButton"; this.mStopStartButton.Size = new Size(77, 29); this.mStopStartButton.Text = "Pause"; this.mStopStartButton.Click += new EventHandler(this.toolStripButton1_Click); this.toolStripSeparator2.Name = "toolStripSeparator2"; this.toolStripSeparator2.Size = new Size(6, 32); this.helpToolStripButton.DisplayStyle = ToolStripItemDisplayStyle.Image; this.helpToolStripButton.Image = (Image) componentResourceManager.GetObject("helpToolStripButton.Image"); this.helpToolStripButton.ImageScaling = ToolStripItemImageScaling.None; this.helpToolStripButton.ImageTransparentColor = Color.Black; this.helpToolStripButton.Name = "helpToolStripButton"; this.helpToolStripButton.Size = new Size(23, 29); this.helpToolStripButton.Text = "Help"; this.helpToolStripButton.Click += new EventHandler(this.helpToolStripButton_Click); this.mDockPanel.ActiveAutoHideContent = (IDockContent) null; this.mDockPanel.Dock = DockStyle.Fill; this.mDockPanel.DockBackColor = SystemColors.ControlDark; this.mDockPanel.DockBottomPortion = 0.3; this.mDockPanel.DockLeftPortion = 0.3; this.mDockPanel.DockRightPortion = 0.3; this.mDockPanel.DockTopPortion = 75.0; this.mDockPanel.Location = new Point(0, 67); this.mDockPanel.Margin = new Padding(4, 5, 4, 5); this.mDockPanel.Name = "mDockPanel"; this.mDockPanel.Size = new Size(1578, 777); dockPanelGradient1.EndColor = SystemColors.ControlLight; dockPanelGradient1.StartColor = SystemColors.ControlLight; autoHideStripSkin.DockStripGradient = dockPanelGradient1; tabGradient1.EndColor = SystemColors.ControlLight; tabGradient1.StartColor = SystemColors.ControlLight; tabGradient1.TextColor = SystemColors.ControlDarkDark; autoHideStripSkin.TabGradient = tabGradient1; dockPanelSkin.AutoHideStripSkin = autoHideStripSkin; tabGradient2.EndColor = SystemColors.ControlLightLight; tabGradient2.StartColor = SystemColors.ControlLightLight; tabGradient2.TextColor = SystemColors.ControlText; paneStripGradient.ActiveTabGradient = tabGradient2; dockPanelGradient2.EndColor = SystemColors.Control; dockPanelGradient2.StartColor = SystemColors.Control; paneStripGradient.DockStripGradient = dockPanelGradient2; tabGradient3.EndColor = SystemColors.ControlLight; tabGradient3.StartColor = SystemColors.ControlLight; tabGradient3.TextColor = SystemColors.ControlText; paneStripGradient.InactiveTabGradient = tabGradient3; dockPaneStripSkin.DocumentGradient = paneStripGradient; tabGradient4.EndColor = SystemColors.ActiveCaption; tabGradient4.LinearGradientMode = LinearGradientMode.Vertical; tabGradient4.StartColor = SystemColors.GradientActiveCaption; tabGradient4.TextColor = SystemColors.ActiveCaptionText; toolWindowGradient.ActiveCaptionGradient = tabGradient4; tabGradient5.EndColor = SystemColors.Control; tabGradient5.StartColor = SystemColors.Control; tabGradient5.TextColor = SystemColors.ControlText; toolWindowGradient.ActiveTabGradient = tabGradient5; dockPanelGradient3.EndColor = SystemColors.Control; dockPanelGradient3.StartColor = SystemColors.Control; toolWindowGradient.DockStripGradient = dockPanelGradient3; tabGradient6.EndColor = SystemColors.GradientInactiveCaption; tabGradient6.LinearGradientMode = LinearGradientMode.Vertical; tabGradient6.StartColor = SystemColors.GradientInactiveCaption; tabGradient6.TextColor = SystemColors.ControlText; toolWindowGradient.InactiveCaptionGradient = tabGradient6; tabGradient7.EndColor = Color.Transparent; tabGradient7.StartColor = Color.Transparent; tabGradient7.TextColor = SystemColors.ControlDarkDark; toolWindowGradient.InactiveTabGradient = tabGradient7; dockPaneStripSkin.ToolWindowGradient = toolWindowGradient; dockPanelSkin.DockPaneStripSkin = dockPaneStripSkin; this.mDockPanel.Skin = dockPanelSkin; this.mDockPanel.TabIndex = 4; this.mDockPanel.ActiveDocumentChanged += new EventHandler(this.mDockPanel_ActiveDocumentChanged); this.AllowDrop = true; this.AutoScaleDimensions = new SizeF(9f, 20f); this.AutoScaleMode = AutoScaleMode.Font; this.ClientSize = new Size(1578, 844); this.Controls.Add((Control) this.mDockPanel); this.Controls.Add((Control) this.toolStrip); this.Controls.Add((Control) this.mMenu); this.DoubleBuffered = true; this.Icon = (Icon) componentResourceManager.GetObject("$this.Icon"); this.IsMdiContainer = true; this.MainMenuStrip = this.mMenu; this.Margin = new Padding(4, 5, 4, 5); this.Name = nameof (MainForm); this.StartPosition = FormStartPosition.CenterScreen; this.Text = "FiestaShark"; this.FormClosing += new FormClosingEventHandler(this.MainForm_FormClosing); this.FormClosed += new FormClosedEventHandler(this.MainForm_FormClosed); this.Load += new EventHandler(this.MainForm_Load); this.DragDrop += new DragEventHandler(this.MainForm_DragDrop); this.DragEnter += new DragEventHandler(this.MainForm_DragEnter); this.mMenu.ResumeLayout(false); this.mMenu.PerformLayout(); this.toolStrip.ResumeLayout(false); this.toolStrip.PerformLayout(); this.ResumeLayout(false); this.PerformLayout(); } } }