Abnormal disconnect 1.8

Hi - just trying this to see if I can use it like BitVise on mac..

I cannot connect - or it does connect then drops...can you advise

11:40:59 debug3: sign_and_send_pubkey: signing using rsa-sha2-512
11:40:59 debug3: send packet: type 50
11:41:00 debug3: receive packet: type 52
11:41:00 debug1: Authentication succeeded (publickey).
11:41:00 Authenticated to ls089 ([xx.xx.xx.xx]:22).
11:41:00 debug1: Local connections to 127.0.0.1:992 forwarded to remote address localhost:992
11:41:00 debug3: channel_setup_fwd_listener_tcpip: type 2 wildcard 0 addr 127.0.0.1
11:41:00 debug1: Local forwarding listening on 127.0.0.1 port 992.
11:41:00 Abnormal Disconnect

Are you using Core Tunnel? Could you please paste the full connection log?

Thank you,

Sorry one other thing - my server is configured not to accept passwords.

Thanks again.

Kevin

Hi Yang,

I tried posting the log - but your system thinks I’m posting links and has not accepted my email

How should I do this?

Regards

Kevin

Hi Yang,

  How do I get around this if you want to see the full log which

has a number of URL's in it.

Regards

Kevin

Can you verify the ownership of the .ssh folder and public key on the host. Should be 600 and too wide ownership will give this result.

Mikael

Hi Mikael,

I have drwx-S-- on the permissions on the host.

I'll see what they are actually on the host.

Thanks

Kevin

Hi Mikael,

I've run this on my host.

mkdir -p /home/<your_ibmi_profile>/.ssh
chmod 755 /home/<your_ibmi_profile>
chmod 700 /home/<your_ibmi_profile>/.ssh
chmod 600 /home/<your_ibmi_profile>/.ssh/authorized_keys

  Still the last line is abnormal disconnect - everything else in

the log looks OK.

  I am running bitVise on a windows machine and it is working fine
  • so my assumption is that the host config is good..

Your thoughts?

Kevin

Hi Mikael,

I removed Exitonforwardfailure so there is no value…now I get …is this masking the error…and why the permission denied

11:48:05 Authenticated to ls089 ([66.186.183.82]:22).
11:48:05 debug1: Local connections to 127.0.0.1:992 forwarded to remote address localhost:992
11:48:05 debug3: channel_setup_fwd_listener_tcpip: type 2 wildcard 0 addr 127.0.0.1
11:48:05 debug1: Local forwarding listening on 127.0.0.1 port 992.
11:48:05 bind [127.0.0.1]:992: Permission denied
11:48:05 channel_setup_fwd_listener_tcpip: cannot listen to port: 992
11:48:05 Could not request local forwarding.
11:48:05 debug2: fd 5 setting TCP_NODELAY
11:48:05 debug3: ssh_packet_set_tos: set IP_TOS 0x48
11:48:05 debug1: Requesting no-more-sessions@openssh.com
11:48:05 debug3: send packet: type 80
11:48:05 debug1: Entering interactive session.
11:48:05 Connected
11:48:05 debug1: pledge: network
11:48:05 debug2: fd 6 setting O_NONBLOCK
11:48:05 debug2: fd 7 setting O_NONBLOCK
11:48:06 debug3: receive packet: type 80
11:48:06 debug1: client_input_global_request: rtype hostkeys-00@openssh.com want_reply 0
11:48:06 debug3: receive packet: type 4
11:48:06 debug1: Remote: /home/KEV/.ssh/authorized_keys:2: key options: agent-forwarding port-forwarding pty user-rc x11-forwarding
11:48:06 debug3: receive packet: type 4
11:48:06 debug1: Remote: /home/KEV/.ssh/authorized_keys:2: key options: agent-forwarding port-forwarding pty user-rc x11-forwarding

Hi Kevin, sorry for late reply.

Could you please run the Equivalent Command on Terminal.app or Core Shell, and see what happens when connecting via ssh command? You can find the command in the connection log:

Equivalent Command: ssh -D ...

