|
I'm trying to make updates to LDAP entries using the ldap_modify_s() API and I'm not having any success doing this. The LDAP code that Scott Klement posted recently (it can be seen at http://archive.midrange.com/rpg400-l/200206/msg00503.html) contained a definition for the LDAPmod data structure and a prototype for the ldap_modify_s() API. ldap_modify_s() is prototyped as: Dldap_modify_s PR 10I 0 extproc('ldap_modify_s') D ld * value D dn * value options(*STRING) D mods * value and the LDAPmod data structure is defined as: Dp_LDAPmod S * DLDAPmod DS based(p_LDAPmod) align D mod_op 10I 0 D mod_type * D modv_strvals * D mod_values * overlay(modv_strvals:1) D modv_bvals * overlay(modv_strvals:1) D mod_bvalues * overlay(modv_strvals:1) D mod_next * According to the documentation, the "mods" parameter is "a pointer to a null-terminated array of pointers to LDAPmod structures" and both mod_type and mod_values are pointers to null terminated arrays attributes and values to add, delete, or replace. I've never done anything like this in RPG before (we're on V4R5 still so I can't take advantage of the enhancements to dealing with data structures in V5R1 that I'm sure would make this easier) and I'm completely lost. Can anyone either send me some sample code that shows how to use this or something like it or (better yet) point me to some documentation that could help me figure this out on my own? Thanks, Matt
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.