PC에서 cygwin을 업그레이드했지만 이제 Linux에서 SSH에 액세스할 수 없습니다.

PC에서 cygwin을 업그레이드했지만 이제 Linux에서 SSH에 액세스할 수 없습니다.

모든 것이 완벽하게 설정되어 있으며 문제 없이 비밀번호를 사용하지 않고도 Linux 상자에서 내 PC의 cygsrv(Cygwin SSH 서버)로 SSH를 연결할 수 있습니다(DSA 키 btw를 사용하고 있습니다). 모든 .ssh 권한이 정확합니다. JIC 양쪽의 .ssh/config에 다음 줄을 추가하기도 했습니다.

PubkeyAcceptedKeyTypes +ssh-dss

이것은 몇 년 동안 작동해 왔습니다. Cygwin에 패키지를 설치하고 싶고 물론 다른 모든 패키지도 업그레이드하고 싶습니다. 업그레이드하려면 SSH cygsrv를 꺼야 합니다. 이제 cygwin은 다음과 같습니다.

$ uname -a
CYGWIN_NT-6.3 PCName 2.4.1(0.293/5/3) 2016-01-24 11:26 x86_64 Cygwin

이제 더 이상 oa 비밀번호를 사용하여 로그인할 수 없습니다. 양쪽의 .ssh 디렉터리에는 아무 것도 변경되지 않습니다.

그런데 oa 비밀번호를 사용하여 Cygwin에서 Linux에 자동으로 로그인할 수 있습니다. 나는 이것이 DSA 취약점을 처리하여 더욱 안전하게 만드는 것과 관련이 있다고 생각합니다.

이것은 Linux용 SSH 출력입니다.

