Exceptions & Errors¶
Errors.
- exception freeiam.errors.AdminlimitExceeded(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAdminlimit exceeded.
- exc_class¶
alias of
ADMINLIMIT_EXCEEDED
- exception freeiam.errors.AffectsMultipleDSAs(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAffects multiple Directory System Agent.
- exc_class¶
alias of
AFFECTS_MULTIPLE_DSAS
- exception freeiam.errors.AliasDerefProblem(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorA problem was encountered when dereferencing an alias.
- exc_class¶
alias of
ALIAS_DEREF_PROBLEM
- exception freeiam.errors.AliasProblem(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn alias in the directory points to a nonexistent entry.
- exc_class¶
alias of
ALIAS_PROBLEM
- exception freeiam.errors.AlreadyExists(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe entry already exists. E.g. the DN specified with add() already exists in the DIT.
- exc_class¶
alias of
ALREADY_EXISTS
- exception freeiam.errors.AssertionFailed(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAssertion failed.
- exc_class¶
alias of
ASSERTION_FAILED
- exception freeiam.errors.AuthMethodNotSupported(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAuthentication method is not supported.
- exc_class¶
alias of
AUTH_METHOD_NOT_SUPPORTED
- exception freeiam.errors.AuthUnknown(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe authentication method specified to bind() is not known.
- exc_class¶
alias of
AUTH_UNKNOWN
- exception freeiam.errors.Busy(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe DSA is busy.
- exc_class¶
alias of
BUSY
- exception freeiam.errors.Cancelled(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorCancelled.
- exc_class¶
alias of
CANCELLED
- exception freeiam.errors.CannotCancel(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorCannot cancel.
- exc_class¶
alias of
CANNOT_CANCEL
- exception freeiam.errors.ClientLoop(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorClient loop.
- exc_class¶
alias of
CLIENT_LOOP
- exception freeiam.errors.CompareFalse(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorA compare operation returned False.
- exc_class¶
alias of
COMPARE_FALSE
- exception freeiam.errors.CompareTrue(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorA compare operation returned true.
- exc_class¶
alias of
COMPARE_TRUE
- exception freeiam.errors.ConfidentialityRequired(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorIndicates that the session is not protected by a protocol such as Transport Layer Security (TLS).
which provides session confidentiality.
- exc_class¶
alias of
CONFIDENTIALITY_REQUIRED
- exception freeiam.errors.ConnectError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorConnect error.
- exc_class¶
alias of
CONNECT_ERROR
- exception freeiam.errors.ConstraintViolation(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn attribute value specified or an operation started violates some server-side constraint.
(e.g., a postalAddress has too many lines or a line that is too long or a password is expired).
- exc_class¶
alias of
CONSTRAINT_VIOLATION
- exception freeiam.errors.ControlNotFound(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorControl was not found.
- exc_class¶
alias of
CONTROL_NOT_FOUND
- exception freeiam.errors.DecodingError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn error was encountered decoding a result from the LDAP server.
- exc_class¶
alias of
DECODING_ERROR
- exception freeiam.errors.EncodingError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn error was encountered encoding parameters to send to the LDAP server.
- exc_class¶
alias of
ENCODING_ERROR
- exception freeiam.errors.FilterError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe filter syntax is invalid e.g. due to unbalanced parentheses.
- exc_class¶
alias of
FILTER_ERROR
- exception freeiam.errors.InappropriateAuthentication(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorInappropriate authentication was specified.
(e.g. if the user has no userPassword attribute on a simple bind)
- exc_class¶
alias of
INAPPROPRIATE_AUTH
- exception freeiam.errors.InappropriateMatching(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe filter type is not supported for the specified attribute.
- exc_class¶
alias of
INAPPROPRIATE_MATCHING
- exception freeiam.errors.InsufficientAccess(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe user has insufficient access to perform the operation.
- exc_class¶
alias of
INSUFFICIENT_ACCESS
- exception freeiam.errors.InvalidCredentials(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorInvalid credentials were presented during bind() or simple_bind(). (e.g., a wrong password).
- exc_class¶
alias of
INVALID_CREDENTIALS
- exception freeiam.errors.InvalidDN(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorA syntactically invalid DN was specified.
- exc_class¶
alias of
INVALID_DN_SYNTAX
- exception freeiam.errors.InvalidSyntax(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn attribute value specified by the client did not comply to the syntax defined in the server-side schema.
- exc_class¶
alias of
INVALID_SYNTAX
- exception freeiam.errors.IsLeaf(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe object specified is a leaf of the directory tree.
- exc_class¶
alias of
IS_LEAF
- exception freeiam.errors.LdapError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
ErrorLDAP Error wrapper base class.
- property controls: list[ResponseControl] | None¶
List of LDAP Control instances attached to the error.
- property description: str | None¶
String giving a description of the error class, as provided by calling OpenLDAP’s ldap_err2string on the result.
- property errno: int | None¶
The C errno, usually set by system calls or libc rather than the LDAP libraries.
- exc_class¶
alias of
LDAPError
- classmethod from_ldap_exception(exc: LDAPError) Self[source]¶
Get instance from the correct child exception.
- property info: str | None¶
String containing more information that the server may have sent.
The value is server-specific: for example, the OpenLDAP server may send different info messages than Active Directory or 389-DS
- property matched: str | None¶
Truncated form of the name provided or alias. dereferenced for the lowest entry (object or alias) that was matched.
- property result: int | None¶
Numeric code of the error class.
- exception freeiam.errors.LocalError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorSome local error occurred. Usually caused by failed memory allocation.
- exc_class¶
alias of
LOCAL_ERROR
- exception freeiam.errors.LoopDetected(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorA loop was detected.
- exc_class¶
alias of
LOOP_DETECT
- exception freeiam.errors.MoreResultsToReturn(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorMore results to return.
- exc_class¶
alias of
MORE_RESULTS_TO_RETURN
- exception freeiam.errors.NamingViolation(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorA naming violation occurred. This is raised e.g. if the LDAP server has constraints about the tree naming.
- exc_class¶
alias of
NAMING_VIOLATION
- exception freeiam.errors.NoMemory(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorNo memory.
- exc_class¶
alias of
NO_MEMORY
- exception freeiam.errors.NoObjectClassMods(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorModifying the objectClass attribute as requested is not allowed (e.g. modifying structural object class of existing entry).
- exc_class¶
alias of
NO_OBJECT_CLASS_MODS
- exception freeiam.errors.NoResultsReturned(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorNo results returned.
- exc_class¶
alias of
NO_RESULTS_RETURNED
- exception freeiam.errors.NoSuchAttribute(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe attribute type specified does not exist in the entry.
- exc_class¶
alias of
NO_SUCH_ATTRIBUTE
- exception freeiam.errors.NoSuchObject(*args: Any, **kwargs: Any)[source]¶
Bases:
LdapErrorThe specified object does not exist in the directory.
- property base_dn: freeiam.ldap.dn.DN | None¶
Get search base DN.
- exc_class¶
alias of
NO_SUCH_OBJECT
- exception freeiam.errors.NoSuchOperation(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorNo such operation.
- exc_class¶
alias of
NO_SUCH_OPERATION
- exception freeiam.errors.NoUniqueEntry(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorNo unique entry.
- exc_class¶
alias of
NO_UNIQUE_ENTRY
- exception freeiam.errors.NotAllowedOnNonleaf(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe operation is not allowed on a non-leaf object.
- exc_class¶
alias of
NOT_ALLOWED_ON_NONLEAF
- exception freeiam.errors.NotAllowedOnRDN(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe operation is not allowed on an RDN.
- exc_class¶
alias of
NOT_ALLOWED_ON_RDN
- exception freeiam.errors.NotSupported(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorNot supported.
- exc_class¶
alias of
NOT_SUPPORTED
- exception freeiam.errors.NotUnique[source]¶
Bases:
ErrorMore than one unique search result.
- property results: list[freeiam.ldap._wrapper.Result]¶
The non unique search results.
- exception freeiam.errors.ObjectClassViolation(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn object class violation occurred.
When the LDAP server checked the data sent by the client against the server-side schema (e.g. a “must” attribute was missing in the entry data)
- exc_class¶
alias of
OBJECT_CLASS_VIOLATION
- exception freeiam.errors.OperationsError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn operations error occurred.
- exc_class¶
alias of
OPERATIONS_ERROR
- exception freeiam.errors.Other(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn unclassified error occurred.
- exc_class¶
alias of
OTHER
- exception freeiam.errors.ParamError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn LDAP routine was called with a bad parameter.
- exc_class¶
alias of
PARAM_ERROR
- exception freeiam.errors.PartialResults(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorOnly partial results were returned.
This exception is raised if a referral is received when using LDAPv2. This exception should never be seen with LDAPv3.
- exc_class¶
alias of
PARTIAL_RESULTS
- exception freeiam.errors.ProtocolError(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorA violation of the LDAP protocol was detected.
- exc_class¶
alias of
PROTOCOL_ERROR
- exception freeiam.errors.ProxiedAuthorizationDenied(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorProxied authorization was denied.
- exc_class¶
alias of
PROXIED_AUTHORIZATION_DENIED
- exception freeiam.errors.ProxyAuthZFailure(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorX-Proxy Authorization failure.
- exc_class¶
alias of
X_PROXY_AUTHZ_FAILURE
- exception freeiam.errors.Referral(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorReferral.
- exc_class¶
alias of
REFERRAL
- exception freeiam.errors.ReferralLimitExceeded(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorReferral limit exceeded.
- exc_class¶
alias of
REFERRAL_LIMIT_EXCEEDED
- exception freeiam.errors.ResultsTooLarge(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe result does not fit into a UDP packet.
This happens only when using UDP-based CLDAP (connection-less LDAP) which is not supported anyway.
- exc_class¶
alias of
RESULTS_TOO_LARGE
- exception freeiam.errors.SASLBindInProgress(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorSASL bind in progress.
- exc_class¶
alias of
SASL_BIND_IN_PROGRESS
- exception freeiam.errors.ServerDown(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe LDAP library can’t contact the LDAP server.
- exc_class¶
alias of
SERVER_DOWN
- exception freeiam.errors.SizelimitExceeded(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn LDAP size limit was exceeded. This could be due to a sizelimit configuration on the LDAP server.
- exc_class¶
alias of
SIZELIMIT_EXCEEDED
- exception freeiam.errors.StrongAuthNotSupported(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe LDAP server does not support strong authentication.
- exc_class¶
alias of
STRONG_AUTH_NOT_SUPPORTED
- exception freeiam.errors.StrongAuthRequired(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorStrong authentication is required for the operation.
- exc_class¶
alias of
STRONG_AUTH_REQUIRED
- exception freeiam.errors.Success(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorSuccess.
- exc_class¶
alias of
SUCCESS
- exception freeiam.errors.TimelimitExceeded(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn LDAP time limit was exceeded.
- exc_class¶
alias of
TIMELIMIT_EXCEEDED
- exception freeiam.errors.Timeout(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorA timelimit was exceeded while waiting for a result from the server.
- exc_class¶
alias of
TIMEOUT
- exception freeiam.errors.TooLate(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorToo late.
- exc_class¶
alias of
TOO_LATE
- exception freeiam.errors.TypeOrValueExists(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn attribute type or attribute value specified already exists in the entry.
- exc_class¶
alias of
TYPE_OR_VALUE_EXISTS
Bases:
LdapErrorThe DSA is unavailable.
alias of
UNAVAILABLE
Bases:
LdapErrorIndicates that the LDAP server was unable to satisfy a request.
Because one or more critical extensions were not available. Either the server does not support the control or the control is not appropriate for the operation type.
alias of
UNAVAILABLE_CRITICAL_EXTENSION
- exception freeiam.errors.UndefinedType(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorAn attribute type used is not defined in the server-side schema.
- exc_class¶
alias of
UNDEFINED_TYPE
- exception freeiam.errors.UnwillingToPerform(args: dict[str, str | int | list[tuple[str, int, bytes]]] | None = None)[source]¶
Bases:
LdapErrorThe DSA is unwilling to perform the operation.
- exc_class¶
alias of
UNWILLING_TO_PERFORM