Stored Passwords
PrivX can store the password for a target account and use it to authenticate to the host. Users whose roles grant access to the account can connect without entering the target account password.
To configure PrivX to change target account passwords automatically, see Rotating Stored Passwords.
For a walkthrough that starts with the user entering the root password and then shows how to enable certificate authentication, see Quick SSH Access.
Configuring Stored Passwords
-
For SSH connections, configure the SSH server on the target host to allow password authentication. If the server allows only keyboard-interactive authentication, PrivX cannot use the stored password to connect.
-
In the PrivX Web UI, go to Administration → Hosts and click Edit for the target host.
-
Under Accounts, enter the target account’s password in Password. Under Roles, select the roles that can access the account. Repeat this step for each account you want to configure.
-
Save changes.
To verify the configuration, connect to the target account as a PrivX user with one of the selected roles. The connection should open without prompting for the target account password.
Granting SSH Access to Root Through Roles
You can grant a local PrivX user SSH access to a target host’s root account without sharing the root password. The user’s role grants access to the account, and PrivX uses the stored password to authenticate to the host.
Before you begin, make sure the target host allows SSH password authentication for root and that you know the root password.
To grant access and verify the connection:
-
Log in to the PrivX Web UI as an administrator.
-
Go to Administration → Users and click Add User. Enter a username, complete the other required fields, and click Save. This example uses
ttesteras the username.
-
Go to Administration → Roles and click Add Role.
- Enter a name for the role. This example uses
Root for ttester. - Under Mapping Rules, click Add Rule and select Local users as the directory. In Search String, enter
(principal=<username>), replacing<username>with the username you created. For this example, enter(principal=ttester). Press Enter or click outside the field. Verify that Matching Users shows one match, then click Save.
- Enter a name for the role. This example uses
-
Go to Administration → Hosts and edit the target host.
-
Under Services, verify that the host has an SSH service. If you need to add one, click Add Service, select SSH, and enter the SSH server address and port.
In this example, enabled Trust on first use lets
ttesterverify and save the SSH host key on the first connection. If you leave this setting disabled,ttesterwill see the host key prompt on every connection until an administrator or host manager saves the key.
-
Under Accounts, select the
rootaccount. If the account is missing, click Add Account and enterrootas the username. In Password, enter the target host’srootpassword. For Roles, select the role you created and click Save.
-
-
To verify target host connectivity:
-
Log out of PrivX and log in as the local user you created.
ttesterwas used in this example. -
Go to Connections → Hosts, expand the target host, and connect to its SSH service as
root. If prompted, verify the SSH host key before accepting it. The session should open without prompting for therootpassword, as userttesteris grantedrootaccess on the target host.
-