11
Programación / Programación General / [Delphi] DH Downloader 2.0
en: 28 Octubre 2016, 22:21 pm
Un Downloader hecho en Delphi.
Tiene las siguientes opciones :
Principales : Mezclar una imagen con un malware y que la imagen resultante se vea bien Descargar manualmente o generar el stub para descargar la imagen infectada y ejecutar el malware Secundarias : [++] Ocultar rastros
[++] Persistencia
[++] UAC Tricky
[++] Extraccion de malware personalizado
[++] Editar la fecha de creacion del malware
[++] File Pumper
[++] Extension Spoofer
[++] Icon Changer
[++] Virtual PC
[++] Virtual Box
[++] Debug
[++] Wireshark
[++] OllyDg
[++] Anubis
[++] Kaspersky
[++] VMWare
[++] UAC
[++] Firewall
[++] CMD
[++] Run
[++] Taskmgr
[++] Regedit
[++] Updates
[++] MsConfig
Una imagen :
Un video con ejemplos de uso :
VIDEO Si quieren bajar el programa y el proyecto con el codigo fuente lo pueden hacer desde aca :
SourceForge .
Github .
Eso seria todo.
12
Programación / Programación General / [Delphi] DH Virus Maker 2.0
en: 18 Octubre 2016, 15:16 pm
Un generador de virus hecho en Delphi.
Tiene las siguientes opciones :
[++] Borrar archivos
[++] Matar procesos
[++] Ejecutar comandos
[++] Abrir CD
[++] Ocultar iconos y taskbar
[++] Messages Single & Bomber
[++] SendKeys
[++] Abrir word y escribir solo
[++] Crazy Mouse
[++] Crazy Hour
[++] Apagar,reiniciar y cerrar sesion
[++] Abrir URL
[++] Cargar Paint
[++] Cambiar texto del taskbar
[++] Apagar monitor
[++] Hacer que la computadora hable
[++] Beep Bomber
[++] Bloquear el teclado y el mouse
[++] Cambiar y bloquear el wallpaper
[++] Cambiar y bloquear el screensaver
[++] Printer Bomber
[++] Form Bomber
[++] HTML Bomber
[++] Windows Bomber
[++] Descargar y ejecutar malware con threads
[++] Activar Firewall
[++] Activar Regedit
[++] Activar UAC
[++] Activar CMD
[++] Activar Run
[++] Restaurar y desbloquear wallpaper o screensaver
[++] Activar Taskmgr
[++] Activar Updates
[++] Restaurar texto de taskbar
[++] Mostrar de nuevo iconos o taskbar
[++] Ocultar rastros
[++] Persistencia
[++] UAC Tricky
[++] Extraccion de malware personalizado
[++] Editar la fecha de creacion del malware
[++] File Pumper
[++] Extension Spoofer
[++] Icon Changer
[++] Virtual PC
[++] Virtual Box
[++] Debug
[++] Wireshark
[++] OllyDg
[++] Anubis
[++] Kaspersky
[++] VMWare
[++] UAC
[++] Firewall
[++] CMD
[++] Run
[++] Taskmgr
[++] Regedit
[++] Updates
[++] MsConfig
Unas imagen :
Un video con ejemplos de uso :
VIDEO Si quieren bajar el programa y el proyecto con el codigo fuente lo pueden hacer desde aca :
SourceForge .
Github .
Eso seria todo.
13
Programación / Programación General / [Delphi] Project Spartacus 2.0
en: 16 Octubre 2016, 14:32 pm
Una IRC Botnet hecha en Delphi.
Tiene las siguientes opciones :
[++] Conectar a cualquier servidor irc
[++] Permite servidor IRC secundario
[++] Establecer timeout por cada respuesta
[++] El infectado puede usar un nick configurado o la ip codificada
[++] Listar directorio
[++] Leer archivos
[++] Borrar archivos
[++] Listar procesos
[++] Matar procesos por nombre
[++] Ejecutar y leer comandos
[++] Activar y desactivar regedit
[++] Activar y desactivar firewall
[++] Abrir y cerrar CD
[++] Mostrar y ocultar iconos
[++] Mostrar y ocultar taskbar
[++] Mostrar mensajes
[++] Message Bomber
[++] Enviar teclas
[++] Ejecutar Word y hacer que escriba solo
[++] Volver loco al mouse
[++] Volver loca la hora
[++] Apagar,reiniciar y cerrar sesion
[++] Abrir paginas
[++] Abrir paint
[++] Cambiar el texto del taskbar
[++] Apagar el monitor
[++] Hacer hablar a la computadora
[++] Beeps Bomber
[++] Listar drives,servicios y ventanas activas
[++] Descargar y ejecutar en segundo plano con threads
[++] Cambiar y bloquear el wallpaper
[++] Cambiar y bloquear el screensaver
[++] Printer Bomber
[++] Form Bomber
[++] HTML Bomber
[++] Windows Bomber
[++] Bloquear el mouse y el teclado
[++] Keylogger
[++] Desintalador
[++] SQLI Dos
[++] HTTP Flood
[++] Socket Flood
[++] Slowloris
[++] UDP Flood
[++] Ocultar rastros
[++] Persistencia
[++] UAC Tricky
[++] Extraccion de malware personalizado
[++] Editar la fecha de creacion del malware
[++] File Pumper
[++] Extension Spoofer
[++] Icon Changer
[++] Virtual PC
[++] Virtual Box
[++] Debug
[++] Wireshark
[++] OllyDg
[++] Anubis
[++] Kaspersky
[++] VMWare
[++] UAC
[++] Firewall
[++] CMD
[++] Run
[++] Taskmgr
[++] Regedit
[++] Updates
[++] MsConfig
Unas imagenes :
Un video con ejemplos de uso :
VIDEO Si quieren bajar el programa y el proyecto con el codigo fuente lo pueden hacer desde aca :
SourceForge .
Github .
Eso seria todo.
MOD: Imagen adaptada a lo usado en el foro.
14
Programación / Programación General / [Delphi] DH Botnet 2.0
en: 14 Octubre 2016, 16:16 pm
Una Botnet hecha en Delphi.
Tiene las siguientes opciones :
[++] Generar Key por cada infectado
[++] Generar App en PHP de la botnet desde la GUI principal
[++] Listar directorio
[++] Leer archivos
[++] Borrar archivos
[++] Listar procesos
[++] Matar procesos por nombre
[++] Ejecutar y leer comandos
[++] Activar y desactivar regedit
[++] Activar y desactivar firewall
[++] Abrir y cerrar CD
[++] Mostrar y ocultar iconos
[++] Mostrar y ocultar taskbar
[++] Mostrar mensajes
[++] Message Bomber
[++] Enviar teclas
[++] Ejecutar Word y hacer que escriba solo
[++] Volver loco al mouse
[++] Volver loca la hora
[++] Apagar,reiniciar y cerrar sesion
[++] Abrir paginas
[++] Abrir paint
[++] Cambiar el texto del taskbar
[++] Apagar el monitor
[++] Hacer hablar a la computadora
[++] Beeps Bomber
[++] Listar drives,servicios y ventanas activas
[++] Descargar y ejecutar en segundo plano con threads
[++] Cambiar y bloquear el wallpaper
[++] Cambiar y bloquear el screensaver
[++] Printer Bomber
[++] Form Bomber
[++] HTML Bomber
[++] Windows Bomber
[++] Bloquear el mouse y el teclado
[++] Keylogger
[++] Desintalador
[++] SQLI Dos
[++] HTTP Flood
[++] Socket Flood
[++] Slowloris
[++] UDP Flood
[++] Ocultar rastros
[++] Persistencia
[++] UAC Tricky
[++] Extraccion de malware personalizado
[++] Editar la fecha de creacion del malware
[++] File Pumper
[++] Extension Spoofer
[++] Icon Changer
[++] Virtual PC
[++] Virtual Box
[++] Debug
[++] Wireshark
[++] OllyDg
[++] Anubis
[++] Kaspersky
[++] VMWare
[++] UAC
[++] Firewall
[++] CMD
[++] Run
[++] Taskmgr
[++] Regedit
[++] Updates
[++] MsConfig
Unas imagenes :
Un video con ejemplos de uso :
VIDEO Si quieren bajar el programa y el proyecto con el codigo fuente lo pueden hacer desde aca :
SourceForge .
Github .
Eso seria todo.
MOD: Imagen adaptada a lo permitido en el foro.
15
Programación / Programación General / [Delphi] DH Rat 2.0
en: 12 Octubre 2016, 21:07 pm
Un Rat hecho en Delphi.
Tiene las siguientes opciones :
[++] Conexion reversa
[++] Conexion codificada
[++] Listar directorio
[++] Leer archivos
[++] Borrar archivos
[++] Listar procesos
[++] Matar procesos por nombre
[++] Ejecutar y leer comandos
[++] Activar y desactivar regedit
[++] Activar y desactivar firewall
[++] Abrir y cerrar CD
[++] Mostrar y ocultar iconos
[++] Mostrar y ocultar taskbar
[++] Mostrar mensajes
[++] Message Bomber
[++] Enviar teclas
[++] Ejecutar Word y hacer que escriba solo
[++] Volver loco al mouse
[++] Volver loca la hora
[++] Apagar,reiniciar y cerrar sesion
[++] Abrir paginas
[++] Abrir paint
[++] Cambiar el texto del taskbar
[++] Apagar el monitor
[++] Hacer hablar a la computadora
[++] Beeps Bomber
[++] Listar drives,servicios y ventanas activas
[++] Descargar y ejecutar en segundo plano con threads
[++] Cambiar y bloquear el wallpaper
[++] Cambiar y bloquear el screensaver
[++] Printer Bomber
[++] Form Bomber
[++] HTML Bomber
[++] Windows Bomber
[++] Bloquear el mouse y el teclado
[++] Capturar la webcam de forma remota
[++] Capturar el escritorio de forma remota
[++] Keylogger
[++] Desintalador
[++] SQLI Dos
[++] HTTP Flood
[++] Socket Flood
[++] Slowloris
[++] UDP Flood
[++] Ocultar rastros
[++] Persistencia
[++] UAC Tricky
[++] Extraccion de malware personalizado
[++] Editar la fecha de creacion del malware
[++] File Pumper
[++] Extension Spoofer
[++] Icon Changer
[++] Virtual PC
[++] Virtual Box
[++] Debug
[++] Wireshark
[++] OllyDg
[++] Anubis
[++] Kaspersky
[++] VMWare
[++] UAC
[++] Firewall
[++] CMD
[++] Run
[++] Taskmgr
[++] Regedit
[++] Updates
[++] MsConfig
Una imagen :
Un video con ejemplos de uso :
VIDEO Si quieren bajar el programa y el proyecto con el codigo fuente lo pueden hacer desde aca :
SourceForge .
Github .
Eso seria todo.
16
Programación / Programación General / [Delphi] DH Auto Clicker 0.6
en: 2 Octubre 2016, 20:02 pm
Un programa en Delphi para usar un clicker automatico para juegos o lo que sea.
Opciones :
Capturar posicion del mouse para usar en el programa Timeout para cada click Teclas de acceso rapido para empezar y terminar el clicker Clicks en posiciones aleatorias Los Clicks que permite son izquierda,medio,derecha y doble click Una imagen :
El codigo :
// DH Auto Clicker 0.6
// (C) Doddy Hackman 2016
unit auto_clicker;
interface
uses
Winapi. Windows , Winapi. Messages , System. SysUtils , System. Variants ,
System. Classes , Vcl. Graphics ,
Vcl. Controls , Vcl. Forms , Vcl. Dialogs , Vcl. ExtCtrls , Vcl. StdCtrls ,
Vcl. ComCtrls , Math, Vcl. ImgList , Vcl. Imaging . pngimage ;
type
TFormHome = class ( TForm)
logo: TImage;
gbMousePosition: TGroupBox;
lblXPosition: TLabel;
txt_X_Now: TEdit;
lblYPosition: TLabel;
txt_Y_Now: TEdit;
gbOptions: TGroupBox;
lblType: TLabel;
cmbType: TComboBox;
lblSleep: TLabel;
txtSleep: TEdit;
lblXSelect: TLabel;
txt_X_Select: TEdit;
lblYSelect: TLabel;
txt_Y_Select: TEdit;
lblSeconds: TLabel;
btnGetPosition: TButton;
cbUseRandomClicks: TCheckBox;
btnStart: TButton;
btnStop: TButton;
status: TStatusBar;
tmGetMousePosition: TTimer;
tmClicker: TTimer;
notificar: TTrayIcon;
tmHookKeys: TTimer;
ilIconos: TImageList;
procedure tmGetMousePositionTimer( Sender: TObject ) ;
procedure btnGetPositionClick( Sender: TObject ) ;
procedure tmClickerTimer( Sender: TObject ) ;
procedure notificarClick( Sender: TObject ) ;
procedure tmHookKeysTimer( Sender: TObject ) ;
procedure btnStartClick( Sender: TObject ) ;
procedure btnStopClick( Sender: TObject ) ;
private
{ Private declarations }
public
procedure capturar_posicion_mouse( ) ;
procedure iniciar_clicker( ) ;
procedure desactivar_clicker( ) ;
end ;
var
FormHome: TFormHome;
implementation
{$R *.dfm}
function message_box( title, message_text, type_message: string ) : string ;
begin
if not ( title = '' ) and not ( message_text = '' ) and not ( type_message = '' ) then
begin
try
begin
if ( type_message = 'Information' ) then
begin
MessageBox( FormHome. Handle , PChar ( message_text) , PChar ( title) ,
MB_ICONINFORMATION) ;
end
else if ( type_message = 'Warning' ) then
begin
MessageBox( FormHome. Handle , PChar ( message_text) , PChar ( title) ,
MB_ICONWARNING) ;
end
else if ( type_message = 'Question' ) then
begin
MessageBox( FormHome. Handle , PChar ( message_text) , PChar ( title) ,
MB_ICONQUESTION) ;
end
else if ( type_message = 'Error' ) then
begin
MessageBox( FormHome. Handle , PChar ( message_text) , PChar ( title) ,
MB_ICONERROR) ;
end
else
begin
MessageBox( FormHome. Handle , PChar ( message_text) , PChar ( title) ,
MB_ICONINFORMATION) ;
end ;
Result : = '[+] MessageBox : OK' ;
end ;
except
begin
Result : = '[-] Error' ;
end ;
end ;
end
else
begin
Result : = '[-] Error' ;
end ;
end ;
procedure mouse_click( option: string ) ;
// Function based in : http://www.swissdelphicenter.ch/torry/showcode.php?id=360
// Thanks to Thomas Stutz
begin
if ( option = 'left' ) then
begin
mouse_event( MOUSEEVENTF_LEFTDOWN, 0 , 0 , 0 , 0 ) ;
mouse_event( MOUSEEVENTF_LEFTUP, 0 , 0 , 0 , 0 ) ;
end
else if ( option = 'right' ) then
begin
mouse_event( MOUSEEVENTF_RIGHTDOWN, 0 , 0 , 0 , 0 ) ;
mouse_event( MOUSEEVENTF_RIGHTUP, 0 , 0 , 0 , 0 ) ;
end
else if ( option = 'middle' ) then
begin
mouse_event( MOUSEEVENTF_MIDDLEDOWN, 0 , 0 , 0 , 0 ) ;
mouse_event( MOUSEEVENTF_MIDDLEUP, 0 , 0 , 0 , 0 ) ;
end
else if ( option = 'double' ) then
begin
mouse_event( MOUSEEVENTF_LEFTDOWN, 0 , 0 , 0 , 0 ) ;
mouse_event( MOUSEEVENTF_LEFTUP, 0 , 0 , 0 , 0 ) ;
GetDoubleClickTime;
mouse_event( MOUSEEVENTF_LEFTDOWN, 0 , 0 , 0 , 0 ) ;
mouse_event( MOUSEEVENTF_LEFTUP, 0 , 0 , 0 , 0 ) ;
end
else
begin
mouse_event( MOUSEEVENTF_LEFTDOWN, 0 , 0 , 0 , 0 ) ;
mouse_event( MOUSEEVENTF_LEFTUP, 0 , 0 , 0 , 0 ) ;
end ;
end ;
procedure TFormHome. iniciar_clicker ( ) ;
begin
if ( cmbType. ItemIndex <> - 1 ) and not ( txt_X_Select. Text = '' ) and
not ( txt_Y_Select. Text = '' ) and not ( txtSleep. Text = '' ) then
begin
tmClicker. Interval : = StrToInt ( txtSleep. Text ) * 1000 ;
tmClicker. Enabled : = True ;
status. Panels [ 0 ] . Text : = '[+] Working ...' ;
FormHome. Update ;
notificar. BalloonTitle : = 'DH Auto Clicker' ;
notificar. BalloonHint : = 'Clicker Started' ;
notificar. ShowBalloonHint ;
end
else
begin
message_box( 'DH Auto Clicker 0.6' , 'Complete the options' , 'Warning' ) ;
end ;
end ;
procedure TFormHome. desactivar_clicker ( ) ;
begin
tmClicker. Enabled : = False ;
status. Panels [ 0 ] . Text : = '[+] Stopped' ;
FormHome. Update ;
notificar. BalloonTitle : = 'DH Auto Clicker' ;
notificar. BalloonHint : = 'Clicker Stopped' ;
notificar. ShowBalloonHint ;
end ;
procedure TFormHome. btnStartClick ( Sender: TObject ) ;
begin
iniciar_clicker( ) ;
end ;
procedure TFormHome. btnStopClick ( Sender: TObject ) ;
begin
desactivar_clicker( ) ;
end ;
procedure TFormHome. capturar_posicion_mouse ( ) ;
begin
txt_X_Select. Text : = txt_X_Now. Text ;
txt_Y_Select. Text : = txt_Y_Now. Text ;
status. Panels [ 0 ] . Text : = '[+] Position updated' ;
FormHome. Update ;
notificar. BalloonTitle : = 'DH Auto Clicker' ;
notificar. BalloonHint : = 'Position updated' ;
notificar. ShowBalloonHint ;
end ;
procedure TFormHome. notificarClick ( Sender: TObject ) ;
begin
Show( ) ;
WindowState : = wsNormal;
Application. BringToFront ( ) ;
end ;
procedure TFormHome. btnGetPositionClick ( Sender: TObject ) ;
begin
capturar_posicion_mouse( ) ;
end ;
procedure TFormHome. tmGetMousePositionTimer ( Sender: TObject ) ;
var
ubicacion: tPoint;
begin
ubicacion : = Mouse. CursorPos ;
txt_X_Now. Text : = IntToStr ( ubicacion. X ) ;
txt_Y_Now. Text : = IntToStr ( ubicacion. Y ) ;
end ;
procedure TFormHome. tmHookKeysTimer ( Sender: TObject ) ;
var
i: integer ;
re: Longint ;
begin
for i : = 119 to 124 do
begin
re : = GetAsyncKeyState( i) ;
If re = - 32767 then
Begin
if ( i = 120 ) then
begin
capturar_posicion_mouse( ) ;
end
else if ( i = 122 ) then
begin
iniciar_clicker( ) ;
end
else if ( i = 123 ) then
begin
desactivar_clicker( ) ;
end
else
begin
// ?
end ;
End ;
End ;
end ;
procedure TFormHome. tmClickerTimer ( Sender: TObject ) ;
var
tipo: integer ;
nombre_tipo: string ;
X: integer ;
Y: integer ;
time_sleep: integer ;
begin
tipo : = cmbType. ItemIndex ;
nombre_tipo : = '' ;
if ( tipo = 0 ) then
begin
nombre_tipo : = 'left' ;
end
else if ( tipo = 1 ) then
begin
nombre_tipo : = 'middle' ;
end
else if ( tipo = 2 ) then
begin
nombre_tipo : = 'right' ;
end
else if ( tipo = 3 ) then
begin
nombre_tipo : = 'double' ;
end
else
begin
nombre_tipo : = 'left' ;
end ;
X : = 0 ;
Y : = 0 ;
if ( cbUseRandomClicks. Checked ) then
begin
X : = RandomRange ( 1 , 2000 ) ;
Y : = RandomRange ( 1 , 1000 ) ;
end
else
begin
X : = StrToInt ( txt_X_Select. Text ) ;
Y : = StrToInt ( txt_Y_Select. Text ) ;
end ;
time_sleep : = StrToInt ( txtSleep. Text ) * 1000 ;
SetCursorPos( X, Y) ;
mouse_click( nombre_tipo) ;
end ;
end .
// The End ?
Si quieren bajar el programa y el proyecto con el codigo fuente lo pueden hacer desde aca :
SourceForge .
Eso seria todo.
18
Programación / Programación General / [Delphi] DH Browser 1.0
en: 5 Septiembre 2016, 02:33 am
Un navegador web en Delphi con las siguientes opciones :
Podes ver el codigo fuente de la pagina cargado Se puede modificar los headers para HTTP Header Injection Se puede buscar palabras en el codigo fuente SQLI Scanner incorporado Admin Finder incorporado Crack MD5 incorporado Una imagen :
El codigo :
// DH Browser 1.0
// (C) Doddy Hackman 2016
// Credits :
// Navigate based on : http://www.swissdelphicenter.ch/torry/showcode.php?id=2242
// FindText based on : http://delphi.cjcsoft.net/viewthread.php?tid=47143
// Get HTML based on : http://delphi.about.com/od/adptips2005/qt/webbrowserhtml.htm
unit dh;
interface
uses
Winapi. Windows , Winapi. Messages , System. SysUtils , System. Variants ,
System. Classes , Vcl. Graphics ,
Vcl. Controls , Vcl. Forms , Vcl. Dialogs , Vcl. StdCtrls , Vcl. OleCtrls , SHDocVw,
Vcl. Imaging . pngimage , Vcl. ExtCtrls , Vcl. ComCtrls , mshtml, Vcl. Menus ,
IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient, IdHTTP, PerlRegEx,
IdMultipartFormData, Vcl. ImgList , Vcl. Styles . Utils . ComCtrls ,
Vcl. Styles . Utils . Menus ,
Vcl. Styles . Utils . SysStyleHook ,
Vcl. Styles . Utils . SysControls , Vcl. Styles . Utils . Forms ,
Vcl. Styles . Utils . StdCtrls , Vcl. Styles . Utils . ScreenTips ;
type
TFormHome = class ( TForm)
gbEnterPage: TGroupBox;
btnEnter: TButton;
gbHeaders: TGroupBox;
mmHeaders: TMemo;
GroupBox3: TGroupBox;
GroupBox4: TGroupBox;
gbAbout: TGroupBox;
txtURL: TEdit;
imgLogo: TImage;
imgAbout: TImage;
btnSQLI_Scanner: TButton;
btnAdminFinder: TButton;
btnCrack_MD5: TButton;
btnSearch_for_text: TButton;
cbUse_This_Headers: TCheckBox;
browser: TWebBrowser;
status: TStatusBar;
progreso: TProgressBar;
mmSource: TMemo;
menu: TPopupMenu;
ShowSourceHTML1: TMenuItem;
ShowBrowser1: TMenuItem;
nave: TIdHTTP;
buscar_codigo: TFindDialog;
ilIconos: TImageList;
lblAbout: TLabel;
procedure btnEnterClick( Sender: TObject ) ;
procedure browserDownloadComplete( Sender: TObject ) ;
procedure browserProgressChange( ASender: TObject ;
Progress, ProgressMax: Integer ) ;
procedure ShowSourceHTML1Click( Sender: TObject ) ;
procedure ShowBrowser1Click( Sender: TObject ) ;
procedure btnSQLI_ScannerClick( Sender: TObject ) ;
procedure btnAdminFinderClick( Sender: TObject ) ;
procedure btnCrack_MD5Click( Sender: TObject ) ;
procedure btnSearch_for_textClick( Sender: TObject ) ;
procedure buscar_codigoFind( Sender: TObject ) ;
procedure FormCreate( Sender: TObject ) ;
private
{ Private declarations }
public
{ Public declarations }
end ;
var
FormHome: TFormHome;
implementation
{$R *.dfm}
procedure TFormHome. btnAdminFinderClick ( Sender: TObject ) ;
const
paginas: array [ 1 .. 250 ] of string = ( 'admin/admin.asp' , 'admin/login.asp' ,
'admin/index.asp' , 'admin/admin.aspx' , 'admin/login.aspx' ,
'admin/index.aspx' , 'admin/webmaster.asp' , 'admin/webmaster.aspx' ,
'asp/admin/index.asp' , 'asp/admin/index.aspx' , 'asp/admin/admin.asp' ,
'asp/admin/admin.aspx' , 'asp/admin/webmaster.asp' ,
'asp/admin/webmaster.aspx' , 'admin/' , 'login.asp' , 'login.aspx' ,
'admin.asp' , 'admin.aspx' , 'webmaster.aspx' , 'webmaster.asp' ,
'login/index.asp' , 'login/index.aspx' , 'login/login.asp' ,
'login/login.aspx' , 'login/admin.asp' , 'login/admin.aspx' ,
'administracion/index.asp' , 'administracion/index.aspx' ,
'administracion/login.asp' , 'administracion/login.aspx' ,
'administracion/webmaster.asp' , 'administracion/webmaster.aspx' ,
'administracion/admin.asp' , 'administracion/admin.aspx' , 'php/admin/' ,
'admin/admin.php' , 'admin/index.php' , 'admin/login.php' , 'admin/system.php' ,
'admin/ingresar.php' , 'admin/administrador.php' , 'admin/default.php' ,
'administracion/' , 'administracion/index.php' , 'administracion/login.php' ,
'administracion/ingresar.php' , 'administracion/admin.php' ,
'administration/' , 'administration/index.php' , 'administration/login.php' ,
'administrator/index.php' , 'administrator/login.php' ,
'administrator/system.php' , 'system/' , 'system/login.php' , 'admin.php' ,
'login.php' , 'administrador.php' , 'administration.php' , 'administrator.php' ,
'admin1.html' , 'admin1.php' , 'admin2.php' , 'admin2.html' , 'yonetim.php' ,
'yonetim.html' , 'yonetici.php' , 'yonetici.html' , 'adm/' ,
'admin/account.php' , 'admin/account.html' , 'admin/index.html' ,
'admin/login.html' , 'admin/home.php' , 'admin/controlpanel.html' ,
'admin/controlpanel.php' , 'admin.html' , 'admin/cp.php' , 'admin/cp.html' ,
'cp.php' , 'cp.html' , 'administrator/' , 'administrator/index.html' ,
'administrator/login.html' , 'administrator/account.html' ,
'administrator/account.php' , 'administrator.html' , 'login.html' ,
'modelsearch/login.php' , 'moderator.php' , 'moderator.html' ,
'moderator/login.php' , 'moderator/login.html' , 'moderator/admin.php' ,
'moderator/admin.html' , 'moderator/' , 'account.php' , 'account.html' ,
'controlpanel/' , 'controlpanel.php' , 'controlpanel.html' ,
'admincontrol.php' , 'admincontrol.html' , 'adminpanel.php' ,
'adminpanel.html' , 'admin1.asp' , 'admin2.asp' , 'yonetim.asp' ,
'yonetici.asp' , 'admin/account.asp' , 'admin/home.asp' ,
'admin/controlpanel.asp' , 'admin/cp.asp' , 'cp.asp' ,
'administrator/index.asp' , 'administrator/login.asp' ,
'administrator/account.asp' , 'administrator.asp' , 'modelsearch/login.asp' ,
'moderator.asp' , 'moderator/login.asp' , 'moderator/admin.asp' ,
'account.asp' , 'controlpanel.asp' , 'admincontrol.asp' , 'adminpanel.asp' ,
'fileadmin/' , 'fileadmin.php' , 'fileadmin.asp' , 'fileadmin.html' ,
'administration.html' , 'sysadmin.php' , 'sysadmin.html' , 'phpmyadmin/' ,
'myadmin/' , 'sysadmin.asp' , 'sysadmin/' , 'ur-admin.asp' , 'ur-admin.php' ,
'ur-admin.html' , 'ur-admin/' , 'Server.php' , 'Server.html' , 'Server.asp' ,
'Server/' , 'wpadmin/' , 'administr8.php' , 'administr8.html' , 'administr8/' ,
'administr8.asp' , 'webadmin/' , 'webadmin.php' , 'webadmin.asp' ,
'webadmin.html' , 'administratie/' , 'admins/' , 'admins.php' , 'admins.asp' ,
'admins.html' , 'administrivia/' , 'Database_Administration/' , 'WebAdmin/' ,
'useradmin/' , 'sysadmins/' , 'admin1/' , 'systemadministration/' ,
'administrators/' , 'pgadmin/' , 'directadmin/' , 'staradmin/' ,
'ServerAdministrator/' , 'SysAdmin/' , 'administer/' , 'LiveUser_Admin/' ,
'sysadmin/' , 'typo3/' , 'panel/' , 'cpanel/' , 'cPanel/' , 'cpanel_file/' ,
'platz_login/' , 'rcLogin/' , 'blogindex/' , 'formslogin/' , 'autologin/' ,
'support_login/' , 'meta_login/' , 'manuallogin/' , 'simpleLogin/' ,
'loginflat/' , 'utility_login/' , 'showlogin/' , 'memlogin/' , 'members/' ,
'login-redirect/' , 'sublogin/' , 'wplogin/' , 'login1/' , 'dirlogin/' ,
'login_db/' , 'xlogin/' , 'smblogin/' , 'customer_login/' , 'UserLogin/' ,
'loginus/' , 'acct_login/' , 'admin_area/' , 'bigadmin/' , 'project-admins/' ,
'phppgadmin/' , 'pureadmin/' , 'sqladmin/' , 'radmind/' , 'openvpnadmin/' ,
'wizmysqladmin/' , 'vadmind/' , 'ezsqliteadmin/' , 'hpwebjetadmin/' ,
'newsadmin/' , 'adminpro/' , 'Lotus_Domino_Admin/' , 'bbadmin/' , 'vmailadmin/' ,
'Indy_admin/' , 'ccp14admin/' , 'irc-macadmin/' , 'banneradmin/' , 'sshadmin/' ,
'phpldapadmin/' , 'macadmin/' , 'administratoraccounts/' , 'admin4_account/' ,
'admin4_colon/' , 'radmind1/' , 'SuperAdmin/' , 'AdminTools/' , 'cmsadmin/' ,
'SysAdmin2/' , 'globes_admin/' , 'cadmins/' , 'phpSQLiteAdmin/' ,
'navSiteAdmin/' , 'server_admin_small/' , 'logo_sysadmin/' , 'server/' ,
'database_administration/' , 'power_user/' , 'system_administration/' ,
'ss_vms_admin_sm/' ) ;
var
i: Integer ;
control: Integer ;
var
cabeceras: OLEVariant;
uno: OLEVariant;
dos: OLEVariant;
tres: OLEVariant;
begin
if not ( txtURL. Text = '' ) then
begin
control : = 0 ;
status. Panels [ 0 ] . Text : = '[+] Finding Panel ....' ;
FormHome. status . Update ;
for i : = Low ( paginas) to High ( paginas) do
if ( control = 1 ) then
begin
Abort ;
end
else
begin
try
status. Panels [ 0 ] . Text : = '[+] Testing : ' + paginas[ i] ;
FormHome. status . Update ;
nave. Get ( txtURL. Text + '/' + paginas[ i] ) ;
if nave. ResponseCode = 200 then
begin
txtURL. Text : = txtURL. Text + '/' + paginas[ i] ;
uno : = navNoReadFromCache or navNoWriteToCache;
dos : = '' ;
tres : = '' ;
if ( cbUse_This_Headers. Checked ) then
begin
cabeceras : = mmHeaders. Text ;
browser. Navigate ( txtURL. Text , uno, dos, tres, cabeceras) ;
end
else
begin
cabeceras : = '' ;
browser. Navigate ( txtURL. Text , uno, dos, tres, cabeceras) ;
end ;
control : = 1 ;
status. Panels [ 0 ] . Text : = '[+] Panel Found' ;
FormHome. status . Update ;
MessageBox( 0 , 'Panel Found' , 'DH Browser 1.0' , MB_ICONINFORMATION) ;
Abort ;
end ;
except
on E: EIdHttpProtocolException do ;
on E: Exception do ;
end ;
end ;
status. Panels [ 0 ] . Text : = '[-] Panel not found' ;
FormHome. status . Update ;
MessageBox( 0 , 'Panel not found' , 'DH Browser 1.0' , MB_ICONERROR) ;
end
else
begin
MessageBox( 0 , 'Enter URL' , 'DH Browser 1.0' , MB_ICONINFORMATION) ;
end ;
end ;
procedure TFormHome. browserDownloadComplete ( Sender: TObject ) ;
var
buscador: IHTMLElement;
begin
progreso. Position : = 0 ;
status. Panels [ 0 ] . Text : = '[+] Page loaded' ;
FormHome. status . Update ;
// Get HTML based on : http://delphi.about.com/od/adptips2005/qt/webbrowserhtml.htm
begin
try
begin
mmSource. Clear ;
buscador : = ( browser. Document AS IHTMLDocument2) . body ;
while not ( buscador. parentElement = nil ) do
begin
buscador : = buscador. parentElement ;
end ;
mmSource. Lines . Add ( buscador. outerHTML ) ;
end ;
except
// ??
end ;
end ;
end ;
procedure TFormHome. browserProgressChange ( ASender: TObject ;
Progress, ProgressMax: Integer ) ;
begin
progreso. Max : = ProgressMax;
progreso. Position : = Progress;
end ;
procedure TFormHome. buscar_codigoFind ( Sender: TObject ) ;
// FindText based on : http://delphi.cjcsoft.net/viewthread.php?tid=47143
var
aca: PChar ;
aca2: PChar ;
acatoy: PChar ;
acatoy2: Word ;
begin
With Sender as TFindDialog do
begin
GetMem ( aca2, Length ( FindText) + 1 ) ;
StrPCopy ( aca2, FindText) ;
acatoy2 : = mmSource. GetTextLen + 1 ;
GetMem ( aca, acatoy2) ;
mmSource. GetTextBuf ( aca, acatoy2) ;
acatoy : = aca + mmSource. SelStart + mmSource. SelLength ;
acatoy : = StrPos ( acatoy, aca2) ;
if not ( acatoy = NIL ) then
begin
mmSource. SelStart : = acatoy - aca;
mmSource. SelLength : = Length ( FindText) ;
end ;
mmSource. SetFocus ;
end ;
end ;
procedure TFormHome. btnCrack_MD5Click ( Sender: TObject ) ;
var
md5: string ;
datos: TIdMultiPartFormDataStream;
code: string ;
regex_check: TPerlRegEx;
cracked: string ;
begin
md5 : = InputBox( 'DH Browser 1.0' , 'MD5 : ' , '' ) ;
if not ( md5 = '' ) then
begin
regex_check : = TPerlRegEx. Create ( ) ;
datos : = TIdMultiPartFormDataStream. Create ;
datos. AddFormField ( 'pass' , md5) ;
datos. AddFormField ( 'option' , 'hash2text' ) ;
datos. AddFormField ( 'send' , 'Submit' ) ;
status. Panels [ 0 ] . Text : = '[+] Cracking ...' ;
FormHome. status . Update ;
code : = nave. Post ( 'http://md5online.net/index.php' , datos) ;
regex_check. regex : =
'<center><p>md5 :<b>(.*?)</b> <br>pass : <b>(.*?)</b></p>' ;
regex_check. Subject : = code;
if regex_check. Match then
begin
cracked : = regex_check. Groups [ 2 ] ;
status. Panels [ 0 ] . Text : = '[+] MD5 Cracked : ' + cracked;
FormHome. status . Update ;
MessageBox( 0 , PChar ( 'MD5 Cracked : ' + cracked) , 'DH Browser 1.0' ,
MB_ICONINFORMATION) ;
end
else
begin
status. Panels [ 0 ] . Text : = '[-] Not found' ;
FormHome. status . Update ;
MessageBox( 0 , 'Not found' , 'DH Browser 1.0' , MB_ICONERROR) ;
end ;
end ;
end ;
procedure TFormHome. btnEnterClick ( Sender: TObject ) ;
// Navigate based on : http://www.swissdelphicenter.ch/torry/showcode.php?id=2242
var
cabeceras: OLEVariant;
uno: OLEVariant;
dos: OLEVariant;
tres: OLEVariant;
begin
uno : = navNoReadFromCache or navNoWriteToCache;
dos : = '' ;
tres : = '' ;
if ( cbUse_This_Headers. Checked ) then
begin
cabeceras : = mmHeaders. Text ;
browser. Navigate ( txtURL. Text , uno, dos, tres, cabeceras) ;
end
else
begin
cabeceras : = '' ;
browser. Navigate ( txtURL. Text , uno, dos, tres, cabeceras) ;
end ;
end ;
procedure TFormHome. FormCreate ( Sender: TObject ) ;
begin
UseLatestCommonDialogs : = False ;
end ;
procedure TFormHome. btnSearch_for_textClick ( Sender: TObject ) ;
begin
buscar_codigo. Execute ;
end ;
procedure TFormHome. ShowBrowser1Click ( Sender: TObject ) ;
begin
browser. Visible : = True ;
mmSource. Visible : = False ;
end ;
procedure TFormHome. ShowSourceHTML1Click ( Sender: TObject ) ;
begin
browser. Visible : = False ;
mmSource. Visible : = True ;
end ;
procedure TFormHome. btnSQLI_ScannerClick ( Sender: TObject ) ;
var
pass1: string ;
pass2: string ;
code: string ;
urltest: string ;
urlgen: string ;
full: string ;
codedos: string ;
i: Integer ;
regex_check: TPerlRegEx;
var
cabeceras: OLEVariant;
uno: OLEVariant;
dos: OLEVariant;
tres: OLEVariant;
begin
if not ( txtURL. Text = '' ) then
begin
regex_check : = TPerlRegEx. Create ( ) ;
status. Panels [ 0 ] . Text : = '[+] SQLI Scanning ...' ;
FormHome. status . Update ;
pass1 : = '+' ;
pass2 : = '--' ;
urltest : = 'concat(0x4b30425241,1,0x4b30425241)' ;
status. Panels [ 0 ] . Text : = '[+] Checking ...' ;
FormHome. status . Update ;
code : = nave. Get ( txtURL. Text + '1' + pass1 + 'and' + pass1 + '1=1' + pass2) ;
codedos : = nave. Get ( txtURL. Text + '1' + pass1 + 'and' + pass1 +
'1=0' + pass2) ;
if not ( code = codedos) then
begin
status. Panels [ 0 ] . Text : = '[+] Finding columns number' ;
FormHome. status . Update ;
urltest : = '1' + pass1 + 'and' + pass1 + '1=0' + pass1 + 'union' + pass1 +
'select' + pass1 + 'concat(0x4b30425241,1,0x4b30425241)' ;
urlgen : = '1' ;
for i : = 2 to 36 do
begin
status. Panels [ 0 ] . Text : = '[+] Columns Length : ' + IntToStr ( i) ;
FormHome. status . Update ;
urltest : = urltest + ',concat(0x4b30425241,' + IntToStr ( i) +
',0x4b30425241)' ;
urlgen : = urlgen + ',' + IntToStr ( i) ;
code : = nave. Get ( txtURL. Text + urltest + pass2) ;
regex_check. regex : = 'K0BRA(.*?)K0BRA' ;
regex_check. Subject : = code;
if regex_check. Match then
begin
urlgen : = StringReplace ( urlgen, regex_check. Groups [ 1 ] , 'hackman' , [ ] ) ;
full : = txtURL. Text + '1' + pass1 + 'and' + pass1 + '1=0' + pass1 +
'union' + pass1 + 'select' + pass1 + urlgen;
txtURL. Text : = full;
uno : = navNoReadFromCache or navNoWriteToCache;
dos : = '' ;
tres : = '' ;
if ( cbUse_This_Headers. Checked ) then
begin
cabeceras : = mmHeaders. Text ;
browser. Navigate ( txtURL. Text , uno, dos, tres, cabeceras) ;
end
else
begin
cabeceras : = '' ;
browser. Navigate ( txtURL. Text , uno, dos, tres, cabeceras) ;
end ;
status. Panels [ 0 ] . Text : = '[+] SQI Scanner Finished' ;
FormHome. status . Update ;
MessageBox( 0 , 'SQI Scanner Finished' , 'DH Browser 1.0' ,
MB_ICONINFORMATION) ;
Abort ;
end ;
end ;
status. Panels [ 0 ] . Text : = '[-] Columns length not found' ;
FormHome. status . Update ;
MessageBox( 0 , 'Columns length not found' , 'DH Browser 1.0' , MB_ICONERROR) ;
end
else
begin
status. Panels [ 0 ] . Text : = '[-] Not vulnerable' ;
FormHome. status . Update ;
MessageBox( 0 , 'Not vulnerable' , 'DH Browser 1.0' , MB_ICONERROR) ;
end ;
status. Panels [ 0 ] . Text : = '[+] Done' ;
FormHome. status . Update ;
end
else
begin
MessageBox( 0 , 'Enter URL' , 'DH Browser 1.0' , MB_ICONINFORMATION) ;
end ;
end ;
end .
// The End ?
Si quieren bajar el programa lo pueden hacer de aca :
SourceForge .
Github .
Eso seria todo.
19
Programación / Programación General / [Delphi] IRC Manager 0.3
en: 20 Agosto 2016, 00:29 am
Un simple cliente para chatear en el IRC.
Una imagen :
El codigo :
// IRC Manager 0.3
// (C) Doddy Hackman 2016
unit irc;
interface
uses
Winapi. Windows , Winapi. Messages , System. SysUtils , System. Variants ,
System. Classes , Vcl. Graphics ,
Vcl. Controls , Vcl. Forms , Vcl. Dialogs , Vcl. StdCtrls , Vcl. ComCtrls , Vcl. Menus ,
Vcl. Imaging . pngimage , Vcl. ExtCtrls , IdContext, IdBaseComponent, IdComponent,
IdTCPConnection, IdTCPClient, IdCmdTCPClient, IdIRC, PerlRegex, MMSystem,
Vcl. ImgList , Vcl. Styles . Utils . ComCtrls , Vcl. Styles . Utils . Menus ,
Vcl. Styles . Utils . SysStyleHook ,
Vcl. Styles . Utils . SysControls , Vcl. Styles . Utils . Forms ,
Vcl. Styles . Utils . StdCtrls , Vcl. Styles . Utils . ScreenTips ;
type
TFormHome = class ( TForm)
status: TStatusBar;
gbIRC_Config: TGroupBox;
lblHost: TLabel;
txtHost: TEdit;
lblPort: TLabel;
txtPort: TEdit;
lblChannel: TLabel;
txtChannel: TEdit;
lblNick: TLabel;
gbChat: TGroupBox;
gbNicks: TGroupBox;
lbNicks: TListBox;
txtNickname: TEdit;
btnConnect: TButton;
gbEnterText: TGroupBox;
txtText: TEdit;
btnSend: TButton;
logo: TImage;
mmChat: TRichEdit;
irc: TIdIRC;
ilIconos: TImageList;
procedure btnConnectClick( Sender: TObject ) ;
procedure ircRaw( ASender: TIdContext; AIn: Boolean ; const AMessage: string ) ;
procedure btnSendClick( Sender: TObject ) ;
procedure ircPrivateMessage( ASender: TIdContext;
const ANickname, AHost, ATarget, AMessage: string ) ;
procedure ircNotice( ASender: TIdContext; const ANickname, AHost, ATarget,
ANotice: string ) ;
procedure ircJoin( ASender: TIdContext;
const ANickname, AHost, AChannel: string ) ;
procedure ircPart( ASender: TIdContext; const ANickname, AHost, AChannel,
APartMessage: string ) ;
procedure ircQuit( ASender: TIdContext;
const ANickname, AHost, AReason: string ) ;
procedure FormClose( Sender: TObject ; var Action: TCloseAction) ;
procedure FormCreate( Sender: TObject ) ;
private
{ Private declarations }
public
{ Public declarations }
logs_messages: Boolean ;
end ;
var
FormHome: TFormHome;
implementation
{$R *.dfm}
procedure TFormHome. btnConnectClick ( Sender: TObject ) ;
begin
if ( btnConnect. Caption = 'Connect' ) then
begin
irc. nickname : = txtNickname. text ;
irc. AltNickname : = txtNickname. text + '123' ;
irc. Username : = txtNickname. text ;
irc. RealName : = txtNickname. text ;
irc. Password : = '' ;
irc. host : = txtHost. text ;
irc. port : = StrToInt ( txtPort. text ) ;
mmChat. Lines . Clear ;
lbNicks. Items . Clear ;
logs_messages : = False ;
try
begin
mmChat. Lines . Add ( 'Connecting ...' ) ;
irc. connect ;
irc. Join ( txtChannel. text ) ;
btnConnect. Caption : = 'Disconnect' ;
status. Panels [ 0 ] . text : = '[+] Connected' ;
FormHome. status . Update ;
mmChat. Lines . Add ( 'Connected !' ) ;
end ;
except
begin
status. Panels [ 0 ] . text : = '[-] Error connecting to server' ;
FormHome. status . Update ;
mmChat. Lines . Add ( 'Error connecting to server !' ) ;
MessageBox( 0 , 'Error connecting to server' , 'IRC Manager 1.0' ,
MB_ICONERROR) ;
end ;
end ;
end
else
begin
if ( btnConnect. Caption = 'Disconnect' ) then
begin
irc. Part ( '' ) ;
irc. Disconnect ( '' ) ;
btnConnect. Caption : = 'Connect' ;
status. Panels [ 0 ] . text : = '[+] Disconnected' ;
FormHome. status . Update ;
mmChat. Lines . Add ( 'Disconnected !' ) ;
end ;
end ;
end ;
procedure TFormHome. btnSendClick ( Sender: TObject ) ;
begin
if not ( txtText. text = '' ) then
begin
irc. Say ( txtChannel. text , txtText. text ) ;
mmChat. Lines . Add ( '<' + txtNickname. text + '> ' + txtText. text ) ;
txtText. text : = '' ;
end ;
end ;
procedure TFormHome. FormClose ( Sender: TObject ; var Action: TCloseAction) ;
begin
if mrYes = MessageDlg( 'Close program ?' , mtwarning, [ mbYes, mbNo] , 0 ) then
begin
Exit ;
end
else
begin
Action : = caNone;
end ;
end ;
procedure TFormHome. FormCreate ( Sender: TObject ) ;
begin
UseLatestCommonDialogs : = False ;
end ;
procedure TFormHome. ircJoin ( ASender: TIdContext;
const ANickname, AHost, AChannel: string ) ;
begin
lbNicks. Items . Add ( ANickname) ;
mmChat. Lines . Add ( ANickname + ' has joined' ) ;
end ;
procedure TFormHome. ircNotice ( ASender: TIdContext;
const ANickname, AHost, ATarget, ANotice: string ) ;
begin
// chat.Lines.Add('<' + ANickname + '> ' + ANotice);
end ;
procedure TFormHome. ircPart ( ASender: TIdContext;
const ANickname, AHost, AChannel, APartMessage: string ) ;
begin
lbNicks. Items . Delete ( lbNicks. Items . IndexOf ( ANickname) ) ;
mmChat. Lines . Add ( ANickname + ' part' ) ;
end ;
procedure TFormHome. ircPrivateMessage ( ASender: TIdContext;
const ANickname, AHost, ATarget, AMessage: string ) ;
var
check_regex: TPerlRegex;
begin
check_regex : = TPerlRegex. Create ( ) ;
check_regex. regex : = txtNickname. text ;
check_regex. Subject : = AMessage;
check_regex. Options : = [ preCaseLess] ;
if check_regex. Match then
begin
mmChat. SelAttributes . Color : = clRed;
mmChat. SelAttributes . Style : = [ fsBold] ;
mmChat. Lines . Add ( '* <' + ANickname + '> ' + AMessage) ;
sndPlaySound( Pchar ( GetCurrentDir + '/Data/click.wav' ) , SND_NODEFAULT) ;
end
else
begin
mmChat. Lines . Add ( '<' + ANickname + '> ' + AMessage) ;
end ;
check_regex. Free ;
end ;
procedure TFormHome. ircQuit ( ASender: TIdContext;
const ANickname, AHost, AReason: string ) ;
begin
lbNicks. Items . Delete ( lbNicks. Items . IndexOf ( ANickname) ) ;
mmChat. Lines . Add ( ANickname + ' quit' ) ;
end ;
procedure TFormHome. ircRaw ( ASender: TIdContext; AIn: Boolean ;
const AMessage: string ) ;
var
i: integer ;
code: string ;
renicks: string ;
listanow: TStringList;
regex: TPerlRegex;
otroregex: TPerlRegex;
nick: string ;
texto: string ;
begin
code : = AMessage;
if ( logs_messages = True ) then
begin
mmChat. Lines . Add ( code) ;
end ;
regex : = TPerlRegex. Create ( ) ;
otroregex : = TPerlRegex. Create ( ) ;
regex. regex : = '353 (.*) = #(.*) :(.*)' ;
regex. Subject : = code;
if regex. Match then
begin
lbNicks. Clear ;
renicks : = regex. Groups [ 3 ] ;
renicks : = StringReplace ( renicks, txtNickname. text , '' , [ ] ) ;
listanow : = TStringList. Create ;
listanow. Delimiter : = ' ' ;
listanow. DelimitedText : = renicks;
for i : = 0 to listanow. Count - 1 do
begin
if not ( listanow[ i] = '@' ) then
begin
lbNicks. Items . Add ( listanow[ i] ) ;
end ;
end ;
lbNicks. Items . Add ( txtNickname. text ) ;
logs_messages : = False ;
end ;
otroregex. regex : = 'PRIVMSG (.*) :ACTION (.*)' ;
otroregex. Subject : = code;
if otroregex. Match then
begin
nick : = otroregex. Groups [ 1 ] ;
texto : = otroregex. Groups [ 2 ] ;
mmChat. Lines . Add ( '* ' + texto) ;
end ;
regex. Free ;
otroregex. Free ;
end ;
end .
// The End ?
Si quieren bajar el programa lo pueden hacer de
aca .
20
Programación / Programación General / [Delphi] FTP Manager 1.0
en: 6 Agosto 2016, 04:01 am
Un cliente FTP en Delphi con las siguientes opciones :
Se puede conectar a cualquier servidor FTP Navegar y listar los directorios de nuestra computadora Navegar y listar los directorios del servidor FTP Se puede crear,renombrar,eliminar archivos y directorios de nuestra computadora Se puede crear,renombrar,eliminar archivos y directorios del servidor FTP Se puede bajar y subir archivos del servidor FTP comodamente Una imagen :
El codigo :
// FTP Manager 1.0
// (C) Doddy Hackman 2016
unit ftp;
interface
uses
Winapi. Windows , Winapi. Messages , System. SysUtils , System. Variants ,
System. Classes , Vcl. Graphics ,
Vcl. Controls , Vcl. Forms , Vcl. Dialogs , Vcl. StdCtrls , Vcl. ComCtrls ,
IdBaseComponent, IdComponent, IdTCPConnection, IdTCPClient,
IdExplicitTLSClientServerBase, IdFTP, Shellapi, Vcl. ImgList , IdFTPList,
Vcl. Imaging . pngimage , Vcl. ExtCtrls , Vcl. Menus , Vcl. Styles . Utils . ComCtrls ,
Vcl. Styles . Utils . Menus ,
Vcl. Styles . Utils . SysStyleHook ,
Vcl. Styles . Utils . SysControls , Vcl. Styles . Utils . Forms ,
Vcl. Styles . Utils . StdCtrls , Vcl. Styles . Utils . ScreenTips ;
type
TFormHome = class ( TForm)
gbFTP_Data: TGroupBox;
lblHost: TLabel;
txtHost: TEdit;
lblUsername: TLabel;
txtUsername: TEdit;
lblPassword: TLabel;
txtPassword: TEdit;
btnConnect: TButton;
gbMyFiles: TGroupBox;
lblDirectory1: TLabel;
txtMe_Directory: TEdit;
btnListMe: TButton;
lvLocalFiles: TListView;
gbFTP_Files: TGroupBox;
lblDirectory2: TLabel;
txt_FTP_Directory: TEdit;
btnList_FTP: TButton;
lv_FTP_Files: TListView;
btnUpload: TButton;
btnDownload: TButton;
directorios: TListBox;
archivos: TListBox;
status: TStatusBar;
local_iconos: TImageList;
ftp_client: TIdFTP;
ftp_iconos: TImageList;
progreso: TProgressBar;
imgLogo: TImage;
menu_local: TPopupMenu;
MakeDirectory1: TMenuItem;
Rename1: TMenuItem;
Delete1: TMenuItem;
Refresh1: TMenuItem;
menu_ftp: TPopupMenu;
MakeDirectory2: TMenuItem;
Rename2: TMenuItem;
Delete2: TMenuItem;
Refresh2: TMenuItem;
ilIconos: TImageList;
procedure btnConnectClick( Sender: TObject ) ;
procedure btnListMeClick( Sender: TObject ) ;
procedure btnList_FTPClick( Sender: TObject ) ;
procedure btnUploadClick( Sender: TObject ) ;
procedure ftp_clientWork( ASender: TObject ; AWorkMode: TWorkMode;
AWorkCount: Int64 ) ;
procedure ftp_clientWorkBegin( ASender: TObject ; AWorkMode: TWorkMode;
AWorkCountMax: Int64 ) ;
procedure ftp_clientWorkEnd( ASender: TObject ; AWorkMode: TWorkMode) ;
procedure btnDownloadClick( Sender: TObject ) ;
procedure lvLocalFilesDblClick( Sender: TObject ) ;
procedure lv_FTP_FilesDblClick( Sender: TObject ) ;
procedure MakeDirectory1Click( Sender: TObject ) ;
procedure Rename1Click( Sender: TObject ) ;
procedure Delete1Click( Sender: TObject ) ;
procedure Refresh1Click( Sender: TObject ) ;
procedure FormCreate( Sender: TObject ) ;
procedure MakeDirectory2Click( Sender: TObject ) ;
procedure Rename2Click( Sender: TObject ) ;
procedure Delete2Click( Sender: TObject ) ;
procedure Refresh2Click( Sender: TObject ) ;
private
{ Private declarations }
public
{ Public declarations }
end ;
var
FormHome: TFormHome;
implementation
{$R *.dfm}
procedure listar( dirnownow: string ; ListaDeArchivos: TListView;
ListaDeIconos: TImageList) ;
var
buscar: TSearchRec;
Icon: TIcon;
listate: TListItem;
getdata: SHFILEINFO;
dirnow: string ;
begin
if ( DirectoryExists ( dirnownow) ) then
begin
ListaDeIconos. Clear ;
dirnow : = StringReplace ( dirnownow, '/' , '\' , [ rfReplaceAll, rfIgnoreCase] ) ;
ListaDeArchivos. Items . Clear ;
Icon : = TIcon. Create ;
ListaDeArchivos. Items . BeginUpdate ;
if FindFirst ( dirnow + '*.*' , faAnyFile, buscar) = 0 then
begin
repeat
if ( buscar. Attr = faDirectory) then
begin
with ListaDeArchivos do
begin
if not ( buscar. Name = '.' ) and not ( buscar. Name = '..' ) then
begin
listate : = ListaDeArchivos. Items . Add ;
SHGetFileInfo( PChar ( dirnow + buscar. Name ) , 0 , getdata,
SizeOf ( getdata) , SHGFI_DISPLAYNAME) ;
listate. Caption : = getdata. szDisplayName ;
SHGetFileInfo( PChar ( dirnow + buscar. Name ) , 0 , getdata,
SizeOf ( getdata) , SHGFI_TYPENAME) ;
listate. SubItems . Add ( getdata. szTypeName ) ;
SHGetFileInfo( PChar ( dirnow + buscar. Name ) , 0 , getdata,
SizeOf ( getdata) , SHGFI_ICON or SHGFI_SMALLICON) ;
Icon. Handle : = getdata. hIcon ;
listate. ImageIndex : = ListaDeIconos. AddIcon ( Icon) ;
DestroyIcon( getdata. hIcon ) ;
end ;
end ;
end ;
until FindNext ( buscar) <> 0 ;
FindClose ( buscar) ;
end ;
if FindFirst ( dirnow + '*.*' , faAnyFile, buscar) = 0 then
begin
repeat
if ( buscar. Attr <> faDirectory) then
begin
with ListaDeArchivos do
begin
listate : = ListaDeArchivos. Items . Add ;
SHGetFileInfo( PChar ( dirnow + buscar. Name ) , 0 , getdata,
SizeOf ( getdata) , SHGFI_DISPLAYNAME) ;
listate. Caption : = buscar. Name ;
SHGetFileInfo( PChar ( dirnow + buscar. Name ) , 0 , getdata,
SizeOf ( getdata) , SHGFI_TYPENAME) ;
listate. SubItems . Add ( getdata. szTypeName ) ;
SHGetFileInfo( PChar ( dirnow + buscar. Name ) , 0 , getdata,
SizeOf ( getdata) , SHGFI_ICON or SHGFI_SMALLICON) ;
Icon. Handle : = getdata. hIcon ;
listate. ImageIndex : = ListaDeIconos. AddIcon ( Icon) ;
DestroyIcon( getdata. hIcon ) ;
end ;
end
until FindNext ( buscar) <> 0 ;
FindClose ( buscar) ;
end ;
ListaDeArchivos. Items . EndUpdate ;
end ;
end ;
procedure listarftp( dirnownow2: string ; ListaDeArchivosFTP: TListView;
ftp: TIdFTP; DirectoriosEncontrados: TListBox;
ArchivosEncontrados: TListBox) ;
var
i: integer ;
Item: TIdFTPListItem;
listate2: TListItem;
begin
ListaDeArchivosFTP. Items . Clear ;
DirectoriosEncontrados. Clear ;
ArchivosEncontrados. Clear ;
listate2 : = ListaDeArchivosFTP. Items . Add ;
ftp. ChangeDir ( dirnownow2) ;
ftp. List ( '*.*' , True ) ;
for i : = 0 to ftp. DirectoryListing . Count - 1 do
begin
Item : = ftp. DirectoryListing . Items [ i] ;
if Item. ItemType = ditFile then
begin
DirectoriosEncontrados. Items . Add ( ftp. DirectoryListing . Items [ i]
. FileName ) ;
end
else
begin
ArchivosEncontrados. Items . Add ( ftp. DirectoryListing . Items [ i] . FileName ) ;
end ;
end ;
ListaDeArchivosFTP. Items . Clear ;
for i : = 0 to ArchivosEncontrados. Count - 1 do
begin
with ListaDeArchivosFTP do
begin
listate2 : = ListaDeArchivosFTP. Items . Add ;
listate2. Caption : = ArchivosEncontrados. Items [ i] ;
listate2. SubItems . Add ( 'Directory' ) ;
listate2. ImageIndex : = 0 ;
end ;
end ;
for i : = 0 to DirectoriosEncontrados. Count - 1 do
begin
with ListaDeArchivosFTP do
begin
listate2 : = ListaDeArchivosFTP. Items . Add ;
listate2. Caption : = DirectoriosEncontrados. Items [ i] ;
listate2. SubItems . Add ( 'File' ) ;
listate2. ImageIndex : = 1 ;
end ;
end ;
end ;
procedure TFormHome. btnConnectClick ( Sender: TObject ) ;
begin
lv_FTP_Files. Items . Clear ;
directorios. Clear ;
archivos. Clear ;
if ( btnConnect. Caption = 'Disconnect' ) then
begin
ftp_client. Disconnect ;
btnConnect. Caption : = 'Connect' ;
status. Panels [ 0 ] . Text : = '[+] Disconnected' ;
FormHome. status . Update ;
txt_FTP_Directory. Text : = '' ;
MessageBox( 0 , 'Disconnected' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end
else
begin
ftp_client. host : = txtHost. Text ;
ftp_client. username : = txtUsername. Text ;
ftp_client. password : = txtPassword. Text ;
try
ftp_client. connect ;
btnConnect. Caption : = 'Disconnect' ;
status. Panels [ 0 ] . Text : = '[+] Connected' ;
FormHome. status . Update ;
txt_FTP_Directory. Text : = '/' ;
listarftp( txt_FTP_Directory. Text , lv_FTP_Files, ftp_client, directorios,
archivos) ;
MessageBox( 0 , 'Connected' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
except
status. Panels [ 0 ] . Text : = '[-] Error connecting to server' ;
FormHome. status . Update ;
MessageBox( 0 , 'Error connecting to server' , 'FTP Manager 1.0' ,
MB_ICONERROR) ;
end ;
end ;
end ;
procedure TFormHome. Delete1Click ( Sender: TObject ) ;
var
archivo: string ;
begin
if Assigned ( lvLocalFiles. Selected ) then
begin
archivo : = lvLocalFiles. Selected . Caption ;
if DeleteFile ( txtMe_Directory. Text + '/' + archivo) then
begin
if not ( txtMe_Directory. Text = '' ) then
begin
listar( txtMe_Directory. Text , lvLocalFiles, local_iconos) ;
end ;
MessageBox( 0 , 'Deleted' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end
else
begin
MessageBox( 0 , 'Error' , 'FTP Manager 1.0' , MB_ICONERROR) ;
end ;
end ;
end ;
procedure TFormHome. Delete2Click ( Sender: TObject ) ;
var
archivo: string ;
begin
if Assigned ( lv_FTP_Files. Selected ) then
begin
archivo : = lv_FTP_Files. Selected . Caption ;
ftp_client. ChangeDir ( txt_FTP_Directory. Text ) ;
try
begin
ftp_client. Delete ( archivo) ;
if not ( txt_FTP_Directory. Text = '' ) then
begin
listarftp( txt_FTP_Directory. Text , lv_FTP_Files, ftp_client,
directorios, archivos) ;
end ;
MessageBox( 0 , 'Deleted' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end ;
except
MessageBox( 0 , 'Error' , 'FTP Manager 1.0' , MB_ICONERROR) ;
end ;
end ;
end ;
procedure TFormHome. btnDownloadClick ( Sender: TObject ) ;
var
fileabajar: string ;
begin
if Assigned ( lv_FTP_Files. Selected ) then
begin
try
begin
fileabajar : = lv_FTP_Files. Selected . Caption ;;
ftp_client. OnWork : = ftp_clientWork;
ftp_client. ChangeDir ( txt_FTP_Directory. Text ) ;
progreso. Max : = ftp_client. Size ( ExtractFileName ( fileabajar) ) div 1024 ;
ftp_client. Get ( fileabajar, txtMe_Directory. Text + '/' + fileabajar,
False , False ) ;
if not ( txtMe_Directory. Text = '' ) then
begin
listar( txtMe_Directory. Text , lvLocalFiles, local_iconos) ;
end ;
MessageBox( 0 , 'Action completed successfully' , 'FTP Manager 1.0' ,
MB_ICONINFORMATION) ;
end ;
except
MessageBox( 0 , 'Error' , 'FTP Manager 1.0' , MB_ICONERROR) ;
end ;
end
else
begin
MessageBox( 0 , 'Select File to download' , 'FTP Manager 1.0' ,
MB_ICONINFORMATION) ;
end ;
end ;
procedure TFormHome. FormCreate ( Sender: TObject ) ;
begin
UseLatestCommonDialogs : = False ;
txtMe_Directory. Text : = GetCurrentDir + '\' ;
listar( txtMe_Directory. Text , lvLocalFiles, local_iconos) ;
end ;
procedure TFormHome. ftp_clientWork ( ASender: TObject ; AWorkMode: TWorkMode;
AWorkCount: Int64 ) ;
begin
status. Panels [ 0 ] . Text : = '[+] Working ...' ;
FormHome. status . Update ;
progreso. Position : = AWorkCount div 1024 ;
end ;
procedure TFormHome. ftp_clientWorkBegin ( ASender: TObject ;
AWorkMode: TWorkMode; AWorkCountMax: Int64 ) ;
begin
status. Panels [ 0 ] . Text : = '[+] Working ..' ;
FormHome. status . Update ;
end ;
procedure TFormHome. ftp_clientWorkEnd ( ASender: TObject ; AWorkMode: TWorkMode) ;
begin
status. Panels [ 0 ] . Text : = '[+] Finished' ;
FormHome. status . Update ;
progreso. Max : = 0 ;
end ;
procedure TFormHome. lv_FTP_FilesDblClick ( Sender: TObject ) ;
begin
if Assigned ( lv_FTP_Files. Selected ) then
begin
if ( lv_FTP_Files. Selected . SubItems . Strings [ 0 ] = 'Directory' ) then
begin
ftp_client. ChangeDir ( txt_FTP_Directory. Text +
lv_FTP_Files. Selected . Caption + '/' ) ;
listarftp( txt_FTP_Directory. Text + lv_FTP_Files. Selected . Caption + '/' ,
lv_FTP_Files, ftp_client, directorios, archivos) ;
txt_FTP_Directory. Text : = ftp_client. RetrieveCurrentDir + '/' ;
end ;
end
else
begin
MessageBox( 0 , 'Write path' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end ;
end ;
procedure TFormHome. btnList_FTPClick ( Sender: TObject ) ;
begin
if not ( txt_FTP_Directory. Text = '' ) then
begin
listarftp( txt_FTP_Directory. Text , lv_FTP_Files, ftp_client, directorios,
archivos) ;
end
else
begin
MessageBox( 0 , 'Write path' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end ;
end ;
procedure TFormHome. btnListMeClick ( Sender: TObject ) ;
begin
if not ( txtMe_Directory. Text = '' ) then
begin
listar( txtMe_Directory. Text , lvLocalFiles, local_iconos) ;
end
else
begin
MessageBox( 0 , 'Write path' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end ;
end ;
procedure TFormHome. lvLocalFilesDblClick ( Sender: TObject ) ;
begin
if Assigned ( lvLocalFiles. Selected ) then
begin
if ( DirectoryExists ( txtMe_Directory. Text + lvLocalFiles. Selected . Caption +
'/' ) ) then
begin
Chdir ( txtMe_Directory. Text + lvLocalFiles. Selected . Caption + '/' ) ;
listar( txtMe_Directory. Text + lvLocalFiles. Selected . Caption + '/' ,
lvLocalFiles, local_iconos) ;
txtMe_Directory. Text : = GetCurrentDir + '\' ;
end ;
end
else
begin
MessageBox( 0 , 'Select Path' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end ;
end ;
procedure TFormHome. MakeDirectory1Click ( Sender: TObject ) ;
var
directorio: string ;
begin
directorio : = InputBox( 'FTP Manager 1.0' , 'Directory : ' , '' ) ;
try
begin
MkDir ( txtMe_Directory. Text + '/' + directorio) ;
if not ( txtMe_Directory. Text = '' ) then
begin
listar( txtMe_Directory. Text , lvLocalFiles, local_iconos) ;
end ;
MessageBox( 0 , 'Directory created' , 'FTP Manager 1.0' ,
MB_ICONINFORMATION) ;
end ;
except
MessageBox( 0 , 'Error' , 'FTP Manager 1.0' , MB_ICONERROR) ;
end ;
end ;
procedure TFormHome. MakeDirectory2Click ( Sender: TObject ) ;
var
directorio: string ;
begin
directorio : = InputBox( 'FTP Manager 1.0' , 'Directory : ' , '' ) ;
try
begin
ftp_client. ChangeDir ( txt_FTP_Directory. Text ) ;
ftp_client. MakeDir ( directorio) ;
if not ( txt_FTP_Directory. Text = '' ) then
begin
listarftp( txt_FTP_Directory. Text , lv_FTP_Files, ftp_client,
directorios, archivos) ;
end ;
MessageBox( 0 , 'Directory created' , 'FTP Manager 1.0' ,
MB_ICONINFORMATION) ;
end ;
except
MessageBox( 0 , 'Error' , 'FTP Manager 1.0' , MB_ICONERROR) ;
end ;
end ;
procedure TFormHome. Refresh1Click ( Sender: TObject ) ;
begin
if not ( txtMe_Directory. Text = '' ) then
begin
listar( txtMe_Directory. Text , lvLocalFiles, local_iconos) ;
end
else
begin
MessageBox( 0 , 'Write path' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end ;
end ;
procedure TFormHome. Refresh2Click ( Sender: TObject ) ;
begin
if not ( txt_FTP_Directory. Text = '' ) then
begin
listarftp( txt_FTP_Directory. Text , lv_FTP_Files, ftp_client, directorios,
archivos) ;
end ;
end ;
procedure TFormHome. Rename1Click ( Sender: TObject ) ;
var
original, new_name: string ;
begin
if Assigned ( lvLocalFiles. Selected ) then
begin
original : = lvLocalFiles. Selected . Caption ;
new_name : = InputBox( 'FTP Manager 1.0' , 'New name : ' , '' ) ;
if RenameFile ( txtMe_Directory. Text + '/' + original,
txtMe_Directory. Text + '/' + new_name) then
begin
if not ( txtMe_Directory. Text = '' ) then
begin
listar( txtMe_Directory. Text , lvLocalFiles, local_iconos) ;
end ;
MessageBox( 0 , 'Changed' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end
else
begin
MessageBox( 0 , 'Error' , 'FTP Manager 1.0' , MB_ICONERROR) ;
end ;
end ;
end ;
procedure TFormHome. Rename2Click ( Sender: TObject ) ;
var
original, new_name: string ;
begin
if Assigned ( lv_FTP_Files. Selected ) then
begin
original : = lv_FTP_Files. Selected . Caption ;
new_name : = InputBox( 'FTP Manager 1.0' , 'New name : ' , '' ) ;
try
begin
ftp_client. ChangeDir ( txt_FTP_Directory. Text ) ;
ftp_client. Rename ( original, new_name) ;
if not ( txt_FTP_Directory. Text = '' ) then
begin
listarftp( txt_FTP_Directory. Text , lv_FTP_Files, ftp_client,
directorios, archivos) ;
end ;
MessageBox( 0 , 'Changed' , 'FTP Manager 1.0' , MB_ICONINFORMATION) ;
end ;
except
MessageBox( 0 , 'Error' , 'FTP Manager 1.0' , MB_ICONERROR) ;
end ;
end ;
end ;
procedure TFormHome. btnUploadClick ( Sender: TObject ) ;
var
fileasubir: string ;
dirasubir: string ;
cantidad: File of byte ;
begin
if Assigned ( lvLocalFiles. Selected ) then
begin
try
begin
fileasubir : = txtMe_Directory. Text + lvLocalFiles. Selected . Caption ;
dirasubir : = txt_FTP_Directory. Text ;
ftp_client. OnWork : = ftp_clientWork;
AssignFile ( cantidad, fileasubir) ;
Reset ( cantidad) ;
progreso. Max : = FileSize ( cantidad) div 1024 ;
CloseFile ( cantidad) ;
ftp_client. ChangeDir ( dirasubir) ;
ftp_client. Put ( fileasubir, lvLocalFiles. Selected . Caption , False ) ;
if not ( txt_FTP_Directory. Text = '' ) then
begin
listarftp( txt_FTP_Directory. Text , lv_FTP_Files, ftp_client,
directorios, archivos) ;
end ;
MessageBox( 0 , 'Action completed successfully' , 'FTP Manager 1.0' ,
MB_ICONINFORMATION) ;
end ;
except
MessageBox( 0 , 'Error' , 'FTP Manager 1.0' , MB_ICONERROR) ;
end ;
end
else
begin
MessageBox( 0 , 'Select File to upload' , 'FTP Manager 1.0' ,
MB_ICONINFORMATION) ;
end ;
end ;
end .
// The End ?
Si quieren bajar el programa lo pueden hacer de
aca .