6

I have a raspberrypi ZeroW that I am trying to connect to a network with a hidden ssid. I know that I could add this line "scan_ssid=1" to my wpa_supplicant.conf file for setup that way, however I would like to do all of the network configuration through wpa_cli.

The man page does not seem to have anything on hidden ssid's and when I run the set command it does not provide the output of all the variable options as stated in the man page I just get: "Invalid SET command - at least 2 arguments are required."

tldr: connect to hidden ssid through wpa_cli only

mechpilotace
  • 83
  • 1
  • 7

2 Answers2

7

$ wpa_cli

> add_network 
x
> set_network x ssid "hidden_ssid"
> set_network x psk "secret"
// ALLOW CONNECT TO HIDDEN SSID 
> set_network x scan_ssid 1
> enable_network x
> save_config
> select_network x
ceph3us
  • 557
  • 2
  • 8
  • 22
2

While not quite exactly what I was looking for, I was able to get it running.

This was through Raspbian's rapsi-config utility.

Steps were as follows:

  • Run the rasps-config command with root privileges.
  • Choose the second option: "Network Options"
  • Enter SSID and Passphrase
  • Find and open your "wpa_supplicant.conf" file. Mine is located in /etc/wpa_supplicant/wpa_supplicant.conf
  • Add the following line to the appropriate network: scan_ssid=1. For example:
network={
     ssid="NETWORK_ID"
     scan_ssid=1
     psk="NETWORK_KEY"
}
  • Reboot, and should auto connect to hidden SSID network.
gioele
  • 2,090
  • 2
  • 22
  • 30
mechpilotace
  • 83
  • 1
  • 7