As you may already know Windows 7 adds native Virtual WiFi technology from Microsoft Research as mentioned by Long on his blog. This lead me to this MSDN page stating
“On Windows 7 and later, the operating system installs a virtual device if a Hosted Network capable wireless adapter is present on the machine. This virtual device normally shows up in the “Network Connections Folder” as ‘Wireless Network Connection 2’ with a Device Name of ‘Microsoft Virtual WiFi Miniport adapter’ if the computer has a single wireless network adapter. This virtual device is used exclusively for performing software access point (SoftAP) connections and is not present in the list returned by the WlanEnumInterfaces function. The lifetime of this virtual device is tied to the physical wireless adapter. If the physical wireless adapter is disabled, this virtual device will be removed as well.”
Wait a minute! SoftAP! Seriously? This was a surprize since I had been exploring a solution for this exact problem for more than a month. However I was disappointed at first when I got my hands on Windows 7 RC. There was no setting for this so called SoftAP feature. Forget that, I could not even find the virtual wireless device named “Microsoft Virtual WiFi Miniport adapter”. It just did not exist. Some people on the web speculated that this was because of missing driver support even though Virtual WiFi functionality is a requirement for WLAN drivers under the Windows 7 certification logo. This did not fit. I was never prompted for installing uncertified drivers. As a matter of fact I did not have to install any drivers at all. Everything was done by Windows 7 automatically. I decided to investigate, and found the solution. Basically there is no native GUI to do all this, so you have to use command prompt to do all this. Here is what you need to do.
Run cmd.exe as administrator and enter the following command
netsh wlan set hostednetwork mode=allow “ssid=<ssid>” “key=<passphrase>” keyUsage=persistent
where is <ssid> is the SSID and <passphrase> is the WPA2-Personal key you want to associate with your SoftAP.
This will create the required “Microsoft Virtual WiFi Miniport adapter” and also set up your hostednetwork. You may now setup Internet Connection Sharing or Network Bridging for this newly found adapter. All this is onetime setting.
What is left now is to start the hosted network. The command to start/stop the hostednetwork is “netsh wlan start|stop hostednetwork” and it needs to be run as adminstrator. Since you will have to start/stop the hostednetwork every time you start/stop your computer, I would advice you to create desktop shortcuts for there commands and set them to run as administrator.
It seems some drivers do face some problems with these commands and may need windows to restart to function correctly again. Enjoy. Here are some screenshots for hostednetwork without ICS or bridging and no clients connected.
UPDATE (21 March 2010): If you prefer using a GUI then try Connectify.