test-kitchen / kitchen-ec2

A Test Kitchen Driver for Amazon EC2
Other
221 stars 202 forks source link

Fedora never connects to SSH #565

Open tas50 opened 3 years ago

tas50 commented 3 years ago

Something is wrong with the Fedora AMIs. I'm not sure if they have sshd started when they come up. They never login so this is totally broken.

knightorc commented 2 years ago

@tas50 I've been playing with CentOS 9 Stream with Test Kitchen. /var/log/secure is showing

Dec  7 20:01:37 localhost sshd[14640]: userauth_pubkey: key type ssh-rsa not in PubkeyAcceptedAlgorithms [preauth]

Manual ssh -i aws.key ec2-user@ip works.

Possibly related?

knightorc commented 2 years ago

Adding ssh-rsa to PubkeyAcceptedAlgorithms list in /etc/crypto-policies/back-ends/opensshserver.config permits kitchen create to complete and kitchen login work after an sshd restart

FYI

b0xspread commented 2 years ago

As of Ubuntu 22.04, ssh-rsa will also be removed form the PubkeyAcceptedAlgorithms so the driver needs to add support for ECDSA

bdwyertech commented 2 years ago

Would be resolved by https://github.com/test-kitchen/kitchen-ec2/pull/583 with a blip of config