Keytab file authentication check

4.2k Views Asked by At

I have a query, I have created a user and generated keytab file from it but I want to test it with the credentials before sharing this file is there any way to achieve this, I know the username password and all the relevant information.

1

There are 1 best solutions below

1
On

This is an example using kinit and klist to validate a keytab file named lisa.example.com.keytab for an account with SPN HTTP/lisa.example.com in the EXAMPLE.COM Kerberos realm.

root@4e06b32e1ca8:/usr/local/tomcat/conf# kinit -k -t ./lisa.example.com.keytab HTTP/[email protected] 

root@4e06b32e1ca8:/usr/local/tomcat/conf# klist
 Ticket cache: FILE:/tmp/krb5cc_0
 Default principal: HTTP/[email protected]

 Valid starting Expires Service principal 
07/08/2017 18:27:38 07/09/2017 04:27:38 krbtgt/[email protected]
 renew until 07/09/2017 18:27:38