Bulk upsert VLAN/Q-in-Q mappings: Request

Prev Next

To update or insert all VLAN/Q-in-Q mappings currently configured, send the following request:

PUT https://<IA_IP_address>:<port_number>/config/v1/rbac/vlan/mappings/_bulk

Required header:

Cookie: px=<token>
Content-Type: application/json

Note

To use this request, your user account must be assigned to the Admin role.

Request body:

VlanRange example

{
  "alias": "fireeye_iss_team",
  "group": "CN=Domain Admins,CN=Users,DC=theitbros,DC=com",
  "user": "npadmin",
  "type": "vlan",
  "vlanRanges": [
    {
      "tagStart": 128,
      "tagEnd": 200
    }
  ]
}

QinQ example

{
  "alias": "fireeye_iss_team",
  "group": "CN=Domain Admins,CN=Users,DC=theitbros,DC=fireeye.com",
  "user": "npadmin",
  "type": "qinq",
  "qinqRanges": [
    {
      "outerTag": 1,
      "innerTags": {
        "tagStart": 128,
        "tagEnd": 200
      }
    }
  ]
}

Options

  • IA_IP_address—The IP address of the NDR appliance running the NDR API.

  • port_number—The port number of the NDR appliance running the NDR API.

  • token—This token authenticates the session. By default, the session times out after 24 hours.

Example

PUT https://xxx.xxx.xxx.xxx:443/config/v1/rbac/vlan/mappings/_bulk

Required header:

Cookie: px=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

Bulk upsert VLAN/Q-in-Q mappings: Response

HTTP/1.1 [Response Code] [Response Message]
Date: [Date]
Response fields
  • 200—Mappings were successfully updated

  • 201—New mappings were successfully added.

cURL code sample: Bulk upsert VLAN/Q-in-Q mappings

curl -k --cookie "px=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" -X PUT -H "Content-Type: application/json"https://xxx.xxx.xxx.xxx:443/config/v1/rbac/vlan/mappings/_bulk -d '{ "alias": "fireeye_iss_team", "group": "CN=Domain Admins,CN=Users,DC=theitbros,DC=com", "user": "npadmin", "type": "vlan", "vlanRanges": [ { "tagStart": 128, "tagEnd": 200 } ] } '

This cURL sample includes the following options:

  • -k—This option explicitly allows cURL to perform insecure SSL connections and transfers, which allows you to test your SSL connection without installing a CA certificate.

  • --cookie "px=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"—This option specifies the authentication token for this session.

  • -X PUT—Specifies using the PUT method.

  • -H "Content-Type: application/json"—Specifies that the response should be in JSON.

  • https://xxx.xxx.xxx.xxx:443/config/v1/rbac/vlan/mappings/_bulk—The request URL. Replace xxx.xxx.xxx.xxx with the IP address of your NDR appliance.

  • -d <data>—Specifies the new mapping values.

Results

This example bulk upserts all VLAN/Q-in-Q mappings.