List Trust Rulesets
List all trust rulesets.
TrustRulesetsApi.listTrustRulesets([param1, param2, ...])
TrustRulesetsApi.list_trust_rulesets([param1, param2, ...])
TrustRulesetsApi.listTrustRulesets([param1, param2, ...])
successful operation
Not authorized to list trust rulesets.
- Java
- Python
- JavaScript
import com.trendmicro.deepsecurity.ApiClient; import com.trendmicro.deepsecurity.Configuration; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.ApiException; import com.trendmicro.deepsecurity.api.TrustRulesetsApi; import com.trendmicro.deepsecurity.model.TrustRulesets; public class ListTrustRulesetsExample { public static void main(String[] args) { // Setup ApiClient defaultClient = Configuration.getDefaultApiClient(); defaultClient.setBasePath("YOUR HOST"); // Authentication ApiKeyAuth Legacy API Key = (ApiKeyAuth) defaultClient.getAuthentication("Legacy API Key"); Legacy API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } ApiKeyAuth Trend Micro Cloud One API Key = (ApiKeyAuth) defaultClient.getAuthentication("Trend Micro Cloud One API Key"); Trend Micro Cloud One API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } // Initialization // Set Any Required Values TrustRulesetsApi instance = new TrustRulesetsApi(); String apiVersion = "YOUR VERSION"; try { // Please replace the parameter values with yours TrustRulesets result = instance.listTrustRulesets(apiVersion); System.out.println(result); } catch (ApiException e) { System.err.println("An exception occurred when calling TrustRulesetsApi.listTrustRulesets"); e.printStackTrace(); } } }
- 200
{- "trustRuleSetCount": 0,
- "applicationControlTrustRulesets": [
- {
- "name": "string",
- "description": "string",
- "version": 0,
- "createdTime": 0,
- "lastUpdatedTime": 0,
- "usageCount": 0,
- "ID": 0
}
]
}
Create a Trust Ruleset
Create a new trust ruleset.
TrustRulesetsApi.createTrustRuleset([param1, param2, ...])
TrustRulesetsApi.create_trust_ruleset([param1, param2, ...])
TrustRulesetsApi.createTrustRuleset([param1, param2, ...])
header Parameters
Request Body schema: application/json
The settings of the new trust ruleset.
successful operation
Not authorized to create trust rulesets.
- Payload
- Java
- Python
- JavaScript
{- "name": "string",
- "description": "string"
}
- 200
{- "name": "string",
- "description": "string",
- "version": 0,
- "createdTime": 0,
- "lastUpdatedTime": 0,
- "usageCount": 0,
- "ID": 0
}
Describe a Trust Ruleset
Describe a trust ruleset by ID.
TrustRulesetsApi.describeTrustRuleset([param1, param2, ...])
TrustRulesetsApi.describe_trust_ruleset([param1, param2, ...])
TrustRulesetsApi.describeTrustRuleset([param1, param2, ...])
successful operation
Not authorized to view trust rulesets.
The trust ruleset does not exist.
- Java
- Python
- JavaScript
import com.trendmicro.deepsecurity.ApiClient; import com.trendmicro.deepsecurity.Configuration; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.ApiException; import com.trendmicro.deepsecurity.api.TrustRulesetsApi; import com.trendmicro.deepsecurity.model.TrustRuleset; public class DescribeTrustRulesetExample { public static void main(String[] args) { // Setup ApiClient defaultClient = Configuration.getDefaultApiClient(); defaultClient.setBasePath("YOUR HOST"); // Authentication ApiKeyAuth Legacy API Key = (ApiKeyAuth) defaultClient.getAuthentication("Legacy API Key"); Legacy API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } ApiKeyAuth Trend Micro Cloud One API Key = (ApiKeyAuth) defaultClient.getAuthentication("Trend Micro Cloud One API Key"); Trend Micro Cloud One API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } // Initialization // Set Any Required Values TrustRulesetsApi instance = new TrustRulesetsApi(); Long acTrustRulesetID = 1L; String apiVersion = "YOUR VERSION"; try { // Please replace the parameter values with yours TrustRuleset result = instance.describeTrustRuleset(acTrustRulesetID, apiVersion); System.out.println(result); } catch (ApiException e) { System.err.println("An exception occurred when calling TrustRulesetsApi.describeTrustRuleset"); e.printStackTrace(); } } }
- 200
{- "name": "string",
- "description": "string",
- "version": 0,
- "createdTime": 0,
- "lastUpdatedTime": 0,
- "usageCount": 0,
- "ID": 0
}
Modify a Trust Ruleset
Modify a trust ruleset's attributes by trust ruleset ID, including trust rule assignment.
TrustRulesetsApi.modifyTrustRuleset([param1, param2, ...])
TrustRulesetsApi.modify_trust_ruleset([param1, param2, ...])
TrustRulesetsApi.modifyTrustRuleset([param1, param2, ...])
path Parameters
header Parameters
Request Body schema: application/json
The attributes of the trust ruleset to modify.
successful operation
Not authorized to modify trust rulesets.
The trust ruleset does not exist.
- Payload
- Java
- Python
- JavaScript
{- "name": "string",
- "description": "string",
- "ruleIds": [
- 0
]
}
- 200
{- "name": "string",
- "description": "string",
- "version": 0,
- "createdTime": 0,
- "lastUpdatedTime": 0,
- "usageCount": 0,
- "ID": 0
}
Delete a Trust Ruleset
Delete a trust ruleset by ID.
TrustRulesetsApi.deleteTrustRuleset([param1, param2, ...])
TrustRulesetsApi.delete_trust_ruleset([param1, param2, ...])
TrustRulesetsApi.deleteTrustRuleset([param1, param2, ...])
Request is successful.
Not authorized to delete trust rulesets.
The trust ruleset does not exist.
Cannot delete a trust ruleset that is in use.
- Java
- Python
- JavaScript
import com.trendmicro.deepsecurity.ApiClient; import com.trendmicro.deepsecurity.Configuration; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.ApiException; import com.trendmicro.deepsecurity.api.TrustRulesetsApi; public class DeleteTrustRulesetExample { public static void main(String[] args) { // Setup ApiClient defaultClient = Configuration.getDefaultApiClient(); defaultClient.setBasePath("YOUR HOST"); // Authentication ApiKeyAuth Legacy API Key = (ApiKeyAuth) defaultClient.getAuthentication("Legacy API Key"); Legacy API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } ApiKeyAuth Trend Micro Cloud One API Key = (ApiKeyAuth) defaultClient.getAuthentication("Trend Micro Cloud One API Key"); Trend Micro Cloud One API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } // Initialization // Set Any Required Values TrustRulesetsApi instance = new TrustRulesetsApi(); Long acTrustRulesetID = 1L; String apiVersion = "YOUR VERSION"; try { // Please replace the parameter values with yours instance.deleteTrustRuleset(acTrustRulesetID, apiVersion); } catch (ApiException e) { System.err.println("An exception occurred when calling TrustRulesetsApi.deleteTrustRuleset"); e.printStackTrace(); } } }
Delete a Trust Rule from a Trust Ruleset
Delete a single trust rule from a trust ruleset by the trust ruleset ID and the trust rule ID.
TrustRulesetsApi.deleteTrustRuleFromTrustRuleset([param1, param2, ...])
TrustRulesetsApi.delete_trust_rule_from_trust_ruleset([param1, param2, ...])
TrustRulesetsApi.deleteTrustRuleFromTrustRuleset([param1, param2, ...])
Request is successful.
Not authorized to delete trust rules.
The trust ruleset or the trust rule does not exist.
- Java
- Python
- JavaScript
import com.trendmicro.deepsecurity.ApiClient; import com.trendmicro.deepsecurity.Configuration; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.ApiException; import com.trendmicro.deepsecurity.api.TrustRulesetsApi; public class DeleteTrustRuleFromTrustRulesetExample { public static void main(String[] args) { // Setup ApiClient defaultClient = Configuration.getDefaultApiClient(); defaultClient.setBasePath("YOUR HOST"); // Authentication ApiKeyAuth Legacy API Key = (ApiKeyAuth) defaultClient.getAuthentication("Legacy API Key"); Legacy API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } ApiKeyAuth Trend Micro Cloud One API Key = (ApiKeyAuth) defaultClient.getAuthentication("Trend Micro Cloud One API Key"); Trend Micro Cloud One API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } // Initialization // Set Any Required Values TrustRulesetsApi instance = new TrustRulesetsApi(); Long acTrustRulesetID = 1L; Long acTrustRuleID = 1L; String apiVersion = "YOUR VERSION"; try { // Please replace the parameter values with yours instance.deleteTrustRuleFromTrustRuleset(acTrustRulesetID, acTrustRuleID, apiVersion); } catch (ApiException e) { System.err.println("An exception occurred when calling TrustRulesetsApi.deleteTrustRuleFromTrustRuleset"); e.printStackTrace(); } } }
List Trust Rules in a Trust Ruleset
List all trust rules in a trust ruleset by trust ruleset ID.
TrustRulesetsApi.listTrustRulesetRules([param1, param2, ...])
TrustRulesetsApi.list_trust_ruleset_rules([param1, param2, ...])
TrustRulesetsApi.listTrustRulesetRules([param1, param2, ...])
successful operation
Not authorized to list the trust rules in a trust ruleset.
- Java
- Python
- JavaScript
import com.trendmicro.deepsecurity.ApiClient; import com.trendmicro.deepsecurity.Configuration; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.ApiException; import com.trendmicro.deepsecurity.api.TrustRulesetsApi; import com.trendmicro.deepsecurity.model.TrustRules; public class ListTrustRulesetRulesExample { public static void main(String[] args) { // Setup ApiClient defaultClient = Configuration.getDefaultApiClient(); defaultClient.setBasePath("YOUR HOST"); // Authentication ApiKeyAuth Legacy API Key = (ApiKeyAuth) defaultClient.getAuthentication("Legacy API Key"); Legacy API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } ApiKeyAuth Trend Micro Cloud One API Key = (ApiKeyAuth) defaultClient.getAuthentication("Trend Micro Cloud One API Key"); Trend Micro Cloud One API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } // Initialization // Set Any Required Values TrustRulesetsApi instance = new TrustRulesetsApi(); Long acTrustRulesetID = 1L; String apiVersion = "YOUR VERSION"; try { // Please replace the parameter values with yours TrustRules result = instance.listTrustRulesetRules(acTrustRulesetID, apiVersion); System.out.println(result); } catch (ApiException e) { System.err.println("An exception occurred when calling TrustRulesetsApi.listTrustRulesetRules"); e.printStackTrace(); } } }
- 200
{- "trustRuleCount": 0,
- "applicationControlTrustRules": [
- {
- "type": "allowFromSourceTarget",
- "name": "string",
- "description": "string",
- "isAssigned": true,
- "createdTime": 0,
- "lastUpdatedTime": 0,
- "rulesetIDs": [
- 0
], - "attributes": [
- {
- "name": "string",
- "value": "string"
}
], - "ID": 0
}
]
}
Add Trust Rule IDs
Assign additional trust rule IDs to a trust ruleset.
TrustRulesetsApi.addTrustRules([param1, param2, ...])
TrustRulesetsApi.add_trust_rules([param1, param2, ...])
TrustRulesetsApi.addTrustRules([param1, param2, ...])
path Parameters
header Parameters
Request Body schema: application/json
The ID numbers of the trust rules to add.
successful operation
Not authorized to modify trust rulesets.
The trust ruleset or rules do not exist.
- Payload
- Java
- Python
- JavaScript
{- "ruleIDs": [
- 0
]
}
- 200
{- "ruleIDs": [
- 0
]
}
Set Trust Rule IDs in a Ruleset
Set only the specified trust rule IDs to be assigned to the trust ruleset.
TrustRulesetsApi.setTrustRules([param1, param2, ...])
TrustRulesetsApi.set_trust_rules([param1, param2, ...])
TrustRulesetsApi.setTrustRules([param1, param2, ...])
path Parameters
header Parameters
Request Body schema: application/json
The ID numbers of the trust rules to set.
successful operation
Not authorized to modify trust rulesets.
The trust ruleset does not exist.
- Payload
- Java
- Python
- JavaScript
{- "ruleIDs": [
- 0
]
}
- 200
{- "ruleIDs": [
- 0
]
}
List a Trust Ruleset Assignment
List a trust ruleset's computer and policy assignment by the trust ruleset ID.
TrustRulesetsApi.listTrustRulesetAssignments([param1, param2, ...])
TrustRulesetsApi.list_trust_ruleset_assignments([param1, param2, ...])
TrustRulesetsApi.listTrustRulesetAssignments([param1, param2, ...])
successful operation
Not authorized to access trust ruleset.
The trust ruleset does not exist.
- Java
- Python
- JavaScript
import com.trendmicro.deepsecurity.ApiClient; import com.trendmicro.deepsecurity.Configuration; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.auth.ApiKeyAuth; import com.trendmicro.deepsecurity.ApiException; import com.trendmicro.deepsecurity.api.TrustRulesetsApi; import com.trendmicro.deepsecurity.model.TrustRulesetAssignments; public class ListTrustRulesetAssignmentsExample { public static void main(String[] args) { // Setup ApiClient defaultClient = Configuration.getDefaultApiClient(); defaultClient.setBasePath("YOUR HOST"); // Authentication ApiKeyAuth Legacy API Key = (ApiKeyAuth) defaultClient.getAuthentication("Legacy API Key"); Legacy API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } ApiKeyAuth Trend Micro Cloud One API Key = (ApiKeyAuth) defaultClient.getAuthentication("Trend Micro Cloud One API Key"); Trend Micro Cloud One API Key.setApiKey("YOUR API KEY"); try { defaultClient.trustAllCertificates(false); } catch (Exception e) { System.err.println("An exception occurred when calling ApiClient.trustAllCertificates"); e.printStackTrace(); } // Initialization // Set Any Required Values TrustRulesetsApi instance = new TrustRulesetsApi(); Long acTrustRulesetID = 1L; String apiVersion = "YOUR VERSION"; try { // Please replace the parameter values with yours TrustRulesetAssignments result = instance.listTrustRulesetAssignments(acTrustRulesetID, apiVersion); System.out.println(result); } catch (ApiException e) { System.err.println("An exception occurred when calling TrustRulesetsApi.listTrustRulesetAssignments"); e.printStackTrace(); } } }
- 200
{- "computers": [
- {
- "name": "string",
- "id": 0
}
], - "policies": [
- {
- "name": "string",
- "id": 0
}
]
}