여기서의 시나리오는 AWS에서 생성한 개인 키(ED25519 키)를 받고 Windows 10/1809의 내장 SSH(OpenSSH_for_Windows_7.7p1, LibreSSL 2.6.5)를 사용하여 시도한 결과 제대로 작동한다는 것입니다.
동일한 PC에서 동일한 키를 시도했지만 WSL Ubuntu 18.04.3(OpenSSH_7.6p1 Ubuntu-4ubuntu0.3, OpenSSL 1.0.2n 2017년 12월 7일) 내에서 키가 잘못된 형식이라고 불평합니다.
ssh -v를 호출하면 다음이 표시됩니다.
....snip a bit here....
debug1: Authenticating to xxxxxxxx.demo.com:22 as 'jgauthier'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: aes128-ctr MAC: hmac-sha1 compression: none
debug1: kex: client->server cipher: aes128-ctr MAC: hmac-sha1 compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:fCykR67cJynMNYYYv9jEO5PhYQgcaU0WRy/xmSsTxYQ
debug1: Host 'xxxxxxxx.demo.com' is known and matches the ECDSA host key.
debug1: Found key in /home/jgauthier/.ssh/known_hosts:1
debug1: rekey after 4294967296 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey after 4294967296 blocks
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<rsa-sha2-256,rsa-sha2-512>
debug1: SSH2_MSG_SERVICE_ACCEPT received
------------------------------------------------------------------------------
NOTICE
This IT system is provided for business use in accordance with approved
Policies and Procedures. By logging in, users acknowledge their understanding
that authorized administrators monitors and stores all activity generated on
this system as appropriate for business and security operations and may
disclose such activity or information as permitted by law.
------------------------------------------------------------------------------
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Trying private key: jgauthier_key.pem
Load key "jgauthier_key.pem": invalid format
debug1: No more authentication methods to try.
[email protected]: Permission denied (publickey).
작동하는 마지막 관련 줄은 다음과 같습니다.
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Trying private key: jgauthier_key.pem
debug1: Authentication succeeded (publickey).
Authenticated to xxxxxxx.demo.com ([nn.nn.nn.nn]:22).
debug1: channel 0: new [client-session]
debug1: Requesting [email protected]
debug1: Entering interactive session.
debug1: pledge: network
debug1: console supports the ansi parsing
debug1: client_input_global_request: rtype [email protected] want_reply 0
Last login: Fri Oct 18 21:30:10 2019 from mm.mm.mm.mm
Last login: Fri Oct 18 21:30:10 2019 from mm.mm.mm.mm
[jgauthier@xxxxxxx ~]$
어떤 아이디어가 있나요? 동일한 PC에서 Ubuntu 18.04.3을 실행하는 VirtualBox VM이나 다른 Linux 시스템에서는 아직 시도하지 않았습니다.
제가 연결하려는 호스트는 CentOS 7.6입니다. 서버리포트 입니다
Remote protocol version 2.0, remote software version OpenSSH_7.4
그게 중요하다면 내가 연결할 때.
CR/LF 대 LF일 수 있다고 생각했지만 WSL Linux에서는 가능한 모든 CR/LF를 제거하기 위해 .pem 파일을 직접 편집하고 파일의 마지막 줄 뒤에 단일 LF를 남겨 두었지만 진행하지 않았습니다. . Windows .ssh 디렉터리의 복사본과 WSL ~/.ssh의 복사본을 비교했는데 둘은 동일했습니다.
SSH의 두 가지 버전, 즉 LibreSSL 2.6.5와 OpenSSL 1.0.2n에 관한 것입니까?