libldap_sys/
bindings.rs

1/* automatically generated by rust-bindgen 0.69.5 */
2
3pub const _BSD_SOURCE: u32 = 1;
4pub const _XOPEN_SOURCE: u32 = 700;
5pub const __BYTE_ORDER: u32 = 1234;
6pub const __LONG_MAX: u64 = 9223372036854775807;
7pub const __LITTLE_ENDIAN: u32 = 1234;
8pub const __BIG_ENDIAN: u32 = 4321;
9pub const __USE_TIME_BITS64: u32 = 1;
10pub const LBER_USE_DER: u32 = 1;
11pub const LBER_OPT_BER_OPTIONS: u32 = 1;
12pub const LBER_OPT_BER_DEBUG: u32 = 2;
13pub const LBER_OPT_BER_REMAINING_BYTES: u32 = 3;
14pub const LBER_OPT_BER_TOTAL_BYTES: u32 = 4;
15pub const LBER_OPT_BER_BYTES_TO_WRITE: u32 = 5;
16pub const LBER_OPT_BER_MEMCTX: u32 = 6;
17pub const LBER_OPT_DEBUG_LEVEL: u32 = 2;
18pub const LBER_OPT_REMAINING_BYTES: u32 = 3;
19pub const LBER_OPT_TOTAL_BYTES: u32 = 4;
20pub const LBER_OPT_BYTES_TO_WRITE: u32 = 5;
21pub const LBER_OPT_LOG_PRINT_FN: u32 = 32769;
22pub const LBER_OPT_MEMORY_FNS: u32 = 32770;
23pub const LBER_OPT_ERROR_FN: u32 = 32771;
24pub const LBER_OPT_LOG_PRINT_FILE: u32 = 32772;
25pub const LBER_OPT_MEMORY_INUSE: u32 = 32773;
26pub const LBER_OPT_LOG_PROC: u32 = 32774;
27pub const LBER_SB_OPT_GET_FD: u32 = 1;
28pub const LBER_SB_OPT_SET_FD: u32 = 2;
29pub const LBER_SB_OPT_HAS_IO: u32 = 3;
30pub const LBER_SB_OPT_SET_NONBLOCK: u32 = 4;
31pub const LBER_SB_OPT_GET_SSL: u32 = 7;
32pub const LBER_SB_OPT_DATA_READY: u32 = 8;
33pub const LBER_SB_OPT_SET_READAHEAD: u32 = 9;
34pub const LBER_SB_OPT_DRAIN: u32 = 10;
35pub const LBER_SB_OPT_NEEDS_READ: u32 = 11;
36pub const LBER_SB_OPT_NEEDS_WRITE: u32 = 12;
37pub const LBER_SB_OPT_GET_MAX_INCOMING: u32 = 13;
38pub const LBER_SB_OPT_SET_MAX_INCOMING: u32 = 14;
39pub const LBER_SB_OPT_UNGET_BUF: u32 = 15;
40pub const LBER_SB_OPT_OPT_MAX: u32 = 15;
41pub const LBER_SBIOD_LEVEL_PROVIDER: u32 = 10;
42pub const LBER_SBIOD_LEVEL_TRANSPORT: u32 = 20;
43pub const LBER_SBIOD_LEVEL_APPLICATION: u32 = 30;
44pub const LBER_OPT_SOCKBUF_DESC: u32 = 4096;
45pub const LBER_OPT_SOCKBUF_OPTIONS: u32 = 4097;
46pub const LBER_OPT_SOCKBUF_DEBUG: u32 = 4098;
47pub const LBER_OPT_SUCCESS: u32 = 0;
48pub const LBER_OPT_ERROR: i32 = -1;
49pub const LBER_BV_ALLOC: u32 = 1;
50pub const LBER_BV_NOTERM: u32 = 2;
51pub const LBER_BV_STRING: u32 = 4;
52pub const LBER_FLUSH_FREE_NEVER: u32 = 0;
53pub const LBER_FLUSH_FREE_ON_SUCCESS: u32 = 1;
54pub const LBER_FLUSH_FREE_ON_ERROR: u32 = 2;
55pub const LBER_FLUSH_FREE_ALWAYS: u32 = 3;
56pub const LBER_ERROR_NONE: u32 = 0;
57pub const LBER_ERROR_PARAM: u32 = 1;
58pub const LBER_ERROR_MEMORY: u32 = 2;
59pub const _LDAP_FEATURES_H: u32 = 1;
60pub const LDAP_VENDOR_VERSION: u32 = 20608;
61pub const LDAP_VENDOR_VERSION_MAJOR: u32 = 2;
62pub const LDAP_VENDOR_VERSION_MINOR: u32 = 6;
63pub const LDAP_VENDOR_VERSION_PATCH: u32 = 8;
64pub const LDAP_API_FEATURE_X_OPENLDAP_REENTRANT: u32 = 1;
65pub const LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE: u32 = 1;
66pub const LDAP_VERSION1: u32 = 1;
67pub const LDAP_VERSION2: u32 = 2;
68pub const LDAP_VERSION3: u32 = 3;
69pub const LDAP_VERSION_MIN: u32 = 2;
70pub const LDAP_VERSION: u32 = 2;
71pub const LDAP_VERSION_MAX: u32 = 3;
72pub const LDAP_API_VERSION: u32 = 3001;
73pub const LDAP_VENDOR_NAME: &[u8; 9] = b"OpenLDAP\0";
74pub const LDAP_API_FEATURE_X_OPENLDAP: u32 = 20608;
75pub const LDAP_API_FEATURE_THREAD_SAFE: u32 = 1;
76pub const LDAP_API_FEATURE_SESSION_THREAD_SAFE: u32 = 1;
77pub const LDAP_API_FEATURE_OPERATION_THREAD_SAFE: u32 = 1;
78pub const LDAP_PORT: u32 = 389;
79pub const LDAPS_PORT: u32 = 636;
80pub const LDAP_ROOT_DSE: &[u8; 1] = b"\0";
81pub const LDAP_NO_ATTRS: &[u8; 4] = b"1.1\0";
82pub const LDAP_ALL_USER_ATTRIBUTES: &[u8; 2] = b"*\0";
83pub const LDAP_ALL_OPERATIONAL_ATTRIBUTES: &[u8; 2] = b"+\0";
84pub const LDAP_MAXINT: u32 = 2147483647;
85pub const LDAP_OPT_API_INFO: u32 = 0;
86pub const LDAP_OPT_DESC: u32 = 1;
87pub const LDAP_OPT_DEREF: u32 = 2;
88pub const LDAP_OPT_SIZELIMIT: u32 = 3;
89pub const LDAP_OPT_TIMELIMIT: u32 = 4;
90pub const LDAP_OPT_REFERRALS: u32 = 8;
91pub const LDAP_OPT_RESTART: u32 = 9;
92pub const LDAP_OPT_PROTOCOL_VERSION: u32 = 17;
93pub const LDAP_OPT_SERVER_CONTROLS: u32 = 18;
94pub const LDAP_OPT_CLIENT_CONTROLS: u32 = 19;
95pub const LDAP_OPT_API_FEATURE_INFO: u32 = 21;
96pub const LDAP_OPT_HOST_NAME: u32 = 48;
97pub const LDAP_OPT_RESULT_CODE: u32 = 49;
98pub const LDAP_OPT_ERROR_NUMBER: u32 = 49;
99pub const LDAP_OPT_DIAGNOSTIC_MESSAGE: u32 = 50;
100pub const LDAP_OPT_ERROR_STRING: u32 = 50;
101pub const LDAP_OPT_MATCHED_DN: u32 = 51;
102pub const LDAP_OPT_SSPI_FLAGS: u32 = 146;
103pub const LDAP_OPT_SIGN: u32 = 149;
104pub const LDAP_OPT_ENCRYPT: u32 = 150;
105pub const LDAP_OPT_SASL_METHOD: u32 = 151;
106pub const LDAP_OPT_SECURITY_CONTEXT: u32 = 153;
107pub const LDAP_OPT_API_EXTENSION_BASE: u32 = 16384;
108pub const LDAP_OPT_DEBUG_LEVEL: u32 = 20481;
109pub const LDAP_OPT_TIMEOUT: u32 = 20482;
110pub const LDAP_OPT_REFHOPLIMIT: u32 = 20483;
111pub const LDAP_OPT_NETWORK_TIMEOUT: u32 = 20485;
112pub const LDAP_OPT_URI: u32 = 20486;
113pub const LDAP_OPT_REFERRAL_URLS: u32 = 20487;
114pub const LDAP_OPT_SOCKBUF: u32 = 20488;
115pub const LDAP_OPT_DEFBASE: u32 = 20489;
116pub const LDAP_OPT_CONNECT_ASYNC: u32 = 20496;
117pub const LDAP_OPT_CONNECT_CB: u32 = 20497;
118pub const LDAP_OPT_SESSION_REFCNT: u32 = 20498;
119pub const LDAP_OPT_KEEPCONN: u32 = 20499;
120pub const LDAP_OPT_SOCKET_BIND_ADDRESSES: u32 = 20500;
121pub const LDAP_OPT_TCP_USER_TIMEOUT: u32 = 20501;
122pub const LDAP_OPT_X_TLS: u32 = 24576;
123pub const LDAP_OPT_X_TLS_CTX: u32 = 24577;
124pub const LDAP_OPT_X_TLS_CACERTFILE: u32 = 24578;
125pub const LDAP_OPT_X_TLS_CACERTDIR: u32 = 24579;
126pub const LDAP_OPT_X_TLS_CERTFILE: u32 = 24580;
127pub const LDAP_OPT_X_TLS_KEYFILE: u32 = 24581;
128pub const LDAP_OPT_X_TLS_REQUIRE_CERT: u32 = 24582;
129pub const LDAP_OPT_X_TLS_PROTOCOL_MIN: u32 = 24583;
130pub const LDAP_OPT_X_TLS_CIPHER_SUITE: u32 = 24584;
131pub const LDAP_OPT_X_TLS_RANDOM_FILE: u32 = 24585;
132pub const LDAP_OPT_X_TLS_SSL_CTX: u32 = 24586;
133pub const LDAP_OPT_X_TLS_CRLCHECK: u32 = 24587;
134pub const LDAP_OPT_X_TLS_CONNECT_CB: u32 = 24588;
135pub const LDAP_OPT_X_TLS_CONNECT_ARG: u32 = 24589;
136pub const LDAP_OPT_X_TLS_DHFILE: u32 = 24590;
137pub const LDAP_OPT_X_TLS_NEWCTX: u32 = 24591;
138pub const LDAP_OPT_X_TLS_CRLFILE: u32 = 24592;
139pub const LDAP_OPT_X_TLS_PACKAGE: u32 = 24593;
140pub const LDAP_OPT_X_TLS_ECNAME: u32 = 24594;
141pub const LDAP_OPT_X_TLS_VERSION: u32 = 24595;
142pub const LDAP_OPT_X_TLS_CIPHER: u32 = 24596;
143pub const LDAP_OPT_X_TLS_PEERCERT: u32 = 24597;
144pub const LDAP_OPT_X_TLS_CACERT: u32 = 24598;
145pub const LDAP_OPT_X_TLS_CERT: u32 = 24599;
146pub const LDAP_OPT_X_TLS_KEY: u32 = 24600;
147pub const LDAP_OPT_X_TLS_PEERKEY_HASH: u32 = 24601;
148pub const LDAP_OPT_X_TLS_REQUIRE_SAN: u32 = 24602;
149pub const LDAP_OPT_X_TLS_PROTOCOL_MAX: u32 = 24603;
150pub const LDAP_OPT_X_TLS_NEVER: u32 = 0;
151pub const LDAP_OPT_X_TLS_HARD: u32 = 1;
152pub const LDAP_OPT_X_TLS_DEMAND: u32 = 2;
153pub const LDAP_OPT_X_TLS_ALLOW: u32 = 3;
154pub const LDAP_OPT_X_TLS_TRY: u32 = 4;
155pub const LDAP_OPT_X_TLS_CRL_NONE: u32 = 0;
156pub const LDAP_OPT_X_TLS_CRL_PEER: u32 = 1;
157pub const LDAP_OPT_X_TLS_CRL_ALL: u32 = 2;
158pub const LDAP_OPT_X_TLS_PROTOCOL_SSL2: u32 = 512;
159pub const LDAP_OPT_X_TLS_PROTOCOL_SSL3: u32 = 768;
160pub const LDAP_OPT_X_TLS_PROTOCOL_TLS1_0: u32 = 769;
161pub const LDAP_OPT_X_TLS_PROTOCOL_TLS1_1: u32 = 770;
162pub const LDAP_OPT_X_TLS_PROTOCOL_TLS1_2: u32 = 771;
163pub const LDAP_OPT_X_TLS_PROTOCOL_TLS1_3: u32 = 772;
164pub const LDAP_OPT_X_SASL_CBINDING_NONE: u32 = 0;
165pub const LDAP_OPT_X_SASL_CBINDING_TLS_UNIQUE: u32 = 1;
166pub const LDAP_OPT_X_SASL_CBINDING_TLS_ENDPOINT: u32 = 2;
167pub const LDAP_OPT_X_SASL_MECH: u32 = 24832;
168pub const LDAP_OPT_X_SASL_REALM: u32 = 24833;
169pub const LDAP_OPT_X_SASL_AUTHCID: u32 = 24834;
170pub const LDAP_OPT_X_SASL_AUTHZID: u32 = 24835;
171pub const LDAP_OPT_X_SASL_SSF: u32 = 24836;
172pub const LDAP_OPT_X_SASL_SSF_EXTERNAL: u32 = 24837;
173pub const LDAP_OPT_X_SASL_SECPROPS: u32 = 24838;
174pub const LDAP_OPT_X_SASL_SSF_MIN: u32 = 24839;
175pub const LDAP_OPT_X_SASL_SSF_MAX: u32 = 24840;
176pub const LDAP_OPT_X_SASL_MAXBUFSIZE: u32 = 24841;
177pub const LDAP_OPT_X_SASL_MECHLIST: u32 = 24842;
178pub const LDAP_OPT_X_SASL_NOCANON: u32 = 24843;
179pub const LDAP_OPT_X_SASL_USERNAME: u32 = 24844;
180pub const LDAP_OPT_X_SASL_GSS_CREDS: u32 = 24845;
181pub const LDAP_OPT_X_SASL_CBINDING: u32 = 24846;
182pub const LDAP_OPT_X_KEEPALIVE_IDLE: u32 = 25344;
183pub const LDAP_OPT_X_KEEPALIVE_PROBES: u32 = 25345;
184pub const LDAP_OPT_X_KEEPALIVE_INTERVAL: u32 = 25346;
185pub const LDAP_OPT_PRIVATE_EXTENSION_BASE: u32 = 28672;
186pub const LDAP_OPT_SUCCESS: u32 = 0;
187pub const LDAP_OPT_ERROR: i32 = -1;
188pub const LDAP_API_INFO_VERSION: u32 = 1;
189pub const LDAP_FEATURE_INFO_VERSION: u32 = 1;
190pub const LDAP_CONTROL_MANAGEDSAIT: &[u8; 24] = b"2.16.840.1.113730.3.4.2\0";
191pub const LDAP_CONTROL_PROXY_AUTHZ: &[u8; 25] = b"2.16.840.1.113730.3.4.18\0";
192pub const LDAP_CONTROL_SUBENTRIES: &[u8; 24] = b"1.3.6.1.4.1.4203.1.10.1\0";
193pub const LDAP_CONTROL_VALUESRETURNFILTER: &[u8; 24] = b"1.2.826.0.1.3344810.2.3\0";
194pub const LDAP_CONTROL_ASSERT: &[u8; 13] = b"1.3.6.1.1.12\0";
195pub const LDAP_CONTROL_PRE_READ: &[u8; 15] = b"1.3.6.1.1.13.1\0";
196pub const LDAP_CONTROL_POST_READ: &[u8; 15] = b"1.3.6.1.1.13.2\0";
197pub const LDAP_CONTROL_SORTREQUEST: &[u8; 23] = b"1.2.840.113556.1.4.473\0";
198pub const LDAP_CONTROL_SORTRESPONSE: &[u8; 23] = b"1.2.840.113556.1.4.474\0";
199pub const LDAP_CONTROL_PAGEDRESULTS: &[u8; 23] = b"1.2.840.113556.1.4.319\0";
200pub const LDAP_CONTROL_AUTHZID_REQUEST: &[u8; 25] = b"2.16.840.1.113730.3.4.16\0";
201pub const LDAP_CONTROL_AUTHZID_RESPONSE: &[u8; 25] = b"2.16.840.1.113730.3.4.15\0";
202pub const LDAP_SYNC_OID: &[u8; 23] = b"1.3.6.1.4.1.4203.1.9.1\0";
203pub const LDAP_CONTROL_SYNC: &[u8; 25] = b"1.3.6.1.4.1.4203.1.9.1.1\0";
204pub const LDAP_CONTROL_SYNC_STATE: &[u8; 25] = b"1.3.6.1.4.1.4203.1.9.1.2\0";
205pub const LDAP_CONTROL_SYNC_DONE: &[u8; 25] = b"1.3.6.1.4.1.4203.1.9.1.3\0";
206pub const LDAP_SYNC_INFO: &[u8; 25] = b"1.3.6.1.4.1.4203.1.9.1.4\0";
207pub const LDAP_SYNC_NONE: u32 = 0;
208pub const LDAP_SYNC_REFRESH_ONLY: u32 = 1;
209pub const LDAP_SYNC_RESERVED: u32 = 2;
210pub const LDAP_SYNC_REFRESH_AND_PERSIST: u32 = 3;
211pub const LDAP_SYNC_REFRESH_PRESENTS: u32 = 0;
212pub const LDAP_SYNC_REFRESH_DELETES: u32 = 1;
213pub const LDAP_SYNC_PRESENT: u32 = 0;
214pub const LDAP_SYNC_ADD: u32 = 1;
215pub const LDAP_SYNC_MODIFY: u32 = 2;
216pub const LDAP_SYNC_DELETE: u32 = 3;
217pub const LDAP_SYNC_NEW_COOKIE: u32 = 4;
218pub const LDAP_CONTROL_DONTUSECOPY: &[u8; 13] = b"1.3.6.1.1.22\0";
219pub const LDAP_CONTROL_PASSWORDPOLICYREQUEST: &[u8; 26] = b"1.3.6.1.4.1.42.2.27.8.5.1\0";
220pub const LDAP_CONTROL_PASSWORDPOLICYRESPONSE: &[u8; 26] = b"1.3.6.1.4.1.42.2.27.8.5.1\0";
221pub const LDAP_CONTROL_NOOP: &[u8; 25] = b"1.3.6.1.4.1.4203.666.5.2\0";
222pub const LDAP_CONTROL_NO_SUBORDINATES: &[u8; 26] = b"1.3.6.1.4.1.4203.666.5.11\0";
223pub const LDAP_CONTROL_RELAX: &[u8; 26] = b"1.3.6.1.4.1.4203.666.5.12\0";
224pub const LDAP_CONTROL_MANAGEDIT: &[u8; 26] = b"1.3.6.1.4.1.4203.666.5.12\0";
225pub const LDAP_CONTROL_SLURP: &[u8; 26] = b"1.3.6.1.4.1.4203.666.5.13\0";
226pub const LDAP_CONTROL_VALSORT: &[u8; 26] = b"1.3.6.1.4.1.4203.666.5.14\0";
227pub const LDAP_CONTROL_X_DEREF: &[u8; 26] = b"1.3.6.1.4.1.4203.666.5.16\0";
228pub const LDAP_CONTROL_X_WHATFAILED: &[u8; 26] = b"1.3.6.1.4.1.4203.666.5.17\0";
229pub const LDAP_CONTROL_X_CHAINING_BEHAVIOR: &[u8; 26] = b"1.3.6.1.4.1.4203.666.11.3\0";
230pub const LDAP_CHAINING_PREFERRED: u32 = 0;
231pub const LDAP_CHAINING_REQUIRED: u32 = 1;
232pub const LDAP_REFERRALS_PREFERRED: u32 = 2;
233pub const LDAP_REFERRALS_REQUIRED: u32 = 3;
234pub const LDAP_CONTROL_X_LAZY_COMMIT: &[u8; 23] = b"1.2.840.113556.1.4.619\0";
235pub const LDAP_CONTROL_X_INCREMENTAL_VALUES: &[u8; 23] = b"1.2.840.113556.1.4.802\0";
236pub const LDAP_CONTROL_X_DOMAIN_SCOPE: &[u8; 24] = b"1.2.840.113556.1.4.1339\0";
237pub const LDAP_CONTROL_X_PERMISSIVE_MODIFY: &[u8; 24] = b"1.2.840.113556.1.4.1413\0";
238pub const LDAP_CONTROL_X_SEARCH_OPTIONS: &[u8; 24] = b"1.2.840.113556.1.4.1340\0";
239pub const LDAP_SEARCH_FLAG_DOMAIN_SCOPE: u32 = 1;
240pub const LDAP_SEARCH_FLAG_PHANTOM_ROOT: u32 = 2;
241pub const LDAP_CONTROL_X_TREE_DELETE: &[u8; 23] = b"1.2.840.113556.1.4.805\0";
242pub const LDAP_CONTROL_X_SERVER_NOTIFICATION: &[u8; 23] = b"1.2.840.113556.1.4.528\0";
243pub const LDAP_CONTROL_X_EXTENDED_DN: &[u8; 23] = b"1.2.840.113556.1.4.529\0";
244pub const LDAP_CONTROL_X_SHOW_DELETED: &[u8; 23] = b"1.2.840.113556.1.4.417\0";
245pub const LDAP_CONTROL_X_DIRSYNC: &[u8; 23] = b"1.2.840.113556.1.4.841\0";
246pub const LDAP_CONTROL_X_DIRSYNC_OBJECT_SECURITY: u32 = 1;
247pub const LDAP_CONTROL_X_DIRSYNC_ANCESTORS_FIRST: u32 = 2048;
248pub const LDAP_CONTROL_X_DIRSYNC_PUBLIC_DATA_ONLY: u32 = 8192;
249pub const LDAP_CONTROL_X_DIRSYNC_INCREMENTAL_VALUES: u32 = 2147483648;
250pub const LDAP_CONTROL_X_SESSION_TRACKING: &[u8; 27] = b"1.3.6.1.4.1.21008.108.63.1\0";
251pub const LDAP_CONTROL_X_SESSION_TRACKING_RADIUS_ACCT_SESSION_ID: &[u8; 29] = b"1.3.6.1.4.1.21008.108.63.1.1\0";
252pub const LDAP_CONTROL_X_SESSION_TRACKING_RADIUS_ACCT_MULTI_SESSION_ID: &[u8; 29] = b"1.3.6.1.4.1.21008.108.63.1.2\0";
253pub const LDAP_CONTROL_X_SESSION_TRACKING_USERNAME: &[u8; 29] = b"1.3.6.1.4.1.21008.108.63.1.3\0";
254pub const LDAP_CONTROL_DUPENT_REQUEST: &[u8; 29] = b"2.16.840.1.113719.1.27.101.1\0";
255pub const LDAP_CONTROL_DUPENT_RESPONSE: &[u8; 29] = b"2.16.840.1.113719.1.27.101.2\0";
256pub const LDAP_CONTROL_DUPENT_ENTRY: &[u8; 29] = b"2.16.840.1.113719.1.27.101.3\0";
257pub const LDAP_CONTROL_DUPENT: &[u8; 29] = b"2.16.840.1.113719.1.27.101.1\0";
258pub const LDAP_CONTROL_PERSIST_REQUEST: &[u8; 24] = b"2.16.840.1.113730.3.4.3\0";
259pub const LDAP_CONTROL_PERSIST_ENTRY_CHANGE_NOTICE: &[u8; 24] = b"2.16.840.1.113730.3.4.7\0";
260pub const LDAP_CONTROL_PERSIST_ENTRY_CHANGE_ADD: u32 = 1;
261pub const LDAP_CONTROL_PERSIST_ENTRY_CHANGE_DELETE: u32 = 2;
262pub const LDAP_CONTROL_PERSIST_ENTRY_CHANGE_MODIFY: u32 = 4;
263pub const LDAP_CONTROL_PERSIST_ENTRY_CHANGE_RENAME: u32 = 8;
264pub const LDAP_CONTROL_VLVREQUEST: &[u8; 24] = b"2.16.840.1.113730.3.4.9\0";
265pub const LDAP_CONTROL_VLVRESPONSE: &[u8; 25] = b"2.16.840.1.113730.3.4.10\0";
266pub const LDAP_CONTROL_X_ACCOUNT_USABILITY: &[u8; 26] = b"1.3.6.1.4.1.42.2.27.9.5.8\0";
267pub const LDAP_CONTROL_X_PASSWORD_EXPIRED: &[u8; 24] = b"2.16.840.1.113730.3.4.4\0";
268pub const LDAP_CONTROL_X_PASSWORD_EXPIRING: &[u8; 24] = b"2.16.840.1.113730.3.4.5\0";
269pub const LDAP_NOTICE_OF_DISCONNECTION: &[u8; 23] = b"1.3.6.1.4.1.1466.20036\0";
270pub const LDAP_NOTICE_DISCONNECT: &[u8; 23] = b"1.3.6.1.4.1.1466.20036\0";
271pub const LDAP_EXOP_START_TLS: &[u8; 23] = b"1.3.6.1.4.1.1466.20037\0";
272pub const LDAP_EXOP_MODIFY_PASSWD: &[u8; 24] = b"1.3.6.1.4.1.4203.1.11.1\0";
273pub const LDAP_EXOP_CANCEL: &[u8; 12] = b"1.3.6.1.1.8\0";
274pub const LDAP_EXOP_X_CANCEL: &[u8; 12] = b"1.3.6.1.1.8\0";
275pub const LDAP_EXOP_REFRESH: &[u8; 27] = b"1.3.6.1.4.1.1466.101.119.1\0";
276pub const LDAP_EXOP_VERIFY_CREDENTIALS: &[u8; 25] = b"1.3.6.1.4.1.4203.666.6.5\0";
277pub const LDAP_EXOP_X_VERIFY_CREDENTIALS: &[u8; 25] = b"1.3.6.1.4.1.4203.666.6.5\0";
278pub const LDAP_EXOP_WHO_AM_I: &[u8; 24] = b"1.3.6.1.4.1.4203.1.11.3\0";
279pub const LDAP_EXOP_X_WHO_AM_I: &[u8; 24] = b"1.3.6.1.4.1.4203.1.11.3\0";
280pub const LDAP_EXOP_TURN: &[u8; 13] = b"1.3.6.1.1.19\0";
281pub const LDAP_EXOP_X_TURN: &[u8; 13] = b"1.3.6.1.1.19\0";
282pub const LDAP_X_DISTPROC_BASE: &[u8; 26] = b"1.3.6.1.4.1.4203.666.11.6\0";
283pub const LDAP_EXOP_X_CHAINEDREQUEST: &[u8; 28] = b"1.3.6.1.4.1.4203.666.11.6.1\0";
284pub const LDAP_FEATURE_X_CANCHAINOPS: &[u8; 28] = b"1.3.6.1.4.1.4203.666.11.6.2\0";
285pub const LDAP_CONTROL_X_RETURNCONTREF: &[u8; 28] = b"1.3.6.1.4.1.4203.666.11.6.3\0";
286pub const LDAP_URLEXT_X_LOCALREFOID: &[u8; 28] = b"1.3.6.1.4.1.4203.666.11.6.4\0";
287pub const LDAP_URLEXT_X_REFTYPEOID: &[u8; 28] = b"1.3.6.1.4.1.4203.666.11.6.5\0";
288pub const LDAP_URLEXT_X_SEARCHEDSUBTREEOID: &[u8; 28] = b"1.3.6.1.4.1.4203.666.11.6.6\0";
289pub const LDAP_URLEXT_X_FAILEDNAMEOID: &[u8; 28] = b"1.3.6.1.4.1.4203.666.11.6.7\0";
290pub const LDAP_URLEXT_X_LOCALREF: &[u8; 17] = b"x-localReference\0";
291pub const LDAP_URLEXT_X_REFTYPE: &[u8; 16] = b"x-referenceType\0";
292pub const LDAP_URLEXT_X_SEARCHEDSUBTREE: &[u8; 18] = b"x-searchedSubtree\0";
293pub const LDAP_URLEXT_X_FAILEDNAME: &[u8; 13] = b"x-failedName\0";
294pub const LDAP_TXN: &[u8; 13] = b"1.3.6.1.1.21\0";
295pub const LDAP_EXOP_TXN_START: &[u8; 15] = b"1.3.6.1.1.21.1\0";
296pub const LDAP_CONTROL_TXN_SPEC: &[u8; 15] = b"1.3.6.1.1.21.2\0";
297pub const LDAP_EXOP_TXN_END: &[u8; 15] = b"1.3.6.1.1.21.3\0";
298pub const LDAP_EXOP_TXN_ABORTED_NOTICE: &[u8; 15] = b"1.3.6.1.1.21.4\0";
299pub const LDAP_FEATURE_ALL_OP_ATTRS: &[u8; 23] = b"1.3.6.1.4.1.4203.1.5.1\0";
300pub const LDAP_FEATURE_OBJECTCLASS_ATTRS: &[u8; 23] = b"1.3.6.1.4.1.4203.1.5.2\0";
301pub const LDAP_FEATURE_ABSOLUTE_FILTERS: &[u8; 23] = b"1.3.6.1.4.1.4203.1.5.3\0";
302pub const LDAP_FEATURE_LANGUAGE_TAG_OPTIONS: &[u8; 23] = b"1.3.6.1.4.1.4203.1.5.4\0";
303pub const LDAP_FEATURE_LANGUAGE_RANGE_OPTIONS: &[u8; 23] = b"1.3.6.1.4.1.4203.1.5.5\0";
304pub const LDAP_FEATURE_MODIFY_INCREMENT: &[u8; 13] = b"1.3.6.1.1.14\0";
305pub const LDAP_FEATURE_SUBORDINATE_SCOPE: &[u8; 25] = b"1.3.6.1.4.1.4203.666.8.1\0";
306pub const LDAP_FEATURE_CHILDREN_SCOPE: &[u8; 25] = b"1.3.6.1.4.1.4203.666.8.1\0";
307pub const LDAP_RES_ANY: i32 = -1;
308pub const LDAP_RES_UNSOLICITED: u32 = 0;
309pub const LDAP_SASL_NULL: &[u8; 1] = b"\0";
310pub const LDAP_SUCCESS: u32 = 0;
311pub const LDAP_OPERATIONS_ERROR: u32 = 1;
312pub const LDAP_PROTOCOL_ERROR: u32 = 2;
313pub const LDAP_TIMELIMIT_EXCEEDED: u32 = 3;
314pub const LDAP_SIZELIMIT_EXCEEDED: u32 = 4;
315pub const LDAP_COMPARE_FALSE: u32 = 5;
316pub const LDAP_COMPARE_TRUE: u32 = 6;
317pub const LDAP_AUTH_METHOD_NOT_SUPPORTED: u32 = 7;
318pub const LDAP_STRONG_AUTH_NOT_SUPPORTED: u32 = 7;
319pub const LDAP_STRONG_AUTH_REQUIRED: u32 = 8;
320pub const LDAP_STRONGER_AUTH_REQUIRED: u32 = 8;
321pub const LDAP_PARTIAL_RESULTS: u32 = 9;
322pub const LDAP_REFERRAL: u32 = 10;
323pub const LDAP_ADMINLIMIT_EXCEEDED: u32 = 11;
324pub const LDAP_UNAVAILABLE_CRITICAL_EXTENSION: u32 = 12;
325pub const LDAP_CONFIDENTIALITY_REQUIRED: u32 = 13;
326pub const LDAP_SASL_BIND_IN_PROGRESS: u32 = 14;
327pub const LDAP_NO_SUCH_ATTRIBUTE: u32 = 16;
328pub const LDAP_UNDEFINED_TYPE: u32 = 17;
329pub const LDAP_INAPPROPRIATE_MATCHING: u32 = 18;
330pub const LDAP_CONSTRAINT_VIOLATION: u32 = 19;
331pub const LDAP_TYPE_OR_VALUE_EXISTS: u32 = 20;
332pub const LDAP_INVALID_SYNTAX: u32 = 21;
333pub const LDAP_NO_SUCH_OBJECT: u32 = 32;
334pub const LDAP_ALIAS_PROBLEM: u32 = 33;
335pub const LDAP_INVALID_DN_SYNTAX: u32 = 34;
336pub const LDAP_IS_LEAF: u32 = 35;
337pub const LDAP_ALIAS_DEREF_PROBLEM: u32 = 36;
338pub const LDAP_X_PROXY_AUTHZ_FAILURE: u32 = 47;
339pub const LDAP_INAPPROPRIATE_AUTH: u32 = 48;
340pub const LDAP_INVALID_CREDENTIALS: u32 = 49;
341pub const LDAP_INSUFFICIENT_ACCESS: u32 = 50;
342pub const LDAP_BUSY: u32 = 51;
343pub const LDAP_UNAVAILABLE: u32 = 52;
344pub const LDAP_UNWILLING_TO_PERFORM: u32 = 53;
345pub const LDAP_LOOP_DETECT: u32 = 54;
346pub const LDAP_NAMING_VIOLATION: u32 = 64;
347pub const LDAP_OBJECT_CLASS_VIOLATION: u32 = 65;
348pub const LDAP_NOT_ALLOWED_ON_NONLEAF: u32 = 66;
349pub const LDAP_NOT_ALLOWED_ON_RDN: u32 = 67;
350pub const LDAP_ALREADY_EXISTS: u32 = 68;
351pub const LDAP_NO_OBJECT_CLASS_MODS: u32 = 69;
352pub const LDAP_RESULTS_TOO_LARGE: u32 = 70;
353pub const LDAP_AFFECTS_MULTIPLE_DSAS: u32 = 71;
354pub const LDAP_VLV_ERROR: u32 = 76;
355pub const LDAP_OTHER: u32 = 80;
356pub const LDAP_CUP_RESOURCES_EXHAUSTED: u32 = 113;
357pub const LDAP_CUP_SECURITY_VIOLATION: u32 = 114;
358pub const LDAP_CUP_INVALID_DATA: u32 = 115;
359pub const LDAP_CUP_UNSUPPORTED_SCHEME: u32 = 116;
360pub const LDAP_CUP_RELOAD_REQUIRED: u32 = 117;
361pub const LDAP_CANCELLED: u32 = 118;
362pub const LDAP_NO_SUCH_OPERATION: u32 = 119;
363pub const LDAP_TOO_LATE: u32 = 120;
364pub const LDAP_CANNOT_CANCEL: u32 = 121;
365pub const LDAP_ASSERTION_FAILED: u32 = 122;
366pub const LDAP_PROXIED_AUTHORIZATION_DENIED: u32 = 123;
367pub const LDAP_SYNC_REFRESH_REQUIRED: u32 = 4096;
368pub const LDAP_X_SYNC_REFRESH_REQUIRED: u32 = 16640;
369pub const LDAP_X_ASSERTION_FAILED: u32 = 16655;
370pub const LDAP_X_NO_OPERATION: u32 = 16654;
371pub const LDAP_X_NO_REFERRALS_FOUND: u32 = 16656;
372pub const LDAP_X_CANNOT_CHAIN: u32 = 16657;
373pub const LDAP_X_INVALIDREFERENCE: u32 = 16658;
374pub const LDAP_TXN_SPECIFY_OKAY: u32 = 16672;
375pub const LDAP_TXN_ID_INVALID: u32 = 16673;
376pub const LDAP_SERVER_DOWN: i32 = -1;
377pub const LDAP_LOCAL_ERROR: i32 = -2;
378pub const LDAP_ENCODING_ERROR: i32 = -3;
379pub const LDAP_DECODING_ERROR: i32 = -4;
380pub const LDAP_TIMEOUT: i32 = -5;
381pub const LDAP_AUTH_UNKNOWN: i32 = -6;
382pub const LDAP_FILTER_ERROR: i32 = -7;
383pub const LDAP_USER_CANCELLED: i32 = -8;
384pub const LDAP_PARAM_ERROR: i32 = -9;
385pub const LDAP_NO_MEMORY: i32 = -10;
386pub const LDAP_CONNECT_ERROR: i32 = -11;
387pub const LDAP_NOT_SUPPORTED: i32 = -12;
388pub const LDAP_CONTROL_NOT_FOUND: i32 = -13;
389pub const LDAP_NO_RESULTS_RETURNED: i32 = -14;
390pub const LDAP_MORE_RESULTS_TO_RETURN: i32 = -15;
391pub const LDAP_CLIENT_LOOP: i32 = -16;
392pub const LDAP_REFERRAL_LIMIT_EXCEEDED: i32 = -17;
393pub const LDAP_X_CONNECTING: i32 = -18;
394pub const LDAP_MOD_OP: u32 = 7;
395pub const LDAP_MOD_ADD: u32 = 0;
396pub const LDAP_MOD_DELETE: u32 = 1;
397pub const LDAP_MOD_REPLACE: u32 = 2;
398pub const LDAP_MOD_INCREMENT: u32 = 3;
399pub const LDAP_MOD_BVALUES: u32 = 128;
400pub const LDAP_DEREF_NEVER: u32 = 0;
401pub const LDAP_DEREF_SEARCHING: u32 = 1;
402pub const LDAP_DEREF_FINDING: u32 = 2;
403pub const LDAP_DEREF_ALWAYS: u32 = 3;
404pub const LDAP_NO_LIMIT: u32 = 0;
405pub const LDAP_MSG_ONE: u32 = 0;
406pub const LDAP_MSG_ALL: u32 = 1;
407pub const LDAP_MSG_RECEIVED: u32 = 2;
408pub const LDAP_URL_SUCCESS: u32 = 0;
409pub const LDAP_URL_ERR_MEM: u32 = 1;
410pub const LDAP_URL_ERR_PARAM: u32 = 2;
411pub const LDAP_URL_ERR_BADSCHEME: u32 = 3;
412pub const LDAP_URL_ERR_BADENCLOSURE: u32 = 4;
413pub const LDAP_URL_ERR_BADURL: u32 = 5;
414pub const LDAP_URL_ERR_BADHOST: u32 = 6;
415pub const LDAP_URL_ERR_BADATTRS: u32 = 7;
416pub const LDAP_URL_ERR_BADSCOPE: u32 = 8;
417pub const LDAP_URL_ERR_BADFILTER: u32 = 9;
418pub const LDAP_URL_ERR_BADEXTS: u32 = 10;
419pub const LDAP_SASL_AUTOMATIC: u32 = 0;
420pub const LDAP_SASL_INTERACTIVE: u32 = 1;
421pub const LDAP_SASL_QUIET: u32 = 2;
422pub const LDAP_AVA_NULL: u32 = 0;
423pub const LDAP_AVA_STRING: u32 = 1;
424pub const LDAP_AVA_BINARY: u32 = 2;
425pub const LDAP_AVA_NONPRINTABLE: u32 = 4;
426pub const LDAP_AVA_FREE_ATTR: u32 = 16;
427pub const LDAP_AVA_FREE_VALUE: u32 = 32;
428pub const LDAP_DN_FORMAT_LDAP: u32 = 0;
429pub const LDAP_DN_FORMAT_LDAPV3: u32 = 16;
430pub const LDAP_DN_FORMAT_LDAPV2: u32 = 32;
431pub const LDAP_DN_FORMAT_DCE: u32 = 48;
432pub const LDAP_DN_FORMAT_UFN: u32 = 64;
433pub const LDAP_DN_FORMAT_AD_CANONICAL: u32 = 80;
434pub const LDAP_DN_FORMAT_LBER: u32 = 240;
435pub const LDAP_DN_FORMAT_MASK: u32 = 240;
436pub const LDAP_DN_PRETTY: u32 = 256;
437pub const LDAP_DN_SKIP: u32 = 512;
438pub const LDAP_DN_P_NOLEADTRAILSPACES: u32 = 4096;
439pub const LDAP_DN_P_NOSPACEAFTERRDN: u32 = 8192;
440pub const LDAP_DN_PEDANTIC: u32 = 61440;
441pub const LDAP_API_FEATURE_CANCEL: u32 = 1000;
442pub const LDAP_API_FEATURE_TURN: u32 = 1000;
443pub const LDAP_API_FEATURE_PAGED_RESULTS: u32 = 2000;
444pub const LDAP_API_FEATURE_SERVER_SIDE_SORT: u32 = 2000;
445pub const LDAP_API_FEATURE_VIRTUAL_LIST_VIEW: u32 = 2000;
446pub const LDAP_API_FEATURE_VERIFY_CREDENTIALS: u32 = 1000;
447pub const LDAP_API_FEATURE_WHOAMI: u32 = 1000;
448pub const LDAP_API_FEATURE_PASSWD_MODIFY: u32 = 1000;
449pub const LDAP_API_FEATURE_PASSWORD_POLICY: u32 = 1000;
450pub const LDAP_API_FEATURE_REFRESH: u32 = 1000;
451pub const LDIF_DEFAULT_ADD: u32 = 1;
452pub const LDIF_ENTRIES_ONLY: u32 = 2;
453pub const LDIF_NO_CONTROLS: u32 = 4;
454pub const LDIF_MODS_ONLY: u32 = 8;
455pub const LDIF_NO_DN: u32 = 16;
456pub const SASL_H: u32 = 1;
457pub const SASL_VERSION_MAJOR: u32 = 2;
458pub const SASL_VERSION_MINOR: u32 = 1;
459pub const SASL_VERSION_STEP: u32 = 28;
460pub const SASL_VERSION_FULL: u32 = 131356;
461pub const PROP_H: u32 = 1;
462pub const PROP_DEFAULT: u32 = 4;
463pub const SASL_CONTINUE: u32 = 1;
464pub const SASL_OK: u32 = 0;
465pub const SASL_FAIL: i32 = -1;
466pub const SASL_NOMEM: i32 = -2;
467pub const SASL_BUFOVER: i32 = -3;
468pub const SASL_NOMECH: i32 = -4;
469pub const SASL_BADPROT: i32 = -5;
470pub const SASL_NOTDONE: i32 = -6;
471pub const SASL_BADPARAM: i32 = -7;
472pub const SASL_TRYAGAIN: i32 = -8;
473pub const SASL_BADMAC: i32 = -9;
474pub const SASL_NOTINIT: i32 = -12;
475pub const SASL_INTERACT: u32 = 2;
476pub const SASL_BADSERV: i32 = -10;
477pub const SASL_WRONGMECH: i32 = -11;
478pub const SASL_BADAUTH: i32 = -13;
479pub const SASL_NOAUTHZ: i32 = -14;
480pub const SASL_TOOWEAK: i32 = -15;
481pub const SASL_ENCRYPT: i32 = -16;
482pub const SASL_TRANS: i32 = -17;
483pub const SASL_EXPIRED: i32 = -18;
484pub const SASL_DISABLED: i32 = -19;
485pub const SASL_NOUSER: i32 = -20;
486pub const SASL_BADVERS: i32 = -23;
487pub const SASL_UNAVAIL: i32 = -24;
488pub const SASL_NOVERIFY: i32 = -26;
489pub const SASL_PWLOCK: i32 = -21;
490pub const SASL_NOCHANGE: i32 = -22;
491pub const SASL_WEAKPASS: i32 = -27;
492pub const SASL_NOUSERPASS: i32 = -28;
493pub const SASL_NEED_OLD_PASSWD: i32 = -29;
494pub const SASL_CONSTRAINT_VIOLAT: i32 = -30;
495pub const SASL_BADBINDING: i32 = -32;
496pub const SASL_CONFIGERR: i32 = -100;
497pub const SASL_MECHNAMEMAX: u32 = 20;
498pub const __PDP_ENDIAN: u32 = 3412;
499pub const BIG_ENDIAN: u32 = 4321;
500pub const LITTLE_ENDIAN: u32 = 1234;
501pub const PDP_ENDIAN: u32 = 3412;
502pub const BYTE_ORDER: u32 = 1234;
503pub const FD_SETSIZE: u32 = 1024;
504pub const SASL_SUCCESS_DATA: u32 = 4;
505pub const SASL_NEED_PROXY: u32 = 8;
506pub const SASL_NEED_HTTP: u32 = 16;
507pub const SASL_SEC_NOPLAINTEXT: u32 = 1;
508pub const SASL_SEC_NOACTIVE: u32 = 2;
509pub const SASL_SEC_NODICTIONARY: u32 = 4;
510pub const SASL_SEC_FORWARD_SECRECY: u32 = 8;
511pub const SASL_SEC_NOANONYMOUS: u32 = 16;
512pub const SASL_SEC_PASS_CREDENTIALS: u32 = 32;
513pub const SASL_SEC_MUTUAL_AUTH: u32 = 64;
514pub const SASL_SEC_MAXIMUM: u32 = 65535;
515pub const SASL_CB_LIST_END: u32 = 0;
516pub const SASL_CB_GETOPT: u32 = 1;
517pub const SASL_LOG_NONE: u32 = 0;
518pub const SASL_LOG_ERR: u32 = 1;
519pub const SASL_LOG_FAIL: u32 = 2;
520pub const SASL_LOG_WARN: u32 = 3;
521pub const SASL_LOG_NOTE: u32 = 4;
522pub const SASL_LOG_DEBUG: u32 = 5;
523pub const SASL_LOG_TRACE: u32 = 6;
524pub const SASL_LOG_PASS: u32 = 7;
525pub const SASL_CB_LOG: u32 = 2;
526pub const SASL_CB_GETPATH: u32 = 3;
527pub const SASL_CB_VERIFYFILE: u32 = 4;
528pub const SASL_CB_GETCONFPATH: u32 = 5;
529pub const SASL_CB_USER: u32 = 16385;
530pub const SASL_CB_AUTHNAME: u32 = 16386;
531pub const SASL_CB_LANGUAGE: u32 = 16387;
532pub const SASL_CB_CNONCE: u32 = 16391;
533pub const SASL_CB_PASS: u32 = 16388;
534pub const SASL_CB_ECHOPROMPT: u32 = 16389;
535pub const SASL_CB_NOECHOPROMPT: u32 = 16390;
536pub const SASL_CB_GETREALM: u32 = 16392;
537pub const SASL_CB_PROXY_POLICY: u32 = 32769;
538pub const SASL_CB_SERVER_USERDB_CHECKPASS: u32 = 32773;
539pub const SASL_CB_SERVER_USERDB_SETPASS: u32 = 32774;
540pub const SASL_CU_NONE: u32 = 0;
541pub const SASL_CU_AUTHID: u32 = 1;
542pub const SASL_CU_AUTHZID: u32 = 2;
543pub const SASL_CU_EXTERNALLY_VERIFIED: u32 = 4;
544pub const SASL_CU_OVERRIDE: u32 = 8;
545pub const SASL_CU_ASIS_MASK: u32 = 65520;
546pub const SASL_CU_VERIFY_AGAINST_HASH: u32 = 16;
547pub const SASL_CB_CANON_USER: u32 = 32775;
548pub const SASL_PATH_TYPE_PLUGIN: u32 = 0;
549pub const SASL_PATH_TYPE_CONFIG: u32 = 1;
550pub const SASL_NOLOG: u32 = 1;
551pub const SASL_USERNAME: u32 = 0;
552pub const SASL_SSF: u32 = 1;
553pub const SASL_MAXOUTBUF: u32 = 2;
554pub const SASL_DEFUSERREALM: u32 = 3;
555pub const SASL_GETOPTCTX: u32 = 4;
556pub const SASL_CALLBACK: u32 = 7;
557pub const SASL_IPLOCALPORT: u32 = 8;
558pub const SASL_IPREMOTEPORT: u32 = 9;
559pub const SASL_PLUGERR: u32 = 10;
560pub const SASL_DELEGATEDCREDS: u32 = 11;
561pub const SASL_SERVICE: u32 = 12;
562pub const SASL_SERVERFQDN: u32 = 13;
563pub const SASL_AUTHSOURCE: u32 = 14;
564pub const SASL_MECHNAME: u32 = 15;
565pub const SASL_AUTHUSER: u32 = 16;
566pub const SASL_APPNAME: u32 = 17;
567pub const SASL_GSS_CREDS: u32 = 18;
568pub const SASL_GSS_PEER_NAME: u32 = 19;
569pub const SASL_GSS_LOCAL_NAME: u32 = 20;
570pub const SASL_CHANNEL_BINDING: u32 = 21;
571pub const SASL_HTTP_REQUEST: u32 = 22;
572pub const SASL_SSF_EXTERNAL: u32 = 100;
573pub const SASL_SEC_PROPS: u32 = 101;
574pub const SASL_AUTH_EXTERNAL: u32 = 102;
575pub const SASL_SET_CREATE: u32 = 1;
576pub const SASL_SET_DISABLE: u32 = 2;
577pub const SASL_SET_NOPLAIN: u32 = 4;
578pub const SASL_SET_CURMECH_ONLY: u32 = 8;
579pub const SASL_AUX_ALL: &[u8; 2] = b"*\0";
580pub const SASL_AUX_PASSWORD_PROP: &[u8; 13] = b"userPassword\0";
581pub const SASL_AUX_PASSWORD: &[u8; 14] = b"*userPassword\0";
582pub const SASL_AUX_UIDNUM: &[u8; 10] = b"uidNumber\0";
583pub const SASL_AUX_GIDNUM: &[u8; 10] = b"gidNumber\0";
584pub const SASL_AUX_FULLNAME: &[u8; 6] = b"gecos\0";
585pub const SASL_AUX_HOMEDIR: &[u8; 14] = b"homeDirectory\0";
586pub const SASL_AUX_SHELL: &[u8; 11] = b"loginShell\0";
587pub const SASL_AUX_MAILADDR: &[u8; 5] = b"mail\0";
588pub const SASL_AUX_UNIXMBX: &[u8; 17] = b"mailMessageStore\0";
589pub const SASL_AUX_MAILCHAN: &[u8; 22] = b"mailSMTPSubmitChannel\0";
590pub type ber_int_t = ::std::os::raw::c_int;
591pub type ber_sint_t = ::std::os::raw::c_int;
592pub type ber_uint_t = ::std::os::raw::c_uint;
593pub type ber_tag_t = ::std::os::raw::c_ulong;
594pub type ber_socket_t = ::std::os::raw::c_int;
595pub type ber_len_t = ::std::os::raw::c_ulong;
596pub type ber_slen_t = ::std::os::raw::c_long;
597#[repr(C)]
598#[derive(Debug, Copy, Clone)]
599pub struct __locale_struct {
600    _unused: [u8; 0],
601}
602pub type locale_t = *mut __locale_struct;
603extern "C" {
604    pub fn memcpy(
605        arg1: *mut ::std::os::raw::c_void,
606        arg2: *const ::std::os::raw::c_void,
607        arg3: ::std::os::raw::c_ulong,
608    ) -> *mut ::std::os::raw::c_void;
609}
610extern "C" {
611    pub fn memmove(
612        arg1: *mut ::std::os::raw::c_void,
613        arg2: *const ::std::os::raw::c_void,
614        arg3: ::std::os::raw::c_ulong,
615    ) -> *mut ::std::os::raw::c_void;
616}
617extern "C" {
618    pub fn memset(
619        arg1: *mut ::std::os::raw::c_void,
620        arg2: ::std::os::raw::c_int,
621        arg3: ::std::os::raw::c_ulong,
622    ) -> *mut ::std::os::raw::c_void;
623}
624extern "C" {
625    pub fn memcmp(
626        arg1: *const ::std::os::raw::c_void,
627        arg2: *const ::std::os::raw::c_void,
628        arg3: ::std::os::raw::c_ulong,
629    ) -> ::std::os::raw::c_int;
630}
631extern "C" {
632    pub fn memchr(
633        arg1: *const ::std::os::raw::c_void,
634        arg2: ::std::os::raw::c_int,
635        arg3: ::std::os::raw::c_ulong,
636    ) -> *mut ::std::os::raw::c_void;
637}
638extern "C" {
639    pub fn strcpy(
640        arg1: *mut ::std::os::raw::c_char,
641        arg2: *const ::std::os::raw::c_char,
642    ) -> *mut ::std::os::raw::c_char;
643}
644extern "C" {
645    pub fn strncpy(
646        arg1: *mut ::std::os::raw::c_char,
647        arg2: *const ::std::os::raw::c_char,
648        arg3: ::std::os::raw::c_ulong,
649    ) -> *mut ::std::os::raw::c_char;
650}
651extern "C" {
652    pub fn strcat(
653        arg1: *mut ::std::os::raw::c_char,
654        arg2: *const ::std::os::raw::c_char,
655    ) -> *mut ::std::os::raw::c_char;
656}
657extern "C" {
658    pub fn strncat(
659        arg1: *mut ::std::os::raw::c_char,
660        arg2: *const ::std::os::raw::c_char,
661        arg3: ::std::os::raw::c_ulong,
662    ) -> *mut ::std::os::raw::c_char;
663}
664extern "C" {
665    pub fn strcmp(
666        arg1: *const ::std::os::raw::c_char,
667        arg2: *const ::std::os::raw::c_char,
668    ) -> ::std::os::raw::c_int;
669}
670extern "C" {
671    pub fn strncmp(
672        arg1: *const ::std::os::raw::c_char,
673        arg2: *const ::std::os::raw::c_char,
674        arg3: ::std::os::raw::c_ulong,
675    ) -> ::std::os::raw::c_int;
676}
677extern "C" {
678    pub fn strcoll(
679        arg1: *const ::std::os::raw::c_char,
680        arg2: *const ::std::os::raw::c_char,
681    ) -> ::std::os::raw::c_int;
682}
683extern "C" {
684    pub fn strxfrm(
685        arg1: *mut ::std::os::raw::c_char,
686        arg2: *const ::std::os::raw::c_char,
687        arg3: ::std::os::raw::c_ulong,
688    ) -> ::std::os::raw::c_ulong;
689}
690extern "C" {
691    pub fn strchr(
692        arg1: *const ::std::os::raw::c_char,
693        arg2: ::std::os::raw::c_int,
694    ) -> *mut ::std::os::raw::c_char;
695}
696extern "C" {
697    pub fn strrchr(
698        arg1: *const ::std::os::raw::c_char,
699        arg2: ::std::os::raw::c_int,
700    ) -> *mut ::std::os::raw::c_char;
701}
702extern "C" {
703    pub fn strcspn(
704        arg1: *const ::std::os::raw::c_char,
705        arg2: *const ::std::os::raw::c_char,
706    ) -> ::std::os::raw::c_ulong;
707}
708extern "C" {
709    pub fn strspn(
710        arg1: *const ::std::os::raw::c_char,
711        arg2: *const ::std::os::raw::c_char,
712    ) -> ::std::os::raw::c_ulong;
713}
714extern "C" {
715    pub fn strpbrk(
716        arg1: *const ::std::os::raw::c_char,
717        arg2: *const ::std::os::raw::c_char,
718    ) -> *mut ::std::os::raw::c_char;
719}
720extern "C" {
721    pub fn strstr(
722        arg1: *const ::std::os::raw::c_char,
723        arg2: *const ::std::os::raw::c_char,
724    ) -> *mut ::std::os::raw::c_char;
725}
726extern "C" {
727    pub fn strtok(
728        arg1: *mut ::std::os::raw::c_char,
729        arg2: *const ::std::os::raw::c_char,
730    ) -> *mut ::std::os::raw::c_char;
731}
732extern "C" {
733    pub fn strlen(arg1: *const ::std::os::raw::c_char) -> ::std::os::raw::c_ulong;
734}
735extern "C" {
736    pub fn strerror(arg1: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char;
737}
738extern "C" {
739    pub fn bcmp(
740        arg1: *const ::std::os::raw::c_void,
741        arg2: *const ::std::os::raw::c_void,
742        arg3: ::std::os::raw::c_ulong,
743    ) -> ::std::os::raw::c_int;
744}
745extern "C" {
746    pub fn bcopy(
747        arg1: *const ::std::os::raw::c_void,
748        arg2: *mut ::std::os::raw::c_void,
749        arg3: usize,
750    );
751}
752extern "C" {
753    pub fn bzero(arg1: *mut ::std::os::raw::c_void, arg2: ::std::os::raw::c_ulong);
754}
755extern "C" {
756    pub fn index(
757        arg1: *const ::std::os::raw::c_char,
758        arg2: ::std::os::raw::c_int,
759    ) -> *mut ::std::os::raw::c_char;
760}
761extern "C" {
762    pub fn rindex(
763        arg1: *const ::std::os::raw::c_char,
764        arg2: ::std::os::raw::c_int,
765    ) -> *mut ::std::os::raw::c_char;
766}
767extern "C" {
768    pub fn ffs(arg1: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
769}
770extern "C" {
771    pub fn ffsl(arg1: ::std::os::raw::c_long) -> ::std::os::raw::c_int;
772}
773extern "C" {
774    pub fn ffsll(arg1: ::std::os::raw::c_longlong) -> ::std::os::raw::c_int;
775}
776extern "C" {
777    pub fn strcasecmp(
778        arg1: *const ::std::os::raw::c_char,
779        arg2: *const ::std::os::raw::c_char,
780    ) -> ::std::os::raw::c_int;
781}
782extern "C" {
783    pub fn strncasecmp(
784        arg1: *const ::std::os::raw::c_char,
785        arg2: *const ::std::os::raw::c_char,
786        arg3: ::std::os::raw::c_ulong,
787    ) -> ::std::os::raw::c_int;
788}
789extern "C" {
790    pub fn strcasecmp_l(
791        arg1: *const ::std::os::raw::c_char,
792        arg2: *const ::std::os::raw::c_char,
793        arg3: locale_t,
794    ) -> ::std::os::raw::c_int;
795}
796extern "C" {
797    pub fn strncasecmp_l(
798        arg1: *const ::std::os::raw::c_char,
799        arg2: *const ::std::os::raw::c_char,
800        arg3: usize,
801        arg4: locale_t,
802    ) -> ::std::os::raw::c_int;
803}
804extern "C" {
805    pub fn strtok_r(
806        arg1: *mut ::std::os::raw::c_char,
807        arg2: *const ::std::os::raw::c_char,
808        arg3: *mut *mut ::std::os::raw::c_char,
809    ) -> *mut ::std::os::raw::c_char;
810}
811extern "C" {
812    pub fn strerror_r(
813        arg1: ::std::os::raw::c_int,
814        arg2: *mut ::std::os::raw::c_char,
815        arg3: usize,
816    ) -> ::std::os::raw::c_int;
817}
818extern "C" {
819    pub fn stpcpy(
820        arg1: *mut ::std::os::raw::c_char,
821        arg2: *const ::std::os::raw::c_char,
822    ) -> *mut ::std::os::raw::c_char;
823}
824extern "C" {
825    pub fn stpncpy(
826        arg1: *mut ::std::os::raw::c_char,
827        arg2: *const ::std::os::raw::c_char,
828        arg3: ::std::os::raw::c_ulong,
829    ) -> *mut ::std::os::raw::c_char;
830}
831extern "C" {
832    pub fn strnlen(arg1: *const ::std::os::raw::c_char, arg2: usize) -> usize;
833}
834extern "C" {
835    pub fn strdup(arg1: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char;
836}
837extern "C" {
838    pub fn strndup(
839        arg1: *const ::std::os::raw::c_char,
840        arg2: ::std::os::raw::c_ulong,
841    ) -> *mut ::std::os::raw::c_char;
842}
843extern "C" {
844    pub fn strsignal(arg1: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char;
845}
846extern "C" {
847    pub fn strerror_l(
848        arg1: ::std::os::raw::c_int,
849        arg2: locale_t,
850    ) -> *mut ::std::os::raw::c_char;
851}
852extern "C" {
853    pub fn strcoll_l(
854        arg1: *const ::std::os::raw::c_char,
855        arg2: *const ::std::os::raw::c_char,
856        arg3: locale_t,
857    ) -> ::std::os::raw::c_int;
858}
859extern "C" {
860    pub fn strxfrm_l(
861        arg1: *mut ::std::os::raw::c_char,
862        arg2: *const ::std::os::raw::c_char,
863        arg3: usize,
864        arg4: locale_t,
865    ) -> usize;
866}
867extern "C" {
868    pub fn memmem(
869        arg1: *const ::std::os::raw::c_void,
870        arg2: usize,
871        arg3: *const ::std::os::raw::c_void,
872        arg4: usize,
873    ) -> *mut ::std::os::raw::c_void;
874}
875extern "C" {
876    pub fn memccpy(
877        arg1: *mut ::std::os::raw::c_void,
878        arg2: *const ::std::os::raw::c_void,
879        arg3: ::std::os::raw::c_int,
880        arg4: ::std::os::raw::c_ulong,
881    ) -> *mut ::std::os::raw::c_void;
882}
883extern "C" {
884    pub fn strsep(
885        arg1: *mut *mut ::std::os::raw::c_char,
886        arg2: *const ::std::os::raw::c_char,
887    ) -> *mut ::std::os::raw::c_char;
888}
889extern "C" {
890    pub fn strlcat(
891        arg1: *mut ::std::os::raw::c_char,
892        arg2: *const ::std::os::raw::c_char,
893        arg3: ::std::os::raw::c_ulong,
894    ) -> ::std::os::raw::c_ulong;
895}
896extern "C" {
897    pub fn strlcpy(
898        arg1: *mut ::std::os::raw::c_char,
899        arg2: *const ::std::os::raw::c_char,
900        arg3: ::std::os::raw::c_ulong,
901    ) -> ::std::os::raw::c_ulong;
902}
903extern "C" {
904    pub fn explicit_bzero(arg1: *mut ::std::os::raw::c_void, arg2: usize);
905}
906pub type BER_ERRNO_FN = ::std::option::Option<
907    unsafe extern "C" fn() -> *mut ::std::os::raw::c_int,
908>;
909pub type BER_LOG_PRINT_FN = ::std::option::Option<
910    unsafe extern "C" fn(buf: *const ::std::os::raw::c_char),
911>;
912pub type BER_MEMALLOC_FN = ::std::option::Option<
913    unsafe extern "C" fn(
914        size: ber_len_t,
915        ctx: *mut ::std::os::raw::c_void,
916    ) -> *mut ::std::os::raw::c_void,
917>;
918pub type BER_MEMCALLOC_FN = ::std::option::Option<
919    unsafe extern "C" fn(
920        n: ber_len_t,
921        size: ber_len_t,
922        ctx: *mut ::std::os::raw::c_void,
923    ) -> *mut ::std::os::raw::c_void,
924>;
925pub type BER_MEMREALLOC_FN = ::std::option::Option<
926    unsafe extern "C" fn(
927        p: *mut ::std::os::raw::c_void,
928        size: ber_len_t,
929        ctx: *mut ::std::os::raw::c_void,
930    ) -> *mut ::std::os::raw::c_void,
931>;
932pub type BER_MEMFREE_FN = ::std::option::Option<
933    unsafe extern "C" fn(
934        p: *mut ::std::os::raw::c_void,
935        ctx: *mut ::std::os::raw::c_void,
936    ),
937>;
938#[repr(C)]
939#[derive(Debug, Copy, Clone)]
940pub struct lber_memory_fns {
941    pub bmf_malloc: BER_MEMALLOC_FN,
942    pub bmf_calloc: BER_MEMCALLOC_FN,
943    pub bmf_realloc: BER_MEMREALLOC_FN,
944    pub bmf_free: BER_MEMFREE_FN,
945}
946#[test]
947fn bindgen_test_layout_lber_memory_fns() {
948    const UNINIT: ::std::mem::MaybeUninit<lber_memory_fns> = ::std::mem::MaybeUninit::uninit();
949    let ptr = UNINIT.as_ptr();
950    assert_eq!(
951        ::std::mem::size_of::<lber_memory_fns>(),
952        32usize,
953        concat!("Size of: ", stringify!(lber_memory_fns)),
954    );
955    assert_eq!(
956        ::std::mem::align_of::<lber_memory_fns>(),
957        8usize,
958        concat!("Alignment of ", stringify!(lber_memory_fns)),
959    );
960    assert_eq!(
961        unsafe { ::std::ptr::addr_of!((*ptr).bmf_malloc) as usize - ptr as usize },
962        0usize,
963        concat!(
964            "Offset of field: ",
965            stringify!(lber_memory_fns),
966            "::",
967            stringify!(bmf_malloc),
968        ),
969    );
970    assert_eq!(
971        unsafe { ::std::ptr::addr_of!((*ptr).bmf_calloc) as usize - ptr as usize },
972        8usize,
973        concat!(
974            "Offset of field: ",
975            stringify!(lber_memory_fns),
976            "::",
977            stringify!(bmf_calloc),
978        ),
979    );
980    assert_eq!(
981        unsafe { ::std::ptr::addr_of!((*ptr).bmf_realloc) as usize - ptr as usize },
982        16usize,
983        concat!(
984            "Offset of field: ",
985            stringify!(lber_memory_fns),
986            "::",
987            stringify!(bmf_realloc),
988        ),
989    );
990    assert_eq!(
991        unsafe { ::std::ptr::addr_of!((*ptr).bmf_free) as usize - ptr as usize },
992        24usize,
993        concat!(
994            "Offset of field: ",
995            stringify!(lber_memory_fns),
996            "::",
997            stringify!(bmf_free),
998        ),
999    );
1000}
1001pub type BerMemoryFunctions = lber_memory_fns;
1002extern "C" {
1003    pub static mut ber_pvt_opt_on: ::std::os::raw::c_char;
1004}
1005#[repr(C)]
1006#[derive(Debug, Copy, Clone)]
1007pub struct berelement {
1008    _unused: [u8; 0],
1009}
1010pub type BerElement = berelement;
1011#[repr(C)]
1012#[derive(Debug, Copy, Clone)]
1013pub struct sockbuf {
1014    _unused: [u8; 0],
1015}
1016pub type Sockbuf = sockbuf;
1017pub type Sockbuf_IO = sockbuf_io;
1018#[repr(C)]
1019#[derive(Debug, Copy, Clone)]
1020pub struct sockbuf_io_desc {
1021    pub sbiod_level: ::std::os::raw::c_int,
1022    pub sbiod_sb: *mut Sockbuf,
1023    pub sbiod_io: *mut Sockbuf_IO,
1024    pub sbiod_pvt: *mut ::std::os::raw::c_void,
1025    pub sbiod_next: *mut sockbuf_io_desc,
1026}
1027#[test]
1028fn bindgen_test_layout_sockbuf_io_desc() {
1029    const UNINIT: ::std::mem::MaybeUninit<sockbuf_io_desc> = ::std::mem::MaybeUninit::uninit();
1030    let ptr = UNINIT.as_ptr();
1031    assert_eq!(
1032        ::std::mem::size_of::<sockbuf_io_desc>(),
1033        40usize,
1034        concat!("Size of: ", stringify!(sockbuf_io_desc)),
1035    );
1036    assert_eq!(
1037        ::std::mem::align_of::<sockbuf_io_desc>(),
1038        8usize,
1039        concat!("Alignment of ", stringify!(sockbuf_io_desc)),
1040    );
1041    assert_eq!(
1042        unsafe { ::std::ptr::addr_of!((*ptr).sbiod_level) as usize - ptr as usize },
1043        0usize,
1044        concat!(
1045            "Offset of field: ",
1046            stringify!(sockbuf_io_desc),
1047            "::",
1048            stringify!(sbiod_level),
1049        ),
1050    );
1051    assert_eq!(
1052        unsafe { ::std::ptr::addr_of!((*ptr).sbiod_sb) as usize - ptr as usize },
1053        8usize,
1054        concat!(
1055            "Offset of field: ",
1056            stringify!(sockbuf_io_desc),
1057            "::",
1058            stringify!(sbiod_sb),
1059        ),
1060    );
1061    assert_eq!(
1062        unsafe { ::std::ptr::addr_of!((*ptr).sbiod_io) as usize - ptr as usize },
1063        16usize,
1064        concat!(
1065            "Offset of field: ",
1066            stringify!(sockbuf_io_desc),
1067            "::",
1068            stringify!(sbiod_io),
1069        ),
1070    );
1071    assert_eq!(
1072        unsafe { ::std::ptr::addr_of!((*ptr).sbiod_pvt) as usize - ptr as usize },
1073        24usize,
1074        concat!(
1075            "Offset of field: ",
1076            stringify!(sockbuf_io_desc),
1077            "::",
1078            stringify!(sbiod_pvt),
1079        ),
1080    );
1081    assert_eq!(
1082        unsafe { ::std::ptr::addr_of!((*ptr).sbiod_next) as usize - ptr as usize },
1083        32usize,
1084        concat!(
1085            "Offset of field: ",
1086            stringify!(sockbuf_io_desc),
1087            "::",
1088            stringify!(sbiod_next),
1089        ),
1090    );
1091}
1092pub type Sockbuf_IO_Desc = sockbuf_io_desc;
1093#[repr(C)]
1094#[derive(Debug, Copy, Clone)]
1095pub struct sockbuf_io {
1096    pub sbi_setup: ::std::option::Option<
1097        unsafe extern "C" fn(
1098            sbiod: *mut Sockbuf_IO_Desc,
1099            arg: *mut ::std::os::raw::c_void,
1100        ) -> ::std::os::raw::c_int,
1101    >,
1102    pub sbi_remove: ::std::option::Option<
1103        unsafe extern "C" fn(sbiod: *mut Sockbuf_IO_Desc) -> ::std::os::raw::c_int,
1104    >,
1105    pub sbi_ctrl: ::std::option::Option<
1106        unsafe extern "C" fn(
1107            sbiod: *mut Sockbuf_IO_Desc,
1108            opt: ::std::os::raw::c_int,
1109            arg: *mut ::std::os::raw::c_void,
1110        ) -> ::std::os::raw::c_int,
1111    >,
1112    pub sbi_read: ::std::option::Option<
1113        unsafe extern "C" fn(
1114            sbiod: *mut Sockbuf_IO_Desc,
1115            buf: *mut ::std::os::raw::c_void,
1116            len: ber_len_t,
1117        ) -> ber_slen_t,
1118    >,
1119    pub sbi_write: ::std::option::Option<
1120        unsafe extern "C" fn(
1121            sbiod: *mut Sockbuf_IO_Desc,
1122            buf: *mut ::std::os::raw::c_void,
1123            len: ber_len_t,
1124        ) -> ber_slen_t,
1125    >,
1126    pub sbi_close: ::std::option::Option<
1127        unsafe extern "C" fn(sbiod: *mut Sockbuf_IO_Desc) -> ::std::os::raw::c_int,
1128    >,
1129}
1130#[test]
1131fn bindgen_test_layout_sockbuf_io() {
1132    const UNINIT: ::std::mem::MaybeUninit<sockbuf_io> = ::std::mem::MaybeUninit::uninit();
1133    let ptr = UNINIT.as_ptr();
1134    assert_eq!(
1135        ::std::mem::size_of::<sockbuf_io>(),
1136        48usize,
1137        concat!("Size of: ", stringify!(sockbuf_io)),
1138    );
1139    assert_eq!(
1140        ::std::mem::align_of::<sockbuf_io>(),
1141        8usize,
1142        concat!("Alignment of ", stringify!(sockbuf_io)),
1143    );
1144    assert_eq!(
1145        unsafe { ::std::ptr::addr_of!((*ptr).sbi_setup) as usize - ptr as usize },
1146        0usize,
1147        concat!("Offset of field: ", stringify!(sockbuf_io), "::", stringify!(sbi_setup)),
1148    );
1149    assert_eq!(
1150        unsafe { ::std::ptr::addr_of!((*ptr).sbi_remove) as usize - ptr as usize },
1151        8usize,
1152        concat!(
1153            "Offset of field: ",
1154            stringify!(sockbuf_io),
1155            "::",
1156            stringify!(sbi_remove),
1157        ),
1158    );
1159    assert_eq!(
1160        unsafe { ::std::ptr::addr_of!((*ptr).sbi_ctrl) as usize - ptr as usize },
1161        16usize,
1162        concat!("Offset of field: ", stringify!(sockbuf_io), "::", stringify!(sbi_ctrl)),
1163    );
1164    assert_eq!(
1165        unsafe { ::std::ptr::addr_of!((*ptr).sbi_read) as usize - ptr as usize },
1166        24usize,
1167        concat!("Offset of field: ", stringify!(sockbuf_io), "::", stringify!(sbi_read)),
1168    );
1169    assert_eq!(
1170        unsafe { ::std::ptr::addr_of!((*ptr).sbi_write) as usize - ptr as usize },
1171        32usize,
1172        concat!("Offset of field: ", stringify!(sockbuf_io), "::", stringify!(sbi_write)),
1173    );
1174    assert_eq!(
1175        unsafe { ::std::ptr::addr_of!((*ptr).sbi_close) as usize - ptr as usize },
1176        40usize,
1177        concat!("Offset of field: ", stringify!(sockbuf_io), "::", stringify!(sbi_close)),
1178    );
1179}
1180#[repr(C)]
1181#[derive(Debug, Copy, Clone)]
1182pub struct berval {
1183    pub bv_len: ber_len_t,
1184    pub bv_val: *mut ::std::os::raw::c_char,
1185}
1186#[test]
1187fn bindgen_test_layout_berval() {
1188    const UNINIT: ::std::mem::MaybeUninit<berval> = ::std::mem::MaybeUninit::uninit();
1189    let ptr = UNINIT.as_ptr();
1190    assert_eq!(
1191        ::std::mem::size_of::<berval>(),
1192        16usize,
1193        concat!("Size of: ", stringify!(berval)),
1194    );
1195    assert_eq!(
1196        ::std::mem::align_of::<berval>(),
1197        8usize,
1198        concat!("Alignment of ", stringify!(berval)),
1199    );
1200    assert_eq!(
1201        unsafe { ::std::ptr::addr_of!((*ptr).bv_len) as usize - ptr as usize },
1202        0usize,
1203        concat!("Offset of field: ", stringify!(berval), "::", stringify!(bv_len)),
1204    );
1205    assert_eq!(
1206        unsafe { ::std::ptr::addr_of!((*ptr).bv_val) as usize - ptr as usize },
1207        8usize,
1208        concat!("Offset of field: ", stringify!(berval), "::", stringify!(bv_val)),
1209    );
1210}
1211pub type BerValue = berval;
1212pub type BerVarray = *mut BerValue;
1213extern "C" {
1214    pub fn ber_error_print(data: *const ::std::os::raw::c_char);
1215}
1216extern "C" {
1217    pub fn ber_bprint(data: *const ::std::os::raw::c_char, len: ber_len_t);
1218}
1219extern "C" {
1220    pub fn ber_dump(ber: *mut BerElement, inout: ::std::os::raw::c_int);
1221}
1222pub type BERDecodeCallback = ::std::option::Option<
1223    unsafe extern "C" fn(
1224        ber: *mut BerElement,
1225        data: *mut ::std::os::raw::c_void,
1226        mode: ::std::os::raw::c_int,
1227    ) -> ::std::os::raw::c_int,
1228>;
1229extern "C" {
1230    pub fn ber_get_tag(ber: *mut BerElement) -> ber_tag_t;
1231}
1232extern "C" {
1233    pub fn ber_skip_tag(ber: *mut BerElement, len: *mut ber_len_t) -> ber_tag_t;
1234}
1235extern "C" {
1236    pub fn ber_peek_tag(ber: *mut BerElement, len: *mut ber_len_t) -> ber_tag_t;
1237}
1238extern "C" {
1239    pub fn ber_skip_raw(ber: *mut BerElement, bv: *mut berval) -> ber_tag_t;
1240}
1241extern "C" {
1242    pub fn ber_skip_element(ber: *mut BerElement, bv: *mut berval) -> ber_tag_t;
1243}
1244extern "C" {
1245    pub fn ber_peek_element(ber: *const BerElement, bv: *mut berval) -> ber_tag_t;
1246}
1247extern "C" {
1248    pub fn ber_get_int(ber: *mut BerElement, num: *mut ber_int_t) -> ber_tag_t;
1249}
1250extern "C" {
1251    pub fn ber_get_enum(ber: *mut BerElement, num: *mut ber_int_t) -> ber_tag_t;
1252}
1253extern "C" {
1254    pub fn ber_decode_int(
1255        bv: *const berval,
1256        num: *mut ber_int_t,
1257    ) -> ::std::os::raw::c_int;
1258}
1259extern "C" {
1260    pub fn ber_get_stringb(
1261        ber: *mut BerElement,
1262        buf: *mut ::std::os::raw::c_char,
1263        len: *mut ber_len_t,
1264    ) -> ber_tag_t;
1265}
1266extern "C" {
1267    pub fn ber_get_stringbv(
1268        ber: *mut BerElement,
1269        bv: *mut berval,
1270        options: ::std::os::raw::c_int,
1271    ) -> ber_tag_t;
1272}
1273extern "C" {
1274    pub fn ber_get_stringa(
1275        ber: *mut BerElement,
1276        buf: *mut *mut ::std::os::raw::c_char,
1277    ) -> ber_tag_t;
1278}
1279extern "C" {
1280    pub fn ber_get_stringal(ber: *mut BerElement, bv: *mut *mut berval) -> ber_tag_t;
1281}
1282extern "C" {
1283    pub fn ber_get_bitstringa(
1284        ber: *mut BerElement,
1285        buf: *mut *mut ::std::os::raw::c_char,
1286        len: *mut ber_len_t,
1287    ) -> ber_tag_t;
1288}
1289extern "C" {
1290    pub fn ber_get_null(ber: *mut BerElement) -> ber_tag_t;
1291}
1292extern "C" {
1293    pub fn ber_get_boolean(ber: *mut BerElement, boolval: *mut ber_int_t) -> ber_tag_t;
1294}
1295extern "C" {
1296    pub fn ber_first_element(
1297        ber: *mut BerElement,
1298        len: *mut ber_len_t,
1299        last: *mut *mut ::std::os::raw::c_char,
1300    ) -> ber_tag_t;
1301}
1302extern "C" {
1303    pub fn ber_next_element(
1304        ber: *mut BerElement,
1305        len: *mut ber_len_t,
1306        last: *const ::std::os::raw::c_char,
1307    ) -> ber_tag_t;
1308}
1309extern "C" {
1310    pub fn ber_scanf(
1311        ber: *mut BerElement,
1312        fmt: *const ::std::os::raw::c_char,
1313        ...
1314    ) -> ber_tag_t;
1315}
1316extern "C" {
1317    pub fn ber_decode_oid(in_: *mut berval, out: *mut berval) -> ::std::os::raw::c_int;
1318}
1319extern "C" {
1320    pub fn ber_encode_oid(in_: *mut berval, out: *mut berval) -> ::std::os::raw::c_int;
1321}
1322pub type BEREncodeCallback = ::std::option::Option<
1323    unsafe extern "C" fn(
1324        ber: *mut BerElement,
1325        data: *mut ::std::os::raw::c_void,
1326    ) -> ::std::os::raw::c_int,
1327>;
1328extern "C" {
1329    pub fn ber_put_enum(
1330        ber: *mut BerElement,
1331        num: ber_int_t,
1332        tag: ber_tag_t,
1333    ) -> ::std::os::raw::c_int;
1334}
1335extern "C" {
1336    pub fn ber_put_int(
1337        ber: *mut BerElement,
1338        num: ber_int_t,
1339        tag: ber_tag_t,
1340    ) -> ::std::os::raw::c_int;
1341}
1342extern "C" {
1343    pub fn ber_put_ostring(
1344        ber: *mut BerElement,
1345        str_: *const ::std::os::raw::c_char,
1346        len: ber_len_t,
1347        tag: ber_tag_t,
1348    ) -> ::std::os::raw::c_int;
1349}
1350extern "C" {
1351    pub fn ber_put_berval(
1352        ber: *mut BerElement,
1353        bv: *mut berval,
1354        tag: ber_tag_t,
1355    ) -> ::std::os::raw::c_int;
1356}
1357extern "C" {
1358    pub fn ber_put_string(
1359        ber: *mut BerElement,
1360        str_: *const ::std::os::raw::c_char,
1361        tag: ber_tag_t,
1362    ) -> ::std::os::raw::c_int;
1363}
1364extern "C" {
1365    pub fn ber_put_bitstring(
1366        ber: *mut BerElement,
1367        str_: *const ::std::os::raw::c_char,
1368        bitlen: ber_len_t,
1369        tag: ber_tag_t,
1370    ) -> ::std::os::raw::c_int;
1371}
1372extern "C" {
1373    pub fn ber_put_null(ber: *mut BerElement, tag: ber_tag_t) -> ::std::os::raw::c_int;
1374}
1375extern "C" {
1376    pub fn ber_put_boolean(
1377        ber: *mut BerElement,
1378        boolval: ber_int_t,
1379        tag: ber_tag_t,
1380    ) -> ::std::os::raw::c_int;
1381}
1382extern "C" {
1383    pub fn ber_start_seq(ber: *mut BerElement, tag: ber_tag_t) -> ::std::os::raw::c_int;
1384}
1385extern "C" {
1386    pub fn ber_start_set(ber: *mut BerElement, tag: ber_tag_t) -> ::std::os::raw::c_int;
1387}
1388extern "C" {
1389    pub fn ber_put_seq(ber: *mut BerElement) -> ::std::os::raw::c_int;
1390}
1391extern "C" {
1392    pub fn ber_put_set(ber: *mut BerElement) -> ::std::os::raw::c_int;
1393}
1394extern "C" {
1395    pub fn ber_printf(
1396        ber: *mut BerElement,
1397        fmt: *const ::std::os::raw::c_char,
1398        ...
1399    ) -> ::std::os::raw::c_int;
1400}
1401extern "C" {
1402    pub fn ber_skip_data(ber: *mut BerElement, len: ber_len_t) -> ber_slen_t;
1403}
1404extern "C" {
1405    pub fn ber_read(
1406        ber: *mut BerElement,
1407        buf: *mut ::std::os::raw::c_char,
1408        len: ber_len_t,
1409    ) -> ber_slen_t;
1410}
1411extern "C" {
1412    pub fn ber_write(
1413        ber: *mut BerElement,
1414        buf: *const ::std::os::raw::c_char,
1415        len: ber_len_t,
1416        zero: ::std::os::raw::c_int,
1417    ) -> ber_slen_t;
1418}
1419extern "C" {
1420    pub fn ber_free(ber: *mut BerElement, freebuf: ::std::os::raw::c_int);
1421}
1422extern "C" {
1423    pub fn ber_free_buf(ber: *mut BerElement);
1424}
1425extern "C" {
1426    pub fn ber_flush2(
1427        sb: *mut Sockbuf,
1428        ber: *mut BerElement,
1429        freeit: ::std::os::raw::c_int,
1430    ) -> ::std::os::raw::c_int;
1431}
1432extern "C" {
1433    pub fn ber_flush(
1434        sb: *mut Sockbuf,
1435        ber: *mut BerElement,
1436        freeit: ::std::os::raw::c_int,
1437    ) -> ::std::os::raw::c_int;
1438}
1439extern "C" {
1440    pub fn ber_alloc() -> *mut BerElement;
1441}
1442extern "C" {
1443    pub fn der_alloc() -> *mut BerElement;
1444}
1445extern "C" {
1446    pub fn ber_alloc_t(beroptions: ::std::os::raw::c_int) -> *mut BerElement;
1447}
1448extern "C" {
1449    pub fn ber_dup(ber: *mut BerElement) -> *mut BerElement;
1450}
1451extern "C" {
1452    pub fn ber_get_next(
1453        sb: *mut Sockbuf,
1454        len: *mut ber_len_t,
1455        ber: *mut BerElement,
1456    ) -> ber_tag_t;
1457}
1458extern "C" {
1459    pub fn ber_init2(
1460        ber: *mut BerElement,
1461        bv: *mut berval,
1462        options: ::std::os::raw::c_int,
1463    );
1464}
1465extern "C" {
1466    pub fn ber_init_w_nullc(ber: *mut BerElement, options: ::std::os::raw::c_int);
1467}
1468extern "C" {
1469    pub fn ber_reset(ber: *mut BerElement, was_writing: ::std::os::raw::c_int);
1470}
1471extern "C" {
1472    pub fn ber_init(bv: *mut berval) -> *mut BerElement;
1473}
1474extern "C" {
1475    pub fn ber_flatten(
1476        ber: *mut BerElement,
1477        bvPtr: *mut *mut berval,
1478    ) -> ::std::os::raw::c_int;
1479}
1480extern "C" {
1481    pub fn ber_flatten2(
1482        ber: *mut BerElement,
1483        bv: *mut berval,
1484        alloc: ::std::os::raw::c_int,
1485    ) -> ::std::os::raw::c_int;
1486}
1487extern "C" {
1488    pub fn ber_remaining(ber: *mut BerElement) -> ::std::os::raw::c_int;
1489}
1490extern "C" {
1491    pub fn ber_get_option(
1492        item: *mut ::std::os::raw::c_void,
1493        option: ::std::os::raw::c_int,
1494        outvalue: *mut ::std::os::raw::c_void,
1495    ) -> ::std::os::raw::c_int;
1496}
1497extern "C" {
1498    pub fn ber_set_option(
1499        item: *mut ::std::os::raw::c_void,
1500        option: ::std::os::raw::c_int,
1501        invalue: *const ::std::os::raw::c_void,
1502    ) -> ::std::os::raw::c_int;
1503}
1504extern "C" {
1505    pub fn ber_sockbuf_alloc() -> *mut Sockbuf;
1506}
1507extern "C" {
1508    pub fn ber_sockbuf_free(sb: *mut Sockbuf);
1509}
1510extern "C" {
1511    pub fn ber_sockbuf_add_io(
1512        sb: *mut Sockbuf,
1513        sbio: *mut Sockbuf_IO,
1514        layer: ::std::os::raw::c_int,
1515        arg: *mut ::std::os::raw::c_void,
1516    ) -> ::std::os::raw::c_int;
1517}
1518extern "C" {
1519    pub fn ber_sockbuf_remove_io(
1520        sb: *mut Sockbuf,
1521        sbio: *mut Sockbuf_IO,
1522        layer: ::std::os::raw::c_int,
1523    ) -> ::std::os::raw::c_int;
1524}
1525extern "C" {
1526    pub fn ber_sockbuf_ctrl(
1527        sb: *mut Sockbuf,
1528        opt: ::std::os::raw::c_int,
1529        arg: *mut ::std::os::raw::c_void,
1530    ) -> ::std::os::raw::c_int;
1531}
1532extern "C" {
1533    pub static mut ber_sockbuf_io_tcp: Sockbuf_IO;
1534}
1535extern "C" {
1536    pub static mut ber_sockbuf_io_readahead: Sockbuf_IO;
1537}
1538extern "C" {
1539    pub static mut ber_sockbuf_io_fd: Sockbuf_IO;
1540}
1541extern "C" {
1542    pub static mut ber_sockbuf_io_debug: Sockbuf_IO;
1543}
1544extern "C" {
1545    pub static mut ber_sockbuf_io_udp: Sockbuf_IO;
1546}
1547extern "C" {
1548    pub fn ber_memalloc(s: ber_len_t) -> *mut ::std::os::raw::c_void;
1549}
1550extern "C" {
1551    pub fn ber_memrealloc(
1552        p: *mut ::std::os::raw::c_void,
1553        s: ber_len_t,
1554    ) -> *mut ::std::os::raw::c_void;
1555}
1556extern "C" {
1557    pub fn ber_memcalloc(n: ber_len_t, s: ber_len_t) -> *mut ::std::os::raw::c_void;
1558}
1559extern "C" {
1560    pub fn ber_memfree(p: *mut ::std::os::raw::c_void);
1561}
1562extern "C" {
1563    pub fn ber_memvfree(vector: *mut *mut ::std::os::raw::c_void);
1564}
1565extern "C" {
1566    pub fn ber_bvfree(bv: *mut berval);
1567}
1568extern "C" {
1569    pub fn ber_bvecfree(bv: *mut *mut berval);
1570}
1571extern "C" {
1572    pub fn ber_bvecadd(
1573        bvec: *mut *mut *mut berval,
1574        bv: *mut berval,
1575    ) -> ::std::os::raw::c_int;
1576}
1577extern "C" {
1578    pub fn ber_dupbv(dst: *mut berval, src: *mut berval) -> *mut berval;
1579}
1580extern "C" {
1581    pub fn ber_bvdup(src: *mut berval) -> *mut berval;
1582}
1583extern "C" {
1584    pub fn ber_mem2bv(
1585        arg1: *const ::std::os::raw::c_char,
1586        len: ber_len_t,
1587        duplicate: ::std::os::raw::c_int,
1588        bv: *mut berval,
1589    ) -> *mut berval;
1590}
1591extern "C" {
1592    pub fn ber_str2bv(
1593        arg1: *const ::std::os::raw::c_char,
1594        len: ber_len_t,
1595        duplicate: ::std::os::raw::c_int,
1596        bv: *mut berval,
1597    ) -> *mut berval;
1598}
1599extern "C" {
1600    pub fn ber_strdup(
1601        arg1: *const ::std::os::raw::c_char,
1602    ) -> *mut ::std::os::raw::c_char;
1603}
1604extern "C" {
1605    pub fn ber_strnlen(s: *const ::std::os::raw::c_char, len: ber_len_t) -> ber_len_t;
1606}
1607extern "C" {
1608    pub fn ber_strndup(
1609        s: *const ::std::os::raw::c_char,
1610        l: ber_len_t,
1611    ) -> *mut ::std::os::raw::c_char;
1612}
1613extern "C" {
1614    pub fn ber_bvreplace(dst: *mut berval, src: *const berval) -> *mut berval;
1615}
1616extern "C" {
1617    pub fn ber_bvarray_free(p: BerVarray);
1618}
1619extern "C" {
1620    pub fn ber_bvarray_add(
1621        p: *mut BerVarray,
1622        bv: *mut BerValue,
1623    ) -> ::std::os::raw::c_int;
1624}
1625extern "C" {
1626    pub fn ber_errno_addr() -> *mut ::std::os::raw::c_int;
1627}
1628#[repr(C)]
1629#[derive(Debug, Copy, Clone)]
1630pub struct ldapapiinfo {
1631    pub ldapai_info_version: ::std::os::raw::c_int,
1632    pub ldapai_api_version: ::std::os::raw::c_int,
1633    pub ldapai_protocol_version: ::std::os::raw::c_int,
1634    pub ldapai_extensions: *mut *mut ::std::os::raw::c_char,
1635    pub ldapai_vendor_name: *mut ::std::os::raw::c_char,
1636    pub ldapai_vendor_version: ::std::os::raw::c_int,
1637}
1638#[test]
1639fn bindgen_test_layout_ldapapiinfo() {
1640    const UNINIT: ::std::mem::MaybeUninit<ldapapiinfo> = ::std::mem::MaybeUninit::uninit();
1641    let ptr = UNINIT.as_ptr();
1642    assert_eq!(
1643        ::std::mem::size_of::<ldapapiinfo>(),
1644        40usize,
1645        concat!("Size of: ", stringify!(ldapapiinfo)),
1646    );
1647    assert_eq!(
1648        ::std::mem::align_of::<ldapapiinfo>(),
1649        8usize,
1650        concat!("Alignment of ", stringify!(ldapapiinfo)),
1651    );
1652    assert_eq!(
1653        unsafe {
1654            ::std::ptr::addr_of!((*ptr).ldapai_info_version) as usize - ptr as usize
1655        },
1656        0usize,
1657        concat!(
1658            "Offset of field: ",
1659            stringify!(ldapapiinfo),
1660            "::",
1661            stringify!(ldapai_info_version),
1662        ),
1663    );
1664    assert_eq!(
1665        unsafe {
1666            ::std::ptr::addr_of!((*ptr).ldapai_api_version) as usize - ptr as usize
1667        },
1668        4usize,
1669        concat!(
1670            "Offset of field: ",
1671            stringify!(ldapapiinfo),
1672            "::",
1673            stringify!(ldapai_api_version),
1674        ),
1675    );
1676    assert_eq!(
1677        unsafe {
1678            ::std::ptr::addr_of!((*ptr).ldapai_protocol_version) as usize - ptr as usize
1679        },
1680        8usize,
1681        concat!(
1682            "Offset of field: ",
1683            stringify!(ldapapiinfo),
1684            "::",
1685            stringify!(ldapai_protocol_version),
1686        ),
1687    );
1688    assert_eq!(
1689        unsafe {
1690            ::std::ptr::addr_of!((*ptr).ldapai_extensions) as usize - ptr as usize
1691        },
1692        16usize,
1693        concat!(
1694            "Offset of field: ",
1695            stringify!(ldapapiinfo),
1696            "::",
1697            stringify!(ldapai_extensions),
1698        ),
1699    );
1700    assert_eq!(
1701        unsafe {
1702            ::std::ptr::addr_of!((*ptr).ldapai_vendor_name) as usize - ptr as usize
1703        },
1704        24usize,
1705        concat!(
1706            "Offset of field: ",
1707            stringify!(ldapapiinfo),
1708            "::",
1709            stringify!(ldapai_vendor_name),
1710        ),
1711    );
1712    assert_eq!(
1713        unsafe {
1714            ::std::ptr::addr_of!((*ptr).ldapai_vendor_version) as usize - ptr as usize
1715        },
1716        32usize,
1717        concat!(
1718            "Offset of field: ",
1719            stringify!(ldapapiinfo),
1720            "::",
1721            stringify!(ldapai_vendor_version),
1722        ),
1723    );
1724}
1725pub type LDAPAPIInfo = ldapapiinfo;
1726#[repr(C)]
1727#[derive(Debug, Copy, Clone)]
1728pub struct ldap_apifeature_info {
1729    pub ldapaif_info_version: ::std::os::raw::c_int,
1730    pub ldapaif_name: *mut ::std::os::raw::c_char,
1731    pub ldapaif_version: ::std::os::raw::c_int,
1732}
1733#[test]
1734fn bindgen_test_layout_ldap_apifeature_info() {
1735    const UNINIT: ::std::mem::MaybeUninit<ldap_apifeature_info> = ::std::mem::MaybeUninit::uninit();
1736    let ptr = UNINIT.as_ptr();
1737    assert_eq!(
1738        ::std::mem::size_of::<ldap_apifeature_info>(),
1739        24usize,
1740        concat!("Size of: ", stringify!(ldap_apifeature_info)),
1741    );
1742    assert_eq!(
1743        ::std::mem::align_of::<ldap_apifeature_info>(),
1744        8usize,
1745        concat!("Alignment of ", stringify!(ldap_apifeature_info)),
1746    );
1747    assert_eq!(
1748        unsafe {
1749            ::std::ptr::addr_of!((*ptr).ldapaif_info_version) as usize - ptr as usize
1750        },
1751        0usize,
1752        concat!(
1753            "Offset of field: ",
1754            stringify!(ldap_apifeature_info),
1755            "::",
1756            stringify!(ldapaif_info_version),
1757        ),
1758    );
1759    assert_eq!(
1760        unsafe { ::std::ptr::addr_of!((*ptr).ldapaif_name) as usize - ptr as usize },
1761        8usize,
1762        concat!(
1763            "Offset of field: ",
1764            stringify!(ldap_apifeature_info),
1765            "::",
1766            stringify!(ldapaif_name),
1767        ),
1768    );
1769    assert_eq!(
1770        unsafe { ::std::ptr::addr_of!((*ptr).ldapaif_version) as usize - ptr as usize },
1771        16usize,
1772        concat!(
1773            "Offset of field: ",
1774            stringify!(ldap_apifeature_info),
1775            "::",
1776            stringify!(ldapaif_version),
1777        ),
1778    );
1779}
1780pub type LDAPAPIFeatureInfo = ldap_apifeature_info;
1781#[repr(C)]
1782#[derive(Debug, Copy, Clone)]
1783pub struct ldapcontrol {
1784    pub ldctl_oid: *mut ::std::os::raw::c_char,
1785    pub ldctl_value: berval,
1786    pub ldctl_iscritical: ::std::os::raw::c_char,
1787}
1788#[test]
1789fn bindgen_test_layout_ldapcontrol() {
1790    const UNINIT: ::std::mem::MaybeUninit<ldapcontrol> = ::std::mem::MaybeUninit::uninit();
1791    let ptr = UNINIT.as_ptr();
1792    assert_eq!(
1793        ::std::mem::size_of::<ldapcontrol>(),
1794        32usize,
1795        concat!("Size of: ", stringify!(ldapcontrol)),
1796    );
1797    assert_eq!(
1798        ::std::mem::align_of::<ldapcontrol>(),
1799        8usize,
1800        concat!("Alignment of ", stringify!(ldapcontrol)),
1801    );
1802    assert_eq!(
1803        unsafe { ::std::ptr::addr_of!((*ptr).ldctl_oid) as usize - ptr as usize },
1804        0usize,
1805        concat!(
1806            "Offset of field: ",
1807            stringify!(ldapcontrol),
1808            "::",
1809            stringify!(ldctl_oid),
1810        ),
1811    );
1812    assert_eq!(
1813        unsafe { ::std::ptr::addr_of!((*ptr).ldctl_value) as usize - ptr as usize },
1814        8usize,
1815        concat!(
1816            "Offset of field: ",
1817            stringify!(ldapcontrol),
1818            "::",
1819            stringify!(ldctl_value),
1820        ),
1821    );
1822    assert_eq!(
1823        unsafe { ::std::ptr::addr_of!((*ptr).ldctl_iscritical) as usize - ptr as usize },
1824        24usize,
1825        concat!(
1826            "Offset of field: ",
1827            stringify!(ldapcontrol),
1828            "::",
1829            stringify!(ldctl_iscritical),
1830        ),
1831    );
1832}
1833pub type LDAPControl = ldapcontrol;
1834#[repr(C)]
1835#[derive(Debug, Copy, Clone)]
1836pub struct ldapmsg {
1837    _unused: [u8; 0],
1838}
1839pub type LDAPMessage = ldapmsg;
1840#[repr(C)]
1841#[derive(Copy, Clone)]
1842pub struct ldapmod {
1843    pub mod_op: ::std::os::raw::c_int,
1844    pub mod_type: *mut ::std::os::raw::c_char,
1845    pub mod_vals: ldapmod_mod_vals_u,
1846}
1847#[repr(C)]
1848#[derive(Copy, Clone)]
1849pub union ldapmod_mod_vals_u {
1850    pub modv_strvals: *mut *mut ::std::os::raw::c_char,
1851    pub modv_bvals: *mut *mut berval,
1852}
1853#[test]
1854fn bindgen_test_layout_ldapmod_mod_vals_u() {
1855    const UNINIT: ::std::mem::MaybeUninit<ldapmod_mod_vals_u> = ::std::mem::MaybeUninit::uninit();
1856    let ptr = UNINIT.as_ptr();
1857    assert_eq!(
1858        ::std::mem::size_of::<ldapmod_mod_vals_u>(),
1859        8usize,
1860        concat!("Size of: ", stringify!(ldapmod_mod_vals_u)),
1861    );
1862    assert_eq!(
1863        ::std::mem::align_of::<ldapmod_mod_vals_u>(),
1864        8usize,
1865        concat!("Alignment of ", stringify!(ldapmod_mod_vals_u)),
1866    );
1867    assert_eq!(
1868        unsafe { ::std::ptr::addr_of!((*ptr).modv_strvals) as usize - ptr as usize },
1869        0usize,
1870        concat!(
1871            "Offset of field: ",
1872            stringify!(ldapmod_mod_vals_u),
1873            "::",
1874            stringify!(modv_strvals),
1875        ),
1876    );
1877    assert_eq!(
1878        unsafe { ::std::ptr::addr_of!((*ptr).modv_bvals) as usize - ptr as usize },
1879        0usize,
1880        concat!(
1881            "Offset of field: ",
1882            stringify!(ldapmod_mod_vals_u),
1883            "::",
1884            stringify!(modv_bvals),
1885        ),
1886    );
1887}
1888#[test]
1889fn bindgen_test_layout_ldapmod() {
1890    const UNINIT: ::std::mem::MaybeUninit<ldapmod> = ::std::mem::MaybeUninit::uninit();
1891    let ptr = UNINIT.as_ptr();
1892    assert_eq!(
1893        ::std::mem::size_of::<ldapmod>(),
1894        24usize,
1895        concat!("Size of: ", stringify!(ldapmod)),
1896    );
1897    assert_eq!(
1898        ::std::mem::align_of::<ldapmod>(),
1899        8usize,
1900        concat!("Alignment of ", stringify!(ldapmod)),
1901    );
1902    assert_eq!(
1903        unsafe { ::std::ptr::addr_of!((*ptr).mod_op) as usize - ptr as usize },
1904        0usize,
1905        concat!("Offset of field: ", stringify!(ldapmod), "::", stringify!(mod_op)),
1906    );
1907    assert_eq!(
1908        unsafe { ::std::ptr::addr_of!((*ptr).mod_type) as usize - ptr as usize },
1909        8usize,
1910        concat!("Offset of field: ", stringify!(ldapmod), "::", stringify!(mod_type)),
1911    );
1912    assert_eq!(
1913        unsafe { ::std::ptr::addr_of!((*ptr).mod_vals) as usize - ptr as usize },
1914        16usize,
1915        concat!("Offset of field: ", stringify!(ldapmod), "::", stringify!(mod_vals)),
1916    );
1917}
1918pub type LDAPMod = ldapmod;
1919#[repr(C)]
1920#[derive(Debug, Copy, Clone)]
1921pub struct ldap {
1922    _unused: [u8; 0],
1923}
1924pub type LDAP = ldap;
1925#[repr(C)]
1926#[derive(Debug, Copy, Clone)]
1927pub struct ldap_url_desc {
1928    pub lud_next: *mut ldap_url_desc,
1929    pub lud_scheme: *mut ::std::os::raw::c_char,
1930    pub lud_host: *mut ::std::os::raw::c_char,
1931    pub lud_port: ::std::os::raw::c_int,
1932    pub lud_dn: *mut ::std::os::raw::c_char,
1933    pub lud_attrs: *mut *mut ::std::os::raw::c_char,
1934    pub lud_scope: ::std::os::raw::c_int,
1935    pub lud_filter: *mut ::std::os::raw::c_char,
1936    pub lud_exts: *mut *mut ::std::os::raw::c_char,
1937    pub lud_crit_exts: ::std::os::raw::c_int,
1938}
1939#[test]
1940fn bindgen_test_layout_ldap_url_desc() {
1941    const UNINIT: ::std::mem::MaybeUninit<ldap_url_desc> = ::std::mem::MaybeUninit::uninit();
1942    let ptr = UNINIT.as_ptr();
1943    assert_eq!(
1944        ::std::mem::size_of::<ldap_url_desc>(),
1945        80usize,
1946        concat!("Size of: ", stringify!(ldap_url_desc)),
1947    );
1948    assert_eq!(
1949        ::std::mem::align_of::<ldap_url_desc>(),
1950        8usize,
1951        concat!("Alignment of ", stringify!(ldap_url_desc)),
1952    );
1953    assert_eq!(
1954        unsafe { ::std::ptr::addr_of!((*ptr).lud_next) as usize - ptr as usize },
1955        0usize,
1956        concat!(
1957            "Offset of field: ",
1958            stringify!(ldap_url_desc),
1959            "::",
1960            stringify!(lud_next),
1961        ),
1962    );
1963    assert_eq!(
1964        unsafe { ::std::ptr::addr_of!((*ptr).lud_scheme) as usize - ptr as usize },
1965        8usize,
1966        concat!(
1967            "Offset of field: ",
1968            stringify!(ldap_url_desc),
1969            "::",
1970            stringify!(lud_scheme),
1971        ),
1972    );
1973    assert_eq!(
1974        unsafe { ::std::ptr::addr_of!((*ptr).lud_host) as usize - ptr as usize },
1975        16usize,
1976        concat!(
1977            "Offset of field: ",
1978            stringify!(ldap_url_desc),
1979            "::",
1980            stringify!(lud_host),
1981        ),
1982    );
1983    assert_eq!(
1984        unsafe { ::std::ptr::addr_of!((*ptr).lud_port) as usize - ptr as usize },
1985        24usize,
1986        concat!(
1987            "Offset of field: ",
1988            stringify!(ldap_url_desc),
1989            "::",
1990            stringify!(lud_port),
1991        ),
1992    );
1993    assert_eq!(
1994        unsafe { ::std::ptr::addr_of!((*ptr).lud_dn) as usize - ptr as usize },
1995        32usize,
1996        concat!("Offset of field: ", stringify!(ldap_url_desc), "::", stringify!(lud_dn)),
1997    );
1998    assert_eq!(
1999        unsafe { ::std::ptr::addr_of!((*ptr).lud_attrs) as usize - ptr as usize },
2000        40usize,
2001        concat!(
2002            "Offset of field: ",
2003            stringify!(ldap_url_desc),
2004            "::",
2005            stringify!(lud_attrs),
2006        ),
2007    );
2008    assert_eq!(
2009        unsafe { ::std::ptr::addr_of!((*ptr).lud_scope) as usize - ptr as usize },
2010        48usize,
2011        concat!(
2012            "Offset of field: ",
2013            stringify!(ldap_url_desc),
2014            "::",
2015            stringify!(lud_scope),
2016        ),
2017    );
2018    assert_eq!(
2019        unsafe { ::std::ptr::addr_of!((*ptr).lud_filter) as usize - ptr as usize },
2020        56usize,
2021        concat!(
2022            "Offset of field: ",
2023            stringify!(ldap_url_desc),
2024            "::",
2025            stringify!(lud_filter),
2026        ),
2027    );
2028    assert_eq!(
2029        unsafe { ::std::ptr::addr_of!((*ptr).lud_exts) as usize - ptr as usize },
2030        64usize,
2031        concat!(
2032            "Offset of field: ",
2033            stringify!(ldap_url_desc),
2034            "::",
2035            stringify!(lud_exts),
2036        ),
2037    );
2038    assert_eq!(
2039        unsafe { ::std::ptr::addr_of!((*ptr).lud_crit_exts) as usize - ptr as usize },
2040        72usize,
2041        concat!(
2042            "Offset of field: ",
2043            stringify!(ldap_url_desc),
2044            "::",
2045            stringify!(lud_crit_exts),
2046        ),
2047    );
2048}
2049pub type LDAPURLDesc = ldap_url_desc;
2050pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_NONE: ldap_sync_refresh_t = -1;
2051pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_PHASE_FLAG: ldap_sync_refresh_t = 16;
2052pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_IDSET_FLAG: ldap_sync_refresh_t = 32;
2053pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_DONE_FLAG: ldap_sync_refresh_t = 64;
2054pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_PRESENT: ldap_sync_refresh_t = 0;
2055pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_ADD: ldap_sync_refresh_t = 1;
2056pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_MODIFY: ldap_sync_refresh_t = 2;
2057pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_DELETE: ldap_sync_refresh_t = 3;
2058pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_PRESENTS: ldap_sync_refresh_t = 16;
2059pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_DELETES: ldap_sync_refresh_t = 19;
2060pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_PRESENTS_IDSET: ldap_sync_refresh_t = 48;
2061pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_DELETES_IDSET: ldap_sync_refresh_t = 51;
2062pub const ldap_sync_refresh_t_LDAP_SYNC_CAPI_DONE: ldap_sync_refresh_t = 80;
2063pub type ldap_sync_refresh_t = ::std::os::raw::c_int;
2064pub type ldap_sync_search_entry_f = ::std::option::Option<
2065    unsafe extern "C" fn(
2066        ls: *mut ldap_sync_t,
2067        msg: *mut LDAPMessage,
2068        entryUUID: *mut berval,
2069        phase: ldap_sync_refresh_t,
2070    ) -> ::std::os::raw::c_int,
2071>;
2072pub type ldap_sync_search_reference_f = ::std::option::Option<
2073    unsafe extern "C" fn(
2074        ls: *mut ldap_sync_t,
2075        msg: *mut LDAPMessage,
2076    ) -> ::std::os::raw::c_int,
2077>;
2078pub type ldap_sync_intermediate_f = ::std::option::Option<
2079    unsafe extern "C" fn(
2080        ls: *mut ldap_sync_t,
2081        msg: *mut LDAPMessage,
2082        syncUUIDs: BerVarray,
2083        phase: ldap_sync_refresh_t,
2084    ) -> ::std::os::raw::c_int,
2085>;
2086pub type ldap_sync_search_result_f = ::std::option::Option<
2087    unsafe extern "C" fn(
2088        ls: *mut ldap_sync_t,
2089        msg: *mut LDAPMessage,
2090        refreshDeletes: ::std::os::raw::c_int,
2091    ) -> ::std::os::raw::c_int,
2092>;
2093#[repr(C)]
2094#[derive(Debug, Copy, Clone)]
2095pub struct ldap_sync_t {
2096    pub ls_base: *mut ::std::os::raw::c_char,
2097    pub ls_scope: ::std::os::raw::c_int,
2098    pub ls_filter: *mut ::std::os::raw::c_char,
2099    pub ls_attrs: *mut *mut ::std::os::raw::c_char,
2100    pub ls_timelimit: ::std::os::raw::c_int,
2101    pub ls_sizelimit: ::std::os::raw::c_int,
2102    pub ls_timeout: ::std::os::raw::c_int,
2103    pub ls_search_entry: ldap_sync_search_entry_f,
2104    pub ls_search_reference: ldap_sync_search_reference_f,
2105    pub ls_intermediate: ldap_sync_intermediate_f,
2106    pub ls_search_result: ldap_sync_search_result_f,
2107    pub ls_private: *mut ::std::os::raw::c_void,
2108    pub ls_ld: *mut LDAP,
2109    pub ls_msgid: ::std::os::raw::c_int,
2110    pub ls_reloadHint: ::std::os::raw::c_int,
2111    pub ls_cookie: berval,
2112    pub ls_refreshPhase: ldap_sync_refresh_t,
2113}
2114#[test]
2115fn bindgen_test_layout_ldap_sync_t() {
2116    const UNINIT: ::std::mem::MaybeUninit<ldap_sync_t> = ::std::mem::MaybeUninit::uninit();
2117    let ptr = UNINIT.as_ptr();
2118    assert_eq!(
2119        ::std::mem::size_of::<ldap_sync_t>(),
2120        128usize,
2121        concat!("Size of: ", stringify!(ldap_sync_t)),
2122    );
2123    assert_eq!(
2124        ::std::mem::align_of::<ldap_sync_t>(),
2125        8usize,
2126        concat!("Alignment of ", stringify!(ldap_sync_t)),
2127    );
2128    assert_eq!(
2129        unsafe { ::std::ptr::addr_of!((*ptr).ls_base) as usize - ptr as usize },
2130        0usize,
2131        concat!("Offset of field: ", stringify!(ldap_sync_t), "::", stringify!(ls_base)),
2132    );
2133    assert_eq!(
2134        unsafe { ::std::ptr::addr_of!((*ptr).ls_scope) as usize - ptr as usize },
2135        8usize,
2136        concat!("Offset of field: ", stringify!(ldap_sync_t), "::", stringify!(ls_scope)),
2137    );
2138    assert_eq!(
2139        unsafe { ::std::ptr::addr_of!((*ptr).ls_filter) as usize - ptr as usize },
2140        16usize,
2141        concat!(
2142            "Offset of field: ",
2143            stringify!(ldap_sync_t),
2144            "::",
2145            stringify!(ls_filter),
2146        ),
2147    );
2148    assert_eq!(
2149        unsafe { ::std::ptr::addr_of!((*ptr).ls_attrs) as usize - ptr as usize },
2150        24usize,
2151        concat!("Offset of field: ", stringify!(ldap_sync_t), "::", stringify!(ls_attrs)),
2152    );
2153    assert_eq!(
2154        unsafe { ::std::ptr::addr_of!((*ptr).ls_timelimit) as usize - ptr as usize },
2155        32usize,
2156        concat!(
2157            "Offset of field: ",
2158            stringify!(ldap_sync_t),
2159            "::",
2160            stringify!(ls_timelimit),
2161        ),
2162    );
2163    assert_eq!(
2164        unsafe { ::std::ptr::addr_of!((*ptr).ls_sizelimit) as usize - ptr as usize },
2165        36usize,
2166        concat!(
2167            "Offset of field: ",
2168            stringify!(ldap_sync_t),
2169            "::",
2170            stringify!(ls_sizelimit),
2171        ),
2172    );
2173    assert_eq!(
2174        unsafe { ::std::ptr::addr_of!((*ptr).ls_timeout) as usize - ptr as usize },
2175        40usize,
2176        concat!(
2177            "Offset of field: ",
2178            stringify!(ldap_sync_t),
2179            "::",
2180            stringify!(ls_timeout),
2181        ),
2182    );
2183    assert_eq!(
2184        unsafe { ::std::ptr::addr_of!((*ptr).ls_search_entry) as usize - ptr as usize },
2185        48usize,
2186        concat!(
2187            "Offset of field: ",
2188            stringify!(ldap_sync_t),
2189            "::",
2190            stringify!(ls_search_entry),
2191        ),
2192    );
2193    assert_eq!(
2194        unsafe {
2195            ::std::ptr::addr_of!((*ptr).ls_search_reference) as usize - ptr as usize
2196        },
2197        56usize,
2198        concat!(
2199            "Offset of field: ",
2200            stringify!(ldap_sync_t),
2201            "::",
2202            stringify!(ls_search_reference),
2203        ),
2204    );
2205    assert_eq!(
2206        unsafe { ::std::ptr::addr_of!((*ptr).ls_intermediate) as usize - ptr as usize },
2207        64usize,
2208        concat!(
2209            "Offset of field: ",
2210            stringify!(ldap_sync_t),
2211            "::",
2212            stringify!(ls_intermediate),
2213        ),
2214    );
2215    assert_eq!(
2216        unsafe { ::std::ptr::addr_of!((*ptr).ls_search_result) as usize - ptr as usize },
2217        72usize,
2218        concat!(
2219            "Offset of field: ",
2220            stringify!(ldap_sync_t),
2221            "::",
2222            stringify!(ls_search_result),
2223        ),
2224    );
2225    assert_eq!(
2226        unsafe { ::std::ptr::addr_of!((*ptr).ls_private) as usize - ptr as usize },
2227        80usize,
2228        concat!(
2229            "Offset of field: ",
2230            stringify!(ldap_sync_t),
2231            "::",
2232            stringify!(ls_private),
2233        ),
2234    );
2235    assert_eq!(
2236        unsafe { ::std::ptr::addr_of!((*ptr).ls_ld) as usize - ptr as usize },
2237        88usize,
2238        concat!("Offset of field: ", stringify!(ldap_sync_t), "::", stringify!(ls_ld)),
2239    );
2240    assert_eq!(
2241        unsafe { ::std::ptr::addr_of!((*ptr).ls_msgid) as usize - ptr as usize },
2242        96usize,
2243        concat!("Offset of field: ", stringify!(ldap_sync_t), "::", stringify!(ls_msgid)),
2244    );
2245    assert_eq!(
2246        unsafe { ::std::ptr::addr_of!((*ptr).ls_reloadHint) as usize - ptr as usize },
2247        100usize,
2248        concat!(
2249            "Offset of field: ",
2250            stringify!(ldap_sync_t),
2251            "::",
2252            stringify!(ls_reloadHint),
2253        ),
2254    );
2255    assert_eq!(
2256        unsafe { ::std::ptr::addr_of!((*ptr).ls_cookie) as usize - ptr as usize },
2257        104usize,
2258        concat!(
2259            "Offset of field: ",
2260            stringify!(ldap_sync_t),
2261            "::",
2262            stringify!(ls_cookie),
2263        ),
2264    );
2265    assert_eq!(
2266        unsafe { ::std::ptr::addr_of!((*ptr).ls_refreshPhase) as usize - ptr as usize },
2267        120usize,
2268        concat!(
2269            "Offset of field: ",
2270            stringify!(ldap_sync_t),
2271            "::",
2272            stringify!(ls_refreshPhase),
2273        ),
2274    );
2275}
2276#[repr(C)]
2277#[derive(Debug, Copy, Clone)]
2278pub struct sockaddr {
2279    _unused: [u8; 0],
2280}
2281pub type ldap_conn_add_f = ::std::option::Option<
2282    unsafe extern "C" fn(
2283        ld: *mut LDAP,
2284        sb: *mut Sockbuf,
2285        srv: *mut LDAPURLDesc,
2286        addr: *mut sockaddr,
2287        ctx: *mut ldap_conncb,
2288    ) -> ::std::os::raw::c_int,
2289>;
2290pub type ldap_conn_del_f = ::std::option::Option<
2291    unsafe extern "C" fn(ld: *mut LDAP, sb: *mut Sockbuf, ctx: *mut ldap_conncb),
2292>;
2293#[repr(C)]
2294#[derive(Debug, Copy, Clone)]
2295pub struct ldap_conncb {
2296    pub lc_add: ldap_conn_add_f,
2297    pub lc_del: ldap_conn_del_f,
2298    pub lc_arg: *mut ::std::os::raw::c_void,
2299}
2300#[test]
2301fn bindgen_test_layout_ldap_conncb() {
2302    const UNINIT: ::std::mem::MaybeUninit<ldap_conncb> = ::std::mem::MaybeUninit::uninit();
2303    let ptr = UNINIT.as_ptr();
2304    assert_eq!(
2305        ::std::mem::size_of::<ldap_conncb>(),
2306        24usize,
2307        concat!("Size of: ", stringify!(ldap_conncb)),
2308    );
2309    assert_eq!(
2310        ::std::mem::align_of::<ldap_conncb>(),
2311        8usize,
2312        concat!("Alignment of ", stringify!(ldap_conncb)),
2313    );
2314    assert_eq!(
2315        unsafe { ::std::ptr::addr_of!((*ptr).lc_add) as usize - ptr as usize },
2316        0usize,
2317        concat!("Offset of field: ", stringify!(ldap_conncb), "::", stringify!(lc_add)),
2318    );
2319    assert_eq!(
2320        unsafe { ::std::ptr::addr_of!((*ptr).lc_del) as usize - ptr as usize },
2321        8usize,
2322        concat!("Offset of field: ", stringify!(ldap_conncb), "::", stringify!(lc_del)),
2323    );
2324    assert_eq!(
2325        unsafe { ::std::ptr::addr_of!((*ptr).lc_arg) as usize - ptr as usize },
2326        16usize,
2327        concat!("Offset of field: ", stringify!(ldap_conncb), "::", stringify!(lc_arg)),
2328    );
2329}
2330extern "C" {
2331    pub fn ldap_get_option(
2332        ld: *mut LDAP,
2333        option: ::std::os::raw::c_int,
2334        outvalue: *mut ::std::os::raw::c_void,
2335    ) -> ::std::os::raw::c_int;
2336}
2337extern "C" {
2338    pub fn ldap_set_option(
2339        ld: *mut LDAP,
2340        option: ::std::os::raw::c_int,
2341        invalue: *const ::std::os::raw::c_void,
2342    ) -> ::std::os::raw::c_int;
2343}
2344pub type LDAP_REBIND_PROC = ::std::option::Option<
2345    unsafe extern "C" fn(
2346        ld: *mut LDAP,
2347        url: *const ::std::os::raw::c_char,
2348        request: ber_tag_t,
2349        msgid: ber_int_t,
2350        params: *mut ::std::os::raw::c_void,
2351    ) -> ::std::os::raw::c_int,
2352>;
2353extern "C" {
2354    pub fn ldap_set_rebind_proc(
2355        ld: *mut LDAP,
2356        rebind_proc: LDAP_REBIND_PROC,
2357        params: *mut ::std::os::raw::c_void,
2358    ) -> ::std::os::raw::c_int;
2359}
2360pub type LDAP_NEXTREF_PROC = ::std::option::Option<
2361    unsafe extern "C" fn(
2362        ld: *mut LDAP,
2363        refsp: *mut *mut *mut ::std::os::raw::c_char,
2364        cntp: *mut ::std::os::raw::c_int,
2365        params: *mut ::std::os::raw::c_void,
2366    ) -> ::std::os::raw::c_int,
2367>;
2368extern "C" {
2369    pub fn ldap_set_nextref_proc(
2370        ld: *mut LDAP,
2371        nextref_proc: LDAP_NEXTREF_PROC,
2372        params: *mut ::std::os::raw::c_void,
2373    ) -> ::std::os::raw::c_int;
2374}
2375pub type LDAP_URLLIST_PROC = ::std::option::Option<
2376    unsafe extern "C" fn(
2377        ld: *mut LDAP,
2378        urllist: *mut *mut LDAPURLDesc,
2379        url: *mut *mut LDAPURLDesc,
2380        params: *mut ::std::os::raw::c_void,
2381    ) -> ::std::os::raw::c_int,
2382>;
2383extern "C" {
2384    pub fn ldap_set_urllist_proc(
2385        ld: *mut LDAP,
2386        urllist_proc: LDAP_URLLIST_PROC,
2387        params: *mut ::std::os::raw::c_void,
2388    ) -> ::std::os::raw::c_int;
2389}
2390extern "C" {
2391    pub fn ldap_control_create(
2392        requestOID: *const ::std::os::raw::c_char,
2393        iscritical: ::std::os::raw::c_int,
2394        value: *mut berval,
2395        dupval: ::std::os::raw::c_int,
2396        ctrlp: *mut *mut LDAPControl,
2397    ) -> ::std::os::raw::c_int;
2398}
2399extern "C" {
2400    pub fn ldap_control_find(
2401        oid: *const ::std::os::raw::c_char,
2402        ctrls: *mut *mut LDAPControl,
2403        nextctrlp: *mut *mut *mut LDAPControl,
2404    ) -> *mut LDAPControl;
2405}
2406extern "C" {
2407    pub fn ldap_control_free(ctrl: *mut LDAPControl);
2408}
2409extern "C" {
2410    pub fn ldap_controls_free(ctrls: *mut *mut LDAPControl);
2411}
2412extern "C" {
2413    pub fn ldap_controls_dup(controls: *const *mut LDAPControl) -> *mut *mut LDAPControl;
2414}
2415extern "C" {
2416    pub fn ldap_control_dup(c: *const LDAPControl) -> *mut LDAPControl;
2417}
2418extern "C" {
2419    pub fn ldap_domain2dn(
2420        domain: *const ::std::os::raw::c_char,
2421        dn: *mut *mut ::std::os::raw::c_char,
2422    ) -> ::std::os::raw::c_int;
2423}
2424extern "C" {
2425    pub fn ldap_dn2domain(
2426        dn: *const ::std::os::raw::c_char,
2427        domain: *mut *mut ::std::os::raw::c_char,
2428    ) -> ::std::os::raw::c_int;
2429}
2430extern "C" {
2431    pub fn ldap_domain2hostlist(
2432        domain: *const ::std::os::raw::c_char,
2433        hostlist: *mut *mut ::std::os::raw::c_char,
2434    ) -> ::std::os::raw::c_int;
2435}
2436extern "C" {
2437    pub fn ldap_extended_operation(
2438        ld: *mut LDAP,
2439        reqoid: *const ::std::os::raw::c_char,
2440        reqdata: *mut berval,
2441        serverctrls: *mut *mut LDAPControl,
2442        clientctrls: *mut *mut LDAPControl,
2443        msgidp: *mut ::std::os::raw::c_int,
2444    ) -> ::std::os::raw::c_int;
2445}
2446extern "C" {
2447    pub fn ldap_extended_operation_s(
2448        ld: *mut LDAP,
2449        reqoid: *const ::std::os::raw::c_char,
2450        reqdata: *mut berval,
2451        serverctrls: *mut *mut LDAPControl,
2452        clientctrls: *mut *mut LDAPControl,
2453        retoidp: *mut *mut ::std::os::raw::c_char,
2454        retdatap: *mut *mut berval,
2455    ) -> ::std::os::raw::c_int;
2456}
2457extern "C" {
2458    pub fn ldap_parse_extended_result(
2459        ld: *mut LDAP,
2460        res: *mut LDAPMessage,
2461        retoidp: *mut *mut ::std::os::raw::c_char,
2462        retdatap: *mut *mut berval,
2463        freeit: ::std::os::raw::c_int,
2464    ) -> ::std::os::raw::c_int;
2465}
2466extern "C" {
2467    pub fn ldap_parse_intermediate(
2468        ld: *mut LDAP,
2469        res: *mut LDAPMessage,
2470        retoidp: *mut *mut ::std::os::raw::c_char,
2471        retdatap: *mut *mut berval,
2472        serverctrls: *mut *mut *mut LDAPControl,
2473        freeit: ::std::os::raw::c_int,
2474    ) -> ::std::os::raw::c_int;
2475}
2476extern "C" {
2477    pub fn ldap_abandon_ext(
2478        ld: *mut LDAP,
2479        msgid: ::std::os::raw::c_int,
2480        serverctrls: *mut *mut LDAPControl,
2481        clientctrls: *mut *mut LDAPControl,
2482    ) -> ::std::os::raw::c_int;
2483}
2484extern "C" {
2485    pub fn ldap_add_ext(
2486        ld: *mut LDAP,
2487        dn: *const ::std::os::raw::c_char,
2488        attrs: *mut *mut LDAPMod,
2489        serverctrls: *mut *mut LDAPControl,
2490        clientctrls: *mut *mut LDAPControl,
2491        msgidp: *mut ::std::os::raw::c_int,
2492    ) -> ::std::os::raw::c_int;
2493}
2494extern "C" {
2495    pub fn ldap_add_ext_s(
2496        ld: *mut LDAP,
2497        dn: *const ::std::os::raw::c_char,
2498        attrs: *mut *mut LDAPMod,
2499        serverctrls: *mut *mut LDAPControl,
2500        clientctrls: *mut *mut LDAPControl,
2501    ) -> ::std::os::raw::c_int;
2502}
2503extern "C" {
2504    pub fn ldap_sasl_bind(
2505        ld: *mut LDAP,
2506        dn: *const ::std::os::raw::c_char,
2507        mechanism: *const ::std::os::raw::c_char,
2508        cred: *mut berval,
2509        serverctrls: *mut *mut LDAPControl,
2510        clientctrls: *mut *mut LDAPControl,
2511        msgidp: *mut ::std::os::raw::c_int,
2512    ) -> ::std::os::raw::c_int;
2513}
2514pub type LDAP_SASL_INTERACT_PROC = ::std::option::Option<
2515    unsafe extern "C" fn(
2516        ld: *mut LDAP,
2517        flags: ::std::os::raw::c_uint,
2518        defaults: *mut ::std::os::raw::c_void,
2519        interact: *mut ::std::os::raw::c_void,
2520    ) -> ::std::os::raw::c_int,
2521>;
2522extern "C" {
2523    pub fn ldap_sasl_interactive_bind(
2524        ld: *mut LDAP,
2525        dn: *const ::std::os::raw::c_char,
2526        saslMechanism: *const ::std::os::raw::c_char,
2527        serverControls: *mut *mut LDAPControl,
2528        clientControls: *mut *mut LDAPControl,
2529        flags: ::std::os::raw::c_uint,
2530        proc_: LDAP_SASL_INTERACT_PROC,
2531        defaults: *mut ::std::os::raw::c_void,
2532        result: *mut LDAPMessage,
2533        rmech: *mut *const ::std::os::raw::c_char,
2534        msgid: *mut ::std::os::raw::c_int,
2535    ) -> ::std::os::raw::c_int;
2536}
2537extern "C" {
2538    pub fn ldap_sasl_interactive_bind_s(
2539        ld: *mut LDAP,
2540        dn: *const ::std::os::raw::c_char,
2541        saslMechanism: *const ::std::os::raw::c_char,
2542        serverControls: *mut *mut LDAPControl,
2543        clientControls: *mut *mut LDAPControl,
2544        flags: ::std::os::raw::c_uint,
2545        proc_: LDAP_SASL_INTERACT_PROC,
2546        defaults: *mut ::std::os::raw::c_void,
2547    ) -> ::std::os::raw::c_int;
2548}
2549extern "C" {
2550    pub fn ldap_sasl_bind_s(
2551        ld: *mut LDAP,
2552        dn: *const ::std::os::raw::c_char,
2553        mechanism: *const ::std::os::raw::c_char,
2554        cred: *mut berval,
2555        serverctrls: *mut *mut LDAPControl,
2556        clientctrls: *mut *mut LDAPControl,
2557        servercredp: *mut *mut berval,
2558    ) -> ::std::os::raw::c_int;
2559}
2560extern "C" {
2561    pub fn ldap_parse_sasl_bind_result(
2562        ld: *mut LDAP,
2563        res: *mut LDAPMessage,
2564        servercredp: *mut *mut berval,
2565        freeit: ::std::os::raw::c_int,
2566    ) -> ::std::os::raw::c_int;
2567}
2568extern "C" {
2569    pub fn ldap_compare_ext(
2570        ld: *mut LDAP,
2571        dn: *const ::std::os::raw::c_char,
2572        attr: *const ::std::os::raw::c_char,
2573        bvalue: *mut berval,
2574        serverctrls: *mut *mut LDAPControl,
2575        clientctrls: *mut *mut LDAPControl,
2576        msgidp: *mut ::std::os::raw::c_int,
2577    ) -> ::std::os::raw::c_int;
2578}
2579extern "C" {
2580    pub fn ldap_compare_ext_s(
2581        ld: *mut LDAP,
2582        dn: *const ::std::os::raw::c_char,
2583        attr: *const ::std::os::raw::c_char,
2584        bvalue: *mut berval,
2585        serverctrls: *mut *mut LDAPControl,
2586        clientctrls: *mut *mut LDAPControl,
2587    ) -> ::std::os::raw::c_int;
2588}
2589extern "C" {
2590    pub fn ldap_delete_ext(
2591        ld: *mut LDAP,
2592        dn: *const ::std::os::raw::c_char,
2593        serverctrls: *mut *mut LDAPControl,
2594        clientctrls: *mut *mut LDAPControl,
2595        msgidp: *mut ::std::os::raw::c_int,
2596    ) -> ::std::os::raw::c_int;
2597}
2598extern "C" {
2599    pub fn ldap_delete_ext_s(
2600        ld: *mut LDAP,
2601        dn: *const ::std::os::raw::c_char,
2602        serverctrls: *mut *mut LDAPControl,
2603        clientctrls: *mut *mut LDAPControl,
2604    ) -> ::std::os::raw::c_int;
2605}
2606extern "C" {
2607    pub fn ldap_parse_result(
2608        ld: *mut LDAP,
2609        res: *mut LDAPMessage,
2610        errcodep: *mut ::std::os::raw::c_int,
2611        matcheddnp: *mut *mut ::std::os::raw::c_char,
2612        diagmsgp: *mut *mut ::std::os::raw::c_char,
2613        referralsp: *mut *mut *mut ::std::os::raw::c_char,
2614        serverctrls: *mut *mut *mut LDAPControl,
2615        freeit: ::std::os::raw::c_int,
2616    ) -> ::std::os::raw::c_int;
2617}
2618extern "C" {
2619    pub fn ldap_err2string(err: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_char;
2620}
2621extern "C" {
2622    pub fn ldap_modify_ext(
2623        ld: *mut LDAP,
2624        dn: *const ::std::os::raw::c_char,
2625        mods: *mut *mut LDAPMod,
2626        serverctrls: *mut *mut LDAPControl,
2627        clientctrls: *mut *mut LDAPControl,
2628        msgidp: *mut ::std::os::raw::c_int,
2629    ) -> ::std::os::raw::c_int;
2630}
2631extern "C" {
2632    pub fn ldap_modify_ext_s(
2633        ld: *mut LDAP,
2634        dn: *const ::std::os::raw::c_char,
2635        mods: *mut *mut LDAPMod,
2636        serverctrls: *mut *mut LDAPControl,
2637        clientctrls: *mut *mut LDAPControl,
2638    ) -> ::std::os::raw::c_int;
2639}
2640extern "C" {
2641    pub fn ldap_rename(
2642        ld: *mut LDAP,
2643        dn: *const ::std::os::raw::c_char,
2644        newrdn: *const ::std::os::raw::c_char,
2645        newSuperior: *const ::std::os::raw::c_char,
2646        deleteoldrdn: ::std::os::raw::c_int,
2647        sctrls: *mut *mut LDAPControl,
2648        cctrls: *mut *mut LDAPControl,
2649        msgidp: *mut ::std::os::raw::c_int,
2650    ) -> ::std::os::raw::c_int;
2651}
2652extern "C" {
2653    pub fn ldap_rename_s(
2654        ld: *mut LDAP,
2655        dn: *const ::std::os::raw::c_char,
2656        newrdn: *const ::std::os::raw::c_char,
2657        newSuperior: *const ::std::os::raw::c_char,
2658        deleteoldrdn: ::std::os::raw::c_int,
2659        sctrls: *mut *mut LDAPControl,
2660        cctrls: *mut *mut LDAPControl,
2661    ) -> ::std::os::raw::c_int;
2662}
2663extern "C" {
2664    pub fn ldap_create(ldp: *mut *mut LDAP) -> ::std::os::raw::c_int;
2665}
2666extern "C" {
2667    pub fn ldap_initialize(
2668        ldp: *mut *mut LDAP,
2669        url: *const ::std::os::raw::c_char,
2670    ) -> ::std::os::raw::c_int;
2671}
2672extern "C" {
2673    pub fn ldap_dup(old: *mut LDAP) -> *mut LDAP;
2674}
2675extern "C" {
2676    pub fn ldap_connect(ld: *mut LDAP) -> ::std::os::raw::c_int;
2677}
2678extern "C" {
2679    pub fn ldap_tls_inplace(ld: *mut LDAP) -> ::std::os::raw::c_int;
2680}
2681extern "C" {
2682    pub fn ldap_start_tls(
2683        ld: *mut LDAP,
2684        serverctrls: *mut *mut LDAPControl,
2685        clientctrls: *mut *mut LDAPControl,
2686        msgidp: *mut ::std::os::raw::c_int,
2687    ) -> ::std::os::raw::c_int;
2688}
2689extern "C" {
2690    pub fn ldap_install_tls(ld: *mut LDAP) -> ::std::os::raw::c_int;
2691}
2692extern "C" {
2693    pub fn ldap_start_tls_s(
2694        ld: *mut LDAP,
2695        serverctrls: *mut *mut LDAPControl,
2696        clientctrls: *mut *mut LDAPControl,
2697    ) -> ::std::os::raw::c_int;
2698}
2699extern "C" {
2700    pub fn ldap_first_message(
2701        ld: *mut LDAP,
2702        chain: *mut LDAPMessage,
2703    ) -> *mut LDAPMessage;
2704}
2705extern "C" {
2706    pub fn ldap_next_message(ld: *mut LDAP, msg: *mut LDAPMessage) -> *mut LDAPMessage;
2707}
2708extern "C" {
2709    pub fn ldap_count_messages(
2710        ld: *mut LDAP,
2711        chain: *mut LDAPMessage,
2712    ) -> ::std::os::raw::c_int;
2713}
2714extern "C" {
2715    pub fn ldap_first_reference(
2716        ld: *mut LDAP,
2717        chain: *mut LDAPMessage,
2718    ) -> *mut LDAPMessage;
2719}
2720extern "C" {
2721    pub fn ldap_next_reference(
2722        ld: *mut LDAP,
2723        ref_: *mut LDAPMessage,
2724    ) -> *mut LDAPMessage;
2725}
2726extern "C" {
2727    pub fn ldap_count_references(
2728        ld: *mut LDAP,
2729        chain: *mut LDAPMessage,
2730    ) -> ::std::os::raw::c_int;
2731}
2732extern "C" {
2733    pub fn ldap_parse_reference(
2734        ld: *mut LDAP,
2735        ref_: *mut LDAPMessage,
2736        referralsp: *mut *mut *mut ::std::os::raw::c_char,
2737        serverctrls: *mut *mut *mut LDAPControl,
2738        freeit: ::std::os::raw::c_int,
2739    ) -> ::std::os::raw::c_int;
2740}
2741extern "C" {
2742    pub fn ldap_first_entry(ld: *mut LDAP, chain: *mut LDAPMessage) -> *mut LDAPMessage;
2743}
2744extern "C" {
2745    pub fn ldap_next_entry(ld: *mut LDAP, entry: *mut LDAPMessage) -> *mut LDAPMessage;
2746}
2747extern "C" {
2748    pub fn ldap_count_entries(
2749        ld: *mut LDAP,
2750        chain: *mut LDAPMessage,
2751    ) -> ::std::os::raw::c_int;
2752}
2753extern "C" {
2754    pub fn ldap_get_entry_controls(
2755        ld: *mut LDAP,
2756        entry: *mut LDAPMessage,
2757        serverctrls: *mut *mut *mut LDAPControl,
2758    ) -> ::std::os::raw::c_int;
2759}
2760extern "C" {
2761    pub fn ldap_delete_result_entry(
2762        list: *mut *mut LDAPMessage,
2763        e: *mut LDAPMessage,
2764    ) -> *mut LDAPMessage;
2765}
2766extern "C" {
2767    pub fn ldap_add_result_entry(list: *mut *mut LDAPMessage, e: *mut LDAPMessage);
2768}
2769extern "C" {
2770    pub fn ldap_get_dn(
2771        ld: *mut LDAP,
2772        entry: *mut LDAPMessage,
2773    ) -> *mut ::std::os::raw::c_char;
2774}
2775#[repr(C)]
2776#[derive(Debug, Copy, Clone)]
2777pub struct ldap_ava {
2778    pub la_attr: berval,
2779    pub la_value: berval,
2780    pub la_flags: ::std::os::raw::c_uint,
2781    pub la_private: *mut ::std::os::raw::c_void,
2782}
2783#[test]
2784fn bindgen_test_layout_ldap_ava() {
2785    const UNINIT: ::std::mem::MaybeUninit<ldap_ava> = ::std::mem::MaybeUninit::uninit();
2786    let ptr = UNINIT.as_ptr();
2787    assert_eq!(
2788        ::std::mem::size_of::<ldap_ava>(),
2789        48usize,
2790        concat!("Size of: ", stringify!(ldap_ava)),
2791    );
2792    assert_eq!(
2793        ::std::mem::align_of::<ldap_ava>(),
2794        8usize,
2795        concat!("Alignment of ", stringify!(ldap_ava)),
2796    );
2797    assert_eq!(
2798        unsafe { ::std::ptr::addr_of!((*ptr).la_attr) as usize - ptr as usize },
2799        0usize,
2800        concat!("Offset of field: ", stringify!(ldap_ava), "::", stringify!(la_attr)),
2801    );
2802    assert_eq!(
2803        unsafe { ::std::ptr::addr_of!((*ptr).la_value) as usize - ptr as usize },
2804        16usize,
2805        concat!("Offset of field: ", stringify!(ldap_ava), "::", stringify!(la_value)),
2806    );
2807    assert_eq!(
2808        unsafe { ::std::ptr::addr_of!((*ptr).la_flags) as usize - ptr as usize },
2809        32usize,
2810        concat!("Offset of field: ", stringify!(ldap_ava), "::", stringify!(la_flags)),
2811    );
2812    assert_eq!(
2813        unsafe { ::std::ptr::addr_of!((*ptr).la_private) as usize - ptr as usize },
2814        40usize,
2815        concat!("Offset of field: ", stringify!(ldap_ava), "::", stringify!(la_private)),
2816    );
2817}
2818pub type LDAPAVA = ldap_ava;
2819pub type LDAPRDN = *mut *mut LDAPAVA;
2820pub type LDAPDN = *mut LDAPRDN;
2821extern "C" {
2822    pub fn ldap_rdnfree(rdn: LDAPRDN);
2823}
2824extern "C" {
2825    pub fn ldap_dnfree(dn: LDAPDN);
2826}
2827extern "C" {
2828    pub fn ldap_bv2dn(
2829        bv: *mut berval,
2830        dn: *mut LDAPDN,
2831        flags: ::std::os::raw::c_uint,
2832    ) -> ::std::os::raw::c_int;
2833}
2834extern "C" {
2835    pub fn ldap_str2dn(
2836        str_: *const ::std::os::raw::c_char,
2837        dn: *mut LDAPDN,
2838        flags: ::std::os::raw::c_uint,
2839    ) -> ::std::os::raw::c_int;
2840}
2841extern "C" {
2842    pub fn ldap_dn2bv(
2843        dn: LDAPDN,
2844        bv: *mut berval,
2845        flags: ::std::os::raw::c_uint,
2846    ) -> ::std::os::raw::c_int;
2847}
2848extern "C" {
2849    pub fn ldap_dn2str(
2850        dn: LDAPDN,
2851        str_: *mut *mut ::std::os::raw::c_char,
2852        flags: ::std::os::raw::c_uint,
2853    ) -> ::std::os::raw::c_int;
2854}
2855extern "C" {
2856    pub fn ldap_bv2rdn(
2857        bv: *mut berval,
2858        rdn: *mut LDAPRDN,
2859        next: *mut *mut ::std::os::raw::c_char,
2860        flags: ::std::os::raw::c_uint,
2861    ) -> ::std::os::raw::c_int;
2862}
2863extern "C" {
2864    pub fn ldap_str2rdn(
2865        str_: *const ::std::os::raw::c_char,
2866        rdn: *mut LDAPRDN,
2867        next: *mut *mut ::std::os::raw::c_char,
2868        flags: ::std::os::raw::c_uint,
2869    ) -> ::std::os::raw::c_int;
2870}
2871extern "C" {
2872    pub fn ldap_rdn2bv(
2873        rdn: LDAPRDN,
2874        bv: *mut berval,
2875        flags: ::std::os::raw::c_uint,
2876    ) -> ::std::os::raw::c_int;
2877}
2878extern "C" {
2879    pub fn ldap_rdn2str(
2880        rdn: LDAPRDN,
2881        str_: *mut *mut ::std::os::raw::c_char,
2882        flags: ::std::os::raw::c_uint,
2883    ) -> ::std::os::raw::c_int;
2884}
2885extern "C" {
2886    pub fn ldap_dn_normalize(
2887        in_: *const ::std::os::raw::c_char,
2888        iflags: ::std::os::raw::c_uint,
2889        out: *mut *mut ::std::os::raw::c_char,
2890        oflags: ::std::os::raw::c_uint,
2891    ) -> ::std::os::raw::c_int;
2892}
2893extern "C" {
2894    pub fn ldap_dn2ufn(dn: *const ::std::os::raw::c_char) -> *mut ::std::os::raw::c_char;
2895}
2896extern "C" {
2897    pub fn ldap_explode_dn(
2898        dn: *const ::std::os::raw::c_char,
2899        notypes: ::std::os::raw::c_int,
2900    ) -> *mut *mut ::std::os::raw::c_char;
2901}
2902extern "C" {
2903    pub fn ldap_explode_rdn(
2904        rdn: *const ::std::os::raw::c_char,
2905        notypes: ::std::os::raw::c_int,
2906    ) -> *mut *mut ::std::os::raw::c_char;
2907}
2908pub type LDAPDN_rewrite_func = ::std::option::Option<
2909    unsafe extern "C" fn(
2910        dn: LDAPDN,
2911        flags: ::std::os::raw::c_uint,
2912        ctx: *mut ::std::os::raw::c_void,
2913    ) -> ::std::os::raw::c_int,
2914>;
2915extern "C" {
2916    pub fn ldap_X509dn2bv(
2917        x509_name: *mut ::std::os::raw::c_void,
2918        dn: *mut berval,
2919        func: LDAPDN_rewrite_func,
2920        flags: ::std::os::raw::c_uint,
2921    ) -> ::std::os::raw::c_int;
2922}
2923extern "C" {
2924    pub fn ldap_dn2dcedn(
2925        dn: *const ::std::os::raw::c_char,
2926    ) -> *mut ::std::os::raw::c_char;
2927}
2928extern "C" {
2929    pub fn ldap_dcedn2dn(
2930        dce: *const ::std::os::raw::c_char,
2931    ) -> *mut ::std::os::raw::c_char;
2932}
2933extern "C" {
2934    pub fn ldap_dn2ad_canonical(
2935        dn: *const ::std::os::raw::c_char,
2936    ) -> *mut ::std::os::raw::c_char;
2937}
2938extern "C" {
2939    pub fn ldap_get_dn_ber(
2940        ld: *mut LDAP,
2941        e: *mut LDAPMessage,
2942        berout: *mut *mut BerElement,
2943        dn: *mut berval,
2944    ) -> ::std::os::raw::c_int;
2945}
2946extern "C" {
2947    pub fn ldap_get_attribute_ber(
2948        ld: *mut LDAP,
2949        e: *mut LDAPMessage,
2950        ber: *mut BerElement,
2951        attr: *mut berval,
2952        vals: *mut *mut berval,
2953    ) -> ::std::os::raw::c_int;
2954}
2955extern "C" {
2956    pub fn ldap_first_attribute(
2957        ld: *mut LDAP,
2958        entry: *mut LDAPMessage,
2959        ber: *mut *mut BerElement,
2960    ) -> *mut ::std::os::raw::c_char;
2961}
2962extern "C" {
2963    pub fn ldap_next_attribute(
2964        ld: *mut LDAP,
2965        entry: *mut LDAPMessage,
2966        ber: *mut BerElement,
2967    ) -> *mut ::std::os::raw::c_char;
2968}
2969extern "C" {
2970    pub fn ldap_get_values_len(
2971        ld: *mut LDAP,
2972        entry: *mut LDAPMessage,
2973        target: *const ::std::os::raw::c_char,
2974    ) -> *mut *mut berval;
2975}
2976extern "C" {
2977    pub fn ldap_count_values_len(vals: *mut *mut berval) -> ::std::os::raw::c_int;
2978}
2979extern "C" {
2980    pub fn ldap_value_free_len(vals: *mut *mut berval);
2981}
2982extern "C" {
2983    pub fn ldap_result(
2984        ld: *mut LDAP,
2985        msgid: ::std::os::raw::c_int,
2986        all: ::std::os::raw::c_int,
2987        timeout: *mut timeval,
2988        result: *mut *mut LDAPMessage,
2989    ) -> ::std::os::raw::c_int;
2990}
2991extern "C" {
2992    pub fn ldap_msgtype(lm: *mut LDAPMessage) -> ::std::os::raw::c_int;
2993}
2994extern "C" {
2995    pub fn ldap_msgid(lm: *mut LDAPMessage) -> ::std::os::raw::c_int;
2996}
2997extern "C" {
2998    pub fn ldap_msgfree(lm: *mut LDAPMessage) -> ::std::os::raw::c_int;
2999}
3000extern "C" {
3001    pub fn ldap_msgdelete(
3002        ld: *mut LDAP,
3003        msgid: ::std::os::raw::c_int,
3004    ) -> ::std::os::raw::c_int;
3005}
3006extern "C" {
3007    pub fn ldap_bv2escaped_filter_value(
3008        in_: *mut berval,
3009        out: *mut berval,
3010    ) -> ::std::os::raw::c_int;
3011}
3012extern "C" {
3013    pub fn ldap_search_ext(
3014        ld: *mut LDAP,
3015        base: *const ::std::os::raw::c_char,
3016        scope: ::std::os::raw::c_int,
3017        filter: *const ::std::os::raw::c_char,
3018        attrs: *mut *mut ::std::os::raw::c_char,
3019        attrsonly: ::std::os::raw::c_int,
3020        serverctrls: *mut *mut LDAPControl,
3021        clientctrls: *mut *mut LDAPControl,
3022        timeout: *mut timeval,
3023        sizelimit: ::std::os::raw::c_int,
3024        msgidp: *mut ::std::os::raw::c_int,
3025    ) -> ::std::os::raw::c_int;
3026}
3027extern "C" {
3028    pub fn ldap_search_ext_s(
3029        ld: *mut LDAP,
3030        base: *const ::std::os::raw::c_char,
3031        scope: ::std::os::raw::c_int,
3032        filter: *const ::std::os::raw::c_char,
3033        attrs: *mut *mut ::std::os::raw::c_char,
3034        attrsonly: ::std::os::raw::c_int,
3035        serverctrls: *mut *mut LDAPControl,
3036        clientctrls: *mut *mut LDAPControl,
3037        timeout: *mut timeval,
3038        sizelimit: ::std::os::raw::c_int,
3039        res: *mut *mut LDAPMessage,
3040    ) -> ::std::os::raw::c_int;
3041}
3042extern "C" {
3043    pub fn ldap_unbind_ext(
3044        ld: *mut LDAP,
3045        serverctrls: *mut *mut LDAPControl,
3046        clientctrls: *mut *mut LDAPControl,
3047    ) -> ::std::os::raw::c_int;
3048}
3049extern "C" {
3050    pub fn ldap_unbind_ext_s(
3051        ld: *mut LDAP,
3052        serverctrls: *mut *mut LDAPControl,
3053        clientctrls: *mut *mut LDAPControl,
3054    ) -> ::std::os::raw::c_int;
3055}
3056extern "C" {
3057    pub fn ldap_destroy(ld: *mut LDAP) -> ::std::os::raw::c_int;
3058}
3059extern "C" {
3060    pub fn ldap_put_vrFilter(
3061        ber: *mut BerElement,
3062        vrf: *const ::std::os::raw::c_char,
3063    ) -> ::std::os::raw::c_int;
3064}
3065extern "C" {
3066    pub fn ldap_memalloc(s: ber_len_t) -> *mut ::std::os::raw::c_void;
3067}
3068extern "C" {
3069    pub fn ldap_memrealloc(
3070        p: *mut ::std::os::raw::c_void,
3071        s: ber_len_t,
3072    ) -> *mut ::std::os::raw::c_void;
3073}
3074extern "C" {
3075    pub fn ldap_memcalloc(n: ber_len_t, s: ber_len_t) -> *mut ::std::os::raw::c_void;
3076}
3077extern "C" {
3078    pub fn ldap_memfree(p: *mut ::std::os::raw::c_void);
3079}
3080extern "C" {
3081    pub fn ldap_memvfree(v: *mut *mut ::std::os::raw::c_void);
3082}
3083extern "C" {
3084    pub fn ldap_strdup(
3085        arg1: *const ::std::os::raw::c_char,
3086    ) -> *mut ::std::os::raw::c_char;
3087}
3088extern "C" {
3089    pub fn ldap_mods_free(mods: *mut *mut LDAPMod, freemods: ::std::os::raw::c_int);
3090}
3091extern "C" {
3092    pub fn ldap_is_ldap_url(url: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int;
3093}
3094extern "C" {
3095    pub fn ldap_is_ldaps_url(
3096        url: *const ::std::os::raw::c_char,
3097    ) -> ::std::os::raw::c_int;
3098}
3099extern "C" {
3100    pub fn ldap_is_ldapi_url(
3101        url: *const ::std::os::raw::c_char,
3102    ) -> ::std::os::raw::c_int;
3103}
3104extern "C" {
3105    pub fn ldap_url_parse(
3106        url: *const ::std::os::raw::c_char,
3107        ludpp: *mut *mut LDAPURLDesc,
3108    ) -> ::std::os::raw::c_int;
3109}
3110extern "C" {
3111    pub fn ldap_url_desc2str(ludp: *mut LDAPURLDesc) -> *mut ::std::os::raw::c_char;
3112}
3113extern "C" {
3114    pub fn ldap_free_urldesc(ludp: *mut LDAPURLDesc);
3115}
3116extern "C" {
3117    pub fn ldap_cancel(
3118        ld: *mut LDAP,
3119        cancelid: ::std::os::raw::c_int,
3120        sctrls: *mut *mut LDAPControl,
3121        cctrls: *mut *mut LDAPControl,
3122        msgidp: *mut ::std::os::raw::c_int,
3123    ) -> ::std::os::raw::c_int;
3124}
3125extern "C" {
3126    pub fn ldap_cancel_s(
3127        ld: *mut LDAP,
3128        cancelid: ::std::os::raw::c_int,
3129        sctrl: *mut *mut LDAPControl,
3130        cctrl: *mut *mut LDAPControl,
3131    ) -> ::std::os::raw::c_int;
3132}
3133extern "C" {
3134    pub fn ldap_turn(
3135        ld: *mut LDAP,
3136        mutual: ::std::os::raw::c_int,
3137        identifier: *const ::std::os::raw::c_char,
3138        sctrls: *mut *mut LDAPControl,
3139        cctrls: *mut *mut LDAPControl,
3140        msgidp: *mut ::std::os::raw::c_int,
3141    ) -> ::std::os::raw::c_int;
3142}
3143extern "C" {
3144    pub fn ldap_turn_s(
3145        ld: *mut LDAP,
3146        mutual: ::std::os::raw::c_int,
3147        identifier: *const ::std::os::raw::c_char,
3148        sctrl: *mut *mut LDAPControl,
3149        cctrl: *mut *mut LDAPControl,
3150    ) -> ::std::os::raw::c_int;
3151}
3152extern "C" {
3153    pub fn ldap_create_page_control_value(
3154        ld: *mut LDAP,
3155        pagesize: ber_int_t,
3156        cookie: *mut berval,
3157        value: *mut berval,
3158    ) -> ::std::os::raw::c_int;
3159}
3160extern "C" {
3161    pub fn ldap_create_page_control(
3162        ld: *mut LDAP,
3163        pagesize: ber_int_t,
3164        cookie: *mut berval,
3165        iscritical: ::std::os::raw::c_int,
3166        ctrlp: *mut *mut LDAPControl,
3167    ) -> ::std::os::raw::c_int;
3168}
3169extern "C" {
3170    pub fn ldap_parse_pageresponse_control(
3171        ld: *mut LDAP,
3172        ctrl: *mut LDAPControl,
3173        count: *mut ber_int_t,
3174        cookie: *mut berval,
3175    ) -> ::std::os::raw::c_int;
3176}
3177#[repr(C)]
3178#[derive(Debug, Copy, Clone)]
3179pub struct ldapsortkey {
3180    pub attributeType: *mut ::std::os::raw::c_char,
3181    pub orderingRule: *mut ::std::os::raw::c_char,
3182    pub reverseOrder: ::std::os::raw::c_int,
3183}
3184#[test]
3185fn bindgen_test_layout_ldapsortkey() {
3186    const UNINIT: ::std::mem::MaybeUninit<ldapsortkey> = ::std::mem::MaybeUninit::uninit();
3187    let ptr = UNINIT.as_ptr();
3188    assert_eq!(
3189        ::std::mem::size_of::<ldapsortkey>(),
3190        24usize,
3191        concat!("Size of: ", stringify!(ldapsortkey)),
3192    );
3193    assert_eq!(
3194        ::std::mem::align_of::<ldapsortkey>(),
3195        8usize,
3196        concat!("Alignment of ", stringify!(ldapsortkey)),
3197    );
3198    assert_eq!(
3199        unsafe { ::std::ptr::addr_of!((*ptr).attributeType) as usize - ptr as usize },
3200        0usize,
3201        concat!(
3202            "Offset of field: ",
3203            stringify!(ldapsortkey),
3204            "::",
3205            stringify!(attributeType),
3206        ),
3207    );
3208    assert_eq!(
3209        unsafe { ::std::ptr::addr_of!((*ptr).orderingRule) as usize - ptr as usize },
3210        8usize,
3211        concat!(
3212            "Offset of field: ",
3213            stringify!(ldapsortkey),
3214            "::",
3215            stringify!(orderingRule),
3216        ),
3217    );
3218    assert_eq!(
3219        unsafe { ::std::ptr::addr_of!((*ptr).reverseOrder) as usize - ptr as usize },
3220        16usize,
3221        concat!(
3222            "Offset of field: ",
3223            stringify!(ldapsortkey),
3224            "::",
3225            stringify!(reverseOrder),
3226        ),
3227    );
3228}
3229pub type LDAPSortKey = ldapsortkey;
3230extern "C" {
3231    pub fn ldap_create_sort_keylist(
3232        sortKeyList: *mut *mut *mut LDAPSortKey,
3233        keyString: *mut ::std::os::raw::c_char,
3234    ) -> ::std::os::raw::c_int;
3235}
3236extern "C" {
3237    pub fn ldap_free_sort_keylist(sortkeylist: *mut *mut LDAPSortKey);
3238}
3239extern "C" {
3240    pub fn ldap_create_sort_control_value(
3241        ld: *mut LDAP,
3242        keyList: *mut *mut LDAPSortKey,
3243        value: *mut berval,
3244    ) -> ::std::os::raw::c_int;
3245}
3246extern "C" {
3247    pub fn ldap_create_sort_control(
3248        ld: *mut LDAP,
3249        keyList: *mut *mut LDAPSortKey,
3250        iscritical: ::std::os::raw::c_int,
3251        ctrlp: *mut *mut LDAPControl,
3252    ) -> ::std::os::raw::c_int;
3253}
3254extern "C" {
3255    pub fn ldap_parse_sortresponse_control(
3256        ld: *mut LDAP,
3257        ctrl: *mut LDAPControl,
3258        result: *mut ber_int_t,
3259        attribute: *mut *mut ::std::os::raw::c_char,
3260    ) -> ::std::os::raw::c_int;
3261}
3262#[repr(C)]
3263#[derive(Debug, Copy, Clone)]
3264pub struct ldapvlvinfo {
3265    pub ldvlv_version: ber_int_t,
3266    pub ldvlv_before_count: ber_int_t,
3267    pub ldvlv_after_count: ber_int_t,
3268    pub ldvlv_offset: ber_int_t,
3269    pub ldvlv_count: ber_int_t,
3270    pub ldvlv_attrvalue: *mut berval,
3271    pub ldvlv_context: *mut berval,
3272    pub ldvlv_extradata: *mut ::std::os::raw::c_void,
3273}
3274#[test]
3275fn bindgen_test_layout_ldapvlvinfo() {
3276    const UNINIT: ::std::mem::MaybeUninit<ldapvlvinfo> = ::std::mem::MaybeUninit::uninit();
3277    let ptr = UNINIT.as_ptr();
3278    assert_eq!(
3279        ::std::mem::size_of::<ldapvlvinfo>(),
3280        48usize,
3281        concat!("Size of: ", stringify!(ldapvlvinfo)),
3282    );
3283    assert_eq!(
3284        ::std::mem::align_of::<ldapvlvinfo>(),
3285        8usize,
3286        concat!("Alignment of ", stringify!(ldapvlvinfo)),
3287    );
3288    assert_eq!(
3289        unsafe { ::std::ptr::addr_of!((*ptr).ldvlv_version) as usize - ptr as usize },
3290        0usize,
3291        concat!(
3292            "Offset of field: ",
3293            stringify!(ldapvlvinfo),
3294            "::",
3295            stringify!(ldvlv_version),
3296        ),
3297    );
3298    assert_eq!(
3299        unsafe {
3300            ::std::ptr::addr_of!((*ptr).ldvlv_before_count) as usize - ptr as usize
3301        },
3302        4usize,
3303        concat!(
3304            "Offset of field: ",
3305            stringify!(ldapvlvinfo),
3306            "::",
3307            stringify!(ldvlv_before_count),
3308        ),
3309    );
3310    assert_eq!(
3311        unsafe {
3312            ::std::ptr::addr_of!((*ptr).ldvlv_after_count) as usize - ptr as usize
3313        },
3314        8usize,
3315        concat!(
3316            "Offset of field: ",
3317            stringify!(ldapvlvinfo),
3318            "::",
3319            stringify!(ldvlv_after_count),
3320        ),
3321    );
3322    assert_eq!(
3323        unsafe { ::std::ptr::addr_of!((*ptr).ldvlv_offset) as usize - ptr as usize },
3324        12usize,
3325        concat!(
3326            "Offset of field: ",
3327            stringify!(ldapvlvinfo),
3328            "::",
3329            stringify!(ldvlv_offset),
3330        ),
3331    );
3332    assert_eq!(
3333        unsafe { ::std::ptr::addr_of!((*ptr).ldvlv_count) as usize - ptr as usize },
3334        16usize,
3335        concat!(
3336            "Offset of field: ",
3337            stringify!(ldapvlvinfo),
3338            "::",
3339            stringify!(ldvlv_count),
3340        ),
3341    );
3342    assert_eq!(
3343        unsafe { ::std::ptr::addr_of!((*ptr).ldvlv_attrvalue) as usize - ptr as usize },
3344        24usize,
3345        concat!(
3346            "Offset of field: ",
3347            stringify!(ldapvlvinfo),
3348            "::",
3349            stringify!(ldvlv_attrvalue),
3350        ),
3351    );
3352    assert_eq!(
3353        unsafe { ::std::ptr::addr_of!((*ptr).ldvlv_context) as usize - ptr as usize },
3354        32usize,
3355        concat!(
3356            "Offset of field: ",
3357            stringify!(ldapvlvinfo),
3358            "::",
3359            stringify!(ldvlv_context),
3360        ),
3361    );
3362    assert_eq!(
3363        unsafe { ::std::ptr::addr_of!((*ptr).ldvlv_extradata) as usize - ptr as usize },
3364        40usize,
3365        concat!(
3366            "Offset of field: ",
3367            stringify!(ldapvlvinfo),
3368            "::",
3369            stringify!(ldvlv_extradata),
3370        ),
3371    );
3372}
3373pub type LDAPVLVInfo = ldapvlvinfo;
3374extern "C" {
3375    pub fn ldap_create_vlv_control_value(
3376        ld: *mut LDAP,
3377        ldvlistp: *mut LDAPVLVInfo,
3378        value: *mut berval,
3379    ) -> ::std::os::raw::c_int;
3380}
3381extern "C" {
3382    pub fn ldap_create_vlv_control(
3383        ld: *mut LDAP,
3384        ldvlistp: *mut LDAPVLVInfo,
3385        ctrlp: *mut *mut LDAPControl,
3386    ) -> ::std::os::raw::c_int;
3387}
3388extern "C" {
3389    pub fn ldap_parse_vlvresponse_control(
3390        ld: *mut LDAP,
3391        ctrls: *mut LDAPControl,
3392        target_posp: *mut ber_int_t,
3393        list_countp: *mut ber_int_t,
3394        contextp: *mut *mut berval,
3395        errcodep: *mut ::std::os::raw::c_int,
3396    ) -> ::std::os::raw::c_int;
3397}
3398extern "C" {
3399    pub fn ldap_verify_credentials(
3400        ld: *mut LDAP,
3401        cookie: *mut berval,
3402        dn: *const ::std::os::raw::c_char,
3403        mechanism: *const ::std::os::raw::c_char,
3404        cred: *mut berval,
3405        ctrls: *mut *mut LDAPControl,
3406        serverctrls: *mut *mut LDAPControl,
3407        clientctrls: *mut *mut LDAPControl,
3408        msgidp: *mut ::std::os::raw::c_int,
3409    ) -> ::std::os::raw::c_int;
3410}
3411extern "C" {
3412    pub fn ldap_verify_credentials_s(
3413        ld: *mut LDAP,
3414        cookie: *mut berval,
3415        dn: *const ::std::os::raw::c_char,
3416        mechanism: *const ::std::os::raw::c_char,
3417        cred: *mut berval,
3418        vcictrls: *mut *mut LDAPControl,
3419        serverctrls: *mut *mut LDAPControl,
3420        clientctrls: *mut *mut LDAPControl,
3421        code: *mut ::std::os::raw::c_int,
3422        diagmsgp: *mut *mut ::std::os::raw::c_char,
3423        scookie: *mut *mut berval,
3424        servercredp: *mut *mut berval,
3425        vcoctrls: *mut *mut *mut LDAPControl,
3426    ) -> ::std::os::raw::c_int;
3427}
3428extern "C" {
3429    pub fn ldap_parse_verify_credentials(
3430        ld: *mut LDAP,
3431        res: *mut LDAPMessage,
3432        code: *mut ::std::os::raw::c_int,
3433        diagmsgp: *mut *mut ::std::os::raw::c_char,
3434        cookie: *mut *mut berval,
3435        servercredp: *mut *mut berval,
3436        vcctrls: *mut *mut *mut LDAPControl,
3437    ) -> ::std::os::raw::c_int;
3438}
3439extern "C" {
3440    pub fn ldap_parse_whoami(
3441        ld: *mut LDAP,
3442        res: *mut LDAPMessage,
3443        authzid: *mut *mut berval,
3444    ) -> ::std::os::raw::c_int;
3445}
3446extern "C" {
3447    pub fn ldap_whoami(
3448        ld: *mut LDAP,
3449        sctrls: *mut *mut LDAPControl,
3450        cctrls: *mut *mut LDAPControl,
3451        msgidp: *mut ::std::os::raw::c_int,
3452    ) -> ::std::os::raw::c_int;
3453}
3454extern "C" {
3455    pub fn ldap_whoami_s(
3456        ld: *mut LDAP,
3457        authzid: *mut *mut berval,
3458        sctrls: *mut *mut LDAPControl,
3459        cctrls: *mut *mut LDAPControl,
3460    ) -> ::std::os::raw::c_int;
3461}
3462extern "C" {
3463    pub fn ldap_parse_passwd(
3464        ld: *mut LDAP,
3465        res: *mut LDAPMessage,
3466        newpasswd: *mut berval,
3467    ) -> ::std::os::raw::c_int;
3468}
3469extern "C" {
3470    pub fn ldap_passwd(
3471        ld: *mut LDAP,
3472        user: *mut berval,
3473        oldpw: *mut berval,
3474        newpw: *mut berval,
3475        sctrls: *mut *mut LDAPControl,
3476        cctrls: *mut *mut LDAPControl,
3477        msgidp: *mut ::std::os::raw::c_int,
3478    ) -> ::std::os::raw::c_int;
3479}
3480extern "C" {
3481    pub fn ldap_passwd_s(
3482        ld: *mut LDAP,
3483        user: *mut berval,
3484        oldpw: *mut berval,
3485        newpw: *mut berval,
3486        newpasswd: *mut berval,
3487        sctrls: *mut *mut LDAPControl,
3488        cctrls: *mut *mut LDAPControl,
3489    ) -> ::std::os::raw::c_int;
3490}
3491pub const passpolicyerror_enum_PP_passwordExpired: passpolicyerror_enum = 0;
3492pub const passpolicyerror_enum_PP_accountLocked: passpolicyerror_enum = 1;
3493pub const passpolicyerror_enum_PP_changeAfterReset: passpolicyerror_enum = 2;
3494pub const passpolicyerror_enum_PP_passwordModNotAllowed: passpolicyerror_enum = 3;
3495pub const passpolicyerror_enum_PP_mustSupplyOldPassword: passpolicyerror_enum = 4;
3496pub const passpolicyerror_enum_PP_insufficientPasswordQuality: passpolicyerror_enum = 5;
3497pub const passpolicyerror_enum_PP_passwordTooShort: passpolicyerror_enum = 6;
3498pub const passpolicyerror_enum_PP_passwordTooYoung: passpolicyerror_enum = 7;
3499pub const passpolicyerror_enum_PP_passwordInHistory: passpolicyerror_enum = 8;
3500pub const passpolicyerror_enum_PP_passwordTooLong: passpolicyerror_enum = 9;
3501pub const passpolicyerror_enum_PP_noError: passpolicyerror_enum = 65535;
3502pub type passpolicyerror_enum = ::std::os::raw::c_uint;
3503pub use self::passpolicyerror_enum as LDAPPasswordPolicyError;
3504extern "C" {
3505    pub fn ldap_create_passwordpolicy_control(
3506        ld: *mut LDAP,
3507        ctrlp: *mut *mut LDAPControl,
3508    ) -> ::std::os::raw::c_int;
3509}
3510extern "C" {
3511    pub fn ldap_parse_passwordpolicy_control(
3512        ld: *mut LDAP,
3513        ctrl: *mut LDAPControl,
3514        expirep: *mut ber_int_t,
3515        gracep: *mut ber_int_t,
3516        errorp: *mut LDAPPasswordPolicyError,
3517    ) -> ::std::os::raw::c_int;
3518}
3519extern "C" {
3520    pub fn ldap_passwordpolicy_err2txt(
3521        arg1: LDAPPasswordPolicyError,
3522    ) -> *const ::std::os::raw::c_char;
3523}
3524extern "C" {
3525    pub fn ldap_parse_password_expiring_control(
3526        ld: *mut LDAP,
3527        ctrl: *mut LDAPControl,
3528        secondsp: *mut ::std::os::raw::c_long,
3529    ) -> ::std::os::raw::c_int;
3530}
3531extern "C" {
3532    pub fn ldap_parse_refresh(
3533        ld: *mut LDAP,
3534        res: *mut LDAPMessage,
3535        newttl: *mut ber_int_t,
3536    ) -> ::std::os::raw::c_int;
3537}
3538extern "C" {
3539    pub fn ldap_refresh(
3540        ld: *mut LDAP,
3541        dn: *mut berval,
3542        ttl: ber_int_t,
3543        sctrls: *mut *mut LDAPControl,
3544        cctrls: *mut *mut LDAPControl,
3545        msgidp: *mut ::std::os::raw::c_int,
3546    ) -> ::std::os::raw::c_int;
3547}
3548extern "C" {
3549    pub fn ldap_refresh_s(
3550        ld: *mut LDAP,
3551        dn: *mut berval,
3552        ttl: ber_int_t,
3553        newttl: *mut ber_int_t,
3554        sctrls: *mut *mut LDAPControl,
3555        cctrls: *mut *mut LDAPControl,
3556    ) -> ::std::os::raw::c_int;
3557}
3558extern "C" {
3559    pub fn ldap_txn_start(
3560        ld: *mut LDAP,
3561        sctrls: *mut *mut LDAPControl,
3562        cctrls: *mut *mut LDAPControl,
3563        msgidp: *mut ::std::os::raw::c_int,
3564    ) -> ::std::os::raw::c_int;
3565}
3566extern "C" {
3567    pub fn ldap_txn_start_s(
3568        ld: *mut LDAP,
3569        sctrl: *mut *mut LDAPControl,
3570        cctrl: *mut *mut LDAPControl,
3571        rettxnid: *mut *mut berval,
3572    ) -> ::std::os::raw::c_int;
3573}
3574extern "C" {
3575    pub fn ldap_txn_end(
3576        ld: *mut LDAP,
3577        commit: ::std::os::raw::c_int,
3578        txnid: *mut berval,
3579        sctrls: *mut *mut LDAPControl,
3580        cctrls: *mut *mut LDAPControl,
3581        msgidp: *mut ::std::os::raw::c_int,
3582    ) -> ::std::os::raw::c_int;
3583}
3584extern "C" {
3585    pub fn ldap_txn_end_s(
3586        ld: *mut LDAP,
3587        commit: ::std::os::raw::c_int,
3588        txnid: *mut berval,
3589        sctrl: *mut *mut LDAPControl,
3590        cctrl: *mut *mut LDAPControl,
3591        retidp: *mut ::std::os::raw::c_int,
3592    ) -> ::std::os::raw::c_int;
3593}
3594extern "C" {
3595    pub fn ldap_sync_initialize(ls: *mut ldap_sync_t) -> *mut ldap_sync_t;
3596}
3597extern "C" {
3598    pub fn ldap_sync_destroy(ls: *mut ldap_sync_t, freeit: ::std::os::raw::c_int);
3599}
3600extern "C" {
3601    pub fn ldap_sync_init(
3602        ls: *mut ldap_sync_t,
3603        mode: ::std::os::raw::c_int,
3604    ) -> ::std::os::raw::c_int;
3605}
3606extern "C" {
3607    pub fn ldap_sync_init_refresh_only(ls: *mut ldap_sync_t) -> ::std::os::raw::c_int;
3608}
3609extern "C" {
3610    pub fn ldap_sync_init_refresh_and_persist(
3611        ls: *mut ldap_sync_t,
3612    ) -> ::std::os::raw::c_int;
3613}
3614extern "C" {
3615    pub fn ldap_sync_poll(ls: *mut ldap_sync_t) -> ::std::os::raw::c_int;
3616}
3617extern "C" {
3618    pub fn ldap_create_session_tracking_value(
3619        ld: *mut LDAP,
3620        sessionSourceIp: *mut ::std::os::raw::c_char,
3621        sessionSourceName: *mut ::std::os::raw::c_char,
3622        formatOID: *mut ::std::os::raw::c_char,
3623        sessionTrackingIdentifier: *mut berval,
3624        value: *mut berval,
3625    ) -> ::std::os::raw::c_int;
3626}
3627extern "C" {
3628    pub fn ldap_create_session_tracking_control(
3629        ld: *mut LDAP,
3630        sessionSourceIp: *mut ::std::os::raw::c_char,
3631        sessionSourceName: *mut ::std::os::raw::c_char,
3632        formatOID: *mut ::std::os::raw::c_char,
3633        sessionTrackingIdentifier: *mut berval,
3634        ctrlp: *mut *mut LDAPControl,
3635    ) -> ::std::os::raw::c_int;
3636}
3637extern "C" {
3638    pub fn ldap_parse_session_tracking_control(
3639        ld: *mut LDAP,
3640        ctrl: *mut LDAPControl,
3641        ip: *mut berval,
3642        name: *mut berval,
3643        oid: *mut berval,
3644        id: *mut berval,
3645    ) -> ::std::os::raw::c_int;
3646}
3647extern "C" {
3648    pub fn ldap_create_dirsync_value(
3649        ld: *mut LDAP,
3650        flags: ::std::os::raw::c_int,
3651        maxAttrCount: ::std::os::raw::c_int,
3652        cookie: *mut berval,
3653        value: *mut berval,
3654    ) -> ::std::os::raw::c_int;
3655}
3656extern "C" {
3657    pub fn ldap_create_dirsync_control(
3658        ld: *mut LDAP,
3659        flags: ::std::os::raw::c_int,
3660        maxAttrCount: ::std::os::raw::c_int,
3661        cookie: *mut berval,
3662        ctrlp: *mut *mut LDAPControl,
3663    ) -> ::std::os::raw::c_int;
3664}
3665extern "C" {
3666    pub fn ldap_parse_dirsync_control(
3667        ld: *mut LDAP,
3668        ctrl: *mut LDAPControl,
3669        continueFlag: *mut ::std::os::raw::c_int,
3670        cookie: *mut berval,
3671    ) -> ::std::os::raw::c_int;
3672}
3673extern "C" {
3674    pub fn ldap_create_extended_dn_value(
3675        ld: *mut LDAP,
3676        flag: ::std::os::raw::c_int,
3677        value: *mut berval,
3678    ) -> ::std::os::raw::c_int;
3679}
3680extern "C" {
3681    pub fn ldap_create_extended_dn_control(
3682        ld: *mut LDAP,
3683        flag: ::std::os::raw::c_int,
3684        ctrlp: *mut *mut LDAPControl,
3685    ) -> ::std::os::raw::c_int;
3686}
3687extern "C" {
3688    pub fn ldap_create_show_deleted_control(
3689        ld: *mut LDAP,
3690        ctrlp: *mut *mut LDAPControl,
3691    ) -> ::std::os::raw::c_int;
3692}
3693extern "C" {
3694    pub fn ldap_create_server_notification_control(
3695        ld: *mut LDAP,
3696        ctrlp: *mut *mut LDAPControl,
3697    ) -> ::std::os::raw::c_int;
3698}
3699extern "C" {
3700    pub fn ldap_create_assertion_control_value(
3701        ld: *mut LDAP,
3702        assertion: *mut ::std::os::raw::c_char,
3703        value: *mut berval,
3704    ) -> ::std::os::raw::c_int;
3705}
3706extern "C" {
3707    pub fn ldap_create_assertion_control(
3708        ld: *mut LDAP,
3709        filter: *mut ::std::os::raw::c_char,
3710        iscritical: ::std::os::raw::c_int,
3711        ctrlp: *mut *mut LDAPControl,
3712    ) -> ::std::os::raw::c_int;
3713}
3714#[repr(C)]
3715#[derive(Debug, Copy, Clone)]
3716pub struct LDAPDerefSpec {
3717    pub derefAttr: *mut ::std::os::raw::c_char,
3718    pub attributes: *mut *mut ::std::os::raw::c_char,
3719}
3720#[test]
3721fn bindgen_test_layout_LDAPDerefSpec() {
3722    const UNINIT: ::std::mem::MaybeUninit<LDAPDerefSpec> = ::std::mem::MaybeUninit::uninit();
3723    let ptr = UNINIT.as_ptr();
3724    assert_eq!(
3725        ::std::mem::size_of::<LDAPDerefSpec>(),
3726        16usize,
3727        concat!("Size of: ", stringify!(LDAPDerefSpec)),
3728    );
3729    assert_eq!(
3730        ::std::mem::align_of::<LDAPDerefSpec>(),
3731        8usize,
3732        concat!("Alignment of ", stringify!(LDAPDerefSpec)),
3733    );
3734    assert_eq!(
3735        unsafe { ::std::ptr::addr_of!((*ptr).derefAttr) as usize - ptr as usize },
3736        0usize,
3737        concat!(
3738            "Offset of field: ",
3739            stringify!(LDAPDerefSpec),
3740            "::",
3741            stringify!(derefAttr),
3742        ),
3743    );
3744    assert_eq!(
3745        unsafe { ::std::ptr::addr_of!((*ptr).attributes) as usize - ptr as usize },
3746        8usize,
3747        concat!(
3748            "Offset of field: ",
3749            stringify!(LDAPDerefSpec),
3750            "::",
3751            stringify!(attributes),
3752        ),
3753    );
3754}
3755#[repr(C)]
3756#[derive(Debug, Copy, Clone)]
3757pub struct LDAPDerefVal {
3758    pub type_: *mut ::std::os::raw::c_char,
3759    pub vals: BerVarray,
3760    pub next: *mut LDAPDerefVal,
3761}
3762#[test]
3763fn bindgen_test_layout_LDAPDerefVal() {
3764    const UNINIT: ::std::mem::MaybeUninit<LDAPDerefVal> = ::std::mem::MaybeUninit::uninit();
3765    let ptr = UNINIT.as_ptr();
3766    assert_eq!(
3767        ::std::mem::size_of::<LDAPDerefVal>(),
3768        24usize,
3769        concat!("Size of: ", stringify!(LDAPDerefVal)),
3770    );
3771    assert_eq!(
3772        ::std::mem::align_of::<LDAPDerefVal>(),
3773        8usize,
3774        concat!("Alignment of ", stringify!(LDAPDerefVal)),
3775    );
3776    assert_eq!(
3777        unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize },
3778        0usize,
3779        concat!("Offset of field: ", stringify!(LDAPDerefVal), "::", stringify!(type_)),
3780    );
3781    assert_eq!(
3782        unsafe { ::std::ptr::addr_of!((*ptr).vals) as usize - ptr as usize },
3783        8usize,
3784        concat!("Offset of field: ", stringify!(LDAPDerefVal), "::", stringify!(vals)),
3785    );
3786    assert_eq!(
3787        unsafe { ::std::ptr::addr_of!((*ptr).next) as usize - ptr as usize },
3788        16usize,
3789        concat!("Offset of field: ", stringify!(LDAPDerefVal), "::", stringify!(next)),
3790    );
3791}
3792#[repr(C)]
3793#[derive(Debug, Copy, Clone)]
3794pub struct LDAPDerefRes {
3795    pub derefAttr: *mut ::std::os::raw::c_char,
3796    pub derefVal: berval,
3797    pub attrVals: *mut LDAPDerefVal,
3798    pub next: *mut LDAPDerefRes,
3799}
3800#[test]
3801fn bindgen_test_layout_LDAPDerefRes() {
3802    const UNINIT: ::std::mem::MaybeUninit<LDAPDerefRes> = ::std::mem::MaybeUninit::uninit();
3803    let ptr = UNINIT.as_ptr();
3804    assert_eq!(
3805        ::std::mem::size_of::<LDAPDerefRes>(),
3806        40usize,
3807        concat!("Size of: ", stringify!(LDAPDerefRes)),
3808    );
3809    assert_eq!(
3810        ::std::mem::align_of::<LDAPDerefRes>(),
3811        8usize,
3812        concat!("Alignment of ", stringify!(LDAPDerefRes)),
3813    );
3814    assert_eq!(
3815        unsafe { ::std::ptr::addr_of!((*ptr).derefAttr) as usize - ptr as usize },
3816        0usize,
3817        concat!(
3818            "Offset of field: ",
3819            stringify!(LDAPDerefRes),
3820            "::",
3821            stringify!(derefAttr),
3822        ),
3823    );
3824    assert_eq!(
3825        unsafe { ::std::ptr::addr_of!((*ptr).derefVal) as usize - ptr as usize },
3826        8usize,
3827        concat!(
3828            "Offset of field: ",
3829            stringify!(LDAPDerefRes),
3830            "::",
3831            stringify!(derefVal),
3832        ),
3833    );
3834    assert_eq!(
3835        unsafe { ::std::ptr::addr_of!((*ptr).attrVals) as usize - ptr as usize },
3836        24usize,
3837        concat!(
3838            "Offset of field: ",
3839            stringify!(LDAPDerefRes),
3840            "::",
3841            stringify!(attrVals),
3842        ),
3843    );
3844    assert_eq!(
3845        unsafe { ::std::ptr::addr_of!((*ptr).next) as usize - ptr as usize },
3846        32usize,
3847        concat!("Offset of field: ", stringify!(LDAPDerefRes), "::", stringify!(next)),
3848    );
3849}
3850extern "C" {
3851    pub fn ldap_create_deref_control_value(
3852        ld: *mut LDAP,
3853        ds: *mut LDAPDerefSpec,
3854        value: *mut berval,
3855    ) -> ::std::os::raw::c_int;
3856}
3857extern "C" {
3858    pub fn ldap_create_deref_control(
3859        ld: *mut LDAP,
3860        ds: *mut LDAPDerefSpec,
3861        iscritical: ::std::os::raw::c_int,
3862        ctrlp: *mut *mut LDAPControl,
3863    ) -> ::std::os::raw::c_int;
3864}
3865extern "C" {
3866    pub fn ldap_derefresponse_free(dr: *mut LDAPDerefRes);
3867}
3868extern "C" {
3869    pub fn ldap_parse_derefresponse_control(
3870        ld: *mut LDAP,
3871        ctrl: *mut LDAPControl,
3872        drp: *mut *mut LDAPDerefRes,
3873    ) -> ::std::os::raw::c_int;
3874}
3875extern "C" {
3876    pub fn ldap_parse_deref_control(
3877        ld: *mut LDAP,
3878        ctrls: *mut *mut LDAPControl,
3879        drp: *mut *mut LDAPDerefRes,
3880    ) -> ::std::os::raw::c_int;
3881}
3882extern "C" {
3883    pub fn ldap_create_persistentsearch_control_value(
3884        ld: *mut LDAP,
3885        changetypes: ::std::os::raw::c_int,
3886        changesonly: ::std::os::raw::c_int,
3887        return_echg_ctls: ::std::os::raw::c_int,
3888        value: *mut berval,
3889    ) -> ::std::os::raw::c_int;
3890}
3891extern "C" {
3892    pub fn ldap_create_persistentsearch_control(
3893        ld: *mut LDAP,
3894        changetypes: ::std::os::raw::c_int,
3895        changesonly: ::std::os::raw::c_int,
3896        return_echg_ctls: ::std::os::raw::c_int,
3897        isCritical: ::std::os::raw::c_int,
3898        ctrlp: *mut *mut LDAPControl,
3899    ) -> ::std::os::raw::c_int;
3900}
3901extern "C" {
3902    pub fn ldap_parse_entrychange_control(
3903        ld: *mut LDAP,
3904        ctrl: *mut LDAPControl,
3905        chgtypep: *mut ::std::os::raw::c_int,
3906        prevdnp: *mut berval,
3907        chgnumpresentp: *mut ::std::os::raw::c_int,
3908        chgnump: *mut ::std::os::raw::c_long,
3909    ) -> ::std::os::raw::c_int;
3910}
3911extern "C" {
3912    pub fn ldap_create_accountusability_control(
3913        ld: *mut LDAP,
3914        ctrlp: *mut *mut LDAPControl,
3915    ) -> ::std::os::raw::c_int;
3916}
3917#[repr(C)]
3918#[derive(Debug, Copy, Clone)]
3919pub struct LDAPAccountUsabilityMoreInfo {
3920    pub inactive: ber_int_t,
3921    pub reset: ber_int_t,
3922    pub expired: ber_int_t,
3923    pub remaining_grace: ber_int_t,
3924    pub seconds_before_unlock: ber_int_t,
3925}
3926#[test]
3927fn bindgen_test_layout_LDAPAccountUsabilityMoreInfo() {
3928    const UNINIT: ::std::mem::MaybeUninit<LDAPAccountUsabilityMoreInfo> = ::std::mem::MaybeUninit::uninit();
3929    let ptr = UNINIT.as_ptr();
3930    assert_eq!(
3931        ::std::mem::size_of::<LDAPAccountUsabilityMoreInfo>(),
3932        20usize,
3933        concat!("Size of: ", stringify!(LDAPAccountUsabilityMoreInfo)),
3934    );
3935    assert_eq!(
3936        ::std::mem::align_of::<LDAPAccountUsabilityMoreInfo>(),
3937        4usize,
3938        concat!("Alignment of ", stringify!(LDAPAccountUsabilityMoreInfo)),
3939    );
3940    assert_eq!(
3941        unsafe { ::std::ptr::addr_of!((*ptr).inactive) as usize - ptr as usize },
3942        0usize,
3943        concat!(
3944            "Offset of field: ",
3945            stringify!(LDAPAccountUsabilityMoreInfo),
3946            "::",
3947            stringify!(inactive),
3948        ),
3949    );
3950    assert_eq!(
3951        unsafe { ::std::ptr::addr_of!((*ptr).reset) as usize - ptr as usize },
3952        4usize,
3953        concat!(
3954            "Offset of field: ",
3955            stringify!(LDAPAccountUsabilityMoreInfo),
3956            "::",
3957            stringify!(reset),
3958        ),
3959    );
3960    assert_eq!(
3961        unsafe { ::std::ptr::addr_of!((*ptr).expired) as usize - ptr as usize },
3962        8usize,
3963        concat!(
3964            "Offset of field: ",
3965            stringify!(LDAPAccountUsabilityMoreInfo),
3966            "::",
3967            stringify!(expired),
3968        ),
3969    );
3970    assert_eq!(
3971        unsafe { ::std::ptr::addr_of!((*ptr).remaining_grace) as usize - ptr as usize },
3972        12usize,
3973        concat!(
3974            "Offset of field: ",
3975            stringify!(LDAPAccountUsabilityMoreInfo),
3976            "::",
3977            stringify!(remaining_grace),
3978        ),
3979    );
3980    assert_eq!(
3981        unsafe {
3982            ::std::ptr::addr_of!((*ptr).seconds_before_unlock) as usize - ptr as usize
3983        },
3984        16usize,
3985        concat!(
3986            "Offset of field: ",
3987            stringify!(LDAPAccountUsabilityMoreInfo),
3988            "::",
3989            stringify!(seconds_before_unlock),
3990        ),
3991    );
3992}
3993#[repr(C)]
3994#[derive(Copy, Clone)]
3995pub union LDAPAccountUsability {
3996    pub seconds_remaining: ber_int_t,
3997    pub more_info: LDAPAccountUsabilityMoreInfo,
3998}
3999#[test]
4000fn bindgen_test_layout_LDAPAccountUsability() {
4001    const UNINIT: ::std::mem::MaybeUninit<LDAPAccountUsability> = ::std::mem::MaybeUninit::uninit();
4002    let ptr = UNINIT.as_ptr();
4003    assert_eq!(
4004        ::std::mem::size_of::<LDAPAccountUsability>(),
4005        20usize,
4006        concat!("Size of: ", stringify!(LDAPAccountUsability)),
4007    );
4008    assert_eq!(
4009        ::std::mem::align_of::<LDAPAccountUsability>(),
4010        4usize,
4011        concat!("Alignment of ", stringify!(LDAPAccountUsability)),
4012    );
4013    assert_eq!(
4014        unsafe {
4015            ::std::ptr::addr_of!((*ptr).seconds_remaining) as usize - ptr as usize
4016        },
4017        0usize,
4018        concat!(
4019            "Offset of field: ",
4020            stringify!(LDAPAccountUsability),
4021            "::",
4022            stringify!(seconds_remaining),
4023        ),
4024    );
4025    assert_eq!(
4026        unsafe { ::std::ptr::addr_of!((*ptr).more_info) as usize - ptr as usize },
4027        0usize,
4028        concat!(
4029            "Offset of field: ",
4030            stringify!(LDAPAccountUsability),
4031            "::",
4032            stringify!(more_info),
4033        ),
4034    );
4035}
4036extern "C" {
4037    pub fn ldap_parse_accountusability_control(
4038        ld: *mut LDAP,
4039        ctrl: *mut LDAPControl,
4040        availablep: *mut ::std::os::raw::c_int,
4041        usabilityp: *mut LDAPAccountUsability,
4042    ) -> ::std::os::raw::c_int;
4043}
4044#[repr(C)]
4045#[derive(Copy, Clone)]
4046pub struct ldifrecord {
4047    pub lr_op: ber_tag_t,
4048    pub lr_dn: berval,
4049    pub lr_ctrls: *mut *mut LDAPControl,
4050    pub ldif_ops: ldifrecord_ldif_ops_u,
4051    pub lr_ctx: *mut ::std::os::raw::c_void,
4052    pub lr_lines: ::std::os::raw::c_int,
4053    pub lr_lm: *mut LDAPMod,
4054    pub lr_mops: *mut ::std::os::raw::c_uchar,
4055    pub lr_freeval: *mut ::std::os::raw::c_char,
4056    pub lr_vals: *mut berval,
4057    pub lr_btype: *mut berval,
4058}
4059#[repr(C)]
4060#[derive(Copy, Clone)]
4061pub union ldifrecord_ldif_ops_u {
4062    pub lr_mods: *mut *mut LDAPMod,
4063    pub ldif_op_rename: ldifrecord_ldif_ops_u_ldif_op_rename_s,
4064    pub ldif_op_ext: ldifrecord_ldif_ops_u_ldif_op_ext_s,
4065    pub ldif_op_cmp: ldifrecord_ldif_ops_u_ldif_op_cmp_s,
4066}
4067#[repr(C)]
4068#[derive(Debug, Copy, Clone)]
4069pub struct ldifrecord_ldif_ops_u_ldif_op_rename_s {
4070    pub lr_newrdn: berval,
4071    pub lr_newsuperior: berval,
4072    pub lr_deleteoldrdn: ::std::os::raw::c_int,
4073}
4074#[test]
4075fn bindgen_test_layout_ldifrecord_ldif_ops_u_ldif_op_rename_s() {
4076    const UNINIT: ::std::mem::MaybeUninit<ldifrecord_ldif_ops_u_ldif_op_rename_s> = ::std::mem::MaybeUninit::uninit();
4077    let ptr = UNINIT.as_ptr();
4078    assert_eq!(
4079        ::std::mem::size_of::<ldifrecord_ldif_ops_u_ldif_op_rename_s>(),
4080        40usize,
4081        concat!("Size of: ", stringify!(ldifrecord_ldif_ops_u_ldif_op_rename_s)),
4082    );
4083    assert_eq!(
4084        ::std::mem::align_of::<ldifrecord_ldif_ops_u_ldif_op_rename_s>(),
4085        8usize,
4086        concat!("Alignment of ", stringify!(ldifrecord_ldif_ops_u_ldif_op_rename_s)),
4087    );
4088    assert_eq!(
4089        unsafe { ::std::ptr::addr_of!((*ptr).lr_newrdn) as usize - ptr as usize },
4090        0usize,
4091        concat!(
4092            "Offset of field: ",
4093            stringify!(ldifrecord_ldif_ops_u_ldif_op_rename_s),
4094            "::",
4095            stringify!(lr_newrdn),
4096        ),
4097    );
4098    assert_eq!(
4099        unsafe { ::std::ptr::addr_of!((*ptr).lr_newsuperior) as usize - ptr as usize },
4100        16usize,
4101        concat!(
4102            "Offset of field: ",
4103            stringify!(ldifrecord_ldif_ops_u_ldif_op_rename_s),
4104            "::",
4105            stringify!(lr_newsuperior),
4106        ),
4107    );
4108    assert_eq!(
4109        unsafe { ::std::ptr::addr_of!((*ptr).lr_deleteoldrdn) as usize - ptr as usize },
4110        32usize,
4111        concat!(
4112            "Offset of field: ",
4113            stringify!(ldifrecord_ldif_ops_u_ldif_op_rename_s),
4114            "::",
4115            stringify!(lr_deleteoldrdn),
4116        ),
4117    );
4118}
4119#[repr(C)]
4120#[derive(Debug, Copy, Clone)]
4121pub struct ldifrecord_ldif_ops_u_ldif_op_ext_s {
4122    pub lr_extop_oid: berval,
4123    pub lr_extop_data: berval,
4124}
4125#[test]
4126fn bindgen_test_layout_ldifrecord_ldif_ops_u_ldif_op_ext_s() {
4127    const UNINIT: ::std::mem::MaybeUninit<ldifrecord_ldif_ops_u_ldif_op_ext_s> = ::std::mem::MaybeUninit::uninit();
4128    let ptr = UNINIT.as_ptr();
4129    assert_eq!(
4130        ::std::mem::size_of::<ldifrecord_ldif_ops_u_ldif_op_ext_s>(),
4131        32usize,
4132        concat!("Size of: ", stringify!(ldifrecord_ldif_ops_u_ldif_op_ext_s)),
4133    );
4134    assert_eq!(
4135        ::std::mem::align_of::<ldifrecord_ldif_ops_u_ldif_op_ext_s>(),
4136        8usize,
4137        concat!("Alignment of ", stringify!(ldifrecord_ldif_ops_u_ldif_op_ext_s)),
4138    );
4139    assert_eq!(
4140        unsafe { ::std::ptr::addr_of!((*ptr).lr_extop_oid) as usize - ptr as usize },
4141        0usize,
4142        concat!(
4143            "Offset of field: ",
4144            stringify!(ldifrecord_ldif_ops_u_ldif_op_ext_s),
4145            "::",
4146            stringify!(lr_extop_oid),
4147        ),
4148    );
4149    assert_eq!(
4150        unsafe { ::std::ptr::addr_of!((*ptr).lr_extop_data) as usize - ptr as usize },
4151        16usize,
4152        concat!(
4153            "Offset of field: ",
4154            stringify!(ldifrecord_ldif_ops_u_ldif_op_ext_s),
4155            "::",
4156            stringify!(lr_extop_data),
4157        ),
4158    );
4159}
4160#[repr(C)]
4161#[derive(Debug, Copy, Clone)]
4162pub struct ldifrecord_ldif_ops_u_ldif_op_cmp_s {
4163    pub lr_cmp_attr: berval,
4164    pub lr_cmp_bvalue: berval,
4165}
4166#[test]
4167fn bindgen_test_layout_ldifrecord_ldif_ops_u_ldif_op_cmp_s() {
4168    const UNINIT: ::std::mem::MaybeUninit<ldifrecord_ldif_ops_u_ldif_op_cmp_s> = ::std::mem::MaybeUninit::uninit();
4169    let ptr = UNINIT.as_ptr();
4170    assert_eq!(
4171        ::std::mem::size_of::<ldifrecord_ldif_ops_u_ldif_op_cmp_s>(),
4172        32usize,
4173        concat!("Size of: ", stringify!(ldifrecord_ldif_ops_u_ldif_op_cmp_s)),
4174    );
4175    assert_eq!(
4176        ::std::mem::align_of::<ldifrecord_ldif_ops_u_ldif_op_cmp_s>(),
4177        8usize,
4178        concat!("Alignment of ", stringify!(ldifrecord_ldif_ops_u_ldif_op_cmp_s)),
4179    );
4180    assert_eq!(
4181        unsafe { ::std::ptr::addr_of!((*ptr).lr_cmp_attr) as usize - ptr as usize },
4182        0usize,
4183        concat!(
4184            "Offset of field: ",
4185            stringify!(ldifrecord_ldif_ops_u_ldif_op_cmp_s),
4186            "::",
4187            stringify!(lr_cmp_attr),
4188        ),
4189    );
4190    assert_eq!(
4191        unsafe { ::std::ptr::addr_of!((*ptr).lr_cmp_bvalue) as usize - ptr as usize },
4192        16usize,
4193        concat!(
4194            "Offset of field: ",
4195            stringify!(ldifrecord_ldif_ops_u_ldif_op_cmp_s),
4196            "::",
4197            stringify!(lr_cmp_bvalue),
4198        ),
4199    );
4200}
4201#[test]
4202fn bindgen_test_layout_ldifrecord_ldif_ops_u() {
4203    const UNINIT: ::std::mem::MaybeUninit<ldifrecord_ldif_ops_u> = ::std::mem::MaybeUninit::uninit();
4204    let ptr = UNINIT.as_ptr();
4205    assert_eq!(
4206        ::std::mem::size_of::<ldifrecord_ldif_ops_u>(),
4207        40usize,
4208        concat!("Size of: ", stringify!(ldifrecord_ldif_ops_u)),
4209    );
4210    assert_eq!(
4211        ::std::mem::align_of::<ldifrecord_ldif_ops_u>(),
4212        8usize,
4213        concat!("Alignment of ", stringify!(ldifrecord_ldif_ops_u)),
4214    );
4215    assert_eq!(
4216        unsafe { ::std::ptr::addr_of!((*ptr).lr_mods) as usize - ptr as usize },
4217        0usize,
4218        concat!(
4219            "Offset of field: ",
4220            stringify!(ldifrecord_ldif_ops_u),
4221            "::",
4222            stringify!(lr_mods),
4223        ),
4224    );
4225    assert_eq!(
4226        unsafe { ::std::ptr::addr_of!((*ptr).ldif_op_rename) as usize - ptr as usize },
4227        0usize,
4228        concat!(
4229            "Offset of field: ",
4230            stringify!(ldifrecord_ldif_ops_u),
4231            "::",
4232            stringify!(ldif_op_rename),
4233        ),
4234    );
4235    assert_eq!(
4236        unsafe { ::std::ptr::addr_of!((*ptr).ldif_op_ext) as usize - ptr as usize },
4237        0usize,
4238        concat!(
4239            "Offset of field: ",
4240            stringify!(ldifrecord_ldif_ops_u),
4241            "::",
4242            stringify!(ldif_op_ext),
4243        ),
4244    );
4245    assert_eq!(
4246        unsafe { ::std::ptr::addr_of!((*ptr).ldif_op_cmp) as usize - ptr as usize },
4247        0usize,
4248        concat!(
4249            "Offset of field: ",
4250            stringify!(ldifrecord_ldif_ops_u),
4251            "::",
4252            stringify!(ldif_op_cmp),
4253        ),
4254    );
4255}
4256#[test]
4257fn bindgen_test_layout_ldifrecord() {
4258    const UNINIT: ::std::mem::MaybeUninit<ldifrecord> = ::std::mem::MaybeUninit::uninit();
4259    let ptr = UNINIT.as_ptr();
4260    assert_eq!(
4261        ::std::mem::size_of::<ldifrecord>(),
4262        128usize,
4263        concat!("Size of: ", stringify!(ldifrecord)),
4264    );
4265    assert_eq!(
4266        ::std::mem::align_of::<ldifrecord>(),
4267        8usize,
4268        concat!("Alignment of ", stringify!(ldifrecord)),
4269    );
4270    assert_eq!(
4271        unsafe { ::std::ptr::addr_of!((*ptr).lr_op) as usize - ptr as usize },
4272        0usize,
4273        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_op)),
4274    );
4275    assert_eq!(
4276        unsafe { ::std::ptr::addr_of!((*ptr).lr_dn) as usize - ptr as usize },
4277        8usize,
4278        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_dn)),
4279    );
4280    assert_eq!(
4281        unsafe { ::std::ptr::addr_of!((*ptr).lr_ctrls) as usize - ptr as usize },
4282        24usize,
4283        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_ctrls)),
4284    );
4285    assert_eq!(
4286        unsafe { ::std::ptr::addr_of!((*ptr).ldif_ops) as usize - ptr as usize },
4287        32usize,
4288        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(ldif_ops)),
4289    );
4290    assert_eq!(
4291        unsafe { ::std::ptr::addr_of!((*ptr).lr_ctx) as usize - ptr as usize },
4292        72usize,
4293        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_ctx)),
4294    );
4295    assert_eq!(
4296        unsafe { ::std::ptr::addr_of!((*ptr).lr_lines) as usize - ptr as usize },
4297        80usize,
4298        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_lines)),
4299    );
4300    assert_eq!(
4301        unsafe { ::std::ptr::addr_of!((*ptr).lr_lm) as usize - ptr as usize },
4302        88usize,
4303        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_lm)),
4304    );
4305    assert_eq!(
4306        unsafe { ::std::ptr::addr_of!((*ptr).lr_mops) as usize - ptr as usize },
4307        96usize,
4308        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_mops)),
4309    );
4310    assert_eq!(
4311        unsafe { ::std::ptr::addr_of!((*ptr).lr_freeval) as usize - ptr as usize },
4312        104usize,
4313        concat!(
4314            "Offset of field: ",
4315            stringify!(ldifrecord),
4316            "::",
4317            stringify!(lr_freeval),
4318        ),
4319    );
4320    assert_eq!(
4321        unsafe { ::std::ptr::addr_of!((*ptr).lr_vals) as usize - ptr as usize },
4322        112usize,
4323        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_vals)),
4324    );
4325    assert_eq!(
4326        unsafe { ::std::ptr::addr_of!((*ptr).lr_btype) as usize - ptr as usize },
4327        120usize,
4328        concat!("Offset of field: ", stringify!(ldifrecord), "::", stringify!(lr_btype)),
4329    );
4330}
4331pub type LDIFRecord = ldifrecord;
4332extern "C" {
4333    pub fn ldap_ldif_record_done(lr: *mut LDIFRecord);
4334}
4335extern "C" {
4336    pub fn ldap_parse_ldif_record(
4337        rbuf: *mut berval,
4338        linenum: ::std::os::raw::c_ulong,
4339        lr: *mut LDIFRecord,
4340        errstr: *const ::std::os::raw::c_char,
4341        flags: ::std::os::raw::c_uint,
4342    ) -> ::std::os::raw::c_int;
4343}
4344pub type wchar_t = ::std::os::raw::c_int;
4345#[repr(C)]
4346#[repr(align(16))]
4347#[derive(Debug, Copy, Clone)]
4348pub struct max_align_t {
4349    pub __ll: ::std::os::raw::c_longlong,
4350    pub __bindgen_padding_0: u64,
4351    pub __ld: u128,
4352}
4353#[test]
4354fn bindgen_test_layout_max_align_t() {
4355    const UNINIT: ::std::mem::MaybeUninit<max_align_t> = ::std::mem::MaybeUninit::uninit();
4356    let ptr = UNINIT.as_ptr();
4357    assert_eq!(
4358        ::std::mem::size_of::<max_align_t>(),
4359        32usize,
4360        concat!("Size of: ", stringify!(max_align_t)),
4361    );
4362    assert_eq!(
4363        ::std::mem::align_of::<max_align_t>(),
4364        16usize,
4365        concat!("Alignment of ", stringify!(max_align_t)),
4366    );
4367    assert_eq!(
4368        unsafe { ::std::ptr::addr_of!((*ptr).__ll) as usize - ptr as usize },
4369        0usize,
4370        concat!("Offset of field: ", stringify!(max_align_t), "::", stringify!(__ll)),
4371    );
4372    assert_eq!(
4373        unsafe { ::std::ptr::addr_of!((*ptr).__ld) as usize - ptr as usize },
4374        16usize,
4375        concat!("Offset of field: ", stringify!(max_align_t), "::", stringify!(__ld)),
4376    );
4377}
4378#[repr(C)]
4379#[derive(Debug, Copy, Clone)]
4380pub struct propval {
4381    pub name: *const ::std::os::raw::c_char,
4382    pub values: *mut *const ::std::os::raw::c_char,
4383    pub nvalues: ::std::os::raw::c_uint,
4384    pub valsize: ::std::os::raw::c_uint,
4385}
4386#[test]
4387fn bindgen_test_layout_propval() {
4388    const UNINIT: ::std::mem::MaybeUninit<propval> = ::std::mem::MaybeUninit::uninit();
4389    let ptr = UNINIT.as_ptr();
4390    assert_eq!(
4391        ::std::mem::size_of::<propval>(),
4392        24usize,
4393        concat!("Size of: ", stringify!(propval)),
4394    );
4395    assert_eq!(
4396        ::std::mem::align_of::<propval>(),
4397        8usize,
4398        concat!("Alignment of ", stringify!(propval)),
4399    );
4400    assert_eq!(
4401        unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize },
4402        0usize,
4403        concat!("Offset of field: ", stringify!(propval), "::", stringify!(name)),
4404    );
4405    assert_eq!(
4406        unsafe { ::std::ptr::addr_of!((*ptr).values) as usize - ptr as usize },
4407        8usize,
4408        concat!("Offset of field: ", stringify!(propval), "::", stringify!(values)),
4409    );
4410    assert_eq!(
4411        unsafe { ::std::ptr::addr_of!((*ptr).nvalues) as usize - ptr as usize },
4412        16usize,
4413        concat!("Offset of field: ", stringify!(propval), "::", stringify!(nvalues)),
4414    );
4415    assert_eq!(
4416        unsafe { ::std::ptr::addr_of!((*ptr).valsize) as usize - ptr as usize },
4417        20usize,
4418        concat!("Offset of field: ", stringify!(propval), "::", stringify!(valsize)),
4419    );
4420}
4421#[repr(C)]
4422#[derive(Debug, Copy, Clone)]
4423pub struct propctx {
4424    _unused: [u8; 0],
4425}
4426extern "C" {
4427    pub fn prop_new(estimate: ::std::os::raw::c_uint) -> *mut propctx;
4428}
4429extern "C" {
4430    pub fn prop_dup(
4431        src_ctx: *mut propctx,
4432        dst_ctx: *mut *mut propctx,
4433    ) -> ::std::os::raw::c_int;
4434}
4435extern "C" {
4436    pub fn prop_request(
4437        ctx: *mut propctx,
4438        names: *mut *const ::std::os::raw::c_char,
4439    ) -> ::std::os::raw::c_int;
4440}
4441extern "C" {
4442    pub fn prop_get(ctx: *mut propctx) -> *const propval;
4443}
4444extern "C" {
4445    pub fn prop_getnames(
4446        ctx: *mut propctx,
4447        names: *mut *const ::std::os::raw::c_char,
4448        vals: *mut propval,
4449    ) -> ::std::os::raw::c_int;
4450}
4451extern "C" {
4452    pub fn prop_clear(ctx: *mut propctx, requests: ::std::os::raw::c_int);
4453}
4454extern "C" {
4455    pub fn prop_erase(ctx: *mut propctx, name: *const ::std::os::raw::c_char);
4456}
4457extern "C" {
4458    pub fn prop_dispose(ctx: *mut *mut propctx);
4459}
4460extern "C" {
4461    pub fn prop_format(
4462        ctx: *mut propctx,
4463        sep: *const ::std::os::raw::c_char,
4464        seplen: ::std::os::raw::c_int,
4465        outbuf: *mut ::std::os::raw::c_char,
4466        outmax: ::std::os::raw::c_uint,
4467        outlen: *mut ::std::os::raw::c_uint,
4468    ) -> ::std::os::raw::c_int;
4469}
4470extern "C" {
4471    pub fn prop_set(
4472        ctx: *mut propctx,
4473        name: *const ::std::os::raw::c_char,
4474        value: *const ::std::os::raw::c_char,
4475        vallen: ::std::os::raw::c_int,
4476    ) -> ::std::os::raw::c_int;
4477}
4478extern "C" {
4479    pub fn prop_setvals(
4480        ctx: *mut propctx,
4481        name: *const ::std::os::raw::c_char,
4482        values: *mut *const ::std::os::raw::c_char,
4483    ) -> ::std::os::raw::c_int;
4484}
4485#[repr(C)]
4486#[derive(Debug, Copy, Clone)]
4487pub struct iovec {
4488    _unused: [u8; 0],
4489}
4490#[repr(C)]
4491#[derive(Debug, Copy, Clone)]
4492pub struct sasl_conn {
4493    _unused: [u8; 0],
4494}
4495pub type sasl_conn_t = sasl_conn;
4496#[repr(C)]
4497#[derive(Debug, Copy, Clone)]
4498pub struct sasl_secret {
4499    pub len: ::std::os::raw::c_ulong,
4500    pub data: [::std::os::raw::c_uchar; 1usize],
4501}
4502#[test]
4503fn bindgen_test_layout_sasl_secret() {
4504    const UNINIT: ::std::mem::MaybeUninit<sasl_secret> = ::std::mem::MaybeUninit::uninit();
4505    let ptr = UNINIT.as_ptr();
4506    assert_eq!(
4507        ::std::mem::size_of::<sasl_secret>(),
4508        16usize,
4509        concat!("Size of: ", stringify!(sasl_secret)),
4510    );
4511    assert_eq!(
4512        ::std::mem::align_of::<sasl_secret>(),
4513        8usize,
4514        concat!("Alignment of ", stringify!(sasl_secret)),
4515    );
4516    assert_eq!(
4517        unsafe { ::std::ptr::addr_of!((*ptr).len) as usize - ptr as usize },
4518        0usize,
4519        concat!("Offset of field: ", stringify!(sasl_secret), "::", stringify!(len)),
4520    );
4521    assert_eq!(
4522        unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize },
4523        8usize,
4524        concat!("Offset of field: ", stringify!(sasl_secret), "::", stringify!(data)),
4525    );
4526}
4527pub type sasl_secret_t = sasl_secret;
4528#[repr(C)]
4529#[derive(Debug, Copy, Clone)]
4530pub struct sasl_rand_s {
4531    _unused: [u8; 0],
4532}
4533pub type sasl_rand_t = sasl_rand_s;
4534pub type register_t = ::std::os::raw::c_long;
4535pub type time_t = ::std::os::raw::c_long;
4536pub type suseconds_t = ::std::os::raw::c_long;
4537pub type u_int64_t = ::std::os::raw::c_ulong;
4538pub type mode_t = ::std::os::raw::c_uint;
4539pub type nlink_t = ::std::os::raw::c_ulong;
4540pub type off_t = ::std::os::raw::c_long;
4541pub type ino_t = ::std::os::raw::c_ulong;
4542pub type dev_t = ::std::os::raw::c_ulong;
4543pub type blksize_t = ::std::os::raw::c_long;
4544pub type blkcnt_t = ::std::os::raw::c_long;
4545pub type fsblkcnt_t = ::std::os::raw::c_ulong;
4546pub type fsfilcnt_t = ::std::os::raw::c_ulong;
4547pub type timer_t = *mut ::std::os::raw::c_void;
4548pub type clockid_t = ::std::os::raw::c_int;
4549pub type clock_t = ::std::os::raw::c_long;
4550pub type pid_t = ::std::os::raw::c_int;
4551pub type id_t = ::std::os::raw::c_uint;
4552pub type uid_t = ::std::os::raw::c_uint;
4553pub type gid_t = ::std::os::raw::c_uint;
4554pub type key_t = ::std::os::raw::c_int;
4555pub type useconds_t = ::std::os::raw::c_uint;
4556#[repr(C)]
4557#[derive(Debug, Copy, Clone)]
4558pub struct __pthread {
4559    _unused: [u8; 0],
4560}
4561pub type pthread_t = *mut __pthread;
4562pub type pthread_once_t = ::std::os::raw::c_int;
4563pub type pthread_key_t = ::std::os::raw::c_uint;
4564pub type pthread_spinlock_t = ::std::os::raw::c_int;
4565#[repr(C)]
4566#[derive(Debug, Copy, Clone)]
4567pub struct pthread_mutexattr_t {
4568    pub __attr: ::std::os::raw::c_uint,
4569}
4570#[test]
4571fn bindgen_test_layout_pthread_mutexattr_t() {
4572    const UNINIT: ::std::mem::MaybeUninit<pthread_mutexattr_t> = ::std::mem::MaybeUninit::uninit();
4573    let ptr = UNINIT.as_ptr();
4574    assert_eq!(
4575        ::std::mem::size_of::<pthread_mutexattr_t>(),
4576        4usize,
4577        concat!("Size of: ", stringify!(pthread_mutexattr_t)),
4578    );
4579    assert_eq!(
4580        ::std::mem::align_of::<pthread_mutexattr_t>(),
4581        4usize,
4582        concat!("Alignment of ", stringify!(pthread_mutexattr_t)),
4583    );
4584    assert_eq!(
4585        unsafe { ::std::ptr::addr_of!((*ptr).__attr) as usize - ptr as usize },
4586        0usize,
4587        concat!(
4588            "Offset of field: ",
4589            stringify!(pthread_mutexattr_t),
4590            "::",
4591            stringify!(__attr),
4592        ),
4593    );
4594}
4595#[repr(C)]
4596#[derive(Debug, Copy, Clone)]
4597pub struct pthread_condattr_t {
4598    pub __attr: ::std::os::raw::c_uint,
4599}
4600#[test]
4601fn bindgen_test_layout_pthread_condattr_t() {
4602    const UNINIT: ::std::mem::MaybeUninit<pthread_condattr_t> = ::std::mem::MaybeUninit::uninit();
4603    let ptr = UNINIT.as_ptr();
4604    assert_eq!(
4605        ::std::mem::size_of::<pthread_condattr_t>(),
4606        4usize,
4607        concat!("Size of: ", stringify!(pthread_condattr_t)),
4608    );
4609    assert_eq!(
4610        ::std::mem::align_of::<pthread_condattr_t>(),
4611        4usize,
4612        concat!("Alignment of ", stringify!(pthread_condattr_t)),
4613    );
4614    assert_eq!(
4615        unsafe { ::std::ptr::addr_of!((*ptr).__attr) as usize - ptr as usize },
4616        0usize,
4617        concat!(
4618            "Offset of field: ",
4619            stringify!(pthread_condattr_t),
4620            "::",
4621            stringify!(__attr),
4622        ),
4623    );
4624}
4625#[repr(C)]
4626#[derive(Debug, Copy, Clone)]
4627pub struct pthread_barrierattr_t {
4628    pub __attr: ::std::os::raw::c_uint,
4629}
4630#[test]
4631fn bindgen_test_layout_pthread_barrierattr_t() {
4632    const UNINIT: ::std::mem::MaybeUninit<pthread_barrierattr_t> = ::std::mem::MaybeUninit::uninit();
4633    let ptr = UNINIT.as_ptr();
4634    assert_eq!(
4635        ::std::mem::size_of::<pthread_barrierattr_t>(),
4636        4usize,
4637        concat!("Size of: ", stringify!(pthread_barrierattr_t)),
4638    );
4639    assert_eq!(
4640        ::std::mem::align_of::<pthread_barrierattr_t>(),
4641        4usize,
4642        concat!("Alignment of ", stringify!(pthread_barrierattr_t)),
4643    );
4644    assert_eq!(
4645        unsafe { ::std::ptr::addr_of!((*ptr).__attr) as usize - ptr as usize },
4646        0usize,
4647        concat!(
4648            "Offset of field: ",
4649            stringify!(pthread_barrierattr_t),
4650            "::",
4651            stringify!(__attr),
4652        ),
4653    );
4654}
4655#[repr(C)]
4656#[derive(Debug, Copy, Clone)]
4657pub struct pthread_rwlockattr_t {
4658    pub __attr: [::std::os::raw::c_uint; 2usize],
4659}
4660#[test]
4661fn bindgen_test_layout_pthread_rwlockattr_t() {
4662    const UNINIT: ::std::mem::MaybeUninit<pthread_rwlockattr_t> = ::std::mem::MaybeUninit::uninit();
4663    let ptr = UNINIT.as_ptr();
4664    assert_eq!(
4665        ::std::mem::size_of::<pthread_rwlockattr_t>(),
4666        8usize,
4667        concat!("Size of: ", stringify!(pthread_rwlockattr_t)),
4668    );
4669    assert_eq!(
4670        ::std::mem::align_of::<pthread_rwlockattr_t>(),
4671        4usize,
4672        concat!("Alignment of ", stringify!(pthread_rwlockattr_t)),
4673    );
4674    assert_eq!(
4675        unsafe { ::std::ptr::addr_of!((*ptr).__attr) as usize - ptr as usize },
4676        0usize,
4677        concat!(
4678            "Offset of field: ",
4679            stringify!(pthread_rwlockattr_t),
4680            "::",
4681            stringify!(__attr),
4682        ),
4683    );
4684}
4685#[repr(C)]
4686#[derive(Copy, Clone)]
4687pub struct pthread_attr_t {
4688    pub __u: pthread_attr_t__bindgen_ty_1,
4689}
4690#[repr(C)]
4691#[derive(Copy, Clone)]
4692pub union pthread_attr_t__bindgen_ty_1 {
4693    pub __i: [::std::os::raw::c_int; 14usize],
4694    pub __vi: [::std::os::raw::c_int; 14usize],
4695    pub __s: [::std::os::raw::c_ulong; 7usize],
4696}
4697#[test]
4698fn bindgen_test_layout_pthread_attr_t__bindgen_ty_1() {
4699    const UNINIT: ::std::mem::MaybeUninit<pthread_attr_t__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit();
4700    let ptr = UNINIT.as_ptr();
4701    assert_eq!(
4702        ::std::mem::size_of::<pthread_attr_t__bindgen_ty_1>(),
4703        56usize,
4704        concat!("Size of: ", stringify!(pthread_attr_t__bindgen_ty_1)),
4705    );
4706    assert_eq!(
4707        ::std::mem::align_of::<pthread_attr_t__bindgen_ty_1>(),
4708        8usize,
4709        concat!("Alignment of ", stringify!(pthread_attr_t__bindgen_ty_1)),
4710    );
4711    assert_eq!(
4712        unsafe { ::std::ptr::addr_of!((*ptr).__i) as usize - ptr as usize },
4713        0usize,
4714        concat!(
4715            "Offset of field: ",
4716            stringify!(pthread_attr_t__bindgen_ty_1),
4717            "::",
4718            stringify!(__i),
4719        ),
4720    );
4721    assert_eq!(
4722        unsafe { ::std::ptr::addr_of!((*ptr).__vi) as usize - ptr as usize },
4723        0usize,
4724        concat!(
4725            "Offset of field: ",
4726            stringify!(pthread_attr_t__bindgen_ty_1),
4727            "::",
4728            stringify!(__vi),
4729        ),
4730    );
4731    assert_eq!(
4732        unsafe { ::std::ptr::addr_of!((*ptr).__s) as usize - ptr as usize },
4733        0usize,
4734        concat!(
4735            "Offset of field: ",
4736            stringify!(pthread_attr_t__bindgen_ty_1),
4737            "::",
4738            stringify!(__s),
4739        ),
4740    );
4741}
4742#[test]
4743fn bindgen_test_layout_pthread_attr_t() {
4744    const UNINIT: ::std::mem::MaybeUninit<pthread_attr_t> = ::std::mem::MaybeUninit::uninit();
4745    let ptr = UNINIT.as_ptr();
4746    assert_eq!(
4747        ::std::mem::size_of::<pthread_attr_t>(),
4748        56usize,
4749        concat!("Size of: ", stringify!(pthread_attr_t)),
4750    );
4751    assert_eq!(
4752        ::std::mem::align_of::<pthread_attr_t>(),
4753        8usize,
4754        concat!("Alignment of ", stringify!(pthread_attr_t)),
4755    );
4756    assert_eq!(
4757        unsafe { ::std::ptr::addr_of!((*ptr).__u) as usize - ptr as usize },
4758        0usize,
4759        concat!("Offset of field: ", stringify!(pthread_attr_t), "::", stringify!(__u)),
4760    );
4761}
4762#[repr(C)]
4763#[derive(Copy, Clone)]
4764pub struct pthread_mutex_t {
4765    pub __u: pthread_mutex_t__bindgen_ty_1,
4766}
4767#[repr(C)]
4768#[derive(Copy, Clone)]
4769pub union pthread_mutex_t__bindgen_ty_1 {
4770    pub __i: [::std::os::raw::c_int; 10usize],
4771    pub __vi: [::std::os::raw::c_int; 10usize],
4772    pub __p: [*mut ::std::os::raw::c_void; 5usize],
4773}
4774#[test]
4775fn bindgen_test_layout_pthread_mutex_t__bindgen_ty_1() {
4776    const UNINIT: ::std::mem::MaybeUninit<pthread_mutex_t__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit();
4777    let ptr = UNINIT.as_ptr();
4778    assert_eq!(
4779        ::std::mem::size_of::<pthread_mutex_t__bindgen_ty_1>(),
4780        40usize,
4781        concat!("Size of: ", stringify!(pthread_mutex_t__bindgen_ty_1)),
4782    );
4783    assert_eq!(
4784        ::std::mem::align_of::<pthread_mutex_t__bindgen_ty_1>(),
4785        8usize,
4786        concat!("Alignment of ", stringify!(pthread_mutex_t__bindgen_ty_1)),
4787    );
4788    assert_eq!(
4789        unsafe { ::std::ptr::addr_of!((*ptr).__i) as usize - ptr as usize },
4790        0usize,
4791        concat!(
4792            "Offset of field: ",
4793            stringify!(pthread_mutex_t__bindgen_ty_1),
4794            "::",
4795            stringify!(__i),
4796        ),
4797    );
4798    assert_eq!(
4799        unsafe { ::std::ptr::addr_of!((*ptr).__vi) as usize - ptr as usize },
4800        0usize,
4801        concat!(
4802            "Offset of field: ",
4803            stringify!(pthread_mutex_t__bindgen_ty_1),
4804            "::",
4805            stringify!(__vi),
4806        ),
4807    );
4808    assert_eq!(
4809        unsafe { ::std::ptr::addr_of!((*ptr).__p) as usize - ptr as usize },
4810        0usize,
4811        concat!(
4812            "Offset of field: ",
4813            stringify!(pthread_mutex_t__bindgen_ty_1),
4814            "::",
4815            stringify!(__p),
4816        ),
4817    );
4818}
4819#[test]
4820fn bindgen_test_layout_pthread_mutex_t() {
4821    const UNINIT: ::std::mem::MaybeUninit<pthread_mutex_t> = ::std::mem::MaybeUninit::uninit();
4822    let ptr = UNINIT.as_ptr();
4823    assert_eq!(
4824        ::std::mem::size_of::<pthread_mutex_t>(),
4825        40usize,
4826        concat!("Size of: ", stringify!(pthread_mutex_t)),
4827    );
4828    assert_eq!(
4829        ::std::mem::align_of::<pthread_mutex_t>(),
4830        8usize,
4831        concat!("Alignment of ", stringify!(pthread_mutex_t)),
4832    );
4833    assert_eq!(
4834        unsafe { ::std::ptr::addr_of!((*ptr).__u) as usize - ptr as usize },
4835        0usize,
4836        concat!("Offset of field: ", stringify!(pthread_mutex_t), "::", stringify!(__u)),
4837    );
4838}
4839#[repr(C)]
4840#[derive(Copy, Clone)]
4841pub struct pthread_cond_t {
4842    pub __u: pthread_cond_t__bindgen_ty_1,
4843}
4844#[repr(C)]
4845#[derive(Copy, Clone)]
4846pub union pthread_cond_t__bindgen_ty_1 {
4847    pub __i: [::std::os::raw::c_int; 12usize],
4848    pub __vi: [::std::os::raw::c_int; 12usize],
4849    pub __p: [*mut ::std::os::raw::c_void; 6usize],
4850}
4851#[test]
4852fn bindgen_test_layout_pthread_cond_t__bindgen_ty_1() {
4853    const UNINIT: ::std::mem::MaybeUninit<pthread_cond_t__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit();
4854    let ptr = UNINIT.as_ptr();
4855    assert_eq!(
4856        ::std::mem::size_of::<pthread_cond_t__bindgen_ty_1>(),
4857        48usize,
4858        concat!("Size of: ", stringify!(pthread_cond_t__bindgen_ty_1)),
4859    );
4860    assert_eq!(
4861        ::std::mem::align_of::<pthread_cond_t__bindgen_ty_1>(),
4862        8usize,
4863        concat!("Alignment of ", stringify!(pthread_cond_t__bindgen_ty_1)),
4864    );
4865    assert_eq!(
4866        unsafe { ::std::ptr::addr_of!((*ptr).__i) as usize - ptr as usize },
4867        0usize,
4868        concat!(
4869            "Offset of field: ",
4870            stringify!(pthread_cond_t__bindgen_ty_1),
4871            "::",
4872            stringify!(__i),
4873        ),
4874    );
4875    assert_eq!(
4876        unsafe { ::std::ptr::addr_of!((*ptr).__vi) as usize - ptr as usize },
4877        0usize,
4878        concat!(
4879            "Offset of field: ",
4880            stringify!(pthread_cond_t__bindgen_ty_1),
4881            "::",
4882            stringify!(__vi),
4883        ),
4884    );
4885    assert_eq!(
4886        unsafe { ::std::ptr::addr_of!((*ptr).__p) as usize - ptr as usize },
4887        0usize,
4888        concat!(
4889            "Offset of field: ",
4890            stringify!(pthread_cond_t__bindgen_ty_1),
4891            "::",
4892            stringify!(__p),
4893        ),
4894    );
4895}
4896#[test]
4897fn bindgen_test_layout_pthread_cond_t() {
4898    const UNINIT: ::std::mem::MaybeUninit<pthread_cond_t> = ::std::mem::MaybeUninit::uninit();
4899    let ptr = UNINIT.as_ptr();
4900    assert_eq!(
4901        ::std::mem::size_of::<pthread_cond_t>(),
4902        48usize,
4903        concat!("Size of: ", stringify!(pthread_cond_t)),
4904    );
4905    assert_eq!(
4906        ::std::mem::align_of::<pthread_cond_t>(),
4907        8usize,
4908        concat!("Alignment of ", stringify!(pthread_cond_t)),
4909    );
4910    assert_eq!(
4911        unsafe { ::std::ptr::addr_of!((*ptr).__u) as usize - ptr as usize },
4912        0usize,
4913        concat!("Offset of field: ", stringify!(pthread_cond_t), "::", stringify!(__u)),
4914    );
4915}
4916#[repr(C)]
4917#[derive(Copy, Clone)]
4918pub struct pthread_rwlock_t {
4919    pub __u: pthread_rwlock_t__bindgen_ty_1,
4920}
4921#[repr(C)]
4922#[derive(Copy, Clone)]
4923pub union pthread_rwlock_t__bindgen_ty_1 {
4924    pub __i: [::std::os::raw::c_int; 14usize],
4925    pub __vi: [::std::os::raw::c_int; 14usize],
4926    pub __p: [*mut ::std::os::raw::c_void; 7usize],
4927}
4928#[test]
4929fn bindgen_test_layout_pthread_rwlock_t__bindgen_ty_1() {
4930    const UNINIT: ::std::mem::MaybeUninit<pthread_rwlock_t__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit();
4931    let ptr = UNINIT.as_ptr();
4932    assert_eq!(
4933        ::std::mem::size_of::<pthread_rwlock_t__bindgen_ty_1>(),
4934        56usize,
4935        concat!("Size of: ", stringify!(pthread_rwlock_t__bindgen_ty_1)),
4936    );
4937    assert_eq!(
4938        ::std::mem::align_of::<pthread_rwlock_t__bindgen_ty_1>(),
4939        8usize,
4940        concat!("Alignment of ", stringify!(pthread_rwlock_t__bindgen_ty_1)),
4941    );
4942    assert_eq!(
4943        unsafe { ::std::ptr::addr_of!((*ptr).__i) as usize - ptr as usize },
4944        0usize,
4945        concat!(
4946            "Offset of field: ",
4947            stringify!(pthread_rwlock_t__bindgen_ty_1),
4948            "::",
4949            stringify!(__i),
4950        ),
4951    );
4952    assert_eq!(
4953        unsafe { ::std::ptr::addr_of!((*ptr).__vi) as usize - ptr as usize },
4954        0usize,
4955        concat!(
4956            "Offset of field: ",
4957            stringify!(pthread_rwlock_t__bindgen_ty_1),
4958            "::",
4959            stringify!(__vi),
4960        ),
4961    );
4962    assert_eq!(
4963        unsafe { ::std::ptr::addr_of!((*ptr).__p) as usize - ptr as usize },
4964        0usize,
4965        concat!(
4966            "Offset of field: ",
4967            stringify!(pthread_rwlock_t__bindgen_ty_1),
4968            "::",
4969            stringify!(__p),
4970        ),
4971    );
4972}
4973#[test]
4974fn bindgen_test_layout_pthread_rwlock_t() {
4975    const UNINIT: ::std::mem::MaybeUninit<pthread_rwlock_t> = ::std::mem::MaybeUninit::uninit();
4976    let ptr = UNINIT.as_ptr();
4977    assert_eq!(
4978        ::std::mem::size_of::<pthread_rwlock_t>(),
4979        56usize,
4980        concat!("Size of: ", stringify!(pthread_rwlock_t)),
4981    );
4982    assert_eq!(
4983        ::std::mem::align_of::<pthread_rwlock_t>(),
4984        8usize,
4985        concat!("Alignment of ", stringify!(pthread_rwlock_t)),
4986    );
4987    assert_eq!(
4988        unsafe { ::std::ptr::addr_of!((*ptr).__u) as usize - ptr as usize },
4989        0usize,
4990        concat!("Offset of field: ", stringify!(pthread_rwlock_t), "::", stringify!(__u)),
4991    );
4992}
4993#[repr(C)]
4994#[derive(Copy, Clone)]
4995pub struct pthread_barrier_t {
4996    pub __u: pthread_barrier_t__bindgen_ty_1,
4997}
4998#[repr(C)]
4999#[derive(Copy, Clone)]
5000pub union pthread_barrier_t__bindgen_ty_1 {
5001    pub __i: [::std::os::raw::c_int; 8usize],
5002    pub __vi: [::std::os::raw::c_int; 8usize],
5003    pub __p: [*mut ::std::os::raw::c_void; 4usize],
5004}
5005#[test]
5006fn bindgen_test_layout_pthread_barrier_t__bindgen_ty_1() {
5007    const UNINIT: ::std::mem::MaybeUninit<pthread_barrier_t__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit();
5008    let ptr = UNINIT.as_ptr();
5009    assert_eq!(
5010        ::std::mem::size_of::<pthread_barrier_t__bindgen_ty_1>(),
5011        32usize,
5012        concat!("Size of: ", stringify!(pthread_barrier_t__bindgen_ty_1)),
5013    );
5014    assert_eq!(
5015        ::std::mem::align_of::<pthread_barrier_t__bindgen_ty_1>(),
5016        8usize,
5017        concat!("Alignment of ", stringify!(pthread_barrier_t__bindgen_ty_1)),
5018    );
5019    assert_eq!(
5020        unsafe { ::std::ptr::addr_of!((*ptr).__i) as usize - ptr as usize },
5021        0usize,
5022        concat!(
5023            "Offset of field: ",
5024            stringify!(pthread_barrier_t__bindgen_ty_1),
5025            "::",
5026            stringify!(__i),
5027        ),
5028    );
5029    assert_eq!(
5030        unsafe { ::std::ptr::addr_of!((*ptr).__vi) as usize - ptr as usize },
5031        0usize,
5032        concat!(
5033            "Offset of field: ",
5034            stringify!(pthread_barrier_t__bindgen_ty_1),
5035            "::",
5036            stringify!(__vi),
5037        ),
5038    );
5039    assert_eq!(
5040        unsafe { ::std::ptr::addr_of!((*ptr).__p) as usize - ptr as usize },
5041        0usize,
5042        concat!(
5043            "Offset of field: ",
5044            stringify!(pthread_barrier_t__bindgen_ty_1),
5045            "::",
5046            stringify!(__p),
5047        ),
5048    );
5049}
5050#[test]
5051fn bindgen_test_layout_pthread_barrier_t() {
5052    const UNINIT: ::std::mem::MaybeUninit<pthread_barrier_t> = ::std::mem::MaybeUninit::uninit();
5053    let ptr = UNINIT.as_ptr();
5054    assert_eq!(
5055        ::std::mem::size_of::<pthread_barrier_t>(),
5056        32usize,
5057        concat!("Size of: ", stringify!(pthread_barrier_t)),
5058    );
5059    assert_eq!(
5060        ::std::mem::align_of::<pthread_barrier_t>(),
5061        8usize,
5062        concat!("Alignment of ", stringify!(pthread_barrier_t)),
5063    );
5064    assert_eq!(
5065        unsafe { ::std::ptr::addr_of!((*ptr).__u) as usize - ptr as usize },
5066        0usize,
5067        concat!(
5068            "Offset of field: ",
5069            stringify!(pthread_barrier_t),
5070            "::",
5071            stringify!(__u),
5072        ),
5073    );
5074}
5075pub type u_int8_t = ::std::os::raw::c_uchar;
5076pub type u_int16_t = ::std::os::raw::c_ushort;
5077pub type u_int32_t = ::std::os::raw::c_uint;
5078pub type caddr_t = *mut ::std::os::raw::c_char;
5079pub type u_char = ::std::os::raw::c_uchar;
5080pub type u_short = ::std::os::raw::c_ushort;
5081pub type ushort = ::std::os::raw::c_ushort;
5082pub type u_int = ::std::os::raw::c_uint;
5083pub type uint = ::std::os::raw::c_uint;
5084pub type u_long = ::std::os::raw::c_ulong;
5085pub type ulong = ::std::os::raw::c_ulong;
5086pub type quad_t = ::std::os::raw::c_longlong;
5087pub type u_quad_t = ::std::os::raw::c_ulonglong;
5088#[repr(C)]
5089#[derive(Debug, Copy, Clone)]
5090pub struct timeval {
5091    pub tv_sec: time_t,
5092    pub tv_usec: suseconds_t,
5093}
5094#[test]
5095fn bindgen_test_layout_timeval() {
5096    const UNINIT: ::std::mem::MaybeUninit<timeval> = ::std::mem::MaybeUninit::uninit();
5097    let ptr = UNINIT.as_ptr();
5098    assert_eq!(
5099        ::std::mem::size_of::<timeval>(),
5100        16usize,
5101        concat!("Size of: ", stringify!(timeval)),
5102    );
5103    assert_eq!(
5104        ::std::mem::align_of::<timeval>(),
5105        8usize,
5106        concat!("Alignment of ", stringify!(timeval)),
5107    );
5108    assert_eq!(
5109        unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize },
5110        0usize,
5111        concat!("Offset of field: ", stringify!(timeval), "::", stringify!(tv_sec)),
5112    );
5113    assert_eq!(
5114        unsafe { ::std::ptr::addr_of!((*ptr).tv_usec) as usize - ptr as usize },
5115        8usize,
5116        concat!("Offset of field: ", stringify!(timeval), "::", stringify!(tv_usec)),
5117    );
5118}
5119#[repr(C)]
5120#[derive(Debug, Copy, Clone)]
5121pub struct timespec {
5122    pub tv_sec: time_t,
5123    pub tv_nsec: ::std::os::raw::c_long,
5124}
5125#[test]
5126fn bindgen_test_layout_timespec() {
5127    const UNINIT: ::std::mem::MaybeUninit<timespec> = ::std::mem::MaybeUninit::uninit();
5128    let ptr = UNINIT.as_ptr();
5129    assert_eq!(
5130        ::std::mem::size_of::<timespec>(),
5131        16usize,
5132        concat!("Size of: ", stringify!(timespec)),
5133    );
5134    assert_eq!(
5135        ::std::mem::align_of::<timespec>(),
5136        8usize,
5137        concat!("Alignment of ", stringify!(timespec)),
5138    );
5139    assert_eq!(
5140        unsafe { ::std::ptr::addr_of!((*ptr).tv_sec) as usize - ptr as usize },
5141        0usize,
5142        concat!("Offset of field: ", stringify!(timespec), "::", stringify!(tv_sec)),
5143    );
5144    assert_eq!(
5145        unsafe { ::std::ptr::addr_of!((*ptr).tv_nsec) as usize - ptr as usize },
5146        8usize,
5147        concat!("Offset of field: ", stringify!(timespec), "::", stringify!(tv_nsec)),
5148    );
5149}
5150#[repr(C)]
5151#[derive(Debug, Copy, Clone)]
5152pub struct __sigset_t {
5153    pub __bits: [::std::os::raw::c_ulong; 16usize],
5154}
5155#[test]
5156fn bindgen_test_layout___sigset_t() {
5157    const UNINIT: ::std::mem::MaybeUninit<__sigset_t> = ::std::mem::MaybeUninit::uninit();
5158    let ptr = UNINIT.as_ptr();
5159    assert_eq!(
5160        ::std::mem::size_of::<__sigset_t>(),
5161        128usize,
5162        concat!("Size of: ", stringify!(__sigset_t)),
5163    );
5164    assert_eq!(
5165        ::std::mem::align_of::<__sigset_t>(),
5166        8usize,
5167        concat!("Alignment of ", stringify!(__sigset_t)),
5168    );
5169    assert_eq!(
5170        unsafe { ::std::ptr::addr_of!((*ptr).__bits) as usize - ptr as usize },
5171        0usize,
5172        concat!("Offset of field: ", stringify!(__sigset_t), "::", stringify!(__bits)),
5173    );
5174}
5175pub type sigset_t = __sigset_t;
5176pub type fd_mask = ::std::os::raw::c_ulong;
5177#[repr(C)]
5178#[derive(Debug, Copy, Clone)]
5179pub struct fd_set {
5180    pub fds_bits: [::std::os::raw::c_ulong; 16usize],
5181}
5182#[test]
5183fn bindgen_test_layout_fd_set() {
5184    const UNINIT: ::std::mem::MaybeUninit<fd_set> = ::std::mem::MaybeUninit::uninit();
5185    let ptr = UNINIT.as_ptr();
5186    assert_eq!(
5187        ::std::mem::size_of::<fd_set>(),
5188        128usize,
5189        concat!("Size of: ", stringify!(fd_set)),
5190    );
5191    assert_eq!(
5192        ::std::mem::align_of::<fd_set>(),
5193        8usize,
5194        concat!("Alignment of ", stringify!(fd_set)),
5195    );
5196    assert_eq!(
5197        unsafe { ::std::ptr::addr_of!((*ptr).fds_bits) as usize - ptr as usize },
5198        0usize,
5199        concat!("Offset of field: ", stringify!(fd_set), "::", stringify!(fds_bits)),
5200    );
5201}
5202extern "C" {
5203    pub fn select(
5204        arg1: ::std::os::raw::c_int,
5205        arg2: *mut fd_set,
5206        arg3: *mut fd_set,
5207        arg4: *mut fd_set,
5208        arg5: *mut timeval,
5209    ) -> ::std::os::raw::c_int;
5210}
5211extern "C" {
5212    pub fn pselect(
5213        arg1: ::std::os::raw::c_int,
5214        arg2: *mut fd_set,
5215        arg3: *mut fd_set,
5216        arg4: *mut fd_set,
5217        arg5: *const timespec,
5218        arg6: *const sigset_t,
5219    ) -> ::std::os::raw::c_int;
5220}
5221pub type sasl_malloc_t = ::std::option::Option<
5222    unsafe extern "C" fn(arg1: usize) -> *mut ::std::os::raw::c_void,
5223>;
5224pub type sasl_calloc_t = ::std::option::Option<
5225    unsafe extern "C" fn(arg1: usize, arg2: usize) -> *mut ::std::os::raw::c_void,
5226>;
5227pub type sasl_realloc_t = ::std::option::Option<
5228    unsafe extern "C" fn(
5229        arg1: *mut ::std::os::raw::c_void,
5230        arg2: usize,
5231    ) -> *mut ::std::os::raw::c_void,
5232>;
5233pub type sasl_free_t = ::std::option::Option<
5234    unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void),
5235>;
5236extern "C" {
5237    pub fn sasl_set_alloc(
5238        arg1: sasl_malloc_t,
5239        arg2: sasl_calloc_t,
5240        arg3: sasl_realloc_t,
5241        arg4: sasl_free_t,
5242    );
5243}
5244pub type sasl_mutex_alloc_t = ::std::option::Option<
5245    unsafe extern "C" fn() -> *mut ::std::os::raw::c_void,
5246>;
5247pub type sasl_mutex_lock_t = ::std::option::Option<
5248    unsafe extern "C" fn(mutex: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int,
5249>;
5250pub type sasl_mutex_unlock_t = ::std::option::Option<
5251    unsafe extern "C" fn(mutex: *mut ::std::os::raw::c_void) -> ::std::os::raw::c_int,
5252>;
5253pub type sasl_mutex_free_t = ::std::option::Option<
5254    unsafe extern "C" fn(mutex: *mut ::std::os::raw::c_void),
5255>;
5256extern "C" {
5257    pub fn sasl_set_mutex(
5258        arg1: sasl_mutex_alloc_t,
5259        arg2: sasl_mutex_lock_t,
5260        arg3: sasl_mutex_unlock_t,
5261        arg4: sasl_mutex_free_t,
5262    );
5263}
5264pub type sasl_ssf_t = ::std::os::raw::c_uint;
5265#[repr(C)]
5266#[derive(Debug, Copy, Clone)]
5267pub struct sasl_security_properties {
5268    pub min_ssf: sasl_ssf_t,
5269    pub max_ssf: sasl_ssf_t,
5270    pub maxbufsize: ::std::os::raw::c_uint,
5271    pub security_flags: ::std::os::raw::c_uint,
5272    pub property_names: *mut *const ::std::os::raw::c_char,
5273    pub property_values: *mut *const ::std::os::raw::c_char,
5274}
5275#[test]
5276fn bindgen_test_layout_sasl_security_properties() {
5277    const UNINIT: ::std::mem::MaybeUninit<sasl_security_properties> = ::std::mem::MaybeUninit::uninit();
5278    let ptr = UNINIT.as_ptr();
5279    assert_eq!(
5280        ::std::mem::size_of::<sasl_security_properties>(),
5281        32usize,
5282        concat!("Size of: ", stringify!(sasl_security_properties)),
5283    );
5284    assert_eq!(
5285        ::std::mem::align_of::<sasl_security_properties>(),
5286        8usize,
5287        concat!("Alignment of ", stringify!(sasl_security_properties)),
5288    );
5289    assert_eq!(
5290        unsafe { ::std::ptr::addr_of!((*ptr).min_ssf) as usize - ptr as usize },
5291        0usize,
5292        concat!(
5293            "Offset of field: ",
5294            stringify!(sasl_security_properties),
5295            "::",
5296            stringify!(min_ssf),
5297        ),
5298    );
5299    assert_eq!(
5300        unsafe { ::std::ptr::addr_of!((*ptr).max_ssf) as usize - ptr as usize },
5301        4usize,
5302        concat!(
5303            "Offset of field: ",
5304            stringify!(sasl_security_properties),
5305            "::",
5306            stringify!(max_ssf),
5307        ),
5308    );
5309    assert_eq!(
5310        unsafe { ::std::ptr::addr_of!((*ptr).maxbufsize) as usize - ptr as usize },
5311        8usize,
5312        concat!(
5313            "Offset of field: ",
5314            stringify!(sasl_security_properties),
5315            "::",
5316            stringify!(maxbufsize),
5317        ),
5318    );
5319    assert_eq!(
5320        unsafe { ::std::ptr::addr_of!((*ptr).security_flags) as usize - ptr as usize },
5321        12usize,
5322        concat!(
5323            "Offset of field: ",
5324            stringify!(sasl_security_properties),
5325            "::",
5326            stringify!(security_flags),
5327        ),
5328    );
5329    assert_eq!(
5330        unsafe { ::std::ptr::addr_of!((*ptr).property_names) as usize - ptr as usize },
5331        16usize,
5332        concat!(
5333            "Offset of field: ",
5334            stringify!(sasl_security_properties),
5335            "::",
5336            stringify!(property_names),
5337        ),
5338    );
5339    assert_eq!(
5340        unsafe { ::std::ptr::addr_of!((*ptr).property_values) as usize - ptr as usize },
5341        24usize,
5342        concat!(
5343            "Offset of field: ",
5344            stringify!(sasl_security_properties),
5345            "::",
5346            stringify!(property_values),
5347        ),
5348    );
5349}
5350pub type sasl_security_properties_t = sasl_security_properties;
5351#[repr(C)]
5352#[derive(Debug, Copy, Clone)]
5353pub struct sasl_callback {
5354    pub id: ::std::os::raw::c_ulong,
5355    pub proc_: ::std::option::Option<unsafe extern "C" fn() -> ::std::os::raw::c_int>,
5356    pub context: *mut ::std::os::raw::c_void,
5357}
5358#[test]
5359fn bindgen_test_layout_sasl_callback() {
5360    const UNINIT: ::std::mem::MaybeUninit<sasl_callback> = ::std::mem::MaybeUninit::uninit();
5361    let ptr = UNINIT.as_ptr();
5362    assert_eq!(
5363        ::std::mem::size_of::<sasl_callback>(),
5364        24usize,
5365        concat!("Size of: ", stringify!(sasl_callback)),
5366    );
5367    assert_eq!(
5368        ::std::mem::align_of::<sasl_callback>(),
5369        8usize,
5370        concat!("Alignment of ", stringify!(sasl_callback)),
5371    );
5372    assert_eq!(
5373        unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize },
5374        0usize,
5375        concat!("Offset of field: ", stringify!(sasl_callback), "::", stringify!(id)),
5376    );
5377    assert_eq!(
5378        unsafe { ::std::ptr::addr_of!((*ptr).proc_) as usize - ptr as usize },
5379        8usize,
5380        concat!("Offset of field: ", stringify!(sasl_callback), "::", stringify!(proc_)),
5381    );
5382    assert_eq!(
5383        unsafe { ::std::ptr::addr_of!((*ptr).context) as usize - ptr as usize },
5384        16usize,
5385        concat!(
5386            "Offset of field: ",
5387            stringify!(sasl_callback),
5388            "::",
5389            stringify!(context),
5390        ),
5391    );
5392}
5393pub type sasl_callback_t = sasl_callback;
5394pub type sasl_getopt_t = ::std::option::Option<
5395    unsafe extern "C" fn(
5396        context: *mut ::std::os::raw::c_void,
5397        plugin_name: *const ::std::os::raw::c_char,
5398        option: *const ::std::os::raw::c_char,
5399        result: *mut *const ::std::os::raw::c_char,
5400        len: *mut ::std::os::raw::c_uint,
5401    ) -> ::std::os::raw::c_int,
5402>;
5403pub type sasl_log_t = ::std::option::Option<
5404    unsafe extern "C" fn(
5405        context: *mut ::std::os::raw::c_void,
5406        level: ::std::os::raw::c_int,
5407        message: *const ::std::os::raw::c_char,
5408    ) -> ::std::os::raw::c_int,
5409>;
5410pub type sasl_getpath_t = ::std::option::Option<
5411    unsafe extern "C" fn(
5412        context: *mut ::std::os::raw::c_void,
5413        path: *mut *const ::std::os::raw::c_char,
5414    ) -> ::std::os::raw::c_int,
5415>;
5416pub const sasl_verify_type_t_SASL_VRFY_PLUGIN: sasl_verify_type_t = 0;
5417pub const sasl_verify_type_t_SASL_VRFY_CONF: sasl_verify_type_t = 1;
5418pub const sasl_verify_type_t_SASL_VRFY_PASSWD: sasl_verify_type_t = 2;
5419pub const sasl_verify_type_t_SASL_VRFY_OTHER: sasl_verify_type_t = 3;
5420pub type sasl_verify_type_t = ::std::os::raw::c_uint;
5421pub type sasl_verifyfile_t = ::std::option::Option<
5422    unsafe extern "C" fn(
5423        context: *mut ::std::os::raw::c_void,
5424        file: *const ::std::os::raw::c_char,
5425        type_: sasl_verify_type_t,
5426    ) -> ::std::os::raw::c_int,
5427>;
5428pub type sasl_getconfpath_t = ::std::option::Option<
5429    unsafe extern "C" fn(
5430        context: *mut ::std::os::raw::c_void,
5431        path: *mut *mut ::std::os::raw::c_char,
5432    ) -> ::std::os::raw::c_int,
5433>;
5434pub type sasl_getsimple_t = ::std::option::Option<
5435    unsafe extern "C" fn(
5436        context: *mut ::std::os::raw::c_void,
5437        id: ::std::os::raw::c_int,
5438        result: *mut *const ::std::os::raw::c_char,
5439        len: *mut ::std::os::raw::c_uint,
5440    ) -> ::std::os::raw::c_int,
5441>;
5442pub type sasl_getsecret_t = ::std::option::Option<
5443    unsafe extern "C" fn(
5444        conn: *mut sasl_conn_t,
5445        context: *mut ::std::os::raw::c_void,
5446        id: ::std::os::raw::c_int,
5447        psecret: *mut *mut sasl_secret_t,
5448    ) -> ::std::os::raw::c_int,
5449>;
5450pub type sasl_chalprompt_t = ::std::option::Option<
5451    unsafe extern "C" fn(
5452        context: *mut ::std::os::raw::c_void,
5453        id: ::std::os::raw::c_int,
5454        challenge: *const ::std::os::raw::c_char,
5455        prompt: *const ::std::os::raw::c_char,
5456        defresult: *const ::std::os::raw::c_char,
5457        result: *mut *const ::std::os::raw::c_char,
5458        len: *mut ::std::os::raw::c_uint,
5459    ) -> ::std::os::raw::c_int,
5460>;
5461pub type sasl_getrealm_t = ::std::option::Option<
5462    unsafe extern "C" fn(
5463        context: *mut ::std::os::raw::c_void,
5464        id: ::std::os::raw::c_int,
5465        availrealms: *mut *const ::std::os::raw::c_char,
5466        result: *mut *const ::std::os::raw::c_char,
5467    ) -> ::std::os::raw::c_int,
5468>;
5469pub type sasl_authorize_t = ::std::option::Option<
5470    unsafe extern "C" fn(
5471        conn: *mut sasl_conn_t,
5472        context: *mut ::std::os::raw::c_void,
5473        requested_user: *const ::std::os::raw::c_char,
5474        rlen: ::std::os::raw::c_uint,
5475        auth_identity: *const ::std::os::raw::c_char,
5476        alen: ::std::os::raw::c_uint,
5477        def_realm: *const ::std::os::raw::c_char,
5478        urlen: ::std::os::raw::c_uint,
5479        propctx: *mut propctx,
5480    ) -> ::std::os::raw::c_int,
5481>;
5482pub type sasl_server_userdb_checkpass_t = ::std::option::Option<
5483    unsafe extern "C" fn(
5484        conn: *mut sasl_conn_t,
5485        context: *mut ::std::os::raw::c_void,
5486        user: *const ::std::os::raw::c_char,
5487        pass: *const ::std::os::raw::c_char,
5488        passlen: ::std::os::raw::c_uint,
5489        propctx: *mut propctx,
5490    ) -> ::std::os::raw::c_int,
5491>;
5492pub type sasl_server_userdb_setpass_t = ::std::option::Option<
5493    unsafe extern "C" fn(
5494        conn: *mut sasl_conn_t,
5495        context: *mut ::std::os::raw::c_void,
5496        user: *const ::std::os::raw::c_char,
5497        pass: *const ::std::os::raw::c_char,
5498        passlen: ::std::os::raw::c_uint,
5499        propctx: *mut propctx,
5500        flags: ::std::os::raw::c_uint,
5501    ) -> ::std::os::raw::c_int,
5502>;
5503pub type sasl_canon_user_t = ::std::option::Option<
5504    unsafe extern "C" fn(
5505        conn: *mut sasl_conn_t,
5506        context: *mut ::std::os::raw::c_void,
5507        in_: *const ::std::os::raw::c_char,
5508        inlen: ::std::os::raw::c_uint,
5509        flags: ::std::os::raw::c_uint,
5510        user_realm: *const ::std::os::raw::c_char,
5511        out: *mut ::std::os::raw::c_char,
5512        out_max: ::std::os::raw::c_uint,
5513        out_len: *mut ::std::os::raw::c_uint,
5514    ) -> ::std::os::raw::c_int,
5515>;
5516extern "C" {
5517    pub fn sasl_set_path(
5518        path_type: ::std::os::raw::c_int,
5519        path: *mut ::std::os::raw::c_char,
5520    ) -> ::std::os::raw::c_int;
5521}
5522extern "C" {
5523    pub fn sasl_version(
5524        implementation: *mut *const ::std::os::raw::c_char,
5525        version: *mut ::std::os::raw::c_int,
5526    );
5527}
5528extern "C" {
5529    pub fn sasl_version_info(
5530        implementation: *mut *const ::std::os::raw::c_char,
5531        version_string: *mut *const ::std::os::raw::c_char,
5532        version_major: *mut ::std::os::raw::c_int,
5533        version_minor: *mut ::std::os::raw::c_int,
5534        version_step: *mut ::std::os::raw::c_int,
5535        version_patch: *mut ::std::os::raw::c_int,
5536    );
5537}
5538extern "C" {
5539    pub fn sasl_done();
5540}
5541extern "C" {
5542    pub fn sasl_server_done() -> ::std::os::raw::c_int;
5543}
5544extern "C" {
5545    pub fn sasl_client_done() -> ::std::os::raw::c_int;
5546}
5547extern "C" {
5548    pub fn sasl_dispose(pconn: *mut *mut sasl_conn_t);
5549}
5550extern "C" {
5551    pub fn sasl_errstring(
5552        saslerr: ::std::os::raw::c_int,
5553        langlist: *const ::std::os::raw::c_char,
5554        outlang: *mut *const ::std::os::raw::c_char,
5555    ) -> *const ::std::os::raw::c_char;
5556}
5557extern "C" {
5558    pub fn sasl_errdetail(conn: *mut sasl_conn_t) -> *const ::std::os::raw::c_char;
5559}
5560extern "C" {
5561    pub fn sasl_seterror(
5562        conn: *mut sasl_conn_t,
5563        flags: ::std::os::raw::c_uint,
5564        fmt: *const ::std::os::raw::c_char,
5565        ...
5566    );
5567}
5568extern "C" {
5569    pub fn sasl_getprop(
5570        conn: *mut sasl_conn_t,
5571        propnum: ::std::os::raw::c_int,
5572        pvalue: *mut *const ::std::os::raw::c_void,
5573    ) -> ::std::os::raw::c_int;
5574}
5575#[repr(C)]
5576#[derive(Debug, Copy, Clone)]
5577pub struct sasl_channel_binding {
5578    pub name: *const ::std::os::raw::c_char,
5579    pub critical: ::std::os::raw::c_int,
5580    pub len: ::std::os::raw::c_ulong,
5581    pub data: *const ::std::os::raw::c_uchar,
5582}
5583#[test]
5584fn bindgen_test_layout_sasl_channel_binding() {
5585    const UNINIT: ::std::mem::MaybeUninit<sasl_channel_binding> = ::std::mem::MaybeUninit::uninit();
5586    let ptr = UNINIT.as_ptr();
5587    assert_eq!(
5588        ::std::mem::size_of::<sasl_channel_binding>(),
5589        32usize,
5590        concat!("Size of: ", stringify!(sasl_channel_binding)),
5591    );
5592    assert_eq!(
5593        ::std::mem::align_of::<sasl_channel_binding>(),
5594        8usize,
5595        concat!("Alignment of ", stringify!(sasl_channel_binding)),
5596    );
5597    assert_eq!(
5598        unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize },
5599        0usize,
5600        concat!(
5601            "Offset of field: ",
5602            stringify!(sasl_channel_binding),
5603            "::",
5604            stringify!(name),
5605        ),
5606    );
5607    assert_eq!(
5608        unsafe { ::std::ptr::addr_of!((*ptr).critical) as usize - ptr as usize },
5609        8usize,
5610        concat!(
5611            "Offset of field: ",
5612            stringify!(sasl_channel_binding),
5613            "::",
5614            stringify!(critical),
5615        ),
5616    );
5617    assert_eq!(
5618        unsafe { ::std::ptr::addr_of!((*ptr).len) as usize - ptr as usize },
5619        16usize,
5620        concat!(
5621            "Offset of field: ",
5622            stringify!(sasl_channel_binding),
5623            "::",
5624            stringify!(len),
5625        ),
5626    );
5627    assert_eq!(
5628        unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize },
5629        24usize,
5630        concat!(
5631            "Offset of field: ",
5632            stringify!(sasl_channel_binding),
5633            "::",
5634            stringify!(data),
5635        ),
5636    );
5637}
5638pub type sasl_channel_binding_t = sasl_channel_binding;
5639#[repr(C)]
5640#[derive(Debug, Copy, Clone)]
5641pub struct sasl_http_request {
5642    pub method: *const ::std::os::raw::c_char,
5643    pub uri: *const ::std::os::raw::c_char,
5644    pub entity: *const ::std::os::raw::c_uchar,
5645    pub elen: ::std::os::raw::c_ulong,
5646    pub non_persist: ::std::os::raw::c_uint,
5647}
5648#[test]
5649fn bindgen_test_layout_sasl_http_request() {
5650    const UNINIT: ::std::mem::MaybeUninit<sasl_http_request> = ::std::mem::MaybeUninit::uninit();
5651    let ptr = UNINIT.as_ptr();
5652    assert_eq!(
5653        ::std::mem::size_of::<sasl_http_request>(),
5654        40usize,
5655        concat!("Size of: ", stringify!(sasl_http_request)),
5656    );
5657    assert_eq!(
5658        ::std::mem::align_of::<sasl_http_request>(),
5659        8usize,
5660        concat!("Alignment of ", stringify!(sasl_http_request)),
5661    );
5662    assert_eq!(
5663        unsafe { ::std::ptr::addr_of!((*ptr).method) as usize - ptr as usize },
5664        0usize,
5665        concat!(
5666            "Offset of field: ",
5667            stringify!(sasl_http_request),
5668            "::",
5669            stringify!(method),
5670        ),
5671    );
5672    assert_eq!(
5673        unsafe { ::std::ptr::addr_of!((*ptr).uri) as usize - ptr as usize },
5674        8usize,
5675        concat!(
5676            "Offset of field: ",
5677            stringify!(sasl_http_request),
5678            "::",
5679            stringify!(uri),
5680        ),
5681    );
5682    assert_eq!(
5683        unsafe { ::std::ptr::addr_of!((*ptr).entity) as usize - ptr as usize },
5684        16usize,
5685        concat!(
5686            "Offset of field: ",
5687            stringify!(sasl_http_request),
5688            "::",
5689            stringify!(entity),
5690        ),
5691    );
5692    assert_eq!(
5693        unsafe { ::std::ptr::addr_of!((*ptr).elen) as usize - ptr as usize },
5694        24usize,
5695        concat!(
5696            "Offset of field: ",
5697            stringify!(sasl_http_request),
5698            "::",
5699            stringify!(elen),
5700        ),
5701    );
5702    assert_eq!(
5703        unsafe { ::std::ptr::addr_of!((*ptr).non_persist) as usize - ptr as usize },
5704        32usize,
5705        concat!(
5706            "Offset of field: ",
5707            stringify!(sasl_http_request),
5708            "::",
5709            stringify!(non_persist),
5710        ),
5711    );
5712}
5713pub type sasl_http_request_t = sasl_http_request;
5714extern "C" {
5715    pub fn sasl_setprop(
5716        conn: *mut sasl_conn_t,
5717        propnum: ::std::os::raw::c_int,
5718        value: *const ::std::os::raw::c_void,
5719    ) -> ::std::os::raw::c_int;
5720}
5721extern "C" {
5722    pub fn sasl_idle(conn: *mut sasl_conn_t) -> ::std::os::raw::c_int;
5723}
5724#[repr(C)]
5725#[derive(Debug, Copy, Clone)]
5726pub struct sasl_interact {
5727    pub id: ::std::os::raw::c_ulong,
5728    pub challenge: *const ::std::os::raw::c_char,
5729    pub prompt: *const ::std::os::raw::c_char,
5730    pub defresult: *const ::std::os::raw::c_char,
5731    pub result: *const ::std::os::raw::c_void,
5732    pub len: ::std::os::raw::c_uint,
5733}
5734#[test]
5735fn bindgen_test_layout_sasl_interact() {
5736    const UNINIT: ::std::mem::MaybeUninit<sasl_interact> = ::std::mem::MaybeUninit::uninit();
5737    let ptr = UNINIT.as_ptr();
5738    assert_eq!(
5739        ::std::mem::size_of::<sasl_interact>(),
5740        48usize,
5741        concat!("Size of: ", stringify!(sasl_interact)),
5742    );
5743    assert_eq!(
5744        ::std::mem::align_of::<sasl_interact>(),
5745        8usize,
5746        concat!("Alignment of ", stringify!(sasl_interact)),
5747    );
5748    assert_eq!(
5749        unsafe { ::std::ptr::addr_of!((*ptr).id) as usize - ptr as usize },
5750        0usize,
5751        concat!("Offset of field: ", stringify!(sasl_interact), "::", stringify!(id)),
5752    );
5753    assert_eq!(
5754        unsafe { ::std::ptr::addr_of!((*ptr).challenge) as usize - ptr as usize },
5755        8usize,
5756        concat!(
5757            "Offset of field: ",
5758            stringify!(sasl_interact),
5759            "::",
5760            stringify!(challenge),
5761        ),
5762    );
5763    assert_eq!(
5764        unsafe { ::std::ptr::addr_of!((*ptr).prompt) as usize - ptr as usize },
5765        16usize,
5766        concat!("Offset of field: ", stringify!(sasl_interact), "::", stringify!(prompt)),
5767    );
5768    assert_eq!(
5769        unsafe { ::std::ptr::addr_of!((*ptr).defresult) as usize - ptr as usize },
5770        24usize,
5771        concat!(
5772            "Offset of field: ",
5773            stringify!(sasl_interact),
5774            "::",
5775            stringify!(defresult),
5776        ),
5777    );
5778    assert_eq!(
5779        unsafe { ::std::ptr::addr_of!((*ptr).result) as usize - ptr as usize },
5780        32usize,
5781        concat!("Offset of field: ", stringify!(sasl_interact), "::", stringify!(result)),
5782    );
5783    assert_eq!(
5784        unsafe { ::std::ptr::addr_of!((*ptr).len) as usize - ptr as usize },
5785        40usize,
5786        concat!("Offset of field: ", stringify!(sasl_interact), "::", stringify!(len)),
5787    );
5788}
5789pub type sasl_interact_t = sasl_interact;
5790extern "C" {
5791    pub fn sasl_client_init(callbacks: *const sasl_callback_t) -> ::std::os::raw::c_int;
5792}
5793extern "C" {
5794    pub fn sasl_client_new(
5795        service: *const ::std::os::raw::c_char,
5796        serverFQDN: *const ::std::os::raw::c_char,
5797        iplocalport: *const ::std::os::raw::c_char,
5798        ipremoteport: *const ::std::os::raw::c_char,
5799        prompt_supp: *const sasl_callback_t,
5800        flags: ::std::os::raw::c_uint,
5801        pconn: *mut *mut sasl_conn_t,
5802    ) -> ::std::os::raw::c_int;
5803}
5804extern "C" {
5805    pub fn sasl_client_start(
5806        conn: *mut sasl_conn_t,
5807        mechlist: *const ::std::os::raw::c_char,
5808        prompt_need: *mut *mut sasl_interact_t,
5809        clientout: *mut *const ::std::os::raw::c_char,
5810        clientoutlen: *mut ::std::os::raw::c_uint,
5811        mech: *mut *const ::std::os::raw::c_char,
5812    ) -> ::std::os::raw::c_int;
5813}
5814extern "C" {
5815    pub fn sasl_client_step(
5816        conn: *mut sasl_conn_t,
5817        serverin: *const ::std::os::raw::c_char,
5818        serverinlen: ::std::os::raw::c_uint,
5819        prompt_need: *mut *mut sasl_interact_t,
5820        clientout: *mut *const ::std::os::raw::c_char,
5821        clientoutlen: *mut ::std::os::raw::c_uint,
5822    ) -> ::std::os::raw::c_int;
5823}
5824extern "C" {
5825    pub fn sasl_server_init(
5826        callbacks: *const sasl_callback_t,
5827        appname: *const ::std::os::raw::c_char,
5828    ) -> ::std::os::raw::c_int;
5829}
5830extern "C" {
5831    pub fn sasl_server_new(
5832        service: *const ::std::os::raw::c_char,
5833        serverFQDN: *const ::std::os::raw::c_char,
5834        user_realm: *const ::std::os::raw::c_char,
5835        iplocalport: *const ::std::os::raw::c_char,
5836        ipremoteport: *const ::std::os::raw::c_char,
5837        callbacks: *const sasl_callback_t,
5838        flags: ::std::os::raw::c_uint,
5839        pconn: *mut *mut sasl_conn_t,
5840    ) -> ::std::os::raw::c_int;
5841}
5842extern "C" {
5843    pub fn sasl_global_listmech() -> *mut *const ::std::os::raw::c_char;
5844}
5845extern "C" {
5846    pub fn sasl_listmech(
5847        conn: *mut sasl_conn_t,
5848        user: *const ::std::os::raw::c_char,
5849        prefix: *const ::std::os::raw::c_char,
5850        sep: *const ::std::os::raw::c_char,
5851        suffix: *const ::std::os::raw::c_char,
5852        result: *mut *const ::std::os::raw::c_char,
5853        plen: *mut ::std::os::raw::c_uint,
5854        pcount: *mut ::std::os::raw::c_int,
5855    ) -> ::std::os::raw::c_int;
5856}
5857extern "C" {
5858    pub fn sasl_server_start(
5859        conn: *mut sasl_conn_t,
5860        mech: *const ::std::os::raw::c_char,
5861        clientin: *const ::std::os::raw::c_char,
5862        clientinlen: ::std::os::raw::c_uint,
5863        serverout: *mut *const ::std::os::raw::c_char,
5864        serveroutlen: *mut ::std::os::raw::c_uint,
5865    ) -> ::std::os::raw::c_int;
5866}
5867extern "C" {
5868    pub fn sasl_server_step(
5869        conn: *mut sasl_conn_t,
5870        clientin: *const ::std::os::raw::c_char,
5871        clientinlen: ::std::os::raw::c_uint,
5872        serverout: *mut *const ::std::os::raw::c_char,
5873        serveroutlen: *mut ::std::os::raw::c_uint,
5874    ) -> ::std::os::raw::c_int;
5875}
5876extern "C" {
5877    pub fn sasl_checkapop(
5878        conn: *mut sasl_conn_t,
5879        challenge: *const ::std::os::raw::c_char,
5880        challen: ::std::os::raw::c_uint,
5881        response: *const ::std::os::raw::c_char,
5882        resplen: ::std::os::raw::c_uint,
5883    ) -> ::std::os::raw::c_int;
5884}
5885extern "C" {
5886    pub fn sasl_checkpass(
5887        conn: *mut sasl_conn_t,
5888        user: *const ::std::os::raw::c_char,
5889        userlen: ::std::os::raw::c_uint,
5890        pass: *const ::std::os::raw::c_char,
5891        passlen: ::std::os::raw::c_uint,
5892    ) -> ::std::os::raw::c_int;
5893}
5894extern "C" {
5895    pub fn sasl_user_exists(
5896        conn: *mut sasl_conn_t,
5897        service: *const ::std::os::raw::c_char,
5898        user_realm: *const ::std::os::raw::c_char,
5899        user: *const ::std::os::raw::c_char,
5900    ) -> ::std::os::raw::c_int;
5901}
5902extern "C" {
5903    pub fn sasl_setpass(
5904        conn: *mut sasl_conn_t,
5905        user: *const ::std::os::raw::c_char,
5906        pass: *const ::std::os::raw::c_char,
5907        passlen: ::std::os::raw::c_uint,
5908        oldpass: *const ::std::os::raw::c_char,
5909        oldpasslen: ::std::os::raw::c_uint,
5910        flags: ::std::os::raw::c_uint,
5911    ) -> ::std::os::raw::c_int;
5912}
5913extern "C" {
5914    pub fn sasl_auxprop_request(
5915        conn: *mut sasl_conn_t,
5916        propnames: *mut *const ::std::os::raw::c_char,
5917    ) -> ::std::os::raw::c_int;
5918}
5919extern "C" {
5920    pub fn sasl_auxprop_getctx(conn: *mut sasl_conn_t) -> *mut propctx;
5921}
5922extern "C" {
5923    pub fn sasl_auxprop_store(
5924        conn: *mut sasl_conn_t,
5925        ctx: *mut propctx,
5926        user: *const ::std::os::raw::c_char,
5927    ) -> ::std::os::raw::c_int;
5928}
5929extern "C" {
5930    pub fn sasl_encode(
5931        conn: *mut sasl_conn_t,
5932        input: *const ::std::os::raw::c_char,
5933        inputlen: ::std::os::raw::c_uint,
5934        output: *mut *const ::std::os::raw::c_char,
5935        outputlen: *mut ::std::os::raw::c_uint,
5936    ) -> ::std::os::raw::c_int;
5937}
5938extern "C" {
5939    pub fn sasl_encodev(
5940        conn: *mut sasl_conn_t,
5941        invec: *const iovec,
5942        numiov: ::std::os::raw::c_uint,
5943        output: *mut *const ::std::os::raw::c_char,
5944        outputlen: *mut ::std::os::raw::c_uint,
5945    ) -> ::std::os::raw::c_int;
5946}
5947extern "C" {
5948    pub fn sasl_decode(
5949        conn: *mut sasl_conn_t,
5950        input: *const ::std::os::raw::c_char,
5951        inputlen: ::std::os::raw::c_uint,
5952        output: *mut *const ::std::os::raw::c_char,
5953        outputlen: *mut ::std::os::raw::c_uint,
5954    ) -> ::std::os::raw::c_int;
5955}