Hosts in Active Directory (SSSD)¶
Linux servers joined to AD with SSSD (realm join corp.example.com)
already know every AD user: their names, IDs, groups and home directories.
BastionXP CA adds the SSH login with a certificate. Nothing on these servers
changes for BastionXP CA besides two lines in sshd_config.
1. The login name¶
SSSD names users [email protected] by default, or alice with
use_fully_qualified_names = False in /etc/sssd/sssd.conf. The
certificate's principal must be exactly that name:
| SSSD login name | Principal in the access rules |
|---|---|
[email protected] |
{username} (with username_attribute: userPrincipalName, or preferred_username with OIDC) |
alice |
{short_username} |
2. Trust the CA¶
3. Home directories¶
For people who never logged in there before:
4. Who may log in where¶
Stays with SSSD, if you want it per host:
With UsePAM yes, sshd asks SSSD's account check also for certificate
logins, so the check holds, and a person disabled in AD is refused even
with a certificate that has hours left.
Division of labour¶
The certificate decides who the person is; AD and SSSD decide what
their account is on the host. Someone removed from linux-users gets no
new certificate, and their current one expires within its lifetime (16
hours by default; shorter with --validity).