diff --git a/secure-app-model/keyvault/CPVApplication/App.config b/secure-app-model/keyvault/CPVApplication/App.config
index e2fcd7c..4430433 100644
--- a/secure-app-model/keyvault/CPVApplication/App.config
+++ b/secure-app-model/keyvault/CPVApplication/App.config
@@ -13,6 +13,9 @@
+
+
+
@@ -35,13 +38,53 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/secure-app-model/keyvault/CPVApplication/CPVApplication.csproj b/secure-app-model/keyvault/CPVApplication/CPVApplication.csproj
index a03e181..8e2bfe4 100644
--- a/secure-app-model/keyvault/CPVApplication/CPVApplication.csproj
+++ b/secure-app-model/keyvault/CPVApplication/CPVApplication.csproj
@@ -32,17 +32,26 @@
4
-
- ..\packages\Microsoft.Azure.KeyVault.3.0.4\lib\net461\Microsoft.Azure.KeyVault.dll
+
+ ..\packages\Azure.Core.1.24.0\lib\net461\Azure.Core.dll
-
- ..\packages\Microsoft.Azure.KeyVault.WebKey.3.0.4\lib\net461\Microsoft.Azure.KeyVault.WebKey.dll
+
+ ..\packages\Azure.Identity.1.6.0\lib\netstandard2.0\Azure.Identity.dll
-
- ..\packages\Microsoft.Identity.Client.4.31.0\lib\net461\Microsoft.Identity.Client.dll
+
+ ..\packages\Azure.Security.KeyVault.Secrets.4.3.0\lib\netstandard2.0\Azure.Security.KeyVault.Secrets.dll
+
+
+ ..\packages\Microsoft.Bcl.AsyncInterfaces.1.1.1\lib\net461\Microsoft.Bcl.AsyncInterfaces.dll
+
+
+ ..\packages\Microsoft.Identity.Client.4.39.0\lib\net461\Microsoft.Identity.Client.dll
+
+
+ ..\packages\Microsoft.Identity.Client.Extensions.Msal.2.19.3\lib\net45\Microsoft.Identity.Client.Extensions.Msal.dll
- ..\packages\Microsoft.Rest.ClientRuntime.2.3.20\lib\net461\Microsoft.Rest.ClientRuntime.dll
+ ..\packages\Microsoft.Rest.ClientRuntime.2.3.24\lib\net461\Microsoft.Rest.ClientRuntime.dll
..\packages\Microsoft.Rest.ClientRuntime.Azure.3.3.19\lib\net461\Microsoft.Rest.ClientRuntime.Azure.dll
@@ -60,20 +69,44 @@
..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll
+
+ ..\packages\System.Buffers.4.5.1\lib\net461\System.Buffers.dll
+
..\packages\System.ComponentModel.Annotations.4.7.0\lib\net461\System.ComponentModel.Annotations.dll
+
+ ..\packages\System.Diagnostics.DiagnosticSource.4.6.0\lib\net46\System.Diagnostics.DiagnosticSource.dll
+
+
+ ..\packages\System.Memory.4.5.4\lib\net461\System.Memory.dll
+
+
+ ..\packages\System.Memory.Data.1.0.2\lib\net461\System.Memory.Data.dll
+
..\packages\System.Net.Http.4.3.4\lib\net46\System.Net.Http.dll
+
+
+ ..\packages\System.Numerics.Vectors.4.5.0\lib\net46\System.Numerics.Vectors.dll
+
+
+ ..\packages\System.Runtime.CompilerServices.Unsafe.4.7.1\lib\net461\System.Runtime.CompilerServices.Unsafe.dll
+
+
+ ..\packages\System.Runtime.InteropServices.RuntimeInformation.4.3.0\lib\net45\System.Runtime.InteropServices.RuntimeInformation.dll
+ True
+ True
+
@@ -85,9 +118,24 @@
..\packages\System.Security.Cryptography.Primitives.4.3.0\lib\net46\System.Security.Cryptography.Primitives.dll
+
+ ..\packages\System.Security.Cryptography.ProtectedData.4.7.0\lib\net461\System.Security.Cryptography.ProtectedData.dll
+
..\packages\System.Security.Cryptography.X509Certificates.4.3.2\lib\net461\System.Security.Cryptography.X509Certificates.dll
+
+ ..\packages\System.Text.Encodings.Web.4.7.2\lib\net461\System.Text.Encodings.Web.dll
+
+
+ ..\packages\System.Text.Json.4.7.2\lib\net461\System.Text.Json.dll
+
+
+ ..\packages\System.Threading.Tasks.Extensions.4.5.4\lib\net461\System.Threading.Tasks.Extensions.dll
+
+
+ ..\packages\System.ValueTuple.4.5.0\lib\net461\System.ValueTuple.dll
+
diff --git a/secure-app-model/keyvault/CPVApplication/Utilities/KeyVaultProvider.cs b/secure-app-model/keyvault/CPVApplication/Utilities/KeyVaultProvider.cs
index b9f2a78..f80ba3b 100644
--- a/secure-app-model/keyvault/CPVApplication/Utilities/KeyVaultProvider.cs
+++ b/secure-app-model/keyvault/CPVApplication/Utilities/KeyVaultProvider.cs
@@ -6,12 +6,11 @@
namespace CPVApplication.Utilities
{
+ using Azure.Identity;
+ using Azure.Security.KeyVault.Secrets;
+ using System;
using System.Configuration;
- using System.Net.Http;
using System.Threading.Tasks;
- using Microsoft.Azure.KeyVault;
- using Microsoft.Azure.KeyVault.Models;
- using Newtonsoft.Json.Linq;
///
/// Provider for accessing secrets from the Azure KeyVault
@@ -19,14 +18,14 @@ namespace CPVApplication.Utilities
public class KeyVaultProvider
{
///
- /// The client used to perform HTTP operations.
+ /// The base address for the instance of Azure Key Vault.
///
- private static readonly HttpClient httpClient = new HttpClient();
+ private readonly string BaseUrl = ConfigurationManager.AppSettings["KeyVaultEndpoint"];
///
- /// The base address for the instance of Azure Key Vault.
+ /// The identifier for the Azure AD application configured to access the instance of Azure Key Vault.
///
- private readonly string BaseUrl = ConfigurationManager.AppSettings["KeyVaultEndpoint"];
+ private readonly string KeyVaultTenantId = ConfigurationManager.AppSettings["ida:KeyVaultTenantId"];
///
/// The identifier for the Azure AD application configured to access the instance of Azure Key Vault.
@@ -41,14 +40,18 @@ public class KeyVaultProvider
///
/// The client used to interact with the instance of Azure Key Vault.
///
- private readonly KeyVaultClient keyVaultClient;
+ private readonly SecretClient secretClient;
///
/// Initializes a new instance of the class.
///
public KeyVaultProvider()
{
- keyVaultClient = new KeyVaultClient(new KeyVaultClient.AuthenticationCallback(GetToken), httpClient);
+ secretClient = new SecretClient(new Uri(BaseUrl),
+ new ClientSecretCredential(
+ KeyVaultTenantId,
+ KeyVaultClientId,
+ KeyVaultClientSecret));
}
///
@@ -58,14 +61,8 @@ public KeyVaultProvider()
/// The value retrieved from the vault.
public async Task GetSecretAsync(string key)
{
- SecretBundle secret = await keyVaultClient.GetSecretAsync(BaseUrl, key.Replace("@", string.Empty).Replace(".", string.Empty)).ConfigureAwait(false);
+ KeyVaultSecret secret = await secretClient.GetSecretAsync(key.Replace("@", string.Empty).Replace(".", string.Empty)).ConfigureAwait(false);
return secret.Value;
}
-
- private async Task GetToken(string authority, string resource, string scope)
- {
- JObject tokenResult = await AuthorizationUtilities.GetADAppToken(authority, resource, KeyVaultClientId, KeyVaultClientSecret);
- return tokenResult["access_token"].ToString();
- }
}
-}
\ No newline at end of file
+}
diff --git a/secure-app-model/keyvault/CPVApplication/packages.config b/secure-app-model/keyvault/CPVApplication/packages.config
index b132b61..28e739f 100644
--- a/secure-app-model/keyvault/CPVApplication/packages.config
+++ b/secure-app-model/keyvault/CPVApplication/packages.config
@@ -1,17 +1,32 @@
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/secure-app-model/keyvault/CSPApplication/App.config b/secure-app-model/keyvault/CSPApplication/App.config
index eab6de0..5e171fb 100644
--- a/secure-app-model/keyvault/CSPApplication/App.config
+++ b/secure-app-model/keyvault/CSPApplication/App.config
@@ -11,7 +11,10 @@
-
+
+
+
+
@@ -34,13 +37,53 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/secure-app-model/keyvault/CSPApplication/CSPApplication.csproj b/secure-app-model/keyvault/CSPApplication/CSPApplication.csproj
index c50a3ba..8942361 100644
--- a/secure-app-model/keyvault/CSPApplication/CSPApplication.csproj
+++ b/secure-app-model/keyvault/CSPApplication/CSPApplication.csproj
@@ -32,17 +32,26 @@
4
-
- ..\packages\Microsoft.Azure.KeyVault.3.0.4\lib\net461\Microsoft.Azure.KeyVault.dll
+
+ ..\packages\Azure.Core.1.24.0\lib\net461\Azure.Core.dll
-
- ..\packages\Microsoft.Azure.KeyVault.WebKey.3.0.4\lib\net461\Microsoft.Azure.KeyVault.WebKey.dll
+
+ ..\packages\Azure.Identity.1.6.0\lib\netstandard2.0\Azure.Identity.dll
-
- ..\packages\Microsoft.Identity.Client.4.31.0\lib\net461\Microsoft.Identity.Client.dll
+
+ ..\packages\Azure.Security.KeyVault.Secrets.4.3.0\lib\netstandard2.0\Azure.Security.KeyVault.Secrets.dll
+
+
+ ..\packages\Microsoft.Bcl.AsyncInterfaces.1.1.1\lib\net461\Microsoft.Bcl.AsyncInterfaces.dll
+
+
+ ..\packages\Microsoft.Identity.Client.4.39.0\lib\net461\Microsoft.Identity.Client.dll
+
+
+ ..\packages\Microsoft.Identity.Client.Extensions.Msal.2.19.3\lib\net45\Microsoft.Identity.Client.Extensions.Msal.dll
- ..\packages\Microsoft.Rest.ClientRuntime.2.3.20\lib\net461\Microsoft.Rest.ClientRuntime.dll
+ ..\packages\Microsoft.Rest.ClientRuntime.2.3.24\lib\net461\Microsoft.Rest.ClientRuntime.dll
..\packages\Microsoft.Rest.ClientRuntime.Azure.3.3.19\lib\net461\Microsoft.Rest.ClientRuntime.Azure.dll
@@ -60,20 +69,44 @@
..\packages\Newtonsoft.Json.12.0.2\lib\net45\Newtonsoft.Json.dll
+
+ ..\packages\System.Buffers.4.5.1\lib\net461\System.Buffers.dll
+
..\packages\System.ComponentModel.Annotations.4.7.0\lib\net461\System.ComponentModel.Annotations.dll
+
+ ..\packages\System.Diagnostics.DiagnosticSource.4.6.0\lib\net46\System.Diagnostics.DiagnosticSource.dll
+
+
+ ..\packages\System.Memory.4.5.4\lib\net461\System.Memory.dll
+
+
+ ..\packages\System.Memory.Data.1.0.2\lib\net461\System.Memory.Data.dll
+
..\packages\System.Net.Http.4.3.4\lib\net46\System.Net.Http.dll
+
+
+ ..\packages\System.Numerics.Vectors.4.5.0\lib\net46\System.Numerics.Vectors.dll
+
+
+ ..\packages\System.Runtime.CompilerServices.Unsafe.4.7.1\lib\net461\System.Runtime.CompilerServices.Unsafe.dll
+
+
+ ..\packages\System.Runtime.InteropServices.RuntimeInformation.4.3.0\lib\net45\System.Runtime.InteropServices.RuntimeInformation.dll
+ True
+ True
+
@@ -85,9 +118,24 @@
..\packages\System.Security.Cryptography.Primitives.4.3.0\lib\net46\System.Security.Cryptography.Primitives.dll
+
+ ..\packages\System.Security.Cryptography.ProtectedData.4.7.0\lib\net461\System.Security.Cryptography.ProtectedData.dll
+
..\packages\System.Security.Cryptography.X509Certificates.4.3.2\lib\net461\System.Security.Cryptography.X509Certificates.dll
+
+ ..\packages\System.Text.Encodings.Web.4.7.2\lib\net461\System.Text.Encodings.Web.dll
+
+
+ ..\packages\System.Text.Json.4.7.2\lib\net461\System.Text.Json.dll
+
+
+ ..\packages\System.Threading.Tasks.Extensions.4.5.4\lib\net461\System.Threading.Tasks.Extensions.dll
+
+
+ ..\packages\System.ValueTuple.4.5.0\lib\net461\System.ValueTuple.dll
+
diff --git a/secure-app-model/keyvault/CSPApplication/Utilities/KeyVaultProvider.cs b/secure-app-model/keyvault/CSPApplication/Utilities/KeyVaultProvider.cs
index 7b9df64..54ee4e6 100644
--- a/secure-app-model/keyvault/CSPApplication/Utilities/KeyVaultProvider.cs
+++ b/secure-app-model/keyvault/CSPApplication/Utilities/KeyVaultProvider.cs
@@ -6,39 +6,32 @@
namespace CSPApplication.Utilities
{
+ using Azure.Identity;
+ using Azure.Security.KeyVault.Secrets;
+ using System;
using System.Configuration;
- using System.Net.Http;
using System.Threading.Tasks;
- using Microsoft.Azure.KeyVault;
- using Microsoft.Azure.KeyVault.Models;
- using Newtonsoft.Json.Linq;
///
/// Provider for accessing secrets from the Azure KeyVault
///
public class KeyVaultProvider
{
+ private readonly string KeyVaultTenantId = ConfigurationManager.AppSettings["ida:KeyVaultTenantId"];
private readonly string KeyVaultClientId = ConfigurationManager.AppSettings["ida:KeyVaultClientId"];
private readonly string KeyVaultClientSecret = ConfigurationManager.AppSettings["ida:KeyVaultClientSecret"];
private readonly string BaseUrl = ConfigurationManager.AppSettings["KeyVaultEndpoint"];
- ///
- /// The client used to perform HTTP operations.
- ///
- private static readonly HttpClient httpClient = new HttpClient();
-
public async Task GetSecretAsync(string key)
{
- KeyVaultClient keyVault = new KeyVaultClient(new KeyVaultClient.AuthenticationCallback(GetToken), httpClient);
+ SecretClient secretClient = new SecretClient(new Uri(BaseUrl),
+ new ClientSecretCredential(
+ KeyVaultTenantId,
+ KeyVaultClientId,
+ KeyVaultClientSecret));
- SecretBundle secret = await keyVault.GetSecretAsync(BaseUrl, key.Replace("@", string.Empty).Replace(".", string.Empty));
+ KeyVaultSecret secret = await secretClient.GetSecretAsync(key.Replace("@", string.Empty).Replace(".", string.Empty)).ConfigureAwait(false);
return secret.Value;
}
-
- private async Task GetToken(string authority, string resource, string scope)
- {
- JObject tokenResult = await AuthorizationUtilities.GetADAppToken(authority, resource, KeyVaultClientId, KeyVaultClientSecret);
- return tokenResult["access_token"].ToString();
- }
}
-}
\ No newline at end of file
+}
diff --git a/secure-app-model/keyvault/CSPApplication/packages.config b/secure-app-model/keyvault/CSPApplication/packages.config
index b132b61..28e739f 100644
--- a/secure-app-model/keyvault/CSPApplication/packages.config
+++ b/secure-app-model/keyvault/CSPApplication/packages.config
@@ -1,17 +1,32 @@
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/secure-app-model/keyvault/PartnerConsent/PartnerConsent.csproj b/secure-app-model/keyvault/PartnerConsent/PartnerConsent.csproj
index 3d6c8d5..2c42759 100644
--- a/secure-app-model/keyvault/PartnerConsent/PartnerConsent.csproj
+++ b/secure-app-model/keyvault/PartnerConsent/PartnerConsent.csproj
@@ -51,16 +51,28 @@
..\packages\Antlr.3.5.0.2\lib\Antlr3.Runtime.dll
-
- ..\packages\Microsoft.Azure.KeyVault.3.0.4\lib\net461\Microsoft.Azure.KeyVault.dll
+
+ ..\packages\Azure.Core.1.24.0\lib\net461\Azure.Core.dll
-
- ..\packages\Microsoft.Azure.KeyVault.WebKey.3.0.4\lib\net461\Microsoft.Azure.KeyVault.WebKey.dll
+
+ ..\packages\Azure.Identity.1.6.0\lib\netstandard2.0\Azure.Identity.dll
+
+
+ ..\packages\Azure.Security.KeyVault.Secrets.4.3.0\lib\netstandard2.0\Azure.Security.KeyVault.Secrets.dll
+
+
+ ..\packages\Microsoft.Bcl.AsyncInterfaces.1.1.1\lib\net461\Microsoft.Bcl.AsyncInterfaces.dll
..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.2.0.1\lib\net45\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.dll
+
+ ..\packages\Microsoft.Identity.Client.4.39.0\lib\net461\Microsoft.Identity.Client.dll
+
+
+ ..\packages\Microsoft.Identity.Client.Extensions.Msal.2.19.3\lib\net45\Microsoft.Identity.Client.Extensions.Msal.dll
+
..\packages\Microsoft.IdentityModel.JsonWebTokens.5.5.0\lib\net461\Microsoft.IdentityModel.JsonWebTokens.dll
@@ -110,23 +122,89 @@
..\packages\Owin.1.0\lib\net40\Owin.dll
+
+ ..\packages\System.Buffers.4.5.1\lib\net461\System.Buffers.dll
+
+
+
+ ..\packages\System.Diagnostics.DiagnosticSource.4.6.0\lib\net46\System.Diagnostics.DiagnosticSource.dll
+
..\packages\System.IdentityModel.Tokens.Jwt.5.5.0\lib\net461\System.IdentityModel.Tokens.Jwt.dll
+
+ ..\packages\System.Memory.4.5.4\lib\net461\System.Memory.dll
+
+
+ ..\packages\System.Memory.Data.1.0.2\lib\net461\System.Memory.Data.dll
+
+
+ ..\packages\System.Net.Http.4.3.4\lib\net46\System.Net.Http.dll
+ True
+ True
+
+
+
+ ..\packages\System.Numerics.Vectors.4.5.0\lib\net46\System.Numerics.Vectors.dll
+
+
+ ..\packages\System.Runtime.CompilerServices.Unsafe.4.7.1\lib\net461\System.Runtime.CompilerServices.Unsafe.dll
+
+
+ ..\packages\System.Runtime.InteropServices.RuntimeInformation.4.3.0\lib\net45\System.Runtime.InteropServices.RuntimeInformation.dll
+ True
+ True
+
+
+ ..\packages\System.Security.Cryptography.Algorithms.4.3.0\lib\net461\System.Security.Cryptography.Algorithms.dll
+ True
+ True
+
+
+ ..\packages\System.Security.Cryptography.Encoding.4.3.0\lib\net46\System.Security.Cryptography.Encoding.dll
+ True
+ True
+
+
+ ..\packages\System.Security.Cryptography.Primitives.4.3.0\lib\net46\System.Security.Cryptography.Primitives.dll
+ True
+ True
+
+
+ ..\packages\System.Security.Cryptography.ProtectedData.4.7.0\lib\net461\System.Security.Cryptography.ProtectedData.dll
+
+
+ ..\packages\System.Security.Cryptography.X509Certificates.4.3.0\lib\net461\System.Security.Cryptography.X509Certificates.dll
+ True
+ True
+
+
+ ..\packages\System.Text.Encodings.Web.4.7.2\lib\net461\System.Text.Encodings.Web.dll
+
+
+ ..\packages\System.Text.Json.4.7.2\lib\net461\System.Text.Json.dll
+
+
+ ..\packages\System.Threading.Tasks.Extensions.4.5.4\lib\net461\System.Threading.Tasks.Extensions.dll
+
+
+ ..\packages\System.ValueTuple.4.5.0\lib\net461\System.ValueTuple.dll
+
+
..\packages\Microsoft.AspNet.WebPages.3.2.7\lib\net45\System.Web.Helpers.dll
@@ -149,14 +227,14 @@
..\packages\Microsoft.AspNet.WebPages.3.2.7\lib\net45\System.Web.WebPages.Razor.dll
+
-
-
+
..\packages\WebGrease.1.6.0\lib\WebGrease.dll
diff --git a/secure-app-model/keyvault/PartnerConsent/Utilities/KeyVaultProvider.cs b/secure-app-model/keyvault/PartnerConsent/Utilities/KeyVaultProvider.cs
index ba96ee9..34ff339 100644
--- a/secure-app-model/keyvault/PartnerConsent/Utilities/KeyVaultProvider.cs
+++ b/secure-app-model/keyvault/PartnerConsent/Utilities/KeyVaultProvider.cs
@@ -6,10 +6,11 @@
namespace PartnerConsent.Utilities
{
+ using Azure.Identity;
+ using Azure.Security.KeyVault.Secrets;
+ using System;
using System.Configuration;
using System.Threading.Tasks;
- using Microsoft.Azure.KeyVault;
- using Microsoft.Azure.KeyVault.Models;
///
@@ -17,6 +18,7 @@ namespace PartnerConsent.Utilities
///
public class KeyVaultProvider
{
+ private readonly string KeyVaultTenantId = ConfigurationManager.AppSettings["ida:KeyVaultTenantId"];
private readonly string KeyVaultClientId = ConfigurationManager.AppSettings["ida:KeyVaultClientId"];
private readonly string KeyVaultClientSecret = ConfigurationManager.AppSettings["ida:KeyVaultClientSecret"];
private readonly string BaseUrl = ConfigurationManager.AppSettings["KeyVaultEndpoint"];
@@ -28,11 +30,13 @@ public class KeyVaultProvider
/// key value in string format
public async Task GetSecretAsync(string key)
{
- KeyVaultClient keyVault = new KeyVaultClient(new KeyVaultClient.AuthenticationCallback(this.GetToken), new System.Net.Http.HttpClient());
-
- string secretIdentifier = this.BaseUrl + "/secrets/" + key.Replace("@", string.Empty).Replace(".", string.Empty);
- SecretBundle secret = await keyVault.GetSecretAsync(secretIdentifier);
+ SecretClient secretClient = new SecretClient(new Uri(BaseUrl),
+ new ClientSecretCredential(
+ KeyVaultTenantId,
+ KeyVaultClientId,
+ KeyVaultClientSecret));
+ KeyVaultSecret secret = await secretClient.GetSecretAsync(key.Replace("@", string.Empty).Replace(".", string.Empty)).ConfigureAwait(false);
return secret.Value;
}
@@ -44,22 +48,13 @@ public async Task GetSecretAsync(string key)
///
public async Task AddSecretAsync(string key, string value)
{
- KeyVaultClient keyVault = new KeyVaultClient(new KeyVaultClient.AuthenticationCallback(this.GetToken), new System.Net.Http.HttpClient());
- await keyVault.SetSecretAsync(this.BaseUrl, key.Replace("@", string.Empty).Replace(".", string.Empty), value);
- }
+ SecretClient secretClient = new SecretClient(new Uri(BaseUrl),
+ new ClientSecretCredential(
+ KeyVaultTenantId,
+ KeyVaultClientId,
+ KeyVaultClientSecret));
- ///
- /// Get application token for the app which is given access to Azure keyvault
- /// Called by delegate in azure key vault SDK
- ///
- /// AAD authority
- /// Azure key vault resource
- /// authorization scope
- ///
- private async Task GetToken(string authority, string resource, string scope)
- {
- Newtonsoft.Json.Linq.JObject tokenResult = await AuthorizationUtilities.GetADAppToken(authority, resource, this.KeyVaultClientId, this.KeyVaultClientSecret);
- return tokenResult["access_token"].ToString();
+ await secretClient.SetSecretAsync(key.Replace("@", string.Empty).Replace(".", string.Empty), value).ConfigureAwait(false);
}
}
}
\ No newline at end of file
diff --git a/secure-app-model/keyvault/PartnerConsent/Web.config b/secure-app-model/keyvault/PartnerConsent/Web.config
index 7c02ce9..1637ee5 100644
--- a/secure-app-model/keyvault/PartnerConsent/Web.config
+++ b/secure-app-model/keyvault/PartnerConsent/Web.config
@@ -1,93 +1,352 @@
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ The following attributes can be set on the tag.
+
+
+
+ -->
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
-
\ No newline at end of file
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/secure-app-model/keyvault/PartnerConsent/packages.config b/secure-app-model/keyvault/PartnerConsent/packages.config
index 090b38e..fd14cbf 100644
--- a/secure-app-model/keyvault/PartnerConsent/packages.config
+++ b/secure-app-model/keyvault/PartnerConsent/packages.config
@@ -1,13 +1,17 @@
+
+
+
-
-
+
+
+
@@ -25,6 +29,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file