I have an interesting issue with a laptop at work. The wireless has been disabled so that I have to use an Ethernet connection (don't ask). The nature of the laptop prevents me from being able to connect to my work network and I have to tie into the work guest network which is wireless based. Right now, what I have is a D-Link DIR-505L which connects to the work guest network and acts as a wireless router with one of my home SSIDs, NAT, and it's own subnet. I have a wireless bridge, an 802.11g device, which connects to the D-Link and provides an Ethernet connection to the laptop in question. I would like to not have to tie up 2 of my own devices to get things done.
What I want to do is setup a WiFi bridge on an RPi, using an 802.11n USB adapter, to connect to the work guest network and plug into the Ethernet port for data. This is just the opposite of what most setups show you. I could also probably setup an additional VM on my work laptop to provide the same service, but I would rather setup the RPi2 to do this as a matter of course.
My biggest bugaboo will be the capture page on the Guest network. There doesn't seem to be any easy way to use CURL to setup access to the page.
This is a blog mostly about techie things, what I am doing to my apartment network on the cheap, IOT, 3D Printing, Raspberry Pis, Arduinos, ESP32, ESP8266, Home Automation, Personal Weather Stations, Things That Go Bump in the Night, and some side issues that need discussing. Remember, sometimes the journey to an end is as much fun as the goal achieved!
Showing posts with label Routing. Show all posts
Showing posts with label Routing. Show all posts
Wednesday, August 26, 2015
Wednesday, January 21, 2015
Setting Up a Specialized Wireless Hotspot/Bridge Combo for Work
Givens: So, where I work at has a number of separate networks. There is a corporate network which has a number of security setups which need to be kept pristine. There is also a guest network which uses a capture port wireless access. I have a copy of Kali Linux on my work laptop which runs in a VM. I want to keep this VM separate from the corporate network but still be able to use it in my job, which involves doing some checks against lab equipment. I also like to bring my RPis into the office to work on during lunch.
Project: What I want to do is use a Raspberry Pi to be the intermediary with two internal network connections at work with the following characteristics:
I think I might dub this one Reverse Router, because I can think of a couple of other things that I might do with it under the area of penetration testing.
Update (2015-01-25): I had problems getting the DHCP server to work correctly and consistently with the TP-Link adapters that I was using, they kept dropping out. I finally got a sufficiently consistent connection once I switched over to the Netgear adapters. I may end up having to buy additional adapters for other tests.
Update (2015-01-27): I changed the channel addresses so that the two Netgear wifi adapters would not be tromping on each other; for stability reasons. I found a website that tells me how to set up multiple SSIDs on the same interface using hostapd (Multiple_SSIDs_with_hostapd). Also finally got the basic wireless access point to work with a wireless connection to my DIR-505L router. So now I have a wireless coming in to a NAT firewall to a WAP with DHCP going out. Right now I am copying the microSD to put onto a different microSD so that I can implement multiple SSIDs. What I want to do there is to have three SSIDs: one accessing the house (house SSID and cert), one for guest access, and one for secure test access (TBD). Each of these SSIDs will be set up to appear if certain files have been touched. I have not fully determined if the Netgear G54/N150 can handle multiple SSIDs or not. I know that hostapd can.
Update (2015-01-28): Well I discovered that there are some issues with changing the mac address of a wifi adapter on the fly. I did the first part of the setup from the Multiple SSIDs with hostapd article and borked the connection. What I will probably find when I look into it is that the wifi mac address was stored somewhere and it's keeping the dhcp server from running on the WAP.
Update (2015-01-29): Nope, the Netgear G54/N150 is not capable of changing the wifi MAC address; at least from my experiments that is the case. I wish that were not true, maybe I will try the previous wifi adapters (based on the rtl8188cu chipset).
Update (2015-01-30): After reading a couple of things online, maybe what I have here is a driver problem for the Netgear G54/N150 nano adapters. What seems to give it away is the problems that I have when I try to use the "iw list" command, which always comes back with an error. In addition, the setup does not appear stable between reboots; sometimes the dhcp server comes up and sometimes it doesn't.
Project: What I want to do is use a Raspberry Pi to be the intermediary with two internal network connections at work with the following characteristics:
- EXT - provide connection to the guest wireless through a wifi adapter on the RPi; have it automatically log into the guest wireless capture page and obtain an IP; this should provide a semi-permanent connection for both internal networks.
- NET1 - provide a bridge to the Kali Linux VM through a USB to Ethernet adapter connected to the Ethernet port on the RPi and then to a USB port on the work laptop; have it provide the EXT IP directly to the Kali Linux VM.
- NET2 - provide a NAT firewall (opt. packet inspection) between the EXT and another wifi adapter which provides a DHCP server/Wireless Access Port with an SSID which is common to the home network. I might split this up into 3 separate SSIDs.
- TUN1 - provide an opt. ssh tunnel through the EXT from NET2 to the home network for vpn connection giving an external WAP connection to my home network.
I think I might dub this one Reverse Router, because I can think of a couple of other things that I might do with it under the area of penetration testing.
Update (2015-01-25): I had problems getting the DHCP server to work correctly and consistently with the TP-Link adapters that I was using, they kept dropping out. I finally got a sufficiently consistent connection once I switched over to the Netgear adapters. I may end up having to buy additional adapters for other tests.
Update (2015-01-27): I changed the channel addresses so that the two Netgear wifi adapters would not be tromping on each other; for stability reasons. I found a website that tells me how to set up multiple SSIDs on the same interface using hostapd (Multiple_SSIDs_with_hostapd). Also finally got the basic wireless access point to work with a wireless connection to my DIR-505L router. So now I have a wireless coming in to a NAT firewall to a WAP with DHCP going out. Right now I am copying the microSD to put onto a different microSD so that I can implement multiple SSIDs. What I want to do there is to have three SSIDs: one accessing the house (house SSID and cert), one for guest access, and one for secure test access (TBD). Each of these SSIDs will be set up to appear if certain files have been touched. I have not fully determined if the Netgear G54/N150 can handle multiple SSIDs or not. I know that hostapd can.
Update (2015-01-28): Well I discovered that there are some issues with changing the mac address of a wifi adapter on the fly. I did the first part of the setup from the Multiple SSIDs with hostapd article and borked the connection. What I will probably find when I look into it is that the wifi mac address was stored somewhere and it's keeping the dhcp server from running on the WAP.
Update (2015-01-29): Nope, the Netgear G54/N150 is not capable of changing the wifi MAC address; at least from my experiments that is the case. I wish that were not true, maybe I will try the previous wifi adapters (based on the rtl8188cu chipset).
Update (2015-01-30): After reading a couple of things online, maybe what I have here is a driver problem for the Netgear G54/N150 nano adapters. What seems to give it away is the problems that I have when I try to use the "iw list" command, which always comes back with an error. In addition, the setup does not appear stable between reboots; sometimes the dhcp server comes up and sometimes it doesn't.
Tuesday, November 26, 2013
Some Thoughts on a Remote Wireless Access Device
The thought occurred to me today that I might want to set up a version of the RPi Router that would be able to be an extension of my home system. What I want to do is take the RPi Router into my office at work, turn it on, and have it use the same SSID, but via an SSH tunnel, go into my system at home. I would need to be able to:
- Use dual wi-fi access, provide a connection to the work wi-fi network (with auto authentication) and provide the same SSID as my home. Not sure if I need two USB wi-fi dongles or not.
- The connection should use an SSH tunnel which is kept up in the background, allowing me to use any of the systems that I have in my house.
- Somehow, this RPi Router should provide a DHCP forwarding from my house to whatever device hooks into the router. I may be able to use my new FVS318N router to accomplish some of this, since it does provide VPN capabilities (in case I cannot get the SSH tunnel to do it). An RPi based VPN for using the FVS318N anyone?
- Should be plug and play, i.e. put in the SD card and plug in the RPi to get it to function. Wishing for the moon at the same time.
Tuesday, August 13, 2013
Trying to resolve a standard interface bootup structure
I have been trying over last weekend to get my setup to come up with the hostapd and dhcp server running along with x11vnc running and showing display :0. Sometimes it works, and sometimes I have to log into the RPi to start something that didn't catch the first time. There may be some timing issues here.
I want to be able to simply plug in the RPi with hub and peripherals and have it come up so that I can connect my iPad 2 both at home and at work. Since there is a wi-fi proxy at work, with a capture page, this presents an unusual issue that needs to be resolved. At work, I have to open up a browser, then enter in a username and password (which changes every two weeks or so) before I can get an internet connection. At home, I have a wireless router which uses a standard form of encryption - that one is easy to get connected to. However, going between each environment has its issues. Solving this issue is the first one that I will need to solve in order to automate the standard interface on new SD cards as I use them. If I can just mount a USB stick and run a script on a new SD card to setup the interface that would be nice. Instead, I find myself having to go around the issue and log in a different way to get my setup the way that I want. More on this later.
Update: I should probably turn this idea into a standard script to be runnable off of a usb stick. That way, I can use the stick to setup a standard setup prior to modifying the setup for anything else.
I want to be able to simply plug in the RPi with hub and peripherals and have it come up so that I can connect my iPad 2 both at home and at work. Since there is a wi-fi proxy at work, with a capture page, this presents an unusual issue that needs to be resolved. At work, I have to open up a browser, then enter in a username and password (which changes every two weeks or so) before I can get an internet connection. At home, I have a wireless router which uses a standard form of encryption - that one is easy to get connected to. However, going between each environment has its issues. Solving this issue is the first one that I will need to solve in order to automate the standard interface on new SD cards as I use them. If I can just mount a USB stick and run a script on a new SD card to setup the interface that would be nice. Instead, I find myself having to go around the issue and log in a different way to get my setup the way that I want. More on this later.
Update: I should probably turn this idea into a standard script to be runnable off of a usb stick. That way, I can use the stick to setup a standard setup prior to modifying the setup for anything else.
Subscribe to:
Posts (Atom)