All Products
Search
Document Center

Resource Orchestration Service:ALIYUN::GA::Listener

Last Updated:Jul 24, 2026

ALIYUN::GA::Listener creates a listener.

Syntax

{
  "Type": "ALIYUN::GA::Listener",
  "Properties": {
    "Description": String,
    "PortRanges": List,
    "Protocol": String,
    "AcceleratorId": String,
    "Name": String,
    "ClientAffinity": String,
    "Certificates": List,
    "SecurityPolicyId": String,
    "ProxyProtocol": Boolean,
    "XForwardedForConfig": Map,
    "RequestTimeout": Integer,
    "IdleTimeout": Integer,
    "HttpVersion": String,
    "Type": String
  }
}

Properties

Property

Type

Required

Editable

Description

Constraints

AcceleratorId

String

Yes

No

The ID of the Global Accelerator instance.

None

PortRanges

List

Yes

Yes

The listening ports.

A maximum of 10 listening ports are supported.

For more information, see PortRanges property.

Protocol

String

Yes

Yes

The network transport protocol for the listener.

Valid values:

  • tcp: TCP.

  • udp: UDP.

  • http: HTTP.

  • https: HTTPS.

Certificates

List

No

Yes

The SSL certificate.

For more information, see Certificates property.

ClientAffinity

String

No

Yes

The client affinity setting.

Valid values:

  • None (default): No client affinity. Requests from the same client are not guaranteed to be directed to the same endpoint.

  • SOURCE_IP: Client affinity is maintained. When a client accesses a stateful application, all requests from that client are directed to the same endpoint, regardless of the source port or protocol.

Description

String

No

Yes

The description of the listener.

None

HttpVersion

String

No

Yes

The maximum HTTP version.

Valid values:

  • http3: HTTP/3.

  • http2 (default): HTTP/2.

  • http1.1: HTTP/1.1.

Note

This parameter is supported only by HTTPS listeners.

IdleTimeout

Integer

No

Yes

The idle connection timeout period.

Unit: seconds. Valid values and defaults by protocol:

  • TCP: 10 to 900 (default: 900).

  • UDP: 10 to 20 (default: 20).

  • HTTP/HTTPS: 1 to 60 (default: 15).

Name

String

No

Yes

The name of the listener.

The name must be 2 to 128 characters long. It must start with a letter or a Chinese character. It can contain letters, Chinese characters, digits, underscores (_), and hyphens (-).

ProxyProtocol

Boolean

No

Yes

Whether to preserve the source IP address of the client.

Valid values:

  • true: Preserves the source IP address of the client.

    After this feature is enabled, backend services can view the source IP addresses of clients.

  • false (default): Does not preserve the source IP address of the client.

Note

This parameter will no longer be configured using listener APIs. Configure this parameter using the APIs for endpoint groups.

For more information about ProxyProtocol, see CreateEndpointGroup and UpdateEndpointGroup.

RequestTimeout

Integer

No

Yes

The request timeout period.

Unit: seconds. Valid values: 1 to 180. Default value: 60.

Note

This parameter takes effect only for HTTP or HTTPS listeners. If the backend server does not respond within the timeout period, Global Accelerator stops waiting and returns HTTP 504 to the client.

SecurityPolicyId

String

No

Yes

The ID of the security policy.

