Browse Source

Can connect to any open wifi

Bob Mottram 8 years ago
parent
commit
4815dcc806
1 changed files with 5 additions and 1 deletions
  1. 5
    1
      src/freedombone-utils-wifi

+ 5
- 1
src/freedombone-utils-wifi View File

370
     fi
370
     fi
371
 
371
 
372
     echo 'update_config=1' > $WIFI_CONFIG
372
     echo 'update_config=1' > $WIFI_CONFIG
373
+    echo 'ap_scan=2' >> $WIFI_CONFIG
374
+    echo 'eapol_version=1' >> $WIFI_CONFIG
373
     echo '' >> $WIFI_CONFIG
375
     echo '' >> $WIFI_CONFIG
374
 
376
 
375
     ctr=0
377
     ctr=0
384
                     WIFI_TYPE="$line"
386
                     WIFI_TYPE="$line"
385
                     if [[ $WIFI_TYPE == $'none' || $WIFI_TYPE == $'open' ]]; then
387
                     if [[ $WIFI_TYPE == $'none' || $WIFI_TYPE == $'open' ]]; then
386
                         echo 'network={' >> $WIFI_CONFIG
388
                         echo 'network={' >> $WIFI_CONFIG
387
-                        echo "  ssid=\"${WIFI_SSID}\"" >> $WIFI_CONFIG
389
+                        if [[ "${WIFI_SSID}" != $'any' && "${WIFI_SSID}" != $'all' && "${WIFI_SSID}" != $'open' ]]; then
390
+                            echo "  ssid=\"${WIFI_SSID}\"" >> $WIFI_CONFIG
391
+                        fi
388
                         echo '  key_mgmt=NONE' >> $WIFI_CONFIG
392
                         echo '  key_mgmt=NONE' >> $WIFI_CONFIG
389
                         echo '}' >> $WIFI_CONFIG
393
                         echo '}' >> $WIFI_CONFIG
390
                         ctr=0
394
                         ctr=0