Skip to content

Commit 04e2fa1

Browse files
authored
[AutoPR security/resource-manager] Add Microsoft.Security applicationWhitelistings API (#6262)
* Generated from 0bc0b6465c2c93267a29e4eb0c39e2b12a8b623e add operation ID's * Generated from 56fe4277e879002f98abc961fc5fb3abf80cf32a remove location from example, add Executable to fileType * Generated from 6307743902cd21e4a200cca1cddc2383121ae216 add Whitelistings to custom-words
1 parent f249de8 commit 04e2fa1

20 files changed

+996
-0
lines changed

sdk/security/azure-mgmt-security/azure/mgmt/security/models/__init__.py

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,14 @@
4747
from .jit_network_access_policy_initiate_virtual_machine_py3 import JitNetworkAccessPolicyInitiateVirtualMachine
4848
from .jit_network_access_policy_initiate_request_py3 import JitNetworkAccessPolicyInitiateRequest
4949
from .kind_py3 import Kind
50+
from .app_whitelisting_issue_summary_py3 import AppWhitelistingIssueSummary
51+
from .vm_recommendation_py3 import VmRecommendation
52+
from .publisher_info_py3 import PublisherInfo
53+
from .user_recommendation_py3 import UserRecommendation
54+
from .path_recommendation_py3 import PathRecommendation
55+
from .app_whitelisting_group_py3 import AppWhitelistingGroup
56+
from .app_whitelisting_groups_py3 import AppWhitelistingGroups
57+
from .app_whitelisting_put_group_data_py3 import AppWhitelistingPutGroupData
5058
from .operation_display_py3 import OperationDisplay
5159
from .operation_py3 import Operation
5260
from .security_task_parameters_py3 import SecurityTaskParameters
@@ -125,6 +133,14 @@
125133
from .jit_network_access_policy_initiate_virtual_machine import JitNetworkAccessPolicyInitiateVirtualMachine
126134
from .jit_network_access_policy_initiate_request import JitNetworkAccessPolicyInitiateRequest
127135
from .kind import Kind
136+
from .app_whitelisting_issue_summary import AppWhitelistingIssueSummary
137+
from .vm_recommendation import VmRecommendation
138+
from .publisher_info import PublisherInfo
139+
from .user_recommendation import UserRecommendation
140+
from .path_recommendation import PathRecommendation
141+
from .app_whitelisting_group import AppWhitelistingGroup
142+
from .app_whitelisting_groups import AppWhitelistingGroups
143+
from .app_whitelisting_put_group_data import AppWhitelistingPutGroupData
128144
from .operation_display import OperationDisplay
129145
from .operation import Operation
130146
from .security_task_parameters import SecurityTaskParameters
@@ -248,6 +264,14 @@
248264
'JitNetworkAccessPolicyInitiateVirtualMachine',
249265
'JitNetworkAccessPolicyInitiateRequest',
250266
'Kind',
267+
'AppWhitelistingIssueSummary',
268+
'VmRecommendation',
269+
'PublisherInfo',
270+
'UserRecommendation',
271+
'PathRecommendation',
272+
'AppWhitelistingGroup',
273+
'AppWhitelistingGroups',
274+
'AppWhitelistingPutGroupData',
251275
'OperationDisplay',
252276
'Operation',
253277
'SecurityTaskParameters',
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class AppWhitelistingGroup(Model):
16+
"""AppWhitelistingGroup.
17+
18+
Variables are only populated by the server, and will be ignored when
19+
sending a request.
20+
21+
:ivar id: Resource Id
22+
:vartype id: str
23+
:ivar name: Resource name
24+
:vartype name: str
25+
:ivar type: Resource type
26+
:vartype type: str
27+
:ivar location: Location where the resource is stored
28+
:vartype location: str
29+
:param enforcement_mode: Possible values include: 'Audit', 'Enforce'
30+
:type enforcement_mode: str or ~azure.mgmt.security.models.enum
31+
:param configuration_status: Possible values include: 'Configured',
32+
'NotConfigured', 'InProgress', 'Failed', 'NoStatus'
33+
:type configuration_status: str or ~azure.mgmt.security.models.enum
34+
:param recommendation_status: Possible values include: 'Recommended',
35+
'NotRecommended', 'NotAvailable', 'NoStatus'
36+
:type recommendation_status: str or ~azure.mgmt.security.models.enum
37+
:param issues:
38+
:type issues:
39+
list[~azure.mgmt.security.models.AppWhitelistingIssueSummary]
40+
:param source_system: Possible values include: 'Azure_AppLocker',
41+
'Azure_AuditD', 'NonAzure_AppLocker', 'NonAzure_AuditD', 'None'
42+
:type source_system: str or ~azure.mgmt.security.models.enum
43+
:param vm_recommendations:
44+
:type vm_recommendations:
45+
list[~azure.mgmt.security.models.VmRecommendation]
46+
:param path_recommendations:
47+
:type path_recommendations:
48+
list[~azure.mgmt.security.models.PathRecommendation]
49+
"""
50+
51+
_validation = {
52+
'id': {'readonly': True},
53+
'name': {'readonly': True},
54+
'type': {'readonly': True},
55+
'location': {'readonly': True},
56+
}
57+
58+
_attribute_map = {
59+
'id': {'key': 'id', 'type': 'str'},
60+
'name': {'key': 'name', 'type': 'str'},
61+
'type': {'key': 'type', 'type': 'str'},
62+
'location': {'key': 'location', 'type': 'str'},
63+
'enforcement_mode': {'key': 'properties.enforcementMode', 'type': 'str'},
64+
'configuration_status': {'key': 'properties.configurationStatus', 'type': 'str'},
65+
'recommendation_status': {'key': 'properties.recommendationStatus', 'type': 'str'},
66+
'issues': {'key': 'properties.issues', 'type': '[AppWhitelistingIssueSummary]'},
67+
'source_system': {'key': 'properties.sourceSystem', 'type': 'str'},
68+
'vm_recommendations': {'key': 'properties.vmRecommendations', 'type': '[VmRecommendation]'},
69+
'path_recommendations': {'key': 'properties.pathRecommendations', 'type': '[PathRecommendation]'},
70+
}
71+
72+
def __init__(self, **kwargs):
73+
super(AppWhitelistingGroup, self).__init__(**kwargs)
74+
self.id = None
75+
self.name = None
76+
self.type = None
77+
self.location = None
78+
self.enforcement_mode = kwargs.get('enforcement_mode', None)
79+
self.configuration_status = kwargs.get('configuration_status', None)
80+
self.recommendation_status = kwargs.get('recommendation_status', None)
81+
self.issues = kwargs.get('issues', None)
82+
self.source_system = kwargs.get('source_system', None)
83+
self.vm_recommendations = kwargs.get('vm_recommendations', None)
84+
self.path_recommendations = kwargs.get('path_recommendations', None)
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class AppWhitelistingGroup(Model):
16+
"""AppWhitelistingGroup.
17+
18+
Variables are only populated by the server, and will be ignored when
19+
sending a request.
20+
21+
:ivar id: Resource Id
22+
:vartype id: str
23+
:ivar name: Resource name
24+
:vartype name: str
25+
:ivar type: Resource type
26+
:vartype type: str
27+
:ivar location: Location where the resource is stored
28+
:vartype location: str
29+
:param enforcement_mode: Possible values include: 'Audit', 'Enforce'
30+
:type enforcement_mode: str or ~azure.mgmt.security.models.enum
31+
:param configuration_status: Possible values include: 'Configured',
32+
'NotConfigured', 'InProgress', 'Failed', 'NoStatus'
33+
:type configuration_status: str or ~azure.mgmt.security.models.enum
34+
:param recommendation_status: Possible values include: 'Recommended',
35+
'NotRecommended', 'NotAvailable', 'NoStatus'
36+
:type recommendation_status: str or ~azure.mgmt.security.models.enum
37+
:param issues:
38+
:type issues:
39+
list[~azure.mgmt.security.models.AppWhitelistingIssueSummary]
40+
:param source_system: Possible values include: 'Azure_AppLocker',
41+
'Azure_AuditD', 'NonAzure_AppLocker', 'NonAzure_AuditD', 'None'
42+
:type source_system: str or ~azure.mgmt.security.models.enum
43+
:param vm_recommendations:
44+
:type vm_recommendations:
45+
list[~azure.mgmt.security.models.VmRecommendation]
46+
:param path_recommendations:
47+
:type path_recommendations:
48+
list[~azure.mgmt.security.models.PathRecommendation]
49+
"""
50+
51+
_validation = {
52+
'id': {'readonly': True},
53+
'name': {'readonly': True},
54+
'type': {'readonly': True},
55+
'location': {'readonly': True},
56+
}
57+
58+
_attribute_map = {
59+
'id': {'key': 'id', 'type': 'str'},
60+
'name': {'key': 'name', 'type': 'str'},
61+
'type': {'key': 'type', 'type': 'str'},
62+
'location': {'key': 'location', 'type': 'str'},
63+
'enforcement_mode': {'key': 'properties.enforcementMode', 'type': 'str'},
64+
'configuration_status': {'key': 'properties.configurationStatus', 'type': 'str'},
65+
'recommendation_status': {'key': 'properties.recommendationStatus', 'type': 'str'},
66+
'issues': {'key': 'properties.issues', 'type': '[AppWhitelistingIssueSummary]'},
67+
'source_system': {'key': 'properties.sourceSystem', 'type': 'str'},
68+
'vm_recommendations': {'key': 'properties.vmRecommendations', 'type': '[VmRecommendation]'},
69+
'path_recommendations': {'key': 'properties.pathRecommendations', 'type': '[PathRecommendation]'},
70+
}
71+
72+
def __init__(self, *, enforcement_mode=None, configuration_status=None, recommendation_status=None, issues=None, source_system=None, vm_recommendations=None, path_recommendations=None, **kwargs) -> None:
73+
super(AppWhitelistingGroup, self).__init__(**kwargs)
74+
self.id = None
75+
self.name = None
76+
self.type = None
77+
self.location = None
78+
self.enforcement_mode = enforcement_mode
79+
self.configuration_status = configuration_status
80+
self.recommendation_status = recommendation_status
81+
self.issues = issues
82+
self.source_system = source_system
83+
self.vm_recommendations = vm_recommendations
84+
self.path_recommendations = path_recommendations
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class AppWhitelistingGroups(Model):
16+
"""Represents a list of VM/server groups and set of rules that are Recommended
17+
by Azure Security Center to be allowed.
18+
19+
:param value:
20+
:type value: list[~azure.mgmt.security.models.AppWhitelistingGroup]
21+
"""
22+
23+
_attribute_map = {
24+
'value': {'key': 'value', 'type': '[AppWhitelistingGroup]'},
25+
}
26+
27+
def __init__(self, **kwargs):
28+
super(AppWhitelistingGroups, self).__init__(**kwargs)
29+
self.value = kwargs.get('value', None)
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class AppWhitelistingGroups(Model):
16+
"""Represents a list of VM/server groups and set of rules that are Recommended
17+
by Azure Security Center to be allowed.
18+
19+
:param value:
20+
:type value: list[~azure.mgmt.security.models.AppWhitelistingGroup]
21+
"""
22+
23+
_attribute_map = {
24+
'value': {'key': 'value', 'type': '[AppWhitelistingGroup]'},
25+
}
26+
27+
def __init__(self, *, value=None, **kwargs) -> None:
28+
super(AppWhitelistingGroups, self).__init__(**kwargs)
29+
self.value = value
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class AppWhitelistingIssueSummary(Model):
16+
"""Represents a summary of the alerts of the VM/server group.
17+
18+
:param issue: Possible values include: 'ViolationsAudited',
19+
'ViolationsBlocked', 'MsiAndScriptViolationsAudited',
20+
'MsiAndScriptViolationsBlocked', 'ExecutableViolationsAudited',
21+
'RulesViolatedManually'
22+
:type issue: str or ~azure.mgmt.security.models.enum
23+
:param number_of_vms: The number of machines in the VM/server group that
24+
have this alert
25+
:type number_of_vms: float
26+
"""
27+
28+
_attribute_map = {
29+
'issue': {'key': 'issue', 'type': 'str'},
30+
'number_of_vms': {'key': 'numberOfVms', 'type': 'float'},
31+
}
32+
33+
def __init__(self, **kwargs):
34+
super(AppWhitelistingIssueSummary, self).__init__(**kwargs)
35+
self.issue = kwargs.get('issue', None)
36+
self.number_of_vms = kwargs.get('number_of_vms', None)
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class AppWhitelistingIssueSummary(Model):
16+
"""Represents a summary of the alerts of the VM/server group.
17+
18+
:param issue: Possible values include: 'ViolationsAudited',
19+
'ViolationsBlocked', 'MsiAndScriptViolationsAudited',
20+
'MsiAndScriptViolationsBlocked', 'ExecutableViolationsAudited',
21+
'RulesViolatedManually'
22+
:type issue: str or ~azure.mgmt.security.models.enum
23+
:param number_of_vms: The number of machines in the VM/server group that
24+
have this alert
25+
:type number_of_vms: float
26+
"""
27+
28+
_attribute_map = {
29+
'issue': {'key': 'issue', 'type': 'str'},
30+
'number_of_vms': {'key': 'numberOfVms', 'type': 'float'},
31+
}
32+
33+
def __init__(self, *, issue=None, number_of_vms: float=None, **kwargs) -> None:
34+
super(AppWhitelistingIssueSummary, self).__init__(**kwargs)
35+
self.issue = issue
36+
self.number_of_vms = number_of_vms
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.serialization import Model
13+
14+
15+
class AppWhitelistingPutGroupData(Model):
16+
"""The altered data of the recommended VM/server group policy.
17+
18+
:param enforcement_mode: Possible values include: 'Audit', 'Enforce'
19+
:type enforcement_mode: str or ~azure.mgmt.security.models.enum
20+
:param vm_recommendations:
21+
:type vm_recommendations:
22+
list[~azure.mgmt.security.models.VmRecommendation]
23+
:param path_recommendations:
24+
:type path_recommendations:
25+
list[~azure.mgmt.security.models.PathRecommendation]
26+
"""
27+
28+
_attribute_map = {
29+
'enforcement_mode': {'key': 'enforcementMode', 'type': 'str'},
30+
'vm_recommendations': {'key': 'vmRecommendations', 'type': '[VmRecommendation]'},
31+
'path_recommendations': {'key': 'pathRecommendations', 'type': '[PathRecommendation]'},
32+
}
33+
34+
def __init__(self, **kwargs):
35+
super(AppWhitelistingPutGroupData, self).__init__(**kwargs)
36+
self.enforcement_mode = kwargs.get('enforcement_mode', None)
37+
self.vm_recommendations = kwargs.get('vm_recommendations', None)
38+
self.path_recommendations = kwargs.get('path_recommendations', None)

0 commit comments

Comments
 (0)