Re: WPS support in hostapd

2015-04-11 Thread Nelson Leung
Thanks. Then I didn't have to work on this.

On Sun, Apr 12, 2015 at 2:07 AM, Adrian Chadd adr...@freebsd.org wrote:

 nl80211 is the linux wifi code.



 -adrian

___
freebsd-wireless@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to freebsd-wireless-unsubscr...@freebsd.org


Re: WPS support in hostapd

2015-04-11 Thread Adrian Chadd
nl80211 is the linux wifi code.



-adrian
___
freebsd-wireless@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to freebsd-wireless-unsubscr...@freebsd.org


WPS support in hostapd

2015-04-11 Thread Nelson Leung
Hi,

I have a WiFi printer which supports only WPS (by push button)  and I am
trying to get it connected to my FreeBSD AP (Freebsd 9.3-RELEASE-p10).

The only information I found is the instructions in the latest version in
hostapd on setting up WPS.
http://w1.fi/cgit/hostap/plain/hostapd/README-WPS
http://w1.fi/cgit/hostap/plain/hostapd/hostapd.conf

So I compiled and installed the hostapd from the port.
Since make config didn't have the options for enabling WPS,
I uncommented the lines directly in the files/config:
CONFIG_WPS=Y
CONFIG_WPS_UPNP=Y

I followed the instructions in the README.WPS and try to connect by push
button.
There are no errors reported from hostapd, but I cannot connect the device
to the AP via WPS.

This is what I did in FreeBSD to initiate the WPS:
# hostapd_cli
hostapd_cli v2.4
Copyright (c) 2004-2015, Jouni Malinen j...@w1.fi and contributors

This software may be distributed under the terms of the BSD license.
See README for more details.


Selected interface 'wlan0'

Interactive mode

 wps_pbc
3WPS-PBC-ACTIVE
OK
 wps_get_status
PBC Status: Active
Last WPS result: None
 3WPS-TIMEOUT

 wps_get_status
PBC Status: Timed-out
Last WPS result: None


The WPS button on the device is pushed right after wps_pbc
But both are timed out.

This is my current hostapd.conf:
# vi /etc/hostapd.conf
interface=wlan0
driver=bsd
logger_syslog=-1
logger_syslog_level=0
logger_stdout=-1
logger_stdout_level=0
debug=3
dump_file=/tmp/hostapd.dump
ctrl_interface=/var/run/hostapd
ctrl_interface_group=wheel
 IEEE 802.11 related config 
ssid=**MASKED**
macaddr_acl=0
auth_algs=1
 IEEE 802.1X related config 
ieee8021x=0
 WPA/IEEE 802.11i config #
wpa=2
wpa_passphrase=**MASKED**
wpa_key_mgmt=WPA-PSK
wpa_pairwise=CCMP TKIP

#WPS related config
#Per PSK for each WPS client
wpa_psk_file=/etc/hostapd.psk

# Enable internal EAP server for EAP-WSC (part of Wi-Fi Protected Setup)
eap_server=1
# WPS configuration (AP configured, do not allow external WPS Registrars)
wps_state=2
ap_setup_locked=1
# If UUID is not configured, it will be generated based on local MAC
address.
#uuid=87654321-9abc-def0-1234-56789abc
wps_pin_requests=/var/run/hostapd.pin-req
device_name=Wireless AP
manufacturer=Company
model_name=WAP
model_number=123
serial_number=12345
device_type=6-0050F204-1
os_version=01020300
config_methods=label display push_button keypad
pbc_in_m1=1


Any help is much appreciated.

Thanks,
Nelson Leung
___
freebsd-wireless@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to freebsd-wireless-unsubscr...@freebsd.org


Re: WPS support in hostapd

2015-04-11 Thread Adrian Chadd
Which NIC is it?