Valid values:

  • tls_cipher_policy_1_0

    • Supported TLS versions: TLSv1.0, TLSv1.1, and TLSv1.2.

    • Supported cipher suites: ECDHE-RSA-AES128-GCM-SHA256, ECDHE-RSA-AES256-GCM-SHA384, ECDHE-RSA-AES128-SHA256, ECDHE-RSA-AES256-SHA384, AES128-GCM-SHA256, AES256-GCM-SHA384, AES128-SHA256, AES256-SHA256, ECDHE-RSA-AES128-SHA, ECDHE-RSA-AES256-SHA, AES128-SHA, AES256-SHA, and DES-CBC3-SHA.

  • tls_cipher_policy_1_1

    • Supported TLS versions: TLSv1.1 and TLSv1.2.

    • Supported cipher suites: ECDHE-RSA-AES128-GCM-SHA256, ECDHE-RSA-AES256-GCM-SHA384, ECDHE-RSA-AES128-SHA256, ECDHE-RSA-AES256-SHA384, AES128-GCM-SHA256, AES256-GCM-SHA384, AES128-SHA256, AES256-SHA256, ECDHE-RSA-AES128-SHA, ECDHE-RSA-AES256-SHA, AES128-SHA, AES256-SHA, and DES-CBC3-SHA.

  • tls_cipher_policy_1_2

    • Supported TLS version: TLSv1.2.

    • Supported cipher suites: ECDHE-RSA-AES128-GCM-SHA256, ECDHE-RSA-AES256-GCM-SHA384, ECDHE-RSA-AES128-SHA256, ECDHE-RSA-AES256-SHA384, AES128-GCM-SHA256, AES256-GCM-SHA384, AES128-SHA256, AES256-SHA256, ECDHE-RSA-AES128-SHA, ECDHE-RSA-AES256-SHA, AES128-SHA, AES256-SHA, and DES-CBC3-SHA.

  • tls_cipher_policy_1_2_strict

    • Supported TLS version: TLSv1.2.

    • Supported cipher suites: ECDHE-RSA-AES128-GCM-SHA256, ECDHE-RSA-AES256-GCM-SHA384, ECDHE-RSA-AES128-SHA256, ECDHE-RSA-AES256-SHA384, ECDHE-RSA-AES128-SHA, and ECDHE-RSA-AES256-SHA.

  • tls_cipher_policy_1_2_strict_with_1_3

    • Supported TLS versions: TLSv1.2 and TLSv1.3.

    • Supported cipher suites: TLS_AES_128_GCM_SHA256, TLS_AES_256_GCM_SHA384, TLS_CHACHA20_POLY1305_SHA256, TLS_AES_128_CCM_SHA256, TLS_AES_128_CCM_8_SHA256, ECDHE-ECDSA-AES128-GCM-SHA256, ECDHE-ECDSA-AES256-GCM-SHA384, ECDHE-ECDSA-AES128-SHA256, ECDHE-ECDSA-AES256-SHA384, ECDHE-RSA-AES128-GCM-SHA256, ECDHE-RSA-AES256-GCM-SHA384, ECDHE-RSA-AES128-SHA256, ECDHE-RSA-AES256-SHA384, ECDHE-ECDSA-AES128-SHA, ECDHE-ECDSA-AES256-SHA, ECDHE-RSA-AES128-SHA, and ECDHE-RSA-AES256-SHA.

Note

This parameter is supported only by HTTPS listeners.

Type

String

No

No

The routing type of the listener.

Valid values:

  • Standard (default): intelligent routing.

  • CustomRouting: custom routing.

Note

The custom routing listener feature is in preview. To use this feature, contact your Alibaba Cloud account manager.

A standard Global Accelerator instance does not support listeners of two routing types at the same time. The routing type cannot be changed after the listener is configured.

XForwardedForConfig

Map

No

Yes

XForward field configuration.

For more information, see XForwardedForConfig properties.

Certificates syntax

"Certificates": [
 {
    "Id": String
  }
]

Certificates properties

Property

Type

Required

Editable

Description

Constraints

Id

String

Yes

Yes

The ID of the SSL certificate.

Note

This parameter is required only for HTTPS listeners.

XForwardedForConfig syntax

"XForwardedForConfig": {
 "XRealIpEnabled": Boolean,
 "XForwardedForGaIdEnabled": Boolean,
 "XForwardedForGaApEnabled": Boolean,
 "XForwardedForPortEnabled": Boolean,
 "XForwardedForProtoEnabled": Boolean
}

XForwardedForConfig properties

Property

Type

Required

Editable

Description

Constraints

XForwardedForGaApEnabled

Boolean

No

Yes

Whether to use the GA-AP header to retrieve the acceleration region information.