Instead of reply thread via email, you can paste the log on the community, and quote log contents with triple backticks ```

Hi - I'm still getting Sorry, new users can only put 2 links in a post.

Kevins-MacBook-Pro:~ kevinpassey$ ssh -D "/Users/kevinpassey/Library/Group Containers/E78WKS7W4U.io.coressh.ssh/.ssh/privatekey/id_rsa" -vvv -L 127.0.0.1:992:localhost:992 -o PubkeyAuthentication=yes -o ExitOnForwardFailure=yes -o ConnectTimeout=15 KEV@LS089
OpenSSH_7.9p1, LibreSSL 2.7.3
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 48: Applying options for *
debug2: resolving "ls089" port 22
debug2: ssh_connect_direct
debug1: Connecting to ls089 [nn.nn.nn.nn] port 22.
debug2: fd 5 setting O_NONBLOCK
debug1: fd 5 clearing O_NONBLOCK
debug1: Connection established.
debug3: timeout: 11304 ms remain after connect
debug1: identity file /Users/kevinpassey/.ssh/id_rsa type 0
debug1: identity file /Users/kevinpassey/.ssh/id_rsa-cert type -1
debug1: identity file /Users/kevinpassey/.ssh/id_dsa type -1
debug1: identity file /Users/kevinpassey/.ssh/id_dsa-cert type -1
debug1: identity file /Users/kevinpassey/.ssh/id_ecdsa type -1
debug1: identity file /Users/kevinpassey/.ssh/id_ecdsa-cert type -1
debug1: identity file /Users/kevinpassey/.ssh/id_ed25519 type -1
debug1: identity file /Users/kevinpassey/.ssh/id_ed25519-cert type -1
debug1: identity file /Users/kevinpassey/.ssh/id_xmss type -1
debug1: identity file /Users/kevinpassey/.ssh/id_xmss-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_7.9
debug1: Remote protocol version 2.0, remote software version OpenSSH_8.0
debug1: match: OpenSSH_8.0 pat OpenSSH* compat 0x04000000
debug2: fd 5 setting O_NONBLOCK
debug1: Authenticating to ls089:22 as 'KEV'
debug3: hostkeys_foreach: reading file "/Users/kevinpassey/.ssh/known_hosts"
debug3: record_hostkey: found key type ECDSA in file /Users/kevinpassey/.ssh/known_hosts:4
debug3: load_hostkeys: loaded 1 keys from ls089
debug3: order_hostkeyalgs: prefer hostkeyalgs: ecdsa-sha2-nistp256-cert-v01@openssh.com,ecdsa-sha2-nistp384-cert-v01@openssh.com,ecdsa-sha2-nistp521-cert-v01@openssh.com,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521
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: 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: ecdsa-sha2-nistp256-cert-v01@openssh.com,ecdsa-sha2-nistp384-cert-v01@openssh.com,ecdsa-sha2-nistp521-cert-v01@openssh.com,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ssh-ed25519-cert-v01@openssh.com,rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-256-cert-v01@openssh.com,ssh-rsa-cert-v01@openssh.com,ssh-ed25519,rsa-sha2-512,rsa-sha2-256,ssh-rsa
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: 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
debug2: host key algorithms: rsa-sha2-512,rsa-sha2-256,ssh-rsa,ecdsa-sha2-nistp256,ssh-ed25519
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
debug2: compression stoc: none,zlib@openssh.com
debug2: languages ctos: 
debug2: languages stoc: 
debug2: first_kex_follows 0 
debug2: reserved 0 
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug3: send packet: type 30
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug3: receive packet: type 31
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:Ar1m17gU7eKigYD8ezSTUi/WjVoTbD/RBUd1+pnfa1A
debug3: hostkeys_foreach: reading file "/Users/kevinpassey/.ssh/known_hosts"
debug3: record_hostkey: found key type ECDSA in file /Users/kevinpassey/.ssh/known_hosts:4
debug3: load_hostkeys: loaded 1 keys from ls089
debug3: hostkeys_foreach: reading file "/Users/kevinpassey/.ssh/known_hosts"
debug3: record_hostkey: found key type ECDSA in file /Users/kevinpassey/.ssh/known_hosts:4
debug3: load_hostkeys: loaded 1 keys from nn.nn.nn.nn
debug1: Host 'ls089' is known and matches the ECDSA host key.
debug1: Found key in /Users/kevinpassey/.ssh/known_hosts:4
debug3: send packet: type 21
debug2: set_newkeys: mode 1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug3: receive packet: type 21
debug1: SSH2_MSG_NEWKEYS received
debug2: set_newkeys: mode 0
debug1: rekey after 134217728 blocks
debug1: Will attempt key: /Users/kevinpassey/.ssh/id_rsa RSA SHA256:0UsIxMEkANztzVXf+Oo+FYAzv2bsgtHdzgRgTPBnQNY
debug1: Will attempt key: /Users/kevinpassey/.ssh/id_dsa 
debug1: Will attempt key: /Users/kevinpassey/.ssh/id_ecdsa 
debug1: Will attempt key: /Users/kevinpassey/.ssh/id_ed25519 
debug1: Will attempt key: /Users/kevinpassey/.ssh/id_xmss 
debug2: pubkey_prepare: done
debug3: send packet: type 5
debug3: receive packet: type 7
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<ssh-ed25519,ssh-rsa,rsa-sha2-256,rsa-sha2-512,ssh-dss,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521>
debug3: receive packet: type 6
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug3: send packet: type 50
debug3: receive packet: type 51
debug1: Authentications that can continue: publickey,keyboard-interactive
debug3: start over, passed a different list publickey,keyboard-interactive
debug3: preferred 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: /Users/kevinpassey/.ssh/id_rsa RSA SHA256:0UsIxMEkANztzVXf+Oo+FYAzv2bsgtHdzgRgTPBnQNY
debug3: send packet: type 50
debug2: we sent a publickey packet, wait for reply
debug3: receive packet: type 60
debug1: Server accepts key: /Users/kevinpassey/.ssh/id_rsa RSA SHA256:0UsIxMEkANztzVXf+Oo+FYAzv2bsgtHdzgRgTPBnQNY
debug3: sign_and_send_pubkey: RSA SHA256:0UsIxMEkANztzVXf+Oo+FYAzv2bsgtHdzgRgTPBnQNY
debug3: sign_and_send_pubkey: signing using rsa-sha2-512
debug3: send packet: type 50
debug3: receive packet: type 52
debug1: Authentication succeeded (publickey).
Authenticated to ls089 ([nn.nn.nn.nn]:22).
debug1: Local connections to /Users/kevinpassey/Library/Group Containers/E78WKS7W4U.io.coressh.ssh/.ssh/privatekey/id_rsa:-2 forwarded to remote address socks:0
debug3: channel_setup_fwd_listener_streamlocal: type 18 path /Users/kevinpassey/Library/Group Containers/E78WKS7W4U.io.coressh.ssh/.ssh/privatekey/id_rsa
unix_listener: cannot bind to path /Users/kevinpassey/Library/Group Containers/E78WKS7W4U.io.coressh.ssh/.ssh/privatekey/id_rsa: Address already in use
debug1: Local connections to 127.0.0.1:992 forwarded to remote address localhost:992
debug3: channel_setup_fwd_listener_tcpip: type 2 wildcard 0 addr 127.0.0.1
debug1: Local forwarding listening on 127.0.0.1 port 992.
bind [127.0.0.1]:992: Permission denied
channel_setup_fwd_listener_tcpip: cannot listen to port: 992
Could not request local forwarding.
Kevins-MacBook-Pro:~ kevinpassey$ 

Hi - sorry new to the forum software - posted it now..

Here is the problem:

Ports below 1024 can be opened only by root, please change local listening higher than 1024.

I'm using some IBM software that only runs on 23 and 992 - I
cannot change this software to work on another port.

  Thanks for you help anyway. Looks like I'm going to have to use

Bitvise and Parallels..

Kind regards

Kevin

Beginning with macOS 10.14, Core Tunnel can binds to privileged ports without obtain administrative or root privileges. Please take a look at this post for details: