<div dir="ltr"><div><div><div><div>Hi Alexander,<br></div>thank you for your fast reply. <br><br></div>I've already executed: # ipa host-mod --ok-as-delegate=TRUE but still cant log in using GSSAPI to ipa clients.<br><br></div>Please find answers below:<br></div>1. Yes, logging to Linux IPA Client (Centos 6.6) without entering password is not working from AD-joined Windows station with PuTTY. Logging to IPA Master server without entering password (using gssapi) works ok.<br>2. - <br>3. Logging in to ipa clients from AD-joined Windows station with Putty (0.64) always requires password and then Kerberos ticket is available in the shell.<div><div><div><div><br></div><div>After I changed loglevel in /etc/sshd/sshd_config on ipa client to LogLevel Debug i found in /var/log/secure:<br>....<br></div><div>debug1: userauth-request for user leszek service ssh-connection method none<br></div><div>debug1: attempt 0 failures 0<br></div><div>debug1: PAM: initializing for "leszek"<br></div><div>...<br>debug1: Postponed gssapi-with-mic for leszek from X.X.X.X<br></div><div>debug1: Got no client credentials<br></div><div>Failed gssapi-with-mic for user leszek <br><br></div><div>After entering password and logging to system I found this in /var/log/secure:<br>...<br></div><div>debug1: ssh_gssapi_storecreds: Not a GSSAPI mechanism<br></div><div><br></div><div><br>/var/log/sssd/sssd_domain.log<br>...<br></div><div>[ipa_subdom_get_forest] (0x0400: 4th component is not 'trust', nothing to do.<br>...<br><br></div><div>Any ideas? <br><br></div><div>/lm<br></div><br><div><br><br></div><div><br></div></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-05-25 13:25 GMT+02:00 Alexander Bokovoy <span dir="ltr"><<a href="mailto:abokovoy@redhat.com" target="_blank">abokovoy@redhat.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Mon, 25 May 2015, crony wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi All,<br>
we have setup FreeIPA 4.1 (Centos 7) Trust with Windows 2008R2. All (HBAC,<br>
SUDO) works pretty well except SSH SSO using GSSAPI from Windows AD clients<br>
(ex. putty) to Linux client machines (Centos 6). Password authentication<br>
works, just gssapi fails.<br>
</blockquote></span>
Do you have have anything in the SSH server logs when using high enough<br>
debug level?<br>
<br>
SSH GSSAPI (single sign-on) should just work fine. On contrary, delegation or forwarding<br>
of credentials (i.e. Kerberos TGT from AD side being available after<br>
login to SSH server) should not work unless ok-as-delegate flag is set<br>
on the host principal -- see 'ipa host-mod --ok-as-delegate=TRUE'.<br>
<br>
So what exactly is not working:<br>
<br>
1. Logging in without entering a password from AD-joined Windows<br>
station with PuTTY?<br>
<br>
2. Logging in without the password works but no Kerberos ticket<br>
available in the shell?<br>
<br>
3. Logging in always requires password and then Kerberos ticket is not<br>
available in the shell?<br>
<br>
4. Something else?<span class=""><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Actually, there is one scenario where SSH GSSAPI authentication works  -><br>
when connecting to FreeIPA master or replica (trust were established here),<br>
but not to FreeIPA host clients.<br>
<br>
Important sections of configuration files (servers/clients):<br>
<br>
/etc/ssh/sshd_config:<br>
GSSAPIAuthentication yes<br>
KerberosAuthentication yes<br>
</blockquote></span>
Remove 'KerberosAuthentication yes', you don't want it to be used, only<br>
GSSAPI.<span class=""><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
/etc/krb5.conf:<br>
auth_to_local = RULE:[1:$1 <at> $0](^.* <at> WINDOWS.DOMAIN$)s/ <at><br>
WINDOWS.DOMAIN/ <at> windows.domain/<br>
auth_to_local = DEFAULT<br>
</blockquote></span>
You don't need to specify auth_to_local rules in krb5.conf in RHEL 7.1<br>
because we now have this filled in by SSSD. As you are claiming FreeIPA<br>
4.1 is in use, it means CentOS 7.1, thus SSSD automatically contributing<br>
auth_to_local plugin.<span class=""><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
BTW. after I log in by password to linux client machine I can use gssapi<br>
within the same host by ssh-ing in a loop to the localhost, so locally<br>
GSSAPI works here.<br>
</blockquote></span>
This is expected and is by design.<span class=""><br>
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Is there something I missed?<br>
Any help would be greatly appreciated.<br>
</blockquote></span>
Answer my questions above, I suspect all you need is to mark the host<br>
principal as available for delegation.<span class="HOEnZb"><font color="#888888"><br>
<br>
-- <br>
/ Alexander Bokovoy<br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature">Pozdrawiam Leszek Miś<br>www: <a href="http://cronylab.pl" target="_blank">http://cronylab.pl</a><br>www: <a href="http://emerge.pl" target="_blank">http://emerge.pl</a><br>Nothing is secure, paranoia is your friend.</div>
</div>