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

public Class Krb5AcceptCredential

extends Object
implements Krb5CredElement
Class Inheritance
All Implemented Interfaces
sun.security.jgss.krb5.Krb5CredElement, sun.security.jgss.spi.GSSCredentialSpi
Imports
org.ietf.jgss.*, sun.security.jgss.GSSCaller, sun.security.jgss.spi.*, sun.security.krb5.*, javax.security.auth.DestroyFailedException, javax.security.auth.login.LoginException

Implements the krb5 acceptor credential element.
Author
Mayank Upadhyay
Since
1.4

Field Summary

Modifier and TypeField and Description
private final Krb5NameElement
private final ServiceCreds

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public void
destroy()

Destroys the locally cached EncryptionKey value and then calls destroy in the base class.

public void
dispose()

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

Called to invalidate this credential element.

public int

Returns:

the accept lifetime remaining in seconds
getAcceptLifetime
()

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

Returns the accept lifetime remaining.

public int

Returns:

the init lifetime remaining in seconds
getInitLifetime
()

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

Returns the init lifetime remaining.

pack-priv static Krb5AcceptCredential
public EncryptionKey[]
public final Oid

Returns:

the Oid for this credential mechanism
getMechanism
()

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

Returns the oid representing the underlying credential mechanism oid.

public final GSSNameSpi

Returns:

GSSNameSpi representing principal name of this credential
getName
()

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

Returns the principal name for this credential.

public final Provider
public GSSCredentialSpi
impersonate(GSSNameSpi name)

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

Impersonation is only available on the initiator side.

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.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

nameback to summary
private final Krb5NameElement name
scredsback to summary
private final ServiceCreds screds

Constructor Detail

Krb5AcceptCredentialback to summary
private Krb5AcceptCredential(Krb5NameElement name, ServiceCreds creds)

Method Detail

destroyback to summary
public void destroy() throws DestroyFailedException

Destroys the locally cached EncryptionKey value and then calls destroy in the base class.

disposeback to summary
public void dispose() throws GSSException

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

Called to invalidate this credential element.

Exceptions
GSSException:

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

with major codes NO_CRED and FAILURE

getAcceptLifetimeback to summary
public int getAcceptLifetime() throws GSSException

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

Returns the accept lifetime remaining.

Returns:int

the accept lifetime remaining in seconds

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

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

Returns the init lifetime remaining.

Returns:int

the init lifetime remaining in seconds

Exceptions
GSSException:
may be thrown
getInstanceback to summary
pack-priv static Krb5AcceptCredential getInstance(final GSSCaller caller, Krb5NameElement name) throws GSSException
getKrb5EncryptionKeysback to summary
public EncryptionKey[] getKrb5EncryptionKeys(PrincipalName princ)
getMechanismback to summary
public final Oid getMechanism()

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

Returns the oid representing the underlying credential mechanism oid.

Returns:Oid

the Oid for this credential mechanism

Exceptions
GSSException:
may be thrown
getNameback to summary
public final GSSNameSpi getName() throws GSSException

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

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

Returns:GSSNameSpi

GSSNameSpi representing principal name of this credential

Exceptions
GSSException:
may be thrown
getProviderback to summary
public final 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.

Impersonation is only available on the initiator side. The service must start as an initiator to get an initial TGT to complete the S4U2self protocol.

Annotations
@Override
Exceptions
GSSException:

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

may be thrown

isAcceptorCredentialback to summary
public boolean isAcceptorCredential() throws GSSException

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() throws GSSException

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.