Difference between revisions of "Low Level API specification"

From PRPL
Jump to: navigation, search
(Created page with "== cfg80211 driver for WLAN == PLEASE FILL IN API DETAILS == hostapd == PLEASE FILL IN API DETAILS == wpa_supplicant == wpa_supplicant - Wi-Fi Protected Access client and IE...")
 
(hostapd)
Line 3: Line 3:
  
 
== hostapd ==
 
== hostapd ==
PLEASE FILL IN API DETAILS
+
 
 +
=== SYNOPSIS ===
 +
    hostapd [-BdhKtv] config-file ...
 +
 
 +
=== DESCRIPTION ===
 +
The hostapd utility is an authenticator for IEEE 802.11 networks.  It
 +
provides full support for WPA/IEEE  802.11i  and can  also act as an IEEE
 +
802.1X Authenticator with a suitable backend Authentication Server  (typi-
 +
cally FreeRADIUS).  The hostapd utility implements  the authentication
 +
protocols that piggyback on top of  the normal IEEE  802.11 protocol  mecha-
 +
nisms.  To  use hostapd as an authenticator, the underlying  device must
 +
support some basic  functionality such as the ability to set security
 +
information in the  802.11 management frames.  Beware that not all devices
 +
have this support.
 +
 
 +
The hostapd utility is designed to  be a ``daemon''  program  that runs in
 +
the background and  acts as  the backend component controlling the wireless
 +
connection.  It supports separate frontend  programs such as the text-
 +
based frontend, hostapd_cli(8).
 +
 
 +
The following arguments must be specified on the command line:
 +
 
 +
''config-file''
 +
:Use the settings in the specified configuration file; the name of
 +
:the specified wireless interface is contained in this file.  See
 +
:hostapd.conf(5) for a description of the configuration file syn-
 +
:tax.
 +
 
 +
 
 +
:Changes to  the configuration file can be reloaded by sending a
 +
:SIGHUP to the hostapd processor or  with the hostapd_cli(8) utility,
 +
:using  ``hostapd_cli reconfigure''.
 +
 
 +
=== OPTIONS ===
 +
 
 +
The options are as follows:
 +
 
 +
'''-d''' Enable debugging messages.  If this option  is supplied twice, more verbose messages are displayed.
 +
 
 +
'''-h''' Show help text.
 +
 
 +
'''-t''' Include timestamps  in debugging output.
 +
 
 +
'''-v''' Display version information on the  terminal and exit.
 +
 
 +
'''-B''' Detach from the controlling terminal and run as a daemon process in the background.
 +
 
 +
'''-K''' Include key information in  debugging output.
  
 
== wpa_supplicant ==
 
== wpa_supplicant ==

Revision as of 14:50, 17 November 2017

cfg80211 driver for WLAN

PLEASE FILL IN API DETAILS

hostapd

SYNOPSIS

    hostapd [-BdhKtv] config-file ...

DESCRIPTION

The hostapd utility is an authenticator for IEEE 802.11 networks. It provides full support for WPA/IEEE 802.11i and can also act as an IEEE 802.1X Authenticator with a suitable backend Authentication Server (typi- cally FreeRADIUS). The hostapd utility implements the authentication protocols that piggyback on top of the normal IEEE 802.11 protocol mecha- nisms. To use hostapd as an authenticator, the underlying device must support some basic functionality such as the ability to set security information in the 802.11 management frames. Beware that not all devices have this support.

The hostapd utility is designed to be a ``daemon program that runs in the background and acts as the backend component controlling the wireless connection. It supports separate frontend programs such as the text- based frontend, hostapd_cli(8).

The following arguments must be specified on the command line:

config-file

Use the settings in the specified configuration file; the name of
the specified wireless interface is contained in this file. See
hostapd.conf(5) for a description of the configuration file syn-
tax.


Changes to the configuration file can be reloaded by sending a
SIGHUP to the hostapd processor or with the hostapd_cli(8) utility,
using ``hostapd_cli reconfigure.

OPTIONS

The options are as follows:

-d Enable debugging messages. If this option is supplied twice, more verbose messages are displayed.

-h Show help text.

-t Include timestamps in debugging output.

-v Display version information on the terminal and exit.

-B Detach from the controlling terminal and run as a daemon process in the background.

-K Include key information in debugging output.

wpa_supplicant

wpa_supplicant - Wi-Fi Protected Access client and IEEE 802.1X supplicant

Synopsis

wpa_supplicant [ -BddfhKLqqtuvW ] [ -iifname ] [ -cconfig file ] [ -Ddriver ] [ -PPID_file ] [ -foutput file ]

Overview

Wireless networks do not require physical access to the network equipment in the same way as wired networks. This makes it easier for unauthorized users to passively monitor a network and capture all transmitted frames. In addition, unauthorized use of the network is much easier. In many cases, this can happen even without user's explicit knowledge since the wireless LAN adapter may have been configured to automatically join any available network.

Link-layer encryption can be used to provide a layer of security for wireless networks. The original wireless LAN standard, IEEE 802.11, included a simple encryption mechanism, WEP. However, that proved to be flawed in many areas and network protected with WEP cannot be consider secure. IEEE 802.1X authentication and frequently changed dynamic WEP keys can be used to improve the network security, but even that has inherited security issues due to the use of WEP for encryption. Wi-Fi Protected Access and IEEE 802.11i amendment to the wireless LAN standard introduce a much improvement mechanism for securing wireless networks. IEEE 802.11i enabled networks that are using CCMP (encryption mechanism based on strong cryptographic algorithm AES) can finally be called secure used for applications which require efficient protection against unauthorized access.

