APIdia Launch Partner
Top Description Fields Constructors Methods
sun.security.jgss.wrapper

public Class GSSCredElement

extends Object
implements GSSCredentialSpi
Class Inheritance
All Implemented Interfaces
sun.security.jgss.spi.GSSCredentialSpi
Imports
org.ietf.jgss.*, java.lang.ref.Cleaner, java.security.Provider, sun.security.jgss.spi.GSSCredentialSpi, .GSSNameSpi

This class is essentially a wrapper class for the gss_cred_id_t structure of the native GSS library.
Author
Valerie Peng
Since
1.6

Field Summary

Modifier and TypeField and Description
private final Cleaner.Cleanable
private final GSSLibStub
private GSSNameElement
pack-priv final long
private final int

Constructor Summary

AccessConstructor and Description
pack-priv
GSSCredElement(long pCredentials, GSSNameElement srcName, Oid mech)

pack-priv
GSSCredElement(GSSNameElement name, int lifetime, int usage, GSSLibStub stub)

Method Summary

Modifier and TypeMethod and Description
public void
dispose()

Implements sun.security.jgss.spi.GSSCredentialSpi.dispose.

Called to invalidate this credential element and release any system recourses and cryptographic information owned by the credential.

private static Runnable
disposerFor(GSSLibStub stub, long pCredentials)

public int
getAcceptLifetime()

Implements sun.security.jgss.spi.GSSCredentialSpi.getAcceptLifetime.

Returns the accept lifetime remaining.

public int
getInitLifetime()

Implements sun.security.jgss.spi.GSSCredentialSpi.getInitLifetime.

Returns the init lifetime remaining.

public Oid
getMechanism()

Implements sun.security.jgss.spi.GSSCredentialSpi.getMechanism.

Returns the oid representing the underlying credential mechanism oid.

public GSSNameElement
getName()

Implements sun.security.jgss.spi.GSSCredentialSpi.getName.

Returns the principal name for this credential.

public Provider
public GSSCredentialSpi
impersonate(GSSNameSpi name)

Implements sun.security.jgss.spi.GSSCredentialSpi.impersonate.

Impersonates another client.

public boolean
isAcceptorCredential()

Implements sun.security.jgss.spi.GSSCredentialSpi.isAcceptorCredential.

Determines if this credential element can be used by a context acceptor.

public boolean
isInitiatorCredential()

Implements sun.security.jgss.spi.GSSCredentialSpi.isInitiatorCredential.

Determines if this credential element can be used by a context initiator.

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

cleanableback to summary
private final Cleaner.Cleanable cleanable
cStubback to summary
private final GSSLibStub cStub
nameback to summary
private GSSNameElement name
pCredback to summary
pack-priv final long pCred
usageback to summary
private final int usage

Constructor Detail

GSSCredElementback to summary
pack-priv GSSCredElement(long pCredentials, GSSNameElement srcName, Oid mech) throws GSSException
GSSCredElementback to summary
pack-priv GSSCredElement(GSSNameElement name, int lifetime, int usage, GSSLibStub stub) throws GSSException

Method Detail

disposeback to summary
public void dispose()

Implements sun.security.jgss.spi.GSSCredentialSpi.dispose.

Doc from sun.security.jgss.spi.GSSCredentialSpi.dispose.

Called to invalidate this credential element and release any system recourses and cryptographic information owned by the credential.

disposerForback to summary
private static Runnable disposerFor(GSSLibStub stub, long pCredentials)
getAcceptLifetimeback to summary
public int getAcceptLifetime() throws GSSException

Implements sun.security.jgss.spi.GSSCredentialSpi.getAcceptLifetime.

Doc from sun.security.jgss.spi.GSSCredentialSpi.getAcceptLifetime.

Returns the accept lifetime remaining.

Exceptions
GSSException:
may be thrown
getInitLifetimeback to summary
public int getInitLifetime() throws GSSException

Implements sun.security.jgss.spi.GSSCredentialSpi.getInitLifetime.

Doc from sun.security.jgss.spi.GSSCredentialSpi.getInitLifetime.

Returns the init lifetime remaining.

Exceptions
GSSException:
may be thrown
getMechanismback to summary
public Oid getMechanism()

Implements sun.security.jgss.spi.GSSCredentialSpi.getMechanism.

Doc from sun.security.jgss.spi.GSSCredentialSpi.getMechanism.

Returns the oid representing the underlying credential mechanism oid.

getNameback to summary
public GSSNameElement getName() throws GSSException

Implements sun.security.jgss.spi.GSSCredentialSpi.getName.

Doc from sun.security.jgss.spi.GSSCredentialSpi.getName.

Returns the principal name for this credential. The name is in mechanism specific format.

Exceptions
GSSException:
may be thrown
getProviderback to summary
public Provider getProvider()

Implements sun.security.jgss.spi.GSSCredentialSpi.getProvider.

impersonateback to summary
public GSSCredentialSpi impersonate(GSSNameSpi name) throws GSSException

Implements sun.security.jgss.spi.GSSCredentialSpi.impersonate.

Doc from sun.security.jgss.spi.GSSCredentialSpi.impersonate.

Impersonates another client.

Annotations
@Override
Exceptions
GSSException:
may be thrown
isAcceptorCredentialback to summary
public boolean isAcceptorCredential()

Implements sun.security.jgss.spi.GSSCredentialSpi.isAcceptorCredential.

Doc from sun.security.jgss.spi.GSSCredentialSpi.isAcceptorCredential.

Determines if this credential element can be used by a context acceptor.

isInitiatorCredentialback to summary
public boolean isInitiatorCredential()

Implements sun.security.jgss.spi.GSSCredentialSpi.isInitiatorCredential.

Doc from sun.security.jgss.spi.GSSCredentialSpi.isInitiatorCredential.

Determines if this credential element can be used by a context initiator.

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.