Skip to content

Commit

Permalink
Merge pull request Azure#828 from Azure/keyvault_data
Browse files Browse the repository at this point in the history
KeyVault Data Plane
  • Loading branch information
lmazuel authored Dec 29, 2016
2 parents a96ed6e + 001cd36 commit d62963c
Show file tree
Hide file tree
Showing 107 changed files with 5,421 additions and 140 deletions.
1 change: 1 addition & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ and will NOT be installed with the 2.0.0rc6 "azure" meta-package. We removed the
to prepare our customers to the 2.0.0 stable release that will only contains the stable packages
listed before.

- azure-keyvault 0.1.0
- azure-graphrbac 0.30.0rc6
- azure-monitor 0.1.0
- azure-mgmt-authorization 0.30.0rc6
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
19 changes: 19 additions & 0 deletions azure-keyvault/azure/keyvault/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#---------------------------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
#---------------------------------------------------------------------------------------------

from azure.keyvault import http_bearer_challenge_cache as HttpBearerChallengeCache
from .http_bearer_challenge import HttpBearerChallenge
from .key_vault_client import KeyVaultClient
from .key_vault_authentication import KeyVaultAuthentication
from azure.keyvault.generated.version import VERSION

__all__ = [
'HttpBearerChallengeCache',
'HttpBearerChallenge',
'KeyVaultClient',
'KeyVaultAuthentication'
]

__version__ = VERSION

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class Action(Model):
:param action_type: The type of the action. Possible values include:
'EmailContacts', 'AutoRenew'
:type action_type: str or :class:`ActionType
<azure.keyvault.models.ActionType>`
<azure.keyvault.generated.models.ActionType>`
"""

_attribute_map = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@ class CertificateBundle(Model):
:vartype x509_thumbprint: bytes
:ivar policy: The management policy.
:vartype policy: :class:`CertificatePolicy
<azure.keyvault.models.CertificatePolicy>`
<azure.keyvault.generated.models.CertificatePolicy>`
:param cer: CER contents of x509 certificate.
:type cer: bytearray
:param content_type: The content type of the secret
:type content_type: str
:param attributes: The certificate attributes.
:type attributes: :class:`CertificateAttributes
<azure.keyvault.models.CertificateAttributes>`
<azure.keyvault.generated.models.CertificateAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ class CertificateCreateParameters(Model):
:param certificate_policy: The management policy for the certificate
:type certificate_policy: :class:`CertificatePolicy
<azure.keyvault.models.CertificatePolicy>`
<azure.keyvault.generated.models.CertificatePolicy>`
:param certificate_attributes: The attributes of the certificate
(optional)
:type certificate_attributes: :class:`CertificateAttributes
<azure.keyvault.models.CertificateAttributes>`
<azure.keyvault.generated.models.CertificateAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@ class CertificateImportParameters(Model):
:type password: str
:param certificate_policy: The management policy for the certificate
:type certificate_policy: :class:`CertificatePolicy
<azure.keyvault.models.CertificatePolicy>`
<azure.keyvault.generated.models.CertificatePolicy>`
:param certificate_attributes: The attributes of the certificate
(optional)
:type certificate_attributes: :class:`CertificateAttributes
<azure.keyvault.models.CertificateAttributes>`
<azure.keyvault.generated.models.CertificateAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ class CertificateIssuerSetParameters(Model):
:type provider: str
:param credentials: The credentials to be used for the issuer.
:type credentials: :class:`IssuerCredentials
<azure.keyvault.models.IssuerCredentials>`
<azure.keyvault.generated.models.IssuerCredentials>`
:param organization_details: Details of the organization as provided to
the issuer.
:type organization_details: :class:`OrganizationDetails
<azure.keyvault.models.OrganizationDetails>`
<azure.keyvault.generated.models.OrganizationDetails>`
:param attributes: Attributes of the issuer object.
:type attributes: :class:`IssuerAttributes
<azure.keyvault.models.IssuerAttributes>`
<azure.keyvault.generated.models.IssuerAttributes>`
"""

_validation = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ class CertificateIssuerUpdateParameters(Model):
:type provider: str
:param credentials: The credentials to be used for the issuer.
:type credentials: :class:`IssuerCredentials
<azure.keyvault.models.IssuerCredentials>`
<azure.keyvault.generated.models.IssuerCredentials>`
:param organization_details: Details of the organization as provided to
the issuer.
:type organization_details: :class:`OrganizationDetails
<azure.keyvault.models.OrganizationDetails>`
<azure.keyvault.generated.models.OrganizationDetails>`
:param attributes: Attributes of the issuer object.
:type attributes: :class:`IssuerAttributes
<azure.keyvault.models.IssuerAttributes>`
<azure.keyvault.generated.models.IssuerAttributes>`
"""

_attribute_map = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class CertificateItem(Model):
:type id: str
:param attributes: The certificate management attributes
:type attributes: :class:`CertificateAttributes
<azure.keyvault.models.CertificateAttributes>`
<azure.keyvault.generated.models.CertificateAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
:param x509_thumbprint: Thumbprint of the certificate.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class CertificateMergeParameters(Model):
:param certificate_attributes: The attributes of the certificate
(optional)
:type certificate_attributes: :class:`CertificateAttributes
<azure.keyvault.models.CertificateAttributes>`
<azure.keyvault.generated.models.CertificateAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class CertificateOperation(Model):
:param issuer_parameters: Parameters for the issuer of the X509 component
of a certificate.
:type issuer_parameters: :class:`IssuerParameters
<azure.keyvault.models.IssuerParameters>`
<azure.keyvault.generated.models.IssuerParameters>`
:param csr: The Certificate Signing Request (CSR) that is being used in
the certificate operation.
:type csr: bytearray
Expand All @@ -35,7 +35,7 @@ class CertificateOperation(Model):
:param status_details: The status details of the certificate operation.
:type status_details: str
:param error: Error encountered, if any, during the certificate operation.
:type error: :class:`Error <azure.keyvault.models.Error>`
:type error: :class:`Error <azure.keyvault.generated.models.Error>`
:param target: Location which contains the result of the certificate
operation.
:type target: str
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,25 +22,25 @@ class CertificatePolicy(Model):
:vartype id: str
:param key_properties: Properties of the key backing a certificate.
:type key_properties: :class:`KeyProperties
<azure.keyvault.models.KeyProperties>`
<azure.keyvault.generated.models.KeyProperties>`
:param secret_properties: Properties of the secret backing a certificate.
:type secret_properties: :class:`SecretProperties
<azure.keyvault.models.SecretProperties>`
<azure.keyvault.generated.models.SecretProperties>`
:param x509_certificate_properties: Properties of the X509 component of a
certificate.
:type x509_certificate_properties: :class:`X509CertificateProperties
<azure.keyvault.models.X509CertificateProperties>`
<azure.keyvault.generated.models.X509CertificateProperties>`
:param lifetime_actions: Actions that will be performed by Key Vault over
the lifetime of a certificate.
:type lifetime_actions: list of :class:`LifetimeAction
<azure.keyvault.models.LifetimeAction>`
<azure.keyvault.generated.models.LifetimeAction>`
:param issuer_parameters: Parameters for the issuer of the X509 component
of a certificate.
:type issuer_parameters: :class:`IssuerParameters
<azure.keyvault.models.IssuerParameters>`
<azure.keyvault.generated.models.IssuerParameters>`
:param attributes: The certificate attributes.
:type attributes: :class:`CertificateAttributes
<azure.keyvault.models.CertificateAttributes>`
<azure.keyvault.generated.models.CertificateAttributes>`
"""

