On host1 (server) : sshd
with config
Port 56320
AllowUsers user11123
AddressFamily any
ListenAddress 127.0.0.1
TCPKeepAlive yes
Compression delayed
Subsystem sftp /usr/lib/ssh/sftp-server
KexAlgorithms diffie-hellman-group18-sha512
Ciphers [email protected]
MACs [email protected]
PubkeyAcceptedKeyTypes ssh-rsa
HostKeyAlgorithms ssh-rsa
HostbasedAuthentication yes
HostbasedAcceptedKeyTypes ssh-rsa
PasswordAuthentication no
PubkeyAuthentication yes
AuthorizedKeysFile /home/user11123/.ssh/authorized_keys
PermitRootLogin no
PrintMotd no
PrintLastLog yes
ClientAliveInterval 30
ClientAliveCountMax 5
SyslogFacility AUTH
LogLevel INFO
and tor
with
HiddenServiceDir /var/lib/tor/ssh/
HiddenServicePort 56320 127.0.0.1:56320
iptables disabled.
on host2 : tor
and ssh nb
with config
host nb
User user11123
Hostname __copy_addr_from_host1__.onion
Port 56320
VerifyHostKeyDNS no
ProxyCommand ncat -vvv --proxy 127.0.0.1:9050 --proxy-type socks5 %h %p
KexAlgorithms diffie-hellman-group18-sha512
Ciphers [email protected]
MACs [email protected]
PubkeyAcceptedKeyTypes ssh-rsa
HostKeyAlgorithms ssh-rsa
HostbasedAuthentication yes
HostbasedAcceptedKeyTypes ssh-rsa
PasswordAuthentication no
CheckHostIP no
KeepAlive yes
and result is :
Ncat: Version 7.70 ( https://nmap.org/ncat )
NCAT DEBUG: Using system default trusted CA certificates and those in /usr/share/ncat/ca-bundle.crt.
Ncat: Connected to proxy 127.0.0.1:9050
Ncat: No authentication needed.
Ncat: Error: Host unreachable.
kex_exchange_identification: Connection closed by remote host
tor.log
on host2 :
Close 1 streams for service [scrubbed].onion for reason resolve failed. Fetch status: No more HSDir available to query.
please tell me how to set it up