1

I am trying to add a custom attribute to the user class in active directory but it keeps failing. I have already created the ExpirationDate attribute (date-time type -- oMYsyntax = 24 and attributeSyntax = 2.5.5.11).

I have added several other attributes successfully (all others were string type though) with the exact same syntax - just changing the mayContain to the desired attribute name. This one keeps failing though

Add error on entry starting on line 1: No Such Attribute The server side error is: 0x57 The parameter is incorrect. The extended server error is: 00000057: LdapErr: DSID-0C090D6F, comment: Error in attribute conversion operation, data 0, v2580 Number of Objects Modified: 0.

I've tried with and without a space after "dn:" but both failed with same error. What am I doing wrong?

    dn: CN=User,CN=Schema,CN=Configuration,DC=sub,DC=domain,DC=local
    changetype: modify
    add: mayContain
    mayContain: ExpirationDate
    -

Note I am using AWS Directory Service - so I cannot update the attributes using the AD Schema Console - I have to use the ldf method

sp_vennem
  • 55
  • 1
  • 8

1 Answers1

0

if you declare your attribute as datetime, you should provide a datetime entry if you want to add it, you can change your attribute type to string, or observe if there is oter datetime attribute in your directory a copy thier variable structure (i.e. 01/01/01 or 01-01-01 ...)

Hamza Tahiri
  • 488
  • 3
  • 13