API v2: Accountsยถ

Account defines the privileged account existing on the monitored server. It specifies the actual login credentials, user authentication mode: anonymous (without user authentication), regular (with login credentials substitution) or forward (with login and password forwarding); password changing policy as well as the password changer itself.


Data Structures: AccountModelยถ

AccountModelยถ

Attribute

Type

Required

Description

id

string

yes

Read-only object Identifier. Requires rights to perform operations on the account object: read for GET, modify for PATCH, and delete for DELETE.

name

string

yes

Unique accountโ€™s name

description

string

no

Object description

note

string

Read-only; expensive to use

blocked

boolean; default value false

yes

reason

string

if blocked == true

type

string {regular, forward, anonymous}

yes

Immutable

category

string {nonprivileged, privileged}

protocol

string

Protocol of the pool orย server which the account isย assigned to. Read-only; expensive to use.

server_id

string

yes

server_name

string

Read-only; expensive to use

server_address

string

Read-only; expensive to use

server_mask

number

Read-only; expensive to use

server_port_first

number

Read-only; expensive to use

server_port_last

number

Read-only; expensive to use

server_port

number

Read-only; expensive to use

pool_id

string

yes

pool_name

string

Read-only; expensive to use

hotseat

boolean; default value false

if type == regular

Enable to be informed about existing connections via the Access Gateway. Available for the server with protocol == rdp

method

string {account, passvn, password, sshkey}

if type == regular || forward

Authentication method

domain

string

if type == regular || forward

login

string; may be empty

if type == regular

secret

string; may be empty

if method == password || sshkey

secret_passphrase

string

with sshkey

Passphrase to use to decrypt SSH private key.

ssh_public_key

string

SSH public key. Read-only; expensive to use.

ssh_fingerprint _sha256

string

SSH key SHA256 fingerprint. Read-only; expensive to use.

forward_domain

boolean; default value false

if type == forward

servauth

boolean; default value false

if type == forward

Authentication against server

account_id

string

if method == account

passvn_id

string

if method == passvn

passvn_name

string

Read-only; expensive to use

dump_mode

string {all, none, raw, noraw}; default value noraw

yes

Session recording options

retention_locked

boolean; default value false

yes

retention_remove

number

Value range from 1 to 2147483647.

retention_external

number

Value range from 1 to 2147483647.

timestamp_enabled

boolean; default value false

yes

ocr_enabled

boolean; default value false

yes

ocr_lang

string {eng, pol, deu, hun, nor, rus, ukr}; if more than 1, separated by the + symbol

if ocr_enabled == true

ssh_agent

boolean; default value false

yes

rdp_remote_apps _only

boolean; default value false

yes

Restrict access to the account exclusively through remote applications.

password_lastupdate

datetime

Read-only

password_lastcheck

datetime

Read-only

password_change _policy_id

string

if type == regular

Password change policy identifier.

password_change _policy_name

string

Password change policy name. Read-only; expensive to use.

password_checkout _time_limit

datetime (h:m:s)

if password_change _on_checkin == true

password_change _on_checkin

boolean

If set, password will be changed after last password checkin.

password_change _on_session_end

boolean

If set, password will be changed after session finishes.

password_change _trigger_pending

boolean

Waiting for password change after triggered. Read-only; expensive to use.

password_change _trigger_available

boolean

Can manually trigger password change request? Read-only; expensive to use.

password_changer_ids

string-array

Read-only; hidden; expensive to use

password_recovery

boolean

If set and password verification detects unknown password, password changer will try to recover the password to a known value.

last_login

datetime

Read-only; expensive to use

safes

object-array

JSON object array containing id, name, and position of assigned safes. Read-only; expensive to use.

safes_ids

string-array

Read-only; hidden; expensive to use

safe_names

string-array

Read-only; hidden; expensive to use

servers

object-array

Read-only; expensive to use; JSON object array containing id, mask, name, port and address of assigned servers.

servers_ids

string-array

Read-only; hidden; expensive to use

servers_names

string-array

Read-only; hidden; expensive to use

state

string {created, discovered, onboarded, quarantined}

Accountโ€™s discovery state: discovered, onboarded, quarantined, or created (for manually created accounts). Read-only. Expensive to use.

