KRB5KDC客户端名称不匹配在freeipa,通过证书身份验证
情况是我正在使用标准证书创建配置文件为 FreeIPA 创建用户证书。但每次当我尝试使用证书以域用户身份登录时,我都会看到消息“客户端名称不匹配”。据我了解,这条消息是由kerberos发送的,但绝对不清楚他不喜欢我的证书的什么。 同时,我可以安全地以用户身份登录,并通过无需证书登录来获取 Kerberos 票证。
如果我尝试通过证书获取 Kerberos 票证,这就是命令返回给我的内容:
KRB5_TRACE=/dev/stdout kinit -X X509_user_identity=FILE:/root/arantin.pem,/root/arantin.key arantin
[9541] 1649160627.927861: Getting initial credentials for [email protected]
[9541] 1649160627.928000: Sending request (167 bytes) to FREE.IPA
[9541] 1649160627.928150: Initiating TCP connection to stream 192.168.3.3:88
[9541] 1649160627.928265: Sending TCP request to stream 192.168.3.3:88
[9541] 1649160627.930303: Received answer (292 bytes) from stream 192.168.3.3:88
[9541] 1649160627.930330: Terminating TCP connection to stream 192.168.3.3:88
[9541] 1649160627.930421: Response was from master KDC
[9541] 1649160627.930477: Received error from KDC: -1765328359/Additional pre-authentication required
[9541] 1649160627.930505: Processing preauth types: 16, 15, 14, 136, 19, 147, 2, 133
[9541] 1649160627.930528: Selected etype info: etype aes256-cts, salt "9X\Clzp2xtK\fDk_", params ""
[9541] 1649160627.930547: Received cookie: MIT
[9541] 1649160627.930717: Preauth module pkinit (147) (info) returned: 0/Success
[9541] 1649160627.930893: PKINIT client computed kdc-req-body checksum 9/AC06024CC2069A9C1060B15A3403C8E8BD6447CC
[9541] 1649160627.930912: PKINIT client making DH request
[9541] 1649160628.173868: Preauth module pkinit (16) (real) returned: 0/Success
[9541] 1649160628.173901: Produced preauth for next request: 133, 16
[9541] 1649160628.173930: Sending request (2844 bytes) to FREE.IPA
[9541] 1649160628.174001: Initiating TCP connection to stream 192.168.3.3:88
[9541] 1649160628.174096: Sending TCP request to stream 192.168.3.3:88
[9541] 1649160628.176732: Received answer (161 bytes) from stream 192.168.3.3:88
[9541] 1649160628.176758: Terminating TCP connection to stream 192.168.3.3:88
[9541] 1649160628.176814: Response was from master KDC
[9541] 1649160628.176851: Received error from KDC: -1765328309/Client name mismatch
kinit: Client name mismatch while getting initial credentials
我需要了解如何在 FreeIPA 上配置证书颁发配置文件,以便它们工作并接收 kerberos 票证。
the situation is that I am creating a user certificate for FreeIPA using standard certificate creation profiles. But every time I see the message "Client name mismatch" when I try to log in as a domain user using a certificate. This message, as I understand it, is sent by kerberos, but it is absolutely not clear what he does not like about my certificate.
At the same time, I can safely log in as a user and get a Kerberos ticket by logging in without a certificate.
This is what the command returns to me if I try to get a Kerberos ticket by certificate:
KRB5_TRACE=/dev/stdout kinit -X X509_user_identity=FILE:/root/arantin.pem,/root/arantin.key arantin
[9541] 1649160627.927861: Getting initial credentials for [email protected]
[9541] 1649160627.928000: Sending request (167 bytes) to FREE.IPA
[9541] 1649160627.928150: Initiating TCP connection to stream 192.168.3.3:88
[9541] 1649160627.928265: Sending TCP request to stream 192.168.3.3:88
[9541] 1649160627.930303: Received answer (292 bytes) from stream 192.168.3.3:88
[9541] 1649160627.930330: Terminating TCP connection to stream 192.168.3.3:88
[9541] 1649160627.930421: Response was from master KDC
[9541] 1649160627.930477: Received error from KDC: -1765328359/Additional pre-authentication required
[9541] 1649160627.930505: Processing preauth types: 16, 15, 14, 136, 19, 147, 2, 133
[9541] 1649160627.930528: Selected etype info: etype aes256-cts, salt "9X\Clzp2xtK\fDk_", params ""
[9541] 1649160627.930547: Received cookie: MIT
[9541] 1649160627.930717: Preauth module pkinit (147) (info) returned: 0/Success
[9541] 1649160627.930893: PKINIT client computed kdc-req-body checksum 9/AC06024CC2069A9C1060B15A3403C8E8BD6447CC
[9541] 1649160627.930912: PKINIT client making DH request
[9541] 1649160628.173868: Preauth module pkinit (16) (real) returned: 0/Success
[9541] 1649160628.173901: Produced preauth for next request: 133, 16
[9541] 1649160628.173930: Sending request (2844 bytes) to FREE.IPA
[9541] 1649160628.174001: Initiating TCP connection to stream 192.168.3.3:88
[9541] 1649160628.174096: Sending TCP request to stream 192.168.3.3:88
[9541] 1649160628.176732: Received answer (161 bytes) from stream 192.168.3.3:88
[9541] 1649160628.176758: Terminating TCP connection to stream 192.168.3.3:88
[9541] 1649160628.176814: Response was from master KDC
[9541] 1649160628.176851: Received error from KDC: -1765328309/Client name mismatch
kinit: Client name mismatch while getting initial credentials
I need to understand how to configure certificate issuance profiles on FreeIPA so that they work and receive a kerberos ticket.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我会回答自己。问题在于,有必要将以下行添加到KDM和KRB5配置 - 在领域和libdefaults块中,
您还需要创建一个新的配置文件。 Freeipa的说明
https://www.freeipa.org/page/page/page/page/v4/certificate_profiles
>
@ a Freeipa-用您的域部分替换
I'll answer myself. The problem was that it was necessary to add the following lines to the kdm and krb5 configs - to the realms and libdefaults blocks, respectively
You will also need to create a new profile. Instructions from FreeIPA
https://www.freeipa.org/page/V4/Certificate_Profiles
Certificate example
@FreeIPA - replace it with your domain part