12-24-2021, 06:02 PM
(This post was last modified: 12-24-2021, 08:14 PM by TheOldPresbyope.
Edit Reason: second bullet shouldn't imply psk is exchanged
)
(12-24-2021, 04:58 PM)phorize Wrote: ...
20211217 194231 worker: wlan0 wait 43 for IP address
20211217 194233 worker: wlan0 wait 44 for IP address
20211217 194235 worker: wlan0 no IP addr for SSID
20211217 194235 worker: wlan0 AP mode started
20211217 194308 worker: wlan0 wait 0 for IP address
20211217 194310 worker: wlan0 wait 1 for IP address
20211217 194312 worker: wlan0 wait 2 for IP address
20211217 194314 worker: IP addr (172.24.1.1)
20211217 194314 worker: Netmask (255.255.255.0)
20211217 194314 worker: Gateway (0.0.0.0)
20211217 194314 worker: Pri DNS (127.0.0.1)
20211217 194314 worker: Domain (None)
20211217 194314 worker: Pi integrated wlan0 power save disabled
...
This is exactly the response I would expect if
- no AP with the given SSID responds (because, say, an incorrect SSID was entered manually), or
- an AP with the given SSID responds but it doesn't agree with the 256-bit psk it receives from moOde (because, say, an incorrect passphrase---aka password---wsa entered)
- an AP with the given SSID responds but, based on a complicated handshake performed during association, it doesn't agree that it and moOde are using the same 256-bit psk (because, say, an incorrect passphrase---aka password---was entered in moOde).
A note about WiFi language: what moOde and many other software systems call the password is a passphrase in Wifi parlance. It plays no role in the actual Wireless Protected Access (WPA) exchanges. Rather it is a human-readable string from which the 256-bit pre-shared key (psk) can be computed using the SSID as a salt value and running an agreed algorithm. It is this psk which is stored and exchanged used for data exchanges between WiFi clients/APs. [see, for example, https://en.wikipedia.org/wiki/Wi-Fi_Protected_Access]
The 256-bit psk is frequently shown in its hexadecimal form as a string of 64 hexadecimal digits. It is this hex string which is displayed in the moOde Password window after "save" is clicked. Just like the passphrase, the psk should never be published/posted/left in a github repo, etc.
You can check the psk calculation for yourself using the Linux command wpa_passphrase. Refer to its man page.
Made-up example:
AP SSID: Whoville
passphrase: You're a mean one, Mister Grinch
Code:
kreed@T520:~$ wpa_passphrase Whoville "You're a mean one, Mister Grinch"
network={
ssid="Whoville"
#psk="You're a mean one, Mister Grinch"
psk=cee88f2390c75cbd7e3cbc8c81f9ebe83ec8009f97fd19981c0bbb58d5aa1cea
This 64-character psk value should be the same as the "password" value displayed in moOde after saving.
Note that the quotation marks are not part of my whimsical passphrase value just as they aren't part of my ssid value. However, a quotation mark is a legal character in passphrases. AFAICT, these days the net-config.php code in moOde correctly deals with spaces and punctuation marks.
Regards,
Kent