PSM-SSH: Failed to execute login sequence

PSM-SSH: Failed to execute login sequence

146
Created On 11/10/26 10:55 AM - Last Modified 11/10/26 15:55 PM


Symptom


When using the PSM-SSH connection component, the error  "059E Failed to execute login sequence: Incorrect sequence defined in configuration, or network timeout occurred." could be thrown

Environment


9.6;9.7;9.8;9.9;9.9.5;9.10;10.0;10.1;10.2;10.3;10.4;10.5;10.6;10.7;10.8;10.9;10.10 This can occur with any target server using a UNIX variant (i.e. Solaris, Linux, HP-UX, IBM-AIX, etc).

Cause


The cause of the issue may stem from the actual shell prompt that is presented at the login phase. By default, most shell prompts contain [<username>@<hostname> ]$, and the AutoLogonSequenceWithLogonAccount will account for that. However, some systems, depending on configuration could use a single "$" or other character as a prompt. The default AutoLogonSequenceWithLogonAccount will not parse this properly, resulting in the error.

Resolution


The AutoLogonSequenceWithLogonAccount is located in the PSM-SSH Connection Component (Configuration Options -> Options -> Connection Components -> PSM-SSH -> Target Settings -> Client Specific). This is a regular expression that will parse the UNIX prompt and then execute the su - root. 

You can modify the regular expression to meet needs of different prompts. The following example shows how to account for not only the default, but also the single "$" prompt:

.*\$|\[.*\@.* ~]\$ >exec su - {Username} 
Password:>{Password} 

Note the .*\$ will account for any text before the $ prompt, and since the $ is usually a special character, this is negated with the "\". Multiple regular expressions are separated with a vertical bar ("|")

For example with a server that needs:
useraccount@LINUX-SERVER2:~>

The prompt used can be:
.*\@.*\:~> >exec su - {Username}
 


Actions
  • Print
  • Copy Link

    https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA1hj0000000waICAQ&lang=en_US&refURL=http%3A%2F%2Fknowledgebase.paloaltonetworks.com%2FKCSArticleDetail