aruba_wlc_clients: use utf8 instead of ascii decoding
General information
Affected devices: WLAN controllers from Aruba
The aruba_wlc_clients check shows how many clients are connected for each SSID.
As far as I know, IEEE 802.11 (correct me if I'm wrong, but I think this was introduced with IEEE 802.11-2007 or IEEE 802.11-2012) specifies that an SSID may contain any UTF-8 character. Limiting it to the ASCII character set would therefore be insufficient and lead to errors.
Bug reports
Information about the system or setup should be unimportant, as the error can be reproduced completely independently of the setup and we are talking about a standard here.
Example with ASCII encoding:
>>> bytes(int(x) for x in "11.195.164".split(".")[1:]).decode("ascii")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 0: ordinal not in range(128)
Proposed changes
UTF-8 is used instead of ASCII encoding. I don't think this would break any running system.
>>> bytes(int(x) for x in "11.195.164".split(".")[1:]).decode("utf8")
'ä'
All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.
I have read the CLA Document and I hereby sign the CLA or my organization already has a signed CLA.
recheck
Hey mabezi, this PR will be released with Werk #17497 / 2eb74bb2e198f26629ca8ad7bf90bfb02dc58b56. Thanks a lot for your support!