The Credentials Library enables you to centrally store and manage credentials for use in your tests. This improves security and access control, as secret credential values are not displayed to portal users, and it is possible to limit which users have access to use specific credentials. The Library also makes it easy to use the same credentials across multiple different Product, Folder, or Test configurations. You can store an unlimited number of credentials in the Credentials Library.
Adding a Credential
- Navigate to Control Center > Library > Credentials
- Click New
- Select a credential type (Token, Password, or Certificate)
- Input a friendly name for this credential in the Credential Name field. (e.g. "API Token")
- Optionally enter a description, such as the purpose of the credential.
- Input the credential. (User Name & Password, Certificate, or Token String). Once saved, Token values, Certificate Passphrases and passwords are masked in the Portal UI.
- Optionally input one or more labels for this credential. (labels can make it easier for users to locate credentials in the Library later.)
- If you want to limit access to this credential to certain portal users, change the "Access" setting to Custom and then input the names of contacts that may access the Token.*
- Click Save
*The "Access" setting is not available by default. Please reach out to your account team if you would like this option added to your Catchpoint Portal.
Using Stored Credentials
Once you have saved a Credential in the Library, you can access it when configuring a Product, Folder, or Test. (Credentials with Custom Access enabled can only be accessed within individual Tests. This is because the inheritance of the Credential from a Product or Folder could circumvent Custom Access limits.) Follow these steps to access a stored credential in your configuration:
- Create or edit an existing Product, Folder, or Test
- Navigate to the Requests section (if the inheritance is enabled for Requests, then you must disable it or edit the Requests section of the parent Product or Folder).
- Click Add Username and Password, Add Tokens or Add Certificate.
- Click Add from Library. A list of credentials you have access to is displayed.
- Select the desired credential(s) from the list.
- Perform the following steps for each credential value that you want to add to the header (i.e. each token, each username, and each password.)
- Click Add HTTP Headers
- Select whether you want to apply this credential to requests to the Test URL or a Child Host. If a Child Host, input its hostname.
- Select the specific header field that you want to associate with the credential. Select Custom to input a custom header field name.
- Input the appropriate macro in the Value field:
- ${token}
- ${userName}
- ${password}
- ${certificate}
Note that the above macros will be replaced with the FIRST credential value configured in the Requests section. If you have added multiple credentials of the same type and need to specify one of them, then include the credential name in parentheses: - ${token(credential_name)}
- ${userName(credential_name)}
- ${password(credential_name)}
- ${certificate(credential_name)}
For example, if you are referencing a Token called "API_Token" then you would input: ${token(API_Token)}
- Click Save. The specified credentials will be included in the header for authentication by this test (or child tests, if configuring a Product or Folder.)
- If a contact wants to create/delete library credentials, their corresponding user role must have at least the delete property enabled under Manage Contacts. If the delete property is not enabled then the user will receive an error message when attempting to create credentials.
- Token macro has not been yet implemented for Single URL web monitors (Object/Chrome/Emulated/Mobile etc.).