wpa_supplicant is an implementation of the WPA Supplicant component, i.e., the part that runs in the client stations. It implements WPA key negotiation with a WPA Authenticator and EAP authentication with Authentication Server. In addition, it controls the roaming and IEEE 802.11 authentication/association of the wireless LAN driver.

wpa_supplicant is designed to be a "daemon" program that runs in the background and acts as the backend component controlling the wireless connection. wpa_supplicant supports separate frontend programs and an example text-based frontend, wpa_cli, is included with wpa_supplicant.

Before wpa_supplicant can do its work, the network interface must be available. That means that the physical device must be present and enabled, and the driver for the device must be loaded. The daemon will exit immediately if the device is not already available.

After wpa_supplicant has configured the network device, higher level configuration such as DHCP may proceed. There are a variety of ways to integrate wpa_supplicant into a machine's networking scripts, a few of which are described in sections below.

The following steps are used when associating with an AP using WPA:

  • wpa_supplicant requests the kernel driver to scan neighboring BSSes
  • wpa_supplicant selects a BSS based on its configuration
  • wpa_supplicant requests the kernel driver to associate with the chosen BSS
  • If WPA-EAP: integrated IEEE 802.1X Supplicant completes EAP authentication with the authentication server (proxied by the Authenticator in the AP)
  • If WPA-EAP: master key is received from the IEEE 802.1X Supplicant
  • If WPA-PSK: wpa_supplicant uses PSK as the master session key
  • wpa_supplicant completes WPA 4-Way Handshake and Group Key Handshake with the Authenticator (AP)
  • wpa_supplicant configures encryption keys for unicast and broadcast
  • normal data packets can be transmitted and received

Supported Features

Supported WPA/IEEE 802.11i features:

  • WPA-PSK ("WPA-Personal")
  • WPA with EAP (e.g., with RADIUS authentication server) ("WPA-Enterprise") Following authentication methods are supported with an integrate IEEE 802.1X Supplicant:

EAP-TLS

  • EAP-PEAP/MSCHAPv2 (both PEAPv0 and PEAPv1)
  • EAP-PEAP/TLS (both PEAPv0 and PEAPv1)
  • EAP-PEAP/GTC (both PEAPv0 and PEAPv1)
  • EAP-PEAP/OTP (both PEAPv0 and PEAPv1)
  • EAP-PEAP/MD5-Challenge (both PEAPv0 and PEAPv1)
  • EAP-TTLS/EAP-MD5-Challenge
  • EAP-TTLS/EAP-GTC
  • EAP-TTLS/EAP-OTP
  • EAP-TTLS/EAP-MSCHAPv2
  • EAP-TTLS/EAP-TLS
  • EAP-TTLS/MSCHAPv2
  • EAP-TTLS/MSCHAP
  • EAP-TTLS/PAP
  • EAP-TTLS/CHAP
  • EAP-SIM
  • EAP-AKA
  • EAP-PSK
  • EAP-PAX
  • LEAP (note: requires special support from the driver for IEEE 802.11 authentication)

(following methods are supported, but since they do not generate keying material, they cannot be used with WPA or IEEE 802.1X WEP keying)

  • EAP-MD5-Challenge
  • EAP-MSCHAPv2
  • EAP-GTC

EAP-OTP

  • key management for CCMP, TKIP, WEP104, WEP40
  • RSN/WPA2 (IEEE 802.11i)
  • pre-authentication
  • PMKSA caching

Available Drivers

A summary of available driver backends is below. Support for each of the driver backends is chosen at wpa_supplicant compile time. For a list of supported driver backends that may be used with the -D option on your system, refer to the help output of wpa_supplicant (wpa_supplicant -h).

  • hostap
(default) Host AP driver (Intersil Prism2/2.5/3). (this can also be used with Linuxant DriverLoader).
  • hermes
Agere Systems Inc. driver (Hermes-I/Hermes-II).
  • madwifi
MADWIFI 802.11 support (Atheros, etc.).
  • atmel
ATMEL AT76C5XXx (USB, PCMCIA).
  • wext
Linux wireless extensions (generic).
  • ndiswrapper
Linux ndiswrapper.
  • broadcom
Broadcom wl.o driver.
  • ipw
Intel ipw2100/2200 driver.
  • wired
wpa_supplicant wired Ethernet driver
  • roboswitch
wpa_supplicant Broadcom switch driver
  • bsd
BSD 802.11 support (Atheros, etc.).
  • ndis
Windows NDIS driver.

Command Line Options

Most command line options have global scope. Some are given per interface, and are only valid if at least one -i option is specified, otherwise they're ignored. Option groups for different interfaces must be separated by -N option.

-b br_ifname

Optional bridge interface name. (Per interface)

-B

Run daemon in the background.

-c filename

Path to configuration file. (Per interface)

-C ctrl_interface

Path to ctrl_interface socket (Per interface. Only used if -c is not).

-i ifname

Interface to listen on. Multiple instances of this option can be present, one per interface, separated by -N option (see below).

-d

Increase debugging verbosity (-dd even more).

-D driver

Driver to use (can be multiple drivers: nl80211,wext). (Per interface, see the available options below.)

-f output file

Log output to specified file instead of stdout.

-g global ctrl_interface

Path to global ctrl_interface socket. If specified, interface definitions may be omitted.

-K

Include keys (passwords, etc.) in debug output.

-t

Include timestamp in debug messages.

-h

Help. Show a usage message.

-L

Show license (GPL and BSD).

-p

Driver parameters. (Per interface)

-P PID_file

Path to PID file.

-q

Decrease debugging verbosity (-q q even less).

-u

Enabled DBus control interface. If enabled, interface definitions may be omitted.

-v

Show version.

-W

Wait for a control interface monitor before starting.

-N

Start describing new interface.

iw support with WLAN management frames transmitted via nl80211

PLEASE FILL IN API DETAILS