What Is an Ad Hoc Network?

five hands fist bumping over laptops connected via an ad hoc network

Connecting two computers does not always require a centrally managed network. Instead, users can set up an ad hoc network between two computers. The two devices communicate through an ethernet cable or wireless cards. However, this connection is only temporary.

How Does an Ad Hoc Network Work?

Let’s say that Adam needs to transfer a file over to his friend, Eve, but doesn’t have access to a safe Wi-Fi connection. He can create an ad hoc network instead.

An ad hoc network is a temporary type of Local Area Network (LAN). If you set up an ad hoc network permanently, it becomes a LAN.

Multiple devices can use an ad hoc network at the same time, but this might cause a lull in performance. Users can also employ an ad hoc network to access the internet, as long as the hosting device can access the internet. This might be useful if only one small area of a location can access the internet, but multiple people need to get online.

With an ad hoc network, several devices can share the host device’s internet access. Employers typically pay well for jobs that manage this sort of network, especially in fields that demand a lot of travel.

Adam can create an ad hoc network between his and Eve’s laptops wirelessly, as long as it is within 100 meters (about 328 feet). From that point, he can transfer files to Eve’s laptop.

However, since Adam’s computer is the hosting device, the connection between the two devices will end when Adam ends the session, no matter how many devices are connected to the ad hoc network at the time.

Ad Hoc Connection Security

One of the biggest concerns with an ad hoc network is security. If cyber-attackers get within signal range, they will generally be able to connect to a wireless ad hoc network and, therefore, to the device.

Furthermore, users cannot disable their SSID broadcast in ad hoc mode, meaning that the network name cannot be hidden if users are in a public place. For this reason, ad hoc networks are not always appropriate.

However, because ad hoc connections are temporary and only accessible within 100 meters, they can be ideal for some situations. Attackers cannot hack into a device from far away and do not have unlimited time to plan their attack.

How to Set Up an Ad Hoc Network

Devices will start in infrastructure mode, but all devices that you want connected to the ad hoc network must be in ad hoc mode. To change this, you must either install a wireless network adapter or change a couple settings within your computer.

How you set up your ad hoc network will depend on what operating system you use. Training for and acquiring a computer networking certification will give you the skills to install and manage a variety of networks, but if you’re in a pinch, follow the guides below.

Windows 10 or 8

  1.  Go through the Command Prompt and type the following: netsh wlan set hostednetwork mode=allow ssid=[your desired network name] key =[your desired password].
  2.  Start the hosted network by inputting the following into Command Prompt: netsh wlan start hostednetwork.
  3.  In your Control Panel, open Network and Sharing Center.
  4.  Click on Network Connections.
  5.  Click on Change Advanced Sharing Center.
  6.  Turn on Network Discovery.
  7.  Click OK.

Windows 7

  1.  Click on the Start menu.
  2.  Click Connect To.
  3.  Then Set up a connection or network.
  4.  Choose Set up a wireless ad-hoc (computer-to-computer) network.
  5.  Click Next.
  6.  Enter the network details, like the SSID and the password.
  7.  Click Next.

Mac OS

  1.  Pick Create Network from AirPort
  2.  Click on Create a Computer-to-Computer Network.
  3.  Follow the on-screen prompts.

Following these steps will create an ad hoc network that other devices can join. From there, you can transfer files between connected devices and other connected users can access the internet through your device.

CompTIA Network+ covers computer networking topics including setting up an ad hoc network. Download the exam objectives to see all the topics covered by this IT certification.


Read more about Computer Networks.

Tags : Computer Networks