Skip to content

Commit 5e131f5

Browse files
authored
Merge pull request Azure#12641 from gloo-shock/master
Add support of lacking event types
2 parents b6327e8 + aeb7eaf commit 5e131f5

File tree

9 files changed

+35
-785
lines changed

9 files changed

+35
-785
lines changed

Solutions/WithSecureElementsViaFunction/Data Connectors/WithSecureElementsAzureFunction/lib/events_formatter.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
from .message_factory import MessageFactory
21
import re
32

43

@@ -43,17 +42,14 @@ class Formatter:
4342
}
4443
DEEP_GUARD_RARITY_REPUTATION_REGEX = "Rarity: (\\d+), Reputation: (\\d+)"
4544

46-
def __init__(self):
47-
self._message_factory = MessageFactory()
48-
4945
def format(self, event):
5046
engine = event.engine
5147
result = {
5248
"DeviceVendor": "WithSecure",
5349
"DeviceEventClassID": f"{engine}.{event.action}",
5450
"Activity": Formatter.ENGINE_TO_ACTIVITY.get(engine, engine),
5551
"LogSeverity": Formatter.SEVERITY_TO_INDEX.get(event.severity),
56-
"Message": self._message_factory.get_message(event),
52+
"Message": event.message,
5753
"DeviceAction": event.action,
5854
"SimplifiedDeviceAction": event.action,
5955
"PersistenceTimestamp": event.persistenceTimestamp,

Solutions/WithSecureElementsViaFunction/Data Connectors/WithSecureElementsAzureFunction/lib/message_factory.py

Lines changed: 0 additions & 540 deletions
This file was deleted.

Solutions/WithSecureElementsViaFunction/Data Connectors/WithSecureElementsAzureFunction/lib/messages.properties

Lines changed: 0 additions & 212 deletions
This file was deleted.

Solutions/WithSecureElementsViaFunction/Data Connectors/WithSecureElementsAzureFunction/lib/withsecure_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ def _get_events_page(self, auth_token, from_date, org_id=None, next_page=None):
101101
engine_param_value = self._engine_group
102102
else:
103103
engine_param = "engineGroup"
104-
engine_param_value = "epp,edr,ecp"
104+
engine_param_value = "epp,edr,ecp,xm"
105105

106106
data = {
107107
"limit": 100,
Binary file not shown.

Solutions/WithSecureElementsViaFunction/Data Connectors/azuredeploy_Connector_WithSecureElements_AzureFunction.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,8 @@
425425
"scope": "[resourceId('Microsoft.Insights/dataCollectionRules', variables('ruleName'))]",
426426
"properties": {
427427
"roleDefinitionId": "[resourceId('Microsoft.Authorization/roleDefinitions', variables('dcrRoleId'))]",
428-
"principalId": "[parameters('entraObjectId')]"
428+
"principalId": "[parameters('entraObjectId')]",
429+
"principalType": "ServicePrincipal"
429430
}
430431
}
431432
],
Lines changed: 30 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,30 @@
1-
azure-core==1.38.0 ; python_version >= "3.10" and python_version < "3.11"
2-
azure-data-tables==12.5.0 ; python_version >= "3.10" and python_version < "3.11"
3-
azure-identity==1.15.0 ; python_version >= "3.10" and python_version < "3.11"
4-
azure-monitor-ingestion==1.0.3 ; python_version >= "3.10" and python_version < "3.11"
5-
azure-storage-file-share==12.15.0 ; python_version >= "3.10" and python_version < "3.11"
6-
azure-functions==1.11.2 ; python_version >= "3.10" and python_version < "3.11"
7-
certifi==2024.2.2 ; python_version >= "3.10" and python_version < "3.11"
8-
cffi==1.16.0 ; python_version >= "3.10" and python_version < "3.11" and platform_python_implementation != "PyPy"
9-
charset-normalizer==3.3.2 ; python_version >= "3.10" and python_version < "3.11"
10-
cryptography==44.0.1 ; python_version >= "3.10" and python_version < "3.11"
11-
idna==3.6 ; python_version >= "3.10" and python_version < "3.11"
12-
isodate==0.6.1 ; python_version >= "3.10" and python_version < "3.11"
13-
msal-extensions==1.1.0 ; python_version >= "3.10" and python_version < "3.11"
14-
msal==1.26.0 ; python_version >= "3.10" and python_version < "3.11"
15-
multidict==6.0.5 ; python_version >= "3.10" and python_version < "3.11"
16-
packaging==23.2 ; python_version >= "3.10" and python_version < "3.11"
17-
portalocker==2.8.2 ; python_version >= "3.10" and python_version < "3.11"
18-
pycparser==2.21 ; python_version >= "3.10" and python_version < "3.11" and platform_python_implementation != "PyPy"
19-
pyjwt[crypto]==2.8.0 ; python_version >= "3.10" and python_version < "3.11"
20-
pywin32==306 ; python_version >= "3.10" and python_version < "3.11" and platform_system == "Windows"
21-
requests==2.32.4 ; python_version >= "3.10" and python_version < "3.11"
22-
six==1.16.0 ; python_version >= "3.10" and python_version < "3.11"
23-
typing-extensions==4.9.0 ; python_version >= "3.10" and python_version < "3.11"
24-
urllib3==2.6.3 ; python_version >= "3.10" and python_version < "3.11"
25-
yarl==1.9.4 ; python_version >= "3.10" and python_version < "3.11"
1+
azure-core==1.38.0 ; python_version == "3.12"
2+
azure-data-tables==12.4.4 ; python_version == "3.12"
3+
azure-identity==1.15.0 ; python_version == "3.12"
4+
azure-monitor-ingestion==1.0.3 ; python_version == "3.12"
5+
azure-storage-file-share==12.13.0 ; python_version == "3.12"
6+
black==25.1.0 ; python_version == "3.12"
7+
certifi==2024.7.4 ; python_version == "3.12"
8+
cffi==1.16.0 ; python_version == "3.12" and platform_python_implementation != "PyPy"
9+
charset-normalizer==3.3.2 ; python_version == "3.12"
10+
click==8.1.7 ; python_version == "3.12"
11+
colorama==0.4.6 ; python_version == "3.12" and platform_system == "Windows"
12+
cryptography==43.0.1 ; python_version == "3.12"
13+
idna==3.7 ; python_version == "3.12"
14+
isodate==0.6.1 ; python_version == "3.12"
15+
msal-extensions==1.1.0 ; python_version == "3.12"
16+
msal==1.26.0 ; python_version == "3.12"
17+
multidict==6.0.5 ; python_version == "3.12"
18+
mypy-extensions==1.0.0 ; python_version == "3.12"
19+
packaging==23.2 ; python_version == "3.12"
20+
pathspec==0.12.1 ; python_version == "3.12"
21+
platformdirs==4.2.0 ; python_version == "3.12"
22+
portalocker==2.8.2 ; python_version == "3.12"
23+
pycparser==2.21 ; python_version == "3.12" and platform_python_implementation != "PyPy"
24+
pyjwt==2.8.0 ; python_version == "3.12"
25+
pywin32==306 ; python_version == "3.12" and platform_system == "Windows"
26+
requests==2.31.0 ; python_version == "3.12"
27+
six==1.16.0 ; python_version == "3.12"
28+
typing-extensions==4.9.0 ; python_version == "3.12"
29+
urllib3==2.6.3 ; python_version == "3.12"
30+
yarl==1.9.4 ; python_version == "3.12"
0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)