Kerberos SSH Login

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
0
down vote

favorite












I'm trying to setup a



  • ssh server

  • ssh client

  • kerberos server

Now, on both the SSH server and client I can poll a ticket by calling, kinit -p root/admin.



In SSH/SSHD config I set



  • GSSAPIAuthentication yes

  • GSSAPICleanupCredentials yes

  • GSSAPIDelegateCredentials yes

Now when I try from client to ssh to the ssh-server I'm still prompted about password, why is that?



$ ssh -vv sshserver
debug2: compression ctos: none,zlib@openssh.com
debug2: compression stoc: none,zlib@openssh.com
debug2: languages ctos:
debug2: languages stoc:
debug2: first_kex_follows 0
debug2: reserved 0
debug1: kex: algorithm: curve25519-sha256@libssh.org
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC:
<implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC:
<implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256
SHA256:71jU1n0c5M2uGF1RA37xc5ktz7CVmq2lqztrM+0ApX8
debug1: Host 'sshserver.kea.dk' is known and matches the ECDSA host key.
debug1: Found key in /home/ghost/.ssh/known_hosts:1
debug2: set_newkeys: mode 1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug2: set_newkeys: mode 0
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS received
debug2: key: /home/ghost/.ssh/id_rsa (0x564e5774b270)
debug2: key: /home/ghost/.ssh/id_dsa ((nil))
debug2: key: /home/ghost/.ssh/id_ecdsa ((nil))
debug2: key: /home/ghost/.ssh/id_ed25519 ((nil))
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<rsa-sha2-256,rsa-sha2-512>
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug1: Next authentication method: gssapi-keyex
debug1: No valid Key exchange context
debug2: we did not send a packet, disable method
debug1: Next authentication method: gssapi-with-mic
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we did not send a packet, disable method
debug1: Next authentication method: publickey
debug1: Offering RSA public key: /home/ghost/.ssh/id_rsa
debug2: we sent a publickey packet, wait for reply
debug1: Server accepts key: pkalg rsa-sha2-512 blen 535
debug2: input_userauth_pk_ok: fp
SHA256:V731Bh8CcX3x80tGJcwqsSBOo0wZbq2iIFc+ZHnyadg
debug1: Trying private key: /home/ghost/.ssh/id_dsa
debug1: Trying private key: /home/ghost/.ssh/id_ecdsa
debug1: Trying private key: /home/ghost/.ssh/id_ed25519
debug2: we did not send a packet, disable method
debug1: Next authentication method: password






share|improve this question






















  • Did you add a service principal for sshd to your kerberos database?
    – Sebastian Stark
    May 22 at 7:29











  • I think I did when I made the key for the ssh server? When doing listprincs it shows ssh/mykerberos.kea.dk@MYKERBEROS.KEA.DK
    – MrSykkox
    May 22 at 9:01











  • Are you using the exact same hostname for the ssh command line like shown in listprincs? That would have to be "ssh mykerberos.kea.dk"
    – Sebastian Stark
    May 27 at 12:35














up vote
0
down vote

favorite












I'm trying to setup a



  • ssh server

  • ssh client

  • kerberos server

Now, on both the SSH server and client I can poll a ticket by calling, kinit -p root/admin.



In SSH/SSHD config I set



  • GSSAPIAuthentication yes

  • GSSAPICleanupCredentials yes

  • GSSAPIDelegateCredentials yes

Now when I try from client to ssh to the ssh-server I'm still prompted about password, why is that?



$ ssh -vv sshserver
debug2: compression ctos: none,zlib@openssh.com
debug2: compression stoc: none,zlib@openssh.com
debug2: languages ctos:
debug2: languages stoc:
debug2: first_kex_follows 0
debug2: reserved 0
debug1: kex: algorithm: curve25519-sha256@libssh.org
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC:
<implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC:
<implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256
SHA256:71jU1n0c5M2uGF1RA37xc5ktz7CVmq2lqztrM+0ApX8
debug1: Host 'sshserver.kea.dk' is known and matches the ECDSA host key.
debug1: Found key in /home/ghost/.ssh/known_hosts:1
debug2: set_newkeys: mode 1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug2: set_newkeys: mode 0
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS received
debug2: key: /home/ghost/.ssh/id_rsa (0x564e5774b270)
debug2: key: /home/ghost/.ssh/id_dsa ((nil))
debug2: key: /home/ghost/.ssh/id_ecdsa ((nil))
debug2: key: /home/ghost/.ssh/id_ed25519 ((nil))
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<rsa-sha2-256,rsa-sha2-512>
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug1: Next authentication method: gssapi-keyex
debug1: No valid Key exchange context
debug2: we did not send a packet, disable method
debug1: Next authentication method: gssapi-with-mic
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we did not send a packet, disable method
debug1: Next authentication method: publickey
debug1: Offering RSA public key: /home/ghost/.ssh/id_rsa
debug2: we sent a publickey packet, wait for reply
debug1: Server accepts key: pkalg rsa-sha2-512 blen 535
debug2: input_userauth_pk_ok: fp
SHA256:V731Bh8CcX3x80tGJcwqsSBOo0wZbq2iIFc+ZHnyadg
debug1: Trying private key: /home/ghost/.ssh/id_dsa
debug1: Trying private key: /home/ghost/.ssh/id_ecdsa
debug1: Trying private key: /home/ghost/.ssh/id_ed25519
debug2: we did not send a packet, disable method
debug1: Next authentication method: password






share|improve this question






















  • Did you add a service principal for sshd to your kerberos database?
    – Sebastian Stark
    May 22 at 7:29











  • I think I did when I made the key for the ssh server? When doing listprincs it shows ssh/mykerberos.kea.dk@MYKERBEROS.KEA.DK
    – MrSykkox
    May 22 at 9:01











  • Are you using the exact same hostname for the ssh command line like shown in listprincs? That would have to be "ssh mykerberos.kea.dk"
    – Sebastian Stark
    May 27 at 12:35












up vote
0
down vote

favorite









up vote
0
down vote

favorite











I'm trying to setup a



  • ssh server

  • ssh client

  • kerberos server

Now, on both the SSH server and client I can poll a ticket by calling, kinit -p root/admin.



In SSH/SSHD config I set



  • GSSAPIAuthentication yes

  • GSSAPICleanupCredentials yes

  • GSSAPIDelegateCredentials yes

Now when I try from client to ssh to the ssh-server I'm still prompted about password, why is that?



$ ssh -vv sshserver
debug2: compression ctos: none,zlib@openssh.com
debug2: compression stoc: none,zlib@openssh.com
debug2: languages ctos:
debug2: languages stoc:
debug2: first_kex_follows 0
debug2: reserved 0
debug1: kex: algorithm: curve25519-sha256@libssh.org
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC:
<implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC:
<implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256
SHA256:71jU1n0c5M2uGF1RA37xc5ktz7CVmq2lqztrM+0ApX8
debug1: Host 'sshserver.kea.dk' is known and matches the ECDSA host key.
debug1: Found key in /home/ghost/.ssh/known_hosts:1
debug2: set_newkeys: mode 1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug2: set_newkeys: mode 0
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS received
debug2: key: /home/ghost/.ssh/id_rsa (0x564e5774b270)
debug2: key: /home/ghost/.ssh/id_dsa ((nil))
debug2: key: /home/ghost/.ssh/id_ecdsa ((nil))
debug2: key: /home/ghost/.ssh/id_ed25519 ((nil))
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<rsa-sha2-256,rsa-sha2-512>
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug1: Next authentication method: gssapi-keyex
debug1: No valid Key exchange context
debug2: we did not send a packet, disable method
debug1: Next authentication method: gssapi-with-mic
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we did not send a packet, disable method
debug1: Next authentication method: publickey
debug1: Offering RSA public key: /home/ghost/.ssh/id_rsa
debug2: we sent a publickey packet, wait for reply
debug1: Server accepts key: pkalg rsa-sha2-512 blen 535
debug2: input_userauth_pk_ok: fp
SHA256:V731Bh8CcX3x80tGJcwqsSBOo0wZbq2iIFc+ZHnyadg
debug1: Trying private key: /home/ghost/.ssh/id_dsa
debug1: Trying private key: /home/ghost/.ssh/id_ecdsa
debug1: Trying private key: /home/ghost/.ssh/id_ed25519
debug2: we did not send a packet, disable method
debug1: Next authentication method: password






share|improve this question














I'm trying to setup a



  • ssh server

  • ssh client

  • kerberos server

Now, on both the SSH server and client I can poll a ticket by calling, kinit -p root/admin.



In SSH/SSHD config I set



  • GSSAPIAuthentication yes

  • GSSAPICleanupCredentials yes

  • GSSAPIDelegateCredentials yes

Now when I try from client to ssh to the ssh-server I'm still prompted about password, why is that?



$ ssh -vv sshserver
debug2: compression ctos: none,zlib@openssh.com
debug2: compression stoc: none,zlib@openssh.com
debug2: languages ctos:
debug2: languages stoc:
debug2: first_kex_follows 0
debug2: reserved 0
debug1: kex: algorithm: curve25519-sha256@libssh.org
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC:
<implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC:
<implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256
SHA256:71jU1n0c5M2uGF1RA37xc5ktz7CVmq2lqztrM+0ApX8
debug1: Host 'sshserver.kea.dk' is known and matches the ECDSA host key.
debug1: Found key in /home/ghost/.ssh/known_hosts:1
debug2: set_newkeys: mode 1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug2: set_newkeys: mode 0
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS received
debug2: key: /home/ghost/.ssh/id_rsa (0x564e5774b270)
debug2: key: /home/ghost/.ssh/id_dsa ((nil))
debug2: key: /home/ghost/.ssh/id_ecdsa ((nil))
debug2: key: /home/ghost/.ssh/id_ed25519 ((nil))
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<rsa-sha2-256,rsa-sha2-512>
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug1: Next authentication method: gssapi-keyex
debug1: No valid Key exchange context
debug2: we did not send a packet, disable method
debug1: Next authentication method: gssapi-with-mic
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we sent a gssapi-with-mic packet, wait for reply
debug1: Authentications that can continue: publickey,gssapi-keyex,gssapi-with-mic,password
debug2: we did not send a packet, disable method
debug1: Next authentication method: publickey
debug1: Offering RSA public key: /home/ghost/.ssh/id_rsa
debug2: we sent a publickey packet, wait for reply
debug1: Server accepts key: pkalg rsa-sha2-512 blen 535
debug2: input_userauth_pk_ok: fp
SHA256:V731Bh8CcX3x80tGJcwqsSBOo0wZbq2iIFc+ZHnyadg
debug1: Trying private key: /home/ghost/.ssh/id_dsa
debug1: Trying private key: /home/ghost/.ssh/id_ecdsa
debug1: Trying private key: /home/ghost/.ssh/id_ed25519
debug2: we did not send a packet, disable method
debug1: Next authentication method: password








share|improve this question













share|improve this question




share|improve this question








edited May 21 at 0:53









ubashu

2,23221736




2,23221736










asked May 20 at 20:56









MrSykkox

1012




1012











  • Did you add a service principal for sshd to your kerberos database?
    – Sebastian Stark
    May 22 at 7:29











  • I think I did when I made the key for the ssh server? When doing listprincs it shows ssh/mykerberos.kea.dk@MYKERBEROS.KEA.DK
    – MrSykkox
    May 22 at 9:01











  • Are you using the exact same hostname for the ssh command line like shown in listprincs? That would have to be "ssh mykerberos.kea.dk"
    – Sebastian Stark
    May 27 at 12:35
















  • Did you add a service principal for sshd to your kerberos database?
    – Sebastian Stark
    May 22 at 7:29











  • I think I did when I made the key for the ssh server? When doing listprincs it shows ssh/mykerberos.kea.dk@MYKERBEROS.KEA.DK
    – MrSykkox
    May 22 at 9:01











  • Are you using the exact same hostname for the ssh command line like shown in listprincs? That would have to be "ssh mykerberos.kea.dk"
    – Sebastian Stark
    May 27 at 12:35















Did you add a service principal for sshd to your kerberos database?
– Sebastian Stark
May 22 at 7:29





Did you add a service principal for sshd to your kerberos database?
– Sebastian Stark
May 22 at 7:29













I think I did when I made the key for the ssh server? When doing listprincs it shows ssh/mykerberos.kea.dk@MYKERBEROS.KEA.DK
– MrSykkox
May 22 at 9:01





I think I did when I made the key for the ssh server? When doing listprincs it shows ssh/mykerberos.kea.dk@MYKERBEROS.KEA.DK
– MrSykkox
May 22 at 9:01













Are you using the exact same hostname for the ssh command line like shown in listprincs? That would have to be "ssh mykerberos.kea.dk"
– Sebastian Stark
May 27 at 12:35




Are you using the exact same hostname for the ssh command line like shown in listprincs? That would have to be "ssh mykerberos.kea.dk"
– Sebastian Stark
May 27 at 12:35















active

oldest

votes











Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "89"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1038484%2fkerberos-ssh-login%23new-answer', 'question_page');

);

Post as a guest



































active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes










 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1038484%2fkerberos-ssh-login%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

Which professions warranted travel in Medieval times?

How do so many people here on Academia.SE, and in general, afford lavish higher education programs?

Trouble downloading packages list due to a “Hash sum mismatch” error