

# 确定 SSL/TLS RSA 证书中公有密钥的大小
<a name="cnames-and-https-size-of-public-key"></a>

如果您使用的是 CloudFront 备用域名和 HTTPS，则 SSL/TLS RSA 证书中公有密钥的最大大小为 4096 位。(这是密钥大小，不是指公有密钥中的字符数。) 在使用 AWS Certificate Manager 提供您的证书的情况下，虽然 ACM 支持更大的 RSA 密钥，但您无法在 CloudFront 中使用更大的密钥。

您可以通过运行以下 OpenSSL 命令来确定 RSA 公有密钥的大小：

```
openssl x509 -in path and filename of SSL/TLS certificate -text -noout 
```

其中：
+ `-in` 指定您的 SSL/TLS RSA 证书的路径和文件名。
+ `-text` 使 OpenSSL 以位为单位显示 RSA 公有密钥的长度。
+ `-noout` 阻止 OpenSSL 显示公有密钥。

输出示例：

```
Public-Key: (2048 bit)
```