[2.2, 2.1] ssh key comment contains unicode character - node deployment fails
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MAAS |
Invalid
|
High
|
Unassigned | ||
curtin |
Invalid
|
Undecided
|
Unassigned |
Bug Description
if one of the MAAS admin ssh keys contains in the ssh comment the unicode charakter Unicode Character 'RIGHT SINGLE QUOTATION MARK' (U+2019) (see: http://
gui-log:
---
Node changed status - From 'Deploying' to 'Failed deployment' Mon, 27 Feb. 2017 15:52:22
Marking node failed - Installation failed (refer to the installation log for more information). Mon, 27 Feb. 2017 15:52:22
Node installation failure - 'cloudinit' running modules for final Mon, 27 Feb. 2017 15:52:22
Node installation failure - 'cloudinit' running config-
PXE Request - installation Mon, 27 Feb. 2017 15:49:08
---
installation log excerpt via gui:
---
Traceback (most recent call last):
File "/curtin/
contents = util.load_file(cfg)
File "/curtin/
return fp.read(read_len) if read_len else fp.read()
File "/usr/lib/
return codecs.
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 277: ordinal not in range(128)
Injecting fix for ipv6 mtu settings: /tmp/tmpboc7vlo
---
when the key is removed nodes can be deployed normally again.
MAAS versions:
root@ba0b1a-
Desired=
| Status=
|/ Err?=(none)
||/ Name Version Architecture Description
+++-===
un maas <none> <none> (no description available)
ii maas-cli 2.1.3+bzr5573-
ii maas-common 2.1.3+bzr5573-
ii maas-dns 2.1.3+bzr5573-
ii maas-proxy 2.1.3+bzr5573-
ii maas-region-api 2.1.3+bzr5573-
ii maas-region-
un maas-region-
un python-django-maas <none> <none> (no description available)
un python-maas-client <none> <none> (no description available)
ii python3-django-maas 2.1.3+bzr5573-
ii python3-maas-client 2.1.3+bzr5573-
ii python3-
/var/log/maas/* is available upon request
replicate bug:
1. add key via cli:
dtadmin@
Success.
Machine-readable output follows:
{
"id": 22,
"key": "ssh-rsa AAAAB3NzaC1yc2E
"keysource": null
}
2. deploy a node
3. remove this key:
dtadmin@
Success.
4. deploy node again
relevant key part:
dtadmin@
00000000 73 73 68 2d 72 73 61 20 41 41 41 41 42 33 4e 7a |ssh-rsa AAAAB3Nz|
[...]
00000170 57 49 45 4c 37 6d 30 52 39 36 62 5a 20 50 65 e2 |WIEL7m0R96bZ Pe.|
00000180 80 99 65 72 20 50 69 70 65 72 20 7c 20 4d 61 73 |..er Piper | Mas|
[...]
Changed in maas: | |
milestone: | none → 2.2.0 |
importance: | Undecided → High |
status: | New → Triaged |
summary: |
- ssh key comment contains unicode character - node deployment fails + [2.2, 2.1] ssh key comment contains unicode character - node deployment + fails |
Changed in maas: | |
milestone: | 2.2.0 → 2.2.0rc2 |
Changed in maas: | |
milestone: | 2.2.0rc2 → 2.2.0rc3 |
Changed in maas: | |
assignee: | nobody → Данило Шеган (danilo) |
status: | Triaged → In Progress |
Changed in maas: | |
milestone: | 2.2.0rc3 → 2.2.0rc4 |
Changed in maas: | |
milestone: | 2.2.0rc4 → 2.2.1 |
Changed in maas: | |
milestone: | 2.2.1 → 2.2.x |
Changed in maas: | |
milestone: | 2.2.x → 2.3.0 |
Changed in maas: | |
milestone: | 2.3.0 → 2.3.x |
Changed in maas: | |
assignee: | Данило Шеган (danilo) → nobody |
status: | In Progress → Confirmed |
Sigh. It's 2017. Any time we encode text, in the absence of knowledge to the contrary, we should assume it's UTF-8. There are far too many occurrences of "ascii" in the MAAS code.