Show / Hide Table of Contents

Class CfnListener

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

Inheritance
object
CfnElement
CfnRefElement
CfnResource
CfnListener
Implements
IInspectable
IListenerRef
IConstruct
IDependable
IEnvironmentAware
Inherited Members
CfnResource.IsCfnResource(object)
CfnResource.AddDeletionOverride(string)
CfnResource.AddDependency(CfnResource)
CfnResource.AddDependsOn(CfnResource)
CfnResource.AddMetadata(string, object)
CfnResource.AddOverride(string, object)
CfnResource.AddPropertyDeletionOverride(string)
CfnResource.AddPropertyOverride(string, object)
CfnResource.ApplyCrossStackReferenceStrength(ReferenceStrength)
CfnResource.ApplyRemovalPolicy(RemovalPolicy?, IRemovalPolicyOptions)
CfnResource.CfnPropertyName(string)
CfnResource.GetAtt(string, ResolutionTypeHint?)
CfnResource.GetMetadata(string)
CfnResource.ObtainDependencies()
CfnResource.ObtainResourceDependencies()
CfnResource.RemoveDependency(CfnResource)
CfnResource.ReplaceDependency(CfnResource, CfnResource)
CfnResource.ShouldSynthesize()
CfnResource.ToString()
CfnResource.ValidateProperties(object)
CfnResource.CfnOptions
CfnResource.CfnResourceType
CfnResource.Env
CfnResource.UpdatedProperites
CfnResource.UpdatedProperties
CfnRefElement.Ref
CfnElement.IsCfnElement(object)
CfnElement.OverrideLogicalId(string)
CfnElement.With(params IMixin[])
CfnElement.CreationStack
CfnElement.LogicalId
CfnElement.Stack
Namespace: Amazon.CDK.AWS.ElasticLoadBalancingV2
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnListener : CfnResource, IInspectable, IListenerRef, IConstruct, IDependable, IEnvironmentAware
Syntax (vb)
Public Class CfnListener Inherits CfnResource Implements IInspectable, IListenerRef, IConstruct, IDependable, IEnvironmentAware
Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.ElasticLoadBalancingV2;

             var cfnListener = new CfnListener(this, "MyCfnListener", new CfnListenerProps {
                 DefaultActions = new [] { new ActionProperty {
                     Type = "type",

                     // the properties below are optional
                     AuthenticateCognitoConfig = new AuthenticateCognitoConfigProperty {
                         UserPoolArn = "userPoolArn",
                         UserPoolClientId = "userPoolClientId",
                         UserPoolDomain = "userPoolDomain",

                         // the properties below are optional
                         AuthenticationRequestExtraParams = new Dictionary<string, string> {
                             { "authenticationRequestExtraParamsKey", "authenticationRequestExtraParams" }
                         },
                         OnUnauthenticatedRequest = "onUnauthenticatedRequest",
                         Scope = "scope",
                         SessionCookieName = "sessionCookieName",
                         SessionTimeout = "sessionTimeout"
                     },
                     AuthenticateOidcConfig = new AuthenticateOidcConfigProperty {
                         AuthorizationEndpoint = "authorizationEndpoint",
                         ClientId = "clientId",
                         Issuer = "issuer",
                         TokenEndpoint = "tokenEndpoint",
                         UserInfoEndpoint = "userInfoEndpoint",

                         // the properties below are optional
                         AuthenticationRequestExtraParams = new Dictionary<string, string> {
                             { "authenticationRequestExtraParamsKey", "authenticationRequestExtraParams" }
                         },
                         ClientSecret = "clientSecret",
                         OnUnauthenticatedRequest = "onUnauthenticatedRequest",
                         Scope = "scope",
                         SessionCookieName = "sessionCookieName",
                         SessionTimeout = "sessionTimeout",
                         UseExistingClientSecret = false
                     },
                     FixedResponseConfig = new FixedResponseConfigProperty {
                         StatusCode = "statusCode",

                         // the properties below are optional
                         ContentType = "contentType",
                         MessageBody = "messageBody"
                     },
                     ForwardConfig = new ForwardConfigProperty {
                         TargetGroups = new [] { new TargetGroupTupleProperty {
                             TargetGroupArn = "targetGroupArn",
                             Weight = 123
                         } },
                         TargetGroupStickinessConfig = new TargetGroupStickinessConfigProperty {
                             DurationSeconds = 123,
                             Enabled = false
                         }
                     },
                     JwtValidationConfig = new JwtValidationConfigProperty {
                         Issuer = "issuer",
                         JwksEndpoint = "jwksEndpoint",

                         // the properties below are optional
                         AdditionalClaims = new [] { new JwtValidationActionAdditionalClaimProperty {
                             Format = "format",
                             Name = "name",
                             Values = new [] { "values" }
                         } }
                     },
                     Order = 123,
                     RedirectConfig = new RedirectConfigProperty {
                         StatusCode = "statusCode",

                         // the properties below are optional
                         Host = "host",
                         Path = "path",
                         Port = "port",
                         Protocol = "protocol",
                         Query = "query"
                     },
                     TargetGroupArn = "targetGroupArn"
                 } },
                 LoadBalancerArn = "loadBalancerArn",

                 // the properties below are optional
                 AlpnPolicy = new [] { "alpnPolicy" },
                 Certificates = new [] { new CertificateProperty {
                     CertificateArn = "certificateArn"
                 } },
                 ListenerAttributes = new [] { new ListenerAttributeProperty {
                     Key = "key",
                     Value = "value"
                 } },
                 MutualAuthentication = new MutualAuthenticationProperty {
                     AdvertiseTrustStoreCaNames = "advertiseTrustStoreCaNames",
                     IgnoreClientCertificateExpiry = false,
                     Mode = "mode",
                     TrustStoreArn = "trustStoreArn"
                 },
                 Port = 123,
                 Protocol = "protocol",
                 SslPolicy = "sslPolicy"
             });

