141 references to CurrentUser
aspire (17)
Certificates\CertificateGeneration\CertificateManager.cs (6)
252ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 287var allCurrentUserCertificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 543var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false); 609var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 858var location = StoreLocation.CurrentUser; 1020using var store = new X509Store(StoreName.My, StoreLocation.CurrentUser);
Certificates\CertificateGeneration\MacOSCertificateManager.cs (2)
378return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 383if (store.Name! == StoreName.My.ToString() && store.Location == StoreLocation.CurrentUser && Directory.Exists(s_macOSUserHttpsCertificateLocation))
Certificates\CertificateGeneration\UnixCertificateManager.cs (3)
208using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 447using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 537return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false);
Certificates\CertificateGeneration\WindowsCertificateManager.cs (3)
77using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 106using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 123var isTrusted = ListCertificates(StoreName.Root, StoreLocation.CurrentUser, isValid: true, requireExportable: false)
Certificates\NativeCertificateToolRunner.cs (2)
20StoreName.My, StoreLocation.CurrentUser, isValid: true); 71StoreName.My, StoreLocation.CurrentUser, isValid: true);
src\Shared\X509Certificate2Extensions.cs (1)
91(StoreName.Root, StoreLocation.CurrentUser),
Aspire.Dashboard (1)
ServiceClient\DashboardClient.cs (1)
197var location = _dashboardOptions.ResourceServiceClient.ClientCertificate.Location ?? StoreLocation.CurrentUser;
Aspire.Hosting (3)
DeveloperCertificateService.cs (2)
32using var store = new X509Store(StoreName.My, StoreLocation.CurrentUser); 68using var rootStore = new X509Store(StoreName.Root, StoreLocation.CurrentUser);
src\Shared\X509Certificate2Extensions.cs (1)
91(StoreName.Root, StoreLocation.CurrentUser),
Aspire.Playground.Tests (2)
src\Shared\X509Certificate2Extensions.cs (1)
91(StoreName.Root, StoreLocation.CurrentUser),
tests\Aspire.TestUtilities\RequiresFeatureAttribute.cs (1)
99using var store = new X509Store(StoreName.My, StoreLocation.CurrentUser);
Aspire.TestUtilities (2)
RequiresFeatureAttribute.cs (1)
99using var store = new X509Store(StoreName.My, StoreLocation.CurrentUser);
src\Shared\X509Certificate2Extensions.cs (1)
91(StoreName.Root, StoreLocation.CurrentUser),
Binding.UDS.IntegrationTests (1)
ServiceHelper.cs (1)
50using (var store = new X509Store(StoreName.My, StoreLocation.CurrentUser))
Client.ChannelLayer.IntegrationTests (3)
DuplexChannelWithSynchronizationContext.cs (3)
47StoreLocation.CurrentUser, 109StoreLocation.CurrentUser, 186StoreLocation.CurrentUser,
dotnet-dev-certs (17)
Program.cs (3)
306var certificates = certificateManager.ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true); 367var availableCertificates = CertificateManager.Instance.ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true); 382var certificates = manager.ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, exportPath.HasValue());
src\aspnetcore\src\Shared\CertificateGeneration\CertificateManager.cs (6)
254ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 289var allCurrentUserCertificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 546var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false); 612var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 861var location = StoreLocation.CurrentUser; 1023using var store = new X509Store(StoreName.My, StoreLocation.CurrentUser);
src\aspnetcore\src\Shared\CertificateGeneration\MacOSCertificateManager.cs (2)
378return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 383if (store.Name! == StoreName.My.ToString() && store.Location == StoreLocation.CurrentUser && Directory.Exists(MacOSUserHttpsCertificateLocation))
src\aspnetcore\src\Shared\CertificateGeneration\UnixCertificateManager.cs (3)
208using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 447using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 537return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false);
src\aspnetcore\src\Shared\CertificateGeneration\WindowsCertificateManager.cs (3)
81using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 110using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 127var isTrusted = ListCertificates(StoreName.Root, StoreLocation.CurrentUser, isValid: true, requireExportable: false)
dotnet-svcutil-lib (4)
CmdCredentialsProvider.cs (1)
76X509Store certificateStore = new X509Store(StoreName.My, StoreLocation.CurrentUser);
FrameworkFork\System.ServiceModel\System\ServiceModel\Security\X509CertificateInitiatorClientCredential.cs (1)
11internal const StoreLocation DefaultStoreLocation = StoreLocation.CurrentUser;
FrameworkFork\System.ServiceModel\System\ServiceModel\Security\X509CertificateRecipientClientCredential.cs (1)
15internal const StoreLocation DefaultStoreLocation = StoreLocation.CurrentUser;
FrameworkFork\System.ServiceModel\System\ServiceModel\Security\X509ServiceCertificateAuthentication.cs (1)
15internal const StoreLocation DefaultTrustedStoreLocation = StoreLocation.CurrentUser;
Infrastructure.Common (6)
CertificateManager.cs (6)
55s_platformSpecificRootStoreLocation = StoreLocation.CurrentUser; 60s_platformSpecificRootStoreLocation = StoreLocation.CurrentUser; 214return CertificateFromThumbprint(StoreName.My, StoreLocation.CurrentUser, thumbprint, validOnly); 220return CertificateFromThumbprint(StoreName.TrustedPeople, StoreLocation.CurrentUser, thumbprint, validOnly); 247certificate = AddToStoreIfNeeded(StoreName.My, StoreLocation.CurrentUser, certificate); 260certificate = AddToStoreIfNeeded(StoreName.TrustedPeople, StoreLocation.CurrentUser, certificate);
Microsoft.AspNetCore.DataProtection (1)
XmlEncryption\CertificateResolver.cs (1)
31return GetCertificateFromStore(StoreLocation.CurrentUser, thumbprint)
Microsoft.AspNetCore.DeveloperCertificates.XPlat (14)
src\aspnetcore\src\Shared\CertificateGeneration\CertificateManager.cs (6)
254ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 289var allCurrentUserCertificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 546var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false); 612var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 861var location = StoreLocation.CurrentUser; 1023using var store = new X509Store(StoreName.My, StoreLocation.CurrentUser);
src\aspnetcore\src\Shared\CertificateGeneration\MacOSCertificateManager.cs (2)
378return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 383if (store.Name! == StoreName.My.ToString() && store.Location == StoreLocation.CurrentUser && Directory.Exists(MacOSUserHttpsCertificateLocation))
src\aspnetcore\src\Shared\CertificateGeneration\UnixCertificateManager.cs (3)
208using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 447using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 537return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false);
src\aspnetcore\src\Shared\CertificateGeneration\WindowsCertificateManager.cs (3)
81using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 110using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 127var isTrusted = ListCertificates(StoreName.Root, StoreLocation.CurrentUser, isValid: true, requireExportable: false)
Microsoft.AspNetCore.Server.Kestrel.Core (21)
Internal\Certificates\CertificateConfigLoader.cs (1)
329var storeLocation = StoreLocation.CurrentUser;
KestrelServerOptions.cs (1)
382var certs = CertificateManager.Instance.ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: false);
ListenOptionsHttpsExtensions.cs (1)
94=> listenOptions.UseHttps(storeName, subject, allowInvalid, StoreLocation.CurrentUser);
Middleware\HttpsConnectionMiddleware.cs (4)
320store = OpenStore(StoreLocation.CurrentUser); 330_logger.FoundCertWithPrivateKey(certs[0], StoreLocation.CurrentUser); 636var storeLocationString = storeLocation == StoreLocation.LocalMachine ? nameof(StoreLocation.LocalMachine) : nameof(StoreLocation.CurrentUser); 651var storeLocationString = storeLocation == StoreLocation.LocalMachine ? nameof(StoreLocation.LocalMachine) : nameof(StoreLocation.CurrentUser);
src\aspnetcore\src\Shared\CertificateGeneration\CertificateManager.cs (6)
254ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 289var allCurrentUserCertificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 546var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false); 612var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 861var location = StoreLocation.CurrentUser; 1023using var store = new X509Store(StoreName.My, StoreLocation.CurrentUser);
src\aspnetcore\src\Shared\CertificateGeneration\MacOSCertificateManager.cs (2)
378return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 383if (store.Name! == StoreName.My.ToString() && store.Location == StoreLocation.CurrentUser && Directory.Exists(MacOSUserHttpsCertificateLocation))
src\aspnetcore\src\Shared\CertificateGeneration\UnixCertificateManager.cs (3)
208using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 447using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 537return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false);
src\aspnetcore\src\Shared\CertificateGeneration\WindowsCertificateManager.cs (3)
81using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 110using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 127var isTrusted = ListCertificates(StoreName.Root, StoreLocation.CurrentUser, isValid: true, requireExportable: false)
Microsoft.Build.Tasks.Core (3)
ManifestUtil\SecurityUtil.cs (2)
884var personalStore = new X509Store(StoreName.My, StoreLocation.CurrentUser); 903var personalStore = new X509Store(StoreName.My, StoreLocation.CurrentUser);
ResolveKeySource.cs (1)
179var personalStore = new X509Store(StoreName.My, StoreLocation.CurrentUser);
NuGet.CommandLine.XPlat (1)
Commands\Signing\SignCommand.cs (1)
183StoreLocation storeLocation = StoreLocation.CurrentUser;
NuGet.Configuration (2)
Settings\Items\StoreClientCertItem.cs (2)
24private const StoreLocation DefaultStoreLocation = StoreLocation.CurrentUser; 167GetString(StoreLocation.CurrentUser),
PresentationUI (1)
MS\Internal\Documents\DocumentSignatureManager.cs (1)
905X509Store store = new X509Store(StoreLocation.CurrentUser);
RepoTasks (14)
src\aspnetcore\src\Shared\CertificateGeneration\CertificateManager.cs (6)
254ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 289var allCurrentUserCertificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: true, requireExportable: true); 546var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false); 612var certificates = ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 861var location = StoreLocation.CurrentUser; 1023using var store = new X509Store(StoreName.My, StoreLocation.CurrentUser);
src\aspnetcore\src\Shared\CertificateGeneration\MacOSCertificateManager.cs (2)
378return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false); 383if (store.Name! == StoreName.My.ToString() && store.Location == StoreLocation.CurrentUser && Directory.Exists(MacOSUserHttpsCertificateLocation))
src\aspnetcore\src\Shared\CertificateGeneration\UnixCertificateManager.cs (3)
208using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 447using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 537return ListCertificates(StoreName.My, StoreLocation.CurrentUser, isValid: false, requireExportable: false);
src\aspnetcore\src\Shared\CertificateGeneration\WindowsCertificateManager.cs (3)
81using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 110using var store = new X509Store(StoreName.Root, StoreLocation.CurrentUser); 127var isTrusted = ListCertificates(StoreName.Root, StoreLocation.CurrentUser, isValid: true, requireExportable: false)
Security.TransportSecurity.IntegrationTests (9)
Https\HttpsTests.4.1.0.cs (5)
43StoreLocation.CurrentUser, 376StoreLocation.CurrentUser, 425StoreLocation.CurrentUser, 487StoreLocation.CurrentUser, 547StoreLocation.CurrentUser,
Tcp\ClientCredentialTypeTests.4.1.0.cs (2)
40StoreLocation.CurrentUser, 92StoreLocation.CurrentUser,
Tcp\ClientCredentialTypeTests.4.1.1.cs (1)
251StoreLocation.CurrentUser,
Tcp\ClientCredentialTypeTests.OSX.cs (1)
153using (store = new X509Store(StoreName.Disallowed, StoreLocation.CurrentUser))
System.Net.Http (1)
src\runtime\src\libraries\Common\src\System\Net\Security\CertificateHelper.Unix.cs (1)
14using (var myStore = new X509Store(StoreName.My, StoreLocation.CurrentUser))
System.Net.Http.WinHttpHandler (1)
src\runtime\src\libraries\Common\src\System\Net\Security\CertificateHelper.Windows.cs (1)
14using (var myStore = new X509Store(StoreName.My, StoreLocation.CurrentUser))
System.Net.Security (2)
System\Net\CertificateValidationPal.cs (1)
35StoreLocation storeLocation = isMachineStore ? StoreLocation.LocalMachine : StoreLocation.CurrentUser;
System\Net\CertificateValidationPal.Unix.cs (1)
182Debug.Assert(storeLocation == StoreLocation.CurrentUser);
System.Security.Cryptography (6)
System\Security\Cryptography\X509Certificates\StorePal.Windows.Import.cs (1)
237else if (storeLocation == StoreLocation.CurrentUser)
System\Security\Cryptography\X509Certificates\X509Store.cs (5)
18: this("MY", StoreLocation.CurrentUser) 23: this(storeName, StoreLocation.CurrentUser) 28: this(storeName, StoreLocation.CurrentUser) 39if (storeLocation != StoreLocation.CurrentUser && storeLocation != StoreLocation.LocalMachine) 65if (storeLocation != StoreLocation.CurrentUser && storeLocation != StoreLocation.LocalMachine)
System.Security.Cryptography.Pkcs (3)
Internal\Cryptography\Pal\AnyOS\ManagedPal.cs (1)
20certs.AddRange(PkcsHelpers.GetStoreCertificates(StoreName.My, StoreLocation.CurrentUser, openExistingOnly: false));
Internal\Cryptography\Pal\Windows\DecryptorPalWindows.Decrypt.cs (1)
220candidateCerts.AddRange(PkcsHelpers.GetStoreCertificates(StoreName.AddressBook, StoreLocation.CurrentUser, openExistingOnly: true));
Internal\Cryptography\Pal\Windows\PkcsPalWindows.cs (1)
59certs.AddRange(PkcsHelpers.GetStoreCertificates(StoreName.My, StoreLocation.CurrentUser, openExistingOnly: true));
System.Security.Cryptography.Xml (1)
System\Security\Cryptography\Xml\Utils.cs (1)
655stores[0] = new X509Store(storeName, StoreLocation.CurrentUser);
System.ServiceModel.Http (1)
System\ServiceModel\Channels\HttpsChannelFactory.cs (1)
298using (var store = new X509Store(StoreName.My, StoreLocation.CurrentUser))
System.ServiceModel.Primitives (4)
System\IdentityModel\Selectors\X509CertificateValidator.cs (1)
124X509Store store = new X509Store(storeName, StoreLocation.CurrentUser);
System\ServiceModel\Security\X509CertificateInitiatorClientCredential.cs (1)
12internal const StoreLocation DefaultStoreLocation = StoreLocation.CurrentUser;
System\ServiceModel\Security\X509CertificateRecipientClientCredential.cs (1)
15internal const StoreLocation DefaultStoreLocation = StoreLocation.CurrentUser;
System\ServiceModel\Security\X509ServiceCertificateAuthentication.cs (1)
18internal const StoreLocation DefaultTrustedStoreLocation = StoreLocation.CurrentUser;