From 1223c65659b92747dbc480fc898bcc639001e9b5 Mon Sep 17 00:00:00 2001 From: Azure SDK Bot Date: Fri, 20 Sep 2019 06:05:19 +0000 Subject: [PATCH 1/3] Generated from 97b167628eb4b3d4766f863302c4e0d81b12ee83 change the ProtectionMode object --- .../azure/mgmt/security/models/__init__.py | 3 ++ .../azure/mgmt/security/models/_models.py | 43 ++++++++++++++++- .../azure/mgmt/security/models/_models_py3.py | 47 +++++++++++++++++-- 3 files changed, 89 insertions(+), 4 deletions(-) diff --git a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/__init__.py b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/__init__.py index d0c40691dc6b..97856b47b9b1 100644 --- a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/__init__.py +++ b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/__init__.py @@ -73,6 +73,7 @@ from ._models_py3 import PathRecommendation from ._models_py3 import Pricing from ._models_py3 import PricingList + from ._models_py3 import ProtectionMode from ._models_py3 import PublisherInfo from ._models_py3 import RecommendationConfigurationProperties from ._models_py3 import RegulatoryComplianceAssessment @@ -163,6 +164,7 @@ from ._models import PathRecommendation from ._models import Pricing from ._models import PricingList + from ._models import ProtectionMode from ._models import PublisherInfo from ._models import RecommendationConfigurationProperties from ._models import RegulatoryComplianceAssessment @@ -300,6 +302,7 @@ 'PathRecommendation', 'Pricing', 'PricingList', + 'ProtectionMode', 'PublisherInfo', 'RecommendationConfigurationProperties', 'RegulatoryComplianceAssessment', diff --git a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py index 89600c9fb8d6..4e9679482f26 100644 --- a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py +++ b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py @@ -638,6 +638,8 @@ class AppWhitelistingGroup(Model): :vartype location: str :param enforcement_mode: Possible values include: 'Audit', 'Enforce' :type enforcement_mode: str or ~azure.mgmt.security.models.enum + :param protection_mode: + :type protection_mode: ~azure.mgmt.security.models.ProtectionMode :param configuration_status: Possible values include: 'Configured', 'NotConfigured', 'InProgress', 'Failed', 'NoStatus' :type configuration_status: str or ~azure.mgmt.security.models.enum @@ -671,6 +673,7 @@ class AppWhitelistingGroup(Model): 'type': {'key': 'type', 'type': 'str'}, 'location': {'key': 'location', 'type': 'str'}, 'enforcement_mode': {'key': 'properties.enforcementMode', 'type': 'str'}, + 'protection_mode': {'key': 'properties.protectionMode', 'type': 'ProtectionMode'}, 'configuration_status': {'key': 'properties.configurationStatus', 'type': 'str'}, 'recommendation_status': {'key': 'properties.recommendationStatus', 'type': 'str'}, 'issues': {'key': 'properties.issues', 'type': '[AppWhitelistingIssueSummary]'}, @@ -686,6 +689,7 @@ def __init__(self, **kwargs): self.type = None self.location = None self.enforcement_mode = kwargs.get('enforcement_mode', None) + self.protection_mode = kwargs.get('protection_mode', None) self.configuration_status = kwargs.get('configuration_status', None) self.recommendation_status = kwargs.get('recommendation_status', None) self.issues = kwargs.get('issues', None) @@ -738,8 +742,14 @@ def __init__(self, **kwargs): class AppWhitelistingPutGroupData(Model): """The altered data of the recommended VM/server group policy. - :param enforcement_mode: Possible values include: 'Audit', 'Enforce' + :param enforcement_mode: The enforcement mode of the group. Can also be + defined per collection type by using ProtectionMode. Possible values + include: 'Audit', 'Enforce' :type enforcement_mode: str or ~azure.mgmt.security.models.enum + :param protection_mode: The protection mode of the group per collection + type. Can also be defined for all collection types by using + EnforcementMode + :type protection_mode: ~azure.mgmt.security.models.ProtectionMode :param vm_recommendations: :type vm_recommendations: list[~azure.mgmt.security.models.VmRecommendation] @@ -750,6 +760,7 @@ class AppWhitelistingPutGroupData(Model): _attribute_map = { 'enforcement_mode': {'key': 'enforcementMode', 'type': 'str'}, + 'protection_mode': {'key': 'protectionMode', 'type': 'ProtectionMode'}, 'vm_recommendations': {'key': 'vmRecommendations', 'type': '[VmRecommendation]'}, 'path_recommendations': {'key': 'pathRecommendations', 'type': '[PathRecommendation]'}, } @@ -757,6 +768,7 @@ class AppWhitelistingPutGroupData(Model): def __init__(self, **kwargs): super(AppWhitelistingPutGroupData, self).__init__(**kwargs) self.enforcement_mode = kwargs.get('enforcement_mode', None) + self.protection_mode = kwargs.get('protection_mode', None) self.vm_recommendations = kwargs.get('vm_recommendations', None) self.path_recommendations = kwargs.get('path_recommendations', None) @@ -2776,6 +2788,35 @@ def __init__(self, **kwargs): self.value = kwargs.get('value', None) +class ProtectionMode(Model): + """The protection mode of the collection/file types. Exe/Msi/Script are used + for Windows, Executable is used for Linux. + + :param exe: Possible values include: 'Audit', 'Enforce' + :type exe: str or ~azure.mgmt.security.models.enum + :param msi: Possible values include: 'Audit', 'Enforce' + :type msi: str or ~azure.mgmt.security.models.enum + :param script: Possible values include: 'Audit', 'Enforce' + :type script: str or ~azure.mgmt.security.models.enum + :param executable: Possible values include: 'Audit', 'Enforce' + :type executable: str or ~azure.mgmt.security.models.enum + """ + + _attribute_map = { + 'exe': {'key': 'Exe', 'type': 'str'}, + 'msi': {'key': 'Msi', 'type': 'str'}, + 'script': {'key': 'Script', 'type': 'str'}, + 'executable': {'key': 'Executable', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ProtectionMode, self).__init__(**kwargs) + self.exe = kwargs.get('exe', None) + self.msi = kwargs.get('msi', None) + self.script = kwargs.get('script', None) + self.executable = kwargs.get('executable', None) + + class PublisherInfo(Model): """Represents the publisher information of a process/rule. diff --git a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py index 0ec2a932124b..fa66e9726bb0 100644 --- a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py +++ b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py @@ -638,6 +638,8 @@ class AppWhitelistingGroup(Model): :vartype location: str :param enforcement_mode: Possible values include: 'Audit', 'Enforce' :type enforcement_mode: str or ~azure.mgmt.security.models.enum + :param protection_mode: + :type protection_mode: ~azure.mgmt.security.models.ProtectionMode :param configuration_status: Possible values include: 'Configured', 'NotConfigured', 'InProgress', 'Failed', 'NoStatus' :type configuration_status: str or ~azure.mgmt.security.models.enum @@ -671,6 +673,7 @@ class AppWhitelistingGroup(Model): 'type': {'key': 'type', 'type': 'str'}, 'location': {'key': 'location', 'type': 'str'}, 'enforcement_mode': {'key': 'properties.enforcementMode', 'type': 'str'}, + 'protection_mode': {'key': 'properties.protectionMode', 'type': 'ProtectionMode'}, 'configuration_status': {'key': 'properties.configurationStatus', 'type': 'str'}, 'recommendation_status': {'key': 'properties.recommendationStatus', 'type': 'str'}, 'issues': {'key': 'properties.issues', 'type': '[AppWhitelistingIssueSummary]'}, @@ -679,13 +682,14 @@ class AppWhitelistingGroup(Model): 'path_recommendations': {'key': 'properties.pathRecommendations', 'type': '[PathRecommendation]'}, } - 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: + def __init__(self, *, enforcement_mode=None, protection_mode=None, configuration_status=None, recommendation_status=None, issues=None, source_system=None, vm_recommendations=None, path_recommendations=None, **kwargs) -> None: super(AppWhitelistingGroup, self).__init__(**kwargs) self.id = None self.name = None self.type = None self.location = None self.enforcement_mode = enforcement_mode + self.protection_mode = protection_mode self.configuration_status = configuration_status self.recommendation_status = recommendation_status self.issues = issues @@ -738,8 +742,14 @@ def __init__(self, *, issue=None, number_of_vms: float=None, **kwargs) -> None: class AppWhitelistingPutGroupData(Model): """The altered data of the recommended VM/server group policy. - :param enforcement_mode: Possible values include: 'Audit', 'Enforce' + :param enforcement_mode: The enforcement mode of the group. Can also be + defined per collection type by using ProtectionMode. Possible values + include: 'Audit', 'Enforce' :type enforcement_mode: str or ~azure.mgmt.security.models.enum + :param protection_mode: The protection mode of the group per collection + type. Can also be defined for all collection types by using + EnforcementMode + :type protection_mode: ~azure.mgmt.security.models.ProtectionMode :param vm_recommendations: :type vm_recommendations: list[~azure.mgmt.security.models.VmRecommendation] @@ -750,13 +760,15 @@ class AppWhitelistingPutGroupData(Model): _attribute_map = { 'enforcement_mode': {'key': 'enforcementMode', 'type': 'str'}, + 'protection_mode': {'key': 'protectionMode', 'type': 'ProtectionMode'}, 'vm_recommendations': {'key': 'vmRecommendations', 'type': '[VmRecommendation]'}, 'path_recommendations': {'key': 'pathRecommendations', 'type': '[PathRecommendation]'}, } - def __init__(self, *, enforcement_mode=None, vm_recommendations=None, path_recommendations=None, **kwargs) -> None: + def __init__(self, *, enforcement_mode=None, protection_mode=None, vm_recommendations=None, path_recommendations=None, **kwargs) -> None: super(AppWhitelistingPutGroupData, self).__init__(**kwargs) self.enforcement_mode = enforcement_mode + self.protection_mode = protection_mode self.vm_recommendations = vm_recommendations self.path_recommendations = path_recommendations @@ -2776,6 +2788,35 @@ def __init__(self, *, value, **kwargs) -> None: self.value = value +class ProtectionMode(Model): + """The protection mode of the collection/file types. Exe/Msi/Script are used + for Windows, Executable is used for Linux. + + :param exe: Possible values include: 'Audit', 'Enforce' + :type exe: str or ~azure.mgmt.security.models.enum + :param msi: Possible values include: 'Audit', 'Enforce' + :type msi: str or ~azure.mgmt.security.models.enum + :param script: Possible values include: 'Audit', 'Enforce' + :type script: str or ~azure.mgmt.security.models.enum + :param executable: Possible values include: 'Audit', 'Enforce' + :type executable: str or ~azure.mgmt.security.models.enum + """ + + _attribute_map = { + 'exe': {'key': 'Exe', 'type': 'str'}, + 'msi': {'key': 'Msi', 'type': 'str'}, + 'script': {'key': 'Script', 'type': 'str'}, + 'executable': {'key': 'Executable', 'type': 'str'}, + } + + def __init__(self, *, exe=None, msi=None, script=None, executable=None, **kwargs) -> None: + super(ProtectionMode, self).__init__(**kwargs) + self.exe = exe + self.msi = msi + self.script = script + self.executable = executable + + class PublisherInfo(Model): """Represents the publisher information of a process/rule. From 1b0510bbc4260236a558b97ae6c79526c6d47aee Mon Sep 17 00:00:00 2001 From: Azure SDK Bot Date: Fri, 20 Sep 2019 06:13:11 +0000 Subject: [PATCH 2/3] Generated from a89fd1dbe6506be202e9272e4720506457ee577c add None to enforcement mode --- .../azure/mgmt/security/models/_models.py | 13 +++++++------ .../azure/mgmt/security/models/_models_py3.py | 13 +++++++------ 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py index 4e9679482f26..d996bfd64890 100644 --- a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py +++ b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py @@ -636,7 +636,8 @@ class AppWhitelistingGroup(Model): :vartype type: str :ivar location: Location where the resource is stored :vartype location: str - :param enforcement_mode: Possible values include: 'Audit', 'Enforce' + :param enforcement_mode: Possible values include: 'Audit', 'Enforce', + 'None' :type enforcement_mode: str or ~azure.mgmt.security.models.enum :param protection_mode: :type protection_mode: ~azure.mgmt.security.models.ProtectionMode @@ -744,7 +745,7 @@ class AppWhitelistingPutGroupData(Model): :param enforcement_mode: The enforcement mode of the group. Can also be defined per collection type by using ProtectionMode. Possible values - include: 'Audit', 'Enforce' + include: 'Audit', 'Enforce', 'None' :type enforcement_mode: str or ~azure.mgmt.security.models.enum :param protection_mode: The protection mode of the group per collection type. Can also be defined for all collection types by using @@ -2792,13 +2793,13 @@ class ProtectionMode(Model): """The protection mode of the collection/file types. Exe/Msi/Script are used for Windows, Executable is used for Linux. - :param exe: Possible values include: 'Audit', 'Enforce' + :param exe: Possible values include: 'Audit', 'Enforce', 'None' :type exe: str or ~azure.mgmt.security.models.enum - :param msi: Possible values include: 'Audit', 'Enforce' + :param msi: Possible values include: 'Audit', 'Enforce', 'None' :type msi: str or ~azure.mgmt.security.models.enum - :param script: Possible values include: 'Audit', 'Enforce' + :param script: Possible values include: 'Audit', 'Enforce', 'None' :type script: str or ~azure.mgmt.security.models.enum - :param executable: Possible values include: 'Audit', 'Enforce' + :param executable: Possible values include: 'Audit', 'Enforce', 'None' :type executable: str or ~azure.mgmt.security.models.enum """ diff --git a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py index fa66e9726bb0..71f9c6d68e43 100644 --- a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py +++ b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py @@ -636,7 +636,8 @@ class AppWhitelistingGroup(Model): :vartype type: str :ivar location: Location where the resource is stored :vartype location: str - :param enforcement_mode: Possible values include: 'Audit', 'Enforce' + :param enforcement_mode: Possible values include: 'Audit', 'Enforce', + 'None' :type enforcement_mode: str or ~azure.mgmt.security.models.enum :param protection_mode: :type protection_mode: ~azure.mgmt.security.models.ProtectionMode @@ -744,7 +745,7 @@ class AppWhitelistingPutGroupData(Model): :param enforcement_mode: The enforcement mode of the group. Can also be defined per collection type by using ProtectionMode. Possible values - include: 'Audit', 'Enforce' + include: 'Audit', 'Enforce', 'None' :type enforcement_mode: str or ~azure.mgmt.security.models.enum :param protection_mode: The protection mode of the group per collection type. Can also be defined for all collection types by using @@ -2792,13 +2793,13 @@ class ProtectionMode(Model): """The protection mode of the collection/file types. Exe/Msi/Script are used for Windows, Executable is used for Linux. - :param exe: Possible values include: 'Audit', 'Enforce' + :param exe: Possible values include: 'Audit', 'Enforce', 'None' :type exe: str or ~azure.mgmt.security.models.enum - :param msi: Possible values include: 'Audit', 'Enforce' + :param msi: Possible values include: 'Audit', 'Enforce', 'None' :type msi: str or ~azure.mgmt.security.models.enum - :param script: Possible values include: 'Audit', 'Enforce' + :param script: Possible values include: 'Audit', 'Enforce', 'None' :type script: str or ~azure.mgmt.security.models.enum - :param executable: Possible values include: 'Audit', 'Enforce' + :param executable: Possible values include: 'Audit', 'Enforce', 'None' :type executable: str or ~azure.mgmt.security.models.enum """ From 401b2a17bb994e9524c0919bceb70325ea987fef Mon Sep 17 00:00:00 2001 From: Azure SDK Bot Date: Sun, 22 Sep 2019 06:51:30 +0000 Subject: [PATCH 3/3] Generated from 16c7d5f2a872e3b7cc01c7dd8af608a586776fe9 lowercase the collection types --- .../azure/mgmt/security/models/_models.py | 8 ++++---- .../azure/mgmt/security/models/_models_py3.py | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py index d996bfd64890..a6a826094c6f 100644 --- a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py +++ b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models.py @@ -2804,10 +2804,10 @@ class ProtectionMode(Model): """ _attribute_map = { - 'exe': {'key': 'Exe', 'type': 'str'}, - 'msi': {'key': 'Msi', 'type': 'str'}, - 'script': {'key': 'Script', 'type': 'str'}, - 'executable': {'key': 'Executable', 'type': 'str'}, + 'exe': {'key': 'exe', 'type': 'str'}, + 'msi': {'key': 'msi', 'type': 'str'}, + 'script': {'key': 'script', 'type': 'str'}, + 'executable': {'key': 'executable', 'type': 'str'}, } def __init__(self, **kwargs): diff --git a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py index 71f9c6d68e43..0fceeef55f0e 100644 --- a/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py +++ b/sdk/security/azure-mgmt-security/azure/mgmt/security/models/_models_py3.py @@ -2804,10 +2804,10 @@ class ProtectionMode(Model): """ _attribute_map = { - 'exe': {'key': 'Exe', 'type': 'str'}, - 'msi': {'key': 'Msi', 'type': 'str'}, - 'script': {'key': 'Script', 'type': 'str'}, - 'executable': {'key': 'Executable', 'type': 'str'}, + 'exe': {'key': 'exe', 'type': 'str'}, + 'msi': {'key': 'msi', 'type': 'str'}, + 'script': {'key': 'script', 'type': 'str'}, + 'executable': {'key': 'executable', 'type': 'str'}, } def __init__(self, *, exe=None, msi=None, script=None, executable=None, **kwargs) -> None: