2 implementations of ExpirationDate
Microsoft.AspNetCore.DataProtection (1)
KeyManagement\Key.cs (1)
120public DateTimeOffset ExpirationDate { get; }
Microsoft.AspNetCore.DataProtection.Tests (1)
KeyManagement\KeyRingTests.cs (1)
111public DateTimeOffset ExpirationDate { get; }
16 references to ExpirationDate
Microsoft.AspNetCore.DataProtection (8)
KeyManagement\DefaultKeyResolver.cs (1)
169_logger.ConsideringKeyWithExpirationDateAsDefaultKey(preferredDefaultKey.KeyId, preferredDefaultKey.ExpirationDate);
KeyManagement\KeyExtensions.cs (1)
12return (key.ExpirationDate <= now);
KeyManagement\KeyRingProvider.cs (6)
117var defaultKeyExpirationDate = defaultKey.ExpirationDate; 121nextDefaultKey.ExpirationDate < minExpirationDate); 146_logger.UsingFallbackKeyWithExpirationAsDefaultKey(keyToUse.KeyId, keyToUse.ExpirationDate); 166var newKey = _keyManager.CreateNewKey(activationDate: defaultKey.ExpirationDate, expirationDate: now + _newKeyLifetime); 198expirationTime: (defaultKey.ExpirationDate <= now) ? nextAutoRefreshTime : Min(defaultKey.ExpirationDate, nextAutoRefreshTime),
Microsoft.AspNetCore.DataProtection.Tests (8)
KeyManagement\DefaultKeyResolverTests.cs (1)
464mockKey.Setup(o => o.ExpirationDate).Returns(expirationDate);
KeyManagement\KeyRingProviderTests.cs (3)
79Tuple.Create(key1.ExpirationDate, (IEnumerable<IKey>)allKeys, new DefaultKeyResolution() 291Tuple.Create(key1.ExpirationDate, (DateTimeOffset)now + TimeSpan.FromDays(90), CreateKey()) 941mockKey.Setup(o => o.ExpirationDate).Returns(expirationDate);
KeyManagement\XmlKeyManagerTests.cs (4)
132Assert.Equal(expirationDate, newKey.ExpirationDate); 230Assert.Equal(expirationDate, newKey.ExpirationDate); 375Assert.Equal(XmlConvert.ToDateTimeOffset("2015-03-01T00:00:00Z"), keys[0].ExpirationDate); 381Assert.Equal(XmlConvert.ToDateTimeOffset("2015-06-01T00:00:00Z"), keys[1].ExpirationDate);