示例#1
0
文件: Wikto.cs 项目: liorvh/wikto
 private void CheckIfIShouldStartTheWizard(object sender, EventArgs e)
 {
     if (this.tabControl1.SelectedIndex == 6)
     {
         Wizard thewiz = new Wizard(this);
         this.tabControl1.SelectedIndex = 0;
         thewiz.ShowDialog();
         thewiz.Dispose();
         thewiz = null;
     }
 }
示例#2
0
文件: Wikto.cs 项目: liorvh/wikto
        private void frm_Wikto_Load(object sender, System.EventArgs e)
        {
            txtHeader.Text = "Accept: */*\r\nAccept-Language: en-us\r\nConnection: close\r\nUser-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)\r\nHost: localhost";
            btnStopGoole.Enabled = false;
            LoadConfigInitial();
            if (bl_ShowStart)
            {
                News thenews = new News(this);
                thenews.ShowDialog();
                thenews.Dispose();
                thenews = null;
            }
            LoadConfigInitial();
            if (bl_ShowStart)
                this.chk_ShowStart.Checked = true;
            else
                this.chk_ShowStart.Checked = false;
            if (bl_ShowStartWiz)
                this.chk_StartWiz.Checked = true;
            else
                this.chk_StartWiz.Checked = false;

            if (isFirstTimeRun && !bl_ShowStartWiz)
            {
                MessageBox.Show("This is either the first time Wikto is being run or your configuration file has been deleted or moved.\n\nThe default settings have been loaded.\n\nPlease check this configuration now.", "Wikto Configuration");
                String tmpPath = Application.ExecutablePath;
                String sbPath = "";
                String[] arrPath = tmpPath.Split('\\');
                int tmpi;
                for (tmpi = 0; tmpi < arrPath.Length - 1; tmpi++)
                {
                    if (sbPath.Length == 0)
                        sbPath = arrPath[tmpi];
                    else
                        sbPath = sbPath + "\\" + arrPath[tmpi];
                }
                txtDBlocationNikto.Text = sbPath + "\\databases\\nikto-scan_database.db";
                txtDBLocationGH.Text = sbPath + "\\database\\GHDB.xml";
                tabControl1.SelectedIndex = 5;
                tabControl1.TabPages[5].Refresh();
            }
            lbl_WiktoHome.Links.Add(0, lbl_WiktoHome.Text.Length, "http://www.sensepost.com/research/wikto");
            lbl_ResearchMail.Links.Add(0, lbl_ResearchMail.Text.Length, "mailto:[email protected]");
            lbl_About.Text = lbl_About.Text.Replace("?", Application.ProductVersion.ToString());
            if (bl_ShowStartWiz)
            {
                Wizard thewiz = new Wizard(this);
                this.tabControl1.SelectedIndex = 0;
                thewiz.ShowDialog();
                thewiz.Dispose();
                thewiz = null;
            }
            // We check to ensure that these things are populated...
            if (txtInDirs.Text.Length == 0) txtInDirs.Text = ReadBackEndFile("dirs");
            if (txtInFiles.Text.Length == 0) txtInFiles.Text = ReadBackEndFile("files");
            if (txtInFileTypes.Text.Length == 0) txtInFileTypes.Text = ReadBackEndFile("extensions");
        }