Valid values:

  • true: Uses the GA-AP header to retrieve the acceleration region information.

  • false (default): Does not use the GA-AP header to retrieve the acceleration region information.

Note

This parameter is supported only by HTTP and HTTPS listeners.

XForwardedForGaIdEnabled

Boolean

No

Yes

Whether to use the GA-ID header to retrieve the ID of the Global Accelerator instance.

Valid values:

  • true: Uses the GA-ID header to retrieve the ID of the Global Accelerator instance.

  • false (default): Does not use the GA-ID header to retrieve the ID of the Global Accelerator instance.

Note

This parameter is supported only by HTTP and HTTPS listeners.

XForwardedForPortEnabled

Boolean

No

Yes

Whether to use the GA-X-Forward-Port header to retrieve the listening port of the Global Accelerator instance.

Valid values:

  • true: Uses the GA-X-Forward-Port header to retrieve the listening port of the Global Accelerator instance.

  • false (default): Does not use the GA-X-Forward-Port header to retrieve the listening port of the Global Accelerator instance.

Note

This parameter is supported only by HTTP and HTTPS listeners.

XForwardedForProtoEnabled

Boolean

No

Yes

Whether to use the GA-X-Forward-Proto header to retrieve the listening protocol of the Global Accelerator instance.

Valid values:

  • true: Uses the GA-X-Forward-Proto header to retrieve the listening protocol of the Global Accelerator instance.

  • false (default): Does not use the GA-X-Forward-Proto header to retrieve the listening protocol of the Global Accelerator instance.

Note

This parameter is supported only by HTTP and HTTPS listeners.

XRealIpEnabled

Boolean

No

Yes

Whether to use the X-Real-IP header to retrieve the real IP addresses of clients.

Valid values:

  • true: Uses the X-Real-IP header to retrieve the real IP addresses of clients.

  • false (default): Does not use the X-Real-IP header to retrieve the real IP addresses of clients.

Note

This parameter is supported only by HTTP and HTTPS listeners.

PortRanges syntax

"PortRanges": [
  {
    "FromPort": Integer,
    "ToPort": Integer
  }
]

PortRanges properties

Property

Type

Required

Editable

Description

Constraints

FromPort

Integer

Yes

Yes

The first port in the listening port range used to receive and forward requests to endpoints.

None

ToPort

Integer

Yes

Yes

The last port in the listening port range used to receive and forward requests to endpoints.

None

Return values

Fn::GetAtt

  • ListenerId: The ID of the listener.

Examples

Scenario 1: Create a TCP listener for a GA instance for Layer-4 acceleration.

ROSTemplateFormatVersion: '2015-09-01'
Description:
  zh-cn: 为全球加速实例创建TCP监听,用于四层协议加速。
  en: Create a TCP listener for a GA instance for Layer-4 acceleration.
Parameters:
  AcceleratorId:
    Type: String
    Label:
      zh-cn: 全球加速实例ID
      en: Accelerator ID
    Description:
      zh-cn: 已有的全球加速实例ID。
      en: The ID of an existing Global Accelerator instance.
  ListenerName:
    Type: String
    Label:
      zh-cn: 监听名称
      en: Listener Name
    Description:
      zh-cn: >-
        监听器的名称,2~128个字符,
        以字母或汉字开头。
      en: >-
        Listener name, 2-128 characters,
        starting with a letter or Chinese character.
    Default: tcp-listener
  FromPort:
    Type: Number
    Label:
      zh-cn: 起始监听端口
      en: From Port
    Description:
      zh-cn: 监听端口范围的起始端口。
      en: The start port of the listening port range.
    Default: 9000
    MinValue: 1
    MaxValue: 65499
  ToPort:
    Type: Number
    Label:
      zh-cn: 结束监听端口
      en: To Port
    Description:
      zh-cn: 监听端口范围的结束端口,与起始端口相同时表示监听单个端口。
      en: The end port of the listening port range. Same as from-port for a single port.
    Default: 9000
    MinValue: 1
    MaxValue: 65499
