com.sun.gssapi

Class ChannelBinding


public class ChannelBinding
extends java.lang.Object

The JGSS accommodates the concept of caller-provided channel binding information. Channel bindings are used to strengthen the quality with which peer entity authentication is provided during context establishment. They enable the JGSS callers to bind the establishment of the a security context to relevant characteristics like addresses or to application specific data.

The caller initiating the security context must determine the appropriate channel binding values to set in the GSSContext object. The acceptor must provide identical binding in order to validate that received tokens possess correct channel-related characteristics.

Use of channel bindings is optional in JGSS. Since channel- binding information may be transmitted in context establishment tokens, applications should therefore not use confidential data as channel-binding components.

See Also:
GSSContext.setChannelBinding(ChannelBinding), java.net.InetAddress

Constructor Summary

ChannelBinding(InetAddress initAddr, InetAddress acceptAddr, byte[] appData)
Construct a channel bindings object that contains all the user specified tags.
ChannelBinding(byte[] appData)
Construct a channel bindings object without any addressing information.

Method Summary

boolean
equals(Object obj)
Compares two instances of ChannelBinding
InetAddress
getAcceptorAddress()
Get the acceptor's address for this channel binding.
byte[]
getApplicationData()
Get the application specified data for this channel binding.
InetAddress
getInitiatorAddress()
Get the initiator's address for this channel binding.

Constructor Details

ChannelBinding

public ChannelBinding(InetAddress initAddr,
                      InetAddress acceptAddr,
                      byte[] appData)
Construct a channel bindings object that contains all the user specified tags.
Parameters:
initAddr - the address of the context initiator
acceptAddr - address of the context acceptor
appData - a byte array of application data to be used as part of the channel-binding

ChannelBinding

public ChannelBinding(byte[] appData)
Construct a channel bindings object without any addressing information.
Parameters:
appData - a byte array of application data to be used as part of the channel-binding

Method Details

equals

public boolean equals(Object obj)
Compares two instances of ChannelBinding
Returns:
true if objects are the same

getAcceptorAddress

public InetAddress getAcceptorAddress()
Get the acceptor's address for this channel binding.
Returns:
the acceptor's address. null if no address information is contained

getApplicationData

public byte[] getApplicationData()
Get the application specified data for this channel binding. The byte array is not copied.
Returns:
byte[] the application data that comprises this channel-binding

getInitiatorAddress

public InetAddress getInitiatorAddress()
Get the initiator's address for this channel binding.
Returns:
the initiator's address. null if no address information is contained