Skip to main content

ldap_client_proto/
lib.rs

1// SPDX-License-Identifier: MIT OR Apache-2.0
2
3pub mod controls;
4pub mod dn;
5pub mod filter;
6pub mod message;
7pub mod result_code;
8pub mod url;
9
10pub use controls::{
11    Control, DOMAIN_SCOPE_OID, DomainScopeControl, MANAGE_DSA_IT_OID, ManageDsaItControl,
12    PAGED_RESULTS_OID, PagedResultsControl, SERVER_SORT_OID, SERVER_SORT_REQUEST_OID,
13    SERVER_SORT_RESPONSE_OID, SortKey, SortKeyList, SortResult,
14};
15pub use dn::{Dn, Rdn, escape_dn_value};
16pub use filter::Filter;
17pub use message::*;
18pub use result_code::ResultCode;
19pub use url::{LdapScheme, LdapUrl};
20
21#[derive(Debug, thiserror::Error)]
22pub enum ProtoError {
23    #[error("BER error: {0}")]
24    Ber(#[from] ldap_client_ber::BerError),
25
26    #[error("protocol error: {0}")]
27    Protocol(String),
28
29    #[error("filter parse error: {0}")]
30    FilterParse(String),
31}