|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.unboundid.ldap.sdk.Control
com.unboundid.ldap.sdk.unboundidds.controls.GetAuthorizationEntryRequestControl
@NotMutable @ThreadSafety(level=COMPLETELY_THREADSAFE) public final class GetAuthorizationEntryRequestControl
NOTE: This class is part of the Commercial Edition of the UnboundID LDAP SDK for Java. It is not available for use in applications that include only the Standard Edition of the LDAP SDK, and is not supported for use in conjunction with non-UnboundID products.This class provides an implementation of an LDAP control that can be included in a bind request to request that the Directory Server return the authentication and authorization entries for the user that authenticated. The value of this control may be absent, but if it is present then will be encoded as follows:
GetAuthorizationEntryRequest ::= SEQUENCE { includeAuthNEntry [0] BOOLEAN DEFAULT TRUE, includeAuthZEntry [1] BOOLEAN DEFAULT TRUE, attributes [2] AttributeSelection OPTIONAL }
ReadOnlyEntry authNEntry = null; ReadOnlyEntry authZEntry = null; BindRequest bindRequest = new SimpleBindRequest( "uid=john.doe,ou=People,dc=example,dc=com", "password", new GetAuthorizationEntryRequestControl()); BindResult bindResult = connection.bind(bindRequest); GetAuthorizationEntryResponseControl c = GetAuthorizationEntryResponseControl.get(bindResult); if (c != null) { authNEntry = c.getAuthNEntry(); authZEntry = c.getAuthZEntry(); }
Field Summary | |
---|---|
static java.lang.String |
GET_AUTHORIZATION_ENTRY_REQUEST_OID
The OID (1.3.6.1.4.1.30221.2.5.6) for the get authorization entry request control. |
Constructor Summary | |
---|---|
GetAuthorizationEntryRequestControl()
Creates a new get authorization entry request control that will request all user attributes in both the authentication and authorization entries. |
|
GetAuthorizationEntryRequestControl(boolean isCritical,
boolean includeAuthNEntry,
boolean includeAuthZEntry,
java.util.List<java.lang.String> attributes)
Creates a new get authorization entry request control with the provided information. |
|
GetAuthorizationEntryRequestControl(boolean isCritical,
boolean includeAuthNEntry,
boolean includeAuthZEntry,
java.lang.String... attributes)
Creates a new get authorization entry request control with the provided information. |
|
GetAuthorizationEntryRequestControl(boolean includeAuthNEntry,
boolean includeAuthZEntry,
java.util.List<java.lang.String> attributes)
Creates a new get authorization entry request control with the provided information. |
|
GetAuthorizationEntryRequestControl(boolean includeAuthNEntry,
boolean includeAuthZEntry,
java.lang.String... attributes)
Creates a new get authorization entry request control with the provided information. |
|
GetAuthorizationEntryRequestControl(Control control)
Creates a new get authorization entry request control which is decoded from the provided generic control. |
Method Summary | |
---|---|
java.util.List<java.lang.String> |
getAttributes()
Retrieves the attributes that will be requested for the authentication and/or authorization entries. |
java.lang.String |
getControlName()
Retrieves the user-friendly name for this control, if available. |
boolean |
includeAuthNEntry()
Indicates whether the entry for the authenticated user should be included in the response control. |
boolean |
includeAuthZEntry()
Indicates whether the entry for the authorized user should be included in the response control. |
void |
toString(java.lang.StringBuilder buffer)
Appends a string representation of this LDAP control to the provided buffer. |
Methods inherited from class com.unboundid.ldap.sdk.Control |
---|
decode, decode, decodeControls, deregisterDecodeableControl, encode, encodeControls, equals, getOID, getValue, hashCode, hasValue, isCritical, readFrom, registerDecodeableControl, toString, writeTo |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String GET_AUTHORIZATION_ENTRY_REQUEST_OID
Constructor Detail |
---|
public GetAuthorizationEntryRequestControl()
public GetAuthorizationEntryRequestControl(boolean includeAuthNEntry, boolean includeAuthZEntry, java.lang.String... attributes)
includeAuthNEntry
- Indicates whether to include the authentication
entry in the response.includeAuthZEntry
- Indicates whether to include the authorization
entry in the response.attributes
- The attributes to include in the entries in the
response. It may be empty or null
to
request all user attributes.public GetAuthorizationEntryRequestControl(boolean includeAuthNEntry, boolean includeAuthZEntry, java.util.List<java.lang.String> attributes)
includeAuthNEntry
- Indicates whether to include the authentication
entry in the response.includeAuthZEntry
- Indicates whether to include the authorization
entry in the response.attributes
- The attributes to include in the entries in the
response. It may be empty or null
to
request all user attributes.public GetAuthorizationEntryRequestControl(boolean isCritical, boolean includeAuthNEntry, boolean includeAuthZEntry, java.lang.String... attributes)
isCritical
- Indicates whether the control should be marked
critical.includeAuthNEntry
- Indicates whether to include the authentication
entry in the response.includeAuthZEntry
- Indicates whether to include the authorization
entry in the response.attributes
- The attributes to include in the entries in the
response. It may be empty or null
to
request all user attributes.public GetAuthorizationEntryRequestControl(boolean isCritical, boolean includeAuthNEntry, boolean includeAuthZEntry, java.util.List<java.lang.String> attributes)
isCritical
- Indicates whether the control should be marked
critical.includeAuthNEntry
- Indicates whether to include the authentication
entry in the response.includeAuthZEntry
- Indicates whether to include the authorization
entry in the response.attributes
- The attributes to include in the entries in the
response. It may be empty or null
to
request all user attributes.public GetAuthorizationEntryRequestControl(Control control) throws LDAPException
control
- The generic control to decode as a get authorization entry
request control.
LDAPException
- If the provided control cannot be decoded as a get
authorization entry request control.Method Detail |
---|
public boolean includeAuthNEntry()
true
if the entry for the authenticated user should be
included in the response control, or false
if not.public boolean includeAuthZEntry()
true
if the entry for the authorized user should be
included in the response control, or false
if not.public java.util.List<java.lang.String> getAttributes()
public java.lang.String getControlName()
getControlName
in class Control
public void toString(java.lang.StringBuilder buffer)
toString
in class Control
buffer
- The buffer to which to append the string representation of
this buffer.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |