<iframe src="https://www.googletagmanager.com/ns.html?id=GTM-M74D8PB" height="0" width="0" style="display:none;visibility:hidden">
Loading
Skip to NavigationSkip to Main Content

Okta Access Gateway Kerberos Application Fails With a 401 - Unauthorised and Server Not Found In Kerberos Database Errors

Access Gateway
Okta Classic Engine
Okta Identity Engine

Overview

Okta Access Gateway (OAG) generates a 401 error when a user attempts to access an Internet Information Services (IIS) application because the authentication header name is incorrect. Administrators must change the header attribute name to iwa_username in the OAG application settings to resolve the issue. This issue assumes the Kerberos realm is valid and the Kerberos simulator is successful.

Okta displays the following error when a user attempts to access the application:

 

401 - Unauthorized: Access is denied due to invalid credentials.


Client Error 

Okta generates the following log entries when this error occurs:

 

Server not found in Kerberos database.

 

2023-06-16T12:55:56.000-04:00 oag-admin.nbcorp.us oag-admin.nbcorp.us LWxmOLdK4: 2023/06/16 12:55:56 [error] 4056#0: *637 [lua] authSession.lua:1443: Major ERR:Unspecified GSS failure.  Minor code may provide more
information, client: 10.43.85.11, server: gw-iis.nbcorp.us, request: "GET / HTTP/2.0", host: "gw-iis.nbcorp.us", referrer: "https://okta-nbcorp.pixtulate.com/ "
2023-06-16T12:55:56.000-04:00 oag-admin.nbcorp.us oag-admin.nbcorp.us LWxmOLdK4: 2023/06/16 12:55:56 [error] 4056#0: *637 [lua] authSession.lua:1444: Minor ERR:Server not found in Kerberos database, client: 10.43.8
5.11, server: gw-iis.nbcorp.us, request: "GET / HTTP/2.0", host: "gw-iis.nbcorp.us", referrer: "https://okta-nbcorp.pixtulate.com/

 

Applies To

  • Okta Identity Engine (OIE)
  • Okta Classic Engine
  • Okta Access Gateway (OAG)
  • Kerberos
  • Internet Information Services (IIS) Application

Cause

Okta Access Gateway requires the authentication header name to be exactly iwa_username.

 

The following image displays the correct header configuration.
OAG Iwa_name 

If an administrator configures a different header name, Okta cannot request the Kerberos ticket from the Key Distribution Center (KDC). The KDC rejects the Kerberos ticket request and generates a KDC_ERR_C_PRINCIPAL_UNKNOWN error.

 

The following packet capture image displays the KDC rejection error.
KDC_ERR_C_PRINCIPAL_UNKNOWN 

Solution

How is the Okta Access Gateway Kerberos application 401 error resolved?

Resolve the 401 error by configuring the header attribute name to iwa_username in the Okta Access Gateway application settings by following these steps.

  1. Navigate to the Okta Access Gateway application settings.
  2. Locate the header attribute used for authentication.
  3. Change the name of the header attribute to iwa_username.
  4. Save the configuration.

 

Related References

Loading
Okta Support - Okta Access Gateway Kerberos Application Fails With a 401 - Unauthorised and Server Not Found In Kerberos Database Errors