Installing THC-Hydra 5.7 on Ubuntu Lucid Lynx 10.04

Wikipedia describes THC-Hydra as “… software … that uses a dictionary attack to test for weak or simple passwords on one or many remote hosts running a variety of different services.” Its useful for doing quick tests against your servers to make sure that your users are not using simple passwords. In pen tester speak, this is called a brute-force attack.

Here are the steps needed for installing it on the 32-bit version of Ubuntu Lucid Lynx 10.04.

Make sure you have all the necessary development tools (i.e. libraries, compilers, headers) and the source files for GTK:

sudo apt-get install build-essential linux-headers-$(uname -r) libgtk2.0-dev

Download and extract the THC-Hydra tarball

wget -c http://freeworld.thc.org/releases/hydra-5.7-src.tar.gz
tar -xvzf hydra-5.7-src.tar.gz
cd hydra-5.7-src

Now you are ready to compile:

./configure
make
sudo makeinstall

You are now ready to use Hydra. Type ./hydra -h to get syntax help. The GUI version can be started by running xhydra.

An example of using Hydra would look like this:

./hydra -l yourfriend@hisdomain.com -P password.txt -V mail.hisdomain.com imap

I believe that I am only at a beginning, only knocking at a door, and I believe that the best is yet to come. –Pat Buckley

You can leave a response, or trackback from your own site.

