ssh -X -v
says that I don't have xauth data and it uses fake authentication for X11 forwarding?
I have put ssh_config X11 to "yes". Same with sshd_config.
In /etc/ssh/ssh_config
, I have removed the #
hash character from Port 22 and Protocol 2 and added XauthLocation /usr/bin/xauth
but it still doesn't recognize it?
My goal is to ssh to another computer and open firefox or xclock, leafpad, send notifications and etc... on that computer.
I made it work only one way, when I used xhost +
, but I don't like using it.
sudo cat /etc/ssh/ssh_config | grep X11
ForwardX11 yes
ForwardX11Trusted yes
sudo cat /etc/ssh/sshd_config | grep X11
X11Forwarding yes
X11DisplayOffset 10
X11UseLocalhost no
Here's the output of ssh -X -v
OpenSSH_7.2p2 Ubuntu-4ubuntu2.4, OpenSSL 1.0.2g 1 Mar 2016
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: Connecting to 192.168.5.22 [192.168.5.22] port 22.
debug1: Connection established.
debug1: key_load_public: No such file or directory
debug1: identity file /home/kasutaja/.ssh/id_rsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/kasutaja/.ssh/id_rsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/kasutaja/.ssh/id_dsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/kasutaja/.ssh/id_dsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/kasutaja/.ssh/id_ecdsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/kasutaja/.ssh/id_ecdsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/kasutaja/.ssh/id_ed25519 type -1
debug1: key_load_public: No such file or directory
debug1: identity file /home/kasutaja/.ssh/id_ed25519-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_7.2p2 Ubuntu-4ubuntu2.4
debug1: Remote protocol version 2.0, remote software version OpenSSH_7.2p2 Ubuntu-4ubuntu2.4
debug1: match: OpenSSH_7.2p2 Ubuntu-4ubuntu2.4 pat OpenSSH* compat 0x04000000
debug1: Authenticating to 192.168.5.22:22 as 'kasutaja'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: [email protected]
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: [email protected] MAC: <implicit> compression: none
debug1: kex: client->server cipher: [email protected] MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:s6nPrSaS0Xv70nUEuen+/KI7VY504pGwTBwFokztLSw
debug1: Host '192.168.5.22' is known and matches the ECDSA host key.
debug1: Found key in /home/kasutaja/.ssh/known_hosts:7
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS received
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
debug1: Authentications that can continue: publickey,password
debug1: Next authentication method: publickey
debug1: Trying private key: /home/kasutaja/.ssh/id_rsa
debug1: Trying private key: /home/kasutaja/.ssh/id_dsa
debug1: Trying private key: /home/kasutaja/.ssh/id_ecdsa
debug1: Trying private key: /home/kasutaja/.ssh/id_ed25519
debug1: Next authentication method: password
[email protected]'s password:
debug1: Authentication succeeded (password).
Authenticated to 192.168.5.22 ([192.168.5.22]:22).
debug1: channel 0: new [client-session]
debug1: Requesting [email protected]
debug1: Entering interactive session.
debug1: pledge: exec
debug1: client_input_global_request: rtype [email protected] want_reply 0
Warning: No xauth data; using fake authentication data for X11 forwarding.
debug1: Requesting X11 forwarding with authentication spoofing.
debug1: Sending environment.
debug1: Sending env LC_PAPER = et_EE.UTF-8
debug1: Sending env LC_ADDRESS = et_EE.UTF-8
debug1: Sending env LC_MONETARY = et_EE.UTF-8
debug1: Sending env LC_NUMERIC = et_EE.UTF-8
debug1: Sending env LC_TELEPHONE = et_EE.UTF-8
debug1: Sending env LC_IDENTIFICATION = et_EE.UTF-8
debug1: Sending env LANG = et_EE.UTF-8
debug1: Sending env LC_MEASUREMENT = et_EE.UTF-8
debug1: Sending env LC_TIME = et_EE.UTF-8
debug1: Sending env LC_NAME = et_EE.UTF-8
Welcome to Ubuntu 16.04.4 LTS (GNU/Linux 4.4.0-127-generic x86_64)