Tchater maintenant avec le support
Tchattez avec un ingénieur du support

One Identity Safeguard for Privileged Sessions 7.2 - 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 MSSQL connections RDP connections SSH connections Telnet connections VNC connections Search, retrieve, download, and index sessions Reporting Health and maintenance Advanced authentication and authorization Completing the Welcome Wizard using REST Enable and configure analytics using REST REST API examples

Configuration default values

Querying the default values for singleton resources, for example syslog servers

Querying the default values for singleton resources, for example syslog servers request

curl --cookie cookies --request PUT --data '@-' https://<IP-address-of-SPS>/api/configuration/management/syslog?defaults <<'REQUEST'
{
    "receivers": [
        {}
    ]
}
REQUEST

Querying the default values for singleton resources, for example syslog servers response

{
    "body": {
        "encryption": {
            "client_authentication": null,
            "trust_store": null
        },
        "include_node_id": true,
        "receivers": [
            {
                "address": {
                    "selection": "ip",
                    "value": "127.0.0.1"
                },
                "port": 1,
                "protocol": {
                    "ip_protocol": "tcp",
                    "protocol_type": "legacy-bsd",
                    "tls_enabled": false
                }
            }
        ]
    },
    "key": "syslog",
    "meta": {
        "first": "/api/configuration/management/accounting",
        "href": "/api/configuration/management/syslog",
        "last": "/api/configuration/management/web_gateway_authentication",
        "next": "/api/configuration/management/system_backup",
        "parent": "/api/configuration/management",
        "previous": "/api/configuration/management/support_info",
        "transaction": "/api/transaction"
    }
}
Querying defaults for objects in a container, for example SSH authentication policies

Querying defaults for objects in a container, for example SSH authentication policies request

curl --cookie cookies --request POST --data '@-' https://<IP-address-of-SPS>/api/configuration/ssh/authentication_policies?defaults <<'REQUEST'
{
    "backend": {
        "selection": "radius"
    }
}
REQUEST

Querying defaults for objects in a container, for example SSH authentication policies response

{
    "body": {
        "backend": {
            "authentication_protocol": "pap",
            "selection": "radius",
            "servers": [
                {
                    "address": {
                        "selection": "ip",
                        "value": "127.0.0.1"
                    },
                    "port": 1,
                    "shared_secret": {
                        "key": "",
                        "meta": {
                            "href": "/api/configuration/passwords"
                        }
                    }
                }
            ]
        },
        "gateway_methods": {
            "kerberos": false,
            "password": false,
            "public_key": false
        },
        "name": "unknown",
        "relayed_methods": {
            "kerberos": false,
            "keyboard_interactive": true,
            "password": true,
            "public_key": {
                "selection": "agent"
            }
        }
    },
    "key": "",
    "meta": {
        "first": "/api/configuration/ssh/authentication_policies",
        "href": "/api/configuration/ssh/authentication_policies",
        "last": "/api/configuration/ssh/settings_policies",
        "next": "/api/configuration/ssh/channel_policies",
        "parent": "/api/configuration/ssh",
        "previous": null,
        "transaction": "/api/transaction"
    }
}

Date and time configuration

Querying date and time configuration

Querying date and time configuration request

curl --cookie cookies --request GET https://<IP-address-of-SPS>/api/configuration/datetime

Querying date and time configuration response

{
    "items": [
        {
            "key": "ntp_servers",
            "meta": { "href": "/api/configuration/datetime/ntp_servers" }
        },
        {
            "key": "timezone",
            "meta": { "href": "/api/configuration/datetime/timezone" }
        }
    ],
    "meta": {
        "first": "/api/configuration/aaa",
        "href": "/api/configuration/datetime",
        "last": "/api/configuration/x509",
        "next": "/api/configuration/http",
        "parent": "/api/configuration",
        "previous": "/api/configuration/alerting",
        "transaction": "/api/transaction"
    }
}
Querying timezone configuration

Querying timezone configuration request

curl --cookie cookies --request GET https://<IP-address-of-SPS>/api/configuration/datetime/timezone

