summaryrefslogtreecommitdiff
path: root/package/network/utils/iwinfo/src/iwinfo_nl80211.c
Commit message (Collapse)AuthorAgeFilesLines
* package/network/utils: probably from OpenWRTLudovic Pouzenc2018-09-161-3/+69
|
* package: fix segfault of iwinfo.scanlist("radio0").Jo-Philipp Wich2014-08-121-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | This is a bug revealed in r41830. First, the static variable `char nif[IFNAMSIZ]` of nl80211_phy2ifname() would be zeroed out if the argument is "wlan0" or the like. This will happen in the following call stack. nl80211_get_scanlist("radio0", buf, len); nl80211_phy2ifname("radio0") // return static var nif with content "wlan0" nl80211_get_scanlist(nif, buf, len); // tail call nl80211_get_mode(nif); nl80211_phy2ifname(nif); // zero out nif Later we try nl80211_ifadd("") which was supposed to create interface "tmp.", but that won't happen because nl80211_msg() will put an invalid ifidx 0 to the nlmsg. Then iwinfo_ifup() and iwinfo_ifdown() would fail and happily nl80211_get_scanlist() returned 0 and left *len undefined. Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com> SVN-Revision: 42151
* iwinfo: allow scans in AP mode on nl80211Felix Fietkau2014-08-061-0/+1
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 42014
* iwinfo: add missing include statementFelix Fietkau2014-08-031-0/+1
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 41955
* iwinfo: avoid creating tmp.* ifaces for scanningJo-Philipp Wich2014-07-251-2/+22
| | | | | | | | | | | | If the iface to scan on already is in ad-hoc, station or monitor mode then do not spawn a temporary iface. Also preventively disable IPv6 on temporary ifaces before bringing them up to avoid potential security issues. Signed-off-by: Jo-Philipp Wich <jow@openwrt.org> SVN-Revision: 41830
* iwinfo: continue scanning even if temporary mac cannot be changedJo-Philipp Wich2014-07-251-2/+1
| | | | | | | | | | So far iwinfo aborted a wifi scan attempt if the mac of the spawned interface could not be changed. Change the code to try anyway - this should fix wifi scanning on RaLink devices. Signed-off-by: Jo-Philipp Wich <jow@openwrt.org> SVN-Revision: 41826
* iwinfo: add 802.11ac hwmode supportJohn Crispin2014-06-021-1/+9
| | | | | | | | | | In case of .11ac device the hwmode was not properly displayed. This patch fixes it. Signed-off-by: Marek Kwaczynski <marek.kwaczynski@tieto.com> Signed-off-by: Bartosz Markowski <bartosz.markowski@tieto.com> SVN-Revision: 40953
* iwinfo: null-terminate the ssid on nl80211 scan to avoid printing trailing ↵Felix Fietkau2014-05-301-1/+4
| | | | | | | | garbage Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 40884
* iwinfo: move nl80211_ops to iwinfo_nl80211.c, make functions staticFelix Fietkau2014-05-211-155/+185
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 40812
* iwinfo: move wext_ops to iwinfo_wext.c, make functions staticFelix Fietkau2014-05-211-5/+4
| | | | | | Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 40810
* iwinfo: adjust for changed wpa_supplicant control socket pathJo-Philipp Wich2014-05-101-1/+7
| | | | | | Signed-off-by: Jo-Philipp Wich <jow@openwrt.org> SVN-Revision: 40747
* iwinfo: when using nl80211, parse interface combinations instead of ↵Felix Fietkau2013-09-141-9/+57
| | | | | | | | creating/deleting interfaces Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 37983
* iwinfo: add phyname attribute, this is useful to group networks by radio phyJo-Philipp Wich2013-06-091-0/+25
| | | | SVN-Revision: 36889
* libiwinfo: ignore log messages from wpa_supplicant while scanningJo-Philipp Wich2013-06-091-16/+47
| | | | | | | | | | | | | | | wpa_supplicant may send log and event messages intermixed with the expected scan results. This makes "iwinfo wlan0 scan" and LuCI "site survey" display nothing when many AP's are around. Eliminate the CTRL-EVENT-BSS-ADDED events, interspersed log messages, lines with unexpected format. Increase timeout to handle the max number of channels (2.4, 3.6, 4.9, 5 GHz). Insure receive buffer is null-terminated. Signed-off-by: Jean-Pierre Tosoni <jp.tosoni@acksys.fr> SVN-Revision: 36888
* iwinfo: only consider joined bss when finding current operating frequency, ↵Jo-Philipp Wich2013-05-121-1/+2
| | | | | | fixes spurious misreporting of frequencies in ad-hoc mode SVN-Revision: 36604
* iwinfo: add SR71-15 radio info, fix nl80211 channel/frequency reporting on ↵Jo-Philipp Wich2013-04-241-2/+3
| | | | | | some architectures SVN-Revision: 36417
* iwinfo: fix frequency/channel and channel/frequency conversions to properly ↵Jo-Philipp Wich2013-04-091-12/+19
| | | | | | implement 802.11j SVN-Revision: 36292
* iwinfo: don't use the txpower value from debugfs for now, it does not match ↵Jo-Philipp Wich2013-01-041-0/+2
| | | | | | the values reported via wext SVN-Revision: 35007
* iwinfo: replace more wext calls with nl80211 equivalents, attempt to infer ↵Jo-Philipp Wich2013-01-021-64/+226
| | | | | | nl80211 tx power from debugfs before querying wext SVN-Revision: 34982
* iwinfo: properly initialize memory of global nl80211_state, fixes random ↵Jo-Philipp Wich2012-10-291-0/+2
| | | | | | libnl-tiny assertions when using nl80211_probe() on not supported devices SVN-Revision: 34003
* packages: sort network related packages into package/network/Felix Fietkau2012-10-101-0/+2080
SVN-Revision: 33688