10.4. 配置 ACME Realm
本节描述了如何为 PKI ACME 响应器 配置域。realm 配置位于 /etc/pki/pki-tomcat/acme/realm.conf。
您可以使用 pki-server acme-realm-mod 命令通过命令行配置 ACME Realm。
在没有参数的情况下调用此命令会启动一个互动模式,例如:
$ pki-server acme-realm-mod The current value is displayed in the square brackets. To keep the current value, simply press Enter. To change the current value, enter the new value. To remove the current value, enter a blank space. Enter the type of the realm. Available types: ds. Database Type: ds Enter the location of the LDAP server (e.g. ldap://localhost.localdomain:389). Server URL [ldap://localhost.localdomain:389]: Enter the authentication type. Available types: BasicAuth, SslClientAuth. Authentication Type [BasicAuth]: Enter the bind DN. Bind DN [cn=Directory Manager]: Enter the bind password. Bind Password [ ****** ]: Enter the base DN for the ACME users subtree. Users DN [ou=people,dc=acme,dc=pki,dc=example,dc=com]: Enter the base DN for the ACME groups subtree. Groups DN [ou=groups,dc=acme,dc=pki,dc=example,dc=com]:-
使用--
type参数调用 命令会根据指定的类型创建新的配置。 - 使用其他参数调用 命令会更新指定的参数。
10.4.1. 配置 DS Realm 复制链接链接已复制到粘贴板!
您可以将 PKI ACME Responder 配置为使用目录服务器域。DS Realm 的示例配置位于 /usr/share/pki/acme/realm/ds/realm.conf。
配置目录服务器域:
-
为 DS 中的 ACME 用户和组准备子树。示例 LDIF 文件位于
/usr/share/pki/acme/realm/ds/create.ldif]。本例使用dc=acme,dc=pki,dc=example,dc=com作为基本 DN。 使用
ldapadd命令导入 LDIF 文件:$ ldapadd -h $HOSTNAME -x -D "cn=Directory Manager" -w Secret.123 \ -f /usr/share/pki/acme/realm/ds/create.ldif将
/usr/share/pki/acme/realm/ds/realm.conf示例配置文件复制到/etc/pki/pki-tomcat/acme目录中,或者运行以下命令来自定义某些参数:$ pki-server acme-realm-mod --type ds \ -DbindPassword=Secret.123根据需要自定义配置:
在独立 ACME 部署中,
realm.conf文件应类似如下:class=org.example.acme.realm.DSRealm url=ldap://<hostname>:389 authType=BasicAuth bindDN=cn=Directory Manager bindPassword=Secret.123 usersDN=ou=people,dc=acme,dc=pki,dc=example,dc=com groupsDN=ou=groups,dc=acme,dc=pki,dc=example,dc=com在共享 CA 和 ACME 部署中,
realm.conf文件应类似如下:class=org.example.acme.realm.DSRealm configFile=conf/ca/CS.cfg usersDN=ou=people,dc=ca,dc=pki,dc=example,dc=com groupsDN=ou=groups,dc=ca,dc=pki,dc=example,dc=com