⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 db_select.pas

📁 sql inject HDSI3--delphi.rar
💻 PAS
字号:
unit db_select;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, ComCtrls,ThreadErrorDBSelect;

type
  TForm_db_select = class(TForm)
    suiListBox_dbnames: TListView;
    Button_db: TButton;
    Button_stop_DBSelect: TButton;
    Button_select: TButton;
    procedure Button_selectClick(Sender: TObject);
    procedure Button_dbClick(Sender: TObject);
    procedure Button_stop_DBSelectClick(Sender: TObject);
  private
    { Private declarations }
  public
    stop_DBSelect:Boolean;
    { Public declarations }
  end;

var
  Form_db_select: TForm_db_select;

implementation

uses Main_Unit,CJdatabase_unit;

{$R *.dfm}

procedure TForm_db_select.Button_selectClick(Sender: TObject);
begin
try
  if Form_main.suiEdit_power.Text<>'SA' then
  begin
    Application.MessageBox(pchar('不是SA权限,可能无法跨库'),pchar('提示'),mb_ok);
  end;
  if assigned(suiListBox_dbnames.Selected) then
    begin
        Form_main.suiEdit_dbname.Text:=suiListBox_dbnames.Selected.Caption;
    end;
    close;
  except
  end;
end;

procedure TForm_db_select.Button_dbClick(Sender: TObject);
var
  i:integer;
  str_url:string;
  count:integer;
begin

try
  stop_DBSelect:=false;
  //如果没有注入地址,退出
  if Form_main.suiComboBox2_url.Text='' then
    begin
      Application.MessageBox(pchar('注入地址不能为空,请添入注入地址'),pchar('警告'),mb_ok);
      exit;
    end;
  str_url:=trim(Form_main.suiComboBox2_url.Text);
   { if Main_unit.g_sContent ='' then
    begin
      Application.MessageBox(pchar('从注入地址不能获得有效的页面,无法猜解表的长度,退出'),pchar('提示'),mb_ok+mb_iconinformation);
      exit;
    end; }

    if CJdatabase_unit.IferrReport=false then
      begin
          //if Application.MessageBox(pchar('是否进行猜解数据库,这需要很长的时间?'),pchar('提示'),MB_YESNO)=IDYES then
          Form_main.executeDBSelect(str_url,Main_unit.g_sContent);
          exit;
      end;

    count:=GetDatabaseCount(str_url);
    {for i:=1 to count do
    begin
          if stop_DBSelect=true then
            exit;
         suiListBox_dbnames.Items.Add.Caption:=GetDatabaseName(str_url,i);
    end; }
    for i:=1 to count do
    begin
        if not assigned(main_unit.ThdErrorDBSelObj[i-1]) then
        begin
          main_unit.ThdErrorDBSelObj[i-1]:=TThreadErrorDBSelect.Create(true);
          main_unit.ThdErrorDBSelObj[i-1].FURL:=str_url;
          main_unit.ThdErrorDBSelObj[i-1].iTop:=i;
          main_unit.ThdErrorDBSelObj[i-1].Resume;
        end;
    end;

except
end;

end;

procedure TForm_db_select.Button_stop_DBSelectClick(Sender: TObject);
begin
    stop_DBSelect:=true;
end;

end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -