谷歌官方文档,地址:https://cloud.google.com/certificate-manager/docs/public-ca-tutorial 。可以先查看下备用。
一、申请一个谷歌账号
有账号,本步骤可以忽略。
二、创建一个谷歌云项目
打开:https://console.cloud.google.com/ 左上角Google cloud图标边上,点击下三角。新建项目。名字随意。记下 “项目的ID”(这里注意不是项目名,是ID)。
复制项目ID备用。
三、申请EAB_KID: EAB 密钥 ID 和 EAB_HMAC_KEY: EAB HMAC 密钥
创建角色
打开:https://console.cloud.google.com/ 右上角,选择第一个命令行图标。以下代码需输入命令行。
gcloud projects add-iam-policy-binding 项目ID --member=user:你的邮箱地址 --role=roles/publicca.externalAccountKeyCreator
启用公共 CA API
gcloud services enable publicca.googleapis.com
如果第一次报错那就再运行一次。
申请 EAB 密钥 ID 和 HMAC
gcloud publicca external-account-keys create
记住返回的b64MacKey和keyID,复制并存档,放在记事本等文本编辑软件保存即可,不要弄丢了。申请证书需要使用。
三、使用b64MacKey和keyID
在acmessl.cn选择google public ca证书申请,输入b64MacKey和keyID。提交申请计量科。
注意:
- Register an ACME account You must use an EAB secret within 7 days of obtaining it. The EAB secret is invalidated if you don't use it within 7 days. The ACME account registered using an EAB secret has no expiration.
您必须在获取 EAB 密钥后的 7 天内使用该密钥。如果您在 7 天内未使用 EAB 密钥,则该密钥将失效。 使用 EAB 密钥注册的 ACME 帐户没有过期时间。