Resources:
  Listener:
    Type: ALIYUN::GA::Listener
    Properties:
      AcceleratorId:
        Ref: AcceleratorId
      Name:
        Ref: ListenerName
      Protocol: tcp
      PortRanges:
        - FromPort:
            Ref: FromPort
          ToPort:
            Ref: ToPort
      ClientAffinity: SOURCE_IP
Outputs:
  ListenerId:
    Label:
      zh-cn: 监听ID
      en: Listener ID
    Description:
      zh-cn: 创建成功的监听器唯一标识。
      en: The unique identifier of the created listener.
    Value:
      Fn::GetAtt:
        - Listener
        - ListenerId
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Description": {
    "zh-cn": "为全球加速实例创建TCP监听,用于四层协议加速。",
    "en": "Create a TCP listener for a GA instance for Layer-4 acceleration."
  },
  "Parameters": {
    "AcceleratorId": {
      "Type": "String",
      "Label": {
        "zh-cn": "全球加速实例ID",
        "en": "Accelerator ID"
      },
      "Description": {
        "zh-cn": "已有的全球加速实例ID。",
        "en": "The ID of an existing Global Accelerator instance."
      }
    },
    "ListenerName": {
      "Type": "String",
      "Label": {
        "zh-cn": "监听名称",
        "en": "Listener Name"
      },
      "Description": {
        "zh-cn": "监听器的名称,2~128个字符,以字母或汉字开头。",
        "en": "Listener name, 2-128 characters, starting with a letter or Chinese character."
      },
      "Default": "tcp-listener"
    },
    "FromPort": {
      "Type": "Number",
      "Label": {
        "zh-cn": "起始监听端口",
        "en": "From Port"
      },
      "Description": {
        "zh-cn": "监听端口范围的起始端口。",
        "en": "The start port of the listening port range."
      },
      "Default": 9000,
      "MinValue": 1,
      "MaxValue": 65499
    },
    "ToPort": {
      "Type": "Number",
      "Label": {
        "zh-cn": "结束监听端口",
        "en": "To Port"
      },
      "Description": {
        "zh-cn": "监听端口范围的结束端口,与起始端口相同时表示监听单个端口。",
        "en": "The end port of the listening port range. Same as from-port for a single port."
      },
      "Default": 9000,
      "MinValue": 1,
      "MaxValue": 65499
    }
  },
  "Resources": {
    "Listener": {
      "Type": "ALIYUN::GA::Listener",
      "Properties": {
        "AcceleratorId": {
          "Ref": "AcceleratorId"
        },
        "Name": {
          "Ref": "ListenerName"
        },
        "Protocol": "tcp",
        "PortRanges": [
          {
            "FromPort": {
              "Ref": "FromPort"
            },
            "ToPort": {
              "Ref": "ToPort"
            }
          }
        ],
        "ClientAffinity": "SOURCE_IP"
      }
    }
  },
  "Outputs": {
    "ListenerId": {
      "Label": {
        "zh-cn": "监听ID",
        "en": "Listener ID"
      },
      "Description": {
        "zh-cn": "创建成功的监听器唯一标识。",
        "en": "The unique identifier of the created listener."
      },
      "Value": {
        "Fn::GetAtt": [
          "Listener",
          "ListenerId"
        ]
      }
    }
  }
}

Scenario 2: Create an HTTP listener with XForwardedFor config to obtain the client real IP and acceleration information.

ROSTemplateFormatVersion: '2015-09-01'
Description:
  zh-cn: 创建HTTP监听并配置XForwardedFor头,获取客户端真实IP和加速信息。
  en: Create an HTTP listener with XForwardedFor config for client IP and GA info.
Parameters:
  AcceleratorId:
    Type: String
    Label:
      zh-cn: 全球加速实例ID
      en: Accelerator ID
    Description:
      zh-cn: 已有的全球加速实例ID。
      en: The ID of an existing Global Accelerator instance.
  ListenerName:
    Type: String
    Label:
      zh-cn: 监听名称
      en: Listener Name
    Description:
      zh-cn: 监听器的名称。
      en: The name of the listener.
    Default: http-listener
Resources:
  Listener:
    Type: ALIYUN::GA::Listener
    Properties:
      AcceleratorId:
        Ref: AcceleratorId
      Name:
        Ref: ListenerName
      Description: HTTP listener with XForwardedFor enabled to obtain client and acceleration information.
      Protocol: http
      PortRanges:
        - FromPort: 80
          ToPort: 80
        - FromPort: 8080
          ToPort: 8080
      ClientAffinity: NONE
      XForwardedForConfig:
        XRealIpEnabled: true
        XForwardedForGaIdEnabled: true
        XForwardedForGaApEnabled: true
        XForwardedForPortEnabled: true
        XForwardedForProtoEnabled: true
Outputs:
  ListenerId:
    Label:
      zh-cn: 监听ID
      en: Listener ID
    Description:
      zh-cn: 创建成功的HTTP监听器唯一标识。
      en: The unique identifier of the created HTTP listener.
    Value:
      Fn::GetAtt:
        - Listener
        - ListenerId
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Description": {
    "zh-cn": "创建HTTP监听并配置XForwardedFor头,获取客户端真实IP和加速信息。",
    "en": "Create an HTTP listener with XForwardedFor config for client IP and GA info."
  },
  "Parameters": {
    "AcceleratorId": {
      "Type": "String",
      "Label": {
        "zh-cn": "全球加速实例ID",
        "en": "Accelerator ID"
      },
      "Description": {
        "zh-cn": "已有的全球加速实例ID。",
        "en": "The ID of an existing Global Accelerator instance."
      }
    },
    "ListenerName": {
      "Type": "String",
      "Label": {
        "zh-cn": "监听名称",
        "en": "Listener Name"
      },
      "Description": {
        "zh-cn": "监听器的名称。",
        "en": "The name of the listener."
      },
      "Default": "http-listener"
    }
  },
  "Resources": {
    "Listener": {
      "Type": "ALIYUN::GA::Listener",
      "Properties": {
        "AcceleratorId": {
          "Ref": "AcceleratorId"
        },
        "Name": {
          "Ref": "ListenerName"
        },
        "Description": "HTTP listener with XForwardedFor enabled to obtain client and acceleration information.",
        "Protocol": "http",
        "PortRanges": [
          {
            "FromPort": 80,
            "ToPort": 80
          },
          {
            "FromPort": 8080,
            "ToPort": 8080
          }
        ],
        "ClientAffinity": "NONE",
        "XForwardedForConfig": {
          "XRealIpEnabled": true,
          "XForwardedForGaIdEnabled": true,
          "XForwardedForGaApEnabled": true,
          "XForwardedForPortEnabled": true,
          "XForwardedForProtoEnabled": true
        }
      }
    }
  },
  "Outputs": {
    "ListenerId": {
      "Label": {
        "zh-cn": "监听ID",
        "en": "Listener ID"
      },
      "Description": {
        "zh-cn": "创建成功的HTTP监听器唯一标识。",
        "en": "The unique identifier of the created HTTP listener."
      },
      "Value": {
        "Fn::GetAtt": [
          "Listener",
          "ListenerId"
        ]
      }
    }
  }
}

Scenario 3: Create an HTTPS listener with an SSL certificate and a TLS security policy for secure global acceleration.

ROSTemplateFormatVersion: '2015-09-01'
Description:
  zh-cn: 创建HTTPS监听并配置SSL证书和TLS安全策略,实现安全的全球加速。
  en: Create an HTTPS listener with SSL certificate and TLS security policy.
