Issues with Cisco ASA

Hi Yang,

I can't connect by ssh with my firewall, have this issue.

––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
Equivalent Command: ssh -vvv -o ServerAliveInterval=15 -o KexAlgorithms=+diffie-hellman-group14-sha1 -o ExitOnForwardFailure=yes -o ServerAliveCountMax=3 -p 22 jaraujo@172.15.20.1
22:22:16 Connecting…
22:22:16 Using Core Helper 6.6 (r3386)
22:22:16 OpenSSH_8.8p1, OpenSSL 1.1.1l 24 Aug 2021
22:22:16 debug1: Reading configuration data /Users/skyones/.ssh/config
22:22:16 debug1: Reading configuration data /etc/ssh/ssh_config
22:22:16 debug1: /etc/ssh/ssh_config line 21: include /etc/ssh/ssh_config.d/* matched no files
22:22:16 debug1: /etc/ssh/ssh_config line 54: Applying options for *
22:22:16 debug2: resolve_canonicalize: hostname 172.15.20.1 is address
22:22:16 debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts' -> '/Users/skyones/.ssh/known_hosts'
22:22:16 debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts2' -> '/Users/skyones/.ssh/known_hosts2'
22:22:16 debug3: ssh_connect_direct: entering
22:22:16 debug1: Connecting to 172.15.20.1 [172.15.20.1] port 22.
22:22:16 debug3: set_sock_tos: set socket 3 IP_TOS 0x48
22:22:16 debug1: Connection established.
22:22:16 debug1: identity file /Users/skyones/.ssh/id_rsa type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_rsa-cert type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_dsa type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_dsa-cert type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_ecdsa type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_ecdsa-cert type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_ecdsa_sk type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_ecdsa_sk-cert type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_ed25519 type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_ed25519-cert type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_ed25519_sk type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_ed25519_sk-cert type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_xmss type -1
22:22:16 debug1: identity file /Users/skyones/.ssh/id_xmss-cert type -1
22:22:16 debug1: Local version string SSH-2.0-OpenSSH_8.8
22:22:16 debug1: Remote protocol version 2.0, remote software version Cisco-1.25
22:22:16 debug1: compat_banner: match: Cisco-1.25 pat Cisco-1.* compat 0x60000000
22:22:16 debug2: fd 3 setting O_NONBLOCK
22:22:16 debug1: Authenticating to 172.15.20.1:22 as 'jaraujo'
22:22:16 Authenticating…
22:22:16 debug3: record_hostkey: found key type RSA in file /Users/skyones/.ssh/known_hosts:112
22:22:16 debug3: load_hostkeys_file: loaded 1 keys from 172.15.20.1
22:22:16 debug1: load_hostkeys: fopen /Users/skyones/.ssh/known_hosts2: No such file or directory
22:22:16 debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
22:22:16 debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
22:22:16 debug3: order_hostkeyalgs: prefer hostkeyalgs: rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256
22:22:16 debug3: send packet: type 20
22:22:16 debug1: SSH2_MSG_KEXINIT sent
22:22:16 debug3: receive packet: type 20
22:22:16 debug1: SSH2_MSG_KEXINIT received
22:22:16 debug2: local client KEXINIT proposal
22:22:16 debug2: KEX algorithms: curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512,diffie-hellman-group14-sha256,diffie-hellman-group14-sha1,ext-info-c
22:22:16 debug2: host key algorithms: rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256,ssh-ed25519-cert-v01@openssh.com,ecdsa-sha2-nistp256-cert-v01@openssh.com,ecdsa-sha2-nistp384-cert-v01@openssh.com,ecdsa-sha2-nistp521-cert-v01@openssh.com,sk-ssh-ed25519-cert-v01@openssh.com,sk-ecdsa-sha2-nistp256-cert-v01@openssh.com,ssh-ed25519,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,sk-ssh-ed25519@openssh.com,sk-ecdsa-sha2-nistp256@openssh.com
22:22:16 debug2: ciphers ctos: chacha20-poly1305@openssh.com,aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm@openssh.com,aes256-gcm@openssh.com
22:22:16 debug2: ciphers stoc: chacha20-poly1305@openssh.com,aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm@openssh.com,aes256-gcm@openssh.com
22:22:16 debug2: MACs ctos: umac-64-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-sha1-etm@openssh.com,umac-64@openssh.com,umac-128@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-sha1
22:22:16 debug2: MACs stoc: umac-64-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-sha1-etm@openssh.com,umac-64@openssh.com,umac-128@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-sha1
22:22:16 debug2: compression ctos: none,zlib@openssh.com,zlib
22:22:16 debug2: compression stoc: none,zlib@openssh.com,zlib
22:22:16 debug2: languages ctos:
22:22:16 debug2: languages stoc:
22:22:16 debug2: first_kex_follows 0
22:22:16 debug2: reserved 0
22:22:16 debug2: peer server KEXINIT proposal
22:22:16 debug2: KEX algorithms: diffie-hellman-group14-sha1
22:22:16 debug2: host key algorithms: ssh-ed25519
22:22:16 debug2: ciphers ctos: aes128-gcm@openssh.com,aes256-ctr,aes256-cbc,aes192-ctr,aes192-cbc,aes128-ctr,aes128-cbc,chacha20-poly1305@openssh.com
22:22:16 debug2: ciphers stoc: aes128-gcm@openssh.com,aes256-ctr,aes256-cbc,aes192-ctr,aes192-cbc,aes128-ctr,aes128-cbc,chacha20-poly1305@openssh.com
22:22:16 debug2: MACs ctos: hmac-sha2-256
22:22:16 debug2: MACs stoc: hmac-sha2-256
22:22:16 debug2: compression ctos: none
22:22:16 debug2: compression stoc: none
22:22:16 debug2: languages ctos:
22:22:16 debug2: languages stoc:
22:22:16 debug2: first_kex_follows 0
22:22:16 debug2: reserved 0
22:22:16 debug1: kex: algorithm: diffie-hellman-group14-sha1
22:22:16 debug1: kex: host key algorithm: ssh-ed25519
22:22:16 debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
22:22:16 debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
22:22:16 debug2: bits set: 1044/2048
22:22:16 debug3: send packet: type 30
22:22:16 debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
22:22:16 Connection closed by 172.15.20.1 port 22
22:22:16 Abnormal Disconnect

Hi Jose,

Could you please run following command in a local terminal, and paste the output?

ssh -vvv -o ServerAliveInterval=15 -o KexAlgorithms=+diffie-hellman-group14-sha1 -o ExitOnForwardFailure=yes -o ServerAliveCountMax=3 -p 22 jaraujo@172.15.20.1

Thank you,

Yang

skyones@Macbook-Pro-M1 ~ % ssh jaraujo@172.15.20.1 -vvv -o ServerAliveInterval=15 -o KexAlgorithms=+diffie-hellman-group14-sha1
OpenSSH_9.0p1, LibreSSL 3.3.6
debug1: Reading configuration data /Users/skyones/.ssh/config
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 21: include /etc/ssh/ssh_config.d/* matched no files
debug1: /etc/ssh/ssh_config line 54: Applying options for *
debug2: resolve_canonicalize: hostname 172.15.20.1 is address
debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts' -> '/Users/skyones/.ssh/known_hosts'
debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts2' -> '/Users/skyones/.ssh/known_hosts2'
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug3: ssh_connect_direct: entering
debug1: Connecting to 172.15.20.1 [172.15.20.1] port 22.
debug3: set_sock_tos: set socket 3 IP_TOS 0x48
debug1: Connection established.
debug1: identity file /Users/skyones/.ssh/id_rsa type -1
debug1: identity file /Users/skyones/.ssh/id_rsa-cert type -1
debug1: identity file /Users/skyones/.ssh/id_ecdsa type -1
debug1: identity file /Users/skyones/.ssh/id_ecdsa-cert type -1
debug1: identity file /Users/skyones/.ssh/id_ecdsa_sk type -1
debug1: identity file /Users/skyones/.ssh/id_ecdsa_sk-cert type -1
debug1: identity file /Users/skyones/.ssh/id_ed25519 type -1
debug1: identity file /Users/skyones/.ssh/id_ed25519-cert type -1
debug1: identity file /Users/skyones/.ssh/id_ed25519_sk type -1
debug1: identity file /Users/skyones/.ssh/id_ed25519_sk-cert type -1
debug1: identity file /Users/skyones/.ssh/id_xmss type -1
debug1: identity file /Users/skyones/.ssh/id_xmss-cert type -1
debug1: identity file /Users/skyones/.ssh/id_dsa type -1
debug1: identity file /Users/skyones/.ssh/id_dsa-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_9.0
debug1: Remote protocol version 2.0, remote software version Cisco-1.25
debug1: compat_banner: match: Cisco-1.25 pat Cisco-1.* compat 0x60000000
debug2: fd 3 setting O_NONBLOCK
debug1: Authenticating to 172.15.20.1:22 as 'jaraujo'
debug3: record_hostkey: found key type RSA in file /Users/skyones/.ssh/known_hosts:112
debug3: load_hostkeys_file: loaded 1 keys from 172.15.20.1
debug1: load_hostkeys: fopen /Users/skyones/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug3: order_hostkeyalgs: prefer hostkeyalgs: rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256
debug3: send packet: type 20
debug1: SSH2_MSG_KEXINIT sent
debug3: receive packet: type 20
debug1: SSH2_MSG_KEXINIT received
debug2: local client KEXINIT proposal
debug2: KEX algorithms: sntrup761x25519-sha512@openssh.com,curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512,diffie-hellman-group14-sha256,diffie-hellman-group14-sha1,ext-info-c
debug2: host key algorithms: rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256,ssh-ed25519-cert-v01@openssh.com,ecdsa-sha2-nistp256-cert-v01@openssh.com,ecdsa-sha2-nistp384-cert-v01@openssh.com,ecdsa-sha2-nistp521-cert-v01@openssh.com,ssh-ed25519,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521
debug2: ciphers ctos: chacha20-poly1305@openssh.com,aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm@openssh.com,aes256-gcm@openssh.com
debug2: ciphers stoc: chacha20-poly1305@openssh.com,aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm@openssh.com,aes256-gcm@openssh.com
debug2: MACs ctos: umac-64-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-sha1-etm@openssh.com,umac-64@openssh.com,umac-128@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-sha1
debug2: MACs stoc: umac-64-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-sha1-etm@openssh.com,umac-64@openssh.com,umac-128@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-sha1
debug2: compression ctos: none,zlib@openssh.com,zlib
debug2: compression stoc: none,zlib@openssh.com,zlib
debug2: languages ctos:
debug2: languages stoc:
debug2: first_kex_follows 0
debug2: reserved 0
debug2: peer server KEXINIT proposal
debug2: KEX algorithms: diffie-hellman-group14-sha1
debug2: host key algorithms: ssh-rsa
debug2: ciphers ctos: aes128-gcm@openssh.com,aes256-ctr,aes256-cbc,aes192-ctr,aes192-cbc,aes128-ctr,aes128-cbc,chacha20-poly1305@openssh.com
debug2: ciphers stoc: aes128-gcm@openssh.com,aes256-ctr,aes256-cbc,aes192-ctr,aes192-cbc,aes128-ctr,aes128-cbc,chacha20-poly1305@openssh.com
debug2: MACs ctos: hmac-sha2-256
debug2: MACs stoc: hmac-sha2-256
debug2: compression ctos: none
debug2: compression stoc: none
debug2: languages ctos:
debug2: languages stoc:
debug2: first_kex_follows 0
debug2: reserved 0
debug1: kex: algorithm: diffie-hellman-group14-sha1
debug1: kex: host key algorithm: (no match)
Unable to negotiate with 172.15.20.1 port 22: no matching host key type found. Their offer: ssh-rsa

Thank you for the log.

Please try set HostkeyAlgorithms to +ssh-rsa in Advanced options in Settings of the profile.

Kindly Regards,

Yang