19 writes to DefaultKey
Microsoft.AspNetCore.DataProtection (1)
KeyManagement\DefaultKeyResolver.cs (1)
216retVal.DefaultKey = defaultKey;
Microsoft.AspNetCore.DataProtection.Tests (18)
KeyManagement\KeyRingProviderTests.cs (18)
38DefaultKey = key1, 76DefaultKey = key1, 81DefaultKey = key2, 124DefaultKey = null, 129DefaultKey = key1, 172DefaultKey = null, // Since there are no keys 177DefaultKey = null, // Since all keys are revoked 213DefaultKey = null, 218DefaultKey = null, 257DefaultKey = null, 297DefaultKey = key1, 302DefaultKey = key2, 341DefaultKey = key1, 462DefaultKey = key1, 474DefaultKey = key2ValidWhenKey1Expires ? key2 : null, 492DefaultKey = key1, 544DefaultKey = key, 549DefaultKey = key,
17 references to DefaultKey
Microsoft.AspNetCore.DataProtection (2)
KeyManagement\KeyRingProvider.cs (2)
89var defaultKey = defaultKeyPolicy.DefaultKey; 120(_defaultKeyResolver.ResolveDefaultKeyPolicy(defaultKeyExpirationDate, allKeys).DefaultKey is not { } nextDefaultKey ||
Microsoft.AspNetCore.DataProtection.Tests (15)
KeyManagement\DefaultKeyResolverTests.cs (15)
26Assert.Null(resolution.DefaultKey); 42Assert.Same(key1, resolution.DefaultKey); 58Assert.Same(key2, resolution.DefaultKey); 73Assert.Same(key1, resolution.DefaultKey); 88Assert.Same(key1, resolution.DefaultKey); 105Assert.Same(key1, resolution.DefaultKey); 121Assert.Null(resolution.DefaultKey); 137Assert.Null(resolution.DefaultKey); 152Assert.Same(key1, resolution.DefaultKey); 167Assert.Null(resolution.DefaultKey); 184Assert.Same(key3, resolution.DefaultKey); 273Assert.Same(key1, resolution.DefaultKey); 304Assert.Null(resolution.DefaultKey); 383Assert.Null(resolution.DefaultKey); 444Assert.Same(key, resolution.DefaultKey);