
我已经要求管理活动目录的 Windows 团队将我的 ssh 公钥添加到我的 AD 帐户。但首次登录我的 Ubuntu 服务器后,密钥未创建。您知道 Windows AD 的 sssd 或 sshd-config 中需要哪些设置才能在 Linux 主机上创建公钥吗?谢谢。
答案1
需要以下几行:
sshd
AuthorizedKeys命令 /usr/bin/sss_ssh_authorizedkeys %u
AuthorizedKeysCommand用户 root
ssd 的
ldap_user_extra_attrs = altSecurityIdentities:altSecurityIdentities
ldap_user_ssh_public_key = altSecurityIdentities
ldap_use_tokengroups = True