Querying timezone configuration response

{
    "key": "timezone",
    "body": "America/New_York",
    "meta": {
        "first": "/api/configuration/datetime/ntp_servers",
        "href": "/api/configuration/datetime/timezone",
        "last": "/api/configuration/datetime/timezone",
        "next": null,
        "parent": "/api/configuration/datetime",
        "previous": "/api/configuration/datetime/ntp_servers",
        "transaction": "/api/transaction"
    }
}
Querying NTP servers configuration

Querying NTP servers configuration request

curl --cookie cookies --request GET https://<IP-address-of-SPS>/api/configuration/datetime/ntp_servers

Querying NTP servers configuration response

{
    "key": "ntp_servers",
    "body": [
        {
            "selection": "fqdn",
            "value": "pool.ntp.org"
        }
    ],
    "meta": {
        "first": "/api/configuration/datetime/ntp_servers",
        "href": "/api/configuration/datetime/ntp_servers",
        "last": "/api/configuration/datetime/timezone",
        "next": "/api/configuration/datetime/timezone",
        "parent": "/api/configuration/datetime",
        "previous": null,
        "transaction": "/api/transaction"
    }
}

Firmware slots

Querying firmware slots

Querying firmware slots request

curl --cookie cookies --request GET https://<IP-address-of-SPS>/api/firmware/slots

Querying firmware slots response

{
    "items": [
          {
              "body": {
                  "after_reboot": false,
                  "current": true,
                  "upgrade_news": null,
                  "upgrade_notes": "some notes",
                  "version": "6.5.0"
              },
              "key": "1",
              "meta": {"href": "/api/firmware/slots/1"}
          },
          {
              "body": {
                  "after_reboot": true,
                  "current": false,
                  "upgrade_news": null,
                  "upgrade_notes": "some notes",
                  "version": "6.6.0"
              },
              "key": "2",
              "meta": {"href": "/api/firmware/slots/2"}
          },
          {
              "body": {},
              "key": "3",
              "meta": {"href": "/api/firmware/slots/3"}
          },
          {
              "body": {
                  "after_reboot": false,
                  "current": false,
                  "upgrade_news": null,
                  "upgrade_notes": "some notes",
                  "version": "6.7.0"
              },
              "key": "4",
              "meta": {"href": "/api/firmware/slots/4"}
          },
          {
              "body": {},
              "key": "5",
              "meta": {"href": "/api/firmware/slots/5"}
          }
    ],
    "meta": {
        "current_slot": "/api/firmware/slots/1",
        "href": "/api/firmware/slots",
        "number_of_empty_slots": 2,
        "parent": "/api/firmware",
        "slot_after_reboot": "/api/firmware/slots/2"
    }
}
Querying a firmware slot

Querying a firmware slot request

curl --cookie cookies --request GET https://<IP-address-of-SPS>/api/firmware/slots/1

Querying a firmware slot response

{
    "body": {
        "after_reboot": false,
        "current": true,
        "upgrade_news": null,
        "upgrade_notes": "some notes",
        "version": "6.5.0"
    },
    "key": "1",
    "meta": {
        "href": "/api/firmware/slots/1",
        "parent": "/api/firmware/slots"
    }
}

Number of sessions

Querying session count

Querying session count request

curl --cookie cookies --request GET https://<IP-address-of-SPS>/api/audit/sessions/_count

Querying session count response

{
  "count": 4,
  "meta": {
     "href": "/api/audit/sessions/_count",
     "parent": "/api/audit/sessions"
   }
}
Querying session count with filter

Querying session count with filter request

curl --cookie cookies --request GET https://<IP-address-of-SPS>/api/audit/sessions/_count?q=protocol%3ASSH

Querying session count with filter response

{
  "count": 2,
  "meta": {
    "href": "/api/audit/sessions/_count",
    "parent": "/api/audit/sessions"
  }
}
Documents connexes

The document was helpful.

Sélectionner une évaluation

I easily found the information I needed.

Sélectionner une évaluation