> For the complete documentation index, see [llms.txt](https://docs.octoxlabs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.octoxlabs.com/adapters/r/rapid7-insight-cloudsec.md).

# Rapid7 Insight CloudSec

Rapid7 Insight CloudSec is a cloud security posture platform, available as a cloud service and as a self-managed deployment. OctoXLabs uses it to add the cloud compute instances it tracks to the device inventory.

## Use cases

* Find cloud instances known to CloudSec but missing from your EDR coverage.

```
Adapters = rapid7-insight-cloudsec AND NOT Adapters = falcon-crowdstrike
```

* Count Linux instances reported by CloudSec.

```
Adapters = rapid7-insight-cloudsec AND OS.Type = Linux
```

## Before you begin

### Network

| Source              | Destination                                                          | Port                                                 | Protocol                           |
| ------------------- | -------------------------------------------------------------------- | ---------------------------------------------------- | ---------------------------------- |
| OctoXLabs connector | {region}.cloudsec.insight.rapid7.com (cloud) or your self-managed IP | 443 for cloud. For self-managed, the port you enter. | HTTPS (HTTP when Is Secure is off) |

### Required permissions

| Scope or role                                   | Permission    | Needed for                       |
| ----------------------------------------------- | ------------- | -------------------------------- |
| Domain Admin, Organization Admin, or Basic User | View Resource | Query resources of type instance |

## Create credentials in Rapid7 Insight CloudSec

{% stepper %}
{% step %}

### Choose who creates the key

A Domain Admin or Organization Admin can generate a personal API key from the user profile.
{% endstep %}

{% step %}

### Or use User Management

Open **Settings > User Management > API Keys** to generate a key.
{% endstep %}

{% step %}

### Or use the API

Create an API-only user with `/v2/public/user/create_api_only_user`, or create a key for a user ID with `/v2/public/apikey/create`. Get user IDs from `/v2/public/users/list`.
{% endstep %}
{% endstepper %}

## Connection parameters

| Parameter  | Required    | Type    | Default | Description                                                              |
| ---------- | ----------- | ------- | ------- | ------------------------------------------------------------------------ |
| Region     | Conditional | String  | None    | Cloud region identifier, for example us2. Use it for the cloud endpoint. |
| IP Address | Conditional | String  | None    | Address of a self-managed or on-prem CloudSec. Use instead of Region.    |
| Port       | Conditional | Integer | None    | Required when IP Address is set.                                         |
| API Key    | Yes         | String  | None    | Key sent in the Api-Key header.                                          |
| Is Secure? | No          | Boolean | True    | Use HTTPS.                                                               |
| Timeout    | No          | Integer | 30      | Seconds to wait for API responses.                                       |

Provide either Region, or IP Address and Port together. Not both.

## Troubleshooting

| Error message                                                      | Cause                                                                                                                                      | Fix                                                                                                                          |
| ------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------- |
| You can only provide either 'region' OR 'ip' and 'port', not both. | Region was set together with IP or Port.                                                                                                   | Fill only Region, or only IP Address and Port.                                                                               |
| You must provide either 'region' OR both 'ip' and 'port'.          | Neither Region nor the IP and Port pair was given.                                                                                         | Provide Region, or both IP Address and Port.                                                                                 |
| Status Code:                                                       | The API answered with a status other than the one the connector expects. The message also lists the URL, the method and the response body. | Read the status code and the response body in the message, then check the credentials, the permissions and the network path. |

## Change history

{% hint style="info" %}
Available starting from version 6.2.0.
{% endhint %}
