コード例 #1
0
ファイル: MainForm.cs プロジェクト: SayHalou/ospy
        public MainForm()
        {
            InitializeComponent();

            config = ConfigManager.GetContext("MainForm");

            colorPool = new ColorPool();

            listener = new AgentListener();
            receivedHandler = new AgentListener.ElementsReceivedHandler(listener_ElementsReceived);
            listener.MessageElementsReceived += receivedHandler;
            stoppedHandler = new AgentListener.StoppedHandler(listener_Stopped);
            listener.Stopped += stoppedHandler;

            tblMessages = dataSet.Tables["messages"];

            debugForm = new DebugForm();
            injectForm = new InjectForm();
            swForm = new SoftwallForm();

            packetParser = new PacketParser(debugForm);
            packetParser.PacketDescriptionReceived += new PacketParser.PacketDescriptionReceivedHandler(packetParser_PacketDescriptionReceived);

            dumpDisplayMode = DisplayMode.HEX;

            findTypeComboBox.SelectedIndex = 0;

            ClearState();
            LoadSettings();
            ApplyFilters();
        }
コード例 #2
0
ファイル: MultiSessionView.cs プロジェクト: SayHalou/ospy
        //
        // API
        //

        public void Clear()
        {
            colorPool = new ColorPool();

            // The first color is white, skip it
            colorPool.GetColorForId("MultiSessionView1");

            DeleteSessions(sessions.ToArray());
        }