diff --git a/README.md b/README.md index 729c5d70bc3ca..3a89fec4d97eb 100644 --- a/README.md +++ b/README.md @@ -24,17 +24,17 @@ Each service might have a number of libraries available from each of the followi * [Management](#Management) ### Client: July 2019 Preview -New wave of packages that we are currently releasing in **preview**. These libraries follow the [Azure SDK Design Guidelines for Java](https://azuresdkspecs.z5.web.core.windows.net/JavaSpec.html) and share a number of core features such as HTTP retries, logging, transport protocols, authentication protocols, etc., so that once you learn how to use these features in one client library, you will know how to use them in other client libraries. You can learn about these shared features [here](core). +New wave of packages that we are currently releasing in **preview**. These libraries follow the [Azure SDK Design Guidelines for Java](https://azuresdkspecs.z5.web.core.windows.net/JavaSpec.html) and share a number of core features such as HTTP retries, logging, transport protocols, authentication protocols, etc., so that once you learn how to use these features in one client library, you will know how to use them in other client libraries. You can learn about these shared features [here](core). These preview libraries can be easily identified by their folder, package, and namespaces names starting with `azure-`, e.g. `azure-keyvault`. The libraries released in the July 2019 preview: - [App Configuration](sdk/appconfiguration/azure-data-appconfiguration/README.md) -- [Event Hubs](sdk/eventhubs/azure-eventhubs/README.md) +- [Event Hubs](sdk/eventhubs/azure-messaging-eventhubs/README.md) - [Identity](sdk/identity/azure-identity/README.md) - [Key Vault Keys](sdk/keyvault/azure-keyvault-keys/README.md) - [Key Vault Secrets](sdk/keyvault/client/azure-keyvault-secrets/README.md) -- [Storage Blobs](storage/client/README.md) +- [Storage Blobs](sdk/storage/azure-storage-blob/README.md) >NOTE: If you need to ensure your code is ready for production, use one of the stable libraries. diff --git a/sdk/identity/azure-identity/README.md b/sdk/identity/azure-identity/README.md index 69a073df5bf1c..ee4d6ec676694 100644 --- a/sdk/identity/azure-identity/README.md +++ b/sdk/identity/azure-identity/README.md @@ -1,11 +1,11 @@ # Azure Identity client library for Java -The Azure Identity library provides Azure Active Directory token authentication support across the Azure SDK. It provides a set of TokenCredential implementations which can be used to construct Azure SDK clients which support AAD token authentication. - +The Azure Identity library provides Azure Active Directory token authentication support across the Azure SDK. It provides a set of TokenCredential implementations which can be used to construct Azure SDK clients which support AAD token authentication. + This library is in preview and currently supports: - - [Service principal authentication](https://docs.microsoft.com/en-us/azure/active-directory/develop/app-objects-and-service-principals) - - [Managed identity authentication](https://docs.microsoft.com/en-us/azure/active-directory/managed-identities-azure-resources/overview) - - [Device code authentication](https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-device-code) - - Interactive browser authentication, based on [OAuth2 authentication code](https://docs.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-auth-code-flow) + - [Service principal authentication](https://docs.microsoft.com/azure/active-directory/develop/app-objects-and-service-principals) + - [Managed identity authentication](https://docs.microsoft.com/azure/active-directory/managed-identities-azure-resources/overview) + - [Device code authentication](https://docs.microsoft.com/azure/active-directory/develop/v2-oauth2-device-code) + - Interactive browser authentication, based on [OAuth2 authentication code](https://docs.microsoft.com/azure/active-directory/develop/v2-oauth2-auth-code-flow) [Source code][source] | API reference documentation (Coming Soon) | [Azure Active Directory documentation][aad_doc] @@ -87,10 +87,10 @@ In this case, the port number is 8765. ## Key concepts ### Credentials -A credential is a class which contains or can obtain the data needed for a service client to authenticate requests. Service clients across Azure SDK accept credentials when they are constructed and use those credentials to authenticate requests to the service.Azure Identity offers a variety of credential classes in the `azure-identity` package capable of acquiring an AAD token. All of these credential classes are implementations of the `TokenCredential` abstract class in [Azure Core][azure_core_library], and can be used by any service client which can be constructed with a `TokenCredential`. +A credential is a class which contains or can obtain the data needed for a service client to authenticate requests. Service clients across Azure SDK accept credentials when they are constructed and use those credentials to authenticate requests to the service.Azure Identity offers a variety of credential classes in the `azure-identity` package capable of acquiring an AAD token. All of these credential classes are implementations of the `TokenCredential` abstract class in [Azure Core][azure_core_library], and can be used by any service client which can be constructed with a `TokenCredential`. -The credential types in Azure Identity differ in the types of AAD identities they can authenticate and how they are configured: +The credential types in Azure Identity differ in the types of AAD identities they can authenticate and how they are configured: |credential class|identity|configuration |-|-|- @@ -106,13 +106,13 @@ The credential types in Azure Identity differ in the types of AAD identities the Credentials can be chained together to be tried in turn until one succeeds using the `ChainedTokenCredential`; see [chaining credentials](#chaining-credentials) for details. ## DefaultAzureCredential -`DefaultAzureCredential` is appropriate for most scenarios where the application is intended to run in the Azure Cloud. This is because the `DefaultAzureCredential` determines the appropriate credential type based of the environment it is executing in. It supports authenticating both as a service principal or managed identity, and can be configured so that it will work both in a local development environment or when deployed to the cloud. +`DefaultAzureCredential` is appropriate for most scenarios where the application is intended to run in the Azure Cloud. This is because the `DefaultAzureCredential` determines the appropriate credential type based of the environment it is executing in. It supports authenticating both as a service principal or managed identity, and can be configured so that it will work both in a local development environment or when deployed to the cloud. The `DefaultAzureCredential` will first attempt to authenticate using credentials provided in the environment. In a development environment you can authenticate as a service principal with the `DefaultAzureCredential` by providing configuration in environment variables as described in the next section. If the environment configuration is not present or incomplete, the `DefaultAzureCredential` will then determine if a managed identity is available in the current environment. Authenticating as a managed identity requires no configuration, but does require platform support. See the -[managed identity documentation](https://docs.microsoft.com/en-us/azure/active-directory/managed-identities-azure-resources/services-support-managed-identities) for more details on this. +[managed identity documentation](https://docs.microsoft.com/azure/active-directory/managed-identities-azure-resources/services-support-managed-identities) for more details on this. ## Environment variables @@ -157,10 +157,10 @@ import com.azure.security.keyvault.keys.KeyClient; // authenticate with client secret, ClientSecretCredential clientSecretCredential = new ClientSecretCredentialBuilder() - .clientId("") - .clientSecret("") - .tenantId("") - .build(); + .clientId("") + .clientSecret("") + .tenantId("") + .build(); KeyClient client = KeyClient.builder() .endpoint("https://{YOUR_VAULT_NAME}.vault.azure.net") @@ -178,11 +178,11 @@ import com.azure.security.keyvault.keys.KeyClient; // authenticate with client secret, DeviceCodeCredential deviceCodeCredential = new DeviceCodeCredentialBuilder() - .deviceCodeChallengeConsumer(challenge -> { - // lets user know of the challenge, e.g., display the message on an IoT device - displayMessage(challenge.message()); - }) - .build(); + .deviceCodeChallengeConsumer(challenge -> { + // lets user know of the challenge, e.g., display the message on an IoT device + displayMessage(challenge.message()); + }) + .build(); KeyClient client = KeyClient.builder() .endpoint("https://{YOUR_VAULT_NAME}.vault.azure.net") @@ -201,18 +201,18 @@ ManagedIdentityCredential managedIdentityCredential = new ManagedIdentityCredent .build(); ClientSecretcredential secondServicePrincipal = new ClientSecretCredentialBuilder() - .clientId("") - .clientSecret("") - .tenantId("") - .build(); + .clientId("") + .clientSecret("") + .tenantId("") + .build(); // when an access token is requested, the chain will try each // credential in order, stopping when one provides a token ChainedTokenCredential credentialChain = new ChainedTokenCredentialBuilder() - .addLast(managedIdentityCredential) - .addLast(secondServicePrincipal) - .build(); + .addLast(managedIdentityCredential) + .addLast(secondServicePrincipal) + .build(); // the chain can be used anywhere a credential is required @@ -246,10 +246,10 @@ This project has adopted the [Microsoft Open Source Code of Conduct][code_of_con [azure_cli]: https://docs.microsoft.com/cli/azure [azure_sub]: https://azure.microsoft.com/free/ -[source]: https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/identity/azure-identity -[aad_doc]: https://docs.microsoft.com/en-us/azure/active-directory/ +[source]: ./ +[aad_doc]: https://docs.microsoft.com/azure/active-directory/ [code_of_conduct]: https://opensource.microsoft.com/codeofconduct/ -[keys_client_library]: https://github.com/Azure/azure-sdk-for-java/tree/master/keyvault/client/keys/ -[secrets_client_library]: https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/client/secrets/ -[eventhubs_client_library]: https://github.com/Azure/azure-sdk-for-java/tree/master/eventhubs/client/ -[azure_core_library]: https://github.com/Azure/azure-sdk-for-java/tree/master/core/ +[keys_client_library]: ../../keyvault/azure-keyvault-keys +[secrets_client_library]: ../../keyvault/azure-keyvault-secrets +[eventhubs_client_library]: ../../eventhubs/azure-messaging-eventhubs +[azure_core_library]: ../../core diff --git a/sdk/keyvault/azure-keyvault-keys/README.md b/sdk/keyvault/azure-keyvault-keys/README.md index 3229a45861999..0b6e03cfd3892 100644 --- a/sdk/keyvault/azure-keyvault-keys/README.md +++ b/sdk/keyvault/azure-keyvault-keys/README.md @@ -420,31 +420,31 @@ When you submit a pull request, a CLA-bot will automatically determine whether y This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments. -[source_code]: https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src +[source_code]: src [api_documentation]: https://azure.github.io/azure-sdk-for-java/track2reports/index.html -[azkeyvault_docs]: https://docs.microsoft.com/en-us/azure/key-vault/ +[azkeyvault_docs]: https://docs.microsoft.com/azure/key-vault/ [azure_identity]: https://github.com/Azure/azure-sdk-for-java/tree/master/identity/client [maven]: https://maven.apache.org/ [azure_subscription]: https://azure.microsoft.com/ -[azure_keyvault]: https://docs.microsoft.com/en-us/azure/key-vault/quick-create-portal +[azure_keyvault]: https://docs.microsoft.com/azure/key-vault/quick-create-portal [azure_cli]: https://docs.microsoft.com/cli/azure -[rest_api]: https://docs.microsoft.com/en-us/rest/api/keyvault/ -[azkeyvault_rest]: https://docs.microsoft.com/en-us/rest/api/keyvault/ -[azure_create_application_in_portal]:https://docs.microsoft.com/en-us/azure/active-directory/develop/howto-create-service-principal-portal -[azure_keyvault_cli]:https://docs.microsoft.com/en-us/azure/key-vault/quick-create-cli -[azure_keyvault_cli_full]:https://docs.microsoft.com/en-us/cli/azure/keyvault?view=azure-cli-latest -[keys_samples]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys -[sample_helloWorld]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/HelloWorld.java -[sample_helloWorldAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/HelloWorldAsync.java -[sample_list]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/ListOperations.java -[sample_listAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/ListOperationsAsync.java -[sample_BackupRestore]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/BackupAndRestoreOperations.java -[sample_BackupRestoreAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/BackupAndRestoreOperationsAsync.java -[sample_ManageDeleted]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/ManagingDeletedKeys.java -[sample_ManageDeletedAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/ManagingDeletedKeysAsync.java -[sample_encryptDecrypt]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/cryptography/EncryptDecryptOperations.java -[sample_encryptDecryptAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/cryptography/EncryptDecryptOperationsAsync.java -[sample_signVerify]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/cryptography/SignVerifyOperations.java -[sample_signVerifyAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/cryptography/SignVerifyOperationsAsync.java -[sample_wrapUnwrap]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/cryptography/KeyWrapUnwrapOperations.java -[sample_wrapUnwrapAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-keys/src/samples/java/com/azure/security/keyvault/keys/cryptography/KeyWrapUnwrapOperationsAsync.java +[rest_api]: https://docs.microsoft.com/rest/api/keyvault/ +[azkeyvault_rest]: https://docs.microsoft.com/rest/api/keyvault/ +[azure_create_application_in_portal]:https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal +[azure_keyvault_cli]:https://docs.microsoft.com/azure/key-vault/quick-create-cli +[azure_keyvault_cli_full]:https://docs.microsoft.com/cli/azure/keyvault?view=azure-cli-latest +[keys_samples]: src/samples/java/com/azure/security/keyvault/keys +[sample_helloWorld]: src/samples/java/com/azure/security/keyvault/keys/HelloWorld.java +[sample_helloWorldAsync]: src/samples/java/com/azure/security/keyvault/keys/HelloWorldAsync.java +[sample_list]: src/samples/java/com/azure/security/keyvault/keys/ListOperations.java +[sample_listAsync]: src/samples/java/com/azure/security/keyvault/keys/ListOperationsAsync.java +[sample_BackupRestore]: src/samples/java/com/azure/security/keyvault/keys/BackupAndRestoreOperations.java +[sample_BackupRestoreAsync]: src/samples/java/com/azure/security/keyvault/keys/BackupAndRestoreOperationsAsync.java +[sample_ManageDeleted]: src/samples/java/com/azure/security/keyvault/keys/ManagingDeletedKeys.java +[sample_ManageDeletedAsync]: src/samples/java/com/azure/security/keyvault/keys/ManagingDeletedKeysAsync.java +[sample_encryptDecrypt]: src/samples/java/com/azure/security/keyvault/keys/cryptography/EncryptDecryptOperations.java +[sample_encryptDecryptAsync]: src/samples/java/com/azure/security/keyvault/keys/cryptography/EncryptDecryptOperationsAsync.java +[sample_signVerify]: src/samples/java/com/azure/security/keyvault/keys/cryptography/SignVerifyOperations.java +[sample_signVerifyAsync]: src/samples/java/com/azure/security/keyvault/keys/cryptography/SignVerifyOperationsAsync.java +[sample_wrapUnwrap]: src/samples/java/com/azure/security/keyvault/keys/cryptography/KeyWrapUnwrapOperations.java +[sample_wrapUnwrapAsync]: src/samples/java/com/azure/security/keyvault/keys/cryptography/KeyWrapUnwrapOperationsAsync.java diff --git a/sdk/keyvault/azure-keyvault-secrets/README.md b/sdk/keyvault/azure-keyvault-secrets/README.md index 06ce29eb171b8..dcbdbe7974bf2 100644 --- a/sdk/keyvault/azure-keyvault-secrets/README.md +++ b/sdk/keyvault/azure-keyvault-secrets/README.md @@ -286,25 +286,25 @@ When you submit a pull request, a CLA-bot will automatically determine whether y This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments. -[source_code]: https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src +[source_code]: src [api_documentation]: https://azure.github.io/azure-sdk-for-java/track2reports/index.html [azure_identity]: https://github.com/Azure/azure-sdk-for-java/tree/master/identity/client -[azkeyvault_docs]: https://docs.microsoft.com/en-us/azure/key-vault/ +[azkeyvault_docs]: https://docs.microsoft.com/azure/key-vault/ [maven]: https://maven.apache.org/ [azure_subscription]: https://azure.microsoft.com/ -[azure_keyvault]: https://docs.microsoft.com/en-us/azure/key-vault/quick-create-portal +[azure_keyvault]: https://docs.microsoft.com/azure/key-vault/quick-create-portal [azure_cli]: https://docs.microsoft.com/cli/azure -[rest_api]: https://docs.microsoft.com/en-us/rest/api/keyvault/ -[azkeyvault_rest]: https://docs.microsoft.com/en-us/rest/api/keyvault/ -[azure_create_application_in_portal]:https://docs.microsoft.com/en-us/azure/active-directory/develop/howto-create-service-principal-portal -[azure_keyvault_cli]:https://docs.microsoft.com/en-us/azure/key-vault/quick-create-cli -[azure_keyvault_cli_full]:https://docs.microsoft.com/en-us/cli/azure/keyvault?view=azure-cli-latest -[secrets_samples]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets -[sample_helloWorld]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets/HelloWorld.java -[sample_helloWorldAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets/HelloWorldAsync.java -[sample_list]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets/ListOperations.java -[sample_listAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets/ListOperationsAsync.java -[sample_BackupRestore]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets/BackupAndRestoreOperations.java -[sample_BackupRestoreAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets/BackupAndRestoreOperationsAsync.java -[sample_ManageDeleted]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets/ManagingDeletedSecrets.java -[sample_ManageDeletedAsync]:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/keyvault/azure-keyvault-secrets/src/samples/java/com/azure/security/keyvault/secrets/ManagingDeletedSecretsAsync.java +[rest_api]: https://docs.microsoft.com/rest/api/keyvault/ +[azkeyvault_rest]: https://docs.microsoft.com/rest/api/keyvault/ +[azure_create_application_in_portal]:https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal +[azure_keyvault_cli]:https://docs.microsoft.com/azure/key-vault/quick-create-cli +[azure_keyvault_cli_full]:https://docs.microsoft.com/cli/azure/keyvault?view=azure-cli-latest +[secrets_samples]: src/samples/java/com/azure/security/keyvault/secrets +[sample_helloWorld]: src/samples/java/com/azure/security/keyvault/secrets/HelloWorld.java +[sample_helloWorldAsync]: src/samples/java/com/azure/security/keyvault/secrets/HelloWorldAsync.java +[sample_list]: src/samples/java/com/azure/security/keyvault/secrets/ListOperations.java +[sample_listAsync]: src/samples/java/com/azure/security/keyvault/secrets/ListOperationsAsync.java +[sample_BackupRestore]: src/samples/java/com/azure/security/keyvault/secrets/BackupAndRestoreOperations.java +[sample_BackupRestoreAsync]: src/samples/java/com/azure/security/keyvault/secrets/BackupAndRestoreOperationsAsync.java +[sample_ManageDeleted]: src/samples/java/com/azure/security/keyvault/secrets/ManagingDeletedSecrets.java +[sample_ManageDeletedAsync]: src/samples/java/com/azure/security/keyvault/secrets/ManagingDeletedSecretsAsync.java