com.ibm.security.jgss.mech.spnego

Class SPNEGOName

  1. java.lang.Object
  2. extended bycom.ibm.security.jgss.mech.spnego.SPNEGOName
All implemented interfaces:
GSSNameSpi

  1. public class SPNEGOName
  2. extends java.lang.Object
  3. implements GSSNameSpi
Represents a SPNEGO mechanism specific name element.
Version:
1.0
Author:
Yanni Zhang

Constructor Summary

Constructor and Description
SPNEGOName(byte[] name,Oid nameType)
Constructs a SPNEGOName
SPNEGOName(java.lang.String name,Oid nameType)
Constructs a SPNEGOName

Method Summary

Modifier and Type Method and Description
  1. boolean
equals(GSSNameSpi name)
Equals method for the GSSNameSpi objects.
  1. byte[]
export()
Returns a flat name representation for this object.
  1. Oid
getMechanism()
Get the mechanism type that this NameElement corresponds to.
  1. java.security.Provider
getProvider()
  1. Oid
getStringNameType()
Returns the oid describing the format of the printable name.
  1. boolean
isAnonymousName()
Indicates if this name object represents an Anonymous name.
  1. java.lang.String
toString()
Returns a string representation for this name.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

Constructor Detail

SPNEGOName

  1. public SPNEGOName(java.lang.String name,
  2. Oid nameType)
  3. throws GSSException
Constructs a SPNEGOName
Parameters:
name - name string
nameType - the object identifier corresponding to the name type. SPNEGOName support any name types. If null, then it could be one of the name types supported by selected mechanism
Throws:

SPNEGOName

  1. public SPNEGOName(byte[] name,
  2. Oid nameType)
  3. throws GSSException
Constructs a SPNEGOName
Parameters:
name - name byte array
nameType - the object identifier corresponding to the name type. SPNEGOName support any name types. If null, then it could be one of the name types supported by selected mechanism
Throws:

Method Detail

getProvider

  1. public java.security.Provider getProvider( )
Specified by:
getProvider in interface GSSNameSpi

equals

  1. public boolean equals(GSSNameSpi name)
  2. throws GSSException
Equals method for the GSSNameSpi objects. If either name denotes an anonymous principal, the call should return false.
Specified by:
equals in interface GSSNameSpi
Parameters:
name - to be compared with
Throws:
GSSException - with major codes of BAD_NAMETYPE, BAD_NAME, FAILURE

export

  1. public byte[] export()
  2. throws GSSException
Returns a flat name representation for this object. The name format is defined in RFC 2078.
Specified by:
export in interface GSSNameSpi
Returns:
the flat name representation for this object
Throws:
GSSException - with major codes NAME_NOT_MN, BAD_NAME, BAD_NAME, FAILURE.

getMechanism

  1. public Oid getMechanism()
Get the mechanism type that this NameElement corresponds to.
Specified by:
getMechanism in interface GSSNameSpi
Returns:
the Oid of the mechanism type

toString

  1. public java.lang.String toString( )
Returns a string representation for this name. The printed name type can be obtained by calling getStringNameType().
Specified by:
toString in interface GSSNameSpi
Overrides:
toString in class java.lang.Object
Returns:
string form of this name
See Also:

getStringNameType

  1. public Oid getStringNameType()
Returns the oid describing the format of the printable name.
Specified by:
Returns:
the Oid for the format of the printed name

isAnonymousName

  1. public boolean isAnonymousName( )
Indicates if this name object represents an Anonymous name.
Specified by: