Skip to content

ansible: codify workstation SSH keys after a fleet-wide lockout - #606

Merged
swares merged 1 commit into
mainfrom
fix/workstation-ssh-keys
Sep 23, 2026
Merged

swares merged 1 commit into
mainfrom
fix/workstation-ssh-keys

Conversation

@swares

@swares swares commented Sep 23, 2026

Copy link
Copy Markdown
Owner

2.15 set PasswordAuthentication no everywhere on 09-20. On 09-23 the Windows laptop could not log in anywhere: it had never been given a key, and password auth had been carrying it silently. ansible/files/ held one public key - the break-glass one - and no mechanism for a workstation key existed.

That entry examines what the change does to sshd in detail and never asks who was authenticating with a password. Before removing an authentication method, enumerate who is actually using it.

Recovery was the break-glass key, which worked on .160, .42 and .21 - so 1.2's 'test it' checkbox, open since August, is answered by a real lockout rather than a drill. Key auth is unaffected by PasswordAuthentication no, which is why that path survived the change that caused the outage.

admin-keys.yml replaces the ad-hoc recovery push. It asserts at least one key exists and that each file matches an SSH public-key shape, because the recovery command ran with an unset variable, handed authorized_key an empty string, and got SUCCESS on thirteen hosts with changed: false. Regex verified against the real keys and against empty, garbage, a bare key type, and a private key pasted by mistake.

Excludes xu3-1 deliberately (2.16): a key granting NOPASSWD sudo on a host running OpenSSL 1.0.2g. Records that the recovery push already put one there and must be removed. Also records opi-zero2w-1 down with No route to host - the second Zero 2W in four days to silently miss a fleet-wide change, and the DNS tertiary.

2.15 set PasswordAuthentication no everywhere on 09-20. On 09-23 the Windows laptop could not log in anywhere: it had never been given a key, and password auth had been carrying it silently. ansible/files/ held one public key - the break-glass one - and no mechanism for a workstation key existed.

That entry examines what the change does to sshd in detail and never asks who was authenticating with a password. Before removing an authentication method, enumerate who is actually using it.

Recovery was the break-glass key, which worked on .160, .42 and .21 - so 1.2's 'test it' checkbox, open since August, is answered by a real lockout rather than a drill. Key auth is unaffected by PasswordAuthentication no, which is why that path survived the change that caused the outage.

admin-keys.yml replaces the ad-hoc recovery push. It asserts at least one key exists and that each file matches an SSH public-key shape, because the recovery command ran with an unset variable, handed authorized_key an empty string, and got SUCCESS on thirteen hosts with changed: false. Regex verified against the real keys and against empty, garbage, a bare key type, and a private key pasted by mistake.

Excludes xu3-1 deliberately (2.16): a key granting NOPASSWD sudo on a host running OpenSSL 1.0.2g. Records that the recovery push already put one there and must be removed. Also records opi-zero2w-1 down with No route to host - the second Zero 2W in four days to silently miss a fleet-wide change, and the DNS tertiary.
@swares
swares merged commit 0b6aa11 into main Sep 23, 2026
4 checks passed
@swares
swares deleted the fix/workstation-ssh-keys branch September 23, 2026 17:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant