Skip to main content
Version: v46

Public-Key Authentication (SSH Bastion)

PrivX users can upload their personal public keys, to be used for authenticating connections through PrivX SSH Bastion. For more information, see Connecting Through PrivX Bastion.

Uploading and Using Authorized Keys​

To upload a user's public key:

  1. Go to Administration → Users, select the user, and click Edit.

  2. Under Authorized Keys, click Add Authorized Key and enter the required information.

    Each key must have a validity period. If you do not specify one, PrivX uses the configured maximum validity period (730 days by default), starting one hour before the current time.

To allow users to upload their own public keys, grant them the authorized-keys-manage permission.

PrivX users with authorized keys can authenticate connections through SSH Bastion using the corresponding private key, without entering their PrivX password. For example, when using ssh:

ssh -i /path/to/private_key <bastion_syntax>

Uploaded keys must be unique within PrivX. You cannot upload the same key twice.

Public-key authentication to PrivX SSH Bastion does not support client interaction, such as keyboard-interactive authentication, multi-factor authentication, or accepting host keys. OpenID Connect (OIDC) users can use authorized keys only when Expire Implicit Roles is enabled for their OIDC directory. For more information, see OpenID-Connect (OIDC) Authentication.

Authorized-Key Expiry​

PrivX periodically checks and deletes expired authorized keys (every 24 hours by default). For keys with an original lifetime exceeding 30 days, PrivX generates audit events 30 and 7 days before the expiry date.

To configure authorized-key expiry, go to Administration → Settings → Role Store, under Authorized Keys:

  • Maximum Validity Period (Days): Set the maximum validity period for authorized keys. Restart PrivX to apply changes.
  • Expired Keys Purge Interval (Hours): Set how often PrivX checks for and deletes expired authorized keys. Changes apply when you save the settings, without restarting PrivX. Set the interval to 0 to disable automatic deletion of expired authorized keys. For information about how interval changes affect task execution, see Configuring Housekeeping Tasks.

For descriptions of all settings, see PrivX Settings.

Supported Authorized-Key Types​

Supported formats:

  • ssh authorized keys format
  • ssh2 public key format (RFC4716)

Default allowed algorithms:

  • ssh-ed25519
  • ssh-rsa (minimum 2048 bits)

All supported algorithms:

  • ecdsa-sha2-nistp224 / 256 / 384 / 521
  • ssh-ed25519
  • ssh-dss
  • ssh-rsa

To configure the allowed key algorithms and minimum RSA key length, go to Administration → Settings → Role Store, under Authorized Keys.

Restart PrivX to apply changes to these settings.