立即与支持人员聊天
与支持团队交流

One Identity Safeguard for Privileged Sessions 6.0.9 - REST API Reference Guide

Introduction Using the SPS REST API Basic settings User management and access control Managing SPS General connection settings HTTP connections Citrix ICA connections RDP connections SSH connections Telnet connections VNC connections Search, download, and index sessions Reporting Health and maintenance Advanced authentication and authorization Completing the Welcome Wizard using REST Enable and configure analytics using REST

Join node(s) to the cluster

Once you have a Central Management Safeguard for Privileged Sessions node in place, then you can join other nodes to your cluster.

To join nodes to your cluster, complete the following steps for each node that you want to join to the cluster:

  1. Open a transaction.

    For details, see Open a transaction.

  2. Create a join request.

    POST the IP address of the Central Management node as a JSON object to the https://<IP-address-of-node-to-join-to-cluster>/api/cluster/join_request endpoint. The body of the POST request should be the following:

    {
        "central_management_address": "<IP-address-of-Central-Management-node>"
    }

    For example:

    curl -X POST -H "Content-Type: application/json" --cookie cookies https://<IP-address-of-node-to-join-to-cluster>/api/cluster/join_request --data '{"central_management_address": "<IP-address-of-Central-Management-node>"}'

    The following is a sample response received.

    For details of the meta object, see Message format.

    By default, no role is assigned to a non-management node, that is why the "roles" array is empty.

    {
        "body": {
            "address": "<IP-address-of-node-joined-to-cluster>",
            "node_id": "46f97a58-4028-467d-9a22-9cfe78ae3e1c",
            "psk": "Ler7HZDFmZCxnLLgHNRfZYfORhlZS99l9vEVr5UKtJEb1d4WeaHcBmQJLs4VDWIn",
            "roles": []
        },
        "meta": {
            "href": "/api/cluster/join_request",
            "parent": "/api/cluster",
            "remaining_seconds": 600
        }
    }
    Elements Type Description
    body Top-level element (JSON object) Contains the JSON object of the node.
    address string The IP address of the node.
    node_id string A reference ID for the node.
    psk string The pre-shared key of the node used for authentication.
    roles string The role of the node.
  3. Join the node to the cluster.

    POST the "body" object of the response to the https://<IP-address-of-Central-Management-node>/api/cluster/nodes endpoint as a JSON object. The body of the POST request should be the following:

    {
        "address": "<IP-address-of-node-joined-to-cluster>",
        "node_id": "46f97a58-4028-467d-9a22-9cfe78ae3e1c",
        "psk": "Ler7HZDFmZCxnLLgHNRfZYfORhlZS99l9vEVr5UKtJEb1d4WeaHcBmQJLs4VDWIn",
        "roles": []
    },

    For example:

    POST -H "Content-Type: application/json" --cookie cookies https://<IP-address-of-Central-Management-node>/api/cluster/nodes --data '{"address": "<IP-address-of-node-joined-to-cluster>", "node_id": "46f97a58-4028-467d-9a22-9cfe78ae3e1c", "psk": "Ler7HZDFmZCxnLLgHNRfZYfORhlZS99l9vEVr5UKtJEb1d4WeaHcBmQJLs4VDWIn","roles": []}'

    If the POST request is successful, the response includes:

    {
        "body": {
            "address": "<IP-address-of-node-joined-to-cluster>",
            "roles": []
        },
        "key": "46f97a58-4028-467d-9a22-9cfe78ae3e1c",
        "meta": {
            "href": "/api/cluster/nodes/46f97a58-4028-467d-9a22-9cfe78ae3e1c",
            "parent": "/api/cluster/nodes",
            "remaining_seconds": 28800
        }
    }
  4. Commit your changes on both the Central Management node and the node you joined to the cluster.

    For details, see Commit a transaction.

Query join status

To find out whether a node has been joined to a cluster, complete the following steps.

  1. Query the /api/cluster/join_request endpoint on the node whose join status you want to figure out.

    curl GET --cookie cookies https://<IP-address-of-node-to-be-queried>/api/cluster/join_request
    			   

    The following is a sample response received.

    For details of the meta object, see Message format.

        "details": {
            "central_management_address": "<IP-address-of-Central-Management-node>"
        },
        "meta": {
            "href": "/api/cluster/join_request",
            "parent": "/api/cluster",
            "remaining_seconds": 600
        },
        "status": "in cluster"
    }
    Elements Type Description
    details Top-level element Contains the IP address of the Central Management node of the cluster.
    central_management_address string

    The IP address of the Central Management node.

    Not provided when no cluster has been set up yet.

    status string

    Possible values are:

    • not configured: Displayed when no cluster has been set up yet.
    • in progress: Displayed when the join action is in progress.
    • in cluster: Displayed when the node is already in the cluster.

