[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

SSSD, ssh-keys im LDAP und Loginprobleme



Guten Abend,
in unserem LDAP-Setup haben wir testweise die Möglichkeit eingebaut ssh-keys für
einen User anzulegen.
Diese können dann via SSSD und dem AuthorizedKeysCommand von OpenSSH abgerufen
werden und benötigen keine /home/$user/.ssh/authorized_keys Konfiguration pro
Host mehr.
Das funktioniert auch soweit. Allerdings funktioniert es nun immer, egal, ob mit
dem host Attribut login-rechte vergeben worden sind oder nicht.
Ist das erwartbares Verhalten, oder ist da in der Konfiguration noch irgendwas
falsch.
Aktuell habe ich da PAM im Verdacht.
Die entsprechenden Konfigurationsdateien sind angefügt.
Wenn da jemand Erfahrungen hat würde ich mich über Hilfe sehr freuen.

Viele Grüße
Thore

/usr/share/pam-configs/ldap
----
Name: LDAP Authentication
Default: yes
Priority: 128
Auth-Type: Primary
Auth-Initial:
	[success=end default=ignore]	pam_sss.so
Auth:
	[success=end default=ignore]	pam_sss.so use_first_pass
Account-Type: Primary
Account:
	[success=end default=ignore]	pam_sss.so
Password-Type: Primary
Password-Initial:
	[success=end user_unknown=ignore default=die]	pam_sss.so
Password:
	[success=end user_unknown=ignore default=die]	pam_sss.so try_first_pass
Session-Type: Additional
Session:
        [success=ok new_authtok_reqd=ok ignore=ignore default=bad]  pam_mkhomedir.so skel=/etc/skel/ umask=0022
	optional			pam_sss.so


/etc/sssd/sssd.conf
----
[sssd]
config_file_version = 2
services = nss, pam, ssh
# SSSD will not start if you do not configure any domains.
# Add new domain configurations as [domain/<NAME>] sections, and
# then add the list of domains (in the order you want them to be
# queried) to the "domains" attribute below and uncomment it.
domains = aaa.example.com

[nss]

[pam]

# LDAP domain configuration
[domain/aaa.example.com]
id_provider = ldap
auth_provider = ldap
# ldap_schema can be set to "rfc2307", which stores group member names in the
# "memberuid" attribute, or to "rfc2307bis", which stores group member DNs in
# the "member" attribute. If you do not know this value, ask your LDAP
# administrator.
ldap_schema = rfc2307bis

ldap_uri = ldaps://aaa.example.com
ldap_search_base = dc=example,dc=com
chpass_provider = ldap
ldap_chpass_uri = ldaps://aaa-master.example.com
# Note that enabling enumeration will have a moderate performance impact.
# Consequently, the default value for enumeration is FALSE.
# Refer to the sssd.conf man page for full details.
enumerate = true
# Allow offline logins by locally storing password hashes (default: false).
cache_credentials = true
ldap_tls_reqcert = demand
ldap_tls_cacert = /etc/ssl/certs/ca-certificates.crt



Reply to: