Private Keys for PSMP-SSH

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Private Keys for PSMP-SSH

L5 Sessionator

I have onboarded following meta data in the Cyberark and PSM-SSH works fine for any target using same Keys however, I am having issue with connect via PSMP-SSH.

 

username: ec2-user

address: aws.console.com

 

Notes:

PEM Keys have been onboarded into the Cyberark and PSM-SSH works fine whenever user clicks on "connect" and they populate target IPs in "Remote Machine" and they are able to connect but with PSMP-SSH, it throws below error.

 

Error:

Failed to obtain account. Error: [010E Retrieve target account [ec2-user] with address [140.34.56.32] failed. Error: [314E The requested account could not be found.

Please make sure a domain account with the specified domain machine is defined in the system.]] (Diagnostic Info: 1)

 

Hence, I know that account exist and I have been using below syntax which I use for password based linux machines to connect to target and it doesn't work. Could you please let me know what I need to make it possible?

 

Connection string :

 

 ssh [email protected]%ec2-user#aws.console.com%[email protected]

1 accepted solution

Accepted Solutions

L5 Sessionator

Solution:

Address field can be dummy which is not big deal. If we are trying to connect to remote machine using PSMP-SSH then it gives error as account could not be found. To resolve the issue we have to have following steps verified and connection becomes successful and object not found errors goes away.

 

Note: We do not have to point PEM keys locally in connection syntax/string for PSMP-SSH. Hence, PEM keys syntax/string also works same as password based for PSMP-SSH

 

The target user, and target dummy domainaddress above are used to query the Vault for a matching configured Password Object stored in the vault.

A) The vault user in the above string, making the request to use the target user, must have the correct permissions in the vault to view, and use this account.

B) The PSMP sting needs to match the following values, for what the password object is stored in the vault:

- Target User, needs to match for the "username" configured for the password object

- Target dummy Domainaddress needs to match for "Address" this can be an IP or FQDN, but the string needs to match how this is stored for the password object.

C) PSMP-SSH and "PSMRemoteMachine" needs to be configured for the connection component that is attached to the account platform.

View solution in original post

9 REPLIES 9

L4 Transporter

Hello,

You may need additional configurations.

 

If the user authenticates to CyberArk with a password, you can add the percent sign as an additional delimiter to the PSMP configuration to support the pound sign for the target user domain address.

https://docs.cyberark.com/pam-self-hosted/latest/en/content/pasimp/configuring-psmp-syntax-delimiters.htm?Highlight=additional%20delimiter

 

If the user authenticates to CyberArk with a smartcard you will need the delimiter above and add a custom attribute or use an existing attribute in Active Directory to store the ssh-rsa key value for the smartcard logon certificate and add that attribute to the LDAP profile.

https://docs.cyberark.com/pam-self-hosted/latest/en/content/pasimp/configuring-management-of-users-public-ssh-keys.htm#top

Connecting with password we have no issue. I am just worried about to make connection using Private Key via terminal. i read that doc. little confused. however, i will go again

L4 Transporter

Hello,

It can be somewhat confusing for sure.

 

When going through the PVWA you use PSM-SSH and the authentication event has already occurred logging into the PVWA.

 

When using PSMP you need a method of authenticating to the vault which will depend on environment requirements.

For example, if using smartcards to authenticate not only do you need to set the configurations to support that such as leveraging Active Directory to store the ssh-rsa key value of the smartcard logon certificate, you also have to set the client software being used to leverage the certificate. In Putty-CAC you set the CAPI certificate to be associated and saved with the configured sessions.

 

However, the specific error posted appears to show the target user is not found which is likely due to not having the delimiter setup on the PSMP server(s). Try adding the percent sign as an additional delimiter and use the same string posted.

We have already additional delimiter set.

Hey @sanjay sah​ If the account is onboarded as ec2-user aws.console.com, but Remote Machine address: 140.34.56.32 and it can't be found, that means there must still be an issue with the syntax.

 

i.e.

VaultUsername@VaultUserDomain%ec2-user#aws.console.com%140.34.56.32@PSMPServer

this above syntax works for password-based connection to the target just not for private key's object ones

L4 Transporter

In my opinion, as you provide DNS name of the target as address in onboarded account, you should also use it in connection string, not the numeric IP address - and this is simply what the error says

Error is not saying that one. It is saying that have corresponding address affliated with address for remote machine whether it can be IP or DNS

L5 Sessionator

Solution:

Address field can be dummy which is not big deal. If we are trying to connect to remote machine using PSMP-SSH then it gives error as account could not be found. To resolve the issue we have to have following steps verified and connection becomes successful and object not found errors goes away.

 

Note: We do not have to point PEM keys locally in connection syntax/string for PSMP-SSH. Hence, PEM keys syntax/string also works same as password based for PSMP-SSH

 

The target user, and target dummy domainaddress above are used to query the Vault for a matching configured Password Object stored in the vault.

A) The vault user in the above string, making the request to use the target user, must have the correct permissions in the vault to view, and use this account.

B) The PSMP sting needs to match the following values, for what the password object is stored in the vault:

- Target User, needs to match for the "username" configured for the password object

- Target dummy Domainaddress needs to match for "Address" this can be an IP or FQDN, but the string needs to match how this is stored for the password object.

C) PSMP-SSH and "PSMRemoteMachine" needs to be configured for the connection component that is attached to the account platform.

  • 1 accepted solution
  • 113 Views
  • 9 replies
  • 0 Likes
Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!

The LIVEcommunity thanks you for your participation!