Assign a role to a node

By default, nodes do not have any roles assigned to them. The only exception is the Central Management node, which you specifically promoted to fulfill that role. To assign a role to a node in the cluster, complete the following steps.

  1. Open a transaction.

    For details, see Open a transaction.

  2. Update the JSON object of the node.

    PUT the role you want to assign to the node and the node's IP address as a JSON object to the https://<IP-address-of-Central-Management-node>/api/cluster/nodes/<node-id-of-node-to-be-updated> endpoint.

    You can assign the following roles to a node:

    NOTE:

    The central-management role can only be assigned using the /api/cluster/promote endpoint.

    NOTE:

    Ensure that each node has a search role and only one search role.

    Role Description
    managed-host

    There can be several nodes with this role.

    Nodes with the Managed Host role synchronize their entire configuration from the Central Management node, not only those elements of the configuration that are related to the cluster.

    search-master

    There can be only one node with this role.

    The Search Master node is the one node in the cluster on which you can search all the session data recorded by other nodes in the cluster, provided that the other nodes have been assigned the Search Minion role.

    search-minion

    There can be several nodes with this role.

    Nodes with the Search Minion role send session data that they recorded to the Search Master for central search purposes. The session data recorded by a Search Minion node is not searchable on the node itself, only on the Search Master.

    search-local

    There can be several nodes with this role.

    Nodes with the Search Local role keep the session data that they recorded for local searching. The session data recorded by a Search Local node is searchable on the node itself, but not on the Search Master.

    This is the only backward-compatible search role.

    For further details on roles, see "Cluster roles" in the Administration Guide.

    The body of the PUT request should be the following:

    {
        "roles": ["<role-to-assign>"],
        "address": "<IP-address-of-node-to-be-updated>"
    }

    For example:

    curl -H "Content-Type: application/json" --cookie cookies -X PUT https://<IP-address-of-Central-Management-node>/api/cluster/nodes/46f97a58-4028-467d-9a22-9cfe78ae3e1c --data '{"roles": ["managed-host"], "address": "<IP-address-of-node-to-be-updated>"}'
  3. Commit your changes.

    For details, see Commit a transaction.

Query nodes

To list the nodes available in a cluster, complete the following steps.

  1. Query the /api/cluster/nodes endpoint on the Central Management node.
    curl --cookie cookies https://<IP-address-of-Central-Management-node>/api/cluster/nodes

    The following is a sample response received.

    For details of the meta object, see Message format.

    {
        "items": [
            {
                "key": "46f97a58-4028-467d-9a22-9cfe78ae3e1c",
                "meta": {
                    "href": "/api/cluster/nodes/46f97a58-4028-467d-9a22-9cfe78ae3e1c",
                    "status": "/api/cluster/status/46f97a58-4028-467d-9a22-9cfe78ae3e1c"
                }
            },
            {
                "key": "b35c54da-b556-4f91-ade5-d26283d68277",
                "meta": {
                    "href": "/api/cluster/nodes/b35c54da-b556-4f91-ade5-d26283d68277",
                    "status": "/api/cluster/status/b35c54da-b556-4f91-ade5-d26283d68277"
                }
            }
        ],
        "meta": {
            "href": "/api/cluster/nodes",
            "parent": "/api/cluster",
            "remaining_seconds": 28800,
            "self": "/api/cluster/nodes/b35c54da-b556-4f91-ade5-d26283d68277",
            "status": "/api/cluster/status"
        }
    }
    Elements Type Description
    items Top-level element (list of JSON objects) List of endpoints (objects) available from the current endpoint.
    key string The ID of the node.
    meta Top-level item (JSON object) Contains links to different parts of the REST service.
    href string (relative path) The path of the node that returned the response.
    status string (relative path) The path to the status of the node that returned the response.
相关文档

The document was helpful.

选择评级

I easily found the information I needed.

选择评级