Error: SSH CONN ERROR: Cannot read property bold of undefined
How to fix "SSH CONN ERROR: Cannot read property 'bold' of undefined" error in Ezeelogin WebSSH
Overview: This article explains how to resolve the "SSH CONN ERROR: Cannot read property 'bold' of undefined" error in Ezeelogin WebSSH by debugging the WebSSH console, verifying SSH connectivity, and updating the SSH configuration file.
Refer below article to configure and troubleshoot WebSSH in Ezeelogin.
https://www.ezeelogin.com/kb/article/setup-web-ssh-console-in-ezeelogin-and-ssh-via-browser-180.html
https://www.ezeelogin.com/kb/article/could-not-setup-ezeelogin-web-ssh-service-156.html
Start the WebSSH Console node application manually to determine any errors.
root@gateway ~]# DEBUG=* PORT=52222 node $(awk '/^system_folder/ {print $2}' /usr/local/etc/ezlogin/ez.conf)/application/external/webssh/index.js
WebSSH2 Logout: user=eztest from=192.168.1.1 host=127.0.0.1 port=36000 sessionID=undefined/uZDvv6Fk6KiLwsOcAAAA allowreplay=undefined term=xterm-color socket.io:client ignoring packet write {"type":2,"data":["ssherror","SSH CONN END BY HOST: All configured authentication methods failed"],"nsp":"/"} +2ms
In the above example, the user "eztest" tries to access the WebSSH console, and the error "SSH CONN ERROR: Cannot read property 'bold' of undefined" appears in the console.
In the debug output, it shows "All configured authentication methods failed" for the same user, "eztest".
Follow below steps to fix the above error:
Step 1. Try to manually SSH from the gateway machine as the Ezeelogin user to localhost to confirm it is working. Additionally, ensure that password authentication is enabled for Ezeelogin users.
root@gateway ~]# ssh ezlogin_user@localhost
Step 2. If the user cannot manually SSH, allow the Ezeelogin user group in the configuration file to resolve the error. Add the following line under Match Address 127.0.0.1.
root@gateway ~]# vim /etc/ssh/sshd_config
Match Address 127.0.0.1
PubkeyAuthentication yes
PasswordAuthentication yes
Allowgroups ezuser
Step 3. Restart SSH daemon and try to ssh from the gateway machine as the Ezeelogin user to localhost to confirm it's working fine (refer step 1). Then click on the webssh icon on the Ezeelogin software GUI to make sure it works.
Related Articles: