28 references to ConnectionType
Aspire.Dashboard (23)
Authentication\Connection\ConnectionTypeAuthenticationHandler.cs (1)
43
public HashSet<
ConnectionType
> RequiredConnectionTypes { get; set; } = [];
Authentication\Connection\ConnectionTypeMiddleware.cs (3)
15
private readonly List<
ConnectionType
> _connectionTypes;
18
public ConnectionTypeMiddleware(
ConnectionType
[] connectionTypes, ConnectionDelegate next)
32
public required List<
ConnectionType
> ConnectionTypes { get; init; }
Authentication\Connection\IConnectionTypeFeature.cs (1)
11
List<
ConnectionType
> ConnectionTypes { get; }
Authentication\Connection\ListenOptionsConnectionTypeExtensions.cs (1)
10
public static void UseConnectionTypes(this ListenOptions listenOptions, IEnumerable<
ConnectionType
> connectionTypes)
Configuration\EndpointInfo.cs (2)
9
public record EndpointInfo(string Name, BindingAddress Address, HttpProtocols? HttpProtocols, bool RequireCertificate,
ConnectionType
ConnectionType)
11
public static bool TryAddEndpoint(List<EndpointInfo> configuredEndpoints, BindingAddress? address, string name, HttpProtocols? httpProtocols, bool requireCertificate,
ConnectionType
connectionType)
DashboardWebApplication.cs (14)
571
EndpointInfo.TryAddEndpoint(endpoints, fontendUrl, name, httpProtocols: null, requireCertificate: false, connectionType:
ConnectionType
.Frontend);
573
EndpointInfo.TryAddEndpoint(endpoints, dashboardOptions.Otlp.GetGrpcEndpointAddress(), "OtlpGrpc", httpProtocols: HttpProtocols.Http2, requireCertificate: dashboardOptions.Otlp.AuthMode == OtlpAuthMode.ClientCertificate, connectionType:
ConnectionType
.OtlpGrpc);
574
EndpointInfo.TryAddEndpoint(endpoints, dashboardOptions.Otlp.GetHttpEndpointAddress(), "OtlpHttp", httpProtocols: HttpProtocols.Http1AndHttp2, requireCertificate: dashboardOptions.Otlp.AuthMode == OtlpAuthMode.ClientCertificate, connectionType:
ConnectionType
.OtlpHttp);
575
EndpointInfo.TryAddEndpoint(endpoints, dashboardOptions.Mcp.GetEndpointAddress(), "Mcp", httpProtocols: HttpProtocols.Http1AndHttp2, requireCertificate: dashboardOptions.Otlp.AuthMode == OtlpAuthMode.ClientCertificate, connectionType:
ConnectionType
.Mcp);
641
if (!endpointConfiguration.IsHttps && connectionTypes.Contains(
ConnectionType
.Frontend) && endpointConfiguration.ListenOptions.Protocols == HttpProtocols.Http2)
648
foreach (
var
connectionType in connectionTypes)
652
case
ConnectionType
.Frontend:
657
case
ConnectionType
.OtlpGrpc:
660
case
ConnectionType
.OtlpHttp:
663
case
ConnectionType
.Mcp:
707
.AddScheme<ConnectionTypeAuthenticationHandlerOptions, ConnectionTypeAuthenticationHandler>(ConnectionTypeAuthenticationDefaults.AuthenticationSchemeFrontend, o => o.RequiredConnectionTypes = [
ConnectionType
.Frontend])
708
.AddScheme<ConnectionTypeAuthenticationHandlerOptions, ConnectionTypeAuthenticationHandler>(ConnectionTypeAuthenticationDefaults.AuthenticationSchemeOtlp, o => o.RequiredConnectionTypes = [
ConnectionType
.OtlpGrpc,
ConnectionType
.OtlpHttp])
709
.AddScheme<ConnectionTypeAuthenticationHandlerOptions, ConnectionTypeAuthenticationHandler>(ConnectionTypeAuthenticationDefaults.AuthenticationSchemeMcp, o => o.RequiredConnectionTypes = [
ConnectionType
.Mcp])
Model\BrowserSecurityHeadersMiddleware.cs (1)
67
if (feature == null || feature.ConnectionTypes.Contains(
ConnectionType
.Frontend))
Aspire.Dashboard.Tests (5)
BrowserSecurityHeadersMiddlewareTests.cs (5)
66
[InlineData(
ConnectionType
.OtlpGrpc)]
67
[InlineData(
ConnectionType
.OtlpHttp)]
68
[InlineData(
ConnectionType
.Mcp)]
69
public async Task InvokeAsync_Otlp_NotAdded(
ConnectionType
connectionType)
85
public required List<
ConnectionType
> ConnectionTypes { get; init; }