[Date Prev][Date Next] [Chronological] [Thread] [Top]

(ITS#6580) slapi extended operation not executed



Full_Name: gianluigi nigro
Version: 2.4.21
OS: Linux CentOS release 5.5  ( i686)
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (89.186.39.1)


An extended operation with slapi plugin does not work, it is never executed
because slapd doesnt look for an extended operation registered in a plugin
(debugging slapd i verified that the list struct extop_list -extended.c,
function find_extop, line 208 - contains only built-in extended operation).


1) The initialization function look like this:
?
  char** oids = (char**) slapi_ch_malloc( 2 * sizeof( char * ) );
  oids[0] = 1.3.6.1.4.1.35746.2.11.1";
  oids[1] = NULL;
?
i_ret = slapi_pblock_set(pb, SLAPI_PLUGIN_EXT_OP_OIDLIST, oids );
  if( i_ret == 0 )
    i_ret = slapi_pblock_set(pb, SLAPI_PLUGIN_EXT_OP_FN, (void*) extop1_start
);
  if( i_ret != 0 )
    slapi_log_error( SLAPI_LOG_PLUGIN, "extop1_init",
    "[ERROR] registrazione %s\n", pluginDescription.spd_description );
  
2) slapd.conf look like this:
...
pluginlog /var/log/caronte/plugin.log
plugin extendedop  /opt/ldap/slapi/libextop1-plugin.so extop1_init ...


After server restart:
a) the log file plugin.log tell me that the plugin was successfully registered:
...
06/17/10 10:43:53 plugin_pblock_new: Registered plugin my-plugin 0.1 [mycompany]
(description plugin) ...

b) and the rootDSE object contains information about my extended operation, an
'ldapsearch -x -s base -b "" "(objectclass=*)" +' output like this:
...
supportedControl: 1.3.6.1.1.12
supportedExtension: 1.3.6.1.4.1.35746.2.11.1
supportedExtension: 1.3.6.1.4.1.4203.1.11.1
supportedExtension: 1.3.6.1.4.1.4203.1.11.3
supportedExtension: 1.3.6.1.1.8

But, when i perform the extended operation, no plugin is executed and i get the
error code 2 and the slapd log file look like this:
Jun 17 09:53:03 linux-setup slapd[11969]: conn=1000 op=1 EXT
oid=1.3.6.1.4.1.35746.2.11.1 Jun 17 09:57:33 linux-setup slapd[11969]: conn=1000
op=1 do_extended: unsupported operation "1.3.6.1.4.1.35746.2.11.1"
Jun 17 09:57:33 linux-setup slapd[11969]: conn=1000 op=1 RESULT tag=120 err=2
text=unsupported extended operation

Is it a bug or a lack of implementation?