Introduction============*PyAccessPoint* is a package to create a wifi access point on linux. Itdepends on hostapd for AP provisioning and dnsmasq to assign IP addresses to devices.Dependencies============So, there 2 types of dependencies. System dependencies: - dnsmasq - hostapd - python3Python dependencies - wireless - netifaces - psutilYou can not install python dependencies manually, they will be installed while installing the package. If you want to do it manually, just type (or copy, it's better way :D):: sudo apt install python3-dev python3-pip && sudo pip3 install wireless netifaces psutilInstallation============Easy way by using pip:: sudo apt update && sudo apt --yes --force-yes install dnsmasq hostapd python3-dev python3-pip && sudo pip3 install pyaccesspointHard way1. Install system dependencies :: sudo apt update && sudo apt --yes --force-yes install dnsmasq hostapd python3-dev unzip python3-pip2. Download latest package :: cd ~ && wget --output-document=pyaccesspoint-master.zip https://github.com/Goblenus/pyaccesspoint/archive/master.zip3. Unpack downloaded package :: unzip pyaccesspoint-master.zip && cd pyaccesspoint-master4. Install it :: sudo python3 setup.py install5. Remove files :: cd ~ && sudo rm -rf pyaccesspoint-master.zip pyaccesspoint-masterThat is all. Now you can use PyAccessPoint.One line install::: sudo apt update && sudo apt --yes --force-yes install dnsmasq hostapd python3-dev unzip python3-pip && cd ~ && wget --output-document=pyaccesspoint-master.zip https://github.com/Goblenus/pyaccesspoint/archive/master.zip && unzip pyaccesspoint-master.zip && cd pyaccesspoint-master && sudo python3 setup.py install && cd ~ && sudo rm -rf pyaccesspoint-master.zip pyaccesspoint-masterUsage=====You can use it as standalone command line utility:To start:: sudo pyaccesspoint startIt will create hotspot named "MyAccessPoint" on wlan0 with "1234567890" password.All arguments you may obtain by typing::: pyaccesspoint --helpTo stop:: sudo pyaccesspoint stopYou can configure and save config file. This will save you time at them next start:: sudo pyaccesspoint configureYou config file file will be placed at /etc/accesspoint/accesspoint.json. To start it with config file just type::: sudo pyaccesspoint --config startCode usage============1. Import :: from PyAccessPoint import pyaccesspoint2. Create AccessPoint class :: access_point = pyaccesspoint.AccessPoint()3. Start it :: access_point.start()4. Stop it :: access_point.stop()To check is accesspoint started use is_running :: access_point.is_running()You can change accesspoint parameters while creating AccessPoint classClass parameters: - wlan - wlan interface - inet - wlan forward to interface (use None to off forwarding) - ip - just ip of your accesspoint wlan interface - netmask - so... -> (wiki link) - ssid - name of your accesspoint - password - password of your accesspointTested======- OrangePi Plus with Armbian 5.23Note====This project is python3 compatible only, python2 is not tested at all.Idea====This project is fork of https://github.com/prahladyeri/hotspotd (Prahlad Yeri - [email protected])
Package to manage accesspoint on linux
License
Goblenus/pyaccesspoint
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Package to manage accesspoint on linux
Topics
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published