23 Responses to “Installing THC-Hydra 5.7 on Ubuntu Lucid Lynx 10.04”

  1. sm0ke42o says:

    Followed directions but apparently I am missing some dependencies or something because I receive this error during make.

    gcc -I. -Wall -O2 -o pw-inspector pw-inspector.c

    gcc -I. -Wall -O2 -lm -o hydra hydra-vnc.o hydra-pcnfs.o hydra-rexec.o hydra-nntp.o hydra-socks5.o hydra-telnet.o hydra-cisco.o hydra-http.o hydra-ftp.o hydra-imap.o hydra-pop3.o hydra-smb.o hydra-icq.o hydra-cisco-enable.o hydra-ldap.o hydra-mysql.o hydra-http-proxy.o hydra-smbnt.o hydra-mssql.o hydra-snmp.o hydra-cvs.o hydra-smtpauth.o hydra-sapr3.o hydra-ssh2.o hydra-teamspeak.o hydra-postgres.o hydra-rsh.o hydra-rlogin.o hydra-oracle-listener.o hydra-svn.o hydra-pcanywhere.o hydra-sip.o hydra-vmauthd.o hydra-smtpauth-ntlm.o hydra-firebird.o hydra-ncp.o hydra-http-proxy-auth-ntlm.o hydra-imap-ntlm.o hydra-pop3-ntlm.o hydra-http-form.o crc32.o d3des.o md4.o hydra-mod.o ntlm.o hydra.o -lm -lpq -L/usr/lib -L/usr/local/lib -L/lib -L/usr/lib
    /usr/bin/ld: cannot find -lpq
    collect2: ld returned 1 exit status
    make: *** [hydra] Error 1

    any advice?

  2. Anonymous says:

    I keep having the ssh2 error..

    make: *** [hydra-ssh2.o] Error 1

    I think I might be missing a lib

  3. Riccardo says:

    Hi, I think there is an option for ssl support in ./configure.

    In your case, Hydra works fine, but the ssl support is non present. (993 Gmail IMAP, for example)

    In backtrack 4 Hydra has SSL support.

    Thanks for your info.

    Rjky

    • Edwin says:

      Thanks for the tip. I normally use stunnel but it is a bit of a drag.
      I started up BT4, ran xhydra and plugged in the parameters including SSL and presto! SSL worked. Very easy. Thanks for the tiip.

  4. Leon says:

    I have xhydra installed and working in 10.04 and it works if I type in a url like somewhere.org, as a target, but if I type in somewhere.org/foldername it says login failed (the sub-directory is password protected). Any thoughts?

    Thanks

    • Edwin says:

      According to the README, you need to add the subfolder as an option for the service module http[s]-form-{get|post}. for example: /login.php:user=^USER^&pass=^PASS^&mid=123:incorrect
      I’m not 100% sure how that translates into the GUI xHydra but it seems to be on the Specific tab. The target variable needs to be able to translate into an IP address so you must only use the FQDN or IP Address. I hope that helps.

  5. alex says:

    i put in the first thing and got

    E: dpkg was interrupted, you must manually run ‘sudo dpkg –configure -a’ to correct the problem.

    is this because of a past failed installation?
    whats the bit of code to fix this?
    i lost a link to it

  6. alex says:

    yep, thanks.
    now i feel like a complete noob :(
    thanks for getting back so quick :) )

  7. alex says:

    also, where can i get xhydra? does that come with this installation?

  8. Jose Carlos Ramos Carmenates says:

    Estimado colega:

    Yo lo instale de maravilla sin ningún tipo de dificultad en 10.04, aquí dejo plasmado los pasos que realicé:

    1- descargarlo de http://freeworld.thc.org/releases/hydra-6.1-src.tar.gz
    2- tar -xvzf hydra-6.1-src.tar.gz
    3- cd hydra-6.1-src/
    4- ./configure
    5- make
    6- sudo make install
    y por útimo para hacer uso de el con su entorno gráfico, por su puesto, más cómodo:
    7- xhydra

    Espero que te funcione correctamente, en caso de problema no dudes en contactarme.

    Jose Carlos Ramos Carmenates
    jramoscarmenates@gmail.com
    Saludos

  9. Jochen M. says:

    A Tutorial in German language for ubuntu 10.10 and hydra 6.1 is found here: http://php-faq.eu/content/6/3/de/installations-anleitung-thc_hydra-61-in-ubuntu-1010.html

  10. teage says:

    followed directions and works perfect. thank you.

  11. Kristian says:

    I have followed the instructions carefully, but as I type in the command in the last step, the installation fails. This is what I come up with:

    Now type make install
    kristian@ubuntu:~/hydra-6.3-src$ sudo makeinstall
    sudo: makeinstall: command not found
    kristian@ubuntu:~/hydra-6.3-src$ sudo make install
    strip hydra pw-inspector
    echo OK > /dev/null && test -x xhydra && strip xhydra || echo OK > /dev/null
    cp hydra pw-inspector /usr/local/bin && cd /usr/local/bin && chmod 755 hydra pw-inspector
    echo OK > /dev/null && test -x xhydra && cp xhydra /usr/local/bin && cd /usr/local/bin && chmod 755 xhydra || echo OK > /dev/null
    cp -f hydra.1 xhydra.1 pw-inspector.1 /usr/local/man/man1
    cp: target `/usr/local/man/man1′ is not a directory
    make: *** [install] Error 1
    kristian@ubuntu:~/hydra-6.3-src$

    I am using ubuntu 11.04, and as it is hydra 6.3 I am installing I have of cause change the command to this. Hope you can help me?

    Thanks

    • Edwin says:

      Try creating the non-standard man directory;
      sudo mkdir /usr/local/man/man1

      than try sudo make install again.

  12. [...]     -> Hydra 5.4 Ubuntu 10.04 ‘Lucid Lynx’: http://edwincastillo.com/archives/95     -> Hydra 5.7 Ubuntu 10.10 ‘Maverick [...]

  13. Tinez says:

    Hi, Thanks for Tutorial!

    I have installed Hydra very well. But i have this error message when i tried to crack my router password using hydra:
    ” Error: File for logins not found!”

    Please, may you help me. I have forgotten my router password and don’t want to reset.

    Thanks!

  14. Tinez says:

    The command i type to crack my router password is:
    “hydra 192.168.2.1 -L /wordlists/login.txt -P /wordlists/ap_password.txt -t 1 -e ns -v -f http-get /loginpserr.htm ”

    Thx!

Leave a Reply

Powered by WordPress | Designed by: video games | Thanks to Webdesign Agentur, SUV Reviews and Bed in a Bag