Kerberos authentication may fail with 'Cannot initialize gssapi'
In some cases, Kerberos authentication may fail because NoMachine cannot inizialize the local GSSAPI libraries. This problem has been encountered on macOS and Windows but it could happen also on Linux. It can affect connections by SSH protocol and NX protocol since it's related to the libssh2 library shipped with the NoMachine packages and used by default by NoMachine connections.
Client logs report:
76496 85771 2026-02-19 16:59:38 689.784 ClientSession: A valid certificate for this server was found.
77303 259 16:59:38 729 NXGssapiLoad: ERROR! Unable to import libraries.
77303 259 16:59:38 729 NXGssapiAuthLoop: ERROR! Cannot initialize gssapi.
76496 85771 2026-02-19 16:59:41 483.125 Encryptor/Encryptor: ERROR! Authentication failed.
76496 85771 2026-02-19 16:59:41 483.210 Encryptor/Encryptor: ERROR! Authentication failed in context [I].
As a workaround, if the NoMachine server supports that, connect by using SSH protocol and the system SSH. To do that, edit the edit the player.cfg file in the .nx/config directory under the user's home on the client host and modify the value of the following key from:
<option key="SSH client mode" value="library" />
to:
<option key="SSH client mode" value="native" />
Note for Windows:
install and/or enable OpenSSH client, some instructions are here: http://href="https://kb.nomachine.com/AR11V01259#2