discovered_at

datetime

Account discovered at timestamp. Read-only; expensive to use

onboarded_at

datetime

Account onboarded at timestamp. Read-only; expensive to use.

onboarded_by_id

string

User identifier who onboarded this account. ARead-only; expensive to use.

onboarded_by_name

string

User name who onboarded this account. Read-only; expensive to use.

quarantined_at

datetime

Account quarantined at timestamp. Read-only; expensive to use.

quarantined_by_id

string

User identifier who quarantined this account. Read-only; expensive to use.

quarantined_by_name

string

User name who quarantined this account. Read-only; expensive to use.

quarantine_reason

string

Quarantine reason. Read-only; expensive to use.

scanner_id

string

Scanner identifier. Read-only; expensive to use.

scanner_name

string

Scanner name. Read-only; expensive to use.

secret_exposed

boolean

Determines if there is aย user who checked out the current password and now has lost access to the account, e.g. the user is now blocked, deleted, or there is no longer a safe containing both the user and the account, and gives the user secret check out rights. Read-only; expensive to use.

rights

string-array

Read-only; list of rights the subject has to this object.

created_at

datetime

Read-only. Timestamp of creation.

modified_at

datetime

Read-only. Timestamp of modification.

removed

boolean

Read-only.

builtin

boolean

Read-only; expensive to use; if true, the object is not editable.

hidden

boolean

Read-only; expensive to use; if true, the object is hidden in UI.

Retrieve Available Attributes of the AccountModelยถ

Request

Method

GET

Path

/api/v2/objspec/account

To check allowed methods, available URL parameters and possible responses please refer to the API Overview section.

Refer to the Batch operations topic to create nested requests for operating on the Account objects.


Create an Accountยถ

Request

Method

POST

Path

/api/v2/account

Headers

Content-Type: Application/json

Body

AccountModel

Example Request

POST /api/v2/account

curl -s -k -X POST \
  -H 'Authorization: sgfeea6jsaz4mum9su8w6' \
  -H 'Content-Type: application/json' \
  'https://10.0.214.98/api/v2/account' \
  -d '{
    "name": "test-account",
    "type": "regular",
    "server_id": "1234567890",
    "method": "password",
    "login": "test-account-login",
    "domain": "my-domain"
  }'

Response

{
    "result": "success",
    "account": {
        "id": "1234567890123456"
    }
}

Get Accounts Listยถ

Request

Method

GET

Path

/api/v2/account

Get an Accountยถ

Request

Method

GET

Path

/api/v2/account/<id>

Modify an Accountยถ

Request

Method

PATCH

Path

/api/v2/account/<id>

Headers

Content-Type: Application/json

Body

AccountModel

Example Request: Enable OCR With German, English and Polish Languages for an Account

PATCH /api/v2/account/<id>

    { "ocr_enabled": true,
"ocr_lang": "deu+eng+pol"}

Response

{
    "result": "success"
}

Adding a Password Changer Policy to Accountยถ

Password changer policy canโ€™t be created via API, but can be assigned to a particular Account. It requires a password changer or/and password verifier assigned according to itโ€™s enabled options.

By default there is an existing password policy named Static, without restrictions with id = 1, which has no password change or verification functions assigned.

Request

Method

PATCH

Path

/api/v2/account/<id>

Headers

Content-Type: Application/json

Body

AccountModel

Example Request

PATCH /api/v2/account/<id>

{
        "domain":null,
        "password_change_policy_id":"2345678901234567"
}

Response

{
    "result": "success"
}

Modify Password Change Parameters for Accountยถ

Request

Method

PATCH

Path

/api/v2/account/<id>

Headers

Content-Type: Application/json

Body

AccountModel

Example Request

PATCH /api/v2/account/<id>

{
   "domain":null,
   "password_change_policy_id":"2345678901234567989",
   "password_checkout_time_limit":"06:59:00",
   "password_change_on_session_end":true,
   "password_change_on_checkin":true,
   "password_recovery":true
}

Response

{
    "result": "success"
}

Delete an Accountยถ

Request

Method

DELETE

Path

/api/v2/account/<id>

Managing Security Alertsยถ

Request

Method

POST

Path

/api/v2/account/<account_id>/mark_sessions_as_safe