Synopsis

Constructors

CfnListener(Construct, string, ICfnListenerProps)

Create a new AWS::ElasticLoadBalancingV2::Listener.

Properties

AlpnPolicy

[TLS listener] The name of the Application-Layer Protocol Negotiation (ALPN) policy.

AttrListenerArn

The Amazon Resource Name (ARN) of the listener.

CFN_RESOURCE_TYPE_NAME

The CloudFormation resource type name for this resource class.

Certificates

The default SSL server certificate for a secure listener.

CfnProperties

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

CfnPropertyNames

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

DefaultActions

The actions for the default rule.

ListenerAttributes

The listener attributes.

ListenerRef

A reference to a Listener resource.

LoadBalancerArn

The Amazon Resource Name (ARN) of the load balancer.

MutualAuthentication

The mutual authentication configuration information.

Port

The port on which the load balancer is listening.

Protocol

The protocol for connections from clients to the load balancer.

SslPolicy

[HTTPS and TLS listeners] The security policy that defines which protocols and ciphers are supported.

Methods

ArnForListener(IListenerRef)

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

Inspect(TreeInspector)

Examines the CloudFormation resource and discloses attributes.

IsCfnListener(object)

Checks whether the given object is a CfnListener.

RenderProperties(IDictionary<string, object>)

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

Constructors

CfnListener(Construct, string, ICfnListenerProps)

Create a new AWS::ElasticLoadBalancingV2::Listener.

public CfnListener(Construct scope, string id, ICfnListenerProps props)
Parameters
scope Construct

Scope in which this resource is defined.

id string

Construct identifier for this resource (unique in its scope).

props ICfnListenerProps

Resource properties.

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

Properties

AlpnPolicy

[TLS listener] The name of the Application-Layer Protocol Negotiation (ALPN) policy.

public virtual string[]? AlpnPolicy { get; set; }
Property Value

string[]

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

AttrListenerArn

The Amazon Resource Name (ARN) of the listener.

public virtual string AttrListenerArn { get; }
Property Value

string

Remarks

CloudformationAttribute: ListenerArn

CFN_RESOURCE_TYPE_NAME

The CloudFormation resource type name for this resource class.

public static string CFN_RESOURCE_TYPE_NAME { get; }
Property Value

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

Certificates

The default SSL server certificate for a secure listener.

public virtual object? Certificates { get; set; }
Property Value

object

Remarks

Type union: either IResolvable or (either IResolvable or CfnListener.ICertificateProperty)[]

CfnProperties

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

protected override IDictionary<string, object> CfnProperties { get; }
Property Value

IDictionary<string, object>

Overrides
CfnResource.CfnProperties
Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

CfnPropertyNames

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

protected override IDictionary<string, string> CfnPropertyNames { get; }
Property Value

IDictionary<string, string>

Overrides
CfnResource.CfnPropertyNames
Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

DefaultActions

The actions for the default rule.

public virtual object DefaultActions { get; set; }
Property Value

object

Remarks

You cannot define a condition for a default rule.

Type union: either IResolvable or (either IResolvable or CfnListener.IActionProperty)[]

ListenerAttributes

The listener attributes.

public virtual object? ListenerAttributes { get; set; }
Property Value

object

Remarks

Type union: either IResolvable or (either IResolvable or CfnListener.IListenerAttributeProperty)[]

ListenerRef

A reference to a Listener resource.

public virtual IListenerReference ListenerRef { get; }
Property Value

IListenerReference

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

LoadBalancerArn

The Amazon Resource Name (ARN) of the load balancer.

public virtual string LoadBalancerArn { get; set; }
Property Value

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

MutualAuthentication

The mutual authentication configuration information.

public virtual object? MutualAuthentication { get; set; }
Property Value

object

Remarks

Type union: either IResolvable or CfnListener.IMutualAuthenticationProperty

Port

The port on which the load balancer is listening.

public virtual double? Port { get; set; }
Property Value

double?

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

Protocol

The protocol for connections from clients to the load balancer.

public virtual string? Protocol { get; set; }
Property Value

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

SslPolicy

[HTTPS and TLS listeners] The security policy that defines which protocols and ciphers are supported.

public virtual string? SslPolicy { get; set; }
Property Value

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

