easycheese Posted July 30, 2009 Share Posted July 30, 2009 This is howi have my setup, im using backtrack and the pineapple. I have the Pineapple connected to my Lappy with cat5, and have backtrack running a DHCP server. This is a first Tech artical i wrote, let me know if im missing something or if you try this setup and have problems. Its located: www.dc425.org/dhcp 1. For this im using DHCP3 as my DHCP server. 2. I also used Darren Kitchens Tutorial on Hak5.org for ICS. 3. I created this so i can use the Setup of "evil wifi" located here. Software needed: 1. Backtrack4 2. Dhcp3 3. A Brain I used Darrens Setup for ICS for windows for my Fon, so i can use it both on windows, and Linux. I did the following setup on the fon. Let’s assume that you have successfully installed Der Jasager as per this tutorial. Once you’ve done this go ahead and log in to Der Jasager’s webif interface using a web browser. In my case it was http://192.168.1.1/webif.html. Click the “Network” tab. Change the drop down box next to “Connection Type” from whatever it is set to, to something like Static IP and then back to DHCP. Do this a couple of times. For some reason, in my webif interface, when I change to DHCP, not all settings are available until I do this. In any case, you’ll want to see these options: Change the IP address to something on the same subnet as your non-Internet Connection Shared NIC (that’s “Atheros”on eniac). I changed the IP in the webif interface to 192.168.0.250. Set the Netmask to the default class C address (255.255.255.0). Save your configuration twice. Once using the “Save Changes” button and then again using the “Apply Changes” button. I saved the changes this way, just to be safe. Now, remove power from the Fonera that’s running Der Jasager. Re-associate the ICS’ed NIC to its original access point. In my case, I re-associated “Alfa” to “WRT54G”. Wait a minute, and reapply power to the La Fonera. Then wait a while for the Fonera to boot and the non-ICS’ed NIC (“Atheros” in my case) to associate to “OpenWrt”. You can now open Der Jasager’s web interface in a browser, by connecting and authenticating to the new IP address you just set up. In my case that would be http://192.168.0.250. Here’s how mine looks. After that, lets setup DHCP server on backtrack DHCP3 How too: I first updated dhcp3 on backtrack4. You dont have to do this, but if you want do: sudo apt-get install dhcp3 Then backed up dhcp.conf and erased the contents of the file. Its located at the following: /etc/dhcp3/dhcp.conf This is what my dhcp.conf file looks like: ddns-updates off; option T150 code 150 = string; deny client-updates; one-lease-per-client false; allow bootp; ddns-update-style none; option domain-name-servers 208.67.222.222, 208.67.220.220; default-lease-time 600; max-lease-time 7200; authoritative; subnet 192.168.0.0 netmask 255.255.255.0 { interface eth0; range 192.168.0.2 192.168.0.254; default-lease-time 600; max-lease-time 7200; option subnet-mask 255.255.255.0; option broadcast-address 192.168.0.255; option routers 192.168.0.2; option domain-name-servers 208.67.222.222, 208.67.220.220; } This i edited /etc/network/interfaces; under auto eth0 this is what i have: auto eth0 iface eth0 inet static address 192.168.0.1 network 192.168.0.1/24 netmask 255.255.255.0 Broadcast 192.168.0.254 Then you must tell the dhcp3-server what adapter to listen to. This is located at /etc/default/dhcp3-server Edit that file and under INTERFACES add eth0. It should look like the following: INTERFACES="eth0" Next i set the ipaddress of eth0: sudo ifconfig eth0 inet 192.168.0.2 Next you have to allow all connections through iptables out throught the world, depending on the adapter that is connected to the internet you will have to change it in the command. But the command that i used i let the connection out through my wireless so i use wlan0. sudo iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE You also need to allow ip forwarding: echo 1 > /proc/sys/net/ipv4/ip_forward Now you need to connect the Fon to your laptop. Once connected, start the DHCP server by entering the following: sudo /etc/init.d/dhcp3-server start Once started, you can check for Dhcp leases with the following cat /var/lib/dhcp3/dhcp-leases Now you can startup Hamster and Ferret, Als you can run an Apachi server, with a fake Router page, or what ever you want. Quote Link to comment Share on other sites More sharing options...
easycheese Posted July 30, 2009 Author Share Posted July 30, 2009 The pictures didnt copy over, but if you check my site you can see them. Quote Link to comment Share on other sites More sharing options...
digivore Posted August 1, 2009 Share Posted August 1, 2009 easycheese - your tutorial looks great! thanks for putting that together. I've been struggling off and on with setting up ICS for quite some time, and couldn't figure out what I was doing wrong. I'm currently working with the "piranha firmware" and it seems now that my main problem is that I CAN NOT get the 'connection type' drop down box to display all the options when I select DHCP. I've tried over and over going between static and back to DHCP, but just cannot get the options to come up. does anyone have any insight on this? am i missing something? or should i just not use this firmware and go with the version being used in the tutorial. thanks Quote Link to comment Share on other sites More sharing options...
easycheese Posted August 7, 2009 Author Share Posted August 7, 2009 easycheese - your tutorial looks great! thanks for putting that together. I've been struggling off and on with setting up ICS for quite some time, and couldn't figure out what I was doing wrong. I'm currently working with the "piranha firmware" and it seems now that my main problem is that I CAN NOT get the 'connection type' drop down box to display all the options when I select DHCP. I've tried over and over going between static and back to DHCP, but just cannot get the options to come up. does anyone have any insight on this? am i missing something? or should i just not use this firmware and go with the version being used in the tutorial. thanks What options are you getting, you said you dont get all the options right? Quote Link to comment Share on other sites More sharing options...
Mr-Protocol Posted December 6, 2009 Share Posted December 6, 2009 I followed your guide exactally but for some reason my DHCP3 server will not start. Any ideas as to why? ---Fixed: the filename is dhcpd.conf not dhcp.conf (Backtrack 4 Pre-Final) Quote Link to comment Share on other sites More sharing options...
Mr-Protocol Posted December 7, 2009 Share Posted December 7, 2009 I have DHCP server running. Now when someone connects via the Fonera, the DHCP server does not give them an IP address. Quote Link to comment Share on other sites More sharing options...
digininja Posted December 7, 2009 Share Posted December 7, 2009 Just to let you know that if you run the dhcp server on anything other than the Fon then Jasager probably won't pick up the IP addresses of clients who connect. easycheese, looks like a good how to, thanks for the contribution. Quote Link to comment Share on other sites More sharing options...
taiyed14 Posted December 7, 2009 Share Posted December 7, 2009 I like to run DHCP on the Fon and configure dnsmaq to give out the the IP address of my laptop as the default gateway. I think this makes things much simpler. Internet --- Laptop (GW) --- FON ---- Wireless clients Quote Link to comment Share on other sites More sharing options...
Mr-Protocol Posted December 11, 2009 Share Posted December 11, 2009 I like to run DHCP on the Fon and configure dnsmaq to give out the the IP address of my laptop as the default gateway. I think this makes things much simpler. Internet --- Laptop (GW) --- FON ---- Wireless clients Steps on how that is accomplished please? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.