org.keycloak.example.kerberos

## Class GSSCredentialsClient

- java.lang.Object
- - org.keycloak.example.kerberos.GSSCredentialsClient

-     public class GSSCredentialsClient
      extends Object

  Sample client able to authenticate against ApacheDS LDAP server with Krb5 GSS Credential. Credential was previously retrieved from SPNEGO authentication against Keycloak auth-server and transmitted from Keycloak to the application in OIDC access token We can use GSSCredential to further GSS API calls . Note that if you will use GSS API directly, you can attach GSSCredential when creating GSSContext like this: GSSContext context = gssManager.createContext(serviceName, KerberosSerializationUtils.KRB5_OID, deserializedGssCredential, GSSContext.DEFAULT_LIFETIME); In this example we authenticate against LDAP server, which calls GSS API under the hood when credential is attached to env under Sasl.CREDENTIALS key
  Author:
    Marek Posolda

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `GSSCredentialsClient.LDAPUser`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `GSSCredentialsClient()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static GSSCredentialsClient.LDAPUser` | `getUserFromLDAP(javax.servlet.http.HttpServletRequest req)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### GSSCredentialsClient

          public GSSCredentialsClient()

  - ### Method Detail

    - #### getUserFromLDAP

          public static GSSCredentialsClient.LDAPUser getUserFromLDAP(javax.servlet.http.HttpServletRequest req)
                                                               throws Exception

      Throws:
        `Exception`

Copyright © 2015. All rights reserved.