From ee7d4a29dc66a21e1bde25e63baf820bc190f656 Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Tue, 27 Nov 2018 10:48:40 -0800 Subject: [PATCH 1/2] [AutoPR graphrbac/data-plane] add customKeyIdentifier to password credential (#3833) * Generated from 2d1a131d6bc24477750e780c70ad4384e6e5927d add customKeyIdentifier to password credential * Generated from 1c42b12d70502f95d2f42f1d421ce53f425e7ef6 add creds in app object * Generated from 74a0ba38241f5574f515beb159638e286b44bd6f custom id(thumbprint) for cert creds should be string type --- azure-graphrbac/azure/graphrbac/models/application.py | 9 +++++++++ .../azure/graphrbac/models/application_py3.py | 11 ++++++++++- .../azure/graphrbac/models/key_credential.py | 4 ++-- .../azure/graphrbac/models/key_credential_py3.py | 6 +++--- .../azure/graphrbac/models/password_credential.py | 4 ++++ .../azure/graphrbac/models/password_credential_py3.py | 6 +++++- 6 files changed, 33 insertions(+), 7 deletions(-) diff --git a/azure-graphrbac/azure/graphrbac/models/application.py b/azure-graphrbac/azure/graphrbac/models/application.py index 694eaa66deac..ab8a5cabaa01 100644 --- a/azure-graphrbac/azure/graphrbac/models/application.py +++ b/azure-graphrbac/azure/graphrbac/models/application.py @@ -58,6 +58,11 @@ class Application(DirectoryObject): of required resource access drives the consent experience. :type required_resource_access: list[~azure.graphrbac.models.RequiredResourceAccess] + :param key_credentials: A collection of KeyCredential objects. + :type key_credentials: list[~azure.graphrbac.models.KeyCredential] + :param password_credentials: A collection of PasswordCredential objects + :type password_credentials: + list[~azure.graphrbac.models.PasswordCredential] """ _validation = { @@ -81,6 +86,8 @@ class Application(DirectoryObject): 'homepage': {'key': 'homepage', 'type': 'str'}, 'oauth2_allow_implicit_flow': {'key': 'oauth2AllowImplicitFlow', 'type': 'bool'}, 'required_resource_access': {'key': 'requiredResourceAccess', 'type': '[RequiredResourceAccess]'}, + 'key_credentials': {'key': 'keyCredentials', 'type': '[KeyCredential]'}, + 'password_credentials': {'key': 'passwordCredentials', 'type': '[PasswordCredential]'}, } def __init__(self, **kwargs): @@ -95,4 +102,6 @@ def __init__(self, **kwargs): self.homepage = kwargs.get('homepage', None) self.oauth2_allow_implicit_flow = kwargs.get('oauth2_allow_implicit_flow', None) self.required_resource_access = kwargs.get('required_resource_access', None) + self.key_credentials = kwargs.get('key_credentials', None) + self.password_credentials = kwargs.get('password_credentials', None) self.object_type = 'Application' diff --git a/azure-graphrbac/azure/graphrbac/models/application_py3.py b/azure-graphrbac/azure/graphrbac/models/application_py3.py index 77fa6aa3c3b5..8b525e1fb6a8 100644 --- a/azure-graphrbac/azure/graphrbac/models/application_py3.py +++ b/azure-graphrbac/azure/graphrbac/models/application_py3.py @@ -58,6 +58,11 @@ class Application(DirectoryObject): of required resource access drives the consent experience. :type required_resource_access: list[~azure.graphrbac.models.RequiredResourceAccess] + :param key_credentials: A collection of KeyCredential objects. + :type key_credentials: list[~azure.graphrbac.models.KeyCredential] + :param password_credentials: A collection of PasswordCredential objects + :type password_credentials: + list[~azure.graphrbac.models.PasswordCredential] """ _validation = { @@ -81,9 +86,11 @@ class Application(DirectoryObject): 'homepage': {'key': 'homepage', 'type': 'str'}, 'oauth2_allow_implicit_flow': {'key': 'oauth2AllowImplicitFlow', 'type': 'bool'}, 'required_resource_access': {'key': 'requiredResourceAccess', 'type': '[RequiredResourceAccess]'}, + 'key_credentials': {'key': 'keyCredentials', 'type': '[KeyCredential]'}, + 'password_credentials': {'key': 'passwordCredentials', 'type': '[PasswordCredential]'}, } - def __init__(self, *, additional_properties=None, app_id: str=None, app_roles=None, app_permissions=None, available_to_other_tenants: bool=None, display_name: str=None, identifier_uris=None, reply_urls=None, homepage: str=None, oauth2_allow_implicit_flow: bool=None, required_resource_access=None, **kwargs) -> None: + def __init__(self, *, additional_properties=None, app_id: str=None, app_roles=None, app_permissions=None, available_to_other_tenants: bool=None, display_name: str=None, identifier_uris=None, reply_urls=None, homepage: str=None, oauth2_allow_implicit_flow: bool=None, required_resource_access=None, key_credentials=None, password_credentials=None, **kwargs) -> None: super(Application, self).__init__(additional_properties=additional_properties, **kwargs) self.app_id = app_id self.app_roles = app_roles @@ -95,4 +102,6 @@ def __init__(self, *, additional_properties=None, app_id: str=None, app_roles=No self.homepage = homepage self.oauth2_allow_implicit_flow = oauth2_allow_implicit_flow self.required_resource_access = required_resource_access + self.key_credentials = key_credentials + self.password_credentials = password_credentials self.object_type = 'Application' diff --git a/azure-graphrbac/azure/graphrbac/models/key_credential.py b/azure-graphrbac/azure/graphrbac/models/key_credential.py index ed56f7672311..c777e448af65 100644 --- a/azure-graphrbac/azure/graphrbac/models/key_credential.py +++ b/azure-graphrbac/azure/graphrbac/models/key_credential.py @@ -32,7 +32,7 @@ class KeyCredential(Model): 'Symmetric'. :type type: str :param custom_key_identifier: Custom Key Identifier - :type custom_key_identifier: bytearray + :type custom_key_identifier: str """ _attribute_map = { @@ -43,7 +43,7 @@ class KeyCredential(Model): 'key_id': {'key': 'keyId', 'type': 'str'}, 'usage': {'key': 'usage', 'type': 'str'}, 'type': {'key': 'type', 'type': 'str'}, - 'custom_key_identifier': {'key': 'customKeyIdentifier', 'type': 'bytearray'}, + 'custom_key_identifier': {'key': 'customKeyIdentifier', 'type': 'str'}, } def __init__(self, **kwargs): diff --git a/azure-graphrbac/azure/graphrbac/models/key_credential_py3.py b/azure-graphrbac/azure/graphrbac/models/key_credential_py3.py index b6550d8d11de..c9fbf1b8f00b 100644 --- a/azure-graphrbac/azure/graphrbac/models/key_credential_py3.py +++ b/azure-graphrbac/azure/graphrbac/models/key_credential_py3.py @@ -32,7 +32,7 @@ class KeyCredential(Model): 'Symmetric'. :type type: str :param custom_key_identifier: Custom Key Identifier - :type custom_key_identifier: bytearray + :type custom_key_identifier: str """ _attribute_map = { @@ -43,10 +43,10 @@ class KeyCredential(Model): 'key_id': {'key': 'keyId', 'type': 'str'}, 'usage': {'key': 'usage', 'type': 'str'}, 'type': {'key': 'type', 'type': 'str'}, - 'custom_key_identifier': {'key': 'customKeyIdentifier', 'type': 'bytearray'}, + 'custom_key_identifier': {'key': 'customKeyIdentifier', 'type': 'str'}, } - def __init__(self, *, additional_properties=None, start_date=None, end_date=None, value: str=None, key_id: str=None, usage: str=None, type: str=None, custom_key_identifier: bytearray=None, **kwargs) -> None: + def __init__(self, *, additional_properties=None, start_date=None, end_date=None, value: str=None, key_id: str=None, usage: str=None, type: str=None, custom_key_identifier: str=None, **kwargs) -> None: super(KeyCredential, self).__init__(**kwargs) self.additional_properties = additional_properties self.start_date = start_date diff --git a/azure-graphrbac/azure/graphrbac/models/password_credential.py b/azure-graphrbac/azure/graphrbac/models/password_credential.py index 28d9e2709458..44b07ce43a4b 100644 --- a/azure-graphrbac/azure/graphrbac/models/password_credential.py +++ b/azure-graphrbac/azure/graphrbac/models/password_credential.py @@ -26,6 +26,8 @@ class PasswordCredential(Model): :type key_id: str :param value: Key value. :type value: str + :param custom_key_identifier: Custom Key Identifier + :type custom_key_identifier: bytearray """ _attribute_map = { @@ -34,6 +36,7 @@ class PasswordCredential(Model): 'end_date': {'key': 'endDate', 'type': 'iso-8601'}, 'key_id': {'key': 'keyId', 'type': 'str'}, 'value': {'key': 'value', 'type': 'str'}, + 'custom_key_identifier': {'key': 'customKeyIdentifier', 'type': 'bytearray'}, } def __init__(self, **kwargs): @@ -43,3 +46,4 @@ def __init__(self, **kwargs): self.end_date = kwargs.get('end_date', None) self.key_id = kwargs.get('key_id', None) self.value = kwargs.get('value', None) + self.custom_key_identifier = kwargs.get('custom_key_identifier', None) diff --git a/azure-graphrbac/azure/graphrbac/models/password_credential_py3.py b/azure-graphrbac/azure/graphrbac/models/password_credential_py3.py index 102f23659286..480bed0b6032 100644 --- a/azure-graphrbac/azure/graphrbac/models/password_credential_py3.py +++ b/azure-graphrbac/azure/graphrbac/models/password_credential_py3.py @@ -26,6 +26,8 @@ class PasswordCredential(Model): :type key_id: str :param value: Key value. :type value: str + :param custom_key_identifier: Custom Key Identifier + :type custom_key_identifier: bytearray """ _attribute_map = { @@ -34,12 +36,14 @@ class PasswordCredential(Model): 'end_date': {'key': 'endDate', 'type': 'iso-8601'}, 'key_id': {'key': 'keyId', 'type': 'str'}, 'value': {'key': 'value', 'type': 'str'}, + 'custom_key_identifier': {'key': 'customKeyIdentifier', 'type': 'bytearray'}, } - def __init__(self, *, additional_properties=None, start_date=None, end_date=None, key_id: str=None, value: str=None, **kwargs) -> None: + def __init__(self, *, additional_properties=None, start_date=None, end_date=None, key_id: str=None, value: str=None, custom_key_identifier: bytearray=None, **kwargs) -> None: super(PasswordCredential, self).__init__(**kwargs) self.additional_properties = additional_properties self.start_date = start_date self.end_date = end_date self.key_id = key_id self.value = value + self.custom_key_identifier = custom_key_identifier From 23c60cb6aeb209279870241d03ac4575498f2740 Mon Sep 17 00:00:00 2001 From: Laurent Mazuel Date: Tue, 27 Nov 2018 11:12:52 -0800 Subject: [PATCH 2/2] 0.53.0 --- azure-graphrbac/HISTORY.rst | 13 +++++++++++++ azure-graphrbac/azure/graphrbac/version.py | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/azure-graphrbac/HISTORY.rst b/azure-graphrbac/HISTORY.rst index e908df92d90d..9376566ce063 100644 --- a/azure-graphrbac/HISTORY.rst +++ b/azure-graphrbac/HISTORY.rst @@ -3,6 +3,19 @@ Release History =============== +0.53.0 (2018-11-27) ++++++++++++++++++++ + +**Features** + +- Add PasswordCredentials.custom_key_identifier +- Add Application.key_credentials +- Add Application.password_credentials + +**Bugfix** + +- Fix KeyCredential.custom_key_identifier type from bytes to str + 0.52.0 (2018-10-29) +++++++++++++++++++ diff --git a/azure-graphrbac/azure/graphrbac/version.py b/azure-graphrbac/azure/graphrbac/version.py index 2a91c7e542b6..ec15ad4e864a 100644 --- a/azure-graphrbac/azure/graphrbac/version.py +++ b/azure-graphrbac/azure/graphrbac/version.py @@ -9,5 +9,5 @@ # regenerated. # -------------------------------------------------------------------------- -VERSION = "0.52.0" +VERSION = "0.53.0"