This URL gets the details of a rule object.
Resource URL
GET /ruleobject/<ruleobject_id>
Request Parameters
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Rule object ID | String | Yes |
Response Parameters
Following fields are returned if the request parameters are correct, otherwise error details are returned.
Field Name | Description | Data Type |
|---|---|---|
| Rule object ID | String |
| Rule object name | String |
| Rule object type | String |
| Description | String |
| ID of domain in which the rule object is defined | Number |
| Is rule object visible to child | Boolean |
| Application group object, should be defined if ruleobjType is "APPLICATION_GROUP" | Object |
| Application defined on custom port object, should be defined if ruleobjType is "APPLICATION_ON_CUSTOM_PORT" | Object |
| Finite time period object, should be defined if ruleobjType is "FINITE_TIME_PERIOD" | Object |
| Host IPv4 address object, should be defined if ruleobjType is "HOST_IPV_4" | Object |
| Host IPv6 address object, should be defined if ruleobjType is "HOST_IPV_6" | Object |
| Host DNS name object, should be defined if ruleobjType is "HOST_DNS_NAME" | Object |
| IPv4 address range object, should be defined if ruleobjType is "IPV_4_ADDRESS_RANGE" | Object |
| IPv6 address range object, should be defined if ruleobjType is "IPV_6_ADDRESS_RANGE" | Object |
| IPv4 network object, should be defined if ruleobjType is "NETWORK_IPV_4" | Object |
| IPv6 network object, should be defined if ruleobjType is "NETWORK_IPV_6" | Object |
| Network group object, should be defined if ruleobjType is "NETWORK_GROUP" | Object |
| Recurring time period object, should be defined if ruleobjType is "RECURRING_TIME_PERIOD" | Object |
| Recurring time period group object, should be defined if ruleobjType is "RECURRING_TIME_PERIOD_GROUP" | Object |
| Service object, should be defined if ruleobjType is "CUSTOM_SERVICE" | Object |
| Service range object, should be defined if ruleobjType is "SERVICE_RANGE" | Object |
| Service group object, should be defined if ruleobjType is "SERVICE_GROUP" | Object |
| Network group for exception objects should be defined if ruleobjType is "NETWORK_GROUP_AF". This type of rule object is applicable only for alert filter/Ignore rules. | Object |
Details of ApplicationGroup:
Field Name | Description | Data Type |
|---|---|---|
| List of applications identifier | Array |
Details of object in ApplicationIdentifier:
Field Name | Description | Data Type |
|---|---|---|
| Application rule object ID | String |
| Application type, can be "DEFAULT_APPLICATION" / "APPLICATION_ON_CUSTOM_PORT" | String |
Details of ApplicationonCustomPort
Field Name | Description | Data Type |
|---|---|---|
| Application ID | String |
| List of ports | Array |
Details of object in portsList:
Field Name | Description | Data Type |
|---|---|---|
| IP protocol, can be "TCP" / "UDP" | String |
| Port | Number |
Details of FiniteTimePeriod:
Field Name | Description | Data Type |
|---|---|---|
| From time | String |
| To time | String |
Details of HostIPv4:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| List of IPv4 host address | Object | Yes |
Details of hostIPv4AddressList:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Rule object ID | Number | Yes |
| State of the rule member, should be 1 to Enable and 0 to Disable the rule member. | Number | Yes |
| User comment | String | No |
| User ID | Number | Yes |
| IPv4 Address | String | Yes |
| Change the state of a rule member, should be 1 to add, 2 to update and 3 to delete a rule member. | Number | Yes |
Details of HostIPv6:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| List of IPv6 host address | Object | Yes |
Details of hostIPv6AddressList:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Rule object ID | Number | Yes |
| State of the rule member, should be 1 to Enable and 0 to Disable the rule member. | Number | Yes |
| User comment | String | No |
| User ID | Number | Yes |
| IPv6 Address | String | Yes |
| Change the state of a rule member, should be 1 to add, 2 to update and 3 to delete a rule member. | Number | Yes |
Details of HostDNSName
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| List of host DNS names | Object | Yes |
Details of hostDNSNameList:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Rule object ID | Number | Yes |
| State of the rule member, should be 1 to Enable and 0 to Disable the rule member. | Number | Yes |
| User comment | String | No |
| User ID | Number | Yes |
| host DNS name | String | Yes |
| Change the state of a rule member, should be 1 to add, 2 to update and 3 to delete a rule member. | Number | Yes |
Details of IPv4AddressRange:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| List of IPv4 address range | Object | Yes |
Details of IPV4RangeList:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Rule object ID | Number | Yes |
| State of the rule member, should be 1 to Enable and 0 to Disable the rule member. | Number | Yes |
| User comment | String | No |
| User ID | Number | Yes |
| Start IP range | String | Yes |
| End IP range | String | Yes |
| Change the state of a rule member, should be 1 to add, 2 to update and 3 to delete a rule member. | Number | Yes |
Details of IPv6AddressRange:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| List of IPv6 address range | Object | Yes |
Details of IPV6RangeList:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Rule object ID | Number | Yes |
| State of the rule member, should be 1 to Enable and 0 to Disable the rule member. | Number | Yes |
| User comment | String | No |
| User ID | Number | Yes |
| Start IPv6 range | String | Yes |
| End IPv6 range | String | Yes |
| Change the state of a rule member, should be 1 to add, 2 to update and 3 to delete a rule member. | Number | Yes |
Details of NetworkIPv4:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| List of network IPv4 addresses | Object | Yes |
Details of networkIPV4List:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Rule object ID | Number | Yes |
| State of the rule member, should be 1 to Enable and 0 to Disable the rule member. | Number | Yes |
| User comment | String | No |
| User ID | Number | Yes |
| IPv4 network | String | Yes |
| Change the state of a rule member, should be 1 to add, 2 to update and 3 to delete a rule member. | Number | Yes |
Details of NetworkIPv6:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| List of network IPv6 addresses | Object | Yes |
Details of networkIPV6List:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Rule object ID | Number | Yes |
| State of the rule member, should be 1 to Enable and 0 to Disable the rule member. | Number | Yes |
| User comment | String | No |
| User ID | Number | Yes |
| IPv6 network | String | Yes |
| Change the state of a rule member, should be 1 to add, 2 to update and 3 to delete a rule member. | Number | Yes |
Details of NetworkGroup:
Field Name | Description | Data Type |
|---|---|---|
| List of network objects | Array |
Details of object in NetworkGroupIdentifier:
Field Name | Description | Data Type |
|---|---|---|
| Network rule object ID | String |
| Network type, can be "COUNTRY" / "HOST_IPV_4" / "HOST_IPV_6" / "HOST_DNS_NAME" / "IPV_4_ADDRESS_RANGE" / "IPV_6_ADDRESS_RANGE" / "NETWORK_IPV_4" / "NETWORK_IPV_6" | String |
Details of RecurringTimePeriod:
Field Name | Description | Data Type |
|---|---|---|
| Entire day object | Boolean |
| Duration object | Object |
| List of days, can be "MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY", "SATURDAY", "SUNDAY" | String |
Details of object in duration:
Field Name | Description | Data Type |
|---|---|---|
| From time | String |
| To time | String |
Details of RecurringTimePeriodGroup
Field Name | Description | Data Type |
|---|---|---|
| List of recurring time period rule object Id's | Array |
Details of Service
Field Name | Description | Data Type |
|---|---|---|
| Protocol, can be "TCP" / "UDP" / "PROTOCOL_NUMBER" | String |
| Port number | String |
Details of ServiceRange
Field Name | Description | Data Type |
|---|---|---|
protocol | Protocol, can be "TCP" / "UDP" / "PROTOCOL_NUMBER" | String |
From | From port/protocol number | String |
To | To port/protocol number | String |
Details of ServiceGroup
Field Name | Description | Data Type |
|---|---|---|
| List of service objects | Array |
Details of object in ServiceIdentifier:
Field Name | Description | Data Type |
|---|---|---|
| Service rule object ID | String |
| Service Type, can be "DEFAULT_SERVICE" / "CUSTOM_SERVICE" | String |
Example
Request
GET https://<NSM_IP>/sdkapi/ruleobject/121
Response
{
"RuleObjDef": {
"ruleobjId": "234",
"ruleobjType": "HOST_IPV_4",
"name": "test_SDK3",
"description": "try",
"domain": 0,
"visibleToChild": true,
"hostCriticality": "HIGH",
"ApplicationGroup": null,
"ApplicationOnCustomPort": null,
"FiniteTimePeriod": null,
"HostIPv4": {
"hostIPv4AddressList": [
{
"ruleObjectID": 234,
"value": "172.1.1.3",
"state": 1,
"comment": "test",
"userID": 0,
"changedState": 0
},
{
"ruleObjectID": 234,
"value": "172.0.9.1",
"state": 1,
"comment": "updatecomment",
"userID": 0,
"changedState": 0
},
{
"ruleObjectID": 234,
"value": "172.9.0.2",
"state": 1,
"comment": "test",
"userID": 0,
"changedState": 0
}
]
},
"HostIPv6": null,
"HostDNSName": null,
"IPv4AddressRange": null,
"IPv6AddressRange": null,
"Network_IPV_4": null,
"Network_IPV_6": null,
"NetworkGroup": null,
"RecurringTimePeriod": null,
"RecurringTimePeriodGroup": null,
"Service": null,
"ServiceGroup": null,
"ServiceRange": null
}
}
Error Information
Following error codes are returned by this URL:
S.No | HTTP Error Code | SDK API errorId | SDK API errorMessage |
|---|---|---|---|
1 | 404 | 1720 | Invalid rule object Id/ rule object not visible to this domain |