diff --git a/configure b/configure index 2b72924..0965396 100755 --- a/configure +++ b/configure @@ -916,10 +916,10 @@ fi if [ "X" = "X$XHYDRA_SUPPORT" ]; then - echo "Checking for GUI req's (pkg-config, gtk+-2.0) ..." + echo "Checking for GUI req's (pkg-config, gtk+-3.0) ..." XHYDRA_SUPPORT=`pkg-config --help > /dev/null 2>&1 || echo disabled` if [ "X" = "X$XHYDRA_SUPPORT" ]; then - XHYDRA_SUPPORT=`pkg-config --modversion gtk+-2.0 2> /dev/null` + XHYDRA_SUPPORT=`pkg-config --modversion gtk+-3.0 2> /dev/null` else XHYDRA_SUPPORT="" fi diff --git a/hydra-gtk/configure.ac b/hydra-gtk/configure.ac new file mode 100755 index 0000000..c373fb3 --- /dev/null +++ b/hydra-gtk/configure.ac @@ -0,0 +1,22 @@ +dnl Process this file with autoconf to produce a configure script. + +AC_INIT(configure.in) +AM_INIT_AUTOMAKE(xhydra, 0.1) +AM_CONFIG_HEADER(config.h) +AM_MAINTAINER_MODE + +AC_ISC_POSIX +AC_PROG_CC +AM_PROG_CC_STDC +AC_HEADER_STDC + +pkg_modules="gtk+-3.0 >= 3.0.0" +PKG_CHECK_MODULES(PACKAGE, [$pkg_modules]) +AC_SUBST(PACKAGE_CFLAGS) +AC_SUBST(PACKAGE_LIBS) + +AC_OUTPUT([ +Makefile +src/Makefile +]) + diff --git a/hydra-gtk/src/callbacks.h b/hydra-gtk/src/callbacks.h index dd213fa..e1084a0 100755 --- a/hydra-gtk/src/callbacks.h +++ b/hydra-gtk/src/callbacks.h @@ -8,7 +8,7 @@ void on_about1_activate(GtkMenuItem * menuitem, gpointer user_data); void on_btnStart_clicked(GtkButton * button, gpointer user_data); -void on_wndMain_destroy(GtkObject * object, gpointer user_data); +void on_wndMain_destroy(GtkWidget * object, gpointer user_data); void on_btnStop_clicked(GtkButton * button, gpointer user_data); diff --git a/hydra-gtk/src/interface.c b/hydra-gtk/src/interface.c index bddffe5..8b3c754 100755 --- a/hydra-gtk/src/interface.c +++ b/hydra-gtk/src/interface.c @@ -42,7 +42,7 @@ GtkWidget *create_wndMain(void) { GList *cmbProtocol_items = NULL; GtkWidget *entProtocol; GtkWidget *label7; - GtkObject *spnPort_adj; + GtkWidget *spnPort_adj; GtkWidget *spnPort; GtkWidget *label6; GtkWidget *radioTarget2; @@ -113,9 +113,9 @@ GtkWidget *create_wndMain(void) { GtkWidget *frame13; GtkWidget *table10; GtkWidget *chkExitf; - GtkObject *spnTimeout_adj; + GtkWidget *spnTimeout_adj; GtkWidget *spnTimeout; - GtkObject *spnTasks_adj; + GtkWidget *spnTasks_adj; GtkWidget *spnTasks; GtkWidget *label32; GtkWidget *label31; @@ -143,7 +143,7 @@ GtkWidget *create_wndMain(void) { GtkWidget *chkNTLM; GtkWidget *label18; GtkWidget *frame7; - GtkObject *spnSAPR3_adj; + GtkWidget *spnSAPR3_adj; GtkWidget *spnSAPR3; GtkWidget *label19; GtkWidget *frame15; @@ -177,9 +177,6 @@ GtkWidget *create_wndMain(void) { GtkWidget *label4; GtkWidget *statusbar; GtkAccelGroup *accel_group; - GtkTooltips *tooltips; - - tooltips = gtk_tooltips_new(); accel_group = gtk_accel_group_new(); @@ -187,7 +184,8 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(wndMain, "wndMain"); gtk_window_set_title(GTK_WINDOW(wndMain), "xHydra"); - vbox1 = gtk_vbox_new(FALSE, 0); + vbox1 = gtk_box_new(GTK_ORIENTATION_VERTICAL, 0); + gtk_box_set_homogeneous(GTK_BOX(vbox1), FALSE); gtk_widget_set_name(vbox1, "vbox1"); gtk_widget_show(vbox1); gtk_container_add(GTK_CONTAINER(wndMain), vbox1); @@ -207,7 +205,8 @@ GtkWidget *create_wndMain(void) { gtk_widget_show(ntbMain); gtk_box_pack_start(GTK_BOX(vbox1), ntbMain, TRUE, TRUE, 0); - vbox5 = gtk_vbox_new(FALSE, 0); + vbox5 = gtk_box_new(GTK_ORIENTATION_VERTICAL, 0); + gtk_box_set_homogeneous(GTK_BOX(vbox5), FALSE); gtk_widget_set_name(vbox5, "vbox5"); gtk_widget_show(vbox5); gtk_container_add(GTK_CONTAINER(ntbMain), vbox5); @@ -289,7 +288,7 @@ GtkWidget *create_wndMain(void) { entProtocol = GTK_COMBO(cmbProtocol)->entry; gtk_widget_set_name(entProtocol, "entProtocol"); gtk_widget_show(entProtocol); - gtk_tooltips_set_tip(tooltips, entProtocol, "The protocol to use for the login/password cracking attempt", NULL); + gtk_widget_set_tooltip_text(entProtocol, "The protocol to use for the login/password cracking attempt"); label7 = gtk_label_new("Protocol"); gtk_widget_set_name(label7, "label7"); @@ -302,7 +301,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(spnPort, "spnPort"); gtk_widget_show(spnPort); gtk_table_attach(GTK_TABLE(table8), spnPort, 1, 2, 3, 4, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, spnPort, "select the port on which the daemon you want to brute force runs, 0 means default", NULL); + gtk_widget_set_tooltip_text(spnPort, "select the port on which the daemon you want to brute force runs, 0 means default"); label6 = gtk_label_new("Port"); gtk_widget_set_name(label6, "label6"); @@ -315,7 +314,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(chkIPV6, "chkIPV6"); gtk_widget_show(chkIPV6); gtk_table_attach(GTK_TABLE(table8), chkIPV6, 0, 2, 2, 3, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkIPV6, "Enable to use IPV6", NULL); + gtk_widget_set_tooltip_text(chkIPV6, "Enable to use IPV6"); radioTarget2 = gtk_radio_button_new_with_mnemonic(NULL, "Target List"); gtk_widget_set_name(radioTarget2, "radioTarget2"); @@ -328,13 +327,13 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entTargetFile, "entTargetFile"); gtk_widget_show(entTargetFile); gtk_table_attach(GTK_TABLE(table8), entTargetFile, 1, 2, 1, 2, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, entTargetFile, "A file which contains the targets to attack. One entry per line. IP\naddresses and/or DNS names.", NULL); + gtk_widget_set_tooltip_text(entTargetFile, "A file which contains the targets to attack. One entry per line. IP\naddresses and/or DNS names."); entTarget = gtk_entry_new(); gtk_widget_set_name(entTarget, "entTarget"); gtk_widget_show(entTarget); gtk_table_attach(GTK_TABLE(table8), entTarget, 1, 2, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, entTarget, "The target to attack - DNS name or IP address", NULL); + gtk_widget_set_tooltip_text(entTarget, "The target to attack - DNS name or IP address"); gtk_entry_set_text(GTK_ENTRY(entTarget), "127.0.0.1"); radioTarget1 = gtk_radio_button_new_with_mnemonic(NULL, "Single Target"); @@ -364,25 +363,25 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(chkVerbose, "chkVerbose"); gtk_widget_show(chkVerbose); gtk_table_attach(GTK_TABLE(table9), chkVerbose, 1, 2, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkVerbose, "be verbose", NULL); + gtk_widget_set_tooltip_text(chkVerbose, "be verbose"); chkDebug = gtk_check_button_new_with_mnemonic("Debug"); gtk_widget_set_name(chkDebug, "chkDebug"); gtk_widget_show(chkDebug); gtk_table_attach(GTK_TABLE(table9), chkDebug, 1, 2, 1, 2, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkDebug, "Enable debug mode", NULL); + gtk_widget_set_tooltip_text(chkDebug, "Enable debug mode"); chkAttempts = gtk_check_button_new_with_mnemonic("Show Attempts"); gtk_widget_set_name(chkAttempts, "chkAttempts"); gtk_widget_show(chkAttempts); gtk_table_attach(GTK_TABLE(table9), chkAttempts, 0, 1, 1, 2, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkAttempts, "Show attempts", NULL); + gtk_widget_set_tooltip_text(chkAttempts, "Show attempts"); chkSSL = gtk_check_button_new_with_mnemonic("Use SSL"); gtk_widget_set_name(chkSSL, "chkSSL"); gtk_widget_show(chkSSL); gtk_table_attach(GTK_TABLE(table9), chkSSL, 0, 1, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkSSL, "Enable to use SSL (the target must have SSL enabled!", NULL); + gtk_widget_set_tooltip_text(chkSSL, "Enable to use SSL (the target must have SSL enabled!"); chkServiceDetails = gtk_check_button_new_with_mnemonic ("Service Module Usage Details"); gtk_widget_set_name (chkServiceDetails, "chkServiceDetails"); @@ -390,7 +389,7 @@ GtkWidget *create_wndMain(void) { gtk_table_attach (GTK_TABLE (table9), chkServiceDetails, 1, 2, 2, 3, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip (tooltips, chkServiceDetails, "Service Module Usage Details", NULL); + gtk_widget_set_tooltip_text (chkServiceDetails, "Service Module Usage Details"); chkCompleteHelp = gtk_check_button_new_with_mnemonic ("COMPLETE HELP"); gtk_widget_set_name (chkCompleteHelp, "chkCompleteHelp"); @@ -398,7 +397,7 @@ GtkWidget *create_wndMain(void) { gtk_table_attach (GTK_TABLE (table9), chkCompleteHelp, 0, 1, 2, 3, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip (tooltips, chkCompleteHelp, "Complete Help", NULL); + gtk_widget_set_tooltip_text (chkCompleteHelp, "Complete Help"); label29 = gtk_label_new("Output Options"); gtk_widget_set_name(label29, "label29"); @@ -429,13 +428,13 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entUsernameFile, "entUsernameFile"); gtk_widget_show(entUsernameFile); gtk_table_attach(GTK_TABLE(table2), entUsernameFile, 1, 2, 1, 2, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), 0, 0); - gtk_tooltips_set_tip(tooltips, entUsernameFile, "File with user logins, one entry per line", NULL); + gtk_widget_set_tooltip_text(entUsernameFile, "File with user logins, one entry per line"); entUsername = gtk_entry_new(); gtk_widget_set_name(entUsername, "entUsername"); gtk_widget_show(entUsername); gtk_table_attach(GTK_TABLE(table2), entUsername, 1, 2, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), 0, 0); - gtk_tooltips_set_tip(tooltips, entUsername, "The login to use", NULL); + gtk_widget_set_tooltip_text(entUsername, "The login to use"); gtk_entry_set_text(GTK_ENTRY(entUsername), "yourname"); radioUsername1 = gtk_radio_button_new_with_mnemonic(NULL, "Username"); @@ -457,13 +456,13 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(chkUsernameLoop, "chkUsernameLoop"); gtk_widget_show(chkUsernameLoop); gtk_table_attach(GTK_TABLE(table2), chkUsernameLoop, 0, 1, 2, 3, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkUsernameLoop, "Enable this option to loop around users not passwords", NULL); + gtk_widget_set_tooltip_text(chkUsernameLoop, "Enable this option to loop around users not passwords"); chkDisUser = gtk_check_button_new_with_mnemonic("Protocol does not require usernames"); gtk_widget_set_name(chkDisUser, "chkDisUser"); gtk_widget_show(chkDisUser); gtk_table_attach(GTK_TABLE (table2), chkDisUser, 1, 2, 2, 3, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkDisUser, "Protocols like Cisco, Cisco enable, redis, Oracle listener, SNMP, S7-300, VNC etc. are not using usernames", NULL); + gtk_widget_set_tooltip_text(chkDisUser, "Protocols like Cisco, Cisco enable, redis, Oracle listener, SNMP, S7-300, VNC etc. are not using usernames"); label8 = gtk_label_new("Username"); gtk_widget_set_name(label8, "label8"); @@ -484,13 +483,13 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entPassFile, "entPassFile"); gtk_widget_show(entPassFile); gtk_table_attach(GTK_TABLE(table3), entPassFile, 1, 2, 1, 2, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), 0, 0); - gtk_tooltips_set_tip(tooltips, entPassFile, "File with passwords to try, one entry per line", NULL); + gtk_widget_set_tooltip_text(entPassFile, "File with passwords to try, one entry per line"); entPass = gtk_entry_new(); gtk_widget_set_name(entPass, "entPass"); gtk_widget_show(entPass); gtk_table_attach(GTK_TABLE(table3), entPass, 1, 2, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), 0, 0); - gtk_tooltips_set_tip(tooltips, entPass, "The password to try", NULL); + gtk_widget_set_tooltip_text(entPass, "The password to try"); gtk_entry_set_text(GTK_ENTRY(entPass), "yourpass"); radioPass1 = gtk_radio_button_new_with_mnemonic(NULL, "Password"); @@ -522,7 +521,7 @@ GtkWidget *create_wndMain(void) { gtk_table_attach (GTK_TABLE (table3), entGeneration, 1, 2, 2, 3, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), 0, 0); - gtk_tooltips_set_tip (tooltips, entGeneration, "Generate passwords", NULL); + gtk_widget_set_tooltip_text (entGeneration, "Generate passwords"); gtk_entry_set_text (GTK_ENTRY (entGeneration), "1:1:a"); labelpass = gtk_label_new("Password"); @@ -544,13 +543,13 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(chkColon, "chkColon"); gtk_widget_show(chkColon); gtk_table_attach(GTK_TABLE(table5), chkColon, 0, 1, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkColon, "Enable this option to use a colon file for login/password attempts", NULL); + gtk_widget_set_tooltip_text(chkColon, "Enable this option to use a colon file for login/password attempts"); entColonFile = gtk_entry_new(); gtk_widget_set_name(entColonFile, "entColonFile"); gtk_widget_show(entColonFile); gtk_table_attach(GTK_TABLE(table5), entColonFile, 1, 2, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, entColonFile, "The colon file to use, each line has to be structured like \"mylogin:mypass\"", NULL); + gtk_widget_set_tooltip_text(entColonFile, "The colon file to use, each line has to be structured like \"mylogin:mypass\""); label20 = gtk_label_new("Colon separated file"); gtk_widget_set_name(label20, "label20"); @@ -566,19 +565,19 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(chkPassLogin, "chkPassLogin"); gtk_widget_show(chkPassLogin); gtk_table_attach(GTK_TABLE(table6), chkPassLogin, 0, 1, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkPassLogin, "Enable this option to try the login as password, in addition to the password/file", NULL); + gtk_widget_set_tooltip_text(chkPassLogin, "Enable this option to try the login as password, in addition to the password/file"); chkPassNull = gtk_check_button_new_with_mnemonic("Try empty password"); gtk_widget_set_name(chkPassNull, "chkPassNull"); gtk_widget_show(chkPassNull); gtk_table_attach(GTK_TABLE(table6), chkPassNull, 1, 2, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkPassNull, "Enable this option to try an empty password, in addition to the password/file", NULL); + gtk_widget_set_tooltip_text(chkPassNull, "Enable this option to try an empty password, in addition to the password/file"); chkPassReverse = gtk_check_button_new_with_mnemonic ("Try reversed login"); gtk_widget_set_name (chkPassReverse, "chkPassReverse"); gtk_widget_show (chkPassReverse); gtk_table_attach (GTK_TABLE (table6), chkPassReverse, 2, 3, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip (tooltips, chkPassReverse, "Enable this option to try an reverse password, in addition to the password/file", NULL); + gtk_widget_set_tooltip_text (chkPassReverse, "Enable this option to try an reverse password, in addition to the password/file"); label2 = gtk_label_new("Passwords"); gtk_widget_set_name(label2, "label2"); @@ -610,14 +609,14 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entHTTPProxy, "entHTTPProxy"); gtk_widget_show(entHTTPProxy); gtk_table_attach(GTK_TABLE(table7), entHTTPProxy, 1, 2, 1, 2, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, entHTTPProxy, "The address of the proxy. Syntax: \"http://123.45.67.89:8080\"", NULL); + gtk_widget_set_tooltip_text(entHTTPProxy, "The address of the proxy. Syntax: \"http://123.45.67.89:8080\""); gtk_entry_set_text(GTK_ENTRY(entHTTPProxy), "http://127.0.0.1:8080"); chkProxyAuth = gtk_check_button_new_with_mnemonic("Proxy needs authentication"); gtk_widget_set_name(chkProxyAuth, "chkProxyAuth"); gtk_widget_show(chkProxyAuth); gtk_table_attach(GTK_TABLE(table7), chkProxyAuth, 0, 1, 2, 3, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkProxyAuth, "Enable this if the proxy requires authenticatio", NULL); + gtk_widget_set_tooltip_text(chkProxyAuth, "Enable this if the proxy requires authenticatio"); label23 = gtk_label_new("Username"); gtk_widget_set_name(label23, "label23"); @@ -629,7 +628,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entProxyUser, "entProxyUser"); gtk_widget_show(entProxyUser); gtk_table_attach(GTK_TABLE(table7), entProxyUser, 1, 2, 3, 4, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, entProxyUser, "The user name for proxy authentication", NULL); + gtk_widget_set_tooltip_text(entProxyUser, "The user name for proxy authentication"); gtk_entry_set_text(GTK_ENTRY(entProxyUser), "yourname"); label24 = gtk_label_new("Password"); @@ -642,7 +641,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entProxyPass, "entProxyPass"); gtk_widget_show(entProxyPass); gtk_table_attach(GTK_TABLE(table7), entProxyPass, 1, 2, 4, 5, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, entProxyPass, "The password for proxy authentication", NULL); + gtk_widget_set_tooltip_text(entProxyPass, "The password for proxy authentication"); gtk_entry_set_text(GTK_ENTRY(entProxyPass), "yourpass"); label26 = gtk_label_new(""); @@ -668,7 +667,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(radioProxy2, "radioProxy2"); gtk_widget_show(radioProxy2); gtk_box_pack_start(GTK_BOX(hbox3), radioProxy2, TRUE, TRUE, 0); - gtk_tooltips_set_tip(tooltips, radioProxy2, "Enable this to use a proxy for scanning ( Only for HTTP Module )", NULL); + gtk_widget_set_tooltip_text(radioProxy2, "Enable this to use a proxy for scanning ( Only for HTTP Module )"); gtk_radio_button_set_group(GTK_RADIO_BUTTON(radioProxy2), radioProxy_group); radioProxy_group = gtk_radio_button_get_group(GTK_RADIO_BUTTON(radioProxy2)); @@ -676,7 +675,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(radioProxy3, "radioProxy3"); gtk_widget_show(radioProxy3); gtk_box_pack_start(GTK_BOX(hbox3), radioProxy3, TRUE, TRUE, 0); - gtk_tooltips_set_tip(tooltips, radioProxy3, "Enable this to use a proxy for scanning", NULL); + gtk_widget_set_tooltip_text(radioProxy3, "Enable this to use a proxy for scanning"); gtk_radio_button_set_group(GTK_RADIO_BUTTON(radioProxy3), radioProxy_group); radioProxy_group = gtk_radio_button_get_group(GTK_RADIO_BUTTON(radioProxy3)); @@ -699,21 +698,21 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(chkExitf, "chkExitf"); gtk_widget_show(chkExitf); gtk_table_attach(GTK_TABLE(table10), chkExitf, 0, 2, 2, 3, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, chkExitf, "Enable this to stop all attacking processes once a valid login/password pair is found (per host)", NULL); + gtk_widget_set_tooltip_text(chkExitf, "Enable this to stop all attacking processes once a valid login/password pair is found (per host)"); spnTimeout_adj = gtk_adjustment_new(30, 0, 295, 1, 10, 0); spnTimeout = gtk_spin_button_new(GTK_ADJUSTMENT(spnTimeout_adj), 1, 0); gtk_widget_set_name(spnTimeout, "spnTimeout"); gtk_widget_show(spnTimeout); gtk_table_attach(GTK_TABLE(table10), spnTimeout, 1, 2, 1, 2, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, spnTimeout, "The maximum timeout an attack process is waiting for a response from the target", NULL); + gtk_widget_set_tooltip_text(spnTimeout, "The maximum timeout an attack process is waiting for a response from the target"); spnTasks_adj = gtk_adjustment_new(16, 0, 128, 1, 10, 0); spnTasks = gtk_spin_button_new(GTK_ADJUSTMENT(spnTasks_adj), 1, 0); gtk_widget_set_name(spnTasks, "spnTasks"); gtk_widget_show(spnTasks); gtk_table_attach(GTK_TABLE(table10), spnTasks, 1, 2, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip(tooltips, spnTasks, "The number of attack tasks to run in parallel. The more the faster, the most: computer lockup :-) 16-64 is a good choice", NULL); + gtk_widget_set_tooltip_text(spnTasks, "The number of attack tasks to run in parallel. The more the faster, the most: computer lockup :-) 16-64 is a good choice"); label32 = gtk_label_new("Timeout"); gtk_widget_set_name(label32, "label32"); @@ -733,7 +732,7 @@ GtkWidget *create_wndMain(void) { gtk_table_attach (GTK_TABLE (table10), chkExitF, 0, 2, 3, 4, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip (tooltips, chkExitF, "Enable this to stop all attacking processes once a valid login/password pair is found (global)", NULL); + gtk_widget_set_tooltip_text (chkExitF, "Enable this to stop all attacking processes once a valid login/password pair is found (global)"); chkNoErr = gtk_check_button_new_with_mnemonic ("Do not print messages about connection errors"); gtk_widget_set_name (chkNoErr, "chkNoErr"); @@ -741,7 +740,7 @@ GtkWidget *create_wndMain(void) { gtk_table_attach (GTK_TABLE (table10), chkNoErr, 0, 2, 4, 5, (GtkAttachOptions) (GTK_EXPAND | GTK_SHRINK), (GtkAttachOptions) (GTK_EXPAND), 0, 0); - gtk_tooltips_set_tip (tooltips, chkNoErr, "Do not print messages about connection errors", NULL); + gtk_widget_set_tooltip_text (chkNoErr, "Do not print messages about connection errors"); label30 = gtk_label_new("Performance Options"); gtk_widget_set_name(label30, "label30"); @@ -767,7 +766,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entHTTPProxyURL, "entHTTPProxyURL"); gtk_widget_show(entHTTPProxyURL); gtk_container_add(GTK_CONTAINER(frame10), entHTTPProxyURL); - gtk_tooltips_set_tip(tooltips, entHTTPProxyURL, "URL to connect to via the proxy", NULL); + gtk_widget_set_tooltip_text(entHTTPProxyURL, "URL to connect to via the proxy"); gtk_entry_set_text(GTK_ENTRY(entHTTPProxyURL), "www.suse.com"); label27 = gtk_label_new("http-proxy url / http-proxy-urlenum credential module"); @@ -784,7 +783,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entHTTPURL, "entHTTPURL"); gtk_widget_show(entHTTPURL); gtk_container_add(GTK_CONTAINER(frame3), entHTTPURL); - gtk_tooltips_set_tip(tooltips, entHTTPURL, "The protected URL you want to access", NULL); + gtk_widget_set_tooltip_text(entHTTPURL, "The protected URL you want to access"); gtk_entry_set_text(GTK_ENTRY(entHTTPURL), "/foo/bar/protected.html"); label15 = gtk_label_new("http / https url"); @@ -801,7 +800,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entCiscoPass, "entCiscoPass"); gtk_widget_show(entCiscoPass); gtk_container_add(GTK_CONTAINER(frame4), entCiscoPass); - gtk_tooltips_set_tip(tooltips, entCiscoPass, "The password to the cisco device", NULL); + gtk_widget_set_tooltip_text(entCiscoPass, "The password to the cisco device"); gtk_entry_set_text(GTK_ENTRY(entCiscoPass), "password"); label16 = gtk_label_new("Cisco Enable, Login for Cisco device"); @@ -818,7 +817,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entLDAPDN, "entLDAPDN"); gtk_widget_show(entLDAPDN); gtk_container_add(GTK_CONTAINER(frame5), entLDAPDN); - gtk_tooltips_set_tip(tooltips, entLDAPDN, "The DN scope of ldap to authenticate against", NULL); + gtk_widget_set_tooltip_text(entLDAPDN, "The DN scope of ldap to authenticate against"); gtk_entry_set_text(GTK_ENTRY(entLDAPDN), "dn-scope"); label17 = gtk_label_new("LDAP DN"); @@ -840,19 +839,19 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(chkLocal, "chkLocal"); gtk_widget_show(chkLocal); gtk_box_pack_start(GTK_BOX(hbox2), chkLocal, TRUE, TRUE, 0); - gtk_tooltips_set_tip(tooltips, chkLocal, "Just attack local accounts", NULL); + gtk_widget_set_tooltip_text(chkLocal, "Just attack local accounts"); chkDomain = gtk_check_button_new_with_mnemonic("domain accounts"); gtk_widget_set_name(chkDomain, "chkDomain"); gtk_widget_show(chkDomain); gtk_box_pack_start(GTK_BOX(hbox2), chkDomain, TRUE, TRUE, 0); - gtk_tooltips_set_tip(tooltips, chkDomain, "Attack domain and local accounts", NULL); + gtk_widget_set_tooltip_text(chkDomain, "Attack domain and local accounts"); chkNTLM = gtk_check_button_new_with_mnemonic("Interpret passes as NTLM hashes"); gtk_widget_set_name(chkNTLM, "chkNTLM"); gtk_widget_show(chkNTLM); gtk_box_pack_start(GTK_BOX(hbox2), chkNTLM, FALSE, FALSE, 0); - gtk_tooltips_set_tip(tooltips, chkNTLM, "Interpret passes as NTML hashes", NULL); + gtk_widget_set_tooltip_text(chkNTLM, "Interpret passes as NTML hashes"); label18 = gtk_label_new("SMB"); gtk_widget_set_name(label18, "label18"); @@ -869,7 +868,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(spnSAPR3, "spnSAPR3"); gtk_widget_show(spnSAPR3); gtk_container_add(GTK_CONTAINER(frame7), spnSAPR3); - gtk_tooltips_set_tip(tooltips, spnSAPR3, "The client id you want to attack, something between 0 and 99", NULL); + gtk_widget_set_tooltip_text(spnSAPR3, "The client id you want to attack, something between 0 and 99"); label19 = gtk_label_new("sapr3 client id"); gtk_widget_set_name(label19, "label19"); @@ -885,7 +884,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entCVS, "entCVS"); gtk_widget_show(entCVS); gtk_container_add(GTK_CONTAINER(frame15), entCVS); - gtk_tooltips_set_tip(tooltips, entCVS, "Directory of the CVS/SVN repository", NULL); + gtk_widget_set_tooltip_text(entCVS, "Directory of the CVS/SVN repository"); gtk_entry_set_text(GTK_ENTRY(entCVS), "trunk"); label34 = gtk_label_new("CVS/SVN Repository"); @@ -907,7 +906,7 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(entTelnet, "entTelnet"); gtk_widget_show(entTelnet); gtk_container_add(GTK_CONTAINER(alignment1), entTelnet); - gtk_tooltips_set_tip(tooltips, entTelnet, "Insert the return string for a succesfull login", NULL); + gtk_widget_set_tooltip_text(entTelnet, "Insert the return string for a succesfull login"); label36 = gtk_label_new("Telnet - Successful Login String"); gtk_widget_set_name(label36, "label36"); @@ -1004,25 +1003,25 @@ GtkWidget *create_wndMain(void) { gtk_widget_set_name(btnStart, "btnStart"); gtk_widget_show(btnStart); gtk_box_pack_start(GTK_BOX(hbox1), btnStart, TRUE, FALSE, 0); - gtk_tooltips_set_tip(tooltips, btnStart, "start hydra", NULL); + gtk_widget_set_tooltip_text(btnStart, "start hydra"); btnStop = gtk_button_new_with_mnemonic("Stop"); gtk_widget_set_name(btnStop, "btnStop"); gtk_widget_show(btnStop); gtk_box_pack_start(GTK_BOX(hbox1), btnStop, TRUE, FALSE, 0); - gtk_tooltips_set_tip(tooltips, btnStop, "stop hydra", NULL); + gtk_widget_set_tooltip_text(btnStop, "stop hydra"); btnSave = gtk_button_new_with_mnemonic("Save Output"); gtk_widget_set_name(btnSave, "btnSave"); gtk_widget_show(btnSave); gtk_box_pack_start(GTK_BOX(hbox1), btnSave, TRUE, FALSE, 0); - gtk_tooltips_set_tip(tooltips, btnSave, "save output", NULL); + gtk_widget_set_tooltip_text(btnSave, "save output"); btnClear = gtk_button_new_with_mnemonic("Clear Output"); gtk_widget_set_name(btnClear, "btnClear"); gtk_widget_show(btnClear); gtk_box_pack_start(GTK_BOX(hbox1), btnClear, TRUE, FALSE, 0); - gtk_tooltips_set_tip(tooltips, btnClear, "clear screen", NULL); + gtk_widget_set_tooltip_text(btnClear, "clear screen"); label4 = gtk_label_new("Start"); gtk_widget_set_name(label4, "label4"); @@ -1183,7 +1182,6 @@ GtkWidget *create_wndMain(void) { GLADE_HOOKUP_OBJECT(wndMain, btnClear, "btnClear"); GLADE_HOOKUP_OBJECT(wndMain, label4, "label4"); GLADE_HOOKUP_OBJECT(wndMain, statusbar, "statusbar"); - GLADE_HOOKUP_OBJECT_NO_REF(wndMain, tooltips, "tooltips"); gtk_window_add_accel_group(GTK_WINDOW(wndMain), accel_group); diff --git a/hydra-gtk/src/main.c b/hydra-gtk/src/main.c index 375d98a..cccc1a0 100755 --- a/hydra-gtk/src/main.c +++ b/hydra-gtk/src/main.c @@ -10,6 +10,7 @@ #include #include +#include #include "interface.h" #include "support.h" #include "callbacks.h" @@ -26,7 +27,7 @@ int main(int argc, char *argv[]) { GtkWidget *output; GtkTextBuffer *outputbuf; - gtk_set_locale(); + setlocale(LC_ALL, ""); gtk_init(&argc, &argv); add_pixmap_directory(PACKAGE_DATA_DIR "/" PACKAGE "/pixmaps"); diff --git a/hydra-gtk/src/support.c b/hydra-gtk/src/support.c index 22a1a3a..31c11c9 100755 --- a/hydra-gtk/src/support.c +++ b/hydra-gtk/src/support.c @@ -24,7 +24,7 @@ GtkWidget *lookup_widget(GtkWidget * widget, const gchar * widget_name) { if (GTK_IS_MENU(widget)) parent = gtk_menu_get_attach_widget(GTK_MENU(widget)); else - parent = widget->parent; + parent = gtk_widget_get_parent(widget); if (!parent) parent = (GtkWidget *) g_object_get_data(G_OBJECT(widget), "GladeParentKey"); if (parent == NULL)