React to options changes
This commit is contained in:
commit
4e43fa24cf
|
|
@ -25,7 +25,7 @@ namespace Microsoft.AspNet.Security.DataProtection.Azure
|
||||||
internal static readonly XNamespace XmlNamespace = XNamespace.Get("http://www.asp.net/dataProtection/2014/azure");
|
internal static readonly XNamespace XmlNamespace = XNamespace.Get("http://www.asp.net/dataProtection/2014/azure");
|
||||||
internal static readonly XName KeyRingElementName = XmlNamespace.GetName("keyRing");
|
internal static readonly XName KeyRingElementName = XmlNamespace.GetName("keyRing");
|
||||||
|
|
||||||
public BlobStorageXmlRepository([NotNull] IOptionsAccessor<BlobStorageXmlRepositoryOptions> optionsAccessor)
|
public BlobStorageXmlRepository([NotNull] IOptions<BlobStorageXmlRepositoryOptions> optionsAccessor)
|
||||||
{
|
{
|
||||||
Directory = optionsAccessor.Options.Directory;
|
Directory = optionsAccessor.Options.Directory;
|
||||||
CryptoUtil.Assert(Directory != null, "Directory != null");
|
CryptoUtil.Assert(Directory != null, "Directory != null");
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ namespace Microsoft.AspNet.Security.DataProtection.AuthenticatedEncryption
|
||||||
{
|
{
|
||||||
private readonly CngCbcAuthenticatedEncryptorConfigurationOptions _options;
|
private readonly CngCbcAuthenticatedEncryptorConfigurationOptions _options;
|
||||||
|
|
||||||
public CngCbcAuthenticatedEncryptorConfigurationFactory([NotNull] IOptionsAccessor<CngCbcAuthenticatedEncryptorConfigurationOptions> optionsAccessor)
|
public CngCbcAuthenticatedEncryptorConfigurationFactory([NotNull] IOptions<CngCbcAuthenticatedEncryptorConfigurationOptions> optionsAccessor)
|
||||||
{
|
{
|
||||||
_options = optionsAccessor.Options.Clone();
|
_options = optionsAccessor.Options.Clone();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ namespace Microsoft.AspNet.Security.DataProtection.AuthenticatedEncryption
|
||||||
{
|
{
|
||||||
private readonly CngGcmAuthenticatedEncryptorConfigurationOptions _options;
|
private readonly CngGcmAuthenticatedEncryptorConfigurationOptions _options;
|
||||||
|
|
||||||
public CngGcmAuthenticatedEncryptorConfigurationFactory([NotNull] IOptionsAccessor<CngGcmAuthenticatedEncryptorConfigurationOptions> optionsAccessor)
|
public CngGcmAuthenticatedEncryptorConfigurationFactory([NotNull] IOptions<CngGcmAuthenticatedEncryptorConfigurationOptions> optionsAccessor)
|
||||||
{
|
{
|
||||||
_options = optionsAccessor.Options.Clone();
|
_options = optionsAccessor.Options.Clone();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@ namespace Microsoft.AspNet.Security.DataProtection.AuthenticatedEncryption
|
||||||
{
|
{
|
||||||
private readonly ManagedAuthenticatedEncryptorConfigurationOptions _options;
|
private readonly ManagedAuthenticatedEncryptorConfigurationOptions _options;
|
||||||
|
|
||||||
public ManagedAuthenticatedEncryptorConfigurationFactory([NotNull] IOptionsAccessor<ManagedAuthenticatedEncryptorConfigurationOptions> optionsAccessor)
|
public ManagedAuthenticatedEncryptorConfigurationFactory([NotNull] IOptions<ManagedAuthenticatedEncryptorConfigurationOptions> optionsAccessor)
|
||||||
{
|
{
|
||||||
_options = optionsAccessor.Options.Clone();
|
_options = optionsAccessor.Options.Clone();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ namespace Microsoft.AspNet.Security.DataProtection
|
||||||
}
|
}
|
||||||
|
|
||||||
public DefaultDataProtectionProvider(
|
public DefaultDataProtectionProvider(
|
||||||
[NotNull] IOptionsAccessor<DataProtectionOptions> optionsAccessor,
|
[NotNull] IOptions<DataProtectionOptions> optionsAccessor,
|
||||||
[NotNull] IKeyManager keyManager)
|
[NotNull] IKeyManager keyManager)
|
||||||
{
|
{
|
||||||
KeyRingBasedDataProtectionProvider rootProvider = new KeyRingBasedDataProtectionProvider(new KeyRingProvider(keyManager));
|
KeyRingBasedDataProtectionProvider rootProvider = new KeyRingBasedDataProtectionProvider(new KeyRingProvider(keyManager));
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue