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

Strange behaviour



Hi everybody!

We've setup a realm and configured some hosts in our local network to use this
heimdal-realm. The setup seems to be okey as we can successfully retrieve
tickets via kinit on the hosts. We can even login passwordless into one of the
machines but all the others keep prompting for the password. we have been
struggling with this problem for quite a while now and we are honestly out of
ideas.

Here's the output of kinit and klist -v on two different hosts:

user@erebos ~ $ kinit
user@GUP.UNI-LINZ.AC.AT's Password: 
user@erebos ~ $ klist -v
Credentials cache: FILE:/tmp/krb5cc_359_sQ6fqS
	Principal: user@GUP.UNI-LINZ.AC.AT
    Cache version: 4

Server: krbtgt/GUP.UNI-LINZ.AC.AT@GUP.UNI-LINZ.AC.AT
Client: user@GUP.UNI-LINZ.AC.AT
Ticket etype: aes256-cts-hmac-sha1-96, kvno 1
Ticket length: 282
Auth time:  Nov 23 09:12:25 2007
End time:   Nov 24 09:12:25 2007
Ticket flags: forwardable, initial
Addresses: addressless

user@hydra ~ $ kinit
user@GUP.UNI-LINZ.AC.AT's Password: 
user@hydra ~ $ klist -v
Credentials cache: FILE:/tmp/krb5cc_Y20681
	Principal: user@GUP.UNI-LINZ.AC.AT
    Cache version: 4

Server: krbtgt/GUP.UNI-LINZ.AC.AT@GUP.UNI-LINZ.AC.AT
Client: user@GUP.UNI-LINZ.AC.AT
Ticket etype: aes256-cts-hmac-sha1-96, kvno 1
Ticket length: 282
Auth time:  Nov 23 09:08:44 2007
End time:   Nov 24 09:08:44 2007
Ticket flags: forwardable, initial
Addresses: addressless

As you can see the tickets generated by kinit look exactly the same on both
hosts

Now if we try to log into hydra from erebos this is what happens:

user@erebos ~ $ ssh -v hydra
OpenSSH_4.7p1, OpenSSL 0.9.8g 19 Oct 2007
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Connecting to hydra [140.78.104.100] port 22.
debug1: Connection established.
debug1: identity file /home/guppy/user/.ssh/identity type -1
debug1: identity file /home/guppy/user/.ssh/id_rsa type -1
debug1: identity file /home/guppy/user/.ssh/id_dsa type -1
debug1: Remote protocol version 2.0, remote software version OpenSSH_4.7
debug1: match: OpenSSH_4.7 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_4.7
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Host 'hydra' is known and matches the RSA host key.
debug1: Found key in /home/guppy/cspielma/.ssh/known_hosts:4
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue:
publickey,gssapi-with-mic,password,keyboard-interactive,hostbased
debug1: Next authentication method: gssapi-with-mic
debug1:  Miscellaneous failure (see text)
unknown mech-code 2529639054 for mech 1 3 6 1 4 1 311 2 2 10

debug1: Delegating credentials
debug1: Delegating credentials
debug1: Authentication succeeded (gssapi-with-mic).
debug1: channel 0: new [client-session]
debug1: Entering interactive session.
Last login: Fri Nov 23 09:16:44 2007 from erebos.gup.uni-linz.ac.at
user@hydra ~ $

BUT if we try to ssh from hydra to erebos we get this:

 cspielma@hydra ~ $ ssh -v erebos
OpenSSH_4.7p1, OpenSSL 0.9.8f 11 Oct 2007
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Connecting to erebos [140.78.104.254] port 22.
debug1: Connection established.
debug1: identity file /home/guppy/user/.ssh/identity type -1
debug1: identity file /home/guppy/user/.ssh/id_rsa type 1
debug1: identity file /home/guppy/user/.ssh/id_dsa type -1
debug1: Remote protocol version 2.0, remote software version OpenSSH_4.7
debug1: match: OpenSSH_4.7 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_4.7
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Host 'erebos' is known and matches the RSA host key.
debug1: Found key in /home/guppy/cspielma/.ssh/known_hosts:18
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue:
publickey,gssapi-with-mic,password,keyboard-interactive,hostbased
debug1: Next authentication method: gssapi-with-mic
debug1:  Miscellaneous failure (see text)
unknown mech-code 2529639054 for mech 1 3 6 1 4 1 311 2 2 10

debug1: Authentications that can continue:
publickey,gssapi-with-mic,password,keyboard-interactive,hostbased
debug1: Next authentication method: hostbased
debug1: permanently_drop_suid: 359
debug1: Authentications that can continue:
publickey,gssapi-with-mic,password,keyboard-interactive,hostbased
debug1: permanently_drop_suid: 359
debug1: Authentications that can continue:
publickey,gssapi-with-mic,password,keyboard-interactive,hostbased
debug1: No more client hostkeys for hostbased authentication.
debug1: Next authentication method: publickey
debug1: Trying private key: /home/guppy/user/.ssh/identity
debug1: Offering public key: /home/guppy/user/.ssh/id_rsa
debug1: Authentications that can continue:
publickey,gssapi-with-mic,password,keyboard-interactive,hostbased
debug1: Trying private key: /home/guppy/user/.ssh/id_dsa
debug1: Next authentication method: keyboard-interactive
Password:

When i look into the log of sshd on erebos the last line of the log looks like
this:

Nov 23 09:21:21 erebos sshd[5671]: (pam_krb5): user: attempting authentication
as user@GUP.UNI-LINZ.AC.AT

if i don't do anything and just wait it hangs there for about two minutes and
after that it appends the following lines to the log:

Nov 23 09:23:20 erebos sshd[5671]: (pam_krb5): user: error getting password:
Conversation error
Nov 23 09:23:20 erebos sshd[5671]: (pam_krb5): user: pam_sm_authenticate: exit
(failure)
Nov 23 09:23:20 erebos sshd[5671]: error: ssh_msg_send: write
Nov 23 09:23:20 erebos sshd[5671]: pam_unix(sshd:auth): conversation failed
Nov 23 09:23:20 erebos sshd[5671]: pam_unix(sshd:auth): auth could not identify
password for [user]
Nov 23 09:23:20 erebos sshd[5671]: error: ssh_msg_send: write

I guess that this is the problem but how do i fix that? Any suggestions would
be appreciated.

Regards,

Christoph