asbru-cm/asbru-cm

SSH connection not maintained when using User/Password as the authentication

jim8989 opened this issue · 3 comments

Describe the bug
I get disconnected when using SSH to log into a QNAP server with the User/password authentication enabled but works if manual is enabled

To Reproduce
Steps to reproduce the behavior:

  1. Opened the Edit Connection window and entered the information in the Host section
  2. in the Authentication section User/Password is enabled
  3. Added a user name in the User window and a password in the Password window
  4. Saved and closed the Edit window
  5. Double clicked on the QNAP connection in My Connections
  6. The connection is established and a small menu is produced on the connection window
  7. Connection to the server is terminated

Expected behavior
When the connection is established and the small menu is shown in the window the connection is maintained and one of the options can be chosen and executed by the server

Screenshots
Small connection window: at the bottom of the menu where the cursor is located an entry of one of the numbers or the 'Q' can be typed and the enter key presses to start the selected operation
This text is produced on the scree when the connection is established.

Console Management - Main menu
|
| 1: Show network settings
| 2: System event logs
| 3: Reset to factory default (password required)
| 4: Activate/ deactivate a license
| 5: App management
| 6: Reboot in Rescue mode (w/o configured disk)
| 7: Reboot in Maintenance Mode
| Q: Quit (return to normal shell environment)

Environment (please complete the following information):

  • OS:Debian 11 and 12
  • Ásbrú Version 6.4.0-1-x86-64.appimage with Debian 12 repository install with Debian 11

Additional context
If I go back into the Edit Connection window and change the Authentication from User/Password to Manual and leave the User window with a name, save and close the change. Double click on the Server connection the server asks for the password and after entering the password the Menu appears and a number or 'Q' can be chosen and executed. and the connection works properly.

Having exact issue connecting to a cisco and hp switches. Fedora 38 with asbru-cm-6.4.0-1-x86_64.AppImage

You'll have the tweak the "Prompt RegExp" of you connection as it is specific to your appliance.

Said differently : once the password has been entered, Ásbrú is expecting a given "prompt" to be shown to confirm that the password has been correctly accepted. In your case, the "prompt" is a very special menu. You'll need to change the default "Prompt RegExp" to make it work.

Thanks for the response. After doing some searching on "Prompt RegExp" I found two sections in you doc link but the expressions were beyond my understanding. However it did get me thinking to try a different path and I was able to log in differently and use the Expect and Execute option to add a couple entries that changed my user to admin so it solves my issue.

I would like to spend some future time to see if I can understand how to use your suggestion to login without the disconnect but for now I'm going to closeout my ticket so you can focus on helping someone else. Really nice piece of software your offering.

Jim