- case "${encryption_mode}" in
- # For WPA*, the key must be between 8 and 63 chars
- WPA2-PSK|WPA2-PSK-SHA256|WPA-PSK|WPA-PSK-SHA256)
- if [ ${l} -ge 8 ] && [ ${l} -le 63 ]; then
- return ${EXIT_TRUE}
- fi
+ # For WPA*, the key must be between 8 and 63 chars
+ if [ ${l} -lt 8 ] || [ ${l} -gt 63 ]; then
+ return ${EXIT_FALSE}
+ fi