### Configure AppLocker for Java Web Start (64-bit) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_oracle_sql.htm Add the 64-bit Java Web Start executable to the AppLocker configuration. Update the Path to reflect your installed JRE version. ```xml ``` -------------------------------- ### PSM Configuration Example Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm This example demonstrates a typical PSM configuration, including identifier and password settings, conditional logic for user sign-in, and validation elements. ```psm identifierId > {username} identifierNext > (Button) password > {password} passwordNext > (Button) if((conditionElementId1 > (Condition) (searchby=id)(exists eq true))) signExistingUserOutElementId > (Button) (searchby=id) end-if else nextPasswordBtnXYZ > (Button) (searchby=id) end-else gb > (Validation) gbq1 > (Validation) ``` -------------------------------- ### Configure AppLocker for Java Web Start (32-bit) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_oracle_sql.htm Add the 32-bit Java Web Start executable to the AppLocker configuration. Update the Path to reflect your installed JRE version. ```xml ``` -------------------------------- ### Writing Information to Logs using WriteToLogMethod Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication_preconnect.htm This example shows how to use the WriteToLogMethod to log messages with different log levels. It demonstrates logging an informational message at the start of a method. ```csharp WriteToLogMethod("Start Method", Consts.LOG_LEVEL_INFO); ``` -------------------------------- ### WebFormFields Example for Gmail Login Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm This example demonstrates how to configure WebFormFields for Gmail login, including entering username and password, and pressing buttons. It also includes validation steps. ```plaintext identifierId > {username} identifierNext > (Button) password > {password} passwordNext > (Button) gb > (Validation) gbq1 > (Validation) ``` -------------------------------- ### Get All Connection Components Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/sdk/api%20commands%20-%20session%20management.htm Retrieves a list of all configured connection components. ```APIDOC ## Get All Connection Components ### Description Retrieves a list of all configured connection components. ### Method GET ### Endpoint /api/v1/session-management/connection-components ``` -------------------------------- ### Get Platforms Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/managing%20platforms.htm Retrieves a list of available platforms. ```APIDOC ## GET /platforms ### Description Retrieves a list of all available platforms. ### Method GET ### Endpoint /platforms ``` -------------------------------- ### WebFormFields Example for Site Using iFrame Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm This example shows how to configure WebFormFields for a site that uses an iframe without an identifier. It includes entering credentials, clicking a login button, and validation steps. ```plaintext gsft_main> (iframe) user_name>{Username} user_password>{Password} sysverb_login>(Button) (mainwindow) nav-settings-button>(Validation)(searchby=id) application_picker_select>(Validation)(searchby=id) ``` -------------------------------- ### WebFormFields Example for Generating MFA Code Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm This example demonstrates configuring WebFormFields to handle MFA code generation and entry. It includes entering credentials, running the MFA code generation, and validating elements. ```plaintext user_name>{Username} user_password>{Password} sysverb_login>(Button) Run Generate_TOTP_MFA_Code (MFADeviceSecret=ZR47PH6OKPRAQRJLQ3KWNL37IP4RWI4NWQIV7BSXEJ63OAPVCWYAQL6AZDLAI55R) mfa_device_code_enter > &MFACode& (searchby=class) nav-settings-button>(Validation)(searchby=id) application_picker_select>(Validation)(searchby=id) ``` -------------------------------- ### Throwing a Custom Preconnect Exception Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication_preconnect.htm This example demonstrates how to throw a custom PreconnectException with a specific error message to be displayed to the end user. This ensures a user-friendly error reporting mechanism. ```csharp throw new PreonnectException("Preconnect exception"); ``` -------------------------------- ### Configure AppLocker for Java (64-bit) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_oracle_sql.htm Add the 64-bit Java Runtime Environment executable to the AppLocker configuration. Update the Path to reflect your installed JRE version. ```xml ``` -------------------------------- ### Configure AppLocker for Java Launcher (64-bit) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_oracle_sql.htm Add the 64-bit Java launcher executable to the AppLocker configuration. Update the Path to reflect your installed JRE version. ```xml ``` -------------------------------- ### Get Applications Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/applications.htm Retrieves a list of all applications managed within Privilege Cloud. ```APIDOC ## Get Applications ### Description Retrieves a list of all applications. ### Method GET ### Endpoint /api/v1/applications ``` -------------------------------- ### If/Else Conditional Statement Example Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm Demonstrates the syntax for if/else and else-if conditional statements. These statements allow for complex decision-making based on element existence, placeholder values, or element counts. ```plaintext %Identifier% > %Input Value% (SearchBy=Text\id\name\class)(sendslow=0.5) if ((%Identifier% > (Condition) (SearchBy=Text\id\name\class) ( Exists [eq] %True\False% )) [and\or] ({myAccountParameter} > (Condition) ( Placeholder eq myAssumedAccountParameterValue ))) %Identifier% > %Input Value% (SearchBy=Text\id\name\class) %Identifier% > (%Button\Click\Verification\Validation\Iframe%) (SearchBy=Text\id\name\class) end-if else-if ((%Identifier%> (Condition) (SearchBy=Text\id\name\class) ( Count [eq\ne\gt\ge\lt\le] %Numeric-value% ))) %Identifier% > %Input Value% (SearchBy=Text\id\name\class) %Identifier% > (%Button\Click\Verification\Validation\Iframe%) (SearchBy=Text\id\name\class) %Identifier% > (Validation)(SearchBy=Text\id\name\class) end-else-if else %Identifier% > %Input Value% (SearchBy=Text\id\name\class) %Identifier% > (%Button\Click\Verification\Validation\Iframe%) (SearchBy=Text\id\name\class) end-else %Identifier% > (Validation)(SearchBy=Text\id\name\class) ``` -------------------------------- ### Configure AppLocker for SQLDeveloper Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_oracle_sql.htm Add the SQLDeveloper executable to the AppLocker configuration. Ensure the Path is updated to the correct installation location. ```xml ``` -------------------------------- ### Get Platform Details Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/managing%20platforms.htm Retrieves detailed information about a specific platform. ```APIDOC ## GET /platforms/{platformId} ### Description Retrieves detailed information for a specific platform identified by its ID. ### Method GET ### Endpoint /platforms/{platformId} ### Parameters #### Path Parameters - **platformId** (string) - Required - The unique identifier of the platform. ``` -------------------------------- ### Get Application Details Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/applications.htm Retrieves detailed information about a specific application. ```APIDOC ## Get Application Details ### Description Retrieves detailed information about a specific application. ### Method GET ### Endpoint /api/v1/applications/{applicationId} ``` -------------------------------- ### Configure AppLocker for Java (32-bit) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_oracle_sql.htm Add the 32-bit Java Runtime Environment executable to the AppLocker configuration. Update the Path to reflect your installed JRE version. ```xml ``` -------------------------------- ### Configure AppLocker for Java Launcher (32-bit) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_oracle_sql.htm Add the 32-bit Java launcher executable to the AppLocker configuration. Update the Path to reflect your installed JRE version. ```xml ``` -------------------------------- ### Example LogonURL for Web Application Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm Specifies the URL of the web application's login page. This URL can include dynamic parameters that are replaced with account property values. ```text https://accounts.google.com/ServiceLogin ``` ```text https://{Address} ``` ```text http://{Address}/Welcome/Login ``` -------------------------------- ### Incorrect Validation Sequence Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm This example is incorrect because it attempts to navigate immediately after validation without a command to break the validation context, such as Wait. ```pasimp username-element-id > {username} (searchby=id) password-element-id > {password} (searchby=id) submit-button-id > (Button) (searchby=id) valid-validation-element-1-id > (Validation) (searchby=class) (Navigate=https://next-page-url) ``` -------------------------------- ### Configure PreConnect DLL Name and Parameters Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication_preconnect.htm Configure the PreConnect DLL name and its parameters in the Connection Components settings. This example shows how to set the DLL name and pass the 'username' parameter. ```text PreConnectDllName with value: CyberArk.PSM.WebAppDispatcher.RevertParametersPreconnect.dll PreConnectParameters with value: username ``` -------------------------------- ### Webform Field XPath Example Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm Example of an XPath identifier for a webform field. Note the use of a caret (^) before brackets when using XPath to escape them. ```text //*[@id="contentBody"]/div/div[2]/div[2]/h1 //*^[@id="contentBody"^]/div/div^[2^]/div^[2^]/h1 ``` -------------------------------- ### Run Deploy-Connectors.ps1 script Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/configurepsmuniversalconnector.htm Execute the Deploy-Connectors.ps1 script to deploy a universal connector for testing purposes. Ensure you are in the PSM Scripts directory. ```powershell CD “C:\Program Files (x86)\CyberArk\PSM\Scripts" ./Deploy-Connectors.ps1 ``` -------------------------------- ### Import Platform Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/managing%20platforms.htm Imports a new platform configuration. ```APIDOC ## POST /platforms/import ### Description Imports a new platform configuration into the system. ### Method POST ### Endpoint /platforms/import ### Request Body - **platformConfiguration** (object) - Required - The configuration details of the platform to import. ``` -------------------------------- ### Get Accounts Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/managing%20accounts.htm Retrieves a list of accounts. ```APIDOC ## GET /accounts ### Description Retrieves a list of accounts. ### Method GET ### Endpoint /accounts ``` -------------------------------- ### Get all Safes Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/sdk-safe-methods.htm API endpoint to retrieve a list of all safes. ```APIDOC ## Get all Safes ### Description Retrieves a list of all available safes. ### Method GET ### Endpoint /api/v1/safes ``` -------------------------------- ### Get Secret Versions Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/managing%20accounts.htm Retrieves the versions of a secret associated with an account. ```APIDOC ## GET /accounts/{accountId}/secrets/versions ### Description Retrieves the versions of a secret associated with an account. ### Method GET ### Endpoint /accounts/{accountId}/secrets/versions ### Parameters #### Path Parameters - **accountId** (string) - Required - The ID of the account whose secret versions are to be retrieved. ``` -------------------------------- ### Create PSMApp Credentials File (Connector 11.7-) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/systemhealth.htm Create or replace credentials files for the PSMApp user using CreateCredFile.exe with UseOSProtectedStorage. Ensure you are in the correct directory and provide necessary parameters. ```powershell CreateCredFile.exe psmapp.cred Password /Username {username} /Password {password} /AppType PSMApp /UseOSProtectedStorage Machine ``` -------------------------------- ### Get Account Activity Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/managing%20accounts.htm Retrieves the activity log for a specific account. ```APIDOC ## GET /accounts/{accountId}/activity ### Description Retrieves the activity log for a specific account. ### Method GET ### Endpoint /accounts/{accountId}/activity ### Parameters #### Path Parameters - **accountId** (string) - Required - The ID of the account for which to retrieve activity. ``` -------------------------------- ### Navigate to Main Window Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/psm_webapplication.htm Use this format to return to the main window from an iframe. This format will also work when an identifier is available, but with lower performance. ```plaintext MainWindow ``` -------------------------------- ### Get Account Details Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/managing%20accounts.htm Retrieves detailed information about a specific account. ```APIDOC ## GET /accounts/{accountId} ### Description Retrieves detailed information about a specific account. ### Method GET ### Endpoint /accounts/{accountId} ### Parameters #### Path Parameters - **accountId** (string) - Required - The ID of the account to retrieve. ``` -------------------------------- ### Get active sessions Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/monitoring.htm Retrieves a list of all currently active sessions. ```APIDOC ## GET /sessions/active ### Description Retrieves a list of all currently active sessions. ### Method GET ### Endpoint /sessions/active ### Response #### Success Response (200) - **sessions** (array) - A list of active session objects. #### Response Example { "sessions": [ { "sessionId": "123e4567-e89b-12d3-a456-426614174000", "startTime": "2023-10-27T10:00:00Z", "user": "john.doe", "application": "SSH" } ] } ``` -------------------------------- ### Add Account Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/managing%20accounts.htm Adds a new account to the system. ```APIDOC ## POST /accounts ### Description Adds a new account to the system. ### Method POST ### Endpoint /accounts ### Request Body - **accountDetails** (object) - Required - The details of the account to add. ``` -------------------------------- ### Create PSMApp Credentials File (Connector 12.1.1+) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/systemhealth.htm Create or replace credentials files for the PSMApp user using CreateCredFile.exe with DPAPIMachineProtection. Ensure you are in the correct directory and provide necessary parameters. ```powershell Copy to clipboardCreateCredFile.exe psmapp.cred Password /Username {username} /Password {password} /AppType PSMApp /DPAPIMachineProtection /EntropyFile ``` -------------------------------- ### Create PSMGW Credentials File (Connector 11.7-) Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/pasimp/systemhealth.htm Create or replace credentials files for the PSMGW user using CreateCredFile.exe with UseOSProtectedStorage. Ensure you are in the correct directory and provide necessary parameters. ```powershell Copy to clipboardCreateCredFile.exe psmgw.cred Password /Username {username} /Password {password} /AppType PSMApp /UseOSProtectedStorage Machine ``` -------------------------------- ### Get active session properties Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/monitoring.htm Retrieves the properties of a specific active session. ```APIDOC ## GET /sessions/active/{sessionId}/properties ### Description Retrieves the properties of a specific active session. ### Method GET ### Endpoint /sessions/active/{sessionId}/properties ### Parameters #### Path Parameters - **sessionId** (string) - Required - The unique identifier of the session. ### Response #### Success Response (200) - **properties** (object) - An object containing the properties of the session. #### Response Example { "properties": { "protocol": "SSH", "clientIp": "192.168.1.100", "os": "Linux" } } ``` -------------------------------- ### Get active session Source: https://docs.cyberark.com/privilege-cloud-shared-services/latest/en/content/webservices/monitoring.htm Retrieves details for a specific active session by its ID. ```APIDOC ## GET /sessions/active/{sessionId} ### Description Retrieves details for a specific active session by its ID. ### Method GET ### Endpoint /sessions/active/{sessionId} ### Parameters #### Path Parameters - **sessionId** (string) - Required - The unique identifier of the session. ### Response #### Success Response (200) - **session** (object) - An object containing the details of the active session. #### Response Example { "session": { "sessionId": "123e4567-e89b-12d3-a456-426614174000", "startTime": "2023-10-27T10:00:00Z", "user": "john.doe", "application": "SSH", "status": "active" } } ```