Fetch Risk Report
The API will retrieve risk reports for data analysis and reporting purposes.
Before you begin
NA
Request Structure
| Endpoint: | /ssh/report/risk |
| Type: | GET |
| Sample URL: | https://<IP/HostName/TenantName>:<GWPORT>/avxapi/ssh/report/risk?gwsource=externalTo understand the elements of the sample URL, click here. |
| Headers: | |
| Content-Type: | application/json |
| Name | Description |
|---|---|
| sessionId
|
(Mandatory) Session ID received after
login. Type: String Constraints: Required if username and password are not provided. |
| username
|
(Mandatory) AppViewX login username. Type: String Constraints: Required if sessionId is not provided. |
| password
|
(Mandatory) AppViewX login password. Type: String Constraints: Required if sessionId is not provided. |
| Content-Type
|
(Mandatory) Specifies the nature of the data in the
payload. Type: String Constraints: The value of the param should be ‘application/json’. |
| gwsource
|
(Mandatory) Source from which the request is
triggered. (E.g. external) Type: String |
| reportName
|
Name of the report to be fetched. Type: String Possible Values: vulnerabilityReport, keyAgeReport, hostKeyAgeReport, hostKeyAlgorithmBitLengthReport, keyAlgorithmBitLengthReport, keySummaryReport, hostCertValidityReport, cipherSuiteServerSide, cipherSuiteClientSide, kexReportServerSide, kexReportClientSide, macReportServerSide, macReportClientSide |
| Payload
|
None |
Response Structure
200 Accepted returns string of type application/json with the following body params.
| Name | Description |
|---|---|
| response | Contains the response of the vulnerability
report Type: Response |
| message | Success message of the action or failure description
in case of error. Will be non-null for failure
response. Type: String |
| appStatusCode | Application-specific status code for the response.
Will be non-null for failure response. Type: String |
| tags | More info in case of failure response. |
Response
| Name | Description |
|---|---|
| keys | List of keys with vulnerability information. Type: List |
| lastUpdateTime | Last updated time of the report. Type: Long |
| securityScore | Security score information of the keys. Type: Number |
| totalKeys | Total number of keys available. Type: Number |
| totalWeakKeys | Total number of weak keys available. Type: Number |
Status Codes
| HTTP Status code | appStatusCode | Message and Possible remediation |
|---|---|---|
| 200 Accepted | NA | Success |
| 401 Unauthorized | AVX_GW_003 | Authentication failed, reason - Invalid
Credentials Possible remediation: Ensure that valid username and password or valid sessionId is provided as the header param. |
| 400 Bad Request | AVX-VLDTN-001 | Mandatory field is missing or invalid values
specified - <<field name>> Possible remediation: Check and ensure that valid value is provided for <<field name>> field in the request. |
Sample Request/Response
To fetch risk reports using /report/risk API.
https://<IP/HostName/TenantName>:<GWPORT>/avxapi/ssh/report/risk?reportName=reportname&gwsource=externalNone
{
"response": {
"keys": [
{
"category": "Suspicious Keys",
"keysCount": 111,
"impact": "High"
},
{
"category": "Shared User Keys",
"keysCount": 1,
"impact": "High"
},
{
"category": "KEX Server Side Weak Algorithms",
"keysCount": 31,
"impact": "High"
},
{
"category": "KEX Client Side Weak Algorithms",
"keysCount": 36,
"impact": "High"
},
{
"category": "Shared Host Keys",
"keysCount": 3,
"impact": "High"
},
{
"category": "Orphan Keys",
"keysCount": 5,
"impact": "Medium"
},
{
"category": "Server Side Weak Ciphers",
"keysCount": 11,
"impact": "Medium"
},
{
"category": "Client Side Weak Ciphers",
"keysCount": 11,
"impact": "Medium"
},
{
"category": "Weak User Keys",
"keysCount": 2,
"impact": "Low"
},
{
"category": "MAC Server Side Weak Algorithms",
"keysCount": 6,
"impact": "Low"
},
{
"category": "MAC Client Side Weak Algorithms",
"keysCount": 6,
"impact": "Low"
},
{
"category": "Weak Host Keys",
"keysCount": 4,
"impact": "Low"
}
],
"lastUpdateTime": 1717662901079,
"securityScore": 36.32568,
"totalKeys": 401,
"totalWeakKeys": 123
},
"message": "Success",
"appStatusCode": "SSH-NB-200",
"tags": {},
"headers": null
}
Reference
- IP/HostName/TenantName: Replace with the actual IP address, hostname,
or tenant name based on the specific configuration in AppViewX.
- IP: A unique identifier assigned to each device connected to
a computer network that uses the Internet Protocol for communication
The IP address will be included in the endpoint URL for an on-prem deployment.
- HostName: A human-readable label assigned to a device (host)
on a network
The hostname will be included in the endpoint URL for an on-prem deployment.
- TenantName: An identifier label for a tenant given to
indicate which tenant's data the API request will
access/modify
The tenant name will be included in the endpoint URL for a SaaS deployment.
- IP: A unique identifier assigned to each device connected to
a computer network that uses the Internet Protocol for communication
- GWPORT: AppViewX gateway port A gateway port refers to a network port through which data is sent and received to communicate with a gateway in an on-prem deployment.Note: GWPORT is not required for SaaS setups.
Example: 31443
- avxapi: Path parameter value (static) that is part of the endpoint's URL
- Endpoint: Endpoint of the API, for example: /ssh/host/create
- gwsource: Source or origin of a gateway, for example: external.