The situation is as follows: We have a Laptop with an Internet connection and we want to share that connection to use our Smartphone or Tablet through WiFi.
Normally to achieve this, we should create a WiFi connection, then make use of IPTables for NAT, etc ... But a user of ArchLinux you have created a script, which you named Create_AP and does all of that for us.
This script makes use of de hostapd + dnsmasq + iptables to create access point NAT, and hostapd + brctl + dhclient to create Access Point. The default behavior is a access point via NAT.
To install Create_AP what we do is open a terminal and put:
$ git clone https://github.com/oblique/create_ap $ cd create_ap $ sudo make install
Likewise, we can simply run a .sh that will be inside the folder. For it to work correctly we must have the following dependencies installed:
- bash (to run the script)
- util-linux (for getopt)
- haveged (optional)
# No password (open network):
create_ap wlan0 eth0 MyAccessPoint
# WPA + WPA2 with Password:
create_ap wlan0 eth0 MyAccessPoint MyPassword
# AP without shared Internet:
create_ap -n wlan0 MyAccessPoint MyPassword
# Network Bridge with shared Internet:
create_ap -m bridge wlan0 eth0 MyAccessPoint MyPassword
There is more information on how to use this script in the README.md file. To start the service we simply execute in the console:
# systemctl start create_ap
And to start it automatically:
# systemctl enable create_ap
For me personally, the Script works perfectly for me, I can connect my ZTE Open to my Laptop via WiFi but I have not found a way to connect to the Internet. It may be the fault of FirefoxOS that it does not have by default the option to put Proxy or something like that, I don't know, but it would be good if you share your experience with us in case it works for you.