Class KrbClient

java.lang.Object
org.apache.kerby.kerberos.kerb.client.KrbClientBase
org.apache.kerby.kerberos.kerb.client.KrbClient

public class KrbClient extends KrbClientBase
A Krb client API for applications to interact with KDC
  • Constructor Details

    • KrbClient

      public KrbClient() throws org.apache.kerby.kerberos.kerb.KrbException
      Default constructor.
      Throws:
      org.apache.kerby.kerberos.kerb.KrbException - e
    • KrbClient

      public KrbClient(KrbConfig krbConfig)
      Construct with prepared KrbConfig.
      Parameters:
      krbConfig - The krb config
    • KrbClient

      public KrbClient(File confDir) throws org.apache.kerby.kerberos.kerb.KrbException
      Constructor with conf dir
      Parameters:
      confDir - The conf dir
      Throws:
      org.apache.kerby.kerberos.kerb.KrbException - e
  • Method Details

    • requestTgt

      public org.apache.kerby.kerberos.kerb.type.ticket.TgtTicket requestTgt(String principal, String password) throws org.apache.kerby.kerberos.kerb.KrbException
      Request a TGT with user plain credential
      Parameters:
      principal - The principal
      password - The password
      Returns:
      The tgt ticket
      Throws:
      org.apache.kerby.kerberos.kerb.KrbException - e
    • requestTgt

      public org.apache.kerby.kerberos.kerb.type.ticket.TgtTicket requestTgt(String principal, File keytabFile) throws org.apache.kerby.kerberos.kerb.KrbException
      Request a TGT with user plain credential
      Parameters:
      principal - The principal
      keytabFile - The keytab file
      Returns:
      TGT
      Throws:
      org.apache.kerby.kerberos.kerb.KrbException - e