Parameters:
  AcceleratorId:
    Type: String
    Label:
      zh-cn: 全球加速实例ID
      en: Accelerator ID
    Description:
      zh-cn: 已有的全球加速实例ID。
      en: The ID of an existing Global Accelerator instance.
  ListenerName:
    Type: String
    Label:
      zh-cn: 监听名称
      en: Listener Name
    Description:
      zh-cn: HTTPS监听器的名称。
      en: The name of the HTTPS listener.
    Default: https-listener
  CertificateId:
    Type: String
    Label:
      zh-cn: SSL证书ID
      en: SSL Certificate ID
    Description:
      zh-cn: >-
        SSL证书的唯一标识,可在SSL证书服务控制台获取。
        证书需与加速域名匹配。
      en: >-
        The SSL certificate ID, available in the SSL Certificates Service console.
        The certificate must match the accelerated domain.
  SecurityPolicyId:
    Type: String
    Label:
      zh-cn: TLS安全策略
      en: TLS Security Policy
    Description:
      zh-cn: >-
        TLS安全策略,决定支持的TLS版本和加密算法套件。
        tls_cipher_policy_1_2_strict_with_1_3:TLSv1.2+1.3,最高安全性(推荐)。
        tls_cipher_policy_1_2_strict:仅TLSv1.2严格模式。
        tls_cipher_policy_1_2:TLSv1.2标准模式。
        tls_cipher_policy_1_0:TLSv1.0+1.1+1.2,兼容性最佳。
      en: >-
        TLS security policy controlling supported TLS versions and cipher suites.
        tls_cipher_policy_1_2_strict_with_1_3: TLSv1.2+1.3, highest security (recommended).
    Default: tls_cipher_policy_1_2_strict_with_1_3
    AllowedValues:
      - tls_cipher_policy_1_2_strict_with_1_3
      - tls_cipher_policy_1_2_strict
      - tls_cipher_policy_1_2
      - tls_cipher_policy_1_1
      - tls_cipher_policy_1_0
  ClientAffinity:
    Type: String
    Label:
      zh-cn: 客户端亲和性
      en: Client Affinity
    Description:
      zh-cn: >-
        SOURCE_IP:保持客户端亲和性,来自同一客户端的请求始终转发到同一终端节点。
        NONE:不保持亲和性,请求可能转发到不同终端节点。
      en: >-
        SOURCE_IP: maintain client affinity, same client always goes to same endpoint.
        NONE: no affinity, requests may go to different endpoints.
    Default: SOURCE_IP
    AllowedValues:
      - SOURCE_IP
      - NONE
Resources:
  Listener:
    Type: ALIYUN::GA::Listener
    Properties:
      AcceleratorId:
        Ref: AcceleratorId
      Name:
        Ref: ListenerName
      Description: HTTPS secure listener with an SSL certificate and a TLS security policy configured.
      Protocol: https
      PortRanges:
        - FromPort: 443
          ToPort: 443
      ClientAffinity:
        Ref: ClientAffinity
      Certificates:
        - Id:
            Ref: CertificateId
      SecurityPolicyId:
        Ref: SecurityPolicyId
      XForwardedForConfig:
        XRealIpEnabled: true
        XForwardedForGaIdEnabled: true
        XForwardedForGaApEnabled: false
        XForwardedForPortEnabled: true
        XForwardedForProtoEnabled: true