Methods

ArnForListener(IListenerRef)

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

public static string ArnForListener(IListenerRef resource)
Parameters
resource IListenerRef
Returns

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.ElasticLoadBalancingV2;

             var cfnListener = new CfnListener(this, "MyCfnListener", new CfnListenerProps {
                 DefaultActions = new [] { new ActionProperty {
                     Type = "type",

                     // the properties below are optional
                     AuthenticateCognitoConfig = new AuthenticateCognitoConfigProperty {
                         UserPoolArn = "userPoolArn",
                         UserPoolClientId = "userPoolClientId",
                         UserPoolDomain = "userPoolDomain",

                         // the properties below are optional
                         AuthenticationRequestExtraParams = new Dictionary<string, string> {
                             { "authenticationRequestExtraParamsKey", "authenticationRequestExtraParams" }
                         },
                         OnUnauthenticatedRequest = "onUnauthenticatedRequest",
                         Scope = "scope",
                         SessionCookieName = "sessionCookieName",
                         SessionTimeout = "sessionTimeout"
                     },
                     AuthenticateOidcConfig = new AuthenticateOidcConfigProperty {
                         AuthorizationEndpoint = "authorizationEndpoint",
                         ClientId = "clientId",
                         Issuer = "issuer",
                         TokenEndpoint = "tokenEndpoint",
                         UserInfoEndpoint = "userInfoEndpoint",

                         // the properties below are optional
                         AuthenticationRequestExtraParams = new Dictionary<string, string> {
                             { "authenticationRequestExtraParamsKey", "authenticationRequestExtraParams" }
                         },
                         ClientSecret = "clientSecret",
                         OnUnauthenticatedRequest = "onUnauthenticatedRequest",
                         Scope = "scope",
                         SessionCookieName = "sessionCookieName",
                         SessionTimeout = "sessionTimeout",
                         UseExistingClientSecret = false
                     },
                     FixedResponseConfig = new FixedResponseConfigProperty {
                         StatusCode = "statusCode",

                         // the properties below are optional
                         ContentType = "contentType",
                         MessageBody = "messageBody"
                     },
                     ForwardConfig = new ForwardConfigProperty {
                         TargetGroups = new [] { new TargetGroupTupleProperty {
                             TargetGroupArn = "targetGroupArn",
                             Weight = 123
                         } },
                         TargetGroupStickinessConfig = new TargetGroupStickinessConfigProperty {
                             DurationSeconds = 123,
                             Enabled = false
                         }
                     },
                     JwtValidationConfig = new JwtValidationConfigProperty {
                         Issuer = "issuer",
                         JwksEndpoint = "jwksEndpoint",

                         // the properties below are optional
                         AdditionalClaims = new [] { new JwtValidationActionAdditionalClaimProperty {
                             Format = "format",
                             Name = "name",
                             Values = new [] { "values" }
                         } }
                     },
                     Order = 123,
                     RedirectConfig = new RedirectConfigProperty {
                         StatusCode = "statusCode",

                         // the properties below are optional
                         Host = "host",
                         Path = "path",
                         Port = "port",
                         Protocol = "protocol",
                         Query = "query"
                     },
                     TargetGroupArn = "targetGroupArn"
                 } },
                 LoadBalancerArn = "loadBalancerArn",

                 // the properties below are optional
                 AlpnPolicy = new [] { "alpnPolicy" },
                 Certificates = new [] { new CertificateProperty {
                     CertificateArn = "certificateArn"
                 } },
                 ListenerAttributes = new [] { new ListenerAttributeProperty {
                     Key = "key",
                     Value = "value"
                 } },
                 MutualAuthentication = new MutualAuthenticationProperty {
                     AdvertiseTrustStoreCaNames = "advertiseTrustStoreCaNames",
                     IgnoreClientCertificateExpiry = false,
                     Mode = "mode",
                     TrustStoreArn = "trustStoreArn"
                 },
                 Port = 123,
                 Protocol = "protocol",
                 SslPolicy = "sslPolicy"
             });

Inspect(TreeInspector)

Examines the CloudFormation resource and discloses attributes.

public virtual void Inspect(TreeInspector inspector)
Parameters
inspector TreeInspector

tree inspector to collect and process attributes.

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

IsCfnListener(object)

Checks whether the given object is a CfnListener.

public static bool IsCfnListener(object x)
Parameters
x object
Returns

bool

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

RenderProperties(IDictionary<string, object>)

Specifies a listener for an Application Load Balancer, Network Load Balancer, or Gateway Load Balancer.

protected override IDictionary<string, object> RenderProperties(IDictionary<string, object> props)
Parameters
props IDictionary<string, object>
Returns

IDictionary<string, object>

Overrides
CfnResource.RenderProperties(IDictionary<string, object>)
Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-elasticloadbalancingv2-listener.html

CloudformationResource: AWS::ElasticLoadBalancingV2::Listener

ExampleMetadata: fixture=_generated

Implements

IInspectable
IListenerRef
Constructs.IConstruct
Constructs.IDependable
IEnvironmentAware
Back to top Generated by DocFX