Access information about all proxy sessions registered in PAM Core.
Requirements
- Authorization with access permission to PAM Core.
- Remote sessions started in PAM Core.
Request
Alert
To list all sessions, the user must have access permission for Credentials and Devices in the authorization.
GET /api/session/remotesessions
Request example
GET {{url}}/api/session/remotesessions
Response
Attention
Depending on the number of sessions registered in the environment, the returned list may be very long and the response time may take a few minutes.
{
"code": 200,
"response": {
"status": 200,
"message": "",
"error": false,
"error_code": 0,
"detail": "",
"mensagem": "",
"erro": false,
"cod_erro": 0
},
"tenant": "Segura",
"remote_sessions": [
{
"id": "3",
"user": "Admin",
"origin_ip": "172.16.20.125",
"credential": "usrdomadm01",
"device": "10.66.33.15:3389",
"protocol": "rdp",
"proxy": "Web Proxy",
"session_id": "e7acacb6aedbab70073456da5744166939b77527",
"start": "2024-05-06 16:05:07",
"end": "2024-05-06 16:07:59",
"time": "00:02:52",
"prevent_purge": "No",
"request": null,
"ITSM": null
},
{
"id": "6",
"user": "Admin",
"origin_ip": "172.16.20.125",
"credential": "usrsudonopass",
"device": "10.66.33.17:22",
"protocol": "ssh",
"proxy": "Web Proxy",
"session_id": "c819cbc5f2fad2065f1d132a22d0e2dfacccb228",
"start": "2024-05-06 16:11:17",
"end": "2024-05-06 16:11:30",
"time": "00:00:13",
"prevent_purge": "No",
"request": null,
"ITSM": null
}
]
}
Response body fields
Info
- The identifier
session_id
is used internally by the application for session-related operations such as access control, activity tracking, and resource management. Each time a session is started, a newsession_id
is generated for that specific session. - This value is automatically assigned by Segura when the session is created and should not be confused with the
session_id
parameter.
Field | Type | Description | Example |
---|---|---|---|
remote_sessions | Array of objects | Data of the listed remote sessions. | - |
id |
Integer | Unique identification code of the remote session. | - |
user |
String | Username that performed the session. | - |
origin_ip |
String | IP address of the user who performed the session. | - |
credential |
String | Credential used to perform the session. | - |
device |
String | Hostname or IP address of the target device and access port. | - |
protocol |
String | Network protocol (SSH, RDP, HTTPS, among others) | - |
proxy |
String | Type of proxy session (Web Proxy, RDP Proxy, Terminal Proxy) | - |
session_id |
String | Unique hash generated by Segura to uniquely identify a specific session. | e7acacb6aedbab70073456da5744166939b77527 |
start |
String | Session start date and time in ISO 8601 format. | 2024-05-06 16:05:07 |
end |
String | Session end date and time in ISO 8601 format. | 2024-05-06 16:07:59 |
time |
String | Session duration. | 00:02:52 |
prevent_purge |
String | Indicates if automatic deletion prevention of session data is enabled. If marked as Yes , it will not be possible to perform a purge on the session. |
No |
request |
String | Request made by the user. | - |
ITSM |
String | ITSM software code. | - |
Common errors
HTTP Code | Error | Message | Possible Cause | Solution |
---|---|---|---|---|
404 | Not Found | "Resource sub not found" | The URL or requested resource is incorrect. | Check the URL and resend the request. |
500 | Internal Server Error | "Unexpected error." | The error is on the Segura server. | Contact the support team for more information. |
- | - | "You are not authorized to access this resource." | You do not have authorization to access this resource. | Ask the administrator to review your access permissions to A2A resources. |
- | Client authentication failed | "Client authentication failed" | Authentication failure of your application with the Segura server. | Check authentication parameters such as Access Token, Client ID, and Client Secret, and request a new access token. |
- | No route matched with those values | "No route matched with those values" | Missing authorization header in the API request. | Request a new access token. |
- | Request timed out | "Request timed out" | The request time has expired. | Check connectivity between the request origin and the server. |