$ ssh -vvv mjhome
OpenSSH_4.3p2, OpenSSL 0.9.8e-fips-rhel5 01 Jul 2008
debug1: Reading configuration data /export/home/mjobe/.ssh/config
debug1: Applying options for mjhome
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to 108.72.79.8 [108.72.79.8] port 3333.
debug1: Connection established.
debug3: Not a RSA1 key file /export/home/mjobe/.ssh/id_rsa.
debug2: key_type_from_name: unknown key type '-----BEGIN'
debug3: key_read: missing keytype
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug2: key_type_from_name: unknown key type '-----END'
debug3: key_read: missing keytype
debug1: identity file /export/home/mjobe/.ssh/id_rsa type 1
debug3: Not a RSA1 key file /export/home/mjobe/.ssh/id_dsa.
debug2: key_type_from_name: unknown key type '-----BEGIN'
debug3: key_read: missing keytype
debug2: key_type_from_name: unknown key type 'Proc-Type:'
debug3: key_read: missing keytype
debug2: key_type_from_name: unknown key type 'DEK-Info:'
debug3: key_read: missing keytype
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug2: key_type_from_name: unknown key type '-----END'
debug3: key_read: missing keytype
debug1: identity file /export/home/mjobe/.ssh/id_dsa type 2
debug1: identity file /export/home/mjobe/.ssh/engdev2_rsa type -1
debug1: identity file /export/home/mjobe/.ssh/engdev2_dsa type -1
debug1: loaded 4 keys
debug1: Remote protocol version 2.0, remote software version OpenSSH_7.1
debug1: match: OpenSSH_7.1 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_4.3
debug2: fd 4 setting O_NONBLOCK
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug2: kex_parse_kexinit: diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1
debug2: kex_parse_kexinit: ssh-rsa,ssh-dss
debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour128,arcfour256,arcfour,aes192-cbc,aes256-cbc,[email protected],aes128-ctr,aes192-ctr,aes256-ctr
debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour128,arcfour256,arcfour,aes192-cbc,aes256-cbc,[email protected],aes128-ctr,aes192-ctr,aes256-ctr
debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96
debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,hmac-ripemd160,[email protected],hmac-sha1-96,hmac-md5-96
debug2: kex_parse_kexinit: none,[email protected],zlib
debug2: kex_parse_kexinit: none,[email protected],zlib
debug2: kex_parse_kexinit:
debug2: kex_parse_kexinit:
debug2: kex_parse_kexinit: first_kex_follows 0
debug2: kex_parse_kexinit: reserved 0
debug2: kex_parse_kexinit: [email protected],ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha1
debug2: kex_parse_kexinit: ssh-rsa,ecdsa-sha2-nistp256
debug2: kex_parse_kexinit: [email protected],aes128-ctr,aes192-ctr,aes256-ctr,[email protected],[email protected]
debug2: kex_parse_kexinit: [email protected],aes128-ctr,aes192-ctr,aes256-ctr,[email protected],[email protected]
debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-sha1
debug2: kex_parse_kexinit: [email protected],[email protected],[email protected],[email protected],[email protected],[email protected],[email protected],hmac-sha2-256,hmac-sha2-512,hmac-sha1
debug2: kex_parse_kexinit: none,[email protected]
debug2: kex_parse_kexinit: none,[email protected]
debug2: kex_parse_kexinit:
debug2: kex_parse_kexinit:
debug2: kex_parse_kexinit: first_kex_follows 0
debug2: kex_parse_kexinit: reserved 0
debug2: mac_init: found hmac-sha1
debug1: kex: server->client aes128-ctr hmac-sha1 none
debug2: mac_init: found hmac-sha1
debug1: kex: client->server aes128-ctr hmac-sha1 none
debug2: dh_gen_key: priv key bits set: 161/320
debug2: bits set: 1024/2048
debug1: sending SSH2_MSG_KEXDH_INIT
debug1: expecting SSH2_MSG_KEXDH_REPLY
debug3: check_host_in_hostfile: filename /dev/null
debug3: check_host_in_hostfile: filename /etc/ssh/ssh_known_hosts
Warning: Permanently added '108.72.79.8' (RSA) to the list of known hosts.
debug2: bits set: 1029/2048
debug1: ssh_rsa_verify: signature correct
debug2: kex_derive_keys
debug2: set_newkeys: mode 1
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug2: set_newkeys: mode 0
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug2: key: /export/home/mjobe/.ssh/id_rsa (0x2b4beaaec650)
debug2: key: /export/home/mjobe/.ssh/id_dsa (0x2b4beaaec680)
debug2: key: /export/home/mjobe/.ssh/engdev2_rsa ((nil))
debug2: key: /export/home/mjobe/.ssh/engdev2_dsa ((nil))
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug3: start over, passed a different list publickey,password,keyboard-interactive
debug3: preferred gssapi-with-mic,publickey,keyboard-interactive,password
debug3: authmethod_lookup publickey
debug3: remaining preferred: keyboard-interactive,password
debug3: authmethod_is_enabled publickey
debug1: Next authentication method: publickey
debug1: Offering public key: /export/home/mjobe/.ssh/id_rsa
debug3: send_pubkey_test
debug2: we sent a publickey packet, wait for reply
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug1: Offering public key: /export/home/mjobe/.ssh/id_dsa
debug3: send_pubkey_test
debug2: we sent a publickey packet, wait for reply
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug1: Trying private key: /export/home/mjobe/.ssh/engdev2_rsa
debug3: no such identity: /export/home/mjobe/.ssh/engdev2_rsa
debug1: Trying private key: /export/home/mjobe/.ssh/engdev2_dsa
debug3: no such identity: /export/home/mjobe/.ssh/engdev2_dsa
debug2: we did not send a packet, disable method
debug3: authmethod_lookup keyboard-interactive
debug3: remaining preferred: password
debug3: authmethod_is_enabled keyboard-interactive
debug1: Next authentication method: keyboard-interactive
debug2: userauth_kbdint
debug2: we sent a keyboard-interactive packet, wait for reply
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug3: userauth_kbdint: disable: no info_req_seen
debug2: we did not send a packet, disable method
debug3: authmethod_lookup password
debug3: remaining preferred:
debug3: authmethod_is_enabled password
debug1: Next authentication method: password

다시 말하지만, 파일 관점에서 다른 것은 변경되지 않았습니다(예: .ssh/...).

답변1

JIC 양쪽의 .ssh/config에 다음 줄을 추가하기도 했습니다.

PubkeyAcceptedKeyTypes +ssh-dss

/etc/ssh/sshd_config클라이언트 구성이 아닌 서버 구성( )에 추가해야 합니다 . 클라이언트 구성은 서버 측에서 읽혀지지 않습니다.

관련 정보