sun.security.mule.krb5
Class KrbApReq

java.lang.Object
  extended by sun.security.mule.krb5.KrbApReq

public class KrbApReq
extends Object

This class encapsulates a KRB-AP-REQ that a client sends to a server for authentication.


Constructor Summary
KrbApReq(byte[] message, EncryptionKey[] keys, InetAddress initiator, Config kerberosConfig)
          Contructs a AP-REQ message from the bytes received from the peer.
KrbApReq(Credentials tgsCred, boolean mutualRequired, boolean useSubKey, boolean useSeqNumber, Checksum cksum, Config kerberosConfig)
          Contructs a AP-REQ message to send to the peer.
 
Method Summary
 Checksum getChecksum()
          Returns the optional Checksum stored in the Authenticator for this message.
 PrincipalName getClient()
          Returns the principal name of the client that generated this message.
 Credentials getCreds()
          Returns the credentials that are contained in the ticket that is part of this this AP-REP.
 byte[] getMessage()
          Returns the ASN.1 encoding that should be sent to the peer.
 boolean getMutualAuthRequired()
          Returns true if mutual authentication is required and hence an AP-REP will need to be generated.
 Integer getSeqNumber()
          Returns the optional sequence number stored in the Authenticator for this message.
 EncryptionKey getSubKey()
          Returns the optional subkey stored in the Authenticator for this message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KrbApReq

public KrbApReq(Credentials tgsCred,
                boolean mutualRequired,
                boolean useSubKey,
                boolean useSeqNumber,
                Checksum cksum,
                Config kerberosConfig)
         throws Asn1Exception,
                KrbCryptoException,
                KrbException,
                IOException
Contructs a AP-REQ message to send to the peer.

Parameters:
tgsCred - the Credentials to be used to construct the AP Request protocol message.
mutualRequired - Whether mutual authentication is required
useSubkey - Whether the subkey is to be used to protect this specific application session. If this is not set then the session key from the ticket will be used.
checksum - checksum of the the application data that accompanies the KRB_AP_REQ.
Throws:
KrbException - for any Kerberos protocol specific error
IOException - for any IO related errors (e.g. socket operations)
Asn1Exception
KrbCryptoException

KrbApReq

public KrbApReq(byte[] message,
                EncryptionKey[] keys,
                InetAddress initiator,
                Config kerberosConfig)
         throws KrbException,
                IOException
Contructs a AP-REQ message from the bytes received from the peer.

Parameters:
message - The message received from the peer
keys - EncrtyptionKeys to decrypt the message; key selected will depend on etype used to encrypte data
Throws:
KrbException - for any Kerberos protocol specific error
IOException - for any IO related errors (e.g. socket operations)
Method Detail

getCreds

public Credentials getCreds()
Returns the credentials that are contained in the ticket that is part of this this AP-REP.


getMutualAuthRequired

public boolean getMutualAuthRequired()
                              throws KrbException,
                                     IOException
Returns true if mutual authentication is required and hence an AP-REP will need to be generated.

Throws:
KrbException
IOException

getSubKey

public EncryptionKey getSubKey()
Returns the optional subkey stored in the Authenticator for this message. Returns null if none is stored.


getSeqNumber

public Integer getSeqNumber()
Returns the optional sequence number stored in the Authenticator for this message. Returns null if none is stored.


getChecksum

public Checksum getChecksum()
Returns the optional Checksum stored in the Authenticator for this message. Returns null if none is stored.


getMessage

public byte[] getMessage()
Returns the ASN.1 encoding that should be sent to the peer.


getClient

public PrincipalName getClient()
Returns the principal name of the client that generated this message.



Copyright © 2013. All Rights Reserved.