PDA

View Full Version : Rogue AP: Bridge Wlan/at0 instead of eth0/at0



leevai
2013-07-09, 20:21
Hey guys, How to make a bridge between the Wireless Lan and the rogue acces point?

To make a bridge between Lan and a rogue acces point would be done by the following commands:
# airbase-ng --essid Rogue -c 1 mon0
--> meaning the unauthorized acces point is called "Rogue" on channel 1 (wich will be "at0").
# brctl addbr (name bridge)
# brctl addif (name bridge) eth0
# brctl addif (name bridge) at0
# ifconfig eth0 0.0.0.0 up
# ifconfig at0 0.0.0.0 up
# echo 1 > /proc/sys/net/ipv4/ip_forward

How would this be done for a Wireless lan?
I've tried:
#brctl addif (name bridge) wlan0 but this is probably not the right thing to do cause I keep getting an error on this one. has it something to do with the "addif" command?

root-boy
2013-07-10, 06:37
If i'm not mistaken, you have two wireless cards ? one to be used as an AP and the other to redirect victims to the internet ?

can you post the result of the following command :
iwconfig

leevai
2013-07-10, 08:12
hups, I have 2 alfa cards and the intern card of my laptop.

# iwconfig shows them to me all 3
#airmon-ng also shows them to me ;-)

root-boy
2013-07-10, 08:49
Ok can you post the output of those commands and the error your are getting when doing the bridge.

leevai
2013-07-10, 09:26
Ok,
My wlan0 is the card of the computer and is connected to the internet
my wlan1 is the alfacard awus036H
Mon0 is together with the wlan1 ==> #airmon-ng start wlan1 creates mon0
I guess I need to create a bridge between the wlan0 and the at0 (--essid Rogue) because the wlan 1 is already busy with the rogue acces point (AP)



# airbase-ng --essid Rogue -c 1 mon0 (works fine)
# brctl addbr (name bridge) (works fine)
# brctl addif (name bridge) wlan0 ==>> this gives me the error

root@kali:~# brctl addif wifi-bridge wlan0
can't add wlan0 to bridge wifi-bridge: Operation not supported
root@kali:~#

The reason why I want to make a wlan/at0 bridge is because when I connect the eth0(Lan) to the laptop it sais it is connected but i can't surf on the internet. wich means any client connecting to my rogue AP can connect but can not surf.
however when i connect my client windows laptop everything goes well as it should.

A bridge between the rogue AP and the wlan0 or wlan1 would be also more interesting I think so i'm not dependeble from any cable. Hope you understand what i'm meaning here.
Will be back tomorrow cause I got the late workshift today.
Greetz and thanks already for the time!

bahha
2013-07-12, 16:27
if what you want to do is to connect to an AP and then share its connection on Rogue AP. you don't even have to have two wifi adapters although it will work too.

You don't have to create a bridge at all . this happened to me and I used IPTABLES and it works .

here use these commands

First create the rogue AP with airbase-ng

then setup the at0 with dhcp and the desired IP range change the ones I provided to your own and DHCPD command depending on what version you are using !

# ifconfig at0 up

# ifconfig at0 192.168.2.129 netmask 255.255.255.128

# route add -net 192.168.2.128 netmask 255.255.255.128 gw 192.168.2.129

# dhcpd -cf /etc/dhcp/dhcpd.conf -pf /var/run/dhcpd.pid at0


# iptables --table nat --append POSTROUTING --out-interface wlan0 -j MASQUERADE ( change wlan0 to wlanx that is to whatever interface you use to connect to the access )

# iptables --append FORWARD --in-interface at0 -j ACCEPT

# echo 1 > /proc/sys/net/ipv4/ip_forward

and it should work

europa81
2013-08-23, 10:21
Hi Everyone, same problem here - massive Newbee ...

have Kali Linux on a Panasonic Toughbook with two Alfas. Everything works fine. However after making at0 with airbase-ng the command brctl is not reccognized. Tried to apt-get install bridge-utils to no avail. Answer is that it is obsolete. Do I need to edit the apt-get server list ? Tried then as mentionned above and Kali Linux answers that the command dhcpd is not reccognized. Is there a more modern way of bridgeing in Kali Linux ? Treid the network settings but did not see any bridgeing capability there either.

Any help is appreciated.

cpcshub
2015-09-28, 15:24
Hi Bahha,

I tried your instructions but still can get internet on my connected client, DHCP work.
Any help will be appreciated.

thanks

k4v3h
2015-11-02, 23:38
hi download bridge-utils from one miroor from this link https://packages.debian.org/squeeze/powerpc/bridge-utils/download then go to directory wich file downloaded , rith click and open that location in terminal and type this command #dpkg --install filename finish tool installed and ready to work ..............excusme for my broken english
Hi Everyone, same problem here - massive Newbee ...

have Kali Linux on a Panasonic Toughbook with two Alfas. Everything works fine. However after making at0 with airbase-ng the command brctl is not reccognized. Tried to apt-get install bridge-utils to no avail. Answer is that it is obsolete. Do I need to edit the apt-get server list ? Tried then as mentionned above and Kali Linux answers that the command dhcpd is not reccognized. Is there a more modern way of bridgeing in Kali Linux ? Treid the network settings but did not see any bridgeing capability there either.

Any help is appreciated.

youdass
2016-04-07, 14:53
it seems that it is impossible or the brctl not supported to bridge at0 (mon) with wlanx I have tried everything to do that but nothing worker i am trying to do the MITM but it only works with eth0.

if anyone has a solution for this matter please let me know

regards