95 references to CertificateTrustScope
Aspire.Hosting (37)
ApplicationModel\CertificateAuthorityCollectionAnnotation.cs (1)
57
public
CertificateTrustScope
? Scope { get; internal set; }
ApplicationModel\CertificateTrustConfigurationCallbackAnnotation.cs (4)
59
/// <see cref="
CertificateTrustScope
.Override"/> or <see cref="
CertificateTrustScope
.System"/> is configured.
87
/// Gets the <see cref="
CertificateTrustScope
"/> for the resource.
89
public required
CertificateTrustScope
Scope { get; init; }
ApplicationModel\CertificateTrustExecutionConfigurationGatherer.cs (8)
22
private readonly Func<
CertificateTrustScope
, CertificateTrustExecutionConfigurationContext> _configContextFactory;
28
public CertificateTrustExecutionConfigurationGatherer(Func<
CertificateTrustScope
, CertificateTrustExecutionConfigurationContext> configContextFactory)
44
additionalData.Scope =
CertificateTrustScope
.Append;
57
if (additionalData.Scope ==
CertificateTrustScope
.None)
63
if (additionalData.Scope ==
CertificateTrustScope
.System)
91
if (additionalData.Scope !=
CertificateTrustScope
.Append)
124
if (additionalData.Scope ==
CertificateTrustScope
.System)
141
public
CertificateTrustScope
Scope { get; internal set; }
ApplicationModel\ContainerCertificatePathsAnnotation.cs (5)
45
/// <see cref="
CertificateTrustScope
"/> is set to <see cref="
CertificateTrustScope
.Override"/> or
46
/// <see cref="
CertificateTrustScope
.System"/>.
53
/// when the resource's <see cref="
CertificateTrustScope
"/> is set to <see cref="
CertificateTrustScope
.Append"/>.
ApplicationModel\ExecutionConfigurationBuilderExtensions.cs (1)
44
public static IExecutionConfigurationBuilder WithCertificateTrustConfig(this IExecutionConfigurationBuilder builder, Func<
CertificateTrustScope
, CertificateTrustExecutionConfigurationContext> configContextFactory)
Ats\ExecutionConfigurationExports.cs (2)
85
Scope =
CertificateTrustScope
.None,
178
public required
CertificateTrustScope
Scope { get; init; }
ContainerResourceBuilderExtensions.cs (3)
1301
/// <param name="defaultCertificateBundlePaths">List of default certificate bundle paths in the container that will be replaced in <see cref="
CertificateTrustScope
.Override"/> or <see cref="
CertificateTrustScope
.System"/> modes. If not specified, defaults to <c>/etc/ssl/certs/ca-certificates.crt</c> for Linux containers.</param>
1302
/// <param name="defaultCertificateDirectoryPaths">List of default certificate directory paths in the container that may be appended to the custom certificates directory in <see cref="
CertificateTrustScope
.Append"/> mode. If not specified, defaults to <c>/usr/local/share/ca-certificates/</c> for Linux containers.</param>
Dcp\ContainerCreator.cs (5)
707
if (scope ==
CertificateTrustScope
.Append)
734
&& certificateTrustConfiguration.Scope !=
CertificateTrustScope
.None
744
if (certificateTrustConfiguration.Scope !=
CertificateTrustScope
.Append)
766
CertificateTrustScope = certificateTrustConfiguration?.Scope ??
CertificateTrustScope
.None,
1089
public
CertificateTrustScope
CertificateTrustScope { get; init; }
Dcp\ExecutableConfigurationResolver.cs (2)
49
if (scope ==
CertificateTrustScope
.Append)
88
certificateTrustConfiguration.Scope !=
CertificateTrustScope
.None &&
ProjectResourceBuilderExtensions.cs (2)
561
builder.WithCertificateTrustScope(
CertificateTrustScope
.None);
566
if (ctx.Scope !=
CertificateTrustScope
.None && OperatingSystem.IsWindows())
ResourceBuilderExtensions.cs (4)
4066
/// Sets the <see cref="
CertificateTrustScope
"/> for custom certificate authorities associated with the resource. The scope
4077
/// The default scope if not overridden is <see cref="
CertificateTrustScope
.Append"/> which means that custom certificate
4079
/// <see cref="
CertificateTrustScope
.Override"/> indicates the set of certificates in referenced
4097
public static IResourceBuilder<TResource> WithCertificateTrustScope<TResource>(this IResourceBuilder<TResource> builder,
CertificateTrustScope
scope)
Aspire.Hosting.Azure.Tests (1)
AzureCosmosDBExtensionsTests.cs (1)
735
Scope =
CertificateTrustScope
.Append,
Aspire.Hosting.Java (5)
JavaHostingExtensions.cs (5)
109
.WithCertificateTrustScope(
CertificateTrustScope
.System)
270
.WithCertificateTrustScope(
CertificateTrustScope
.System)
1677
/// <see cref="
CertificateTrustScope
.System"/> so the generated bundle carries the system roots
1679
/// <see cref="
CertificateTrustScope
.Append"/>, the bundle would contain only Aspire's own
1688
if (ctx.Scope ==
CertificateTrustScope
.Append)
Aspire.Hosting.Java.Tests (3)
AddJavaAppTests.cs (2)
894
Assert.Equal(
CertificateTrustScope
.System, certAnnotation.Scope);
921
Scope =
CertificateTrustScope
.Append,
AddJavaContainerTests.cs (1)
150
Assert.Equal(
CertificateTrustScope
.System, scope.Scope);
Aspire.Hosting.JavaScript (8)
JavaScriptHostingExtensions.cs (8)
306
if (ctx.Scope ==
CertificateTrustScope
.Append)
723
if (ctx.Scope ==
CertificateTrustScope
.Append)
1097
if (ctx.Scope is
CertificateTrustScope
.Append or
CertificateTrustScope
.Override or
CertificateTrustScope
.System)
1110
if (ctx.Scope ==
CertificateTrustScope
.Override)
1114
else if (ctx.Scope ==
CertificateTrustScope
.System)
3040
.WithCertificateTrustScope(
CertificateTrustScope
.None);
Aspire.Hosting.JavaScript.Tests (6)
AddBunAppTests.cs (2)
264
Scope =
CertificateTrustScope
.Append,
292
Scope =
CertificateTrustScope
.Override,
AddDenoAppTests.cs (3)
2410
Scope =
CertificateTrustScope
.Append,
2439
Scope =
CertificateTrustScope
.Override,
2467
Scope =
CertificateTrustScope
.System,
ResourceCreationTests.cs (1)
211
Assert.Equal(
CertificateTrustScope
.None, certAnnotation.Scope);
Aspire.Hosting.Python (3)
PythonAppResourceBuilderExtensions.cs (3)
404
.WithCertificateTrustScope(
CertificateTrustScope
.System)
407
if (ctx.Scope ==
CertificateTrustScope
.Append)
1322
.WithCertificateTrustScope(
CertificateTrustScope
.None);
Aspire.Hosting.Python.Tests (1)
AddPythonAppTests.cs (1)
853
Assert.Equal(
CertificateTrustScope
.None, certAnnotation.Scope);
Aspire.Hosting.Tests (30)
Dcp\DcpExecutorTests.cs (3)
5412
.WithCertificateTrustScope(
CertificateTrustScope
.Override)
5454
.WithCertificateTrustScope(
CertificateTrustScope
.Override)
5587
var sslCertDir = GetPlainExecutableSslCertDirAsync(builder => builder.WithCertificateTrustScope(
CertificateTrustScope
.Override)).GetAwaiter().GetResult();
DistributedApplicationTests.cs (18)
963
[InlineData(false, false, false, false,
CertificateTrustScope
.Append)]
964
[InlineData(false, true, true, false,
CertificateTrustScope
.Append)]
965
[InlineData(true, false, false, false,
CertificateTrustScope
.Append)]
966
[InlineData(false, false, false, false,
CertificateTrustScope
.Override)]
967
[InlineData(false, true, true, false,
CertificateTrustScope
.Override)]
968
[InlineData(true, false, false, false,
CertificateTrustScope
.Override)]
969
[InlineData(false, false, false, true,
CertificateTrustScope
.Override)]
970
[InlineData(false, true, true, true,
CertificateTrustScope
.Override)]
971
[InlineData(true, false, false, true,
CertificateTrustScope
.Override)]
972
[InlineData(false, false, false, false,
CertificateTrustScope
.None)]
973
[InlineData(false, true, false, false,
CertificateTrustScope
.None)]
974
[InlineData(true, false, false, false,
CertificateTrustScope
.None)]
975
public async Task VerifyContainerIncludesExpectedDevCertificateConfiguration(bool? implicitTrust, bool? explicitTrust, bool expectDevCert, bool overridePaths,
CertificateTrustScope
trustScope)
1023
if (trustScope ==
CertificateTrustScope
.Append)
1027
else if (trustScope ==
CertificateTrustScope
.Override)
1044
if (trustScope ==
CertificateTrustScope
.Append)
1053
if (trustScope ==
CertificateTrustScope
.None)
1068
if (trustScope ==
CertificateTrustScope
.Override)
ExecutionConfigurationGathererTests.cs (9)
300
Assert.Equal(
CertificateTrustScope
.Append, metadata.Scope);
314
.WithCertificateTrustScope(
CertificateTrustScope
.System)
329
Assert.Equal(
CertificateTrustScope
.System, metadata.Scope);
344
.WithCertificateTrustScope(
CertificateTrustScope
.Override)
359
Assert.Equal(
CertificateTrustScope
.Override, metadata.Scope);
372
.WithCertificateTrustScope(
CertificateTrustScope
.None)
387
Assert.Equal(
CertificateTrustScope
.None, metadata.Scope);
420
.WithCertificateTrustScope(
CertificateTrustScope
.Append)
882
private static Func<
CertificateTrustScope
, CertificateTrustExecutionConfigurationContext> CreateCertificateTrustConfigurationContextFactory()
TestingAppHost1.AppHost (1)
Program.cs (1)
56
.WithCertificateTrustScope(
CertificateTrustScope
.None);