Add a public SSH key
This method adds an authorized public SSH key for a specific user in the Vault, allowing them to authenticate to the Vault through PSM for SSH using a corresponding private SSH key.
The user who runs this web service requires Reset Users' Passwords permissions in the Vault.
In addition, the user who runs this web service must be in the same Vault location as or higher than the user whose public SSH keys are added.
A user cannot manage their own public SSH keys. |
URL
-
Make sure there are no spaces in the URL.
-
The following characters are not supported in URL values: + & %
-
If the URL includes a dot (.), add a forward slash (/) at the end of the URL. For example: api/Safes/MySafe/Members/user@cyber.com/
|
https://<IIS_Server_Ip>/PasswordVault/WebServices/PIMServices.svc/Users/{UserName}/AuthenticationMethods/SSHKeyAuthentication/AuthorizedKeys/ |
The following mandatory value is required in the URL:
Parameter |
UserName |
||
Type |
String |
||
Description |
The name of the user whose public SSH keys will be added.
|
||
Valid values |
Vault user name |
Resource information
HTTP method |
POST |
Content type |
application/json |
Header parameter
Parameter |
Authorization |
Type |
String |
Description |
The token that identifies the session. |
Valid values |
A session token that was returned from the “Logon” method. |
Body parameters
The public SSH key must be included as a JSON object in the request body. |
|
Parameter |
PublicSSHKey |
Type |
String |
Description |
The content of the public SSH key as it appears in the authorized_keys file. This parameter is required. |
Mandatory |
Yes |
Valid values |
A public SSH key.
|
Result
|
Return codes
For a complete list of return codes, see Return Codes.