Description
"OpenSSH for Windows" version
v1.0.0.0-Beta
Server OperatingSystem
Windows 10 Enterprise
Client OperatingSystem
Windows 10 Enterprise
What is failing
TrustedUserCAKeys doesn't appear to be working for a domain computer running Windows. Identical setup (identical CA Key, identical signed user key) on non-domain computer running Linux works as expected. Should also add this is using a Yubikey device, though I don't believe that matters.
Actual output
Here is the DEBUG3 log of the failure.
debug1: userauth-request for user contoso\\\\dwatley service ssh-connection method publickey [preauth]
debug1: attempt 1 failures 0 [preauth]
debug2: input_userauth_request: try method publickey [preauth]
debug1: userauth_pubkey: test whether pkalg/pkblob are acceptable for ECDSA SHA256:BzwUAn8oLRT54zs5e70vsJDeQ7aQnc+9/5n2RhtQImQ [preauth]
debug3: mm_key_allowed entering [preauth]
debug3: mm_request_send entering: type 22 [preauth]
debug3: mm_key_allowed: waiting for MONITOR_ANS_KEYALLOWED [preauth]
debug3: mm_request_receive_expect entering: type 23 [preauth]
debug3: mm_request_receive entering [preauth]
debug3: mm_request_receive entering
debug3: monitor_read: checking request 22
debug3: mm_answer_keyallowed entering
debug3: mm_answer_keyallowed: key_from_blob: 0000025871AD1D50
debug3: mm_answer_keyallowed: key is not allowed
debug3: mm_request_send entering: type 23
debug2: userauth_pubkey: authenticated 0 pkalg ecdsa-sha2-nistp256 [preauth]
debug3: userauth_finish: failure partial=0 next methods="publickey,keyboard-interactive" [preauth]
debug3: send packet: type 51 [preauth]
debug3: receive packet: type 50 [preauth]
debug1: userauth-request for user contoso\\\\dwatley service ssh-connection method publickey [preauth]
debug1: attempt 2 failures 1 [preauth]
debug2: input_userauth_request: try method publickey [preauth]
debug1: userauth_pubkey: test whether pkalg/pkblob are acceptable for ECDSA-CERT SHA256:+iRhr5z28xnKndebv4JV+sXl2agXRZ22cXwO6nZKokI [preauth]
debug3: mm_key_allowed entering [preauth]
debug3: mm_request_send entering: type 22 [preauth]
debug3: mm_key_allowed: waiting for MONITOR_ANS_KEYALLOWED [preauth]
debug3: mm_request_receive_expect entering: type 23 [preauth]
debug3: mm_request_receive entering [preauth]
debug3: mm_request_receive entering
debug3: monitor_read: checking request 22
debug3: mm_answer_keyallowed entering
debug3: mm_answer_keyallowed: key_from_blob: 0000025871AD1170
Certificate invalid: name is not a listed principal
debug3: mm_answer_keyallowed: key is not allowed
For what it's worth, using authorized_keys works as expected with no issue, but being able to use the TrustedUserCAKeys feature would be much preferred. I'm not sure that the fact that this is a domain joined computer matters, but did want to specify that. My initial thought was maybe the way the user cert was signed might result in a different identity between the two platforms (Windows domain joined, Linux not). What other options are there for debugging this further beyond enabling DEBUG3 as I have already?
Relevant sshd_config params:
debug2: parse_server_config: config __PROGRAMDATA__\\ssh/sshd_config len 376
debug3: __PROGRAMDATA__\\ssh/sshd_config:24 setting LogLevel DEBUG3
debug3: __PROGRAMDATA__\\ssh/sshd_config:40 setting PubkeyAuthentication yes
debug3: __PROGRAMDATA__\\ssh/sshd_config:51 setting PasswordAuthentication no
debug3: __PROGRAMDATA__\\ssh/sshd_config:52 setting ChallengeResponseAuthentication yes
debug3: __PROGRAMDATA__\\ssh/sshd_config:53 setting PermitEmptyPasswords no
debug3: __PROGRAMDATA__\\ssh/sshd_config:59 setting AuthorizedKeysFile none
debug3: __PROGRAMDATA__\\ssh/sshd_config:63 setting TrustedUserCAKeys __PROGRAMDATA__/ssh/ca_userkeys.pub
debug3: __PROGRAMDATA__\\ssh/sshd_config:69 setting HostbasedAuthentication no
debug3: __PROGRAMDATA__\\ssh/sshd_config:103 setting Subsystem sftp sftp-server.exe
debug1: sshd version OpenSSH_7.6, LibreSSL 2.5.3