Outputs:
  ListenerId:
    Label:
      zh-cn: 监听ID
      en: Listener ID
    Description:
      zh-cn: 创建成功的HTTPS监听器唯一标识。
      en: The unique identifier of the created HTTPS listener.
    Value:
      Fn::GetAtt:
        - Listener
        - ListenerId
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Description": {
    "zh-cn": "创建HTTPS监听并配置SSL证书和TLS安全策略,实现安全的全球加速。",
    "en": "Create an HTTPS listener with SSL certificate and TLS security policy."
  },
  "Parameters": {
    "AcceleratorId": {
      "Type": "String",
      "Label": {
        "zh-cn": "全球加速实例ID",
        "en": "Accelerator ID"
      },
      "Description": {
        "zh-cn": "已有的全球加速实例ID。",
        "en": "The ID of an existing Global Accelerator instance."
      }
    },
    "ListenerName": {
      "Type": "String",
      "Label": {
        "zh-cn": "监听名称",
        "en": "Listener Name"
      },
      "Description": {
        "zh-cn": "HTTPS监听器的名称。",
        "en": "The name of the HTTPS listener."
      },
      "Default": "https-listener"
    },
    "CertificateId": {
      "Type": "String",
      "Label": {
        "zh-cn": "SSL证书ID",
        "en": "SSL Certificate ID"
      },
      "Description": {
        "zh-cn": "SSL证书的唯一标识,可在SSL证书服务控制台获取。证书需与加速域名匹配。",
        "en": "The SSL certificate ID, available in the SSL Certificates Service console. The certificate must match the accelerated domain."
      }
    },
    "SecurityPolicyId": {
      "Type": "String",
      "Label": {
        "zh-cn": "TLS安全策略",
        "en": "TLS Security Policy"
      },
      "Description": {
        "zh-cn": "TLS安全策略,决定支持的TLS版本和加密算法套件。tls_cipher_policy_1_2_strict_with_1_3:TLSv1.2+1.3,最高安全性(推荐)。tls_cipher_policy_1_2_strict:仅TLSv1.2严格模式。tls_cipher_policy_1_2:TLSv1.2标准模式。tls_cipher_policy_1_0:TLSv1.0+1.1+1.2,兼容性最佳。",
        "en": "TLS security policy controlling supported TLS versions and cipher suites. tls_cipher_policy_1_2_strict_with_1_3: TLSv1.2+1.3, highest security (recommended)."
      },
      "Default": "tls_cipher_policy_1_2_strict_with_1_3",
      "AllowedValues": [
        "tls_cipher_policy_1_2_strict_with_1_3",
        "tls_cipher_policy_1_2_strict",
        "tls_cipher_policy_1_2",
        "tls_cipher_policy_1_1",
        "tls_cipher_policy_1_0"
      ]
    },
    "ClientAffinity": {
      "Type": "String",
      "Label": {
        "zh-cn": "客户端亲和性",
        "en": "Client Affinity"
      },
      "Description": {
        "zh-cn": "SOURCE_IP:保持客户端亲和性,来自同一客户端的请求始终转发到同一终端节点。NONE:不保持亲和性,请求可能转发到不同终端节点。",
        "en": "SOURCE_IP: maintain client affinity, same client always goes to same endpoint. NONE: no affinity, requests may go to different endpoints."
      },
      "Default": "SOURCE_IP",
      "AllowedValues": [
        "SOURCE_IP",
        "NONE"
      ]
    }
  },
  "Resources": {
    "Listener": {
      "Type": "ALIYUN::GA::Listener",
      "Properties": {
        "AcceleratorId": {
          "Ref": "AcceleratorId"
        },
        "Name": {
          "Ref": "ListenerName"
        },
        "Description": "HTTPS secure listener with an SSL certificate and a TLS security policy configured.",
        "Protocol": "https",
        "PortRanges": [
          {
            "FromPort": 443,
            "ToPort": 443
          }
        ],
        "ClientAffinity": {
          "Ref": "ClientAffinity"
        },
        "Certificates": [
          {
            "Id": {
              "Ref": "CertificateId"
            }
          }
        ],
        "SecurityPolicyId": {
          "Ref": "SecurityPolicyId"
        },
        "XForwardedForConfig": {
          "XRealIpEnabled": true,
          "XForwardedForGaIdEnabled": true,
          "XForwardedForGaApEnabled": false,
          "XForwardedForPortEnabled": true,
          "XForwardedForProtoEnabled": true
        }
      }
    }
  },
  "Outputs": {
    "ListenerId": {
      "Label": {
        "zh-cn": "监听ID",
        "en": "Listener ID"
      },
      "Description": {
        "zh-cn": "创建成功的HTTPS监听器唯一标识。",
        "en": "The unique identifier of the created HTTPS listener."
      },
      "Value": {
        "Fn::GetAtt": [
          "Listener",
          "ListenerId"
        ]
      }
    }
  }
}