_validation = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ class CertificateUpdateParameters(Model):
:param certificate_policy: The management policy for the certificate
:type certificate_policy: :class:`CertificatePolicy
<azure.keyvault.models.CertificatePolicy>`
<azure.keyvault.generated.models.CertificatePolicy>`
:param certificate_attributes: The attributes of the certificate
(optional)
:type certificate_attributes: :class:`CertificateAttributes
<azure.keyvault.models.CertificateAttributes>`
<azure.keyvault.generated.models.CertificateAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class Contacts(Model):
:vartype id: str
:param contact_list: The contact list for the vault certificates.
:type contact_list: list of :class:`Contact
<azure.keyvault.models.Contact>`
<azure.keyvault.generated.models.Contact>`
"""

_validation = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,24 @@ class Error(Model):
:vartype code: str
:ivar message: The error message.
:vartype message: str
:ivar inner_error:
:vartype inner_error: :class:`Error
<azure.keyvault.generated.models.Error>`
"""

_validation = {
'code': {'readonly': True},
'message': {'readonly': True},
'inner_error': {'readonly': True},
}

_attribute_map = {
'code': {'key': 'code', 'type': 'str'},
'message': {'key': 'message', 'type': 'str'},
'inner_error': {'key': 'innererror', 'type': 'Error'},
}

