Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validation: Fix Static Tests results #37

Merged
merged 2 commits into from
Jan 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ VARIABLE | REQUIRED | TYPE | DESCRIPTION
[lookup domain](#action-lookup-domain) - Get all Iris Investigate data for a domain using the Iris Investigate API endpoint (required)
[enrich domain](#action-enrich-domain) - Get all Iris Investigate data for a domain except counts using the high volume Iris Enrich API endpoint (if provisioned)
[on poll](#action-on-poll) - Execute scheduled playbooks based on the set interval(mins) in 'domaintools_scheduled_playbooks' custom list. Smaller intervals will result in more accurate schedules
[configure scheduled playbooks](#action-configure-scheduled-playbooks) - Run on initial setup to configure the optional monitoring playbooks. This action creates a custom list to manage the playbook scheduling and run status.
[configure scheduled playbooks](#action-configure-scheduled-playbooks) - Run on initial setup to configure the optional monitoring playbooks. This action creates a custom list to manage the playbook scheduling and run status

## action: 'test connectivity'
Validate the asset configuration for connectivity
Expand Down Expand Up @@ -619,7 +619,7 @@ No parameters are required for this action
No Output

## action: 'configure scheduled playbooks'
Run on initial setup to configure the optional monitoring playbooks. This action creates a custom list to manage the playbook scheduling and run status.
Run on initial setup to configure the optional monitoring playbooks. This action creates a custom list to manage the playbook scheduling and run status

Type: **generic**
Read only: **True**
Expand All @@ -628,4 +628,9 @@ Read only: **True**
No parameters are required for this action

#### Action Output
No Output
DATA PATH | TYPE | CONTAINS | EXAMPLE VALUES
--------- | ---- | -------- | --------------
action_result.status | string | | failed success
action_result.data.\* | string | |
action_result.summary | string | |
action_result.message | string | |
27 changes: 24 additions & 3 deletions domaintools_iris.json
Original file line number Diff line number Diff line change
Expand Up @@ -2060,12 +2060,33 @@
},
{
"action": "configure scheduled playbooks",
"description": "Run on initial setup to configure the optional monitoring playbooks. This action creates a custom list to manage the playbook scheduling and run status.",
"description": "Run on initial setup to configure the optional monitoring playbooks. This action creates a custom list to manage the playbook scheduling and run status",
"type": "generic",
"identifier": "configure_scheduled_playbooks",
"identifier": "configure_monitoring_scheduled_playbooks",
"read_only": true,
"parameters": {},
"output": [],
"output": [
{
"data_path": "action_result.status",
"data_type": "string",
"example_values": [
"failed",
"success"
]
},
{
"data_path": "action_result.data.*",
"data_type": "string"
},
{
"data_path": "action_result.summary",
"data_type": "string"
},
{
"data_path": "action_result.message",
"data_type": "string"
}
],
"versions": "EQ(*)"
}
],
Expand Down
8 changes: 4 additions & 4 deletions domaintools_iris_connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class DomainToolsConnector(BaseConnector):
ACTION_ID_REVERSE_DOMAIN = "reverse_lookup_domain"
ACTION_ID_LOAD_HASH = "load_hash"
ACTION_ID_ON_POLL = "on_poll"
ACTION_ID_CONFIGURE_SCHEDULED_PLAYBOOK = "configure_scheduled_playbooks"
ACTION_ID_CONFIGURE_SCHEDULED_PLAYBOOK = "configure_monitoring_scheduled_playbooks"

def __init__(self):
# Call the BaseConnectors init first
Expand Down Expand Up @@ -353,7 +353,7 @@ def handle_action(self, param):
elif action_id == self.ACTION_ID_ON_POLL:
ret_val = self._on_poll(param)
elif action_id == self.ACTION_ID_CONFIGURE_SCHEDULED_PLAYBOOK:
ret_val = self._configure_scheduled_playbooks(param)
ret_val = self._configure_monitoring_scheduled_playbooks(param)

return ret_val

Expand Down Expand Up @@ -867,8 +867,8 @@ def _on_poll(self, param):
return action_result.set_status(phantom.APP_SUCCESS, "Completed.")
return action_result.set_status(phantom.APP_ERROR, "Something went wrong.")

def _configure_scheduled_playbooks(self, param):
self.debug_print("configure_scheduled_playbooks action called")
def _configure_monitoring_scheduled_playbooks(self, param):
self.debug_print("configure_monitoring_scheduled_playbooks action called")
action_result = self.add_action_result(ActionResult(dict(param)))

res, is_created = self._create_scheduled_playbook_list()
Expand Down
Loading