Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Pre-authentication failed: Password read interrupted while getting initial credentials [closed]

This is something I have faced and I found the solution. since there wasn't any question about it, I will post it as a question and I will write my solution as the answer.

Environment:

  • OS: Centos Linux, MacOS (Big Sur)
  • Cluster: Cloudera Hadoop Distribution,
  • Tool: Kerberos

Problem:

I created "user.keytab" file by "ktutil" to renew the krb ticket without password as it was recommended in here https://kb.iu.edu/d/aumh

ktutil:  addent -password -p [email protected] -k 1 -e rc4-hmac
Password for [email protected]: [enter your password]
ktutil:  addent -password -p [email protected] -k 1 -e aes256-cts
Password for [email protected]: [enter your password]
ktutil:  wkt user.keytab
ktutil:  quit

then testing end up with exception

(user@server [~])$ kinit [email protected] -k -t user.keytab
kinit: Preauthentication failed while getting initial credentials
like image 778
Alper t. Turker Avatar asked Apr 17 '18 22:04

Alper t. Turker


People also ask

What does “Preauthentication failed while getting initial credentials” mean?

The error, “Preauthentication failed while getting initial credentials” happens when the password is incorrect. Update the keytab file on the problematic Kerberos client with the key provided from the Kerberos server.

Why did my Kerberos pre-authentication fail?

For 4771 (F): Kerberos pre-authentication failed. High-value accounts: You might have high-value domain or local accounts for which you need to monitor each action. Examples of high-value accounts are database administrators, built-in local administrator account, domain administrators, service accounts, domain controller accounts and so on.

What is security event 4771 (F) Kerberos pre-authentication failed?

Describes security event 4771(F) Kerberos pre-authentication failed. This event is generated when the Key Distribution Center fails to issue a Kerberos TGT.

Why is my SELinux password not working?

After wasting quite a lot of time with analyzing configuration files and also SELinux I remembered that the cause for this issue can be quite simple. Try to generate a Kerberos ticket using kinit when receiving error messages like this – it is possible that the password simply expired:


1 Answers

Cause:

key encryption type "aes256-cts" might not be configured in your krb setup

Solution

simply delete keytab file and recreate one without "aes256-cts" encryption by using above steps

ktutil:  addent -password -p [email protected] -k 1 -e rc4-hmac
Password for [email protected]: [enter your password]
ktutil:  wkt user.keytab
ktutil:  quit

or

delete "aes256-cts" encription from the keytab file by following the steps on the link I added above.

and finally execute:

(user@server [~])$ kinit [email protected] -k -t user.keytab

you wont see any error this time and your ticket will be created

like image 71
Alper t. Turker Avatar answered Oct 08 '22 04:10

Alper t. Turker