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

Issue(s) with lastmod in slapd.conf



Hello,

    I had a question about the 'lastmod' construct in the slapd.conf file:
After looking at the bugs mailing list, I see that it's been mentioned,
and about 5 small patches were submitted, but have not been rolled
into the development tree yet...  (Due to the 'Z' timezone issue, and
the ISO (optional?) separator compliance issue?).  Have any decisions
been made about it?

    My personal vote would be to go with UTC time, but another option
would be to extend the syntax in the slapd.conf file to something like:

       lastmod: <on|off|utc>   where on <=> local time (since that's the
                                                        current behaviour)



   On a related subject: I was working with the shell backend, seeing
what the 'modify' command would generate for output, and I was getting
output like this:

  MODIFY
  msgid: 2
  suffix: o=Some Site,c=US
  dn: cn=Some value, o=Some Site, c=US
  replace: modifytimestampmodifytimestamp: 981021095151Z
  replace: modifiersnamemodifiersname: cn=root,o=Some Site,c=US
  add: myattrmyattr: my value for this attribute
  delete: oldattroldattr: old value for this attr
  replace: someattrsomeattr: the value is now different

>From the looks of it, there's a missing newline after the attribute 
being modified.  If that's the case, here's a patch to fix that:

	- Dan (Daniel Carroll - dan@mesastate.edu)

*** servers/slapd/back-shell/modify.c	Wed Oct 21 09:55:40 1998
--- servers/slapd/back-shell/modify.c~	Wed Oct 21 09:55:24 1998
***************
*** 41,55 ****
  	for ( ; mods != NULL; mods = mods->mod_next ) {
  		switch ( mods->mod_op & ~LDAP_MOD_BVALUES ) {
  		case LDAP_MOD_ADD:
! 			fprintf( wfp, "add: %s\n", mods->mod_type );
  			break;
  
  		case LDAP_MOD_DELETE:
! 			fprintf( wfp, "delete: %s\n", mods->mod_type );
  			break;
  
  		case LDAP_MOD_REPLACE:
! 			fprintf( wfp, "replace: %s\n", mods->mod_type );
  			break;
  		}
  
--- 41,55 ----
  	for ( ; mods != NULL; mods = mods->mod_next ) {
  		switch ( mods->mod_op & ~LDAP_MOD_BVALUES ) {
  		case LDAP_MOD_ADD:
! 			fprintf( wfp, "add: %s", mods->mod_type );
  			break;
  
  		case LDAP_MOD_DELETE:
! 			fprintf( wfp, "delete: %s", mods->mod_type );
  			break;
  
  		case LDAP_MOD_REPLACE:
! 			fprintf( wfp, "replace: %s", mods->mod_type );
  			break;
  		}