(I've never used WPS.)



-a


On 11 April 2015 at 10:46, Nelson Leung nelson4...@gmail.com wrote:
 Hi,

 I have a WiFi printer which supports only WPS (by push button)  and I am
 trying to get it connected to my FreeBSD AP (Freebsd 9.3-RELEASE-p10).

 The only information I found is the instructions in the latest version in
 hostapd on setting up WPS.
 http://w1.fi/cgit/hostap/plain/hostapd/README-WPS
 http://w1.fi/cgit/hostap/plain/hostapd/hostapd.conf

 So I compiled and installed the hostapd from the port.
 Since make config didn't have the options for enabling WPS,
 I uncommented the lines directly in the files/config:
 CONFIG_WPS=Y
 CONFIG_WPS_UPNP=Y

 I followed the instructions in the README.WPS and try to connect by push
 button.
 There are no errors reported from hostapd, but I cannot connect the device
 to the AP via WPS.

 This is what I did in FreeBSD to initiate the WPS:
 # hostapd_cli
 hostapd_cli v2.4
 Copyright (c) 2004-2015, Jouni Malinen j...@w1.fi and contributors

 This software may be distributed under the terms of the BSD license.
 See README for more details.


 Selected interface 'wlan0'

 Interactive mode

 wps_pbc
 3WPS-PBC-ACTIVE
 OK
 wps_get_status
 PBC Status: Active
 Last WPS result: None
 3WPS-TIMEOUT

 wps_get_status
 PBC Status: Timed-out
 Last WPS result: None


 The WPS button on the device is pushed right after wps_pbc
 But both are timed out.

 This is my current hostapd.conf:
 # vi /etc/hostapd.conf
 interface=wlan0
 driver=bsd
 logger_syslog=-1
 logger_syslog_level=0
 logger_stdout=-1
 logger_stdout_level=0
 debug=3
 dump_file=/tmp/hostapd.dump
 ctrl_interface=/var/run/hostapd
 ctrl_interface_group=wheel
  IEEE 802.11 related config 
 ssid=**MASKED**
 macaddr_acl=0
 auth_algs=1
  IEEE 802.1X related config 
 ieee8021x=0
  WPA/IEEE 802.11i config #
 wpa=2
 wpa_passphrase=**MASKED**
 wpa_key_mgmt=WPA-PSK
 wpa_pairwise=CCMP TKIP

 #WPS related config
 #Per PSK for each WPS client
 wpa_psk_file=/etc/hostapd.psk

 # Enable internal EAP server for EAP-WSC (part of Wi-Fi Protected Setup)
 eap_server=1
 # WPS configuration (AP configured, do not allow external WPS Registrars)
 wps_state=2
 ap_setup_locked=1
 # If UUID is not configured, it will be generated based on local MAC
 address.
 #uuid=87654321-9abc-def0-1234-56789abc
 wps_pin_requests=/var/run/hostapd.pin-req
 device_name=Wireless AP
 manufacturer=Company
 model_name=WAP
 model_number=123
 serial_number=12345
 device_type=6-0050F204-1
 os_version=01020300
 config_methods=label display push_button keypad
 pbc_in_m1=1


 Any help is much appreciated.

 Thanks,
 Nelson Leung
 ___
 freebsd-wireless@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-wireless
 To unsubscribe, send any mail to freebsd-wireless-unsubscr...@freebsd.org
___
freebsd-wireless@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to freebsd-wireless-unsubscr...@freebsd.org


Re: WPS support in hostapd

2015-04-11 Thread Nelson Leung
Hi,

This is what I get from pciconf:
ath0@pci0:5:0:0:class=0x02 card=0x2055168c chip=0x001d168c
rev=0x01 hdr=0x00
vendor = 'Atheros Communications Inc.'
device = 'AR5007G Wireless Network Adapter'
class  = network
subclass   = ethernet


I just found the example is using nl80211 as the driver in hostapd.conf, so
I am trying this.
But enabling nl80211 support in hostapd requires libnl, which is not found
in /usr/port.

Do you have any idea on this?

Thanks!


On Sun, Apr 12, 2015 at 1:53 AM, Adrian Chadd adr...@freebsd.org wrote:

 Which NIC is it?

 (I've never used WPS.)



 -a


 On 11 April 2015 at 10:46, Nelson Leung nelson4...@gmail.com wrote:
  Hi,
 
  I have a WiFi printer which supports only WPS (by push button)  and I am
  trying to get it connected to my FreeBSD AP (Freebsd 9.3-RELEASE-p10).
 
  The only information I found is the instructions in the latest version in
  hostapd on setting up WPS.
  http://w1.fi/cgit/hostap/plain/hostapd/README-WPS
  http://w1.fi/cgit/hostap/plain/hostapd/hostapd.conf
 
  So I compiled and installed the hostapd from the port.
  Since make config didn't have the options for enabling WPS,
  I uncommented the lines directly in the files/config:
  CONFIG_WPS=Y
  CONFIG_WPS_UPNP=Y
 
  I followed the instructions in the README.WPS and try to connect by push
  button.
  There are no errors reported from hostapd, but I cannot connect the
 device
  to the AP via WPS.
 
  This is what I did in FreeBSD to initiate the WPS:
  # hostapd_cli
  hostapd_cli v2.4
  Copyright (c) 2004-2015, Jouni Malinen j...@w1.fi and contributors
 
  This software may be distributed under the terms of the BSD license.
  See README for more details.
 
 
  Selected interface 'wlan0'
 
  Interactive mode
 
  wps_pbc
  3WPS-PBC-ACTIVE
  OK
  wps_get_status
  PBC Status: Active
  Last WPS result: None
  3WPS-TIMEOUT
 
  wps_get_status
  PBC Status: Timed-out
  Last WPS result: None
 
 
  The WPS button on the device is pushed right after wps_pbc
  But both are timed out.
 
  This is my current hostapd.conf:
  # vi /etc/hostapd.conf
  interface=wlan0
  driver=bsd
  logger_syslog=-1
  logger_syslog_level=0
  logger_stdout=-1
  logger_stdout_level=0
  debug=3
  dump_file=/tmp/hostapd.dump
  ctrl_interface=/var/run/hostapd
  ctrl_interface_group=wheel
   IEEE 802.11 related config 
  ssid=**MASKED**
  macaddr_acl=0
  auth_algs=1
   IEEE 802.1X related config 
  ieee8021x=0
   WPA/IEEE 802.11i config #
  wpa=2
  wpa_passphrase=**MASKED**
  wpa_key_mgmt=WPA-PSK
  wpa_pairwise=CCMP TKIP
 
  #WPS related config
  #Per PSK for each WPS client
  wpa_psk_file=/etc/hostapd.psk
 
  # Enable internal EAP server for EAP-WSC (part of Wi-Fi Protected Setup)
  eap_server=1
  # WPS configuration (AP configured, do not allow external WPS Registrars)
  wps_state=2
  ap_setup_locked=1
  # If UUID is not configured, it will be generated based on local MAC
  address.
  #uuid=87654321-9abc-def0-1234-56789abc
  wps_pin_requests=/var/run/hostapd.pin-req
  device_name=Wireless AP
  manufacturer=Company
  model_name=WAP
  model_number=123
  serial_number=12345
  device_type=6-0050F204-1
  os_version=01020300
  config_methods=label display push_button keypad
  pbc_in_m1=1
 
 
  Any help is much appreciated.
 
  Thanks,
  Nelson Leung
  ___
  freebsd-wireless@freebsd.org mailing list
  http://lists.freebsd.org/mailman/listinfo/freebsd-wireless
  To unsubscribe, send any mail to 
 freebsd-wireless-unsubscr...@freebsd.org

___
freebsd-wireless@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to freebsd-wireless-unsubscr...@freebsd.org