diff options
author | Beniamino Galvani <bgalvani@redhat.com> | 2023-03-22 10:21:30 +0100 |
---|---|---|
committer | Beniamino Galvani <bgalvani@redhat.com> | 2023-03-28 09:46:11 +0200 |
commit | ac2fb0e93d1a7c9c41eba5c77e7e62a9eb07691b (patch) | |
tree | cd1203a8eec496ed41bd348ba16b289583c038e1 | |
parent | 1399aa925d1c0575886b71ec5b80561d35242e9a (diff) | |
download | NetworkManager-ac2fb0e93d1a7c9c41eba5c77e7e62a9eb07691b.tar.gz |
nmcli: fix generating hotspot password
The generated password was all non-alphanumeric characters.
Fixes: 6e96d7173168 ('all: use nm_random_*() instead of g_random_*()')
-rw-r--r-- | src/nmcli/devices.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nmcli/devices.c b/src/nmcli/devices.c index 6e7affdf18..69dc0db864 100644 --- a/src/nmcli/devices.c +++ b/src/nmcli/devices.c @@ -4111,7 +4111,7 @@ generate_wpa_key(char *key, size_t len) do { c = nm_random_u64_range_full(33, 126, TRUE); /* too many non alphanumeric characters are hard to remember for humans */ - } while (g_ascii_isalnum(c)); + } while (!g_ascii_isalnum(c)); key[i] = (char) c; } |