LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud
User Name
Password
Linux - Virtualization and Cloud This forum is for the discussion of all topics relating to Linux Virtualization and Linux Cloud platforms. Xen, KVM, OpenVZ, VirtualBox, VMware, Linux-VServer and all other Linux Virtualization platforms are welcome. OpenStack, CloudStack, ownCloud, Cloud Foundry, Eucalyptus, Nimbus, OpenNebula and all other Linux Cloud platforms are welcome. Note that questions relating solely to non-Linux OS's should be asked in the General forum.

Notices


Reply
  Search this Thread
Old 12-15-2015, 09:59 PM   #1
mailtomsa
LQ Newbie
 
Registered: Nov 2015
Posts: 21

Rep: Reputation: Disabled
Question Use guest OS as access point for public WIFI spots for host?


Hello again,

I have a new question about VirtualBox (or if something else allows what I need, that would be fine as well).

My problem is that my LinuxMint laptop can not access public WIFI hotspots that use captive portal mechanisms to login and agree to their user agreement - which pretty much most of the hotspots out there are doing nowadays. The reason seems to be that those captive portals use mechanisms that are also used in malicious attacks (like DNS spoofing). Since most Linux distros are set up in a way to protect against such attacks, captive portals don't work either.

So I am wondering if I could run a Windows guest OS inside Virtual machine, and hand over full control of the wireless network adapter, so that the guest can log in to the WIFI network; and then somehow make the host OS route through the guest OS.

The only thing I found using Google so far was a post from someone using Parallels on a Mac host to route through a Windows guest OS, but nothing for Linux hosts.

Does anyone know if and how I could get this to work?

Or, if you know an easier/better solution for the captive portal problem, please let me know as well...

Thank you!
 
Old 12-15-2015, 11:49 PM   #2
sag47
Senior Member
 
Registered: Sep 2009
Location: Raleigh, NC
Distribution: Ubuntu, PopOS, Raspbian
Posts: 1,899
Blog Entries: 36

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
TLDR: visit an unsecured website like http://example.com/ so captive portals work as intended.

---

For captive portals, I just visit http://example.com/. Captive portals typically work well when the protocol is plain HTTP. It's usually not the "distro" that makes captive portals harder. It's the browser you're using that typically is making the issue harder for captive portals (i.e. you'll have the same problem on Windows).

For instance, modern versions of Firefox and Google Chrome implement extra security for HTTPS connections such as:Popular sites like Facebook, Google, Twitter, etc. implement HSTS which breaks captive portals ability to intercept secure communications for those sites. This only works when both the server and client (browser) support HSTS but as I said popular modern browsers and sites already do.

Therefore, if you think you're on a wifi access point that has a captive portal then visit http://example.com/ as your first site. They tend to "play nicer" when on a site without encryption.

---

To answer your question about VMs directly accessing wifi. It can only be done in VBox if you have a wireless USB dongle and configure the dongle to be directly connected to the virtual machine. As far as I'm aware (even after web searching) there's no way to exclusively connect built-in wireless to a VM. You could use other tricks such as bridged networking.

---

Fun experiment to determine if a website supports HSTS! Open the terminal and use curl to get the headers of the web server and search for the Strict-Transport-Security header.

Code:
$ curl -sILk https://twitter.com/ | grep -i strict
strict-transport-security: max-age=631138519
$ curl -sILk https://www.google.com/ | grep -i strict
$ curl -sILk https://www.facebook.com/ | grep -i strict
Strict-Transport-Security: max-age=15552000; preload
Based on our experiment it looks like both Twitter and Facebook support HSTS but Google does not. However, browsers still tend to use Certificate Pinning for those popular websites.

Last edited by sag47; 12-16-2015 at 12:28 AM.
 
1 members found this post helpful.
Old 12-16-2015, 03:07 PM   #3
jefro
Moderator
 
Registered: Mar 2008
Posts: 22,020

Rep: Reputation: 3630Reputation: 3630Reputation: 3630Reputation: 3630Reputation: 3630Reputation: 3630Reputation: 3630Reputation: 3630Reputation: 3630Reputation: 3630Reputation: 3630
You could attach a usb nic to a vm windows client and then use something like AnalogX's proxy to send data back to the linux.

Seems easier to get linux working.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
virtualbox guest cannot access the host's LAN with host-only adapter hortageno Linux - Virtualization and Cloud 3 10-29-2015 11:59 AM
Can a VirtualBox Guest Provide a Secure Connection Over Insecure Public WiFi? gentisle Linux - Server 4 12-19-2013 09:48 PM
block ping from host to host using iptables (I am the wireless access point) tris_halo Linux - Security 1 07-14-2013 11:43 AM
Public IP routing, possible NAT guest onto host? ThelenShar Linux - Virtualization and Cloud 7 12-28-2010 11:31 PM
can't access public wifi BUT wifi works on my router at home rob.rice Linux - Networking 4 05-15-2009 01:59 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud

All times are GMT -5. The time now is 02:53 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration