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

(ITS#5940) crash in slapo-rwm when modifying olcRwmRewrite

Full_Name: Jonathan Clarke
Version: RE24
OS: CentOS
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (


Given a simple setup involving back-ldap with slapo-rwm on top, modifying the
attribute "olcRwmRewrite" causes a crash. This seems to happen both while
modifying an existing value, or when deleting one.

The config:
# {1}ldap, config
dn: olcDatabase={1}ldap,cn=config
objectClass: olcDatabaseConfig
objectClass: olcLDAPConfig
olcDatabase: {1}ldap
olcSuffix: o=proxy
olcAddContentAcl: FALSE
olcLastMod: FALSE
olcMaxDerefDepth: 15
olcReadOnly: FALSE
olcMonitoring: FALSE
olcDbURI: "ldap://server.lan";
olcDbStartTLS: none
olcDbIDAssertBind: mode=none flags=prescriptive bindmethod=simple timeout=0 ne
 twork-timeout=0 binddn="cn=administrateur,cn=users,dc=otherdemo,dc=lan" creden
olcDbRebindAsUser: FALSE
olcDbChaseReferrals: TRUE
olcDbTFSupport: no
olcDbProxyWhoAmI: FALSE
olcDbSingleConn: FALSE
olcDbCancel: abandon
olcDbUseTemporaryConn: FALSE
olcDbConnectionPoolMax: 16
olcDbNoRefs: FALSE
olcDbNoUndefFilter: FALSE

# {0}rwm, {1}ldap, config
dn: olcOverlay={0}rwm,olcDatabase={1}ldap,cn=config
objectClass: olcOverlayConfig
objectClass: olcRwmConfig
olcOverlay: {0}rwm
olcRwmRewrite: {0}rwm-suffixmassage "o=proxy" "dc=otherdemo,dc=lan"
olcRwmTFSupport: false
olcRwmNormalizeMapped: FALSE

The operation:
dn: olcOverlay={0}rwm,olcDatabase={1}ldap,cn=config
changeType: modify
replace: olcRwmRewrite
olcRwmRewrite: {0}rwm-suffixmassage "o=proxy" "dc=demo,dc=lan"


GDB output:
conn=4 fd=12 ACCEPT from IP= (IP=
conn=4 op=0 BIND dn="cn=config" method=128
conn=4 op=0 BIND dn="cn=config" mech=SIMPLE ssf=0
conn=4 op=0 RESULT tag=97 err=0 text=
conn=4 op=1 MOD dn="olcOverlay={0}rwm,olcDatabase={1}ldap,cn=config"
conn=4 op=1 MOD attr=olcRwmRewrite
slapd: config.c:59: rewrite_parse: Assertion `info != ((void *)0)' failed.

Program received signal SIGABRT, Aborted.
[Switching to Thread 1106893120 (LWP 31852)]
0x0000003411a30155 in raise () from /lib64/libc.so.6
(gdb) bt
#0  0x0000003411a30155 in raise () from /lib64/libc.so.6
#1  0x0000003411a31bf0 in abort () from /lib64/libc.so.6
#2  0x0000003411a295d6 in __assert_fail () from /lib64/libc.so.6
#3  0x00000000004ea899 in rewrite_parse (info=0x0, fname=0x555ec5 "<suffix
massage>", lineno=1, argc=2, argv=0x41f9a180) at config.c:59
#4  0x00000000004df8fe in rwm_suffix_massage_config (info=0x7c6a,
pvnc=0x41f9a220, nvnc=<value optimized out>, prnc=0x41f9a1f0, nrnc=<value
optimized out>)
    at rwmconf.c:326
#5  0x00000000004dc1bd in rwm_suffixmassage_config (be=<value optimized out>,
fname=0x523789 "slapd", lineno=0, argc=<value optimized out>, 
    argv=<value optimized out>) at rwm.c:1662
#6  0x00000000004dc632 in rwm_cf_gen (c=0x41f9a620) at rwm.c:2076
#7  0x0000000000414b7b in config_set_vals (Conf=0x7abc00, c=0x7c6c) at
#8  0x000000000041835d in config_parse_add (ct=0x7abc00, c=0x41f9a620,
valx=<value optimized out>) at config.c:642
#9  0x000000000040e63f in config_modify_add (ct=0x7abc00, ca=0x41f9a620,
ad=<value optimized out>, i=0) at bconfig.c:4806
#10 0x0000000000410b03 in config_back_modify (op=0x1c8bf360, rs=0x41f9cc20) at
#11 0x0000000000434317 in fe_op_modify (op=0x1c8bf360, rs=0x41f9cc20) at
#12 0x0000000000434a72 in do_modify (op=0x1c8bf360, rs=0x41f9cc20) at
#13 0x000000000041dd2b in connection_operation (ctx=0x41f9cd70, arg_v=<value
optimized out>) at connection.c:1097
#14 0x000000000041e207 in connection_read_thread (ctx=0x41f9cd70, argv=<value
optimized out>) at connection.c:1223
#15 0x00000000004f906a in ldap_int_thread_pool_wrapper (xpool=0x1c83c2d0) at
#16 0x00002b6a8d3532f7 in start_thread () from /lib64/libpthread.so.0
#17 0x0000003411ad1e3d in clone () from /lib64/libc.so.6

Let me know if you need any more details, or output from GDB.