splunk-soar-sdk 1.5.3__py3-none-any.whl → 1.6.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- soar_sdk/abstract.py +5 -0
- soar_sdk/app_client.py +7 -1
- {splunk_soar_sdk-1.5.3.dist-info → splunk_soar_sdk-1.6.1.dist-info}/METADATA +2 -2
- {splunk_soar_sdk-1.5.3.dist-info → splunk_soar_sdk-1.6.1.dist-info}/RECORD +7 -7
- {splunk_soar_sdk-1.5.3.dist-info → splunk_soar_sdk-1.6.1.dist-info}/WHEEL +0 -0
- {splunk_soar_sdk-1.5.3.dist-info → splunk_soar_sdk-1.6.1.dist-info}/entry_points.txt +0 -0
- {splunk_soar_sdk-1.5.3.dist-info → splunk_soar_sdk-1.6.1.dist-info}/licenses/LICENSE +0 -0
soar_sdk/abstract.py
CHANGED
|
@@ -65,6 +65,11 @@ class SOARClient(Generic[SummaryType]):
|
|
|
65
65
|
"""Return the current Container ID passed in the Connector Run Action JSON."""
|
|
66
66
|
pass
|
|
67
67
|
|
|
68
|
+
@abstractmethod
|
|
69
|
+
def get_asset_id(self) -> str:
|
|
70
|
+
"""Return the current Asset ID passed in the Connector Run Action JSON."""
|
|
71
|
+
pass
|
|
72
|
+
|
|
68
73
|
def get(
|
|
69
74
|
self,
|
|
70
75
|
endpoint: str,
|
soar_sdk/app_client.py
CHANGED
|
@@ -46,6 +46,7 @@ class AppClient(SOARClient[SummaryType]):
|
|
|
46
46
|
self._summary: Optional[SummaryType] = None
|
|
47
47
|
self._message: Optional[str] = None
|
|
48
48
|
self.__container_id: int = 0
|
|
49
|
+
self.__asset_id: str = ""
|
|
49
50
|
|
|
50
51
|
@property
|
|
51
52
|
def client(self) -> httpx.Client:
|
|
@@ -71,13 +72,18 @@ class AppClient(SOARClient[SummaryType]):
|
|
|
71
72
|
"""Return the current Container ID passed in the Connector Run Action JSON."""
|
|
72
73
|
return self.__container_id
|
|
73
74
|
|
|
75
|
+
def get_asset_id(self) -> str:
|
|
76
|
+
"""Return the current Asset ID passed in the Connector Run Action JSON."""
|
|
77
|
+
return self.__asset_id
|
|
78
|
+
|
|
74
79
|
def update_client(
|
|
75
|
-
self, soar_auth: SOARClientAuth, asset_id: str, container_id: int = 0
|
|
80
|
+
self, soar_auth: SOARClientAuth, asset_id: str = "", container_id: int = 0
|
|
76
81
|
) -> None:
|
|
77
82
|
"""Update the SOAR client with the given authentication and asset ID."""
|
|
78
83
|
self.authenticate_soar_client(soar_auth)
|
|
79
84
|
self._containers_api.set_executing_asset(asset_id)
|
|
80
85
|
self.__container_id = container_id
|
|
86
|
+
self.__asset_id = asset_id
|
|
81
87
|
|
|
82
88
|
def authenticate_soar_client(self, soar_auth: SOARClientAuth) -> None:
|
|
83
89
|
"""Authenticate the SOAR client with the given authentication credentials."""
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: splunk-soar-sdk
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.6.1
|
|
4
4
|
Summary: The official framework for developing and testing Splunk SOAR Apps
|
|
5
5
|
Project-URL: Homepage, https://github.com/phantomcyber/splunk-soar-sdk
|
|
6
6
|
Project-URL: Documentation, https://github.com/phantomcyber/splunk-soar-sdk
|
|
@@ -93,7 +93,7 @@ Running the above command will add `splunk-soar-sdk` as a dependency of your Spl
|
|
|
93
93
|
|
|
94
94
|
## Usage
|
|
95
95
|
|
|
96
|
-
In order to start using SDK and build your first Splunk SOAR App, follow the [Getting Started guide](https://phantomcyber.github.io/splunk-soar-sdk/getting_started.html).
|
|
96
|
+
In order to start using SDK and build your first Splunk SOAR App, follow the [Getting Started guide](https://phantomcyber.github.io/splunk-soar-sdk/getting_started/index.html).
|
|
97
97
|
|
|
98
98
|
A Splunk SOAR app developed with the SDK will look something like this:
|
|
99
99
|
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
soar_sdk/__init__.py,sha256=RzAng-ARqpK01SY82lNy4uYJFVG0yW6Q3CccEqbToJ4,726
|
|
2
|
-
soar_sdk/abstract.py,sha256=
|
|
2
|
+
soar_sdk/abstract.py,sha256=jGXs2Fv5TRpnh5Duz3mWjY8_DAOpY4RSSzvw_z4XN4I,7950
|
|
3
3
|
soar_sdk/action_results.py,sha256=gAQwHjXbkkzOJTmQnLwBjKjwbuz8mSPyqIVcirVS598,10114
|
|
4
4
|
soar_sdk/actions_manager.py,sha256=wJCyfzkI_6OKZ-Kmll4vRJpGvYdL93Uw-JyEEGnKcw0,5779
|
|
5
5
|
soar_sdk/app.py,sha256=9zI8RM6uo4V0Bj4cgCvJzSOjIBPrvt2meXVAMaPhVrE,32882
|
|
6
6
|
soar_sdk/app_cli_runner.py,sha256=fJoozhyAt7QUMuc02nE5RL_InpsjQBpr6U4rF9sey3E,11627
|
|
7
|
-
soar_sdk/app_client.py,sha256=
|
|
7
|
+
soar_sdk/app_client.py,sha256=0r3jIvMM8szCEHXOgRu07VaovKH96pZut5rn2GfYcsc,6275
|
|
8
8
|
soar_sdk/asset.py,sha256=deS8_B5hr7W2fED8_6wUpVriRgiQ5r8TkGVHiasIaro,10666
|
|
9
9
|
soar_sdk/async_utils.py,sha256=gND8ZiVTqDYLQ88Ua6SN1mInJaEcfa168eOaRoURt3E,1441
|
|
10
10
|
soar_sdk/colors.py,sha256=--i_iXqfyITUz4O95HMjfZQGbwFZ34bLmBhtfpXXqlQ,1095
|
|
@@ -96,8 +96,8 @@ soar_sdk/views/components/pie_chart.py,sha256=LVTeHVJN6nf2vjUs9y7PDBhS0U1fKW750l
|
|
|
96
96
|
soar_sdk/webhooks/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
97
97
|
soar_sdk/webhooks/models.py,sha256=-rjuFA9cRX5zTLp7cHSHVTkt5eVJD6BdESGbj_qkyHI,4540
|
|
98
98
|
soar_sdk/webhooks/routing.py,sha256=BKbURSrBPdOTS5UFL-mHzFEr-Fj04mJMx9KeiPrZ2VQ,6872
|
|
99
|
-
splunk_soar_sdk-1.
|
|
100
|
-
splunk_soar_sdk-1.
|
|
101
|
-
splunk_soar_sdk-1.
|
|
102
|
-
splunk_soar_sdk-1.
|
|
103
|
-
splunk_soar_sdk-1.
|
|
99
|
+
splunk_soar_sdk-1.6.1.dist-info/METADATA,sha256=heLpdVhLVaOMjf4_LGcazK8gCj4LfL65F4HSm2yLAUA,7361
|
|
100
|
+
splunk_soar_sdk-1.6.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
101
|
+
splunk_soar_sdk-1.6.1.dist-info/entry_points.txt,sha256=CgBjo2ZWpYNkt9TgvToL26h2Tg1yt8FbvYTb5NVgNuc,51
|
|
102
|
+
splunk_soar_sdk-1.6.1.dist-info/licenses/LICENSE,sha256=gNCGrGhrSQb1PUzBOByVUN1tvaliwLZfna-QU2r2hQ8,11345
|
|
103
|
+
splunk_soar_sdk-1.6.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|