def __init__(self):
self.code = None
self.message = None
self.inner_error = None
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ class IssuerBundle(Model):
:type provider: str
:param credentials: The credentials to be used for the issuer.
:type credentials: :class:`IssuerCredentials
<azure.keyvault.models.IssuerCredentials>`
<azure.keyvault.generated.models.IssuerCredentials>`
:param organization_details: Details of the organization as provided to
the issuer.
:type organization_details: :class:`OrganizationDetails
<azure.keyvault.models.OrganizationDetails>`
<azure.keyvault.generated.models.OrganizationDetails>`
:param attributes: Attributes of the issuer object.
:type attributes: :class:`IssuerAttributes
<azure.keyvault.models.IssuerAttributes>`
<azure.keyvault.generated.models.IssuerAttributes>`
"""

_validation = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class JsonWebKey(Model):
HSM, Octet, usually RSA. Possible values include: 'EC', 'RSA',
'RSA-HSM', 'oct'
:type kty: str or :class:`JsonWebKeyType
<azure.keyvault.models.JsonWebKeyType>`
<azure.keyvault.generated.models.JsonWebKeyType>`
:param key_ops:
:type key_ops: list of str
:param n: RSA modulus
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,11 @@ class KeyBundle(Model):
sending a request.
:param key: The Json web key
:type key: :class:`JsonWebKey <azure.keyvault.models.JsonWebKey>`
:type key: :class:`JsonWebKey
<azure.keyvault.generated.models.JsonWebKey>`
:param attributes: The key management attributes
:type attributes: :class:`KeyAttributes
<azure.keyvault.models.KeyAttributes>`
<azure.keyvault.generated.models.KeyAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
:ivar managed: True if the key's lifetime is managed by key vault i.e. if
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@ class KeyCreateParameters(Model):
JsonWebKeyType. Supported JsonWebKey key types (kty) for Elliptic Curve,
RSA, HSM, Octet. Possible values include: 'EC', 'RSA', 'RSA-HSM', 'oct'
:type kty: str or :class:`JsonWebKeyType
<azure.keyvault.models.JsonWebKeyType>`
<azure.keyvault.generated.models.JsonWebKeyType>`
:param key_size: The key size in bytes. e.g. 1024 or 2048.
:type key_size: int
:param key_ops:
:type key_ops: list of str or :class:`JsonWebKeyOperation
<azure.keyvault.models.JsonWebKeyOperation>`
<azure.keyvault.generated.models.JsonWebKeyOperation>`
:param key_attributes:
:type key_attributes: :class:`KeyAttributes
<azure.keyvault.models.KeyAttributes>`
<azure.keyvault.generated.models.KeyAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,11 @@ class KeyImportParameters(Model):
:param hsm: Whether to import as a hardware key (HSM) or software key
:type hsm: bool
:param key: The Json web key
:type key: :class:`JsonWebKey <azure.keyvault.models.JsonWebKey>`
:type key: :class:`JsonWebKey
<azure.keyvault.generated.models.JsonWebKey>`
:param key_attributes: The key management attributes
:type key_attributes: :class:`KeyAttributes
<azure.keyvault.models.KeyAttributes>`
<azure.keyvault.generated.models.KeyAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class KeyItem(Model):
:type kid: str
:param attributes: The key management attributes
:type attributes: :class:`KeyAttributes
<azure.keyvault.models.KeyAttributes>`
<azure.keyvault.generated.models.KeyAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
:ivar managed: True if the key's lifetime is managed by key vault i.e. if
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class KeyOperationsParameters(Model):
:param algorithm: algorithm identifier. Possible values include:
'RSA-OAEP', 'RSA1_5'
:type algorithm: str or :class:`JsonWebKeyEncryptionAlgorithm
<azure.keyvault.models.JsonWebKeyEncryptionAlgorithm>`
<azure.keyvault.generated.models.JsonWebKeyEncryptionAlgorithm>`
:param value:
:type value: bytes
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class KeySignParameters(Model):
JsonWebKeySignatureAlgorithm. Possible values include: 'RS256', 'RS384',
'RS512', 'RSNULL'
:type algorithm: str or :class:`JsonWebKeySignatureAlgorithm
<azure.keyvault.models.JsonWebKeySignatureAlgorithm>`
<azure.keyvault.generated.models.JsonWebKeySignatureAlgorithm>`
:param value:
:type value: bytes
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ class KeyUpdateParameters(Model):
:param key_ops: Json web key operations. For more information on possible
key operations, see JsonWebKeyOperation.
:type key_ops: list of str or :class:`JsonWebKeyOperation
<azure.keyvault.models.JsonWebKeyOperation>`
<azure.keyvault.generated.models.JsonWebKeyOperation>`
:param key_attributes:
:type key_attributes: :class:`KeyAttributes
<azure.keyvault.models.KeyAttributes>`
<azure.keyvault.generated.models.KeyAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class KeyVaultError(Model):
sending a request.
:ivar error:
:vartype error: :class:`Error <azure.keyvault.models.Error>`
:vartype error: :class:`Error <azure.keyvault.generated.models.Error>`
"""

_validation = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class KeyVerifyParameters(Model):
JsonWebKeySignatureAlgorithm. Possible values include: 'RS256', 'RS384',
'RS512', 'RSNULL'
:type algorithm: str or :class:`JsonWebKeySignatureAlgorithm
<azure.keyvault.models.JsonWebKeySignatureAlgorithm>`
<azure.keyvault.generated.models.JsonWebKeySignatureAlgorithm>`
:param digest: The digest used for signing
:type digest: bytes
:param signature: The signature to be verified
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ class LifetimeAction(Model):
lifetime of a certificate.
:param trigger: The condition that will execute the action.
:type trigger: :class:`Trigger <azure.keyvault.models.Trigger>`
:type trigger: :class:`Trigger <azure.keyvault.generated.models.Trigger>`
:param action: The action that will be executed.
:type action: :class:`Action <azure.keyvault.models.Action>`
:type action: :class:`Action <azure.keyvault.generated.models.Action>`
"""

_attribute_map = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class OrganizationDetails(Model):
:type id: str
:param admin_details: Details of the organization administrator.
:type admin_details: list of :class:`AdministratorDetails
<azure.keyvault.models.AdministratorDetails>`
<azure.keyvault.generated.models.AdministratorDetails>`
"""

_attribute_map = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class SecretBundle(Model):
:type content_type: str
:param attributes: The secret management attributes
:type attributes: :class:`SecretAttributes
<azure.keyvault.models.SecretAttributes>`
<azure.keyvault.generated.models.SecretAttributes>`
:param tags: Application-specific metadata in the form of key-value pairs
:type tags: dict
:ivar kid: If this is a secret backing a KV certificate, then this field
Expand Down
Loading

0 comments on commit d62963c

Please sign in to comment.