Curl_ldap_version() for IBMi/OS400
- `LDAP_OPT_SUCCESS` (== 0) is missing from some LDAP implementations
and documented to use `LDAP_SUCCESS` (== 0) instead. Use literal zero
to avoid macro name differences.
- fix freeing `LDAP_OPT_API_INFO` buffers:
- docs suggest `ldapai_vendor_name` on IBMi is `const char *`.
Nothing in docs says it need to be freed.
- `ldapai_extensions` need to be freed, according to docs.
However, on IBMi there is `ldap_value_free()` function for it.
Ref: https://www.ibm.com/docs/en/svd/10.0.3?topic=settings-ldap-opt-api-info
Fixing, on OS400 (V7R4M0):
```
CZM1003: LDAP__819.c, 1028.56: CZM0045(30) Undeclared identifier LDAP_OPT_SUCCESS.
CZM1003: LDAP__819.c, 1036.21: CZM0280(30) Function argument assignment between types "char*" and "const char*" is not allowed.
CZM1001: LDAP__819.c, 1037.5: CZM0304(10) No function prototype given for "ber_memvfree".
...
CZS0601: Module LDAP is not created because statement errors occurred.
```
Follow-up to 859ce48de12986f5bf846c2800dacab893ff12c1 #19832
Fixes #20188
Closes #20189
curl is a command-line tool for transferring data from or to a server using URLs. It supports these protocols: DICT, FILE, FTP, FTPS, GOPHER, GOPHERS, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, MQTT, POP3, POP3S, RTMP, RTMPS, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET, TFTP, WS and WSS.
Learn how to use curl by reading the man page or everything curl.
Find out how to install curl by reading the INSTALL document.
libcurl is the library curl is using to do its job. It is readily available to be used by your software. Read the libcurl man page to learn how.
Open Source
curl is Open Source and is distributed under an MIT-like license.
Contact
Contact us on a suitable mailing list or use GitHub issues/ pull requests/ discussions.
All contributors to the project are listed in the THANKS document.
Commercial support
For commercial support, maybe private and dedicated help with your problems or applications using (lib)curl visit the support page.
Website
Visit the curl website for the latest news and downloads.
Source code
Download the latest source from the Git server:
git clone https://github.com/curl/curl
Security problems
Report suspected security problems via our HackerOne page and not in public.
Backers
Thank you to all our backers 🙏 Become a backer.
Sponsors
Support this project by becoming a sponsor.